-
Notifications
You must be signed in to change notification settings - Fork 4
38 lines (35 loc) · 1.7 KB
/
parallel_test.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
# Run tests in parallel to check for bugs that only show up on multiple processes
name: Run tests in parallel
on: [push, pull_request]
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest]
fail-fast: false
timeout-minutes: 60
steps:
- uses: actions/checkout@v2
- uses: mpi4py/setup-mpi@v1
with:
mpi: 'openmpi'
- uses: julia-actions/setup-julia@v1
with:
version: '1.7.2'
arch: x64
- uses: julia-actions/julia-buildpkg@v1
- run: |
julia --project -e 'ENV["JULIA_MPI_BINARY"]="system"; using Pkg; Pkg.build("MPI"; verbose=true)'
julia -O3 --check-bounds=no precompile.jl --debug 1
# Need to use openmpi so that the following arguments work:
# * `--mca rmaps_base_oversubscribe 1` allows oversubscription (more processes
# than physical cores).
# * `--mca mpi_yield_when_idle 1` changes a setting to prevent excessively
# terrible performance when oversubscribing.
mpiexec -np 2 --mca rmaps_base_oversubscribe 1 julia --project=@. -Jmoment_kinetics.so -O3 --check-bounds=no test/runtests.jl --debug 1 --long
mpiexec -np 3 --mca rmaps_base_oversubscribe 1 julia --project=@. -Jmoment_kinetics.so -O3 --check-bounds=no test/runtests.jl --debug 1 --long
mpiexec -np 4 --mca rmaps_base_oversubscribe 1 julia --project=@. -Jmoment_kinetics.so -O3 --check-bounds=no test/runtests.jl --debug 1 --long
# Note: MPI.jl's default implementation is mpich, which has a similar option
# `--with-device=ch3:sock`, but that needs to be set when compiling mpich.
shell: bash