ci: build the Windows CUDA path (nvcc + MSVC host) — the one toolchain no job covers#327
Merged
Merged
Conversation
…n no job covers engine-cuda-syntax compiles backend_cuda.cu with nvcc's GCC host on Linux, and check.yml's windows job is MinGW/UCRT64 CPU-only by design (JustVugg#140). Neither exercises nvcc's MSVC host — the only host compiler nvcc accepts on Windows — so `make cuda-dll` and `make glm CUDA_DLL=1` are currently built by nothing. The gap has already cost real bugs, all compile-time, all catchable without a GPU: - JustVugg#158: MSVC rejects the GCC-style -Xcompiler=-Wall,-Wextra ("D8021 invalid numeric argument '/Wextra'"), CUDA_HOME/NVCC defaults were unresolvable, and the kernel test used POSIX setenv. `make cuda-dll` was unbuildable as shipped. - JustVugg#314: CUDA_HOME containing spaces — the CUDA installer's default layout. This job installs to exactly that path, so it reproduces the condition by default. Two Windows-specific facts the job encodes, both verified by making it fail first: - sub-packages needs "cudart", not just "nvcc": cuda-dll *links* the runtime, and on Windows the headers/import lib are a separate installer component. With '["nvcc"]' alone it dies at `#include <cuda_runtime.h>` — the Linux syntax job never notices because it only compiles. - runs-on is pinned to windows-2022: windows-latest now ships Visual Studio 18 (MSVC 14.5x) and CUDA's crt/host_config.h hard-errors on any host newer than VS 2022. That is a real constraint on every Windows CUDA user today, so the pin tracks what the toolkit supports rather than papering over it with -allow-unsupported-compiler. Build-only on purpose: hosted runners have no NVIDIA device, so this proves the Windows+MSVC CUDA build stays buildable, not that the kernels or the DLL loader behave on real silicon — that still needs hardware (JustVugg#157). A check that overclaims buys the false confidence the engine-cuda-syntax comment already warns about. Verified green on a fork before proposing: https://github.com/lEWFkRAD/colibri/actions/runs/29524302993 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #157 — closing the gap rather than just reporting it.
engine-cuda-syntaxcompilesbackend_cuda.cuwith nvcc's GCC host on Linux, andcheck.yml's windows job is MinGW/UCRT64 CPU-only by design (#140). Neither exercises nvcc's MSVC host — the only host compiler nvcc accepts on Windows — somake cuda-dllandmake glm CUDA_DLL=1are built by nothing in CI today.That gap has already cost real bugs, and every one was compile-time, catchable with no GPU present:
-Xcompiler=-Wall,-Wextra(D8021 invalid numeric argument '/Wextra'),CUDA_HOME/NVCCdefaults were unresolvable, kernel test used POSIXsetenv.make cuda-dllwas unbuildable as shipped.CUDA_HOMEcontaining spaces, i.e. the CUDA installer's default path. This job installs to exactly that layout, so it reproduces that condition by default rather than by luck.Two Windows facts the job encodes — both found by making it fail first, not by reading docs:
sub-packagesneeds"cudart", not just"nvcc".cuda-dlllinks the runtime, and on Windows the headers/import lib ship as a separate installer component. With'["nvcc"]'alone it dies at#include <cuda_runtime.h>. The Linux syntax job never notices because it only compiles.runs-on: windows-2022, notwindows-latest. The latest image now ships Visual Studio 18 (MSVC 14.5x), and CUDA'scrt/host_config.hhard-errors on any host newer than VS 2022 ("Only the versions between 2017 and 2022 (inclusive) are supported"). That's a live constraint on every Windows CUDA user right now, so the pin tracks what the toolkit actually supports.-allow-unsupported-compilerwould only mask it.Build-only on purpose. Hosted runners have no NVIDIA device, so this proves the Windows+MSVC CUDA build stays buildable — not that the kernels or the DLL loader behave on real silicon. That still needs hardware (the sm_120 matrix in #157). I kept the scope explicit in the comments because a check that overclaims buys exactly the false confidence the
engine-cuda-syntaxcomment already warns about.It goes in
ci.ymlrather thancheck.ymldeliberately —check.ymlpromises "no model downloads, no CUDA, no external deps — by design (#140)", and this needs an external toolkit action. Not going to break that contract.Verified green on my fork before opening this, so it isn't landing in your queue untested: https://github.com/lEWFkRAD/colibri/actions/runs/29524302993
Adds ~2 min to CI (the toolkit install dominates). Happy to gate it to paths (
c/backend_cuda.*,c/backend_loader.c,c/Makefile) if you'd rather it not run on every PR — say which and I'll adjust.