Skip to content

Commit ce78796

Browse files
authored
Merge pull request #754 from mrava87/ci-fixptx
CI: fix self-hosted cupy action
2 parents 6d076f4 + ab2ffbf commit ce78796

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

.github/workflows/buildcupy.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,27 @@ jobs:
2828
--extra deep-cu128 --all-groups
2929
'
3030
echo "done!"
31+
- name: Install CUDA 12.8 toolkit
32+
run: |
33+
srun --account=yuxilab -n 1 -N 1 --gres=gpu:L40S:1 bash -c '
34+
# Currently, the NVIDIA GPU drivers on the self-hosted runner
35+
# and the CUDA installation in CUDA_HOME require different PTX versions
36+
# (8.7 and 8.8, respectively). CUDA and NVCC are temporarely
37+
# installed in the uv environment, and the CUDA paths are set in
38+
# the test command, to work around this issue.
39+
uv add nvidia-cuda-nvcc-cu12==12.8.*
40+
# Numba resolves libNVVM via CUDA_HOME and needs a versioned
41+
# libnvvm.so.N (the pip wheel only ships a bare libnvvm.so), so
42+
# add the symlink once here against the wheel-provided toolkit.
43+
ln -sf libnvvm.so .venv/lib/python3.11/site-packages/nvidia/cuda_nvcc/nvvm/lib64/libnvvm.so.4
44+
'
45+
echo "done!"
3146
- name: Test with pytest
3247
run: |
3348
srun --account=yuxilab -n 1 -N 1 --gres=gpu:L40S:1 bash -c '
49+
# Use the pip-installed CUDA 12.8 toolkit (matches the 12.8 driver),
50+
# not any system CUDA on the runner, so numba emits PTX <= 8.7.
51+
export CUDA_HOME="$PWD/.venv/lib/python3.11/site-packages/nvidia/cuda_nvcc"
3452
export CUPY_PYLOPS=1
3553
export TEST_CUPY_PYLOPS=1
3654
uv run pytest --color=yes pytests/

0 commit comments

Comments
 (0)