-
Notifications
You must be signed in to change notification settings - Fork 19
45 lines (39 loc) · 1.33 KB
/
hip.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
name: 🐧 HIP
on: [push, pull_request]
concurrency:
group: ${{ github.ref }}-${{ github.head_ref }}-hip
cancel-in-progress: true
jobs:
build_hip:
name: HIP
runs-on: ubuntu-20.04
env:
CXXFLAGS: "-Werror -Wno-deprecated-declarations -Wno-error=pass-failed -fno-operator-names"
CMAKE_GENERATOR: Ninja
if: github.event.pull_request.draft == false
steps:
- uses: actions/checkout@v3
- name: install dependencies
shell: bash
run: .github/workflows/dependencies/hip.sh
- name: build ImpactX
shell: bash
run: |
source /etc/profile.d/rocm.sh
hipcc --version
which clang
which clang++
export CXX=$(which clang++)
export CC=$(which clang)
python3 -m pip install -U pip setuptools wheel
python3 -m pip install -U cmake
# "mpic++ --showme" forgets open-pal in Ubuntu 20.04 + OpenMPI 4.0.3
# https://bugs.launchpad.net/ubuntu/+source/openmpi/+bug/1941786
# https://github.com/open-mpi/ompi/issues/9317
export LDFLAGS="-lopen-pal"
cmake -S . -B build \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DAMReX_GPU_BACKEND=HIP \
-DAMReX_AMD_ARCH=gfx900 \
-DAMReX_SPACEDIM="1;2;3"
cmake --build build --target pip_install -j 2