153928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 253928bd0SJeremy L Thompson# libCEED GitLab CI 353928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 409f072d1SJed Brownstages: 51e31b501SJeremy L Thompson - test:cpu-and-tidy 61e31b501SJeremy L Thompson - test:gpu-and-float 71e31b501SJeremy L Thompson 853af4701SJeremy L Thompsonworkflow: 953af4701SJeremy L Thompson auto_cancel: 1053af4701SJeremy L Thompson on_job_failure: all 1153af4701SJeremy L Thompson 1226a4920cSJeremy L Thompson 1353928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 1453928bd0SJeremy L Thompson# Memcheck backends + ASAN 1553928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 1653928bd0SJeremy L Thompsonnoether-asan: 1753928bd0SJeremy L Thompson stage: test:cpu-and-tidy 1853928bd0SJeremy L Thompson tags: 1953928bd0SJeremy L Thompson - cpu 2053928bd0SJeremy L Thompson interruptible: true 2153928bd0SJeremy L Thompson before_script: 2253928bd0SJeremy L Thompson # Environment 239e9358dcSJeremy L Thompson # Note: COVERAGE=0 is needed when using ASAN 2453928bd0SJeremy L Thompson - export COVERAGE=0 CC=gcc CXX=g++ FC=gfortran 2553928bd0SJeremy L Thompson - export NPROC_POOL=8 2653928bd0SJeremy L Thompson - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 2753928bd0SJeremy L Thompson - echo "-------------- CC ------------------" && $CC --version 2853928bd0SJeremy L Thompson - echo "-------------- CXX -----------------" && $CXX --version 2953928bd0SJeremy L Thompson - echo "-------------- FC ------------------" && $FC --version 3053928bd0SJeremy L Thompson # ASAN 3153928bd0SJeremy L Thompson - echo "-------------- ASAN ----------------" 3253928bd0SJeremy L Thompson - export ASAN=1 AFLAGS="-fsanitize=address -fsanitize=leak" 3353928bd0SJeremy L Thompson - echo $AFLAGS 3453928bd0SJeremy L Thompson script: 3553928bd0SJeremy L Thompson - rm -f .SUCCESS 3653928bd0SJeremy L Thompson # libCEED 3753928bd0SJeremy L Thompson - make configure OPT='-O -march=native -ffp-contract=fast' 38ad037b63SJeremy L Thompson - BACKENDS_CPU=$(make info-backends-all | grep -o '/cpu[^ ]*' | tr '\n' ' ') 3953928bd0SJeremy L Thompson - echo "-------------- libCEED -------------" && make info 40ad037b63SJeremy L Thompson - echo "-------------- BACKENDS_CPU --------" && echo $BACKENDS_CPU 413bcf805fSJeremy L Thompson - make clean 4253928bd0SJeremy L Thompson - make -j$NPROC_CPU 4353928bd0SJeremy L Thompson # -- libCEED only tests 4453928bd0SJeremy L Thompson - echo "-------------- core tests ----------" 4553928bd0SJeremy L Thompson - echo '[{"subject":"/","metrics":[{"name":"Transfer Size (KB)","value":"19.5","desiredSize":"smaller"},{"name":"Speed Index","value":0,"desiredSize":"smaller"},{"name":"Total Score","value":92,"desiredSize":"larger"},{"name":"Requests","value":4,"desiredSize":"smaller"}]}]' > performance.json 4653928bd0SJeremy L Thompson # Note: PETSC_DIR is set by default in GitLab runner env, unsetting to isolate core tests 4753928bd0SJeremy L Thompson - export PETSC_DIR= PETSC_ARCH= 48ad037b63SJeremy L Thompson - make -k -j$((NPROC_CPU / NPROC_POOL)) BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="memcheck" junit realsearch=% 4953928bd0SJeremy L Thompson # Clang-tidy 5053928bd0SJeremy L Thompson - echo "-------------- clang-tidy ----------" && clang-tidy --version 519e9358dcSJeremy L Thompson - TIDY_OPTS="-fix-errors" make -j$NPROC_CPU tidy && git diff --color=always --exit-code 5253928bd0SJeremy L Thompson # Report status 5353928bd0SJeremy L Thompson - touch .SUCCESS 5453928bd0SJeremy L Thompson artifacts: 5553928bd0SJeremy L Thompson paths: 5653928bd0SJeremy L Thompson - build/*.junit 5753928bd0SJeremy L Thompson reports: 5853928bd0SJeremy L Thompson junit: build/*.junit 5953928bd0SJeremy L Thompson performance: performance.json 6053928bd0SJeremy L Thompson 6153928bd0SJeremy L Thompson 6253928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 6353928bd0SJeremy L Thompson# CPU backends only + make tidy 6453928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 651e31b501SJeremy L Thompsonnoether-cpu: 661e31b501SJeremy L Thompson stage: test:cpu-and-tidy 671e31b501SJeremy L Thompson tags: 681e31b501SJeremy L Thompson - cpu 691e31b501SJeremy L Thompson interruptible: true 701e31b501SJeremy L Thompson before_script: 711e31b501SJeremy L Thompson # Environment 729e9358dcSJeremy L Thompson - export COVERAGE=1 CC=gcc CXX=g++ FC=gfortran 7319868e18SZach Atkins - export NPROC_POOL=8 741e31b501SJeremy L Thompson - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 751e31b501SJeremy L Thompson - echo "-------------- CC ------------------" && $CC --version 761e31b501SJeremy L Thompson - echo "-------------- CXX -----------------" && $CXX --version 771e31b501SJeremy L Thompson - echo "-------------- FC ------------------" && $FC --version 781e31b501SJeremy L Thompson - echo "-------------- GCOV ----------------" && gcov --version 791e31b501SJeremy L Thompson # Libraries for backends 80ed721ed8SJeremy L Thompson # -- LIBXSMM 7 April 2024 81ed721ed8SJeremy L Thompson - cd .. && export XSMM_HASH=94ee71576870152feb62f3f0cf6b061d036dcdb5 && { [[ -d libxsmm-$XSMM_HASH ]] || { curl -L https://github.com/libxsmm/libxsmm/archive/$XSMM_HASH.tar.gz -o xsmm.tar.gz && tar zvxf xsmm.tar.gz && rm xsmm.tar.gz && make -C libxsmm-$XSMM_HASH -j$(nproc); }; } && export XSMM_DIR=$PWD/libxsmm-$XSMM_HASH && cd libCEED 8268c150f8SJed Brown - echo "-------------- LIBXSMM -------------" && basename $XSMM_DIR 83a4b1483eSJeremy L Thompson # -- OCCA v1.6.0 84a4b1483eSJeremy L Thompson - cd .. && export OCCA_VERSION=occa-1.6.0 && { [[ -d $OCCA_VERSION ]] || { git clone --depth 1 --branch v1.6.0 https://github.com/libocca/occa.git $OCCA_VERSION && cd $OCCA_VERSION && export ENABLE_OPENCL="OFF" ENABLE_DPCPP="OFF" ENABLE_HIP="OFF" ENABLE_CUDA="OFF" && ./configure-cmake.sh && cmake --build build --parallel $NPROC_CPU && cmake --install build && cd ..; }; } && export OCCA_DIR=$PWD/$OCCA_VERSION/install && cd libCEED 850be03a92SJeremy L Thompson - echo "-------------- OCCA ----------------" && git -C $OCCA_DIR describe --tags && LD_LIBRARY_PATH=$OCCA_DIR/lib $OCCA_DIR/bin/occa info 861e31b501SJeremy L Thompson script: 871e31b501SJeremy L Thompson - rm -f .SUCCESS 881e31b501SJeremy L Thompson # libCEED 891e31b501SJeremy L Thompson - make configure OPT='-O -march=native -ffp-contract=fast' 901b16049aSZach Atkins - BACKENDS_CPU=$(make info-backends-all | grep -o '/cpu[^ ]*' | tr '\n' ' ') 911e31b501SJeremy L Thompson - echo "-------------- libCEED -------------" && make info 921e31b501SJeremy L Thompson - echo "-------------- BACKENDS_CPU --------" && echo $BACKENDS_CPU 933bcf805fSJeremy L Thompson - make clean 942c2ea1dbSJeremy L Thompson - OCCA_DIR= PEDANTIC=1 make -j$NPROC_CPU 951e31b501SJeremy L Thompson - make -j$NPROC_CPU 961e31b501SJeremy L Thompson # -- libCEED only tests 971e31b501SJeremy L Thompson - echo "-------------- core tests ----------" 981e31b501SJeremy L Thompson - echo '[{"subject":"/","metrics":[{"name":"Transfer Size (KB)","value":"19.5","desiredSize":"smaller"},{"name":"Speed Index","value":0,"desiredSize":"smaller"},{"name":"Total Score","value":92,"desiredSize":"larger"},{"name":"Requests","value":4,"desiredSize":"smaller"}]}]' > performance.json 991e31b501SJeremy L Thompson # Note: PETSC_DIR is set by default in GitLab runner env, unsetting to isolate core tests 1001e31b501SJeremy L Thompson - export PETSC_DIR= PETSC_ARCH= 10119868e18SZach Atkins - make -k -j$((NPROC_CPU / NPROC_POOL)) BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="cpu" junit realsearch=% 1021e31b501SJeremy L Thompson # Libraries for examples 103e5422a12SJeremy L Thompson # -- PETSc (minimal) 1043472baabSJeremy L Thompson - export PETSC_DIR=/projects/petsc PETSC_ARCH=mpich-cpu-int64 && git -C $PETSC_DIR -c safe.directory=$PETSC_DIR describe 1051e31b501SJeremy L Thompson - echo "-------------- PETSc ---------------" && make -C $PETSC_DIR info 106637c7b11SJames Wright - make -k -j$((NPROC_CPU / NPROC_POOL)) BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="cpu" junit search="petsc fluids-navierstokes solids" 107a64df932SJeremy L Thompson # -- MFEM v4.7 108a64df932SJeremy L Thompson - cd .. && export MFEM_VERSION=mfem-4.7 && { [[ -d $MFEM_VERSION ]] || { git clone --depth 1 --branch v4.7 https://github.com/mfem/mfem.git $MFEM_VERSION && make -C $MFEM_VERSION -j$(nproc) serial CXXFLAGS="-O -std=c++11"; }; } && export MFEM_DIR=$PWD/$MFEM_VERSION && cd libCEED 1091e31b501SJeremy L Thompson - echo "-------------- MFEM ----------------" && make -C $MFEM_DIR info 11019868e18SZach Atkins - make -k -j$((NPROC_CPU / NPROC_POOL)) BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="cpu" junit search=mfem 1111e31b501SJeremy L Thompson # -- Nek5000 v19.0 1121e31b501SJeremy L Thompson - export COVERAGE=0 1131e31b501SJeremy L Thompson - cd .. && export NEK5K_VERSION=Nek5000-19.0 && { [[ -d $NEK5K_VERSION ]] || { git clone --depth 1 --branch v19.0 https://github.com/Nek5000/Nek5000.git $NEK5K_VERSION && cd $NEK5K_VERSION/tools && ./maketools genbox genmap reatore2 && cd ../..; }; } && export NEK5K_DIR=$PWD/$NEK5K_VERSION && export PATH=$NEK5K_DIR/bin:$PATH MPI=0 && cd libCEED 1141e31b501SJeremy L Thompson - echo "-------------- Nek5000 -------------" && git -C $NEK5K_DIR describe --tags 11519868e18SZach Atkins - export NPROC_POOL=1 116b41f14d5SJeremy L Thompson - make -k -j$NPROC_CPU BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="cpu" junit search=nek NEK5K_DIR=$NEK5K_DIR 1178c81f8b0SPeter Munch # -- deal.II 8bd5c262f13e15793aa206b6eed8774a9b25ce11 1188c81f8b0SPeter Munch - OCCA_DIR= BACKENDS_CPU=$(make info-backends-all | grep -o '/cpu[^ ]*' | tr '\n' ' ') 1198c81f8b0SPeter Munch - export DEAL_II_ROOT_DIR=/projects/dealii DEAL_II_DIR=/projects/dealii/install 1208c81f8b0SPeter Munch - echo "-------------- deal.II -------------" && git -C $DEAL_II_ROOT_DIR -c safe.directory=$DEAL_II_ROOT_DIR describe --always 1218c81f8b0SPeter Munch - make -k -j$NPROC_CPU BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="cpu" junit search=dealii DEAL_II_DIR=$DEAL_II_DIR 1221e31b501SJeremy L Thompson # Report status 1231e31b501SJeremy L Thompson - touch .SUCCESS 1241e31b501SJeremy L Thompson after_script: 1251e31b501SJeremy L Thompson - | 1261e31b501SJeremy L Thompson if [ -f .SUCCESS ]; then 127fe470f9dSJeremy L Thompson lcov --directory . --capture --output-file coverage.info --ignore-errors source,mismatch; 1281e31b501SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F interface; 1291e31b501SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F gallery; 1301e31b501SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F backends; 1311e31b501SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F tests; 1321e31b501SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F examples; 1331e31b501SJeremy L Thompson fi 1341e31b501SJeremy L Thompson artifacts: 1351e31b501SJeremy L Thompson paths: 1361e31b501SJeremy L Thompson - build/*.junit 1371e31b501SJeremy L Thompson reports: 1381e31b501SJeremy L Thompson junit: build/*.junit 1391e31b501SJeremy L Thompson performance: performance.json 14009f072d1SJed Brown 14126a4920cSJeremy L Thompson 14253928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 14353928bd0SJeremy L Thompson# Check SYCL backends build 14453928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 145ff186337SJeremy L Thompson 146ff186337SJeremy L Thompson# SYCL tests currently disabled 147ff186337SJeremy L Thompson 148ff186337SJeremy L Thompson#noether-sycl: 149ff186337SJeremy L Thompson# stage: test:gpu-and-float 150ff186337SJeremy L Thompson# tags: 151ff186337SJeremy L Thompson# - sycl 152ff186337SJeremy L Thompson# interruptible: true 153ff186337SJeremy L Thompson# before_script: 154ff186337SJeremy L Thompson# # Environment 155ff186337SJeremy L Thompson# - . /opt/intel/oneapi/setvars.sh 156ff186337SJeremy L Thompson# - export COVERAGE=1 CC=icx CXX=icpx 157ff186337SJeremy L Thompson# - export NPROC_POOL=8 158ff186337SJeremy L Thompson# - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 159ff186337SJeremy L Thompson# - echo "-------------- CC ------------------" && $CC --version 160ff186337SJeremy L Thompson# - echo "-------------- CXX -----------------" && $CXX --version 161ff186337SJeremy L Thompson# script: 162ff186337SJeremy L Thompson# - rm -f .SUCCESS 163ff186337SJeremy L Thompson# # libCEED 164ff186337SJeremy L Thompson# - make configure SYCL_DIR=/opt/intel/oneapi/compiler/latest OPT='-O -march=native -ffp-contract=fast' 165ff186337SJeremy L Thompson# - BACKENDS_SYCL=$(make info-backends-all | grep -o '/sycl[^ ]*' | tr '\n' ' ') 166ff186337SJeremy L Thompson# - echo "-------------- libCEED -------------" && make info 167ff186337SJeremy L Thompson# - echo "-------------- BACKENDS_SYCL -------" && echo $BACKENDS_SYCL 168ff186337SJeremy L Thompson# - make clean 169ff186337SJeremy L Thompson# - make -j$NPROC_CPU 170ff186337SJeremy L Thompson# # Report status 171ff186337SJeremy L Thompson# - touch .SUCCESS 17226a4920cSJeremy L Thompson 17326a4920cSJeremy L Thompson 17453928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 1752027fb9dSSirAlienTheGreat# Rust + CUDA 1762027fb9dSSirAlienTheGreat# ---------------------------------------------------------------------------------------- 1772027fb9dSSirAlienTheGreatnoether-rust-qfunctions: 1782027fb9dSSirAlienTheGreat stage: test:gpu-and-float 1792027fb9dSSirAlienTheGreat tags: 1802027fb9dSSirAlienTheGreat - cuda 1812027fb9dSSirAlienTheGreat interruptible: true 1822027fb9dSSirAlienTheGreat before_script: 1832027fb9dSSirAlienTheGreat # Environment 1842027fb9dSSirAlienTheGreat - export COVERAGE=1 CC=gcc CXX=g++ FC=gfortran NVCC=nvcc GPU_CLANG=1 1852027fb9dSSirAlienTheGreat - export NPROC_POOL=4 1862027fb9dSSirAlienTheGreat - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 1872027fb9dSSirAlienTheGreat - echo "-------------- CC ------------------" && $CC --version 1882027fb9dSSirAlienTheGreat - echo "-------------- CXX -----------------" && $CXX --version 1892027fb9dSSirAlienTheGreat - echo "-------------- FC ------------------" && $FC --version 1902027fb9dSSirAlienTheGreat - echo "-------------- NVCC ----------------" && $NVCC --version 1912027fb9dSSirAlienTheGreat - echo "-------------- Rustc ---------------" && rustc --version 1922027fb9dSSirAlienTheGreat - echo "-------------- Clang++ -------------" && clang++ --version 1932027fb9dSSirAlienTheGreat - echo "-------------- GCOV ----------------" && gcov --version 1942027fb9dSSirAlienTheGreat script: 1952027fb9dSSirAlienTheGreat - rm -f .SUCCESS 19627016012SJeremy L Thompson # Rustup 19727016012SJeremy L Thompson - rustup component add rust-src --toolchain nightly-x86_64-unknown-linux-gnu 1982027fb9dSSirAlienTheGreat # libCEED 1992027fb9dSSirAlienTheGreat - make configure OPT='-O -march=native -ffp-contract=fast' CUDA_DIR=/usr/local/cuda-12.9 2002027fb9dSSirAlienTheGreat - echo "-------------- libCEED -------------" && make info 2012027fb9dSSirAlienTheGreat - make clean 2022027fb9dSSirAlienTheGreat - make -k -j$NPROC_CPU -l$NPROC_CPU 2032027fb9dSSirAlienTheGreat # -- libCEED only tests 204*72206858SJeremy L Thompson - echo "-------------- Rust QFunction tests -----" 2052027fb9dSSirAlienTheGreat # Note: PETSC_DIR is set by default in GitLab runner env, unsetting to isolate core tests 2062027fb9dSSirAlienTheGreat - export PETSC_DIR= PETSC_ARCH= 207*72206858SJeremy L Thompson - make -k -j$((NPROC_GPU / NPROC_POOL)) JUNIT_BATCH="rust-qfunction" junit search=rustqfunction 2082027fb9dSSirAlienTheGreat # Report status 2092027fb9dSSirAlienTheGreat - touch .SUCCESS 2102027fb9dSSirAlienTheGreat after_script: 2112027fb9dSSirAlienTheGreat - | 2122027fb9dSSirAlienTheGreat if [ -f .SUCCESS ]; then 2132027fb9dSSirAlienTheGreat lcov --directory . --capture --output-file coverage.info --ignore-errors source,mismatch; 2142027fb9dSSirAlienTheGreat bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F interface; 2152027fb9dSSirAlienTheGreat bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F gallery; 2162027fb9dSSirAlienTheGreat bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F backends; 2172027fb9dSSirAlienTheGreat bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F tests; 2182027fb9dSSirAlienTheGreat bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F examples; 2192027fb9dSSirAlienTheGreat fi 2202027fb9dSSirAlienTheGreat artifacts: 2212027fb9dSSirAlienTheGreat paths: 2222027fb9dSSirAlienTheGreat - build/*.junit 2232027fb9dSSirAlienTheGreat reports: 2242027fb9dSSirAlienTheGreat junit: build/*.junit 2252027fb9dSSirAlienTheGreat 2262027fb9dSSirAlienTheGreat 2272027fb9dSSirAlienTheGreat# ---------------------------------------------------------------------------------------- 22853928bd0SJeremy L Thompson# CUDA backends 22953928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 23053928bd0SJeremy L Thompsonnoether-cuda: 23153928bd0SJeremy L Thompson stage: test:gpu-and-float 23253928bd0SJeremy L Thompson tags: 23353928bd0SJeremy L Thompson - cuda 23453928bd0SJeremy L Thompson interruptible: true 23553928bd0SJeremy L Thompson before_script: 23653928bd0SJeremy L Thompson # Environment 23753928bd0SJeremy L Thompson - export COVERAGE=1 CC=gcc CXX=g++ FC=gfortran NVCC=nvcc 23853928bd0SJeremy L Thompson - export NPROC_POOL=4 23953928bd0SJeremy L Thompson - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 24053928bd0SJeremy L Thompson - echo "-------------- CC ------------------" && $CC --version 24153928bd0SJeremy L Thompson - echo "-------------- CXX -----------------" && $CXX --version 24253928bd0SJeremy L Thompson - echo "-------------- FC ------------------" && $FC --version 24353928bd0SJeremy L Thompson - echo "-------------- NVCC ----------------" && $NVCC --version 24453928bd0SJeremy L Thompson - echo "-------------- GCOV ----------------" && gcov --version 24513da2136SJeremy L Thompson # ASAN 24613da2136SJeremy L Thompson - echo "-------------- ASAN ----------------" 24713da2136SJeremy L Thompson - export ASAN=1 AFLAGS="-fsanitize=address -fsanitize=leak" ASAN_OPTIONS=protect_shadow_gap=0 24813da2136SJeremy L Thompson - echo $AFLAGS 24953928bd0SJeremy L Thompson script: 25053928bd0SJeremy L Thompson - rm -f .SUCCESS 25153928bd0SJeremy L Thompson # libCEED 2527ad93db1SJed Brown - make configure OPT='-O -march=native -ffp-contract=fast' CUDA_DIR=/usr/local/cuda-12.9 25353928bd0SJeremy L Thompson - echo "-------------- libCEED -------------" && make info 25453928bd0SJeremy L Thompson - BACKENDS_GPU=$(make info-backends | grep -o '/gpu[^ ]*' | tr '\n' ' ') 25553928bd0SJeremy L Thompson - echo "-------------- BACKENDS_GPU --------" && echo $BACKENDS_GPU 2563bcf805fSJeremy L Thompson - make clean 25753928bd0SJeremy L Thompson - PEDANTIC=1 make -k -j$NPROC_CPU -l$NPROC_CPU 25853928bd0SJeremy L Thompson # -- libCEED only tests 25953928bd0SJeremy L Thompson - echo "-------------- core tests ----------" 26053928bd0SJeremy L Thompson # Note: PETSC_DIR is set by default in GitLab runner env, unsetting to isolate core tests 26153928bd0SJeremy L Thompson - export PETSC_DIR= PETSC_ARCH= 26253928bd0SJeremy L Thompson - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="cuda" junit realsearch=% 26313da2136SJeremy L Thompson # Rebuild without ASAN 264f3296101SJeremy L Thompson - unset ASAN AFLAGS ASAN_OPTIONS 26513da2136SJeremy L Thompson - make clean 26613da2136SJeremy L Thompson - PEDANTIC=1 make -k -j$NPROC_CPU -l$NPROC_CPU 26753928bd0SJeremy L Thompson # Libraries for examples 26853928bd0SJeremy L Thompson # -- PETSc with CUDA (minimal) 26953928bd0SJeremy L Thompson - export PETSC_DIR=/projects/petsc PETSC_ARCH=mpich-cuda-O PETSC_OPTIONS='-use_gpu_aware_mpi 0' && git -C $PETSC_DIR -c safe.directory=$PETSC_DIR describe 27053928bd0SJeremy L Thompson - echo "-------------- PETSc ---------------" && make -C $PETSC_DIR info 27138f1a2a7SJeremy L Thompson - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="cuda" junit search="petsc fluids solids" 27238f1a2a7SJeremy L Thompson # -- MFEM v4.7 27338f1a2a7SJeremy L Thompson - cd .. && export MFEM_VERSION=mfem-4.7 && { [[ -d $MFEM_VERSION ]] || { git clone --depth 1 --branch v4.7 https://github.com/mfem/mfem.git $MFEM_VERSION && make -C $MFEM_VERSION -j$(nproc) serial CXXFLAGS="-O -std=c++11"; }; } && export MFEM_DIR=$PWD/$MFEM_VERSION && cd libCEED 27438f1a2a7SJeremy L Thompson - echo "-------------- MFEM ----------------" && make -C $MFEM_DIR info 27538f1a2a7SJeremy L Thompson - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="cuda" junit search=mfem 27638f1a2a7SJeremy L Thompson # -- Nek5000 v19.0 27738f1a2a7SJeremy L Thompson - export COVERAGE=0 27838f1a2a7SJeremy L Thompson - cd .. && export NEK5K_VERSION=Nek5000-19.0 && { [[ -d $NEK5K_VERSION ]] || { git clone --depth 1 --branch v19.0 https://github.com/Nek5000/Nek5000.git $NEK5K_VERSION && cd $NEK5K_VERSION/tools && ./maketools genbox genmap reatore2 && cd ../..; }; } && export NEK5K_DIR=$PWD/$NEK5K_VERSION && export PATH=$NEK5K_DIR/bin:$PATH MPI=0 && cd libCEED 27938f1a2a7SJeremy L Thompson - echo "-------------- Nek5000 -------------" && git -C $NEK5K_DIR describe --tags 28038f1a2a7SJeremy L Thompson - export NPROC_POOL=1 28138f1a2a7SJeremy L Thompson - make -k -j$NPROC_GPU BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="cuda" junit search=nek NEK5K_DIR=$NEK5K_DIR 28238f1a2a7SJeremy L Thompson # -- deal.II 8bd5c262f13e15793aa206b6eed8774a9b25ce11 28338f1a2a7SJeremy L Thompson - export DEAL_II_ROOT_DIR=/projects/dealii DEAL_II_DIR=/projects/dealii/install 28438f1a2a7SJeremy L Thompson - echo "-------------- deal.II -------------" && git -C $DEAL_II_ROOT_DIR -c safe.directory=$DEAL_II_ROOT_DIR describe --always 28538f1a2a7SJeremy L Thompson - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="cuda" junit search=dealii DEAL_II_DIR=$DEAL_II_DIR 2869e9358dcSJeremy L Thompson # Clang-tidy 2879e9358dcSJeremy L Thompson - echo "-------------- clang-tidy ----------" && clang-tidy --version 2889e9358dcSJeremy L Thompson - TIDY_OPTS="-fix-errors" make -j$NPROC_CPU tidy && git diff --color=always --exit-code 28953928bd0SJeremy L Thompson # Report status 29053928bd0SJeremy L Thompson - touch .SUCCESS 29153928bd0SJeremy L Thompson after_script: 29253928bd0SJeremy L Thompson - | 29353928bd0SJeremy L Thompson if [ -f .SUCCESS ]; then 294fe470f9dSJeremy L Thompson lcov --directory . --capture --output-file coverage.info --ignore-errors source,mismatch; 29553928bd0SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F interface; 29653928bd0SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F gallery; 29753928bd0SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F backends; 29853928bd0SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F tests; 29953928bd0SJeremy L Thompson bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F examples; 30053928bd0SJeremy L Thompson fi 30153928bd0SJeremy L Thompson artifacts: 30253928bd0SJeremy L Thompson paths: 30353928bd0SJeremy L Thompson - build/*.junit 30453928bd0SJeremy L Thompson reports: 30553928bd0SJeremy L Thompson junit: build/*.junit 30653928bd0SJeremy L Thompson 30753928bd0SJeremy L Thompson 30853928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 30953928bd0SJeremy L Thompson# ROCm backends 31053928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 3111caccaa9SJeremy L Thompson 312527d8beaSJeremy L Thompson# ROCm test execution currently disabled 3131caccaa9SJeremy L Thompson 3141caccaa9SJeremy L Thompson#noether-rocm: 3151caccaa9SJeremy L Thompson# stage: test:gpu-and-float 3161caccaa9SJeremy L Thompson# tags: 3171caccaa9SJeremy L Thompson# - rocm 3181caccaa9SJeremy L Thompson# interruptible: true 3191caccaa9SJeremy L Thompson# before_script: 3201caccaa9SJeremy L Thompson# # Environment 3211caccaa9SJeremy L Thompson# - export COVERAGE=1 CC=gcc CXX=g++ FC=gfortran HIPCC=hipcc 3221caccaa9SJeremy L Thompson# - export NPROC_POOL=4 3231caccaa9SJeremy L Thompson# - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 3241caccaa9SJeremy L Thompson# - echo "-------------- CC ------------------" && $CC --version 3251caccaa9SJeremy L Thompson# - echo "-------------- CXX -----------------" && $CXX --version 3261caccaa9SJeremy L Thompson# - echo "-------------- FC ------------------" && $FC --version 3271caccaa9SJeremy L Thompson# - echo "-------------- HIPCC ---------------" && $HIPCC --version 3281caccaa9SJeremy L Thompson# - echo "-------------- GCOV ----------------" && gcov --version 3291caccaa9SJeremy L Thompson# # Libraries for backends 3301caccaa9SJeremy L Thompson# # -- MAGMA from dev branch 3311caccaa9SJeremy L Thompson# - echo "-------------- MAGMA ---------------" 3321caccaa9SJeremy L Thompson# - export MAGMA_DIR=/projects/hipMAGMA && git -C $MAGMA_DIR -c safe.directory=$MAGMA_DIR describe 3331caccaa9SJeremy L Thompson# script: 3341caccaa9SJeremy L Thompson# - rm -f .SUCCESS 3351caccaa9SJeremy L Thompson# # libCEED 336f4239526SJed Brown# - make configure ROCM_DIR=/opt/rocm-6.3.0 OPT='-O -march=native -ffp-contract=fast' 3371caccaa9SJeremy L Thompson# - BACKENDS_CPU=$(make info-backends-all | grep -o '/cpu[^ ]*' | tr '\n' ' ') && BACKENDS_GPU=$(make info-backends | grep -o '/gpu[^ ]*' | tr '\n' ' ') 3381caccaa9SJeremy L Thompson# - echo "-------------- libCEED -------------" && make info 3391caccaa9SJeremy L Thompson# - echo "-------------- BACKENDS_GPU --------" && echo $BACKENDS_GPU 3401caccaa9SJeremy L Thompson# - make clean 3411caccaa9SJeremy L Thompson# - make -j$NPROC_CPU 3421caccaa9SJeremy L Thompson# # -- libCEED only tests 3431caccaa9SJeremy L Thompson# - echo "-------------- core tests ----------" 3441caccaa9SJeremy L Thompson# - echo '[{"subject":"/","metrics":[{"name":"Transfer Size (KB)","value":"19.5","desiredSize":"smaller"},{"name":"Speed Index","value":0,"desiredSize":"smaller"},{"name":"Total Score","value":92,"desiredSize":"larger"},{"name":"Requests","value":4,"desiredSize":"smaller"}]}]' > performance.json 3451caccaa9SJeremy L Thompson# # Note: PETSC_DIR is set by default in GitLab runner env, unsetting to isolate core tests 3461caccaa9SJeremy L Thompson# - export PETSC_DIR= PETSC_ARCH= 3471caccaa9SJeremy L Thompson# - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="hip" junit realsearch=% 3481caccaa9SJeremy L Thompson# # Libraries for examples 3491caccaa9SJeremy L Thompson# # -- PETSc with HIP (minimal) 3501caccaa9SJeremy L Thompson# - export PETSC_DIR=/projects/petsc PETSC_ARCH=mpich-hip && git -C $PETSC_DIR -c safe.directory=$PETSC_DIR describe 3511caccaa9SJeremy L Thompson# - echo "-------------- PETSc ---------------" && make -C $PETSC_DIR info 3521caccaa9SJeremy L Thompson# - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="hip" junit search="petsc fluids solids" 3531caccaa9SJeremy L Thompson# # Clang-tidy 3541caccaa9SJeremy L Thompson# - echo "-------------- clang-tidy ----------" && clang-tidy --version 3551caccaa9SJeremy L Thompson# - TIDY_OPTS="-fix-errors" make -j$NPROC_CPU tidy && git diff --color=always --exit-code 3561caccaa9SJeremy L Thompson# # Report status 3571caccaa9SJeremy L Thompson# - touch .SUCCESS 3581caccaa9SJeremy L Thompson# after_script: 3591caccaa9SJeremy L Thompson# - | 3601caccaa9SJeremy L Thompson# if [ -f .SUCCESS ]; then 361fe470f9dSJeremy L Thompson# lcov --directory . --capture --output-file coverage.info --ignore-errors source,mismatch; 3621caccaa9SJeremy L Thompson# bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F interface; 3631caccaa9SJeremy L Thompson# bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F gallery; 3641caccaa9SJeremy L Thompson# bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F backends; 3651caccaa9SJeremy L Thompson# bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F tests; 3661caccaa9SJeremy L Thompson# bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F examples; 3671caccaa9SJeremy L Thompson# fi 3681caccaa9SJeremy L Thompson# artifacts: 3691caccaa9SJeremy L Thompson# paths: 3701caccaa9SJeremy L Thompson# - build/*.junit 3711caccaa9SJeremy L Thompson# reports: 3721caccaa9SJeremy L Thompson# junit: build/*.junit 3731caccaa9SJeremy L Thompson# performance: performance.json 374422b158fSJed Brown 37526a4920cSJeremy L Thompson 376527d8beaSJeremy L Thompsonnoether-rocm: 377527d8beaSJeremy L Thompson stage: test:gpu-and-float 378527d8beaSJeremy L Thompson tags: 379527d8beaSJeremy L Thompson - rocm 380527d8beaSJeremy L Thompson interruptible: true 381527d8beaSJeremy L Thompson before_script: 382527d8beaSJeremy L Thompson # Environment 383527d8beaSJeremy L Thompson - export COVERAGE=1 CC=gcc CXX=g++ FC=gfortran HIPCC=hipcc 384527d8beaSJeremy L Thompson - export NPROC_POOL=4 385527d8beaSJeremy L Thompson - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 386527d8beaSJeremy L Thompson - echo "-------------- CC ------------------" && $CC --version 387527d8beaSJeremy L Thompson - echo "-------------- CXX -----------------" && $CXX --version 388527d8beaSJeremy L Thompson - echo "-------------- FC ------------------" && $FC --version 389527d8beaSJeremy L Thompson - echo "-------------- HIPCC ---------------" && $HIPCC --version 390527d8beaSJeremy L Thompson - echo "-------------- GCOV ----------------" && gcov --version 391527d8beaSJeremy L Thompson # Libraries for backends 392527d8beaSJeremy L Thompson # -- MAGMA from dev branch 393527d8beaSJeremy L Thompson - echo "-------------- MAGMA ---------------" 394527d8beaSJeremy L Thompson - export MAGMA_DIR=/projects/hipMAGMA && git -C $MAGMA_DIR -c safe.directory=$MAGMA_DIR describe 395527d8beaSJeremy L Thompson script: 396527d8beaSJeremy L Thompson - rm -f .SUCCESS 397527d8beaSJeremy L Thompson # libCEED 398f4239526SJed Brown - make configure ROCM_DIR=/opt/rocm-6.3.0 OPT='-O -march=native -ffp-contract=fast' 399527d8beaSJeremy L Thompson - BACKENDS_CPU=$(make info-backends-all | grep -o '/cpu[^ ]*' | tr '\n' ' ') && BACKENDS_GPU=$(make info-backends | grep -o '/gpu[^ ]*' | tr '\n' ' ') 400527d8beaSJeremy L Thompson - echo "-------------- libCEED -------------" && make info 401527d8beaSJeremy L Thompson - echo "-------------- BACKENDS_GPU --------" && echo $BACKENDS_GPU 402527d8beaSJeremy L Thompson - make clean 403527d8beaSJeremy L Thompson - make -j$NPROC_CPU 404527d8beaSJeremy L Thompson # Clang-tidy 405527d8beaSJeremy L Thompson - echo "-------------- clang-tidy ----------" && clang-tidy --version 406527d8beaSJeremy L Thompson - make clean 407527d8beaSJeremy L Thompson - TIDY_OPTS="-fix-errors" make -j$NPROC_CPU tidy && git diff --color=always --exit-code 408527d8beaSJeremy L Thompson # Report status 409527d8beaSJeremy L Thompson - touch .SUCCESS 410527d8beaSJeremy L Thompson 411527d8beaSJeremy L Thompson 41253928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 4131caccaa9SJeremy L Thompson# CPU + CUDA backends with CeedScalar == float (32 bit) 41453928bd0SJeremy L Thompson# ---------------------------------------------------------------------------------------- 41580a9ef05SNatalie Beamsnoether-float: 4161e31b501SJeremy L Thompson stage: test:gpu-and-float 41780a9ef05SNatalie Beams tags: 4181e31b501SJeremy L Thompson - cpu 4191caccaa9SJeremy L Thompson - cuda 42080a9ef05SNatalie Beams interruptible: true 4211e31b501SJeremy L Thompson before_script: 4225221680fSJeremy L Thompson # Environment 4231caccaa9SJeremy L Thompson - export COVERAGE=1 CC=gcc CXX=g++ FC= NVCC=nvcc 42419868e18SZach Atkins - export NPROC_POOL=8 42580a9ef05SNatalie Beams - echo "-------------- nproc ---------------" && NPROC_CPU=$(nproc) && NPROC_GPU=$(($(nproc)<8?$(nproc):8)) && echo "NPROC_CPU" $NPROC_CPU && echo "NPROC_GPU" $NPROC_GPU 42680a9ef05SNatalie Beams - echo "-------------- CC ------------------" && $CC --version 42780a9ef05SNatalie Beams - echo "-------------- CXX -----------------" && $CXX --version 4281caccaa9SJeremy L Thompson - echo "-------------- NVCC ----------------" && $NVCC --version 42980a9ef05SNatalie Beams - echo "-------------- GCOV ----------------" && gcov --version 43080a9ef05SNatalie Beams # Libraries for backends 4311caccaa9SJeremy L Thompson# ROCm tests currently disabled 43280a9ef05SNatalie Beams# -- MAGMA from dev branch 4331caccaa9SJeremy L Thompson# - echo "-------------- MAGMA ---------------" 4341caccaa9SJeremy L Thompson# - export MAGMA_DIR=/projects/hipMAGMA && git -C $MAGMA_DIR -c safe.directory=$MAGMA_DIR describe 435ed66640aSJeremy L Thompson # -- LIBXSMM 19 March 2025 436ed66640aSJeremy L Thompson - cd .. && export XSMM_HASH=ba9d6bc69c421c10f0597d582ea1ace6a6126308 && { [[ -d libxsmm-$XSMM_HASH ]] || { curl -L https://github.com/libxsmm/libxsmm/archive/$XSMM_HASH.tar.gz -o xsmm.tar.gz && tar zvxf xsmm.tar.gz && rm xsmm.tar.gz && make -C libxsmm-$XSMM_HASH -j$(nproc); }; } && export XSMM_DIR=$PWD/libxsmm-$XSMM_HASH && cd libCEED 43768c150f8SJed Brown - echo "-------------- LIBXSMM -------------" && basename $XSMM_DIR 4381e31b501SJeremy L Thompson script: 4391e31b501SJeremy L Thompson - rm -f .SUCCESS 44080a9ef05SNatalie Beams # libCEED 4411e31b501SJeremy L Thompson # Change to single precision 442c9c2c079SJeremy L Thompson - sed -i 's/ceed-f64/ceed-f32/1' include/ceed/types.h 44380a9ef05SNatalie Beams # Build libCEED 4447ad93db1SJed Brown - make configure OPT='-O -march=native -ffp-contract=fast' CUDA_DIR=/usr/local/cuda-12.9 4451b16049aSZach Atkins - BACKENDS_CPU=$(make info-backends-all | grep -o '/cpu[^ ]*' | tr '\n' ' ') && BACKENDS_GPU=$(make info-backends | grep -o '/gpu[^ ]*' | tr '\n' ' ') 44680a9ef05SNatalie Beams - echo "-------------- libCEED -------------" && make info 4475221680fSJeremy L Thompson - echo "-------------- BACKENDS_CPU --------" && echo $BACKENDS_CPU 4485221680fSJeremy L Thompson - echo "-------------- BACKENDS_GPU --------" && echo $BACKENDS_GPU 4493bcf805fSJeremy L Thompson - make clean 45080a9ef05SNatalie Beams - make -j$NPROC_CPU 45180a9ef05SNatalie Beams # -- libCEED only tests 45280a9ef05SNatalie Beams - echo "-------------- core tests ----------" 45380a9ef05SNatalie Beams - echo '[{"subject":"/","metrics":[{"name":"Transfer Size (KB)","value":"19.5","desiredSize":"smaller"},{"name":"Speed Index","value":0,"desiredSize":"smaller"},{"name":"Total Score","value":92,"desiredSize":"larger"},{"name":"Requests","value":4,"desiredSize":"smaller"}]}]' > performance.json 45480a9ef05SNatalie Beams # Note: PETSC_DIR is set by default in GitLab runner env, unsetting to isolate core tests 45580a9ef05SNatalie Beams - export PETSC_DIR= PETSC_ARCH= 45619868e18SZach Atkins - make -k -j$((NPROC_CPU / NPROC_POOL)) BACKENDS="$BACKENDS_CPU" JUNIT_BATCH="float-cpu" junit realsearch=% 45719868e18SZach Atkins - export NPROC_POOL=4 4581caccaa9SJeremy L Thompson - make -k -j$((NPROC_GPU / NPROC_POOL)) BACKENDS="$BACKENDS_GPU" JUNIT_BATCH="float-cuda" junit realsearch=% 45980a9ef05SNatalie Beams # Report status 46080a9ef05SNatalie Beams - echo "SUCCESS" > .job_status 46180a9ef05SNatalie Beams after_script: 46280a9ef05SNatalie Beams - | 46380a9ef05SNatalie Beams if [ $(cat .job_status) == "SUCCESS" ]; then 464fe470f9dSJeremy L Thompson lcov --directory . --capture --output-file coverage.info --ignore-errors source,mismatch; 46580a9ef05SNatalie Beams bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F interface; 46680a9ef05SNatalie Beams bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F gallery; 46780a9ef05SNatalie Beams bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F backends; 46880a9ef05SNatalie Beams bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F tests; 46980a9ef05SNatalie Beams bash <(curl -s https://codecov.io/bash) -f coverage.info -t ${CODECOV_ACCESS_TOKEN} -F examples; 47080a9ef05SNatalie Beams fi 471c9c2c079SJeremy L Thompson - sed -i 's/ceed-f32/ceed-f64/1' include/ceed/types.h 47280a9ef05SNatalie Beams artifacts: 47380a9ef05SNatalie Beams paths: 47480a9ef05SNatalie Beams - build/*.junit 47580a9ef05SNatalie Beams reports: 47680a9ef05SNatalie Beams junit: build/*.junit 47780a9ef05SNatalie Beams performance: performance.json 478