Skip to content

Commit 65a15e4

Browse files
committed
Run CI tests on multiple compilers
1 parent 1f8843e commit 65a15e4

File tree

1 file changed

+72
-17
lines changed

1 file changed

+72
-17
lines changed
Lines changed: 72 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,95 @@
11
name: Test C++ interface
22

3-
# The workflow gets triggered by pushes and pull requests
43
on:
54
push:
65
branches: [ "main" ]
76
pull_request:
87
branches: [ "main" ]
98

109
jobs:
11-
build:
10+
build_and_test:
11+
name: ${{ matrix.name }}
12+
runs-on: ${{ matrix.os }}
13+
container: ${{ matrix.container }}
14+
defaults:
15+
run:
16+
shell: bash
1217

13-
runs-on: ubuntu-latest
1418
strategy:
1519
fail-fast: false
20+
matrix:
21+
include:
22+
### Analysis builds
23+
- name: linux_clang-18_cuda-12.1_debug_analysis
24+
os: ubuntu-24.04
25+
container: ubuntu:20.04
26+
# - name: windows_cl-2022_debug_analysis
27+
# os: windows-2022
28+
# - name: macos_xcode-15.4_debug_analysis
29+
# os: macos-14
30+
- name: linux_gcc-12_debug_analysis
31+
os: ubuntu-22.04
32+
container: ubuntu:22.04
33+
34+
### macOS
35+
# - name: macos_xcode-15.4_release
36+
# os: macos-14
37+
# - name: macos_xcode-16.1_debug
38+
# os: macos-15
39+
40+
### Windows
41+
# - name: windows_cl-2022_release
42+
# os: windows-2022
43+
# - name: windows_cl-2022_debug
44+
# os: windows-2022
45+
46+
- name: linux_gcc-11_debug
47+
os: ubuntu-22.04
48+
container: ubuntu:20.04
49+
- name: linux_gcc-12_release_c++20
50+
os: ubuntu-22.04
51+
container: ubuntu:22.04
52+
- name: linux_gcc-13_debug
53+
os: ubuntu-22.04
54+
container: ubuntu:22.04
55+
56+
# clang++
57+
- name: linux_clang-14_release
58+
os: ubuntu-22.04
59+
container: ubuntu:20.04
60+
- name: linux_clang-15_release
61+
os: ubuntu-22.04
62+
container: ubuntu:20.04
63+
- name: linux_clang-15_debug
64+
os: ubuntu-22.04
65+
container: ubuntu:22.04
66+
- name: linux_clang-16_debug_ubsan
67+
os: ubuntu-22.04
68+
container: ubuntu:22.04
69+
- name: linux_clang-16_debug_tsan
70+
os: ubuntu-22.04
71+
container: ubuntu:22.04
1672

1773
steps:
18-
# checks out the code in the repository
19-
- uses: actions/checkout@v3
20-
with:
21-
submodules: true
74+
- uses: actions/checkout@v4
2275

2376
- name: Install dependencies
2477
run: |
25-
sudo apt install -y libboost-dev
26-
sudo apt install -y libtbb-dev
27-
sudo apt install libomp-dev
78+
apt update
79+
apt install -y libboost-dev libtbb-dev libomp-dev
2880
29-
- name: Compile and run tests
81+
- name: Compile tests
82+
working-directory: ${{ github.workspace }}/tests
83+
run: |
84+
cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
85+
cmake --build build --parallel
86+
87+
- name: Run tests
3088
working-directory: ${{ github.workspace }}/tests
3189
run: |
32-
cmake -B build -DCMAKE_BUILD_TYPE=Release
33-
cmake --build build -- -j 3
3490
echo "Running serial backend"
35-
./build/cpu/serial.out
91+
./build/serial.out
3692
echo "Running TBB backend"
37-
./build/cpu/tbb.out
93+
./build/tbb.out
3894
echo "Running OpenMP backend"
39-
./build/cpu/openmp.out
40-
95+
./build/openmp.out

0 commit comments

Comments
 (0)