From 97b2d4f96bb6a1067938eb8077596522641b5bab Mon Sep 17 00:00:00 2001 From: "Li, Ian" Date: Wed, 18 Sep 2024 17:31:39 -0700 Subject: [PATCH] exit on error --- .github/workflows/sycl-linux-benchmark.yml | 1 - devops/scripts/benchmarking/benchmark.sh | 4 +++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sycl-linux-benchmark.yml b/.github/workflows/sycl-linux-benchmark.yml index 428142fd4ce4e..040fb31969d4c 100644 --- a/.github/workflows/sycl-linux-benchmark.yml +++ b/.github/workflows/sycl-linux-benchmark.yml @@ -242,7 +242,6 @@ jobs: ls export CMPLR_ROOT=$PWD/toolchain ./devops/scripts/benchmarking/benchmark.sh ${{ inputs.cache_results == true && '-s' }} - echo $? - name: Push compute-benchmarks if: inputs.cache_results == true && success() env: diff --git a/devops/scripts/benchmarking/benchmark.sh b/devops/scripts/benchmarking/benchmark.sh index 7fbabda307072..07d3950dd2b06 100755 --- a/devops/scripts/benchmarking/benchmark.sh +++ b/devops/scripts/benchmarking/benchmark.sh @@ -147,7 +147,9 @@ process_results() { cat "$BENCHMARK_ERROR_LOG" echo "" fi - [ ! -s "$BENCHMARKING_SLOW_LOG" ] && [ ! -s "$BENCHMARK_ERROR_LOG" ] + if [ -s "$BENCHMARKING_SLOW_LOG" ] || [ -s "$BENCHMARK_ERROR_LOG" ]; then + exit 1 + fi } cleanup() {