From a25a2fdcfc3132760c36341449ab9a17ae6fddb8 Mon Sep 17 00:00:00 2001 From: Simeon Ehrig Date: Wed, 14 Aug 2024 17:30:25 +0200 Subject: [PATCH] remove second docker container launch in GitHub Actions Linux Jobs - The container which are provided by GitHub Actions contains a lot of pre installed software. This dirty environment can provide several problems. Therefore we use the default Ubuntu container from Docker Hub or our pre build container. --- .github/workflows/ci.yml | 36 ++++--- script/ci.sh | 10 +- script/docker_ci.sh | 213 --------------------------------------- script/docker_retry.sh | 35 ------- script/install_clang.sh | 5 - 5 files changed, 25 insertions(+), 274 deletions(-) delete mode 100755 script/docker_ci.sh delete mode 100755 script/docker_retry.sh diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6af42f0fee8..4e5a36fa057 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,6 @@ concurrency: # ALPAKA_CI_STDLIB : {libstdc++, [CXX==clang++]:libc++} # CMAKE_BUILD_TYPE : {Debug, Release} # alpaka_CI : {GITHUB} -# ALPAKA_CI_DOCKER_BASE_IMAGE_NAME : {ubuntu:20.04, ubuntu:22.04} # ALPAKA_BOOST_VERSION : {1.74.0, 1.75.0, 1.76.0, 1.77.0, 1.78.0, 1.79.0, 1.80.0, 1.81.0, 1.82.0} # ALPAKA_CI_CMAKE_VER : {3.22.6, 3.23.5, 3.24.4, 3.25.3, 3.26.4} # ALPAKA_CI_XCODE_VER : {13.2.1, 14.2} @@ -100,6 +99,7 @@ jobs: name: ${{ matrix.name }} runs-on: ${{ matrix.os }} env: ${{ matrix.env }} + container: ${{ matrix.container }} strategy: fail-fast: false @@ -108,7 +108,8 @@ jobs: ### Analysis builds - name: linux_clang-14_cuda-11.2_debug_analysis os: ubuntu-20.04 - env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 14, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.79.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:20.04", ALPAKA_CI_ANALYSIS: ON, ALPAKA_CI_RUN_TESTS: OFF, alpaka_DEBUG: 1, alpaka_ACC_GPU_CUDA_ENABLE: ON, ALPAKA_CI_CUDA_VERSION: "11.2", CMAKE_CUDA_COMPILER: clang++, alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE: OFF, alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE: OFF} + env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 14, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.79.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_ANALYSIS: ON, ALPAKA_CI_RUN_TESTS: OFF, alpaka_DEBUG: 1, alpaka_ACC_GPU_CUDA_ENABLE: ON, ALPAKA_CI_CUDA_VERSION: "11.2", CMAKE_CUDA_COMPILER: clang++, alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE: OFF, alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE: OFF} + container: ubuntu:20.04 - name: windows_cl-2022_debug_analysis os: windows-2022 env: {CXX: cl.exe, CC: cl.exe, ALPAKA_CI_CL_VER: 2022, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.78.0, ALPAKA_CI_CMAKE_VER: 3.23.5, ALPAKA_CI_ANALYSIS: ON, alpaka_DEBUG: 2} @@ -117,7 +118,8 @@ jobs: env: {CXX: clang++, CC: clang, ALPAKA_CI_XCODE_VER: 14.2, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.81.0, ALPAKA_CI_ANALYSIS: ON, alpaka_DEBUG: 2, alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE: ON, alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE: ON, ALPAKA_CI_BUILD_JOBS: 3} - name: linux_gcc-12_debug_analysis os: ubuntu-22.04 - env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 12, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.80.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:22.04", ALPAKA_CI_ANALYSIS: ON, alpaka_DEBUG: 2} + env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 12, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.80.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_ANALYSIS: ON, alpaka_DEBUG: 2} + container: ubuntu:22.04 ### macOS - name: macos_xcode-14.2_release @@ -154,13 +156,16 @@ jobs: # - Ubuntu 22.04 - name: linux_gcc-9_debug os: ubuntu-20.04 - env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 9, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.74.0, ALPAKA_CI_CMAKE_VER: 3.22.6, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:20.04", CMAKE_CXX_EXTENSIONS: OFF} + env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 9, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.74.0, ALPAKA_CI_CMAKE_VER: 3.22.6, OMP_NUM_THREADS: 4, CMAKE_CXX_EXTENSIONS: OFF} + container: ubuntu:20.04 - name: linux_gcc-12_release_c++20 os: ubuntu-22.04 - env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 12, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Release, ALPAKA_BOOST_VERSION: 1.80.0, ALPAKA_CI_CMAKE_VER: 3.24.4, OMP_NUM_THREADS: 2, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:22.04", alpaka_CXX_STANDARD: 20, alpaka_USE_MDSPAN: "FETCH"} + env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 12, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Release, ALPAKA_BOOST_VERSION: 1.80.0, ALPAKA_CI_CMAKE_VER: 3.24.4, OMP_NUM_THREADS: 2, alpaka_CXX_STANDARD: 20, alpaka_USE_MDSPAN: "FETCH"} + container: ubuntu:22.04 - name: linux_gcc-13_debug os: ubuntu-22.04 - env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 13, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.82.0, ALPAKA_CI_CMAKE_VER: 3.26.4, OMP_NUM_THREADS: 2, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:22.04"} + env: {CXX: g++, CC: gcc, ALPAKA_CI_GCC_VER: 13, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.82.0, ALPAKA_CI_CMAKE_VER: 3.26.4, OMP_NUM_THREADS: 2} + container: ubuntu:22.04 # TODO: keep jobs until GitLab CI supports: # - disable CMAKE_CXX_EXTENSIONS=OFF @@ -170,20 +175,25 @@ jobs: # clang++ - name: linux_clang-10_release os: ubuntu-20.04 - env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 10, ALPAKA_CI_STDLIB: libc++, CMAKE_BUILD_TYPE: Release, ALPAKA_BOOST_VERSION: 1.75.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:20.04", alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE: OFF, CMAKE_CXX_EXTENSIONS: OFF} + env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 10, ALPAKA_CI_STDLIB: libc++, CMAKE_BUILD_TYPE: Release, ALPAKA_BOOST_VERSION: 1.75.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE: OFF, CMAKE_CXX_EXTENSIONS: OFF} + container: ubuntu:20.04 # clang-11 tested in GitLab CI - name: linux_clang-12_release os: ubuntu-20.04 - env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 12, ALPAKA_CI_STDLIB: libc++, CMAKE_BUILD_TYPE: Release, ALPAKA_BOOST_VERSION: 1.77.0, ALPAKA_CI_CMAKE_VER: 3.24.4, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:20.04", alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE: OFF, CMAKE_CXX_EXTENSIONS: OFF} + env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 12, ALPAKA_CI_STDLIB: libc++, CMAKE_BUILD_TYPE: Release, ALPAKA_BOOST_VERSION: 1.77.0, ALPAKA_CI_CMAKE_VER: 3.24.4, OMP_NUM_THREADS: 4, alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE: OFF, CMAKE_CXX_EXTENSIONS: OFF} + container: ubuntu:20.04 - name: linux_clang-13_debug os: ubuntu-22.04 - env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 13, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.79.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 3, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:20.04", CMAKE_CXX_EXTENSIONS: OFF} + env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 13, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.79.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 3, CMAKE_CXX_EXTENSIONS: OFF} + container: ubuntu:22.04 - name: linux_clang-16_debug_ubsan - os: ubuntu-latest - env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 16, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.77.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:22.04", CMAKE_CXX_EXTENSIONS: OFF, ALPAKA_CI_SANITIZERS: UBSan} + os: ubuntu-22.04 + env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 16, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.77.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, CMAKE_CXX_EXTENSIONS: OFF, ALPAKA_CI_SANITIZERS: UBSan} + container: ubuntu:22.04 - name: linux_clang-16_debug_tsan - os: ubuntu-latest - env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 16, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.77.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, ALPAKA_CI_DOCKER_BASE_IMAGE_NAME: "ubuntu:22.04", alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE: OFF, alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE: OFF, alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE: OFF, CMAKE_CXX_EXTENSIONS: OFF, ALPAKA_CI_SANITIZERS: TSan} + os: ubuntu-22.04 + env: {CXX: clang++, CC: clang, ALPAKA_CI_CLANG_VER: 16, ALPAKA_CI_STDLIB: libstdc++, CMAKE_BUILD_TYPE: Debug, ALPAKA_BOOST_VERSION: 1.77.0, ALPAKA_CI_CMAKE_VER: 3.23.5, OMP_NUM_THREADS: 4, alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE: OFF, alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE: OFF, alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE: OFF, CMAKE_CXX_EXTENSIONS: OFF, ALPAKA_CI_SANITIZERS: TSan} + container: ubuntu:22.04 steps: - name: check filter diff --git a/script/ci.sh b/script/ci.sh index ebeabff1af8..f50b37ec956 100755 --- a/script/ci.sh +++ b/script/ci.sh @@ -18,11 +18,5 @@ if [ -n "$GITHUB_ACTIONS" ] && [ "$ALPAKA_CI_OS_NAME" = "Linux" ]; then sudo sysctl vm.mmap_rnd_bits=28 fi -if [ "$ALPAKA_CI_OS_NAME" = "Linux" ] -then - ./script/docker_ci.sh -elif [ "$ALPAKA_CI_OS_NAME" = "Windows" ] || [ "$ALPAKA_CI_OS_NAME" = "macOS" ] -then - source ./script/install.sh - ./script/run.sh -fi +source ./script/install.sh +./script/run.sh diff --git a/script/docker_ci.sh b/script/docker_ci.sh deleted file mode 100755 index 753950a3263..00000000000 --- a/script/docker_ci.sh +++ /dev/null @@ -1,213 +0,0 @@ -#!/bin/bash - -# -# Copyright 2023 Benjamin Worpitz, Bernhard Manfred Gruber, Jan Stephan -# SPDX-License-Identifier: MPL-2.0 -# - -# Launch an extra docker container on GitHub Actions with a default ubuntu image. -# The Ubuntu image provided by GitHub contains already a lot of installed software -# and does not provide a clean environment. Therefore unexpected behavior at -# configuring the alpaka build is possible. - -https://github.com/actions/runner-images/blob/main/images/ubuntu/Ubuntu2204-Readme.md - -set +xv -source ./script/setup_utilities/set.sh -source ./script/docker_retry.sh - -echo_green "" - -ALPAKA_CI_BOOST_BRANCH="boost-${ALPAKA_BOOST_VERSION}" - -# runtime and compile time options -ALPAKA_DOCKER_ENV_LIST=() -ALPAKA_DOCKER_ENV_LIST+=("--env" "CC=${CC}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "CXX=${CXX}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_OS_NAME=${ALPAKA_CI_OS_NAME}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_ANALYSIS=${ALPAKA_CI_ANALYSIS}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_TBB_VERSION=${ALPAKA_CI_TBB_VERSION}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_BOOST_BRANCH=${ALPAKA_CI_BOOST_BRANCH}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "BOOST_ROOT=${BOOST_ROOT}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_BOOST_VERSION=${ALPAKA_BOOST_VERSION}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_BOOST_LIB_DIR=${ALPAKA_CI_BOOST_LIB_DIR}") -if [ ! -z "${ALPAKA_CI_CLANG_VER+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_CLANG_VER=${ALPAKA_CI_CLANG_VER}") -fi -if [ ! -z "${ALPAKA_CI_BUILD_JOBS+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_BUILD_JOBS=${ALPAKA_CI_BUILD_JOBS}") -fi -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_STDLIB=${ALPAKA_CI_STDLIB}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_CMAKE_VER=${ALPAKA_CI_CMAKE_VER}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_CMAKE_DIR=${ALPAKA_CI_CMAKE_DIR}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_RUN_TESTS=${ALPAKA_CI_RUN_TESTS}") -if [ ! -z "${CMAKE_CXX_FLAGS+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CXX_FLAGS=${CMAKE_CXX_FLAGS}") -fi -if [ ! -z "${CMAKE_C_COMPILER+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_C_COMPILER=${CMAKE_C_COMPILER}") -fi -if [ ! -z "${CMAKE_CXX_COMPILER+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}") -fi -if [ ! -z "${CMAKE_EXE_LINKER_FLAGS+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_EXE_LINKER_FLAGS=${CMAKE_EXE_LINKER_FLAGS}") -fi -if [ ! -z "${CMAKE_CXX_EXTENSIONS+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CXX_EXTENSIONS=${CMAKE_CXX_EXTENSIONS}") -fi -if [ ! -z "${ALPAKA_CI_GCC_VER+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_GCC_VER=${ALPAKA_CI_GCC_VER}") -fi -if [ ! -z "${ALPAKA_CI_SANITIZERS+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_SANITIZERS=${ALPAKA_CI_SANITIZERS}") -fi -if [ ! -z "${ALPAKA_ACC_CPU_B_SEQ_T_SEQ_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_CPU_B_SEQ_T_SEQ_ENABLE=${alpaka_ACC_CPU_B_SEQ_T_SEQ_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_CPU_B_SEQ_T_THREADS_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_CPU_B_SEQ_T_THREADS_ENABLE=${alpaka_ACC_CPU_B_SEQ_T_THREADS_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE=${alpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE=${alpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_GPU_CUDA_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_GPU_CUDA_ENABLE=${alpaka_ACC_GPU_CUDA_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_GPU_HIP_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_GPU_HIP_ENABLE=${alpaka_ACC_GPU_HIP_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE=${alpaka_ACC_CPU_B_TBB_T_SEQ_ENABLE}") -fi -if [ ! -z "${alpaka_ACC_SYCL_ENABLE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_SYCL_ENABLE=${alpaka_ACC_SYCL_ENABLE}") -fi -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_INSTALL_CUDA=${ALPAKA_CI_INSTALL_CUDA}") -if [ "${ALPAKA_CI_INSTALL_CUDA}" == "ON" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_CUDA_DIR=${ALPAKA_CI_CUDA_DIR}") - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_CUDA_VERSION=${ALPAKA_CI_CUDA_VERSION}") - if [ ! -z "${CMAKE_CUDA_COMPILER+x}" ] - then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CUDA_COMPILER=${CMAKE_CUDA_COMPILER}") - fi - if [ ! -z "${CMAKE_CUDA_ARCHITECTURES+x}" ] - then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CUDA_ARCHITECTURES=${CMAKE_CUDA_ARCHITECTURES}") - fi - if [ ! -z "${CMAKE_CUDA_FLAGS+x}" ] - then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CUDA_FLAGS=${CMAKE_CUDA_FLAGS}") - fi -fi -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_INSTALL_HIP=${ALPAKA_CI_INSTALL_HIP}") -if [ "${ALPAKA_CI_INSTALL_HIP}" == "ON" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_HIP_ROOT_DIR=${ALPAKA_CI_HIP_ROOT_DIR}") - if [ ! -z "${CMAKE_HIP_COMPILER+x}" ] - then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_HIP_COMPILER=${CMAKE_HIP_COMPILER})") - fi - if [ ! -z "${CMAKE_HIP_ARCHITECTURES+x}" ] - then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_HIP_ARCHITECTURES=${CMAKE_HIP_ARCHITECTURES})") - fi - if [! -z "${CMAKE_HIP_FLAGS+x}" ] - then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_HIP_FLAGS=${CMAKE_HIP_FLAGS}") - fi -fi -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_INSTALL_TBB=${ALPAKA_CI_INSTALL_TBB}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_INSTALL_OMP=${ALPAKA_CI_INSTALL_OMP}") -ALPAKA_DOCKER_ENV_LIST+=("--env" "ALPAKA_CI_INSTALL_ATOMIC=${ALPAKA_CI_INSTALL_ATOMIC}") - -# runtime only options -ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CI=${alpaka_CI}") -if [ ! -z "${alpaka_DEBUG+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_DEBUG=${alpaka_DEBUG}") -fi -if [ ! -z "${alpaka_CXX_STANDARD+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CXX_STANDARD=${alpaka_CXX_STANDARD}") -fi -if [ ! -z "${OMP_NUM_THREADS+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "OMP_NUM_THREADS=${OMP_NUM_THREADS}") -fi -if [ ! -z "${alpaka_ACC_GPU_CUDA_ONLY_MODE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_GPU_CUDA_ONLY_MODE=${alpaka_ACC_GPU_CUDA_ONLY_MODE}") -fi -if [ ! -z "${alpaka_ACC_GPU_HIP_ONLY_MODE+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ACC_GPU_HIP_ONLY_MODE=${alpaka_ACC_GPU_HIP_ONLY_MODE}") -fi -if [ ! -z "${alpaka_CUDA_FAST_MATH+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CUDA_FAST_MATH=${alpaka_CUDA_FAST_MATH}") -fi -if [ ! -z "${alpaka_CUDA_FTZ+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CUDA_FTZ=${alpaka_CUDA_FTZ}") -fi -if [ ! -z "${alpaka_CUDA_SHOW_REGISTER+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CUDA_SHOW_REGISTER=${alpaka_CUDA_SHOW_REGISTER}") -fi -if [ ! -z "${alpaka_CUDA_KEEP_FILES+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CUDA_KEEP_FILES=${alpaka_CUDA_KEEP_FILES}") -fi -if [ ! -z "${alpaka_CUDA_EXPT_EXTENDED_LAMBDA+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_CUDA_EXPT_EXTENDED_LAMBDA=${alpaka_CUDA_EXPT_EXTENDED_LAMBDA}") -fi -if [ ! -z "${CMAKE_CUDA_SEPARABLE_COMPILATION+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_CUDA_SEPARABLE_COMPILATION=${CMAKE_CUDA_SEPARABLE_COMPILATION}") -fi -if [ ! -z "${CMAKE_INSTALL_PREFIX+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "CMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}") -fi -if [ ! -z "${alpaka_USE_MDSPAN+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_USE_MDSPAN=${alpaka_USE_MDSPAN}") -fi -if [ ! -z "${alpaka_ENABLE_WERROR+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_ENABLE_WERROR=${alpaka_ENABLE_WERROR}") -fi -if [ ! -z "${alpaka_SYCL_ONEAPI_CPU+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_SYCL_ONEAPI_CPU=${alpaka_SYCL_ONEAPI_CPU}") -fi -if [! -z "${alpaka_SYCL_ONEAPI_CPU_ISA+x}" ] -then - ALPAKA_DOCKER_ENV_LIST+=("--env" "alpaka_SYCL_ONEAPI_CPU_ISA=${alpaka_SYCL_ONEAPI_CPU_ISA}") -fi - -docker_retry docker run -v "$(pwd)":"$(pwd)" -w "$(pwd)" "${ALPAKA_DOCKER_ENV_LIST[@]}" "${ALPAKA_CI_DOCKER_BASE_IMAGE_NAME}" /bin/bash -c "source ./script/install.sh && ./script/run.sh" diff --git a/script/docker_retry.sh b/script/docker_retry.sh deleted file mode 100755 index a6b02924886..00000000000 --- a/script/docker_retry.sh +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/bash -# -# Copyright 2019-2020 Benjamin Worpitz, Rene Widera -# SPDX-License-Identifier: MPL-2.0 -# - -set +xv -source ./script/setup_utilities.sh - -# rerun docker command if error 125 ( -# - triggered by image download problems -# - wait 30 seconds before retry -docker_retry() { - # apply `set +euo pipefail` in a local scope so that the following script is not affected and - # e.g. exit on failure is not deactivated - ( - set +euo pipefail - local result=0 - local count=1 - while [ $count -le 3 ]; do - [ $result -eq 125 ] && { - echo_red "\nThe command \"$*\" failed. Retrying, $count of 3.\n" >&2 - } - "$@" - result=$? - [ $result -ne 125 ] && break - count=$((count + 1)) - sleep 30 - done - [ $count -gt 3 ] && { - echo_red "\nThe command \"$*\" failed 3 times.\n" >&2 - } - return $result - ) -} diff --git a/script/install_clang.sh b/script/install_clang.sh index e65bdefa034..3034273f764 100755 --- a/script/install_clang.sh +++ b/script/install_clang.sh @@ -52,11 +52,6 @@ else travis_retry sudo apt-get -y --quiet update travis_retry sudo apt-get -y --quiet --allow-unauthenticated --no-install-recommends install libc++-${ALPAKA_CI_CLANG_VER}-dev travis_retry sudo apt-get -y --quiet --allow-unauthenticated --no-install-recommends install libc++abi-${ALPAKA_CI_CLANG_VER}-dev - if [ "${ALPAKA_CI_CLANG_VER}" -ge 12 ] - then - # Starting from LLVM 12 libunwind is required when using libc++. For some reason this isn't installed by default - travis_retry sudo apt-get -y --quiet --allow-unauthenticated --no-install-recommends install libunwind-${ALPAKA_CI_CLANG_VER}-dev - fi fi # Workaround if clang uses the stdlibc++. The stdlibc++-9 does not support C++20, therefore we install the stdlibc++-11. Clang automatically uses the latest stdlibc++ version.