Update GPU CI configuration
[alexxy/gromacs.git] / admin / gitlab-ci / gromacs.matrix / gromacs.hipsycl-dev.gitlab-ci.yml
1 # Test goal: build with hipSYCL (both CUDA and ROCm backends) to check SYCL code compatibility
2 # Test intents (should change rarely and conservatively):
3 #   OS: Ubuntu newest supported
4 #   Compiler: Clang
5 #   GPU: hipSYCL
6 #   Scope: configure, build
7 # Test implementation choices (free to change as needed):
8 #   OS: Ubuntu 20.04
9 #   Build type: RelWithAssert
10 #   Compiler: Clang 13 (from ROCm)
11 #   MPI: thread_MPI
12 #   SIMD: AVX2_256
13
14 gromacs:hipsycl-dev:configure:
15   extends:
16     - .gromacs:base:configure
17     - .use-clang:base
18     - .use-sycl
19     - .rules:merge-and-post-merge-acceptance
20   image: ${CI_REGISTRY}/gromacs/gromacs/ci-ubuntu-20.04-llvm-12-cuda-11.4.1-hipsycl-7a309b808-rocm-4.3
21   variables:
22     CMAKE: /usr/local/cmake-3.18.4/bin/cmake
23     CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=AVX2_256"
24     CMAKE_BUILD_TYPE_OPTIONS: "-DCMAKE_BUILD_TYPE=RelWithAssert"
25     # Override the default clang compiler to the one provided by ROCm
26     # Note that this compiler can only build for HIP targets. If this
27     # changes (or we build our own clang) then it would be nice to
28     # reinstate CUDA targets in -DHIPSYCL_TARGETS below.
29     CMAKE_COMPILER_SCRIPT: -DCMAKE_C_COMPILER=/opt/rocm/llvm/bin/clang -DCMAKE_CXX_COMPILER=/opt/rocm/llvm/bin/clang++
30     CMAKE_GPU_OPTIONS: "-DGMX_GPU=SYCL -DGMX_SYCL_HIPSYCL=ON -DHIPSYCL_TARGETS='hip:gfx900'"
31     # Unset COMPILER_LAUNCHER (previously set to ccache) because it conflicts with hipSYCL's syclcc-launcher
32     CMAKE_EXTRA_OPTIONS: "-DCMAKE_C_COMPILER_LAUNCHER= -DCMAKE_CXX_COMPILER_LAUNCHER="
33     COMPILER_MAJOR_VERSION: 13
34
35 gromacs:hipsycl-dev:build:
36   extends:
37     - .variables:default
38     - .gromacs:base:build
39     - .before_script:default
40     # Not using ccache because it plays poorly with syclcc-launcher
41     - .rules:merge-and-post-merge-acceptance
42   image: ${CI_REGISTRY}/gromacs/gromacs/ci-ubuntu-20.04-llvm-12-cuda-11.4.1-hipsycl-7a309b808-rocm-4.3
43   variables:
44     CMAKE: /usr/local/cmake-3.18.4/bin/cmake
45   tags:
46     - k8s-scilifelab
47   needs:
48     - job: gromacs:hipsycl-dev:configure
49