Skip to content

Merge pull request #17750 from masterleinad/fix_compiling_msvc #21927

Merge pull request #17750 from masterleinad/fix_compiling_msvc

Merge pull request #17750 from masterleinad/fix_compiling_msvc #21927

Workflow file for this run

name: github-linux
on:
push:
pull_request:
types:
- opened
- reopened
- synchronize
- ready_for_review
concurrency:
group: ${ {github.event_name }}-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{github.event_name == 'pull_request'}}
permissions:
contents: read
jobs:
########################
# linux-release-serial #
########################
linux-release-serial:
# simple serial release build using g++
name: linux release serial
runs-on: [ubuntu-22.04]
#
# The following condition only runs the workflow on 'push' or if the
# 'pull_request' is not a draft. This is only useful for hackathons or
# other situations when the CI is massively overburdened with pull
# requests.
#
# if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
container:
image: dealii/dependencies:jammy
options: --user root
steps:
- uses: actions/checkout@v4
- name: info
run: |
python --version
g++ -v
cmake --version
- name: configure deal.II
run: |
# sanitize PYTHONPATH
unset PYTHONPATH
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Release \
-D DEAL_II_CXX_FLAGS='-Werror -std=c++20' \
-D DEAL_II_EARLY_DEPRECATIONS=ON \
-DDEAL_II_COMPONENT_PYTHON_BINDINGS=ON \
..
- name: print detailed.log
run: cat build/detailed.log
- name: build
run: |
cd build
make VERBOSE=1 -j2
- name: test
run: |
cd build
make -j2 \
setup_tests_a-framework \
setup_tests_examples \
setup_tests_quick_tests
ctest --output-on-failure -j2 -VV
########################
# linux-debug-parallel #
########################
linux-debug-parallel:
# simple parallel debug build using g++
name: linux debug parallel
runs-on: [ubuntu-22.04]
#
# The following condition only runs the workflow on 'push' or if the
# 'pull_request' is not a draft. This is only useful for hackathons or
# other situations when the CI is massively overburdened with pull
# requests.
#
# if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
container:
image: dealii/dependencies:jammy
options: --user root --env OMPI_ALLOW_RUN_AS_ROOT=1 --env OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1
steps:
- uses: actions/checkout@v4
- name: info
run: |
mpicc -v
cmake --version
- name: configure deal.II
run: |
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Debug \
-D DEAL_II_CXX_FLAGS='-Werror -std=c++20' \
-D DEAL_II_EARLY_DEPRECATIONS=ON \
-D DEAL_II_COMPONENT_EXAMPLES="OFF" \
-D DEAL_II_WITH_MPI="ON" \
-D DEAL_II_WITH_CGAL="ON" \
-D DEAL_II_WITH_HDF5="ON" \
-D DEAL_II_WITH_METIS="ON" \
-D DEAL_II_WITH_PETSC="ON" \
-D DEAL_II_WITH_TRILINOS="ON" \
-D DEAL_II_WITH_VTK="ON" \
..
- name: print detailed.log
run: cat build/detailed.log
- name: build
run: |
cd build
make VERBOSE=1 -j2
- name: test
run: |
# Remove warning: "A high-performance Open MPI point-to-point
# messaging module was unable to find any relevant network
# interfaces."
export OMPI_MCA_btl_base_warn_component_unused='0'
cd build
make -j2 \
setup_tests_a-framework \
setup_tests_examples \
setup_tests_quick_tests
ctest --output-on-failure -j2 -VV
###############################
# linux-debug-parallel-tpetra #
###############################
linux-debug-parallel-tpetra:
# simple parallel debug build using g++ and trilinos+tpetra
name: linux debug parallel tpetra
runs-on: [ubuntu-22.04]
#
# The following condition only runs the workflow on 'push' or if the
# 'pull_request' is not a draft. This is only useful for hackathons or
# other situations when the CI is massively overburdened with pull
# requests.
#
# if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
container:
image: dealii/dependencies:jammy
options: --user root --env OMPI_ALLOW_RUN_AS_ROOT=1 --env OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1
steps:
- uses: actions/checkout@v4
- name: info
run: |
mpicc -v
cmake --version
- name: configure deal.II
run: |
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Debug \
-D DEAL_II_CXX_FLAGS='-std=c++20' \
-D DEAL_II_EARLY_DEPRECATIONS=ON \
-D DEAL_II_COMPONENT_EXAMPLES="OFF" \
-D DEAL_II_WITH_64BIT_INDICES="ON" \
-D DEAL_II_WITH_MPI="ON" \
-D DEAL_II_WITH_P4EST="ON" \
-D DEAL_II_WITH_TRILINOS="ON" \
..
- name: print detailed.log
run: cat build/detailed.log
- name: build
run: |
cd build
make VERBOSE=1 -j2
- name: test
run: |
# Remove warning: "A high-performance Open MPI point-to-point
# messaging module was unable to find any relevant network
# interfaces."
export OMPI_MCA_btl_base_warn_component_unused='0'
cd build
make VERBOSE=1 -j2
- name: test
run: |
# Remove warning: "A high-performance Open MPI point-to-point
# messaging module was unable to find any relevant network
# interfaces."
export OMPI_MCA_btl_base_warn_component_unused='0'
cd build
make -j2 setup_tests
ctest --output-on-failure -j2 -VV -R "tpetra"
############################
# linux-debug-intel-oneapi #
############################
linux-debug-intel-oneapi:
# parallel debug build with Intel oneAPI including MPI and MKL
#
# Based on https://github.com/oneapi-src/oneapi-ci
# For a list of Intel packages see https://oneapi-src.github.io/oneapi-ci/#linux-apt
name: linux debug intel oneapi
runs-on: [ubuntu-22.04]
#
# The following condition only runs the workflow on 'push' or if the
# 'pull_request' is not a draft. This is only useful for hackathons or
# other situations when the CI is massively overburdened with pull
# requests.
#
# if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
steps:
- uses: actions/checkout@v4
- uses: rscohn2/setup-oneapi@v0
with:
components: |
icx
impi
mkl
tbb
- name: info
run: |
source /opt/intel/oneapi/setvars.sh
export I_MPI_CXX=icpx
mpiicpc -v
cmake --version
- name: configure deal.II
run: |
source /opt/intel/oneapi/setvars.sh
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Debug \
-D CMAKE_CXX_COMPILER=icpx \
-D DEAL_II_CXX_FLAGS='-Werror -Wno-error=tautological-constant-compare' \
-D DEAL_II_EARLY_DEPRECATIONS=ON \
-D DEAL_II_WITH_MPI=ON \
-D DEAL_II_WITH_LAPACK=ON \
-D DEAL_II_WITH_TBB=ON \
-D MPI_DIR=${I_MPI_ROOT} \
-D BLAS_DIR=${MKLROOT} \
-D LAPACK_DIR=${MKLROOT} \
-D TBB_DIR=${TBBROOT} \
..
- name: print detailed.log
run: cat build/detailed.log
- name: build
run: |
source /opt/intel/oneapi/setvars.sh
cd build
make VERBOSE=1 -j2
- name: test
run: |
source /opt/intel/oneapi/setvars.sh
cd build
make -j2 \
setup_tests_a-framework \
setup_tests_examples \
setup_tests_quick_tests
ctest --output-on-failure -j2 -VV
#######################
# linux-debug-cuda-11 #
#######################
linux-debug-cuda-11:
# simple parallel debug build using cuda-11
name: linux debug cuda-11
runs-on: [ubuntu-20.04]
#
# The following condition only runs the workflow on 'push' or if the
# 'pull_request' is not a draft. This is only useful for hackathons or
# other situations when the CI is massively overburdened with pull
# requests.
#
# if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
env:
CUDA_ROOT: /usr/local/cuda
steps:
- uses: actions/checkout@v4
- name: modules
run: |
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004.pin
sudo mv cuda-ubuntu2004.pin /etc/apt/preferences.d/cuda-repository-pin-600
sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/3bf863cc.pub
sudo add-apt-repository "deb http://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/ /"
sudo apt-get install -y software-properties-common
sudo add-apt-repository ppa:ginggs/deal.ii-9.4.0-backports
sudo apt-get update
sudo apt-get install -yq --no-install-recommends \
cuda-toolkit-11-8 \
libp4est-dev \
libopenmpi-dev \
numdiff \
openmpi-bin \
libboost-all-dev
# https://github.com/apache/flink/blob/master/tools/azure-pipelines/free_disk_space.sh
- name: remove unused large packages
run : |
echo "=============================================================================="
echo "Freeing up disk space on CI system"
echo "=============================================================================="
echo "Listing 100 largest packages"
dpkg-query -Wf '${Installed-Size}\t${Package}\n' | sort -n | tail -n 100
df -h
echo "Removing large packages"
sudo apt-get remove -y '^dotnet-.*'
sudo apt-get remove -y '^llvm-.*'
sudo apt-get remove -y 'php.*'
sudo apt-get remove -y azure-cli google-cloud-sdk hhvm google-chrome-stable firefox powershell mono-devel
sudo apt-get autoremove -y
sudo apt-get clean
df -h
echo "Removing large directories"
# deleting 15GB
rm -rf /usr/share/dotnet/
df -h
- uses: lukka/get-cmake@v3.27.9
- name: info
run: |
mpicc -v
cmake --version
- uses: actions/checkout@v4
with:
repository: kokkos/kokkos
ref: 3.7.00
path: kokkos
- name: compile and install kokkos
working-directory: kokkos
run: |
mkdir build
cd build
cmake -D BUILD_SHARED_LIBS=ON \
-D CMAKE_CXX_COMPILER=${GITHUB_WORKSPACE}/kokkos/bin/nvcc_wrapper \
-D CMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/../kokkos-install \
-D Kokkos_ENABLE_CUDA=ON \
-D Kokkos_ENABLE_CUDA_LAMBDA=ON \
-D Kokkos_ENABLE_CUDA_CONSTEXPR=ON \
-D Kokkos_ARCH_VOLTA70=ON \
..
make install
- name: configure deal.II
run: |
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Debug \
-D CMAKE_CXX_COMPILER=${GITHUB_WORKSPACE}/kokkos/bin/nvcc_wrapper \
-D DEAL_II_CXX_FLAGS='-Werror -Wno-non-template-friend' \
-D DEAL_II_EARLY_DEPRECATIONS=ON \
-D DEAL_II_WITH_KOKKOS="ON" \
-D KOKKOS_DIR=${GITHUB_WORKSPACE}/../kokkos-install \
-D DEAL_II_WITH_MPI="ON" \
-D DEAL_II_MPI_WITH_DEVICE_SUPPORT="ON" \
-D DEAL_II_WITH_P4EST="ON" \
-D DEAL_II_COMPONENT_EXAMPLES="ON" \
..
- name: print detailed.log
run: cat build/detailed.log
- name: build deal.II
run: |
cd build
make VERBOSE=1 -j2
- name: build CUDA tests
run: |
cd build
make -j2 setup_tests_matrix_free_kokkos
cd tests/matrix_free_kokkos
make -j2 compile_test_executables
#############################
# linux-debug-cuda-11-clang #
#############################
linux-debug-cuda-11-clang:
# simple parallel debug build using cuda-11 and clang
name: linux debug cuda-11 clang
runs-on: [ubuntu-22.04]
#
# The following condition only runs the workflow on 'push' or if the
# 'pull_request' is not a draft. This is only useful for hackathons or
# other situations when the CI is massively overburdened with pull
# requests.
#
# if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
env:
CUDA_ROOT: /usr/local/cuda
steps:
- uses: actions/checkout@v4
- name: modules
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 18
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-ubuntu2204.pin
sudo mv cuda-ubuntu2204.pin /etc/apt/preferences.d/cuda-repository-pin-600
sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/3bf863cc.pub
sudo add-apt-repository "deb http://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/ /"
sudo apt-get install -y software-properties-common
sudo add-apt-repository ppa:ginggs/deal.ii-9.4.0-backports
sudo apt-get update
sudo apt-get install -yq --no-install-recommends \
cuda-toolkit-11-8 \
libp4est-dev \
libopenmpi-dev \
numdiff \
openmpi-bin \
libboost-all-dev
- uses: lukka/get-cmake@v3.27.9
- name: info
run: |
mpicc -v
clang++-18 -v
cmake --version
- uses: actions/checkout@v4
with:
repository: kokkos/kokkos
ref: 3.7.00
path: kokkos
- name: compile and install kokkos
working-directory: kokkos
run: |
mkdir build
cd build
cmake -D BUILD_SHARED_LIBS=ON \
-D CMAKE_CXX_COMPILER=clang++-18 \
-D CMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/../kokkos-install \
-D Kokkos_ENABLE_CUDA=ON \
-D Kokkos_ARCH_VOLTA70=ON \
..
make install
- name: configure deal.II
run: |
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Debug \
-D CMAKE_CXX_COMPILER=clang++-18 \
-D DEAL_II_FORCE_BUNDLED_BOOST=ON \
-D DEAL_II_CXX_FLAGS="-std=c++17" \
-D DEAL_II_EARLY_DEPRECATIONS=ON \
-D DEAL_II_WITH_KOKKOS="ON" \
-D KOKKOS_DIR=${GITHUB_WORKSPACE}/../kokkos-install \
-D DEAL_II_WITH_MPI="ON" \
-D DEAL_II_MPI_WITH_DEVICE_SUPPORT="OFF" \
-D DEAL_II_WITH_P4EST="ON" \
-D DEAL_II_COMPONENT_EXAMPLES="ON" \
..
cat detailed.log
- name: archive detailed.log
uses: actions/upload-artifact@v4
with:
name: linux-cuda-clang-detailed.log
path: build/detailed.log
- name: build deal.II
run: |
cd build
make VERBOSE=1 -j 2
- name: build CUDA tests
run: |
cd build
make -j2 setup_tests_matrix_free_kokkos
cd tests/matrix_free_kokkos
make -j2 compile_test_executables