This PR updates to aspects of the CI to fix blocked PRs:

It moves the Bazel CI into its own set of actions, so failure can be isolated from other tasks.
Updates the clang-cl version used in CI for self-vendored build as it was failing with the default.
This commit is contained in:
Matthew Parkinson
2025-06-30 13:57:07 +01:00
committed by GitHub
parent 0064c01b82
commit 16d96b9f8c

View File

@@ -107,6 +107,19 @@ jobs:
mkdir libs
cp libsnmallocshim*.so libs
for lib in `ls libs`; do echo; echo Testing $lib; ninja clean; LD_PRELOAD=libs/$lib ninja libsnmallocshim.so; done
bazel:
strategy:
matrix:
# Build each combination of OS and release/debug variants
os: [ "ubuntu-24.04", "ubuntu-22.04", "macos-13", "macos-14", "macos-15" ]
build-type: [ "Release", "Debug" ]
# Don't abort runners if a single one fails
fail-fast: false
runs-on: ${{ matrix.os }}
name: Bazel - ${{ matrix.os }} ${{ matrix.build-type }}
steps:
- uses: actions/checkout@v4
- uses: bazelbuild/setup-bazelisk@v3
- name: Mount bazel cache # Optional
uses: actions/cache@v4
@@ -115,6 +128,8 @@ jobs:
key: bazel
- run: bazel build -c opt //:snmalloc
- run: bazel build -c opt //:snmalloc-rs
- run: bazel test -c opt --config=asan //fuzzing:snmalloc_fuzzer
if: ${{ matrix.os != 'macos-13' && matrix.os != 'macos-14' && matrix.os != 'macos-15' }}
# If this looks remarkably familiar, that's because it is. Sigh.
macos:
@@ -159,15 +174,6 @@ jobs:
mkdir libs
cp libsnmallocshim*.so libs
for lib in `ls libs`; do echo; echo Testing $lib; ninja clean; LD_PRELOAD=libs/$lib ninja libsnmallocshim.so; done
- uses: bazelbuild/setup-bazelisk@v3
- name: Mount bazel cache # Optional
uses: actions/cache@v4
with:
path: "~/.cache/bazel"
key: bazel
- run: bazel build -c opt //:snmalloc
- run: bazel build -c opt //:snmalloc-rs
# GitHub doesn't natively support *BSD, but we can run them in VMs on Mac /
# Linux runners
@@ -503,13 +509,6 @@ jobs:
run: cmake --build ${{github.workspace}}/build --target snmalloc-fuzzer
- name: Test
run: ${{github.workspace}}/build/fuzzing/snmalloc-fuzzer
- uses: bazelbuild/setup-bazelisk@v3
- name: Mount bazel cache # Optional
uses: actions/cache@v4
with:
path: "~/.cache/bazel"
key: bazel
- run: bazel test -c opt --config=asan //fuzzing:snmalloc_fuzzer
self-vendored:
strategy:
@@ -535,6 +534,7 @@ jobs:
- name: Prepare Windows
if: runner.os == 'Windows'
run: |
choco upgrade llvm
choco install ninja
- name: Prepare macOS
if: runner.os == 'macOS'