-
Notifications
You must be signed in to change notification settings - Fork 7
/
.gitlab-ci.yml
246 lines (224 loc) · 6.23 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
stages:
- build
- docs
- deploy_docs
- test
- dagger
.excl_runner:
tags: [excl]
variables:
IRIS_INSTALL_ROOT: $CI_PROJECT_DIR/install
CONDA_ROOT: /auto/ciscratch/conda
build-job:
extends: [.excl_runner]
stage: build
before_script:
- module load cmake
- module load gnu
script:
- echo "Installing iris to $CI_PROJECT_DIR/install"
- bash build.sh
artifacts:
paths:
- $IRIS_INSTALL_ROOT
docs-job:
tags: [devdocs]
stage: docs
needs: [build-job]
before_script:
- source $CONDA_ROOT/etc/profile.d/conda.sh
- conda env create --force -p ./envs -f docs/sphinx/environment.yml
- conda activate ./envs
- source $IRIS_INSTALL_ROOT/setup.source
script:
- cd docs/sphinx/source
- python -m sphinx -T -E -b html -d _build/doctrees -D language=en . _build/html
artifacts:
paths:
- docs/sphinx/source/_build/html
.deploy_docs_common:
tags: [devdocs]
stage: deploy_docs
needs: [docs-job]
script:
rsync -a --delete docs/sphinx/source/_build/html/ ~/www/brisbane/iris
deploy_docs-job:
extends: .deploy_docs_common
only:
refs:
- ornl_main
deploy_docs_manual-job:
extends: .deploy_docs_common
when: manual
.test-job:
tags: [zenith]
needs: []
stage: test
allow_failure: true
before_script:
- source /auto/software/iris/setup_system.source
script:
- echo "Installing iris to $IRIS_INSTALL_ROOT"
- bash build-coverage.sh
- echo $CI_REPOSITORY_URL
- echo $CI_PROJECT_PATH
- source $IRIS_INSTALL_ROOT/setup.source
- echo $PATH
- echo $LD_LIBRARY_PATH
- echo $HIP_ROOT
- cd tests
- mkdir build
- cd build
- cmake .. -DIRIS=$IRIS
- make --ignore-errors
- echo IRIS_ARCHS is $IRIS_ARCHS
- ctest --output-junit testRes.xml
after_script:
- python3 -m venv .venv
- source .venv/bin/activate
- pip install gcovr==5.0 # There seems to be a bug for newer versions of gcovr.
- gcovr --xml-pretty --exclude-unreachable-branches --print-summary -o coverage.xml --gcov-ignore-parse-errors
coverage: /^\s*lines:\s*\d+.\d+\%/
artifacts:
when: always
paths:
- tests/build/Testing/Temporary/LastTest.log
- tests/build/testRes.xml
reports:
junit: tests/build/testRes.xml
coverage_report:
coverage_format: cobertura
path: coverage.xml
test-job-zenith-openmp:
extends: .test-job
before_script:
- source /auto/software/iris/setup_system.source
- export IRIS_ARCHS=openmp
- echo "Running OpenMP version of the tests..."
test-job-zenith-cuda:
extends: .test-job
before_script:
- source /auto/software/iris/setup_system.source
- export IRIS_ARCHS=cuda
- echo "Running CUDA version of the tests..."
test-job-zenith-hip:
extends: .test-job
before_script:
- source /auto/software/iris/setup_system.source
- export IRIS_ARCHS=hip
- echo "Running CUDA version of the tests..."
test-job-zenith-opencl:
extends: .test-job
before_script:
- source /auto/software/iris/setup_system.source
- export IRIS_ARCHS=opencl
- echo "Running OpenCL version of the tests..."
test-job-zenith-all:
extends: .test-job
before_script:
- source /auto/software/iris/setup_system.source
- export IRIS_ARCHS=openmp,cuda,hip,opencl
- echo "Running All version of the tests..."
test-job-explorer:
extends: .test-job
tags: [explorer]
# test-job-leconte:
# extends: .test-job
# tags: [leconte]
test-backends-29:
tags: [zenith]
needs: []
stage: test
allow_failure: true
before_script:
- source /auto/software/iris/setup_system.source
script:
- echo "Installing iris to $IRIS_INSTALL_ROOT"
- bash build-coverage.sh
- echo $CI_REPOSITORY_URL
- echo $CI_PROJECT_PATH
- source $IRIS_INSTALL_ROOT/setup.source
- echo $PATH
- echo $LD_LIBRARY_PATH
- echo $HIP_ROOT
- cd tests
- echo "Test backends for test 29"
- cd 29_data_mem
- bash test_backends.sh
after_script:
- python3 -m venv .venv
- source .venv/bin/activate
- pip install gcovr==5.0 # There seems to be a bug for newer versions of gcovr.
- gcovr --xml-pretty --exclude-unreachable-branches --print-summary -o coverage.xml --gcov-ignore-parse-errors
coverage: /^\s*lines:\s*\d+.\d+\%/
artifacts:
when: always
paths:
reports:
coverage_report:
coverage_format: cobertura
path: coverage.xml
test-backends-34:
tags: [zenith]
needs: []
stage: test
allow_failure: true
before_script:
- source /auto/software/iris/setup_system.source
script:
- echo "Installing iris to $IRIS_INSTALL_ROOT"
- bash build-coverage.sh
- echo $CI_REPOSITORY_URL
- echo $CI_PROJECT_PATH
- source $IRIS_INSTALL_ROOT/setup.source
- echo $PATH
- echo $LD_LIBRARY_PATH
- echo $HIP_ROOT
- cd tests
- echo "Test backends for test 34"
- cd 34_set_mem
- bash test_backends.sh
after_script:
- python3 -m venv .venv
- source .venv/bin/activate
- pip install gcovr==5.0 # There seems to be a bug for newer versions of gcovr.
- gcovr --xml-pretty --exclude-unreachable-branches --print-summary -o coverage.xml --gcov-ignore-parse-errors
coverage: /^\s*lines:\s*\d+.\d+\%/
artifacts:
when: always
paths:
reports:
coverage_report:
coverage_format: cobertura
path: coverage.xml
.dagger:
tags: [slurm]
stage: dagger
needs: [build-job]
.run-policy-evaluations-artifacts:
artifacts:
when: always
paths:
- apps/dagger/dagger-figures/*.csv
- slurm*.txt
- errors.txt
.test-correctness-artifacts:
artifacts:
when: always
paths:
- slurm*.txt
- errors.txt
dagger-zenith-run-policy-evaluations:
extends: [.dagger, .run-policy-evaluations-artifacts]
script:
- sbatch --wait --partition=gpu --nodelist=zenith .gitlab-ci-scripts/slurm-dagger-run-policy-evaluations.sh
- echo "Errors $(wc -l errors.txt)"
- cat errors.txt
- if [ -s errors.txt ]; then exit 1; fi
dagger-zenith-test-correctness:
extends: [.dagger, .test-correctness-artifacts]
script:
- sbatch --wait --partition=gpu --nodelist=zenith .gitlab-ci-scripts/slurm-dagger-test-correctness.sh
- echo "Errors $(wc -l errors.txt)"
- cat errors.txt
- if [ -s errors.txt ]; then exit 1; fi