Skip to content

kernels: use Metadata from kernels-data (#499) #978

kernels: use Metadata from kernels-data (#499)

kernels: use Metadata from kernels-data (#499) #978

name: "Build and test kernel (XPU)"
on:
push:
branches: [main]
pull_request:
branches: [main]
types: [opened, synchronize, reopened] # trigger on PRs
paths-ignore:
- "docs/**"
- "*.md"
workflow_dispatch:
jobs:
build:
name: Build kernel
runs-on:
group: aws-highmemory-32-plus-nix
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: DeterminateSystems/nix-installer-action@ef8a148080ab6020fd15196c2084a2eea5ff2d25
with:
extra-conf: |
max-jobs = 4
cores = 12
sandbox-fallback = false
- uses: cachix/cachix-action@1eb2ef646ac0255473d23a5907ad7b04ce94065c # v17
with:
name: huggingface
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
env:
USER: runner
- name: Nix info
run: nix-shell -p nix-info --run "nix-info -m"
# For now we only test that there are no regressions in building XPU
# kernels. Also run tests once we have a XPU runner.
- name: Build relu kernel
run: ( cd examples/kernels/relu && nix build .\#redistributable.torch210-cxx11-xpu20253-x86_64-linux -L )
- name: Build relu tvm-ffi kernel
run: ( cd examples/kernels/relu-tvm-ffi && nix build .\#redistributable.tvm-ffi01-xpu20253-x86_64-linux -L )
- name: Build relu kernel (compiler flags)
run: ( cd examples/kernels/relu-compiler-flags && nix build .\#redistributable.torch210-cxx11-xpu20253-x86_64-linux )
- name: Build cutlass-gemm kernel
run: ( cd examples/kernels/cutlass-gemm && nix build .\#redistributable.torch210-cxx11-xpu20253-x86_64-linux -L )