-
Notifications
You must be signed in to change notification settings - Fork 88
/
.gitlab-ci.yml
717 lines (669 loc) · 21.8 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
stages:
- init-status
- sync
- trigger_pipeline
- build
- test
- code_quality
- deploy
- QoS_tools
- on-failure
- finalize-status
- benchmark-build
- benchmark-cuda
- benchmark-omp
- benchmark-reference
include:
- local: '.gitlab/image.yml'
- local: '.gitlab/rules.yml'
- local: '.gitlab/scripts.yml'
- local: '.gitlab/variables.yml'
# This is a workaround to conditionally make the branch pipelines
# interruptible, because the flag does not directly support rules [1].
#
# [1] https://gitlab.com/gitlab-org/gitlab/-/issues/194023#note_1225906002
- local: '.gitlab/add-interrupt.yml'
rules:
- if: $CI_COMMIT_BRANCH != "master" && $CI_COMMIT_BRANCH != "develop" && $CI_COMMIT_TAG !~ /^v\d+\.\d+\.\d+/
sync:
stage: sync
extends:
- .default_variables
- .before_script_git_template
- .use_status-job-settings
variables:
GIT_STRATEGY: none
PRIVATE_REPO: [email protected]:ginkgo-project/ginkgo.git
PUBLIC_REPO: [email protected]:ginkgo-project/ginkgo.git
script:
- git clone ${PRIVATE_REPO} -b ${CI_COMMIT_REF_NAME} repo_sync
- cd repo_sync
- git pull --ff-only ${PUBLIC_REPO} ${CI_COMMIT_REF_NAME}
- git push ${PRIVATE_REPO} ${CI_COMMIT_REF_NAME}
- git push ${PUBLIC_REPO} ${CI_COMMIT_REF_NAME}
only:
- master
- develop
trigger_pipeline:
stage: trigger_pipeline
extends:
- .default_variables
- .pr_trigger_condition
- .use_status-job-settings
variables:
STATUS_CONTEXT: "quick"
script:
- PR_ID=$(curl -s "https://api.github.com/search/issues?q=sha:${CI_COMMIT_SHA}"
| jq '.items[0].number')
- |
if [[ "${PR_ID}" != "null" ]]; then
echo "Finding the corresponding Pull Request - ${PR_ID}"
echo "Checking whether the PR contains 1:ST:ready-to-merge, 1:ST:run-full-test, or 1:ST:skip-full-test labels"
PR_CONTENT=$(curl -X GET -s -H "Accept: application/vnd.github.v3+json" -H "Authorization: token ${BOT_STATUS_TOKEN}" \
"https://api.github.com/repos/ginkgo-project/ginkgo/issues/${PR_ID}")
SKIP_FULL_PIPELINE=$(echo "${PR_CONTENT}" | jq -r 'any( [.labels | .[] | .name ] | .[] ; . == "1:ST:skip-full-test")')
ENABLE_FULL_PIPELINE=$(echo "${PR_CONTENT}" | jq -r \
'any( [.labels | .[] | .name ] | .[] ; . == "1:ST:ready-to-merge" or . == "1:ST:run-full-test")')
if [[ "${SKIP_FULL_PIPELINE}" == "true" ]]; then
echo "Skipping the full pipeline and making the full pipeline succeed"
curl -X POST -H "Accept: application/vnd.github.v3+json" -H "Authorization: token ${BOT_STATUS_TOKEN}" \
https://api.github.com/repos/ginkgo-project/ginkgo/statuses/${CI_COMMIT_SHA} \
-d "{\"state\":\"success\",\"context\":\"ci/gitlab/gitlab.com/trigger_pipeline\",\"target_url\":\"${CI_JOB_URL}\",\"description\":\"skipped full pipeline\"}"
echo "If you want to run the full tests, remove 1:ST:skip-full-test and add 1:ST:ready-to-merge or 1:ST:run-full-test to the pull request. Then rerun this job or start a new pipeline."
elif [[ "${ENABLE_FULL_PIPELINE}" == "true" ]]; then
echo "Running full pipeline."
curl -X POST -F token=${CI_JOB_TOKEN} -F "ref=${CI_COMMIT_REF_NAME}" -F "variables[STATUS_CONTEXT]=full" \
https://gitlab.com/api/v4/projects/6431537/trigger/pipeline
echo "If want to skip full pipeline, add 1:ST:skip-full-test. Rerun this job or start a new pipeline."
else
echo "Didn't find required labels, so we're making the full pipeline fail."
curl -X POST -H "Accept: application/vnd.github.v3+json" -H "Authorization: token ${BOT_STATUS_TOKEN}" \
https://api.github.com/repos/ginkgo-project/ginkgo/statuses/${CI_COMMIT_SHA} \
-d "{\"state\":\"failure\",\"context\":\"ci/gitlab/gitlab.com/trigger_pipeline\",\"target_url\":\"${CI_JOB_URL}\",\"description\":\"no run/skip full pipeline\"}"
echo "To skip the full pipeline for this pull request, rerun this job or start a new pipeline after adding the label 1:ST:skip-full-test."
echo "To run the full pipeline for this pull request, rerun this job or start a new pipeline after adding one of the 1:ST:run-full-test or 1:ST:ready-to-merge labels."
fi
else
echo "Can not find the corresponding Pull Request"
fi
# cuda 11.4 and friends
build/cuda110/nompi/gcc/cuda/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .quick_test_condition
- .use_gko_cuda110-mvapich-gnu9-llvm9
variables:
BUILD_OMP: "ON"
BUILD_CUDA: "ON"
BUILD_TYPE: "Release"
FAST_TESTS: "ON"
# fix gtest issue https://github.com/google/googletest/issues/3514
CXX_FLAGS: "-Wno-error=maybe-uninitialized"
# disable spurious unused argument warning
EXTRA_CMAKE_FLAGS: "-DCMAKE_CUDA_FLAGS=-diag-suppress=177"
# nvhpc and friends
build/nvhpc233/cuda120/nompi/nvcpp/release/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko_nvhpc233-cuda120-openmpi-gnu12-llvm16
variables:
CXX_COMPILER: "nvc++"
BUILD_OMP: "ON"
BUILD_CUDA: "ON"
BUILD_MPI: "OFF"
BUILD_TYPE: "Release"
FAST_TESTS: "ON"
BUILD_SHARED_LIBS: "OFF"
# disable common gflags warnings
CXX_FLAGS: "--diag_suppress=useless_using_declaration,declared_but_not_referenced"
# disable spurious unused argument warning
EXTRA_CMAKE_FLAGS: "-DCMAKE_CUDA_FLAGS=-diag-suppress=177"
build/nvhpc227/cuda117/nompi/nvcpp/debug/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko_nvhpc227-cuda117-openmpi-gnu11-llvm14
variables:
CXX_COMPILER: "nvc++"
BUILD_OMP: "ON"
BUILD_CUDA: "ON"
BUILD_MPI: "OFF"
BUILD_TYPE: "Debug"
FAST_TESTS: "ON"
# disable common gflags warnings
CXX_FLAGS: "--diag_suppress=useless_using_declaration,declared_but_not_referenced"
# disable spurious unused argument warning
EXTRA_CMAKE_FLAGS: "-DCMAKE_CUDA_FLAGS=-diag-suppress=177"
# ROCm 4.5 and friends
build/amd/nompi/gcc/rocm45/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .quick_test_condition
- .use_gko-rocm45-nompi-gnu8-llvm8
variables:
BUILD_OMP: "ON"
BUILD_HIP: "ON"
NONDEFAULT_STREAM: "ON"
BUILD_TYPE: "Release"
BUILD_HWLOC: "OFF"
build/amd/nompi/clang/rocm45/release/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-rocm45-nompi-gnu8-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
BUILD_HIP: "ON"
BUILD_TYPE: "Release"
BUILD_SHARED_LIBS: "OFF"
build/amd/nompi/clang/rocm45/debug/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-rocm45-nompi-gnu8-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
BUILD_HIP: "ON"
BUILD_TYPE: "Debug"
# ROCm 5.1.4 and friends
build/amd/nompi/gcc/rocm514/debug/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
BUILD_OMP: "ON"
BUILD_HIP: "ON"
BUILD_TYPE: "Debug"
BUILD_SHARED_LIBS: "OFF"
build/amd/nompi/clang/rocm514/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
BUILD_HIP: "ON"
BUILD_TYPE: "Release"
# without omp
build/amd/nompi/gcc/rocm514_wo_omp/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
BUILD_OMP: "OFF"
BUILD_MPI: "OFF"
BUILD_HIP: "ON"
BUILD_TYPE: "Release"
# no cuda but latest gcc and clang
build/nocuda/nompi/gcc/core/debug/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
BUILD_TYPE: "Debug"
FAST_TESTS: "ON"
BUILD_SHARED_LIBS: "OFF"
BUILD_HWLOC: "OFF"
build/nocuda/nompi/clang/core/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_TYPE: "Release"
build/nocuda/nompi/gcc/omp/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .quick_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
BUILD_OMP: "ON"
BUILD_TYPE: "Release"
build/nocuda/openmpi/clang/omp/debug/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-openmpi-gnu9-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
MPI_AS_ROOT: "ON"
BUILD_MPI: "ON"
BUILD_TYPE: "Debug"
FAST_TESTS: "ON"
BUILD_SHARED_LIBS: "OFF"
build/nocuda/openmpi/clang/omp/glibcxx-debug-release/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
MPI_AS_ROOT: "ON"
BUILD_MPI: "ON"
CXX_FLAGS: "-Wpedantic -D_GLIBCXX_DEBUG=1"
# The tests are prohibitively slow in Debug
BUILD_TYPE: "Release"
# nocuda with old compiler
build/nocuda/nompi/gcc/omp/release/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
BUILD_OMP: "ON"
BUILD_TYPE: "Release"
BUILD_SHARED_LIBS: "OFF"
build/nocuda-nomixed/nompi/clang/omp/release/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
BUILD_TYPE: "Release"
BUILD_SHARED_LIBS: "OFF"
MIXED_PRECISION: "OFF"
build/nocuda-nomixed/openmpi/gcc/omp/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
BUILD_MPI: "ON"
MPI_AS_ROOT: "ON"
BUILD_OMP: "ON"
BUILD_TYPE: "Release"
MIXED_PRECISION: "OFF"
build/nocuda-nomixed/nompi/clang/omp/debug/static:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
CXX_COMPILER: "clang++"
BUILD_OMP: "ON"
BUILD_TYPE: "Debug"
BUILD_SHARED_LIBS: "OFF"
MIXED_PRECISION: "OFF"
# spack oneapi 2023.1
build/icpx20231/gpu/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .quick_test_condition
- .use_gko-oneapi20231-igpu
variables:
CXX_COMPILER: "icpx"
CXX_FLAGS: "-Wpedantic -ffp-model=precise"
BUILD_SYCL: "ON"
BUILD_TYPE: "Release"
BUILD_SHARED_LIBS: "ON"
DPCPP_SINGLE_MODE: "ON"
ONEAPI_DEVICE_SELECTOR: "opencl:gpu"
BUILD_HWLOC: "OFF"
# TODO: Enable when debug shared library size issues are fixed
# build/dpcpp/level_zero_igpu/debug/shared:
# extends:
# - .build_and_test_template
# - .default_variables
# - .full_test_condition
# - .use_gko-oneapi-igpu
# variables:
# CXX_COMPILER: "dpcpp"
# CXX_FLAGS: "-Wpedantic -ffp-model=precise"
# BUILD_SYCL: "ON"
# BUILD_TYPE: "Debug"
# BUILD_SHARED_LIBS: "ON"
# DPCPP_SINGLE_MODE: "ON"
# ONEAPI_DEVICE_SELECTOR: "level_zero:gpu"
# It gives two available backends of GPU on tests
build/dpcpp/gpu/release/shared:
extends:
- .build_and_test_template
- .default_variables
- .full_test_condition
- .use_gko-oneapi-igpu
variables:
CXX_COMPILER: "dpcpp"
CXX_FLAGS: "-Wpedantic -ffp-model=precise"
BUILD_SYCL: "ON"
BUILD_TYPE: "Release"
# static builds take too long
BUILD_SHARED_LIBS: "ON"
DPCPP_SINGLE_MODE: "ON"
ONEAPI_DEVICE_SELECTOR: "*:gpu"
BUILD_HWLOC: "OFF"
# windows jobs
# Note that this is using Powershell, not bash
build/windows-cuda/release/shared:
extends:
- .quick_test_condition
stage: build
script:
- if (Test-Path build) { rm -r -fo build }
- if (Test-Path install) { rm -r -fo install }
- mkdir build
- mkdir install
- cmake -B build -DBUILD_SHARED_LIBS=ON -DGINKGO_BUILD_CUDA=ON "-DCMAKE_INSTALL_PREFIX=$pwd\install" .
- cmake --build build --config Release -j16
- ctest --test-dir build -C Release --no-tests=error --output-on-failure
- $env:PATH+=";$pwd/install/bin"
- cmake --install build --config Release
- cmake --build build --target test_install --config Release
tags:
- windows-cuda
build/windows/release/shared:
extends:
- .full_test_condition
stage: build
script:
- if (Test-Path build) { rm -r -fo build }
- if (Test-Path install) { rm -r -fo install }
- mkdir build
- mkdir install
- cmake -B build -DBUILD_SHARED_LIBS=ON -DGINKGO_BUILD_CUDA=OFF "-DCMAKE_INSTALL_PREFIX=$pwd\install" .
- cmake --build build --config Release -j16
- ctest --test-dir build -C Release --no-tests=error --output-on-failure -j16
- $env:PATH+=";$pwd/install/bin"
- cmake --install build --config Release
- cmake --build build --target test_install --config Release
tags:
- windows
# Job with important warnings as error
warnings:
stage: code_quality
extends:
- .build_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
BUILD_OMP: "ON"
CXX_FLAGS: "-Werror=pedantic -pedantic-errors"
allow_failure: yes
# Ensure kernel modules do not depend on core
no-circular-deps:
stage: code_quality
extends:
- .build_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
BUILD_OMP: "ON"
EXTRA_CMAKE_FLAGS: '-DGINKGO_CHECK_CIRCULAR_DEPS=on'
allow_failure: no
# Ensure Ginkgo builds from a subdirectory
subdir-build:
stage: code_quality
extends:
- .build_template
- .default_variables
- .full_test_condition
- .use_gko-nocuda-nompi-gnu9-llvm8
variables:
BUILD_OMP: "ON"
CI_PROJECT_PATH_SUFFIX: "/test_subdir"
allow_failure: no
# Run clang-tidy and iwyu
clang-tidy:
stage: code_quality
extends:
- .build_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
BUILD_OMP: "ON"
EXTRA_CMAKE_FLAGS: '-DGINKGO_WITH_CLANG_TIDY=ON'
allow_failure: yes
iwyu:
stage: code_quality
extends:
- .build_template
- .default_variables
- .full_test_condition
- .use_gko-rocm514-nompi-gnu11-llvm11
variables:
BUILD_OMP: "ON"
EXTRA_CMAKE_FLAGS: '-DGINKGO_WITH_IWYU=ON'
allow_failure: yes
# Code analysis, coverage and reporting tool
# For short living branches or PRs, try to detect an open PR
sonarqube_cov_:
stage: code_quality
extends:
- .default_variables
- .full_test_short_lived_condition
- .before_script_template
- .use_gko_cuda114-openmpi-gnu10-llvm12
tags:
- private_ci
- controller
- cpu
- nla-gpu
script:
- PR_ID=$(curl -s "https://api.github.com/search/issues?q=sha:${CI_COMMIT_SHA}"
| jq '.items[0].number')
- if [[ "${PR_ID}" != "null" ]]; then
target_branch=$(curl -s
"https://api.github.com/repos/ginkgo-project/ginkgo/pulls/${PR_ID}" | jq
'.base.ref' | sed 's/"//g');
sonar_branching="-Dsonar.pullrequest.branch=${CI_COMMIT_REF_NAME}
-Dsonar.pullrequest.base=${target_branch}
-Dsonar.pullrequest.key=${PR_ID}";
else
sonar_branching="-Dsonar.branch.name=${CI_COMMIT_REF_NAME}
-Dsonar.branch.target=develop";
fi
- ctest -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=COVERAGE
-DGINKGO_SONARQUBE_TEST=ON
- sonar-scanner -Dsonar.login=${SONARQUBE_LOGIN}
-Dsonar.cfamily.build-wrapper-output=build/bw-output
-Dsonar.cfamily.gcov.reportsPath=build/Testing/CoverageInfo
${sonar_branching}
- bash <(curl -s https://codecov.io/bash) -f "\!*examples*" -f "\!*third_party*" -f "\!*c\\+\\+*" -f "\!*benchmark*"
# For long living branches, do not detect the PR. A PR would always be detected
# (the one that was merged).
sonarqube_cov:
stage: code_quality
extends:
- .default_variables
- .deploy_condition
- .before_script_template
- .use_gko_cuda114-openmpi-gnu10-llvm12
tags:
- private_ci
- controller
- cpu
- nla-gpu
script:
- ctest -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=COVERAGE
-DGINKGO_SONARQUBE_TEST=ON
- sonar-scanner -Dsonar.login=${SONARQUBE_LOGIN}
-Dsonar.cfamily.build-wrapper-output=build/bw-output
-Dsonar.cfamily.gcov.reportsPath=build/Testing/CoverageInfo
-Dsonar.branch.name=${CI_COMMIT_REF_NAME}
- bash <(curl -s https://codecov.io/bash) -f "\!*examples*" -f "\!*third_party*" -f "\!*c\\+\\+*" -f "\!*benchmark*"
# Deploy documentation to github-pages
gh-pages:
stage: deploy
interruptible: false
extends:
- .default_variables
- .deploy_condition
- .before_script_git_template
- .use_status-job-settings
variables:
PUBLIC_REPO: [email protected]:ginkgo-project/ginkgo-generated-documentation.git
script:
# build docs
- mkdir -p ${CI_JOB_NAME} && pushd ${CI_JOB_NAME}
- cmake ${CI_PROJECT_DIR}
-DCMAKE_CXX_COMPILER=${CXX_COMPILER}
-DCMAKE_CUDA_COMPILER=${CUDA_COMPILER} -DCMAKE_BUILD_TYPE=${BUILD_TYPE}
-DBUILD_SHARED_LIBS=ON ${EXTRA_CMAKE_FLAGS} -DGINKGO_DEVEL_TOOLS=OFF
-DGINKGO_BUILD_REFERENCE=OFF -DGINKGO_BUILD_OMP=OFF -DGINKGO_BUILD_CUDA=OFF
-DGINKGO_BUILD_HIP=OFF -DGINKGO_BUILD_SYCL=OFF -DGINKGO_BUILD_MPI=OFF
-DGINKGO_BUILD_TESTS=OFF -DGINKGO_BUILD_EXAMPLES=OFF
-DGINKGO_BUILD_DOC=ON -DGINKGO_DOC_GENERATE_PDF=ON
- make usr
- make pdf
- popd
# publish it
- git clone ${PUBLIC_REPO} -b gh-pages gh-pages-repo
- rm -rf gh-pages-repo/doc/${CI_COMMIT_REF_NAME}
- mkdir -p gh-pages-repo/doc
- mkdir -p gh-pages-repo/doc/pdf
- cp -r ${CI_JOB_NAME}/doc/usr gh-pages-repo/doc/${CI_COMMIT_REF_NAME}
- cp ${CI_JOB_NAME}/doc/pdf.pdf gh-pages-repo/doc/pdf/${CI_COMMIT_REF_NAME}.pdf
- export CURRENT_SHA="$(git rev-parse --short HEAD)"
- cd gh-pages-repo
- git add -A
- git diff --quiet HEAD ||
(git commit -m "Update documentation from ginkgo-project/ginkgo@${CURRENT_SHA}" && git push)
dependencies: null
needs: []
threadsanitizer:
stage: QoS_tools
extends:
- .default_variables
- .deploy_condition
- .before_script_template
- .use_gko-rocm514-nompi-gnu11-llvm11
- .disable_job_condition
script:
- LD_PRELOAD=/usr/local/lib/libomp.so
CC=clang CXX=clang++
ctest -V -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=TSAN
-DCTEST_MEMORYCHECK_TYPE=ThreadSanitizer
-DCTEST_MEMORYCHECK_SANITIZER_OPTIONS=ignore_noninstrumented_modules=1
--timeout 6000
leaksanitizer:
stage: QoS_tools
extends:
- .default_variables
- .deploy_condition
- .before_script_template
- .use_gko-rocm514-nompi-gnu11-llvm11
script:
- ctest -V -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=LSAN
-DCTEST_MEMORYCHECK_TYPE=LeakSanitizer
addresssanitizer:
stage: QoS_tools
extends:
- .default_variables
- .deploy_condition
- .before_script_template
- .use_gko-rocm514-nompi-gnu11-llvm11
script:
- ctest -V -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=ASAN
-DCTEST_MEMORYCHECK_TYPE=AddressSanitizer
undefinedsanitizer:
stage: QoS_tools
extends:
- .default_variables
- .deploy_condition
- .before_script_template
- .use_gko-rocm514-nompi-gnu11-llvm11
script:
# the Gold linker is required because of a linker flag issues given by UBsan
# in the Ubuntu setup we are using.
- ctest -V -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=UBSAN
-DCTEST_MEMORYCHECK_TYPE=UndefinedBehaviorSanitizer
cudamemcheck:
stage: QoS_tools
extends:
- .before_script_template
- .default_variables
- .deploy_condition
- .use_gko_cuda110-mvapich-gnu9-llvm9
tags:
- private_ci
- nvidia-gpu
script:
- ctest -V -S cmake/CTestScript.cmake -DCTEST_BUILD_CONFIGURATION=RelWithDebInfo
-DCTEST_MEMORYCHECK_TYPE=CudaMemcheck
new-issue-on-failure:
stage: on-failure
interruptible: false
extends:
- .default_variables
- .use_status-job-settings
script: curl --request POST "https://gitlab.com/api/v4/projects/${PROJECT_ID}/issues?private_token=${BOT_ACCESS_TOKEN}&title=Error%20in%20${CI_PROJECT_NAME}%20with%20pipeline%20${CI_PIPELINE_ID}%20for%20commit%20${CI_COMMIT_SHA}&labels&description=${CI_PIPELINE_URL}"
when: on_failure
only:
refs:
- develop
- master
dependencies: []
## Benchmark SpMV
benchmark-cuda-spmv-build:
extends:
- .build_template
- .default_variables
- .use_gko_cuda114-openmpi-gnu10-llvm12
- .benchmark-spmv-cuda-rules
- .disable_job_condition
stage: benchmark-build
variables:
BUILD_OMP: "ON"
BUILD_CUDA: "ON"
BUILD_MPI: "ON"
MPI_AS_ROOT: "ON"
BUILD_HIP: "OFF"
BUILD_TYPE: "Release"
CUDA_ARCH: 80
USE_NAME: "benchmark-cuda-spmv-${CI_PIPELINE_ID}"
KEEP_CONTAINER: "ON"
USE_SLURM: 0
# The name must be of the same as above without `-build`
benchmark-cuda-spmv:
extends:
- .benchmark_template
- .default_variables
- .use_gko_cuda114-openmpi-gnu10-llvm12
- .benchmark-spmv-cuda-rules
- .disable_job_condition
stage: benchmark-cuda
variables:
BENCHMARK_REPO: [email protected]:ginkgo-project/ginkgo-data.git
USE_NAME: "benchmark-cuda-spmv-${CI_PIPELINE_ID}"
SLURM_PARTITION: "accelerated"
SLURM_GRES: "gpu:1"
SLURM_EXCLUSIVE: "ON"
SLURM_TIME: "4:00:00"
BENCHMARK: "spmv"
EXECUTOR: "cuda"
SYSTEM_NAME: "A100"
dependencies: null
needs: [ "benchmark-cuda-spmv-build" ]