1# 2# stage-1 take only a few minutes; they do not run the full test suite or external packages. 3# 4# stage-2 runs on MCS systems and may take 10 to 15 minutes. They run the full test suite but with limited mixture of external packages 5# 6# stage-3 runs on MCS systems and may take an hour or more. They run the full test suite and heavily test external packages, utilize valgrind etc 7# 8# The stage-(n) tests are only started if all of the stage-(n-1) tests run without error 9# You can limit the testing by using the variable STAGE with value 1 or 2 10# 11 12stages: 13 - stage-1 14 - stage-2 15 - stage-3 16 - stage-4 17variables: 18 GIT_STRATEGY: fetch 19 GIT_CLEAN_FLAGS: -ffdxq 20 TIMEOUT: 450 21 22# 23# The most basic template that most tests will expand upon 24# 25 26.test-basic: 27 interruptible: true 28 only: 29 refs: 30# Set with CI/CD Shedules - New Schedule 31 - schedules 32 - api 33# Set with CI/CD Pipelines - Run Pipeline 34 - web 35 - merge_requests 36 dependencies: [] 37 38.test: 39 extends: .test-basic 40 except: 41 variables: 42 # Skip if the docs-only label is attached to a merge request 43 - $CI_MERGE_REQUEST_LABELS =~ /(^|,)docs-only($|,)/ 44 - $PETSC_CI_SCHEDULED =~ /yes/ 45 46check-ci-settings: 47 extends: .test-basic 48 stage: .pre 49 tags: 50 - gce-stage1 51 script: 52 - lib/petsc/bin/maint/check-ci-settings.sh 53 54# 55# This provides the basic order of operations and options template for cloud based stage 1 tests. 56# Not all test-short need to follow this template but most will. 57# 58 59.stage-1: 60 extends: .test 61 stage: stage-1 62 tags: 63 - gce-u22-stage1 64 before_script: 65 - date 66 - hostname 67 - grep PRETTY_NAME /etc/os-release 68 - nproc 69 - lscpu 70 - ccache --zero-stats 71 script: 72 - if [ ! -z ${LOAD_MODULES+x} ]; then module --trace load ${LOAD_MODULES}; module list; fi 73 - if [ ! -z ${INIT_SCRIPT+x} ]; then echo "sourcing ${INIT_SCRIPT}"; source ${INIT_SCRIPT}; fi 74 - printf "PATH:$PATH\n" 75 - printf "PYTHONPATH:$PYTHONPATH\n" 76 - printf "CONFIG_OPTS:${CONFIG_OPTS}\n" 77 - printf "PETSC_OPTIONS:$PETSC_OPTIONS\n" 78 - if [ ! -z ${CI_MERGE_REQUEST_SOURCE_BRANCH_NAME+x} ]; then printf "CI_MERGE_REQUEST_SOURCE_BRANCH_NAME:$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME\n" ;fi 79 - ${PYTHON} ./configure --with-debugging=0 COPTFLAGS='-O -march=native' CXXOPTFLAGS='-O -march=native' FOPTFLAGS='-O -march=native' ${CONFIG_OPTS} 80 - make CFLAGS="${MAKE_CFLAGS}" CXXFLAGS="${MAKE_CXXFLAGS}" FFLAGS="${MAKE_FFLAGS}" 81 - if [ ! -z ${ENABLE_CHECK+x} ]; then make CFLAGS="${MAKE_CFLAGS}" CXXFLAGS="${MAKE_CXXFLAGS}" FFLAGS="${MAKE_FFLAGS}" check; fi 82 - make CFLAGS="${MAKE_TEST_CFLAGS}" CXXFLAGS="${MAKE_TEST_CXXFLAGS}" FFLAGS="${MAKE_TEST_FFLAGS}" allgtests-tap gmakesearch="${TEST_SEARCH}" TIMEOUT=${TIMEOUT} 83 variables: 84 PYTHON: python3 85 MAKE_CFLAGS: -Werror 86 MAKE_CXXFLAGS: -Werror -Wzero-as-null-pointer-constant 87 MAKE_FFLAGS: -Werror 88 MAKE_TEST_CFLAGS: -Werror 89 MAKE_TEST_CXXFLAGS: -Werror 90 MAKE_TEST_FFLAGS: -Werror 91 after_script: 92 - date 93 - ccache --show-stats 94 artifacts: 95 reports: 96 junit: arch-*/tests/testresults.xml 97 name: "$CI_JOB_NAME" 98 when: always 99 paths: 100 - arch-*/lib/petsc/conf/*.log 101 - arch-*/lib/pkgconfig/petsc.pc 102 - arch-*/tests/testresults.xml 103 - arch-*/tests/test_*_tap.log 104 - arch-*/tests/test_*_err.log 105 expire_in: 4 days 106 107# 108# The following tests run on the cloud as part of stage-1. 109# 110 111ompi-cuda: 112 extends: .stage-1 113 tags: 114 - cuda-stage1 115 variables: 116 CONFIG_OPTS: --with-mpi-dir=/nfs/gce/software/custom/linux-ubuntu22.04-x86_64/spack/opt/spack/linux-ubuntu22.04-x86_64/gcc-11.3.0/openmpi-4.1.3-qrpnszy --with-cuda=1 --with-fc=0 117 TEST_SEARCH: snes_tutorials-ex19_cuda% 118 ENABLE_CHECK: 1 119 MAKE_CXXFLAGS: -Werror 120 121mpich-cxx-py3: 122 extends: .stage-1 123 variables: 124 CONFIG_OPTS: --with-clanguage=cxx --with-fc=0 CXXFLAGS=-std=c++11 --with-strict-petscerrorcode 125 TEST_SEARCH: snes_tutorials-ex48% 126 LOAD_MODULES: gcc/12.1.0 mpich/4.1-gcc-12.1.0 127 128uni-complex-float-int64: 129 extends: .stage-1 130 variables: 131 CONFIG_OPTS: --with-mpi=0 --with-scalar-type=complex --with-precision=single --with-64-bit-indices 132 TEST_SEARCH: ts_tutorials-ex11_adv_2d_quad_% 133 LOAD_MODULES: gcc/12.1.0 mpich/4.1-gcc-12.1.0 134 135c99-mlib-static-py: 136 extends: .stage-1 137 variables: 138 CONFIG_OPTS: --with-single-library=0 --with-shared-libraries=0 --with-strict-petscerrorcode CFLAGS=-std=c99 FFLAGS= CXXFLAGS= 139 ENABLE_CHECK: 1 140 TEST_SEARCH: snes_tutorials-ex19% snes_tutorials-ex5f90t% 141 MAKE_TEST_FFLAGS: -Werror -std=f2008 142 LOAD_MODULES: gcc/12.1.0 mpich/4.1-gcc-12.1.0 143 144petsc4py-install: 145 extends: .stage-2 146 tags: 147 - gce-stage2 148 variables: 149 PYTHON: python3 150 T_PREFIX: petsc-install 151 T_DESTDIR: petsc-destdir 152 T_PETSC4PY: src/binding/petsc4py 153 T_VALIDATE_CMD: lib/petsc/bin/maint/validate-petsc4py.sh 154 script: 155 - printf "PATH:$PATH\n" 156 - mkdir hide 157 - if [ ! -z ${CI_MERGE_REQUEST_SOURCE_BRANCH_NAME+x} ]; then printf "CI_MERGE_REQUEST_SOURCE_BRANCH_NAME:$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME\n" ;fi 158 - ${PYTHON} ./configure --prefix="${PWD}/${T_PREFIX}" --with-petsc4py=1 --with-debugging=0 159 - make CFLAGS=-Werror CXXFLAGS="-Werror -Wzero-as-null-pointer-constant" FFLAGS=-Werror 160 - printf "====== Test A. Install into staging directory then into prefix directory (mimics distro package recipe) =====\n" 161 - make install DESTDIR="${PWD}/${T_DESTDIR}" 162 - test "$(find ${PWD}/${T_PREFIX} -mindepth 1 | wc -l)" -eq 0 163 - test "$(find ${PWD}/${T_DESTDIR} -mindepth 1 | wc -l)" -gt 0 164 - (cd "${PWD}/${T_DESTDIR}" && find * -exec install -v -D "{}" "/{}" \; ) 165 - mv arch-* hide/ && PETSC_DIR="${PWD}/${T_PREFIX}" ${T_VALIDATE_CMD} && mv hide/arch-* ./ 166 - rm -r "${PWD}/${T_PREFIX}" "${PWD}/${T_DESTDIR}" && mkdir "${PWD}/${T_PREFIX}" 167 - printf "====== Test B. Install directly into prefix directory =====\n" 168 - make install 169 - test "$(find ${PWD}/${T_PREFIX} -mindepth 1 | wc -l)" -gt 0 170 - mv arch-* hide/ && PETSC_DIR="${PWD}/${T_PREFIX}" ${T_VALIDATE_CMD} && mv hide/arch-* ./ 171 - rm -r "${PWD}/${T_PREFIX}"/*/petsc4py* 172 - printf "====== Test C. Install manually with setuptools =====\n" 173 - export PETSC_DIR="${PWD}/${T_PREFIX}" && (cd "${T_PETSC4PY}" && ${PYTHON} setup.py build) 174 - export PETSC_DIR="${PWD}/${T_PREFIX}" P="${PWD}" && (cd "${T_PETSC4PY}" && ${PYTHON} setup.py install --install-lib="${P}/${T_PREFIX}/lib") 175 - mv arch-* hide/ && PETSC_DIR="${PWD}/${T_PREFIX}" ${T_VALIDATE_CMD} && mv hide/arch-* ./ 176 - rm -r "${PWD}/${T_PREFIX}"/*/petsc4py* 177 - printf "====== Test D. Install manually with setuptools with staging =====\n" 178 - export PETSC_DIR="${PWD}/${T_PREFIX}" P="${PWD}" && (cd "${T_PETSC4PY}" && ${PYTHON} setup.py install --root="${P}/${T_DESTDIR}" --install-lib="${P}/${T_PREFIX}/lib") 179 - (cd "${PWD}/${T_DESTDIR}" && find * -exec install -v -D "{}" "/{}" \; ) 180 - mv arch-* hide/ && PETSC_DIR="${PWD}/${T_PREFIX}" ${T_VALIDATE_CMD} && mv hide/arch-* ./ 181 182petsc4py-pip: 183 extends: .stage-2 184 tags: 185 - gce-stage2 186 variables: 187 PETSC_CONFIGURE_OPTIONS: --with-mpi=0 --with-fc=0 188 CFLAGS: -O0 189 script: 190 - python3 -m venv pip-builds 191 - source pip-builds/bin/activate 192 - python3 -m pip install --upgrade pip 193 - python3 -m pip install . 194 - python3 -m pip install src/binding/petsc4py 195 - python3 -m petsc4py 196 197checksource: 198 extends: .test-basic 199 stage: .pre 200 tags: 201 - gce-u22-stage1 202 script: 203 - python3 ./configure --with-mpi=0 --with-fc=0 --with-cxx=0 204 - vermin --version 205 - make vermin 206 - PATH=/nfs/gce/projects/petsc/soft/u22.04/spack/opt/spack/linux-ubuntu22.04-ivybridge/gcc-11.2.0/llvm-15.0.0-m7mrrtynenjytkmiib2moeqk6kfcifmv/bin:$PATH make checkclangformat SHELL=bash 207 - make checkbadSource SHELL=bash 208 - make checkbadFileChange SHELL=bash 209 - make -f gmakefile check_output SHELL=bash 210 - make check_petsc4py_rst 211 artifacts: 212 name: "$CI_JOB_NAME" 213 when: always 214 paths: 215 - arch-*/lib/petsc/conf/*.patch 216 - arch-*/lib/petsc/conf/*.log 217 expire_in: 4 days 218 219pause-for-approval: 220 extends: .test 221 stage: .pre 222 tags: 223 - gce-stage1 224 only: 225 refs: 226 - merge_requests 227 variables: 228 - $CI_MERGE_REQUEST_EVENT_TYPE == "merged_result" 229 - $CI_MERGE_REQUEST_EVENT_TYPE == "detached" 230 script: 231 - echo "pause-for-approval has no script to run" 232 variables: 233 GIT_STRATEGY: none 234 when: manual 235 allow_failure: false 236 237# 238# Basic template for code coverage generation. Tests should additionally inherit from the more 239# specialized OS-specific versions instead of this one. 240# 241 242.coverage-generate: 243 variables: 244 RUN_GCOV: 1 245 RUN_GCOV_OPTIONS: --decisions 246 247.coverage-disable: 248 variables: 249 RUN_GCOV: 0 250 251# 252# This provides the basic order of operations and options template for stage-2,3 tests. 253# Not all stage-2,3 need to follow this template, but most will. 254# 255.stage-23: 256 extends: 257 - .test 258 - .coverage-generate 259 script: 260 - if [ ! -z ${LOAD_MODULES+x} ]; then module --trace load ${LOAD_MODULES}; module list; fi 261 - if [ ! -z ${GCOV_MODULES+x} ]; then module --trace load ${GCOV_MODULES}; module list; fi 262 - if [ ! -z ${INIT_SCRIPT+x} ]; then echo "sourcing ${INIT_SCRIPT}"; source ${INIT_SCRIPT}; fi 263 - if [ "${RUN_GCOV}" == 1 ]; then 264 printf "RUN_GCOV_OPTIONS:$RUN_GCOV_OPTIONS\n"; 265 gcovr --version; 266 fi 267 - if [ -d ${HOME}/petsc-hash-pkgs/ ]; then find ${HOME}/petsc-hash-pkgs/ -maxdepth 1 -mindepth 1 -type d -mtime +25 -exec rm -rf {} \; ; fi 268 - printf "PATH:$PATH\n" 269 - printf "PYTHONPATH:$PYTHONPATH\n" 270 - printf "PETSC_OPTIONS:$PETSC_OPTIONS\n" 271 - if [ ! -z ${CI_MERGE_REQUEST_SOURCE_BRANCH_NAME+x} ]; then printf "CI_MERGE_REQUEST_SOURCE_BRANCH_NAME:$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME\n" ;fi 272 - printf "./config/examples/${TEST_ARCH}.py\n" 273 - cat ./config/examples/${TEST_ARCH}.py 274 - ./config/examples/${TEST_ARCH}.py || if [ -f naglicenseproblem ]; then exit 126; else exit 1; fi 275 - make CFLAGS="${MAKE_CFLAGS}" CXXFLAGS="${MAKE_CXXFLAGS}" FFLAGS="${MAKE_FFLAGS}" || if [ -f naglicenseproblem ]; then exit 126; else exit 1; fi 276 - make CFLAGS="${MAKE_CFLAGS}" CXXFLAGS="${MAKE_CXXFLAGS}" FFLAGS="${MAKE_FFLAGS}" check || if [ -f naglicenseproblem ]; then exit 126; else exit 1; fi 277 - make updatedatafiles 278 - if [ -z ${DISABLE_PETSC4PY_TESTS+x} ]; then if [ -z ${ENABLE_PETSC4PY_LDPRELOAD+x} ]; then echo "NOT using LD_PRELOAD"; make petsc4pytest; else echo "using LD_PRELOAD"; LD_PRELOAD=${PWD}/${TEST_ARCH}/lib/libpetsc.so make petsc4pytest; fi; fi 279 - if [ -z ${DISABLE_TESTS+x} ]; then make cleantest && make CFLAGS="${MAKE_CFLAGS}" CXXFLAGS="${MAKE_CXXFLAGS}" FFLAGS="${MAKE_FFLAGS}" allgtests-tap TIMEOUT=${TIMEOUT} ${TEST_OPTS} || if [ -f naglicenseproblem ]; then exit 126; else exit 1; fi; fi 280 - if [ "${RUN_GCOV}" == 1 ]; then make gcov PETSC_GCOV_OPTIONS="${RUN_GCOV_OPTIONS}"; fi 281 artifacts: 282 reports: 283 junit: arch-*/tests/testresults.xml 284 name: "$CI_JOB_NAME" 285 when: always 286 paths: 287 - arch-*/lib/petsc/conf/*.log 288 - arch-*/lib/pkgconfig/petsc.pc 289 - arch-*/tests/testresults.xml 290 - arch-*/tests/test_arch-*_tap.log 291 - arch-*/tests/test_arch-*_err.log 292 - arch-*/arch-*-gcovr-report.json.tar.bz2 293 expire_in: 4 days 294 variables: 295 OPENBLAS_NUM_THREADS: 1 296 297.stage-2: 298 extends: .stage-23 299 stage: stage-2 300 301.stage-3: 302 extends: .stage-23 303 stage: stage-3 304 305# 306# The following provide templates for various OSes for pre/post info 307# 308 309.linux_test_noflags: 310 before_script: 311 - date 312 - hostname 313 - grep PRETTY_NAME /etc/os-release 314 - nproc 315 - lscpu 316 - ccache --zero-stats 317 after_script: 318 - date 319 - ccache --show-stats 320 321.linux_test_nofflags: 322 extends: .linux_test_noflags 323 variables: 324 MAKE_CFLAGS: -Werror 325 MAKE_CXXFLAGS: -Werror 326 327.linux_test: 328 extends: .linux_test_noflags 329 variables: 330 MAKE_CFLAGS: -Werror 331 MAKE_CXXFLAGS: -Werror 332 MAKE_FFLAGS: -Werror 333 334.freebsd_test: 335 extends: 336 - .coverage-disable 337 variables: 338 MAKE_CFLAGS: -Werror 339 MAKE_CXXFLAGS: -Werror 340 MAKE_FFLAGS: -Werror 341 before_script: 342 - date 343 - hostname 344 - freebsd-version 345 - echo $(sysctl -n hw.ncpu) 346 - ccache --zero-stats 347 after_script: 348 - date 349 - ccache --show-stats 350 351.osx_test: 352 variables: 353 MAKE_CFLAGS: -Werror 354 MAKE_CXXFLAGS: -Werror 355 MAKE_FFLAGS: -Werror 356 before_script: 357 - date 358 - hostname 359 - sw_vers -productVersion 360 - echo $(sysctl -n hw.ncpu) 361 - ccache --zero-stats 362 after_script: 363 - date 364 - ccache --show-stats 365 366.opensolaris_test: 367 extends: 368 - .coverage-disable 369 before_script: 370 - date 371 - hostname 372 - uname -a 373 - nproc 374 - isainfo -x 375 after_script: 376 - date 377 378.mswin_test: 379 extends: 380 - .coverage-disable 381 before_script: 382 - date 383 - hostname 384 - uname -a 385 - nproc 386 after_script: 387 - date 388 389# 390# The following tests run as part of stage-2. 391# 392# The tags variable used in the tests below connects the particular test with the runners 393# listed on the left hand side of https://gitlab.com/petsc/petsc/-/settings/ci_cd. 394# For example the test 'linux-sycl-double' any runner that has the tags 'gce-u22-stage3, linux-fast' 395# (in a blue box beneath it) 396# 397 398osx-m1: 399 extends: 400 - .stage-3 401 - .osx_test 402 - .coverage-disable 403 tags: 404 - os:macos-m1 405 variables: 406 TEST_ARCH: arch-ci-osx-m1 407 PETSC_OPTIONS: -check_pointer_intensity 0 -error_output_stdout -nox -nox_warning -malloc_dump 408 INIT_SCRIPT: /Volumes/Scratch/svcpetsc/soft/py3venv/cython3setup.sh 409 410freebsd-cxx-cmplx-64idx-dbg: 411 extends: 412 - .stage-2 413 - .freebsd_test 414 tags: 415 - os:fbsd 416 variables: 417 TEST_ARCH: arch-ci-freebsd-cxx-cmplx-64idx-dbg 418 419freebsd-c-single-opt: 420 extends: 421 - .stage-2 422 - .freebsd_test 423 tags: 424 - os:fbsd 425 variables: 426 TEST_ARCH: arch-ci-freebsd-c-single-opt 427 428mswin-opt-impi: 429 extends: 430 - .stage-3 431 - .mswin_test 432 tags: 433 - mswin-stage3 434 variables: 435 TEST_ARCH: arch-ci-mswin-opt-impi 436 TEST_OPTS: search='ksp_ksp_tests*' 437 438linux-gcc-quad-64idx-dbg: 439 extends: 440 - .stage-2 441 - .linux_test 442 tags: 443 - gce-stage2 444 variables: 445 TEST_ARCH: arch-ci-linux-gcc-quad-64idx-dbg 446 447linux-gcc-pkgs-opt: 448 extends: 449 - .stage-2 450 - .linux_test 451 tags: 452 - gce-stage2 453 variables: 454 TEST_ARCH: arch-ci-linux-gcc-pkgs-opt 455 456linux-gcc-complex-opt-32bit: 457 extends: 458 - .stage-2 459 - .linux_test 460 tags: 461 - gce-stage2 462 variables: 463 TEST_ARCH: arch-ci-linux-gcc-complex-opt-32bit 464 465linux-emcc: 466 extends: 467 - .stage-2 468 - .linux_test 469 - .coverage-disable 470 tags: 471 - gce-stage2 472 variables: 473 TEST_ARCH: arch-ci-linux-emcc 474 INIT_SCRIPT: /nfs/gce/projects/petsc/soft/u22.04/emsdk/emsdk_env.sh 475 DISABLE_TESTS: 1 476 477# 478# The following tests run as part of stage-3. 479# 480 481freebsd-cxx-cmplx-pkgs-dbg: 482 extends: 483 - .stage-3 484 - .freebsd_test 485 tags: 486 - os:fbsd 487 variables: 488 TEST_ARCH: arch-ci-freebsd-cxx-cmplx-pkgs-dbg 489 490freebsd-cxx-pkgs-opt: 491 extends: 492 - .stage-3 493 - .freebsd_test 494 tags: 495 - os:fbsd 496 variables: 497 PETSC_OPTIONS: -vecscatter_mpi1 false -options_left false 498 TEST_ARCH: arch-ci-freebsd-cxx-pkgs-opt 499 500freebsd-pkgs-opt: 501 extends: 502 - .stage-3 503 - .freebsd_test 504 tags: 505 - os:fbsd 506 variables: 507 TEST_ARCH: arch-ci-freebsd-pkgs-opt 508 509linux-hip-double: 510 extends: 511 - .stage-3 512 - .linux_test_noflags 513 - .coverage-disable 514 tags: 515 - gpu:amd, os:linux 516 variables: 517 TEST_ARCH: arch-ci-linux-hip-double 518 INIT_SCRIPT: /home/users/balay/bin/instinct-mod-init.sh 519 520linux-sycl-double: 521 extends: 522 - .stage-3 523 - .linux_test_nofflags 524 - .coverage-disable 525 tags: 526 - gce-u22-stage3, linux-fast 527 variables: 528 TEST_ARCH: arch-ci-linux-sycl-double 529 LOAD_MODULES: intel-oneapi-compilers/2022.2.1 intel-oneapi-mpi/2021.5.1 530 TEST_OPTS: query=requires queryval=kokkos_kernels 531 MAKE_CFLAGS: -Wno-expected-file-type -Werror 532 533linux-cuda-pkgs: 534 extends: 535 - .stage-3 536 - .linux_test 537 tags: 538 - cuda-stage3 539 variables: 540 TEST_ARCH: arch-ci-linux-cuda-pkgs 541 # run all tests that: 542 # 1. require cuda, OR 543 # 2. require device, OR 544 # 3. require kokkos[_kernels], AND lives in the vec subdirectory 545 # 546 # need to use the alternate OR spelling since '|' is interpreted as a pipe by the 547 # shell, and I could not manage to escape it enough times... 548 TEST_OPTS: -j3 queryval='cuda,device,kokkos*,vec*' query='requires,requires,requires%OR%name' 549 550linux-cuda112-omp: 551 extends: 552 - .stage-3 553 - .linux_test 554 - .coverage-disable 555 tags: 556 - cuda-stage3 557 variables: 558 TEST_ARCH: arch-ci-linux-cuda112-omp 559 TEST_OPTS: -j4 query=requires queryval=kokkos_kernels 560 LOAD_MODULES: cuda/11.2.2 u-gcc-9/9.4.0 561 OMP_PROC_BIND: "false" 562 OMP_NUM_THREADS: 1 563 564linux-cuda-cmplx: 565 extends: 566 - .stage-3 567 - .linux_test 568 tags: 569 - cuda-stage3 570 variables: 571 TEST_ARCH: arch-ci-linux-cuda-cmplx 572 573linux-cuda-double-64idx: 574 extends: 575 - .stage-3 576 - .linux_test 577 tags: 578 - cuda-stage3 579 variables: 580 TEST_ARCH: arch-ci-linux-cuda-double-64idx 581 TEST_OPTS: -j15 query=requires queryval=cuda 582 583linux-cuda-single-cxx: 584 extends: 585 - .stage-3 586 - .linux_test_noflags 587 - .coverage-disable 588 tags: 589 - cuda-stage3 590 variables: 591 TEST_ARCH: arch-ci-linux-cuda-single-cxx 592 MODULEPATH: /nfs/gce/projects/petsc/soft/u22.04/spack-2023-02-02/share/spack/modules/linux-ubuntu22.04-ivybridge 593 LOAD_MODULES: nvhpc-22.11-gcc-11.3.0-vmvmbrx 594 TEST_OPTS: -j15 query=requires queryval=cuda 595 596linux-cuda-uni-pkgs: 597 extends: 598 - .stage-3 599 - .linux_test 600 tags: 601 - cuda-stage3 602 variables: 603 TEST_ARCH: arch-ci-linux-cuda-uni-pkgs 604 TEST_OPTS: -j20 query=requires queryval=cuda 605 606linux-clang-cuda: 607 extends: 608 - .stage-3 609 - .linux_test 610 - .coverage-disable 611 tags: 612 - cuda-stage3 613 variables: 614 TEST_ARCH: arch-ci-linux-clang-cuda 615 TEST_OPTS: -j 1 queryval='cuda*,snes*' query='requires%OR%name' 616 MODULEPATH: /nfs/gce/projects/petsc/soft/u22.04/spack-2023-02-02/share/spack/modules/linux-ubuntu22.04-ivybridge 617 LOAD_MODULES: llvm-15.0.7-gcc-11.3.0-pjldtxf cuda-11.5.2-gcc-11.3.0-jkoottx gcc-11.3.0-gcc-11.3.0-pgrvke5 618 619linux-viennacl: 620 extends: 621 - .stage-3 622 - .linux_test 623 tags: 624 - cuda-stage3 625 variables: 626 TEST_ARCH: arch-ci-linux-viennacl 627 MAKE_CXXFLAGS: -Werror -Wno-ignored-attributes 628 TEST_OPTS: -j20 query=requires queryval=viennacl 629 630linux-without-fc: 631 extends: 632 - .stage-3 633 - .linux_test 634 tags: 635 - gce-u22-stage3 636 variables: 637 TEST_ARCH: arch-ci-linux-without-fc 638 639linux-cmplx-single: 640 extends: 641 - .stage-3 642 - .linux_test 643 - .coverage-disable 644 tags: 645 - name:si 646 variables: 647 FLEXIBLAS: netlib 648 TEST_ARCH: arch-ci-linux-cmplx-single 649 650linux-gcc-cxx-avx2: 651 extends: 652 - .stage-3 653 - .linux_test 654 tags: 655 - name:petsc-knl-01 656 variables: 657 TEST_ARCH: arch-ci-linux-gcc-cxx-avx2 658 659linux-clang-avx: 660 extends: 661 - .stage-3 662 - .linux_test 663 tags: 664 - name:petsc-knl-01 665 variables: 666 TEST_ARCH: arch-ci-linux-clang-avx 667 668linux-knl: 669 extends: 670 - .stage-3 671 - .linux_test 672 - .coverage-disable 673 tags: 674 - name:petsc-knl-01 675 variables: 676 MAKE_FFLAGS: -warn errors 677 TEST_ARCH: arch-ci-linux-knl 678 LOAD_MODULES: intel-oneapi-compilers/2022.0.2 intel-oneapi-mkl/2022.0.2 intel-oneapi-mpi/2021.5.1 679 680linux-intel-mkl-single: 681 extends: 682 - .stage-3 683 - .linux_test_nofflags 684 - .coverage-disable 685 tags: 686 - name:petsc-knl-01 687 variables: 688 TEST_ARCH: arch-ci-linux-intel-mkl-single 689 LOAD_MODULES: intel-oneapi-compilers/2022.0.2 intel-oneapi-mkl/2022.0.2 intel-oneapi-mpi/2021.5.1 690 691linux-cxx-cmplx-pkgs-64idx: 692 extends: 693 - .stage-3 694 - .linux_test 695 tags: 696 - gce-u22-stage3 697 variables: 698 TEST_ARCH: arch-ci-linux-cxx-cmplx-pkgs-64idx 699 700# Set env vars for 'Kokkos + OpenMP' tests, so that they won't give warnings 701linux-pkgs-dbg-ftn-interfaces: 702 extends: 703 - .stage-3 704 - .linux_test 705 - .coverage-disable 706 tags: 707 - gce-u22-stage3 708 variables: 709 TEST_ARCH: arch-ci-linux-pkgs-dbg-ftn-interfaces 710 OMP_PROC_BIND: "false" 711 OMP_NUM_THREADS: 4 712 713linux-pkgs-cxx-mlib: 714 extends: 715 - .stage-3 716 - .linux_test 717 tags: 718 - gce-u22-stage3 719 variables: 720 TEST_ARCH: arch-ci-linux-pkgs-cxx-mlib 721 except: 722 variables: 723 - $PETSC_CI_SCHEDULED =~ /yes/ 724 725linux-pkgs-valgrind: 726 extends: 727 - .stage-3 728 - .linux_test 729 tags: 730 - gce-valgrind 731 variables: 732 TEST_ARCH: arch-ci-linux-pkgs-valgrind 733 TIMEOUT: 7200 734 735linux-pkgs-opt: 736 extends: 737 - .stage-3 738 - .linux_test 739 - .coverage-disable 740 tags: 741 - gce-u22-stage3, linux-fast 742 variables: 743 TEST_ARCH: arch-ci-linux-pkgs-opt 744 LOAD_MODULES: gcc/12.1.0 745 MAKE_CXXFLAGS: -Wno-deprecated-declarations -Werror 746 747linux-pkgs-dbg: 748 extends: 749 - .stage-3 750 - .linux_test 751 tags: 752 - gce-u22-stage3, linux-gcov 753 variables: 754 TEST_ARCH: arch-ci-linux-pkgs-dbg 755 756linux-matlab-ilp64: 757 extends: 758 - .stage-3 759 - .linux_test 760 tags: 761 - gce-u22-stage3, linux-gcov 762 variables: 763 TEST_ARCH: arch-ci-linux-matlab-ilp64 764 LOAD_MODULES: gcc/9.4.0 matlab/R2022a 765 allow_failure: true 766 767linux-pgi: 768 extends: 769 - .stage-3 770 - .linux_test_noflags 771 - .coverage-disable 772 tags: 773 - gce-u22-stage3, linux-mcpu 774 variables: 775 TEST_ARCH: arch-ci-linux-pgi 776 LOAD_MODULES: nvhpc/22.3 777 778# If the Nag license server fails then ${PETSC_DIR}/naglicenseproblem is created and the job is marked as failed but allow_failure 779linux-nagfor: 780 extends: 781 - .stage-3 782 - .linux_test_nofflags 783 tags: 784 - gce-stage2, linux-mcpu 785 variables: 786 LOAD_MODULES: nag/6.1 787 TEST_ARCH: arch-ci-linux-nagfor 788 allow_failure: 789 exit_codes: 126 790 791linux-intel-cmplx: 792 extends: 793 - .stage-3 794 - .linux_test_nofflags 795 - .coverage-disable 796 tags: 797 - gce-u22-stage3 798 variables: 799 TEST_ARCH: arch-ci-linux-intel-cmplx 800 LOAD_MODULES: intel-oneapi-compilers/2023.0.0 intel-oneapi-mkl/2022.0.2 801 802linux-xsdk-dbg: 803 extends: 804 - .stage-3 805 - .linux_test 806 tags: 807 - gce-u22-stage3 808 variables: 809 TEST_ARCH: arch-ci-linux-xsdk-dbg 810 LOAD_MODULES: gcc/12.1.0 811 812linux-analyzer: 813 extends: 814 - .stage-3 815 - .linux_test 816 - .coverage-disable 817 tags: 818 - gce-u22-stage2 819 script: 820 - printf "PATH:$PATH\n" 821 - printf "PYTHONPATH:$PYTHONPATH\n" 822 - printf "PETSC_OPTIONS:$PETSC_OPTIONS\n" 823 - if [ ! -z ${CI_MERGE_REQUEST_SOURCE_BRANCH_NAME+x} ]; then printf "CI_MERGE_REQUEST_SOURCE_BRANCH_NAME:$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME\n" ;fi 824 - printf "./config/examples/${TEST_ARCH}.py\n" 825 - cat ./config/examples/${TEST_ARCH}.py 826 - ./config/examples/${TEST_ARCH}.py 827 - make LINTER_OPTIONS="${LINTER_OPTIONS}" test-lint 828 - make LINTER_OPTIONS="${LINTER_OPTIONS} -fdoc-* no" lint 829 variables: 830 TEST_ARCH: arch-ci-linux-analyzer 831 LINTER_OPTIONS: "--PETSC_ARCH=${TEST_ARCH} --clang_lib=`llvm-config-14 --libdir`/libclang.so.1 --verbose --werror" 832 artifacts: 833 paths: 834 - arch-*/lib/petsc/conf/*.log 835 - ./petscLintPatches/*.patch 836 expire_in: 4 days 837 except: 838 variables: 839 - $PETSC_CI_SCHEDULED =~ /yes/ 840 841linux-intel: 842 extends: 843 - .stage-3 844 - .linux_test_nofflags 845 - .coverage-disable 846 tags: 847 - gce-u22-stage3 848 variables: 849 TEST_ARCH: arch-ci-linux-intel 850 LOAD_MODULES: intel-oneapi-compilers/2023.0.0 intel-oneapi-mkl/2022.0.2 851 852linux-opt-misc: 853 extends: 854 - .stage-3 855 - .linux_test 856 tags: 857 - gce-u22-stage3, linux-fast 858 variables: 859 TEST_ARCH: arch-ci-linux-opt-misc 860 LOAD_MODULES: gcc/8.5.0 861 862linux-pkgs-64idx: 863 extends: 864 - .stage-3 865 - .linux_test 866 tags: 867 - gce-u22-stage3, linux-mcpu 868 variables: 869 TEST_ARCH: arch-ci-linux-pkgs-64idx 870 LOAD_MODULES: intel-oneapi-mkl/2022.0.2 871 872linux-64idx-i8: 873 extends: 874 - .stage-3 875 - .linux_test 876 tags: 877 - gce-u22-stage3, linux-mcpu 878 variables: 879 TEST_ARCH: arch-ci-linux-64idx-i8 880 881linux-gcc-ifc-cmplx: 882 extends: 883 - .stage-3 884 - .linux_test_nofflags 885 tags: 886 - gce-u22-stage3 887 variables: 888 TEST_ARCH: arch-ci-linux-gcc-ifc-cmplx 889 LOAD_MODULES: intel-oneapi-compilers/2022.2.1 890 891linux-opt-cxx-quad: 892 extends: 893 - .stage-3 894 - .linux_test 895 tags: 896 - gce-u22-stage3 897 variables: 898 TEST_ARCH: arch-ci-linux-opt-cxx-quad 899 900linux-ILP64: 901 extends: 902 - .stage-3 903 - .linux_test 904 tags: 905 - gce-u22-stage3 906 variables: 907 TEST_ARCH: arch-ci-linux-ILP64 908 LOAD_MODULES: gcc/8.5.0 mpich/2-1.5-gcc-8.5.0 909 MAKE_CFLAGS: -Wno-discarded-qualifiers -Werror 910 911linux-64idx-i8-uni: 912 extends: 913 - .stage-3 914 - .linux_test 915 tags: 916 - gce-u22-stage3, linux-mcpu 917 variables: 918 TEST_ARCH: arch-ci-linux-64idx-i8-uni 919 920mswin-intel-cxx-cmplx: 921 extends: 922 - .stage-3 923 - .mswin_test 924 tags: 925 - mswin-stage3 926 variables: 927 TEST_ARCH: arch-ci-mswin-intel-cxx-cmplx 928 929mswin-uni: 930 extends: 931 - .stage-3 932 - .mswin_test 933 tags: 934 - mswin-stage3 935 variables: 936 PETSC_OPTIONS: -check_pointer_intensity 0 -error_output_stdout -nox -nox_warning -malloc_dump 937 TEST_ARCH: arch-ci-mswin-uni 938 939mswin-gnu: 940 extends: 941 - .stage-3 942 - .mswin_test 943 tags: 944 - mswin-stage3 945 variables: 946 TEST_ARCH: arch-ci-mswin-gnu 947 MAKE_CFLAGS: -Werror 948 MAKE_CXXFLAGS: -Werror 949 MAKE_FFLAGS: -Werror 950 DISABLE_TESTS: 1 951 952#mswin-intel: 953# extends: 954# - .stage-3 955# - .mswin_test 956# tags: 957# - os:win 958# variables: 959# TEST_ARCH: arch-ci-mswin-intel 960 961opensolaris-pkgs-opt: 962 extends: 963 - .stage-3 964 - .opensolaris_test 965 tags: 966 - name:n-gage 967 variables: 968 TEST_ARCH: arch-ci-opensolaris-pkgs-opt 969 970opensolaris-cmplx-pkgs-dbg: 971 extends: 972 - .stage-3 973 - .opensolaris_test 974 tags: 975 - name:n-gage 976 variables: 977 TEST_ARCH: arch-ci-opensolaris-cmplx-pkgs-dbg 978 979opensolaris-misc: 980 extends: 981 - .stage-3 982 - .opensolaris_test 983 tags: 984 - name:n-gage 985 variables: 986 TEST_ARCH: arch-ci-opensolaris-misc 987 988osx-cxx-cmplx-pkgs-dbg: 989 extends: 990 - .stage-3 991 - .osx_test 992 - .coverage-disable 993 tags: 994 - os:macos 995 variables: 996 TEST_ARCH: arch-ci-osx-cxx-cmplx-pkgs-dbg 997 INIT_SCRIPT: /Users/glci/bin/py3.sh 998 999osx-cxx-pkgs-opt: 1000 extends: 1001 - .stage-3 1002 - .osx_test 1003 tags: 1004 - os:macos, opt 1005 variables: 1006 PETSC_OPTIONS: -vecscatter_mpi1 false -options_left false 1007 TEST_ARCH: arch-ci-osx-cxx-pkgs-opt 1008 MAKE_CXXFLAGS: -Werror -Wno-pass-failed 1009 1010osx-dbg: 1011 extends: 1012 - .stage-3 1013 - .osx_test 1014 - .coverage-disable 1015 tags: 1016 - os:macos 1017 variables: 1018 TEST_ARCH: arch-ci-osx-dbg 1019 1020osx-xsdk-opt: 1021 extends: 1022 - .stage-3 1023 - .osx_test 1024 - .coverage-disable 1025 tags: 1026 - os:macos, opt 1027 variables: 1028 TEST_ARCH: arch-ci-osx-xsdk-opt 1029 1030# job for analyzing the coverage results and generating the various reports 1031coverage-analyze: 1032 extends: .test 1033 stage: stage-4 1034 tags: 1035 - gce-u22-short 1036 dependencies: 1037 # stage-2 1038 - linux-gcc-quad-64idx-dbg 1039 - linux-gcc-pkgs-opt 1040 - linux-gcc-complex-opt-32bit 1041 # stage-3 1042 - linux-pkgs-dbg 1043 - linux-matlab-ilp64 1044 - linux-cuda-pkgs 1045 - linux-cxx-cmplx-pkgs-64idx 1046 - linux-cuda-cmplx 1047 - linux-cuda-double-64idx 1048 - linux-cuda-uni-pkgs 1049 - linux-viennacl 1050 - linux-without-fc 1051 - linux-gcc-cxx-avx2 1052 - linux-clang-avx 1053 - linux-pkgs-cxx-mlib 1054 - linux-pkgs-valgrind 1055 - linux-nagfor 1056 - linux-xsdk-dbg 1057 - linux-opt-misc 1058 - linux-pkgs-64idx 1059 - linux-64idx-i8 1060 - linux-gcc-ifc-cmplx 1061 - linux-opt-cxx-quad 1062 - linux-ILP64 1063 - linux-64idx-i8-uni 1064 - osx-cxx-pkgs-opt 1065 variables: 1066 PYTHON: python3 1067 PETSC_ARCH: arch-ci-analyze-pipeline 1068 before_script: 1069 - date 1070 - hostname 1071 script: 1072 - if [ ! -z ${LOAD_MODULES+x} ]; then module --trace load ${LOAD_MODULES}; module list; fi 1073 - ${PYTHON} --version 1074 - gcovr --version 1075 - printf "PATH:$PATH\n" 1076 - printf "PYTHONPATH:$PYTHONPATH\n" 1077 - if [ ! -z ${CI_MERGE_REQUEST_SOURCE_BRANCH_NAME+x} ]; then printf "CI_MERGE_REQUEST_SOURCE_BRANCH_NAME:$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME\n" ;fi 1078 - ${PYTHON} ./configure --with-mpi=0 --with-cxx=0 --download-sowing --with-fortran-bindings 1079 - make mergegcov PETSC_GCOV_OPTIONS='--ci-mode --verbose' 1080 coverage: /^\s*lines:\s*\d+.\d+\%/ 1081 artifacts: 1082 name: "$CI_JOB_NAME" 1083 when: always 1084 paths: 1085 - arch-ci-analyze-pipeline/gcovr/* 1086 - arch-ci-analyze-pipeline/lib/petsc/conf/*.log 1087 expire_in: 4 days 1088 reports: 1089 coverage_report: 1090 coverage_format: cobertura 1091 path: arch-ci-analyze-pipeline/gcovr/xml/*.xml 1092 1093# template for the coverage review jobs, these must be separate jobs as you cannot deploy multiple 1094# environments from one job... 1095.coverage-review: 1096 extends: .test 1097 stage: .post 1098 tags: 1099 - gce-u22-short 1100 dependencies: 1101 - coverage-analyze 1102 script: 1103 - date 1104 - hostname 1105 artifacts: 1106 name: "$CI_JOB_NAME" 1107 when: always 1108 paths: 1109 - arch-ci-analyze-pipeline/gcovr/* 1110 - arch-ci-analyze-pipeline/lib/petsc/conf/*.log 1111 expire_in: 4 days 1112 1113coverage-total-review: 1114 extends: .coverage-review 1115 environment: 1116 name: coverage/all/$CI_COMMIT_REF_SLUG 1117 url: https://$CI_PROJECT_NAMESPACE.gitlab.io/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/arch-ci-analyze-pipeline/gcovr/html/report.html 1118 auto_stop_in: one week 1119 deployment_tier: testing 1120 1121coverage-untested-review: 1122 extends: .coverage-review 1123 environment: 1124 name: coverage/untested/$CI_COMMIT_REF_SLUG 1125 url: https://$CI_PROJECT_NAMESPACE.gitlab.io/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/arch-ci-analyze-pipeline/gcovr/html_untested/report_untested.html 1126 auto_stop_in: one week 1127 deployment_tier: testing 1128 1129analyze-pipeline: 1130 extends: .coverage-review 1131 script: 1132 - date 1133 - hostname 1134 # This file is created by lib/petsc/bin/maint/gcov.py. If it exists then the CI 1135 # pipeline should fail 1136 - if [ -f ./arch-ci-analyze-pipeline/gcovr/.CI_FAIL ]; then 1137 cat ./arch-ci-analyze-pipeline/gcovr/merge_gcov_errors.log; 1138 exit 1; 1139 fi 1140 1141# 1142# Base job for a documentation build (runs in venv to allow installing additional packages without root) 1143# 1144.docs: 1145 stage: stage-3 1146 tags: 1147 - gce-stage2 1148 before_script: 1149 - printf "PATH:$PATH\n" 1150 - printf "PYTHONPATH:$PYTHONPATH\n" 1151 - VENV=venv-petsc-docs && 1152 python3 -m venv $VENV && 1153 . $VENV/bin/activate && 1154 cd doc && 1155 python3 -m pip install -r requirements.txt 1156 1157# 1158# Build documentation and make available for review using GitLab pages 1159# 1160docs-review: 1161 extends: 1162 - .docs 1163 - .test-basic 1164 script: 1165 - (make html BUILDDIR="../public" SPHINXOPTS="-T -E -W --keep-going -j 1") || (printf "Sphinx build failed (warnings count as errors)\n" && false) 1166 - (make latexpdf SPHINXOPTS="-T -E -W --keep-going") || (printf "Sphinx build failed (warnings count as errors)\n" && false) 1167 - cp _build/latex/manual.pdf ../public/html/manual/ 1168 environment: 1169 name: review/$CI_COMMIT_REF_NAME 1170 url: https://$CI_PROJECT_NAMESPACE.gitlab.io/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/public/html/index.html 1171 auto_stop_in: one week 1172 deployment_tier: development 1173 artifacts: 1174 paths: 1175 - public 1176 expire_in: 4 days 1177 except: 1178 variables: 1179 - $PETSC_CI_SCHEDULED =~ /yes/ 1180 1181# 1182# Deploy documentation using GitLab pages 1183# 1184pages: # this job name has special meaning to GitLab 1185 extends: .docs 1186 interruptible: true 1187 script: 1188 - mkdir -p ../public/ && cp public/* ../public/ 1189 - git fetch --unshallow --no-tags origin +release:remotes/origin/release +main:remotes/origin/main 1190 - git checkout origin/main && pip install -r requirements.txt && make website-deploy SPHINXOPTS="-j 1" BUILDDIR="../public/main" && make latexpdf && mkdir -p ../public/main/docs/manual && cp _build/latex/manual.pdf ../public/main/manual/ 1191 - make clean BUILDDIR="../public/release" 1192 - git clean -fdxq && rm -rf images 1193 - git checkout origin/release && pip install -r requirements.txt && make website-deploy SPHINXOPTS="-j 1" BUILDDIR="../public/release" && make latexpdf && mkdir -p ../public/release/docs/manual && cp _build/latex/manual.pdf ../public/release/docs/manual/ 1194 - rm -rf ../public/*/.doctrees 1195 only: 1196 variables: 1197 - $PETSC_CI_SCHEDULED == "yes" 1198 artifacts: 1199 paths: 1200 - public 1201 expire_in: 4 days 1202 1203# 1204# 1205# The following tests are experimental; more tests by users at other sites may be added below this. Experimental test 1206# that fail produce a warning, but do not block execution of a pipeline. 1207# 1208 1209.test-experimental: 1210 extends: .test 1211 allow_failure: true 1212 1213