Skip to content

Commit

Permalink
Update the buildAndTestCMake: save core dumps
Browse files Browse the repository at this point in the history
Save core dumps for buildAndTestCMake so that we can triage failures
that occur.

Co-authored-by: Mark Williams <[email protected]>
  • Loading branch information
fzakaria and goomrw committed Mar 16, 2024
1 parent dc4bc72 commit 61453df
Showing 1 changed file with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions .github/workflows/buildAndTestCMake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,16 @@ jobs:
env:
CMAKE_BUILD_TYPE: Release
MLIR_ENABLE_BINDINGS_PYTHON: ON

- name: Setup Core Dumps
run: |
# e is the process name, p is the process id
sudo sysctl -w kernel.core_pattern="core.%e.%p"
ulimit -c unlimited
- name: Build and Test StableHLO (with AddressSanitizer)
shell: bash
run: |
./build_tools/github_actions/ci_build_cmake.sh "$LLVM_BUILD_DIR" "$STABLEHLO_BUILD_DIR"
ulimit -c unlimited # Enable core dumps to be captured (must be in same run block)
sudo ./build_tools/github_actions/ci_build_cmake.sh "$LLVM_BUILD_DIR" "$STABLEHLO_BUILD_DIR"
env:
CMAKE_BUILD_TYPE: Release
STABLEHLO_ENABLE_BINDINGS_PYTHON: OFF
Expand All @@ -89,4 +94,12 @@ jobs:
./build_tools/github_actions/ci_build_cmake.sh "$LLVM_BUILD_DIR" "$STABLEHLO_BUILD_DIR"
env:
CMAKE_BUILD_TYPE: Release
STABLEHLO_ENABLE_BINDINGS_PYTHON: ON
STABLEHLO_ENABLE_BINDINGS_PYTHON: ON

- name: Upload Core Dumps
if: always()
uses: actions/upload-artifact@v4
with:
name: crashes
path: core*
if-no-files-found: ignore

0 comments on commit 61453df

Please sign in to comment.