Skip to content
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
20 changes: 15 additions & 5 deletions .github/workflows/build_mlir_python_bindings_wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ jobs:
contents: write

env:
# Secrets aren't available to PRs from forks; skip what needs the payload then.
HAS_PAYLOAD: ${{ secrets.MLIR_PYTHON_BINDINGS_PAYLOAD != '' }}
# either the PR number or `branch-N` where N always increments
cache-key: mlir_python_bindings_${{ matrix.name }}_clang_${{ format('{0}-{1}', github.ref_name, github.run_number) }}

Expand Down Expand Up @@ -221,10 +223,14 @@ jobs:
fi
if [[ "${{ matrix.os }}" == "macos" ]]; then
brew install antlr boost libarchive
wget -q https://github.com/llvm/eudsl/releases/download/mlir-python-bindings/Payload.zip
unzip -qqP "${{ secrets.MLIR_PYTHON_BINDINGS_PAYLOAD }}" Payload.zip
cat Payload | gunzip | cpio -i
sudo ditto usr /usr
# Secrets aren't available to PRs from forks; build without libmetalirconverter
# (and so without the DXIL extension) then.
if [[ "$HAS_PAYLOAD" == "true" ]]; then
wget -q https://github.com/llvm/eudsl/releases/download/mlir-python-bindings/Payload.zip
unzip -qqP "${{ secrets.MLIR_PYTHON_BINDINGS_PAYLOAD }}" Payload.zip
cat Payload | gunzip | cpio -i
sudo ditto usr /usr
fi
fi

if [[ "${{ matrix.target-arch }}" == "wasm32" ]]; then
Expand Down Expand Up @@ -394,6 +400,10 @@ jobs:
run:
shell: bash

env:
# Secrets aren't available to PRs from forks; skip what needs the payload then.
HAS_PAYLOAD: ${{ secrets.MLIR_PYTHON_BINDINGS_PAYLOAD != '' }}

steps:
- name: "Check out repository"
uses: actions/checkout@v5.1.0
Expand Down Expand Up @@ -444,7 +454,7 @@ jobs:
python -W "error:The global interpreter lock (GIL) has been enabled:RuntimeWarning" multithreaded_tests.py

- name: "Test DXIL matmul"
if: matrix.runs-on == 'macos-15'
if: matrix.runs-on == 'macos-15' && env.HAS_PAYLOAD == 'true'
run: |

wget -q https://github.com/llvm/eudsl/releases/download/mlir-python-bindings/Payload.zip
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/build_test_release_eudsl_python_extras.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,10 @@ jobs:
run:
shell: bash

env:
# Secrets aren't available to PRs from forks; skip what needs the payload then.
HAS_PAYLOAD: ${{ secrets.MLIR_PYTHON_BINDINGS_PAYLOAD != '' }}

steps:
- name: "Check out repository"
uses: actions/checkout@v5.1.0
Expand Down Expand Up @@ -218,7 +222,7 @@ jobs:
fi

- name: "Test DXIL matmul"
if: matrix.runs-on == 'macos-15'
if: matrix.runs-on == 'macos-15' && env.HAS_PAYLOAD == 'true'
run: |

wget -q https://github.com/llvm/eudsl/releases/download/mlir-python-bindings/Payload.zip
Expand Down
Loading