Skip to content

Commit

Permalink
Use contains to get PR labels, not event
Browse files Browse the repository at this point in the history
  • Loading branch information
rengolin committed Feb 10, 2025
1 parent 8eae574 commit 6b6c07b
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions .github/workflows/tpp-benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
inputs:
RUN_EMR_BENCH:
description: "Run on Emerald Rapids"
default: "1"
default: "0"
RUN_ZEN_BENCH:
description: "Run on Zen5"
default: "0"
Expand All @@ -16,7 +16,7 @@ on:
branches:
- 'main'
pull_request:
types: [ labeled, opened, edited, reopened ]
types: [ labeled, opened, edited ]

env:
NPROCS_LIMIT_LINK: 8
Expand All @@ -26,17 +26,17 @@ env:
jobs:
Check_LLVM:
if: ${{ github.event_name }} == "push" || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark' }}) || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark') || \
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
uses: ./.github/workflows/tpp-llvm.yml
secrets: inherit

TPP-MLIR-EMR-BASE:
runs-on: pcl-tiergarten
if: ${{ github.event_name }} == "push" || \
${{ inputs.RUN_EMR_BENCH }} == 1 || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark' }}) || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark') || \
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
needs: Check_LLVM
steps:
- uses: actions/checkout@v4
Expand All @@ -50,8 +50,8 @@ jobs:
runs-on: pcl-tiergarten
if: ${{ github.event_name }} == "push" || \
${{ inputs.RUN_EMR_BENCH }} == 1 || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark' }}) || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark') || \
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
needs: Check_LLVM
steps:
- uses: actions/checkout@v4
Expand All @@ -65,7 +65,7 @@ jobs:
runs-on: pcl-tiergarten
if: ${{ github.event_name }} == "push" || \
${{ inputs.RUN_ZEN_BENCH }} == 1 || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
needs: Check_LLVM
steps:
- uses: actions/checkout@v4
Expand All @@ -79,7 +79,7 @@ jobs:
runs-on: pcl-tiergarten
if: ${{ github.event_name }} == "push" || \
${{ inputs.RUN_ZEN_BENCH }} == 1 || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
needs: Check_LLVM
steps:
- uses: actions/checkout@v4
Expand All @@ -93,7 +93,7 @@ jobs:
runs-on: pcl-tiergarten
if: ${{ github.event_name }} == "push" || \
${{ inputs.RUN_CLX_BENCH }} == 1 || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
needs: Check_LLVM
steps:
- uses: actions/checkout@v4
Expand All @@ -107,7 +107,7 @@ jobs:
runs-on: pcl-tiergarten
if: ${{ github.event_name }} == "push" || \
${{ inputs.RUN_CLX_BENCH }} == 1 || \
(${{ github.event_name }} == "pull_request" && ${{ github.event.label.name == 'benchmark-all' }})
(${{ github.event_name }} == "pull_request" && contains(github.event.pull_request.labels.*.name, 'benchmark-all'))
needs: Check_LLVM
steps:
- uses: actions/checkout@v4
Expand Down

0 comments on commit 6b6c07b

Please sign in to comment.