-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
335 lines (313 loc) · 15.6 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
# -*-indent-tabs-mode:nil;c-basic-offset:2;tab-width:4;-*-
# Copyright 2020-2023 Alfredo A. Correa
image: debian:testing
workflow:
auto_cancel:
on_new_commit: interruptible
variables:
GIT_SUBMODULE_STRATEGY: recursive
openmpi:
stage: build
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates libopenmpi-dev openmpi-bin cmake make g++ git libboost-serialization-dev
- cd .. && ln -s boost-mpi3 mpi3 && cd mpi3
- cd test
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- cmake .. -DCMAKE_BUILD_TYPE=Debug
- cmake --build . --parallel 2 || make VERBOSE=1
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
openmpi-g++-7:
stage: build
image: debian:oldoldstable # default is gcc 8 as of Dec 2023
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates libopenmpi-dev openmpi-bin cmake make g++-7 git libboost-serialization-dev
- apt-get -qq -y install wget
- wget https://github.com/Kitware/CMake/releases/download/v3.27.0-rc3/cmake-3.27.0-rc3-linux-`uname -m`.sh --no-verbose
- sh ./cmake-3.27.0-rc3-linux-`uname -m`.sh --skip-license --prefix=/usr
- cmake --version
- g++-7 --version
- cd .. && ln -s boost-mpi3 mpi3 && cd mpi3
- cd test
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- export MPI_ALLOW_RUN_AS_ROOT="--allow-run-as-root"
- cmake .. -DCMAKE_CXX_COMPILER=g++-7 -DCMAKE_BUILD_TYPE=Debug
- cmake --build . --parallel 2 || make VERBOSE=1
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi"]
exampi:
allow_failure: false
stage: build
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates cmake g++ git libboost-serialization-dev make python3 ssh strace # ca-certificates libopenmpi-dev openmpi-bin cmake make g++ git libboost-serialization-dev
- git clone https://correaa:${EXATOKEN}@github.com/tonyskjellum/ExaMPI.git
- cd ExaMPI
- mkdir build && cd build
- cmake .. --install-prefix=$HOME/exa
- make -j 4
- make install
- export PATH=$HOME/exa/bin:$PATH
- export PATH=$HOME/exa/runtime:$PATH
- export LD_LIBRARY_PATH=$HOME/exa/lib:$LD_LIBRARY_PATH
- export MPI_PATH=$HOME/exa/bin
- export MPI_LIB=$HOME/exa/lib
- export MPI_INC=$HOME/exa/include
- export MPI_HOME=$HOME/exa
- which mpicxx
- which mpirun
- mpirun -n 2 --separate_rank --print_to_file --loghead --logfault --logexec --logcontrol tests/integration_tests/pingpong tests/integration_tests/allreduce
- mpirun -n 2 --separate_rank --print_to_file --loghead --logfault --logexec --logcontrol tests/integration_tests/pingpong tests/integration_tests/alltoall
- ctest --output-on-failure
- cd ../..
- mkdir build && cd build
- which mpicxx
- mpicxx --version
- cmake .. -DCMAKE_BUILD_TYPE=Debug -DUSE_EXAMPI=1 -DMPI_HOME=$HOME/exa
- make -j 2 || make VERBOSE=1
- ls
- ctest --output-on-failure
oneapi:
stage: build
image: intel/oneapi-hpckit:2023.0.0-devel-ubuntu22.04
tags:
- x86_64
- non-shared
script:
- apt-get update && apt-get install --no-install-recommends -y --quiet ca-certificates cmake curl g++ git make libboost-test-dev libboost-serialization-dev
- cd .. && ln -s boost-mpi3 mpi3 && cd mpi3
- cd test
- mkdir build && cd build
- icpx --version
- CXX=icpx CXXFLAGS="-O1" cmake .. -DCMAKE_BUILD_TYPE=Debug
- cmake --build . --parallel 2 || make VERBOSE=1
- ctest --output-on-failure
needs: ["openmpi"]
nvhpc-24.5 c++20:
stage: build
image: nvcr.io/nvidia/nvhpc:24.5-devel-cuda12.4-ubuntu22.04 # https://catalog.ngc.nvidia.com/orgs/nvidia/containers/nvhpc/tags
tags:
- x86_64
- large-disk-space
- non-shared
interruptible: true
script:
- apt-get update && apt-get install --no-install-recommends -y --quiet ca-certificates cmake curl g++ git make libboost-test-dev libboost-serialization-dev
- /opt/nvidia/hpc_sdk/Linux_x86_64/2024/compilers/bin/nvc++ --version
- mkdir build && cd build
- CXX=/opt/nvidia/hpc_sdk/Linux_x86_64/2024/compilers/bin/nvc++ cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_STANDARD=20
- cmake --build . --parallel 2 || cmake --build . --verbose
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi"]
openmpi-clang:
stage: build
image: debian:testing
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates libopenmpi-dev openmpi-bin cmake make clang g++ git libstdc++-12-dev libboost-serialization-dev
- cd .. && ln -s boost-mpi3 mpi3 && cd mpi3
- cd test
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- clang++ --version
- mpirun --version
- CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Debug
- cmake --build . --parallel 2 || make VERBOSE=1
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi"]
openmpi-clang20:
stage: build
image: debian:stable
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates libopenmpi-dev openmpi-bin cmake make clang git libstdc++-12-dev libboost-serialization-dev
- cd test
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- clang++ --version
- mpirun --version
- CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_STANDARD=20
- cmake --build . --parallel 2 || make VERBOSE=1
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi-clang"]
openmpi-clang-tidy:
stage: build
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates libopenmpi-dev openmpi-bin clang libstdc++-12-dev clang-tidy cmake git make libboost-serialization-dev
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- clang++ --version
- clang-tidy --version
- CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_CLANG_TIDY="clang-tidy"
- make --jobs=2 || make VERBOSE=1
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi-clang"]
openmpi-cppcheck:
stage: build
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends libopenmpi-dev openmpi-bin g++ libstdc++-12-dev ca-certificates cmake cppcheck git make libboost-serialization-dev pkg-config libfftw3-dev libfftw3-mpi-dev
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- g++ --version
- cppcheck --version
- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_CPPCHECK="cppcheck;--force;--enable=all;--inline-suppr;--language=c++;--check-level=exhaustive;--suppress=missingIncludeSystem;--suppress=syntaxError;--suppress=unmatchedSuppression;--suppress=unusedFunction;--std=c++17;--error-exitcode=666;-UEXCLUDE_CPPCHECK"
- make --jobs=2 || make VERBOSE=1
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi"]
mpich-debug:
stage: build
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends libopenmpi-dev openmpi-bin g++ libstdc++-12-dev ca-certificates cmake cppcheck git make libboost-serialization-dev
- cd test
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE=""
- export OMPI_ALLOW_RUN_AS_ROOT=1
- export OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1
- cmake .. -DCMAKE_BUILD_TYPE=Debug
- cmake --build . --parallel 2 || cmake --build . --verbose
- ctest --output-on-failure
mpich-valgrind:
stage: build
allow_failure: true
tags:
- non-shared
script:
- apt-get update -qq && apt-get install -qq -y --no-install-recommends ca-certificates cmake git libboost-test-dev libboost-serialization-dev libmpich-dev make mpich valgrind
- mpirun --version
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE=""
- export VALGRIND_EXE="valgrind --leak-check=full --track-origins=yes --show-leak-kinds=all --suppressions=.valgrind_suppressions --gen-suppressions=all --error-exitcode=1 "
- cmake .. -DCMAKE_BUILD_TYPE=Debug
- make --jobs=2 || make VERBOSE=1
- ulimit -n # reports current value
- ulimit -n 1024 # workaround neededed by valgrind in docker running in Fedora 37
- ctest --output-on-failure
needs: ["mpich-debug"]
qmcpack-openmpi:
stage: test
allow_failure: true
image: debian:testing
tags:
- non-shared
script:
- apt-get -qq update && apt-get -qq install --no-install-recommends -y libblas-dev liblapack-dev libfftw3-dev libboost-serialization-dev libopenmpi-dev gfortran g++ cmake make git ca-certificates numdiff python3 python3-numpy python3-h5py python3-mpi4py python3-scipy libxml2-dev libhdf5-dev valgrind
- git clone https://github.com/QMCPACK/qmcpack.git
- cd qmcpack
- git config --global user.email "[email protected]" && git config --global user.name "Alfredo Correa"
- git rm -r external_codes/mpi_wrapper/mpi3 && git commit -m "remove mpi3 subtree"
- git subtree add --squash -P external_codes/mpi_wrapper/mpi3 https://gitlab.com/correaa/boost-mpi3.git $CI_COMMIT_BRANCH
- cd build
- cmake -DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DBUILD_AFQMC=1 -DBUILD_PPCONVERT=1 -DQMC_MIXED_PRECISION=1 -DCMAKE_BUILD_TYPE=Debug -DMPIEXEC_PREFLAGS="--allow-run-as-root;--bind-to;none" .. #-DCMAKE_CXX_FLAGS="-Werror"
- make --jobs=2 || make VERBOSE=1 # afqmc test_afqmc_matrix test_afqmc_numerics test_afqmc_slaterdeterminantoperations test_afqmc_walkers test_afqmc_hamiltonians test_afqmc_hamiltonian_operations test_afqmc_phmsd test_afqmc_wfn_factory test_afqmc_prop_factory test_afqmc_estimators qmc-afqmc-performance
- export VALGRIND_EXE="valgrind --leak-check=full --track-origins=yes --show-leak-kinds=all --suppressions=.valgrind_suppressions --gen-suppressions=all --error-exitcode=1 "
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest -L deterministic -j 2 --output-on-failure -T memcheck # -R afqmc
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest -R afqmc -j 2 --output-on-failure -T memcheck # -R afqmc
needs: ["openmpi"]
qmcpack-cuda-runner:
allow_failure: false
image: nvcr.io/nvidia/cuda:11.8.0-devel-ubuntu22.04
tags:
- non-shared
- nvidia-docker
stage: test
script:
- apt-get -qq update && apt-get -qq install --no-install-recommends -y libblas-dev liblapack-dev libfftw3-dev libboost-serialization-dev libopenmpi-dev gfortran g++ cmake make git ca-certificates numdiff python3 python3-numpy python3-h5py python3-mpi4py python3-scipy libxml2-dev libhdf5-dev
- cmake --version
- git clone --depth=1 https://github.com/QMCPACK/qmcpack.git
- cd qmcpack
- git config --global user.email "[email protected]" && git config --global user.name "Alfredo Correa"
- git rm -r external_codes/mpi3 && git commit -m "remove mpi3 subtree"
- git subtree add --squash -P external_codes/mpi3 $CI_REPOSITORY_URL $CI_COMMIT_BRANCH # e.g. https://gitlab.com/correaa/boost-multi.git
- cd ../qmcpack
- cd build
- CUDACXX=/usr/local/cuda/bin/nvcc cmake -DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DBUILD_AFQMC=1 -DQMC_CXX_STANDARD=17 -DENABLE_CUDA=1 -DCMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc -DQMC_GPU_ARCHS=sm_61 -DCMAKE_CUDA_HOST_COMPILER=g++ -DCMAKE_CXX_FLAGS="-Wno-deprecated -Wno-deprecated-declarations" ..
- make -j4 afqmc test_afqmc_matrix test_afqmc_numerics test_afqmc_slaterdeterminantoperations test_afqmc_walkers test_afqmc_hamiltonians test_afqmc_hamiltonian_operations test_afqmc_phmsd test_afqmc_wfn_factory test_afqmc_prop_factory test_afqmc_estimators qmc-afqmc-performance
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest -R afqmc --output-on-failure
needs: ["openmpi-cuda-11", "qmcpack-openmpi"]
inq-openmpi:
stage: test
image: debian:testing
tags:
- non-shared
- cpu
script:
- apt-get update && apt-get install --no-install-recommends -y --quiet libblas-dev liblapack-dev libfftw3-dev libboost-filesystem-dev libboost-serialization-dev libboost-iostreams-dev libopenmpi-dev libhdf5-dev python3-numpy gfortran g++ cmake pkg-config python3-dev make git ca-certificates wget
- cmake --version
- git clone https://gitlab.com/npneq/inq.git --recurse-submodules
- cd inq
- cd external_libs/mpi3
- git checkout $CI_COMMIT_BRANCH # check that multi repo is mirrored correctly from this repo to the submodule repo (npneq)
- cd ../..
- mkdir build && cd build
- cmake .. --install-prefix=$HOME -DCMAKE_BUILD_TYPE=Release
- make --jobs=2 || make VERBOSE=1
- make install
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi"]
# - export DEBIAN_FRONTEND=noninteractive
# - apt-get update && apt-get install --no-install-recommends -y --quiet ca-certificates git gnupg software-properties-common
# - apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/debian11/x86_64/3bf863cc.pub
# - add-apt-repository "deb https://developer.download.nvidia.com/compute/cuda/repos/debian11/x86_64/ /"
# - add-apt-repository contrib
# - apt-get update
# - apt-get -y install cuda
# TODO(correaa) -> openmpi-cuda-11
openmpi-cuda-11:
stage: build
allow_failure: false
image: nvcr.io/nvidia/cuda:11.8.0-devel-ubuntu22.04
tags:
- non-shared
script:
- apt-get update && apt-get install --no-install-recommends -y cmake libboost-test-dev libboost-serialization-dev libopenmpi-dev make git
- /usr/local/cuda-11/bin/nvcc --version
- cd .. && ln -s boost-mpi3 mpi3 && cd mpi3
- cd test
- mkdir build && cd build
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- cmake .. -DCMAKE_CUDA_COMPILER=/usr/local/cuda-11/bin/nvcc -DCMAKE_BUILD_TYPE=Debug -DENABLE_CUDA=1
- cmake --build . --parallel 2 || cmake --build . --verbose
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure
needs: ["openmpi"]
# - wget https://cmake.org/files/v3.21/cmake-3.21.3-linux-x86_64.sh --no-verbose # following https://askubuntu.com/a/865294/15943
# - mkdir /opt/cmake
# - sh cmake-3.21.3-linux-x86_64.sh --skip-license --prefix=/opt/cmake
# - ln -s /opt/cmake/bin/cmake /usr/local/bin/cmake
inq-cuda-11-openmpi:
stage: build
allow_failure: true
image: nvcr.io/nvidia/cuda:11.8.0-devel-ubuntu22.04
tags:
- non-shared
- nvidia-docker
script:
- apt-get update && apt-get install --no-install-recommends -y --quiet cmake git libblas-dev liblapack-dev libfftw3-dev libboost-filesystem-dev libboost-iostreams-dev libboost-serialization-dev libopenmpi-dev libhdf5-dev ca-certificates gfortran g++ make pkg-config python3-dev python3-numpy wget
- cmake --version
- git clone https://gitlab.com/npneq/inq.git --recurse-submodules
- cd inq
- cd external_libs/mpi3
- git checkout $CI_COMMIT_BRANCH
- cd ../..
- mkdir build && cd build
- /usr/local/cuda-11/bin/nvcc -V
- export MPI_OVERSUBSCRIBE="--oversubscribe"
- CUDACXX=/usr/local/cuda/bin/nvcc cmake .. --install-prefix=$HOME -DENABLE_CUDA=1 -DCMAKE_BUILD_TYPE=Release -DCMAKE_CUDA_ARCHITECTURES=80
- make --jobs=2 # silicon
- make install
- OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 ctest --output-on-failure # --jobs=2 # -R silicon
needs:
- openmpi-cuda-11