From 16a5c36795cacd622078f3d31d36d9743b8bfdf7 Mon Sep 17 00:00:00 2001 From: Brad King Date: Mon, 21 Nov 2022 17:28:19 -0500 Subject: gitlab-ci: add nightly job testing NVHPC with Ninja on Linux --- .gitlab/ci/configure_nvhpc_ninja.cmake | 5 +++++ .gitlab/ci/ctest_exclusions.cmake | 10 ++++++++++ .gitlab/ci/docker/nvhpc22.9/Dockerfile | 6 ++++++ .gitlab/ci/docker/nvhpc22.9/install_deps.sh | 11 +++++++++++ .gitlab/ci/env_nvhpc_ninja.sh | 5 +++++ .gitlab/os-linux.yml | 19 +++++++++++++++++++ 6 files changed, 56 insertions(+) create mode 100644 .gitlab/ci/configure_nvhpc_ninja.cmake create mode 100644 .gitlab/ci/docker/nvhpc22.9/Dockerfile create mode 100755 .gitlab/ci/docker/nvhpc22.9/install_deps.sh create mode 100644 .gitlab/ci/env_nvhpc_ninja.sh (limited to '.gitlab') diff --git a/.gitlab/ci/configure_nvhpc_ninja.cmake b/.gitlab/ci/configure_nvhpc_ninja.cmake new file mode 100644 index 0000000000..ca8ba932f5 --- /dev/null +++ b/.gitlab/ci/configure_nvhpc_ninja.cmake @@ -0,0 +1,5 @@ +set(CMake_TEST_CUDA "NVIDIA" CACHE STRING "") + +set(configure_no_sccache 1) + +include("${CMAKE_CURRENT_LIST_DIR}/configure_external_test.cmake") diff --git a/.gitlab/ci/ctest_exclusions.cmake b/.gitlab/ci/ctest_exclusions.cmake index 89a5ace956..b29e785741 100644 --- a/.gitlab/ci/ctest_exclusions.cmake +++ b/.gitlab/ci/ctest_exclusions.cmake @@ -27,6 +27,16 @@ if ("$ENV{CMAKE_CONFIGURATION}" MATCHES "_jom") ) endif() +if ("$ENV{CMAKE_CONFIGURATION}" MATCHES "nvhpc_") + list(APPEND test_exclusions + # FIXME(#24187): This test fails with NVHPC as the CUDA host compiler. + "^CudaOnly.SeparateCompilationPTX$" + + # FIXME(#24188): FindCUDAToolkit breaks on some symlink layouts. + "^Cuda.Toolkit$" + ) +endif() + string(REPLACE ";" "|" test_exclusions "${test_exclusions}") if (test_exclusions) set(test_exclusions "(${test_exclusions})") diff --git a/.gitlab/ci/docker/nvhpc22.9/Dockerfile b/.gitlab/ci/docker/nvhpc22.9/Dockerfile new file mode 100644 index 0000000000..90e7d1214c --- /dev/null +++ b/.gitlab/ci/docker/nvhpc22.9/Dockerfile @@ -0,0 +1,6 @@ +# https://catalog.ngc.nvidia.com/orgs/nvidia/containers/nvhpc/tags +FROM nvcr.io/nvidia/nvhpc:22.9-devel-cuda_multi-ubuntu22.04 +MAINTAINER Brad King + +COPY install_deps.sh /root/install_deps.sh +RUN sh /root/install_deps.sh diff --git a/.gitlab/ci/docker/nvhpc22.9/install_deps.sh b/.gitlab/ci/docker/nvhpc22.9/install_deps.sh new file mode 100755 index 0000000000..51ee410606 --- /dev/null +++ b/.gitlab/ci/docker/nvhpc22.9/install_deps.sh @@ -0,0 +1,11 @@ +#!/bin/sh + +set -e + +apt-get update + +# Install development tools. +apt-get install -y \ + curl + +apt-get clean diff --git a/.gitlab/ci/env_nvhpc_ninja.sh b/.gitlab/ci/env_nvhpc_ninja.sh new file mode 100644 index 0000000000..687403d096 --- /dev/null +++ b/.gitlab/ci/env_nvhpc_ninja.sh @@ -0,0 +1,5 @@ +export CC=nvc +export CXX=nvc++ +export FC=nvfortran +export CUDACXX=nvcc +export CUDAHOSTCXX=nvc++ diff --git a/.gitlab/os-linux.yml b/.gitlab/os-linux.yml index 8fc6ae1939..f2946c1bd5 100644 --- a/.gitlab/os-linux.yml +++ b/.gitlab/os-linux.yml @@ -255,6 +255,18 @@ CMAKE_CONFIGURATION: inteloneapi_makefiles CMAKE_GENERATOR: "Unix Makefiles" +### NVHPC Compiler + +.nvhpc: + image: "kitware/cmake:ci-nvhpc22.9-x86_64-2022-11-22" + variables: + CMAKE_ARCH: x86_64 + +.nvhpc_ninja: + extends: .nvhpc + variables: + CMAKE_CONFIGURATION: nvhpc_ninja + ### CUDA builds .cuda9.2: @@ -392,6 +404,13 @@ - docker - linux +.linux_x86_64_v3_builder_tags_cuda: + tags: + - cmake + - cuda-rt + - docker + - linux-x86_64-v3 + .linux_builder_tags_radeon: tags: - cmake -- cgit v1.2.1