Skip to content

Commit

Permalink
Merge branch 'development' into use_openpmd-api
Browse files Browse the repository at this point in the history
  • Loading branch information
WeiqunZhang committed Jan 4, 2024
2 parents ea95312 + f1ec8df commit 52bb537
Show file tree
Hide file tree
Showing 78 changed files with 738 additions and 349 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/bittree.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
mpiexec -n 2 ./main2d.gnu.TEST.MPI.ex inputs_bittree amr.plot_int=1000
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-15 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -104,7 +104,7 @@ jobs:
mpiexec -n 2 ./main3d.gnu.TEST.MPI.ex inputs_bittree max_step=10
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-15 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/clang.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
make test_install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -117,7 +117,7 @@ jobs:
make -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -159,7 +159,7 @@ jobs:
make install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
26 changes: 20 additions & 6 deletions .github/workflows/dependencies/dependencies_codeplay.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,24 @@

set -eu -o pipefail

curl -o oneapi_nvidia.sh -L "https://developer.codeplay.com/api/v1/products/download?product=oneapi&variant=nvidia&filters[]=linux&aat=$1"
chmod +x oneapi_nvidia.sh
sudo ./oneapi_nvidia.sh --yes
# `man apt.conf`:
# Number of retries to perform. If this is non-zero APT will retry
# failed files the given number of times.
echo 'Acquire::Retries "3";' | sudo tee /etc/apt/apt.conf.d/80-retries

curl -o oneapi_amd.sh -L "https://developer.codeplay.com/api/v1/products/download?product=oneapi&variant=amd&filters[]=linux&aat=$1"
chmod +x oneapi_amd.sh
sudo ./oneapi_amd.sh --yes
# https://developer.codeplay.com/apt/index.html
sudo wget -qO - https://developer.codeplay.com/apt/public.key | gpg --dearmor | sudo tee /usr/share/keyrings/codeplay-keyring.gpg > /dev/null
echo "deb [signed-by=/usr/share/keyrings/codeplay-keyring.gpg] https://developer.codeplay.com/apt all main" | sudo tee /etc/apt/sources.list.d/codeplay.list

sudo apt-get update

# try apt install up to five times, to avoid connection splits
status=1
for itry in {1..5}
do
sudo apt-get install -y --no-install-recommends \
$1 \
&& { sudo apt-get clean; status=0; break; } \
|| { sleep 10; }
done
if [[ ${status} -ne 0 ]]; then exit 1; fi
3 changes: 3 additions & 0 deletions .github/workflows/dependencies/dependencies_hip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ sudo apt-get install -y --no-install-recommends \
rocrand-dev \
rocprim-dev

# hiprand-dev is a new package that does not exist in old versions
sudo apt-get install -y --no-install-recommends hiprand-dev || true

# activate
#
source /etc/profile.d/rocm.sh
Expand Down
26 changes: 13 additions & 13 deletions .github/workflows/gcc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
make test_install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -107,7 +107,7 @@ jobs:
cmake --build build -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -155,7 +155,7 @@ jobs:
cmake --build build -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -204,7 +204,7 @@ jobs:
cmake --build build -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -263,7 +263,7 @@ jobs:
# Let's not use clang-tidy for this test because it wants to use C++20.
# ${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
# make -j2 -f clang-tidy-ccache-misses.mak \
# make -j2 -k -f clang-tidy-ccache-misses.mak \
# CLANG_TIDY=clang-tidy-12 \
# CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -320,7 +320,7 @@ jobs:
make -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -384,7 +384,7 @@ jobs:
make -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -426,7 +426,7 @@ jobs:
make install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -466,7 +466,7 @@ jobs:
make install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-15 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -506,7 +506,7 @@ jobs:
make install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -546,7 +546,7 @@ jobs:
make install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -585,7 +585,7 @@ jobs:
CCACHE=ccache
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -630,7 +630,7 @@ jobs:
make -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-12 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/hypre.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ jobs:
mpiexec -n 2 ./main3d.gnu.MPI.ex inputs.hypre
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down Expand Up @@ -148,7 +148,7 @@ jobs:
mpiexec -n 2 ./main2d.gnu.MPI.ex inputs.2d
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
34 changes: 14 additions & 20 deletions .github/workflows/intel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ jobs:
-DCMAKE_C_COMPILER=$(which icx) \
-DCMAKE_CXX_COMPILER=$(which icpx) \
-DCMAKE_Fortran_COMPILER=$(which ifx) \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DAMReX_PARALLEL_LINK_JOBS=2
cmake --build build --parallel 2
ccache -s
Expand Down Expand Up @@ -86,7 +87,8 @@ jobs:
-DAMReX_GPU_BACKEND=SYCL \
-DCMAKE_C_COMPILER=$(which icx) \
-DCMAKE_CXX_COMPILER=$(which icpx) \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DAMReX_PARALLEL_LINK_JOBS=2
cmake --build build --parallel 2
ccache -s
Expand All @@ -95,29 +97,24 @@ jobs:
tests-oneapi-sycl-eb-nvidia:
name: oneAPI SYCL for Nvidia GPUs [tests w/ EB]
runs-on: ubuntu-latest
env:
CODEPLAYTOKEN: ${{ secrets.CODEPLAYTOKEN }}
steps:
- uses: actions/checkout@v3
- name: Dependencies
if: ${{ env.CODEPLAYTOKEN != '' }}
run: |
.github/workflows/dependencies/dependencies_nvcc.sh
.github/workflows/dependencies/ubuntu_free_disk_space.sh
.github/workflows/dependencies/dependencies_dpcpp.sh
.github/workflows/dependencies/dependencies_codeplay.sh ${{ env.CODEPLAYTOKEN }}
.github/workflows/dependencies/dependencies_nvcc.sh 12.0
.github/workflows/dependencies/dependencies_codeplay.sh oneapi-nvidia-12.0
.github/workflows/dependencies/dependencies_ccache.sh
- name: Set Up Cache
if: ${{ env.CODEPLAYTOKEN != '' }}
uses: actions/cache@v3
with:
path: ~/.cache/ccache
key: ccache-${{ github.workflow }}-${{ github.job }}-git-${{ github.sha }}
restore-keys: |
ccache-${{ github.workflow }}-${{ github.job }}-git-
- name: Build & Install
if: ${{ env.CODEPLAYTOKEN != '' }}
# clang currently supports CUDA up to version 11.5 and a warning is issued with newer versions
env: {CXXFLAGS: "-fsycl -fsycl-targets=nvptx64-nvidia-cuda -fno-operator-names -Werror -Wall -Wextra -Wpedantic -Wnull-dereference -Wfloat-conversion -Wshadow -Woverloaded-virtual -Wextra-semi -Wunreachable-code -Wnon-virtual-dtor -Wno-unknown-cuda-version"}
env: {CXXFLAGS: "-fsycl -fsycl-targets=nvptx64-nvidia-cuda -Xsycl-target-backend --offload-arch=sm_80 -fno-operator-names -Werror -Wall -Wextra -Wpedantic -Wnull-dereference -Wfloat-conversion -Wshadow -Woverloaded-virtual -Wextra-semi -Wunreachable-code -Wnon-virtual-dtor"}
run: |
export CCACHE_COMPRESS=1
export CCACHE_COMPRESSLEVEL=10
Expand All @@ -136,7 +133,8 @@ jobs:
-DAMReX_GPU_BACKEND=SYCL \
-DCMAKE_C_COMPILER=$(which icx) \
-DCMAKE_CXX_COMPILER=$(which clang++) \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DAMReX_PARALLEL_LINK_JOBS=2
cmake --build build --parallel 2
ccache -s
Expand All @@ -145,28 +143,23 @@ jobs:
no-tests-oneapi-sycl-amd:
name: oneAPI SYCL for AMD GPUs
runs-on: ubuntu-20.04
env:
CODEPLAYTOKEN: ${{ secrets.CODEPLAYTOKEN }}
steps:
- uses: actions/checkout@v3
- name: Dependencies
if: ${{ env.CODEPLAYTOKEN != '' }}
run: |
.github/workflows/dependencies/ubuntu_free_disk_space.sh
.github/workflows/dependencies/dependencies_hip.sh 5.4.6
.github/workflows/dependencies/dependencies_dpcpp.sh
.github/workflows/dependencies/dependencies_codeplay.sh ${{ env.CODEPLAYTOKEN }}
.github/workflows/dependencies/dependencies_hip.sh 5.4.3
.github/workflows/dependencies/dependencies_codeplay.sh oneapi-amd-5.4.3
.github/workflows/dependencies/dependencies_ccache.sh
- name: Set Up Cache
if: ${{ env.CODEPLAYTOKEN != '' }}
uses: actions/cache@v3
with:
path: ~/.cache/ccache
key: ccache-${{ github.workflow }}-${{ github.job }}-git-${{ github.sha }}
restore-keys: |
ccache-${{ github.workflow }}-${{ github.job }}-git-
- name: Build & Install
if: ${{ env.CODEPLAYTOKEN != '' }}
env: {CXXFLAGS: "-fsycl -fsycl-targets=amdgcn-amd-amdhsa -Xsycl-target-backend --offload-arch=gfx90a -fno-operator-names -Werror -Wall -Wextra -Wpedantic -Wnull-dereference -Wfloat-conversion -Wshadow -Woverloaded-virtual -Wextra-semi -Wunreachable-code -Wnon-virtual-dtor"}
run: |
export CCACHE_COMPRESS=1
Expand All @@ -186,7 +179,8 @@ jobs:
-DAMReX_SYCL_SUB_GROUP_SIZE=64 \
-DCMAKE_C_COMPILER=$(which icx) \
-DCMAKE_CXX_COMPILER=$(which clang++) \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DAMReX_PARALLEL_LINK_JOBS=2
cmake --build build --parallel 2
ccache -s
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/petsc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
mpiexec -n 2 ./main2d.gnu.TEST.MPI.ex inputs.rt.2d.petsc
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/smoke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
make test_install
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-15 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sundials.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ jobs:
cmake --build build -j 2
${{github.workspace}}/Tools/C_scripts/mmclt.py --input ${{github.workspace}}/ccache.log.txt
make -j2 -f clang-tidy-ccache-misses.mak \
make -j2 -k -f clang-tidy-ccache-misses.mak \
CLANG_TIDY=clang-tidy-14 \
CLANG_TIDY_ARGS="--config-file=${{github.workspace}}/.clang-tidy --warnings-as-errors=*"
Expand Down
Loading

0 comments on commit 52bb537

Please sign in to comment.