-
Notifications
You must be signed in to change notification settings - Fork 14
162 lines (161 loc) · 5.29 KB
/
CI.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
name: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
schedule:
- cron: '0 5 * * *'
jobs:
CI:
strategy:
matrix:
distro: ['ubuntu:latest']
cxx: ['g++', 'clang++']
backend: ['SERIAL', 'OPENMP']
cmake_build_type: ['Debug', 'Release']
kokkos_ver: ['3.2.01']
arborx: ['ArborX', 'NoArborX']
nnp: ['ON', 'OFF']
layout: ['1']
vector: ['1']
layout_nnp: ['1']
vector_nnp: ['1']
include:
- distro: 'ubuntu:latest'
cxx: 'g++'
openmp: 'ON'
cmake_build_type: 'Release'
kokkos_ver: '3.2.01'
arborx: 'NoArborX'
nnp: 'OFF'
layout: '2'
vector: '64'
layout_nnp: '1'
vector_nnp: '1'
- distro: 'ubuntu:latest'
cxx: 'g++'
openmp: 'ON'
cmake_build_type: 'Release'
kokkos_ver: '3.2.01'
arborx: 'NoArborX'
nnp: 'ON'
layout: '6'
vector: '32'
layout_nnp: '3'
vector_nnp: '32'
- distro: 'ubuntu:latest'
cxx: 'g++'
openmp: 'ON'
cmake_build_type: 'Release'
kokkos_ver: '3.2.01'
arborx: 'NoArborX'
nnp: 'OFF'
layout: '6'
vector: '"1;8;32;1;8;32"'
layout_nnp: '3'
vector_nnp: '"32;8;1"'
runs-on: ubuntu-20.04
container: ghcr.io/ecp-copa/ci-containers/${{ matrix.distro }}
steps:
- name: Get trail license
if: ${{ matrix.cxx == 'icpc' }}
run: |
mkdir ~/Licenses
curl https://dynamicinstaller.intel.com/api/v2/license > ~/Licenses/intel.lic
- name: Checkout kokkos
uses: actions/[email protected]
with:
repository: kokkos/kokkos
ref: ${{ matrix.kokkos_ver }}
path: kokkos
- name: Build kokkos
working-directory: kokkos
run: |
cmake -B build \
-DCMAKE_INSTALL_PREFIX=$HOME/kokkos \
-DKokkos_ENABLE_OPENMP=${{ matrix.openmp }} \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DKokkos_ENABLE_HWLOC=ON \
-DCMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }}
cmake --build build --parallel 2
cmake --install build
- name: Checkout arborx
if: ${{ matrix.arborx == 'ArborX' }}
uses: actions/[email protected]
with:
repository: arborx/ArborX
ref: master
path: arborx
- name: Build arborx
if: ${{ matrix.arborx == 'ArborX' }}
working-directory: arborx
run: |
cmake -B build \
-DCMAKE_PREFIX_PATH=${HOME}/kokkos \
-DCMAKE_INSTALL_PREFIX=$HOME/arborx \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DCMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }}
cmake --build build --parallel 2
cmake --install build
- name: Checkout Cabana
uses: actions/[email protected]
with:
repository: ECP-CoPA/Cabana
ref: master
path: cabana
- name: Build Cabana
working-directory: cabana
run: |
cmake -B build \
-DCMAKE_INSTALL_PREFIX=$HOME/Cabana \
-DMPIEXEC_MAX_NUMPROCS=2 -DMPIEXEC_PREFLAGS="--oversubscribe" \
-DCMAKE_PREFIX_PATH="$HOME/kokkos;$HOME/arborx" \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DCMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }}
cmake --build build --parallel 2
cmake --install build
- name: Checkout n2p2
if: ${{ matrix.nnp == 'ON' }}
uses: actions/[email protected]
with:
repository: CompPhysVienna/n2p2
ref: v2.0.1
path: n2p2
- name: Build n2p2
if: ${{ matrix.nnp == 'ON' }}
working-directory: n2p2/src
run: |
mkdir -p $HOME/n2p2/include
mkdir -p $HOME/n2p2/lib
make libnnpif INTERFACES=CabanaMD PROJECT_INCLUDE=$HOME/n2p2/include PROJECT_LIB=$HOME/n2p2/lib
- name: Checkout CabanaMD
uses: actions/[email protected]
- name: Build CabanaMD
run: |
cmake -B build \
-DCMAKE_INSTALL_PREFIX=$HOME/CabanaMD \
-DMPIEXEC_MAX_NUMPROCS=2 -DMPIEXEC_PREFLAGS="--oversubscribe" \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DCMAKE_CXX_FLAGS="-Wall -Wextra -pedantic -Werror" \
-DCMAKE_PREFIX_PATH="$HOME/Cabana" \
-DCabanaMD_ENABLE_TESTING=ON \
-DCabanaMD_LAYOUT=${{ matrix.layout }} \
-DCabanaMD_VECTORLENGTH=${{ matrix.vector }} \
-DCabanaMD_ENABLE_NNP=${{ matrix.nnp }} \
-DN2P2_DIR=$HOME/n2p2 \
-DCabanaMD_LAYOUT_NNP=${{ matrix.layout_nnp }} \
-DCabanaMD_VECTORLENGTH_NNP=${{ matrix.vector_nnp }}
cmake --build build --parallel 2
CTEST_OUTPUT_ON_FAILURE=1 cmake --build build --target test
cmake --install build
- name: Format CabanaMD
working-directory: build
run: |
make format
git diff --exit-code
- name: Upload Report to codecov.io
if: ${{ matrix.coverage }}
uses: codecov/codecov-action@v1