-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
670 changed files
with
184,906 additions
and
34,367 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: Benchmarks | ||
|
||
on: | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
name: "Benchmarks" | ||
runs-on: ubuntu-22.04 | ||
strategy: | ||
fail-fast: false | ||
env: | ||
CC: gcc-11 | ||
CXX: g++-11 | ||
steps: | ||
- name: Get build dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y ninja-build ccache | ||
- name: Set up cmake | ||
uses: jwlawson/[email protected] | ||
with: | ||
cmake-version: 3.22.x | ||
- name: Clone w/ submodules | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
# figure out vector extensions for ccache key | ||
- name: Check vector extensions | ||
run: | | ||
HAS_AVX512F=$([[ $(lscpu | grep "avx512f" | wc -l) -eq 1 ]] && echo "_avx512f" || echo "") | ||
HAS_AVX2=$([[ $(lscpu | grep "avx2" | wc -l) -eq 1 ]] && echo "_avx2" || echo "") | ||
HAS_FMA=$([[ $(lscpu | grep "fma" | wc -l) -eq 1 ]] && echo "_fma" || echo "") | ||
HAS_AVX=$([[ $(lscpu | grep "avx" | wc -l) -eq 1 ]] && echo "_avx" || echo "") | ||
VECTOR_EXTENSIONS=${HAS_AVX512F}${HAS_AVX2}${HAS_FMA}${HAS_AVX} | ||
echo "VECTOR_EXTENSIONS=$VECTOR_EXTENSIONS" >> $GITHUB_ENV | ||
- name: Setup ccache | ||
uses: hendrikmuhs/[email protected] | ||
with: | ||
key: benchmarks-${{ env.CXX }}-${{ env.VECTOR_EXTENSIONS }} | ||
- name: Build arbor | ||
run: | | ||
mkdir build | ||
cd build | ||
cmake .. -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER=$CXX -DCMAKE_C_COMPILER=$CC -DARB_WITH_MPI=OFF -DARB_USE_BUNDLED_LIBS=ON | ||
ninja -j4 ubenches | ||
cd - | ||
- name: Run benchmarks | ||
run: | | ||
build/bin/accumulate_functor_values | ||
build/bin/default_construct | ||
build/bin/event_setup | ||
build/bin/event_binning | ||
build/bin/fvm_discretize | ||
build/bin/mech_vec | ||
build/bin/task_system |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,35 +7,53 @@ on: | |
jobs: | ||
build: | ||
name: "Sanitize" | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
name: ["Sanitize"] | ||
sanitizer: ["address", "undefined", "thread"] | ||
simd: ["ON", "OFF"] | ||
env: | ||
CC: clang-10 | ||
CXX: clang++-10 | ||
CC: clang-14 | ||
CXX: clang++-14 | ||
ASAN_OPTIONS: detect_leaks=1 | ||
steps: | ||
- name: Get build dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y ninja-build ccache | ||
- name: Set up cmake | ||
uses: jwlawson/actions-setup-cmake@v1.7 | ||
uses: jwlawson/actions-setup-cmake@v1.13 | ||
with: | ||
cmake-version: 3.19.x | ||
- name: Clone w/ submodules | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- name: Update pip | ||
run: python -m pip install --upgrade pip | ||
# figure out vector extensions for ccache key | ||
- name: Check vector extensions | ||
run: | | ||
HAS_AVX512F=$([[ $(lscpu | grep "avx512f" | wc -l) -eq 1 ]] && echo "_avx512f" || echo "") | ||
HAS_AVX2=$([[ $(lscpu | grep "avx2" | wc -l) -eq 1 ]] && echo "_avx2" || echo "") | ||
HAS_FMA=$([[ $(lscpu | grep "fma" | wc -l) -eq 1 ]] && echo "_fma" || echo "") | ||
HAS_AVX=$([[ $(lscpu | grep "avx" | wc -l) -eq 1 ]] && echo "_avx" || echo "") | ||
VECTOR_EXTENSIONS=${HAS_AVX512F}${HAS_AVX2}${HAS_FMA}${HAS_AVX} | ||
echo "VECTOR_EXTENSIONS=$VECTOR_EXTENSIONS" >> $GITHUB_ENV | ||
- name: Setup ccache | ||
uses: hendrikmuhs/[email protected] | ||
with: | ||
key: sanitize-${{ env.CXX }}-${{ matrix.sanitizer }}-${{ env.VECTOR_EXTENSIONS }} | ||
- name: Build arbor | ||
run: | | ||
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH" | ||
mkdir build | ||
cd build | ||
export SAN="-fsanitize=${{ matrix.sanitizer }} -fno-omit-frame-pointer" | ||
cmake .. -DCMAKE_BUILD_TYPE=debug -DCMAKE_CXX_FLAGS="$SAN" -DCMAKE_C_FLAGS="$SAN" -DCMAKE_EXE_LINKER_FLAGS="$SAN" -DCMAKE_MODULE_LINKER_FLAGS="$SAN" -DCMAKE_CXX_COMPILER=$CXX -DCMAKE_C_COMPILER=$CC -DARB_VECTORIZE=${{ matrix.simd }} -DARB_WITH_MPI=OFF -DARB_USE_BUNDLED_LIBS=ON -DARB_WITH_PYTHON=ON -DPython3_EXECUTABLE=`which python` | ||
make -j4 VERBOSE=1 tests examples pyarb | ||
cmake .. -GNinja -DCMAKE_BUILD_TYPE=debug -DCMAKE_CXX_FLAGS="$SAN" -DCMAKE_C_FLAGS="$SAN" -DCMAKE_EXE_LINKER_FLAGS="$SAN" -DCMAKE_MODULE_LINKER_FLAGS="$SAN" -DCMAKE_CXX_COMPILER=$CXX -DCMAKE_C_COMPILER=$CC -DARB_VECTORIZE=${{ matrix.simd }} -DARB_WITH_MPI=OFF -DARB_USE_BUNDLED_LIBS=ON -DARB_WITH_PYTHON=ON -DPython3_EXECUTABLE=`which python` | ||
ninja -j4 -v tests examples pyarb | ||
cd - | ||
- name: Run unit tests | ||
run: | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.