Skip to content

[pre-commit.ci] pre-commit autoupdate (#867) #4513

[pre-commit.ci] pre-commit autoupdate (#867)

[pre-commit.ci] pre-commit autoupdate (#867) #4513

Workflow file for this run

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-24.04
env:
CXXFLAGS: "-Werror -Wno-deprecated-declarations -Wno-error=pass-failed"
CMAKE_GENERATOR: Ninja
if: github.event.pull_request.draft == false
steps:
- uses: actions/checkout@v4
- name: install dependencies
shell: bash
run: .github/workflows/dependencies/hip-openmpi.sh 6.3.2
- name: CCache Cache
uses: actions/cache@v4
# - once stored under a key, they become immutable (even if local cache path content changes)
# - for a refresh the key has to change, e.g., hash of a tracked file in the key
with:
path: |
~/.ccache
~/.cache/ccache
key: ccache-hip-clang-${{ hashFiles('.github/workflows/hip.yml') }}-${{ hashFiles('cmake/dependencies/ABLASTR.cmake') }}
restore-keys: |
ccache-hip-clang-${{ hashFiles('.github/workflows/hip.yml') }}-
ccache-hip-clang-
- 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)
cmake -S . -B build \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DAMReX_AMD_ARCH=gfx900 \
-DImpactX_COMPUTE=HIP \
-DImpactX_FFT=ON \
-DImpactX_PYTHON=ON
cmake --build build -j 4