Skip to content

Merge remote-tracking branch 'origin' into bugfix/integral-symmetry-f… #127

Merge remote-tracking branch 'origin' into bugfix/integral-symmetry-f…

Merge remote-tracking branch 'origin' into bugfix/integral-symmetry-f… #127

name: Intel (Classic) Tests
on: [push]
jobs:
build-and-test:
runs-on: ubuntu-22.04
strategy:
matrix:
mpi: ['FALSE', 'TRUE']
opt: ['FALSE', 'TRUE']
include:
- debug: 'TRUE'
opt: 'FALSE'
- debug: 'FALSE'
opt: 'TRUE'
name: MPI = ${{ matrix.mpi }}, OPT = ${{ matrix.opt }}
env:
CHOMBO_HOME: ${{ github.workspace }}/Chombo/lib
OMP_NUM_THREADS: 1
BUILD_ARGS: MPI=${{ matrix.mpi}} OPT=${{ matrix.opt }} DEBUG=${{ matrix.debug }}
steps:
- name: Checkout Chombo
uses: actions/checkout@v4
with:
repository: GRChombo/Chombo
path: Chombo
- name: Checkout GRChombo
uses: actions/checkout@v4
with:
path: GRChombo
- name: Update package manager database
id: update-database
continue-on-error: true
run: sudo apt-get update
# This is quite slow so only do this if the previous command fails
- name: Update package repository mirrors if necessary
if: steps.update-database.outcome == 'failure'
run: |
sudo gem install apt-spy2
sudo apt-spy2 fix --commit --launchpad --country=US
sudo apt-get update
- name: Install Chombo dependencies
run: sudo apt-get -y --no-install-recommends install csh libgetopt-complete-perl
- name: Install Intel compilers
run: |
wget -O- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB \
| gpg --dearmor | sudo tee /usr/share/keyrings/oneapi-archive-keyring.gpg > /dev/null
echo "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
sudo apt-get update
sudo apt-get -y install intel-oneapi-compiler-dpcpp-cpp-and-cpp-classic-2023.2.4 intel-oneapi-compiler-fortran-2023.2.4 intel-oneapi-mkl-2023.2.0 intel-oneapi-openmp-2023.2.4
working-directory: /tmp
- name: Instal Intel MPI
if: matrix.mpi == 'TRUE'
run: |
sudo apt-get -y install intel-oneapi-mpi intel-oneapi-mpi-devel
- name: Build Chombo
run: |
source /opt/intel/oneapi/setvars.sh
cp $GITHUB_WORKSPACE/GRChombo/InstallNotes/MakeDefsLocalExamples/intel-classic-no-hdf5-minimal.Make.defs.local $CHOMBO_HOME/mk/Make.defs.local
make -j 4 AMRTimeDependent AMRTools BaseTools BoxTools $BUILD_ARGS
working-directory: ${{ env.CHOMBO_HOME }}
- name: Build GRChombo Tests
run: |
source /opt/intel/oneapi/setvars.sh
make test -j 4 $BUILD_ARGS
working-directory: ${{ github.workspace }}/GRChombo
- name: Run GRChombo Tests
run: |
source /opt/intel/oneapi/setvars.sh
make run -j 2 $BUILD_ARGS
working-directory: ${{ github.workspace }}/GRChombo