Now uses similar settings as master.
Change-Id: I2df3ab916930108afaa63830b7fd92680d837584
# Deploy stage for release builds
- release-deploy
-default:
- tags:
- - k8s-scilifelab
-
include:
# Mix-in helper job definitions of general utility.
- local: '/admin/gitlab-ci/global.gitlab-ci.yml'
+ - local: '/admin/gitlab-ci/rules.gitlab-ci.yml'
# gmxapi Python package.
- local: '/admin/gitlab-ci/python-gmxapi.gitlab-ci.yml'
# Further API validation and usability of sample gmxapi extension package.
cache: {}
# Docker image uploaded to dockerhub by user eriklindahl
# TODO: Get DockerFile for admin/dockerfiles
- image: biophysics/gcc-gromacs
+ image: gromacs/ci-docs-llvm:2020
stage: configure-build
-
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
script:
- cmake -P cmake/gmxVersionInfo.cmake &> version.json
-
artifacts:
paths:
- version.json
regressiontests:prepare:
extends:
- .variables:default
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
cache: {}
- image: biophysics/gcc-gromacs
+ image: gromacs/ci-docs-llvm:2020
stage: configure-build
-
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
# Always clone the default version for this branch, master in this case
script:
- export REGTESTBRANCH=release-2020
+ - if [[ ! -z $REGRESSIONTESTBRANCH ]] ; then
+ export REGTESTBRANCH=$REGRESSIONTESTBRANCH ;
+ echo "Using $REGTESTBRANCH instead of default" ;
+ fi
+ - export CHECKOUTCOMMIT=FETCH_HEAD
+ - if [[ ! -z $REGRESSIONTESTCOMMIT ]] ; then
+ export CHECKOUTCOMMIT=$REGRESSIONTESTCOMMIT ;
+ echo "Using $CHECKOUTCOMMIT instead of head of $REGTESTBRANCH" ;
+ fi
- if [[ ! -d regressiontests ]] ; then
mkdir regressiontests ;
cd regressiontests ;
fi
- cd regressiontests
- git fetch https://gitlab.com/gromacs/gromacs-regressiontests.git $REGTESTBRANCH
- - git checkout -qf FETCH_HEAD
+ - git checkout -qf $CHECKOUTCOMMIT
- git clean -ffdxq
- git gc
- git archive -o gmx-regressiontests.tar.gz --prefix regressiontests/ -9 HEAD
cache: {}
# Docker image uploaded to dockerhub by user eriklindahl
# TODO: Get DockerFile for admin/dockerfiles
- image: biophysics/gcc-gromacs
+ image: gromacs/ci-docs-llvm:2020
stage: release-package
-
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
needs:
- job: prepare-release-version
script:
variables:
KUBERNETES_CPU_LIMIT: 4
KUBERNETES_CPU_REQUEST: 2
- KUBERNETES_MEMORY_LIMIT: 4Gi
+ KUBERNETES_MEMORY_REQUEST: 4Gi
script:
- rm -rf gromacs*tar.gz
- cd $BUILD_DIR
BUILD_DIR: build-package
release-verify:
- image: biophysics/gcc-gromacs
+ image: gromacs/ci-docs-llvm:2020
stage: release-verify
extends:
- .variables:default
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
script:
- VERSION=`cat version.json |
python3 -c "import json,sys; print(json.load(sys.stdin)['version'])"`
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
CMAKE_COMPILER_SCRIPT: "-DCMAKE_C_COMPILER=clang-7 -DCMAKE_CXX_COMPILER=clang++-7"
- CMAKE_EXTRA_OPTIONS: ""
CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=None"
CMAKE_MPI_OPTIONS: "-DGMX_THREAD_MPI=OFF"
CMAKE_PRECISION_OPTIONS: "-DGMX_DOUBLE=OFF"
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
CMAKE_COMPILER_SCRIPT: "-DCMAKE_C_COMPILER=clang-7 -DCMAKE_CXX_COMPILER=clang++-7"
- CMAKE_EXTRA_OPTIONS: ""
CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=None"
CMAKE_MPI_OPTIONS: "-DGMX_THREAD_MPI=ON"
CMAKE_PRECISION_OPTIONS: "-DGMX_DOUBLE=OFF"
extends:
- .docs:configure
- .rules:basic-push
- tags: []
variables:
BUILD_DIR: build-docs
CMAKE_EXTRA_OPTIONS: -DGMX_BUILD_HELP=on -DGMX_BUILD_MANUAL=on
- .before_script:default
- .rules:basic-push
stage: documentation
- tags: []
needs:
- job: docs:configure
variables:
variables:
KUBERNETES_CPU_LIMIT: 4
KUBERNETES_CPU_REQUEST: 2
- KUBERNETES_MEMORY_LIMIT: 4Gi
+ KUBERNETES_MEMORY_REQUEST: 4Gi
script:
- cd $BUILD_DIR
- cmake --build . --target manual -- -j4 | tee docs/manual/all-output.log
- .webpage:build
- .rules:basic-push
stage: post-test
- tags: []
needs:
- job: docs:build
- job: check-source
- .docs:configure:release
- .rules:nightly-only-for-release
cache: {}
+ tags:
+ - k8s-scilifelab
dependencies:
- archive:package
- regressiontests:package
- .before_script:default
- .rules:nightly-only-for-release
stage: release-build
+ tags:
+ - k8s-scilifelab
needs:
- job: webpage:configure
variables:
extends:
- .webpage:build
- .rules:nightly-only-for-release
+ stage: release-prepare-deploy
+ tags:
+ - k8s-scilifelab
dependencies:
- webpage:dependencies
- webpage:configure
- stage: release-prepare-deploy
variables:
BUILD_DIR: release-doc-builds
# Mix-in job definitions.
+# The (hidden) job definitions in this file are available to the regular job
+# definitions in other files because this file is first in the *include* list
+# in the root `.gitlab-ci.yml` file.
# Centralized definitions of common job parameter values.
+# Parameters with many optional configurations may be in separate files.
+# Refer to the Infrastructure section of the GROMACS Developer Guide.
.variables:default:
variables:
KUBERNETES_CPU_LIMIT: 8
KUBERNETES_CPU_REQUEST: 4
+ KUBERNETES_MEMORY_REQUEST: 4Gi
KUBERNETES_MEMORY_LIMIT: 8Gi
KUBERNETES_EXTENDED_RESOURCE_NAME: ""
KUBERNETES_EXTENDED_RESOURCE_LIMIT: 0
CACHE_FALLBACK_KEY: "$CI_JOB_NAME-$CI_JOB_STAGE-release-2020"
BUILD_DIR: build
INSTALL_DIR: install
- CMAKE_GMXAPI_OPTIONS: "-DGMX_PYTHON_PACKAGE=OFF"
-# TODO: Get these from updated Docker images.
+ CMAKE_GMXAPI_OPTIONS: ""
# Our generic before_script to install dependencies and prepare the ccache directory.
.before_script:default:
- export CCACHE_BASEDIR=${PWD}
- export CCACHE_DIR=${PWD}/ccache
-# Jobs that run for new commits and pipelines triggered by schedules or
-# through the web interface, unless GROMACS_RELEASE is set. Excluded from
-# extra pipelines generated by merge request events.
-# Includes non-gromacs projects. Note that jobs using this rule are
-# eligible to run on non-gromacs project infrastructure, and should therefore
-# override the default *tag* parameter to exclude tags specific to the GROMACS
-# GitLab Runner infrastructure. I.e. in the job definition, set `tags: []`
-.rules:basic-push:
- rules:
- - if: '$GROMACS_RELEASE'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "web"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "push"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- when: never
-
-# Jobs that run for merge requests and schedules, but not when GROMACS_RELEASE
-# is set. Excludes non-gromacs projects.
-.rules:merge-requests:
- rules:
- - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
- when: never
- - if: '$GROMACS_RELEASE'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "web"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "push"'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- when: always
-
-# Jobs that run for merge requests and schedules for branch `master`,
-# but not when GROMACS_RELEASE is set.
-# Excludes non-gromacs projects.
-.rules:merge-requests:master:
- rules:
- - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
- when: never
- - if: '$GROMACS_RELEASE'
- when: never
- # This rule catches "push" and other events in branches other than `master`
- # but allows merge_request_events for merge requests targeting master.
- # This rule is before "web" so the web interface won't include jobs that can't succeed
- # (and would not ordinarily be run). Such jobs are hard to identify in a way that is
- # sufficiently general for a global rules definition.
- # If extra coverage is needed through a web-triggered job in merge request branches,
- # we could provide an additional short-circuiting rule based on an environment variable
- # to be provided through the web interface.
- - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "master" && $CI_COMMIT_REF_NAME != "master"'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "web"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- when: always
-
-# Jobs that run for merge requests and schedules for branch `release-2020`,
-# but not when GROMACS_RELEASE is set.
-# Excludes non-gromacs projects.
-.rules:merge-requests:release-2020:
- rules:
- - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
- when: never
- - if: '$GROMACS_RELEASE'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "web"'
- when: always
- # This next rule catches "push" and other events in branches other than `release-2020`
- # but allows merge_request_events for merge requests targeting `release-2020`.
- - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "release-2020" && $CI_COMMIT_REF_NAME != "release-2020"'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
- when: always
- - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- when: always
-
-# Rule to run a job only in nightly release-preparation pipelines.
-# Checks if the GROMACS_RELEASE variable was set (typically through the GitLab web interface).
-# Excludes merge_requests and non-gromacs projects.
-# TODO: Update to *rules* syntax.
-.rules:nightly-only-for-release:
- rules:
- - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
- when: never
- - if: '$GROMACS_RELEASE && $CI_PIPELINE_SOURCE == "web"'
- when: always
- - if: '$GROMACS_RELEASE && $CI_PIPELINE_SOURCE == "schedule"'
- when: always
-
-# Jobs that run on schedules, but not for merge requests or when GROMACS_RELEASE
-# is set. Excludes non-gromacs projects.
-.rules:nightly-not-for-release:
- rules:
- - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
- when: never
- - if: '$GROMACS_RELEASE'
- when: never
- - if: '$CI_PIPELINE_SOURCE == "web" || $CI_PIPELINE_SOURCE == "schedule"'
- when: always
-
# Behavioral templates
# Use a persistent compiler cache to speed up rebuilds for a single job.
- .rules:basic-push
stage: pre-build
image: gromacs/cmake-3.9.6-gcc-5-cuda-9.0-openmpi:2020
- tags: []
variables:
KUBERNETES_CPU_LIMIT: 8
KUBERNETES_CPU_REQUEST: 4
- KUBERNETES_MEMORY_LIMIT: 8Gi
+ KUBERNETES_MEMORY_REQUEST: 8Gi
CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=None"
CMAKE_MPI_OPTIONS: "-DGMX_THREAD_MPI=ON"
CMAKE_PRECISION_OPTIONS: "-DGMX_DOUBLE=OFF"
2>&1 | tee cmakeLog.log
- awk '/CMake Warning/,/^--|^$/' cmakeLog.log | tee cmakeErrors.log
- if [ -s cmakeErrors.log ] ; then echo "Found CMake warning while processing build"; cat cmakeErrors.log ; exit 1; fi
- - cmake --build . -- -j8 2>&1 | tee buildLogFile.log
- - cmake --build . --target tests -- -j8 2>&1 | tee testBuildLogFile.log
+ - cmake --build . -- -j$KUBERNETES_CPU_LIMIT 2>&1 | tee buildLogFile.log
+ - cmake --build . --target tests -- -j$KUBERNETES_CPU_LIMIT 2>&1 | tee testBuildLogFile.log
- awk '/warning/,/warning.*generated|^$/' buildLogFile.log testBuildLogFile.log
| grep -v "CMake" | tee buildErrors.log || true
- grep "cannot be built" buildLogFile.log testBuildLogFile.log | tee -a buildErrors.log || true
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
CMAKE_COMPILER_SCRIPT: ""
CMAKE_EXTRA_OPTIONS: ""
- CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=AUTO"
+ CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=AVX2_256"
CMAKE_MPI_OPTIONS: "-DGMX_THREAD_MPI=ON"
CMAKE_PRECISION_OPTIONS: "-DGMX_DOUBLE=OFF"
CMAKE_BUILD_TYPE_OPTIONS: "-DCMAKE_BUILD_TYPE=Debug"
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
CMAKE_COMPILER_SCRIPT: ""
CMAKE_EXTRA_OPTIONS: ""
- CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=AUTO"
+ CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=AVX2_256"
CMAKE_MPI_OPTIONS: "-DGMX_THREAD_MPI=ON"
CMAKE_PRECISION_OPTIONS: "-DGMX_DOUBLE=OFF"
CMAKE_BUILD_TYPE_OPTIONS: "-DCMAKE_BUILD_TYPE=RelWithAssert"
extends:
- .gromacs:base:configure
- .use-gcc:base
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
image: gromacs/cmake-3.9.6-gcc-7-amdopencl-clfft-openmpi:2020
variables:
CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=AVX2_256"
- .gromacs:base:configure
- .use-gcc:base
- .use-opencl
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
image: gromacs/cmake-3.9.6-gcc-6-cuda-10.1-nvidiaopencl-clfft-openmpi:2020
variables:
CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=SSE4.1"
extends:
- .gromacs:base:configure
- .use-clang:base
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
variables:
COMPILER_MAJOR_VERSION: 8
COMPILER_MAJOR_VERSION: 6
RELEASE_BUILD_DIR: release-builds-gcc
CMAKE_EXTRA_OPTIONS: "-DGMX_BUILD_MDRUN_ONLY=ON"
- CMAKE_BUILD_TYPE_OPTIONS : "-DCMAKE_BUILD_TYPE=RelWithDebInfo"
+ CMAKE_BUILD_TYPE_OPTIONS : "-DCMAKE_BUILD_TYPE=RelWithAssert"
CMAKE_REGRESSIONTEST_OPTIONS: ""
dependencies:
- archive:package
variables:
COMPILER_MAJOR_VERSION: 8
RELEASE_BUILD_DIR: release-builds-clang
- CMAKE_BUILD_TYPE_OPTIONS: "-DCMAKE_BUILD_TYPE=RelWithDebInfo"
+ CMAKE_BUILD_TYPE_OPTIONS: "-DCMAKE_BUILD_TYPE=RelWithAssert"
# Jobs running during build stage
stage: build
script:
- cd $BUILD_DIR
- - cmake --build . -- -j8 2>&1 | tee buildLogFile.log
- - cmake --build . --target tests -- -j8 2>&1 | tee testBuildLogFile.log
+ - cmake --build . -- -j$KUBERNETES_CPU_LIMIT 2>&1 | tee buildLogFile.log
+ - cmake --build . --target tests -- -j$KUBERNETES_CPU_LIMIT 2>&1 | tee testBuildLogFile.log
- awk '/warning/,/warning.*generated|^$/' buildLogFile.log testBuildLogFile.log
| grep -v "CMake" | tee buildErrors.log || true
- grep "cannot be built" buildLogFile.log testBuildLogFile.log | tee -a buildErrors.log || true
- cmake --build . --target install 2>&1 | tee installBuildLogFile.log
- if [ -s buildErrors.log ] ; then echo "Found compiler warning during build"; cat buildErrors.log; exit 1; fi
+ - for file in `find . -mindepth 1 -name "*.o" ! -type l` ; do echo $file ; rm $file ; done 2>&1 > remove-build-objects.log
- cd ..
artifacts:
when: always
- .gromacs:base:build
- .before_script:default
- .use-ccache
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
image: gromacs/cmake-3.9.6-gcc-7-amdopencl-clfft-openmpi:2020
needs:
- job: gromacs:gcc-7:configure
- .gromacs:base:build
- .before_script:default
- .use-ccache
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
image: gromacs/cmake-3.9.6-gcc-6-cuda-10.1-nvidiaopencl-clfft-openmpi:2020
needs:
- job: gromacs:gcc-6:configure
- .gromacs:base:build
- .use-clang:base
- .use-ccache
- - .rules:merge-requests
+ - .rules:merge-and-post-merge-acceptance
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
needs:
- job: gromacs:clang-TSAN:configure
- .use-ccache
- .rules:merge-requests
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-ASAN:configure
- .use-ccache
- .rules:merge-requests
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-static-analyzer:configure
extends:
- .variables:default
variables:
+ KUBERNETES_CPU_LIMIT: 4
+ KUBERNETES_CPU_REQUEST: 4
+ KUBERNETES_MEMORY_REQUEST: 4Gi
REGRESSIONTEST_TOTAL_RANK_NUMBER: 4
REGRESSIONTEST_OMP_RANK_NUMBER: 2
REGRESSIONTEST_PME_RANK_NUMBER: 1
variables:
KUBERNETES_EXTENDED_RESOURCE_NAME: "amd.com/gpu"
KUBERNETES_EXTENDED_RESOURCE_LIMIT: 1
+ LD_LIBRARY_PATH: "/opt/rocm-3.5.0/opencl/lib"
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:gcc-7:build
variables:
KUBERNETES_EXTENDED_RESOURCE_NAME: "nvidia.com/gpu"
KUBERNETES_EXTENDED_RESOURCE_LIMIT: 1
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:gcc-6:build
gromacs:clang-TSAN:test:
extends:
- .gromacs:base:test
- - .rules:merge-requests
+ - .rules:post-merge-acceptance
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
needs:
- job: gromacs:clang-TSAN:build
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
variables:
CTEST_RUN_MODE: "ExperimentalMemCheck"
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-ASAN:build
gromacs:gcc-7:regressiontest:
extends:
- .gromacs:base:regressiontest
- - .rules:merge-requests
+ - .rules:post-merge-acceptance
image: gromacs/cmake-3.9.6-gcc-7-amdopencl-clfft-openmpi:2020
variables:
KUBERNETES_EXTENDED_RESOURCE_NAME: "amd.com/gpu"
REGRESSIONTEST_PME_RANK_NUMBER: 0
REGRESSIONTEST_TOTAL_RANK_NUMBER: 2
REGRESSIONTEST_OMP_RANK_NUMBER: 1
+ LD_LIBRARY_PATH: "/opt/rocm-3.5.0/opencl/lib"
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:gcc-7:build
- job: regressiontests:prepare
REGRESSIONTEST_PME_RANK_NUMBER: 0
REGRESSIONTEST_TOTAL_RANK_NUMBER: 2
REGRESSIONTEST_OMP_RANK_NUMBER: 1
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:gcc-6:build
- job: regressiontests:prepare
- .gromacs:base:regressiontest
- .rules:merge-requests
image: gromacs/cmake-3.15.7-llvm-8-intelopencl-openmpi:2020
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-8:build
- job: regressiontests:prepare
gromacs:clang-TSAN:regressiontest:
extends:
- .gromacs:base:regressiontest
- - .rules:merge-requests
+ - .rules:post-merge-acceptance
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-TSAN:build
- job: regressiontests:prepare
- .use-clang:base
- .rules:merge-requests
image: gromacs/cmake-3.15.7-llvm-8-tsan:2020
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-ASAN:build
- job: regressiontests:prepare
REGRESSIONTEST_DOUBLE: "-double"
REGRESSIONTEST_OMP_RANK_NUMBER: 0
REGRESSIONTEST_PARALLEL: "-np"
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-3.6:build
- job: regressiontests:prepare
stage: release-tests
image: gromacs/cmake-3.9.6-gcc-6-cuda-10.1-nvidiaopencl-clfft-openmpi:2020
variables:
+ KUBERNETES_EXTENDED_RESOURCE_NAME: "nvidia.com/gpu"
+ KUBERNETES_EXTENDED_RESOURCE_LIMIT: 1
BUILD_DIR: release-builds-gcc
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:gcc-6:release:configure
- job: gromacs:gcc-6:release:build
image: gromacs/cmake-3.9.6-gcc-7-amdopencl-clfft-openmpi:2020
variables:
BUILD_DIR: release-builds-gcc
+ KUBERNETES_EXTENDED_RESOURCE_NAME: "amd.com/gpu"
+ KUBERNETES_EXTENDED_RESOURCE_LIMIT: 1
+ LD_LIBRARY_PATH: "/opt/rocm-3.5.0/opencl/lib"
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:gcc-7:release:configure
- job: gromacs:gcc-7:release:build
stage: release-tests
image: gromacs/cmake-3.15.7-llvm-8-cuda-10.1-openmpi:2020
variables:
+ KUBERNETES_EXTENDED_RESOURCE_NAME: "nvidia.com/gpu"
+ KUBERNETES_EXTENDED_RESOURCE_LIMIT: 1
BUILD_DIR: release-builds-clang
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-8:release:configure
- job: gromacs:clang-8:release:build
REGRESSIONTEST_DOUBLE: "-double"
REGRESSIONTEST_OMP_RANK_NUMBER: 0
REGRESSIONTEST_PARALLEL: "-np"
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-3.6:release:build
- job: regressiontests:package
REGRESSIONTEST_PME_RANK_NUMBER: 0
REGRESSIONTEST_TOTAL_RANK_NUMBER: 2
REGRESSIONTEST_OMP_RANK_NUMBER: 1
-
+ tags:
+ - k8s-scilifelab
needs:
- job: gromacs:clang-8:release:build
- job: regressiontests:package
- .use-clang:base
- .rules:basic-push
image: gromacs/cmake-3.11.4-llvm-8-openmpi:2020
- tags: []
variables:
COMPILER_MAJOR_VERSION: 8
BUILD_DIR: build-clang-tidy
- .use-clang:base
- .rules:nightly-not-for-release
image: gromacs/cmake-3.11.4-llvm-8-openmpi:2020
- tags: []
variables:
COMPILER_MAJOR_VERSION: 8
BUILD_DIR: build-clang-tidy
- .rules:basic-push
stage: source-check
image: gromacs/cmake-3.11.4-llvm-8-openmpi:2020
- tags: []
needs:
- job: clang-tidy:configure-push
variables:
EXTRA_INSTALLS: clang-tidy-$COMPILER_MAJOR_VERSION
KUBERNETES_CPU_LIMIT: 4
KUBERNETES_CPU_REQUEST: 2
- KUBERNETES_MEMORY_LIMIT: 4Gi
+ KUBERNETES_MEMORY_REQUEST: 4Gi
script:
+ # Make sure that a Python interpreter can be found for `/bin/env python`
+ - test -x /usr/bin/python || update-alternatives --install /usr/bin/python python /usr/bin/python3 1
- REV=$(git fetch -q https://gitlab.com/gromacs/gromacs.git release-2020 && git show -s --pretty=format:"%h" `git merge-base FETCH_HEAD HEAD`)
- HEAD_REV=$(git show -s --pretty=format:"%h" HEAD)
- if [[ "$REV" == "$HEAD_REV" ]] ; then
cache: {}
stage: pre-build
image: gromacs/ci-docs-llvm:2020
- tags: []
variables:
COMPILER_MAJOR_VERSION: 7
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
EXTRA_INSTALLS: clang-format-$COMPILER_MAJOR_VERSION
script:
- REV=$(git fetch -q https://gitlab.com/gromacs/gromacs.git release-2020 && git show -s --pretty=format:"%h" `git merge-base FETCH_HEAD HEAD`)
cache: {}
stage: pre-build
image: gromacs/ci-docs-llvm:2020
- tags: []
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
script:
- REV=$(git fetch -q https://gitlab.com/gromacs/gromacs.git release-2020 && git show -s --pretty=format:"%h" `git merge-base FETCH_HEAD HEAD`)
- HEAD_REV=$(git show -s --pretty=format:"%h" HEAD)
- .rules:basic-push
cache: {}
stage: source-check
- tags: []
needs:
- job: docs:build
artifacts: true
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
BUILD_DIR: build-docs
script:
- cd $BUILD_DIR
- cmake --build . --target check-source
- awk '/warning.*include style.*order/,/You can use.*rst|^$/' docs/doxygen/check-source.log | tee doxygenError.txt || true
+ - awk '/warning:.*includes/,/unnecessarily|^$/' docs/doxygen/check-source.log | tee -a doxygenError.txt || true
- awk '/Traceback/,/.*rror|^$/' docs/doxygen/doxygen*log docs/doxygen/check-source.log | tee -a doxygenError.txt || true
- awk '/warning:/,/in doxygen.*|^$/' docs/doxygen/doxygen*log | tee -a doxygenError.txt || true
+ - grep -i "unused cycle suppression" docs/doxygen/check-source.log | tee -a doxygenError.txt || true
- if [ -s doxygenError.txt ] ; then echo "Found errors while running doxygen"; exit 1; fi
artifacts:
name: docs-artifacts-$CI_COMMIT_REF_SLUG
variables:
KUBERNETES_CPU_LIMIT: 1
KUBERNETES_CPU_REQUEST: 1
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
BUILD_DIR: build-docs
script:
- cd $BUILD_DIR
variables:
KUBERNETES_CPU_LIMIT: 2
KUBERNETES_CPU_REQUEST: 2
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
PY_UNIT_TEST_XML: $CI_PROJECT_DIR/py-JUnitTestResults.xml
PY_MPI_UNIT_TEST_XML: $CI_PROJECT_DIR/py-mpi-JUnitTestResults.xml
PY_ACCEPTANCE_TEST_XML: $CI_PROJECT_DIR/gmxapi-acceptance-JUnitTestResults.xml
- $PY_MPI_ACCEPTANCE_TEST_XML
when: always
expire_in: 1 week
+ tags:
+ - k8s-scilifelab
+ # The dependency means we need to use the same tag restriction as upstream.
needs:
- job: gromacs:clang-8:build
artifacts: true
- $PY_MPI_ACCEPTANCE_TEST_XML
when: always
expire_in: 1 week
+ tags:
+ - k8s-scilifelab
+ # The dependency means we need to use the same tag restriction as upstream.
needs:
- job: gromacs:clang-8:build
artifacts: true
--- /dev/null
+# Mix-in definitions to inherit a standardized *rules* parameter.
+# Reference:
+# * https://docs.gitlab.com/ee/ci/yaml/#rules
+# * https://docs.gitlab.com/ee/ci/variables/README.html#syntax-of-environment-variable-expressions
+
+# GitLab CI uses a YAML array for the *rules* job parameter, but neither YAML
+# nor GitLab CI syntax provide a way to merge arrays. However, elements of
+# *rules* are mappings, and we can at least reduce the amount of copy-paste
+# syntax by providing anchors and example arrays.
+# The following YAML objects may be referenced through "anchors" as elements of
+# the *rules* array in mix-in jobs (defined later in the file).
+# The &<name> annotation is a YAML anchor that allows the annotated {"if", "when"} hash
+# to be inserted with a *<name> alias in a `rules` arrays in the current file.
+# Commonly reusable elements have anchors defined for easy copy-paste templating
+# of new rule sets. Rule elements that are unique to a single *rules* mix-in may
+# be defined with the rule set for readability, particularly when the element is
+# the main distinguishing characteristic of the mix-in.
+
+# Exclude from pipelines launched outside the "gromacs" GitLab project namespace.
+.rules-element:if-not-gromacs-then-never: &if-not-gromacs-then-never
+ if: '$CI_PROJECT_NAMESPACE != "gromacs"'
+ when: never
+
+# Exclude if the GROMACS_RELEASE variable is set.
+.rules-element:if-release-then-never: &if-release-then-never
+ if: '$GROMACS_RELEASE'
+ when: never
+
+# Exclude unless the GROMACS_RELEASE variable is set (through the web interface).
+.rules-element:if-not-release-then-never: &if-not-release-then-never
+ if: '$GROMACS_RELEASE == null'
+ when: never
+
+# Include in pipelines triggered through the web interface.
+.rules-element:if-web-then-always: &if-web-then-always
+ if: '$CI_PIPELINE_SOURCE == "web"'
+ when: always
+
+# Exclude from pipelines triggered by "push" events.
+.rules-element:if-push-then-never: &if-push-then-never
+ if: '$CI_PIPELINE_SOURCE == "push"'
+ when: never
+
+# Include in pipelines triggered by "push" events to any branch.
+.rules-element:if-push-then-always: &if-push-then-always
+ if: '$CI_PIPELINE_SOURCE == "push"'
+ when: always
+
+# Include in "schedule" pipelines (e.g. nightly jobs)
+.rules-element:if-schedule-then-always: &if-schedule-then-always
+ if: '$CI_PIPELINE_SOURCE == "schedule"'
+ when: always
+
+# Exclude from selective "schedule" pipelines, e.g. just those
+# that should run the post-merge-acceptance jobs.
+.rules-element:if-post-merge-acceptance-then-never: &if-post-merge-acceptance-then-never
+ if: '$POST_MERGE_ACCEPTANCE'
+ when: never
+
+# Include in pipelines triggered in the merge request process.
+.rules-element:if-mr-then-always: &if-mr-then-always
+ if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
+ when: always
+
+# Exclude from pipelines triggered in the merge request process, such as for
+# jobs that duplicate checks already performed for "push" events or that we
+# only want to run in scheduled / manually triggered pipelines.
+.rules-element:if-mr-then-never: &if-mr-then-never
+ if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
+ when: never
+
+# Include job when running for merge request or when pushing to protected branch.
+.rules-element:if-post-merge-acceptance-or-mr-then-always: &if-post-merge-acceptance-or-mr-then-always
+ if: '$CI_PIPELINE_SOURCE == "merge_request_event" ||
+ ($CI_PIPELINE_SOURCE == "push" &&
+ ($CI_COMMIT_REF_NAME == "master" || $CI_COMMIT_REF_NAME == "release-*"))'
+ when: always
+
+# Include job only for post submit push
+.rules-element:if-post-merge-acceptance-then-always: &if-post-merge-acceptance-then-always
+ if: '$CI_PIPELINE_SOURCE == "push" &&
+ ($CI_COMMIT_REF_NAME == "master" || $CI_COMMIT_REF_NAME == "release-*")'
+ when: always
+
+# When composing a rule set, note that the first matching rule is applied.
+# If you want later rules to be evaluated, you must make sure that the *if*
+# clause of the earlier rules does not match. This may require inverting the
+# logic of a rule element *if* and *when* clause in a new element definition
+# (above) in order to construct new rule sets.
+
+# Jobs that run for new commits and pipelines triggered by schedules or
+# through the web interface, unless GROMACS_RELEASE is set. Excluded from
+# extra pipelines generated by merge request events.
+# Includes non-gromacs projects. Note that jobs using this rule are
+# eligible to run on non-gromacs project infrastructure, and should therefore
+# override the default *tag* parameter to exclude tags specific to the GROMACS
+# GitLab Runner infrastructure. I.e. in the job definition, set `tags: []`
+.rules:basic-push:
+ rules:
+ - *if-release-then-never
+ - *if-mr-then-never
+ - *if-post-merge-acceptance-then-never
+ - *if-web-then-always
+ - *if-push-then-always
+ - *if-schedule-then-always
+
+# Jobs to run after successful merge of a new commit.
+# Only run on GROMACS infrastructure and only when merging into
+# the master or release branches.
+.rules:post-merge-acceptance:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-release-then-never
+ - *if-mr-then-never
+ - *if-post-merge-acceptance-then-always
+ - *if-web-then-always
+ - *if-schedule-then-always
+
+# Jobs that run for merge requests and schedules, but not when GROMACS_RELEASE
+# is set. Excludes non-GROMACS projects.
+# More elaborate rule sets for merge requests should be based on the same sequence.
+.rules:merge-requests:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-release-then-never
+ - *if-push-then-never
+ - *if-post-merge-acceptance-then-never
+ - *if-web-then-always
+ - *if-schedule-then-always
+ - *if-mr-then-always
+
+# Jobs running both in post submit and for merge requests
+# Excludes non-GROMACS projects.
+.rules:merge-and-post-merge-acceptance:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-release-then-never
+ - *if-web-then-always
+ - *if-schedule-then-always
+ - *if-post-merge-acceptance-or-mr-then-always
+
+# Jobs that run for merge requests and schedules for branch `master`,
+# but not when GROMACS_RELEASE is set.
+# Excludes non-gromacs projects.
+.rules:merge-requests:master:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-release-then-never
+ - *if-post-merge-acceptance-then-never
+ - *if-web-then-always
+ # This rule catches "push" and other events in branches other than `master`
+ # but allows merge_request_events for merge requests targeting master.
+ - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "master" && $CI_COMMIT_REF_NAME != "master"'
+ when: never
+ - *if-schedule-then-always
+ - *if-mr-then-always
+
+# Jobs that run for merge requests and schedules for branch `release-2020`,
+# but not when GROMACS_RELEASE is set.
+# Excludes non-gromacs projects.
+.rules:merge-requests:release-2020:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-release-then-never
+ - *if-post-merge-acceptance-then-never
+ # This next rule catches "push" and other events in branches other than `release-2020`
+ # but allows merge_request_events for merge requests targeting `release-2020`.
+ # This rule is before "web" so the web interface won't include jobs that can't succeed
+ # (and would not ordinarily be run). Such jobs are hard to identify in a way that is
+ # sufficiently general for a global rules definition.
+ # If extra coverage is needed through a web-triggered job in merge request branches,
+ # we could provide an additional short-circuiting rule based on an environment variable
+ # to be provided through the web interface.
+ - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "release-2020" && $CI_COMMIT_REF_NAME != "release-2020"'
+ when: never
+ - *if-web-then-always
+ - *if-schedule-then-always
+ - *if-mr-then-always
+
+# Rule to run a job only in nightly release-preparation pipelines.
+# Checks if the GROMACS_RELEASE variable was set (typically through the GitLab web interface).
+# Excludes merge_requests and non-gromacs projects.
+.rules:nightly-only-for-release:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-not-release-then-never
+ - *if-post-merge-acceptance-then-never
+ - *if-web-then-always
+ - *if-schedule-then-always
+
+# Jobs that run on schedules, but not for merge requests or when GROMACS_RELEASE
+# is set. Excludes non-gromacs projects.
+.rules:nightly-not-for-release:
+ rules:
+ - *if-not-gromacs-then-never
+ - *if-release-then-never
+ - *if-post-merge-acceptance-then-never
+ - *if-web-then-always
+ - *if-schedule-then-always
variables:
KUBERNETES_CPU_LIMIT: 2
KUBERNETES_CPU_REQUEST: 2
- KUBERNETES_MEMORY_LIMIT: 2Gi
+ KUBERNETES_MEMORY_REQUEST: 2Gi
PLUGIN_TEST_XML: $CI_PROJECT_DIR/py-JUnitTestResults.xml
PLUGIN_MPI_TEST_XML: $CI_PROJECT_DIR/py-mpi-JUnitTestResults.xml
EXTRA_INSTALLS: "curl libbz2-dev libffi-dev liblzma-dev libncurses5-dev libncursesw5-dev libreadline-dev libsqlite3-dev libssl-dev llvm python-openssl tk-dev zlib1g-dev"
- $PLUGIN_MPI_TEST_XML
when: always
expire_in: 1 week
+ tags:
+ - k8s-scilifelab
+ # The dependency means we need to use the same tag restriction as upstream.
needs:
# Note: if we want to run regression tests using artifacts from the `release-2020`
# pipelines, we could specify *project* and *ref*, but initially we are only
- $PLUGIN_MPI_TEST_XML
when: always
expire_in: 1 week
+ tags:
+ - k8s-scilifelab
+ # The dependency means we need to use the same tag restriction as upstream.
needs:
- job: gromacs:clang-8:build
artifacts: true
src/gromacs/tables/quadraticsplinetable.h: warning: includes "simd.h" unnecessarily
# These are specific to Folding@Home, and easiest to suppress here
-*: warning: includes non-local file as "corewrap.h"
src/gmxpre.h: warning: includes non-local file as "swindirect.h"
# New external API (see https://redmine.gromacs.org/issues/2586) has some unresolved
#include "gromacs/compat/pointers.h"
-#include "config.h"
-
#include <memory>
#include <vector>
#include "gromacs/gmxpreprocess/readir.h"
-#include "config.h"
-
#include <string>
#include <gtest/gtest.h>
#include "gromacs/utility/enumerationhelpers.h"
-#include "config.h"
-
#include <iostream>
#include <gtest/gtest.h>
*/
#include "gmxpre.h"
-#include "config.h"
-
#include <string>
#include <gmock/gmock.h>
#ifndef GMX_TESTUTILS_TESTASSERTS_H
#define GMX_TESTUTILS_TESTASSERTS_H
+#include "config.h"
+
#include <string>
#include <gtest/gtest.h>