99
1010jobs :
1111 build :
12- name : Build kernels
12+ name : Build kernels (${{ matrix.arch }})
13+ strategy :
14+ matrix :
15+ include :
16+ - arch : x86_64-linux
17+ runner : aws-highmemory-32-plus-nix
18+ - arch : aarch64-linux
19+ runner : aws-r8g-8xl-plus-nix
1320 runs-on :
14- group : aws-highmemory-32-plus-nix
21+ group : ${{ matrix.runner }}
1522 steps :
1623 - uses : actions/checkout@v6
1724 - uses : DeterminateSystems/nix-installer-action@main
@@ -30,27 +37,27 @@ jobs:
3037 run : nix-shell -p nix-info --run "nix-info -m"
3138
3239 - name : Build relu kernel
33- run : ( cd builder/examples/relu && nix build .\#redistributable.torch29-cxx11-cu126-x86_64-linux )
40+ run : ( cd builder/examples/relu && nix build .\#redistributable.torch29-cxx11-cu126-${{ matrix.arch }} )
3441 - name : Copy relu kernel
3542 run : cp -rL builder/examples/relu/result relu-kernel
3643
3744 - name : Build extra-data kernel
38- run : ( cd builder/examples/extra-data && nix build .\#redistributable.torch29-cxx11-cu126-x86_64-linux )
45+ run : ( cd builder/examples/extra-data && nix build .\#redistributable.torch29-cxx11-cu126-${{ matrix.arch }} )
3946 - name : Copy extra-data kernel
4047 run : cp -rL builder/examples/extra-data/result extra-data
4148
4249 - name : Build relu kernel (CPU)
43- run : ( cd builder/examples/relu && nix build .\#redistributable.torch29-cxx11-cpu-x86_64-linux )
50+ run : ( cd builder/examples/relu && nix build .\#redistributable.torch29-cxx11-cpu-${{ matrix.arch }} )
4451 - name : Copy relu kernel (CPU)
4552 run : cp -rL builder/examples/relu/result relu-kernel-cpu
4653
4754 - name : Build cutlass GEMM kernel
48- run : ( cd builder/examples/cutlass-gemm && nix build .\#redistributable.torch29-cxx11-cu126-x86_64-linux )
55+ run : ( cd builder/examples/cutlass-gemm && nix build .\#redistributable.torch29-cxx11-cu126-${{ matrix.arch }} )
4956 - name : Copy cutlass GEMM kernel
5057 run : cp -rL builder/examples/cutlass-gemm/result cutlass-gemm-kernel
5158
5259 - name : Build relu-backprop-compile kernel
53- run : ( cd builder/examples/relu-backprop-compile && nix build .\#redistributable.torch29-cxx11-cu126-x86_64-linux )
60+ run : ( cd builder/examples/relu-backprop-compile && nix build .\#redistributable.torch29-cxx11-cu126-${{ matrix.arch }} )
5461 - name : Copy relu-backprop-compile kernel
5562 run : cp -rL builder/examples/relu-backprop-compile/result relu-backprop-compile-kernel
5663
@@ -59,10 +66,10 @@ jobs:
5966 run : ( cd builder/examples/relu-specific-torch && nix build . )
6067
6168 - name : Build relu kernel (compiler flags)
62- run : ( cd builder/examples/relu-compiler-flags && nix build .\#redistributable.torch29-cxx11-cu126-x86_64-linux )
69+ run : ( cd builder/examples/relu-compiler-flags && nix build .\#redistributable.torch29-cxx11-cu126-${{ matrix.arch }} )
6370
6471 - name : Test that we can build a test shell (e.g. that gcc corresponds to CUDA-required)
65- run : ( cd builder/examples/relu && nix build .#devShells.x86_64-linux .test )
72+ run : ( cd builder/examples/relu && nix build .#devShells.${{ matrix.arch }} .test )
6673
6774 - name : Build silu-and-mul kernel
6875 run : ( cd builder/examples/silu-and-mul && nix build .\#redistributable.torch-cuda )
7279 - name : Upload kernel artifacts
7380 uses : actions/upload-artifact@v6
7481 with :
75- name : built-kernels
82+ name : built-kernels-${{ matrix.arch }}
7683 path : |
7784 activation-kernel
7885 cutlass-gemm-kernel
93100 - name : Download kernel artifacts
94101 uses : actions/download-artifact@v7
95102 with :
96- name : built-kernels
103+ name : built-kernels-x86_64-linux
97104 path : .
98105
99106 - name : Set up Docker Buildx
0 commit comments