Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
on:
workflow_call:

jobs:
clang-format:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: DoozyX/clang-format-lint-action@v0.20
with:
source: '.'
clangFormatVersion: 20

python-lint:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: Install flake8
run: python3 -m pip install flake8
- name: Run flake8
run: python3 -m flake8 .
184 changes: 184 additions & 0 deletions .github/workflows/mac.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,184 @@
on:
workflow_call:

jobs:
macos-clang-build:
runs-on: macOS-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup environment
run: |
brew update-reset
brew install ninja mpich llvm
brew install libomp
brew link libomp --overwrite --force
brew install openssl
brew link openssl --overwrite --force
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: ${{ runner.os }}-clang
create-symlink: true
max-size: 1G
- name: CMake configure
run: >
cmake -S . -B build
-D CMAKE_C_COMPILER_LAUNCHER=ccache -D CMAKE_CXX_COMPILER_LAUNCHER=ccache
-G Ninja -DCMAKE_C_FLAGS="-I$(brew --prefix)/opt/libomp/include"
-DCMAKE_CXX_FLAGS="-I$(brew --prefix)/opt/libomp/include"
-D CMAKE_BUILD_TYPE=RELEASE
-DCMAKE_INSTALL_PREFIX=install
- name: Build project
run: |
cmake --build build --parallel
- name: Install project
run: |
cmake --build build --target install
- name: Archive installed package
run: |
tar -czvf macos-clang-sanitizer-install.tar.gz -C install .
- name: Upload installed package
uses: actions/upload-artifact@v4
with:
name: macos-clang-sanitizer-install
path: macos-clang-sanitizer-install.tar.gz
macos-clang-build-debug:
runs-on: macOS-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup environment
run: |
brew update-reset
brew install ninja mpich llvm
brew install libomp
brew link libomp --overwrite --force
brew install openssl
brew link openssl --overwrite --force
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: ${{ runner.os }}-clang
create-symlink: true
max-size: 1G
- name: CMake configure
run: >
cmake -S . -B build
-D CMAKE_C_COMPILER_LAUNCHER=ccache -D CMAKE_CXX_COMPILER_LAUNCHER=ccache
-G Ninja -DCMAKE_C_FLAGS="-I$(brew --prefix)/opt/libomp/include"
-DCMAKE_CXX_FLAGS="-I$(brew --prefix)/opt/libomp/include"
-D CMAKE_BUILD_TYPE=DEBUG
-DCMAKE_INSTALL_PREFIX=install
- name: Build project
run: |
cmake --build build --parallel
- name: Install project
run: |
cmake --build build --target install
- name: Archive installed package
run: |
tar -czvf macos-clang-debug-install.tar.gz -C install .
- name: Upload installed package
uses: actions/upload-artifact@v4
with:
name: macos-clang-debug-install
path: macos-clang-debug-install.tar.gz
macos-clang-test:
needs:
- macos-clang-build
runs-on: macOS-latest
steps:
- uses: actions/checkout@v4
- name: Setup environment
run: |
brew update-reset
brew install ninja mpich llvm
brew install libomp
brew link libomp --overwrite --force
brew install openssl
brew link openssl --overwrite --force
- name: Download installed package
uses: actions/download-artifact@v4
with:
name: macos-clang-sanitizer-install
- name: Extract installed package
run: |
mkdir -p install
tar -xzvf macos-clang-sanitizer-install.tar.gz -C install
- name: Run func tests (MPI, num_proc=1)
run: python3 scripts/run_tests.py --running-type="processes"
env:
PPC_NUM_PROC: 1
PPC_NUM_THREADS: 3
- name: Run func tests (MPI, num_proc=2)
run: python3 scripts/run_tests.py --running-type="processes"
env:
PPC_NUM_PROC: 2
PPC_NUM_THREADS: 2
- name: Run func tests (MPI, num_proc=3)
run: python3 scripts/run_tests.py --running-type="processes"
env:
PPC_NUM_PROC: 3
PPC_NUM_THREADS: 1
- name: Run func tests (MPI, num_proc=4)
run: python3 scripts/run_tests.py --running-type="processes"
env:
PPC_NUM_PROC: 4
PPC_NUM_THREADS: 1
- name: Run tests (threads, num_threads=1)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 1
- name: Run tests (threads, num_threads=2)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 2
- name: Run tests (threads, num_threads=3)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 3
- name: Run tests (threads, num_threads=4)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 4
macos-clang-test-extended:
needs:
- macos-clang-test
runs-on: macOS-latest
steps:
- uses: actions/checkout@v4
- name: Setup environment
run: |
brew update-reset
brew install ninja mpich llvm
brew install libomp
brew link libomp --overwrite --force
brew install openssl
brew link openssl --overwrite --force
- name: Download installed package
uses: actions/download-artifact@v4
with:
name: macos-clang-sanitizer-install
- name: Extract installed package
run: |
mkdir -p install
tar -xzvf macos-clang-sanitizer-install.tar.gz -C install
- name: Run tests (threads, num_threads=5)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 5
- name: Run tests (threads, num_threads=7)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 7
- name: Run tests (threads, num_threads=11)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 11
- name: Run tests (threads, num_threads=13)
run: python3 scripts/run_tests.py --running-type="threads"
env:
PPC_NUM_THREADS: 13
Loading
Loading