Skip to content

[CI] Add reusable workflows #115

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 12, 2024
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
2 changes: 1 addition & 1 deletion .github/workflows/basic.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: BasicBuilds

on: [push, pull_request, workflow_call]
on: workflow_call

env:
BUILD_DIR : "${{github.workspace}}/build/"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Benchmarks

on: [push, pull_request, workflow_call]
on: workflow_call

jobs:
ubuntu-build:
Expand Down
6 changes: 1 addition & 5 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
name: CodeQL

on: [push, pull_request, workflow_call]

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
on: workflow_call

jobs:
analyze:
Expand Down
61 changes: 61 additions & 0 deletions .github/workflows/pr_push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: PR/push

on: [push, pull_request]

concurrency:
group: ${{ github.head_ref }}-${{ github.workflow }}
cancel-in-progress: true

jobs:
FastBuild:
name: Fast build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
include:
- os: ubuntu-latest
nproc: $(nproc)
pool_scalable: 'ON'
jemalloc: 'ON'
- os: windows-latest
nproc: $Env:NUMBER_OF_PROCESSORS
pool_scalable: 'OFF'
jemalloc: 'OFF'
runs-on: ${{matrix.os}}

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install apt packages
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y cmake libjemalloc-dev libnuma-dev libtbb-dev

- name: Configure CMake
run: >
cmake
-B ${{github.workspace}}/build
-DCMAKE_BUILD_TYPE=Release
-DUMF_FORMAT_CODE_STYLE=OFF
-DUMF_DEVELOPER_MODE=ON
-DUMF_ENABLE_POOL_TRACKING=ON
-DUMF_BUILD_LIBUMF_POOL_SCALABLE=${{matrix.pool_scalable}}
-DUMF_BUILD_LIBUMF_POOL_DISJOINT=ON
-DUMF_BUILD_LIBUMF_POOL_JEMALLOC=${{matrix.jemalloc}}

- name: Build
run: >
cmake --build ${{github.workspace}}/build --config Release -j ${{matrix.nproc}}
Spellcheck:
uses: oneapi-src/unified-memory-framework/.github/workflows/spellcheck.yml@main
Build:
needs: [Spellcheck, FastBuild]
uses: oneapi-src/unified-memory-framework/.github/workflows/basic.yml@main
Benchmark:
needs: [Build]
uses: oneapi-src/unified-memory-framework/.github/workflows/benchmarks.yml@main
CodeQL:
needs: [Build]
uses: oneapi-src/unified-memory-framework/.github/workflows/codeql.yml@main
2 changes: 1 addition & 1 deletion .github/workflows/spellcheck.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: SpellCheck

on: [push, pull_request, workflow_call]
on: workflow_call

jobs:
build:
Expand Down