You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG]: Linker raises FunctionNotFoundError instead of falling back to the driver when nvJitLink < 12.3 is installed #2408
With a CUDA 12.0 nvJitLink in the environment (nvidia-nvjitlink-cu12==12.0.140), Linker.which_backend() — and constructing a Linker — raises
cuda.bindings._internal.utils.FunctionNotFoundError: function nvJitLinkVersion is not found
instead of warning and falling back to the driver (cuLink) backend.
This is a regression: cuda-core 0.6.0 emitted the "nvJitLink is too old (<12.3)" RuntimeWarning and fell back to the driver. The behavior broke in 0.7.0 and is still present in 1.1.0 (verified with the same cuda-bindings and nvJitLink versions in all three environments).
Root cause: nvJitLink 12.0–12.2 export only versioned symbols (__nvJitLink*_12_X); the unversioned nvJitLinkVersion export was added in 12.3. cuda-core >= 0.7.0 probes availability via cuda.pathfinder._optional_cuda_import("cuda.bindings.nvjitlink", probe_function=lambda m: m.version()), but _optional_cuda_import only forgives DynamicLibNotFoundError, so the FunctionNotFoundError raised by version() escapes instead of triggering the fallback. 0.6.0 inspected the symbol pointer (_inspect_function_pointer("__nvJitLinkVersion")) rather than calling the function, which handled this correctly.
Note that import is unaffected (import cuda.core and from cuda.core import Linker succeed); the exception fires whenever the backend decision actually runs. Also note that on 12.0–12.2 cuda.bindings.nvjitlink is unusable across the board (every unversioned symbol lookup fails, not just version()), so falling back is the only viable behavior on those versions.
File "cuda/bindings/cynvjitlink.pyx", line 67, in cuda.bindings.cynvjitlink.nvJitLinkVersion
File "cuda/bindings/_internal/nvjitlink.pyx", line 405, in cuda.bindings._internal.nvjitlink._nvJitLinkVersion
cuda.bindings._internal.utils.FunctionNotFoundError: function nvJitLinkVersion is not found
Verified via /proc/self/maps that the venv's 12.0 libnvJitLink.so is the only nvJitLink mapped into the process (no system library involved). Replacing cuda-core==1.1.0 with 0.6.0 in the same environment produces the expected warning + fallback; 0.7.0 reproduces the crash.
Expected behavior
Linker.which_backend() returns "driver" (with the "nvJitLink is too old (<12.3)" RuntimeWarning), and a Linker constructed in this environment uses the cuLink backend — matching cuda-core 0.6.0.
I've added repro steps, a fix, and regression tests. The PR is currently waiting on maintainer metadata (assignee, \�ug\ label, milestone) and external contributor workflow approval.
Happy to make any changes you suggest. Thanks for filing the issue!
Activity
atiaomar1978-hub commentedon Jul 23, 2026
Independent reproduction + fix PR
Reproduced this on Windows x86_64 (no NVIDIA GPU):
Linker.which_backend()raises the sameFunctionNotFoundError: function nvJitLinkVersion is not found.With cuda-core 0.6.0 in the same environment, backend selection succeeds (falls back to driver).
Opened PR with fix: #2409
test(cuda.core): add coverage for nvJitLink <12.3 driver fallback
atiaomar1978-hub commentedon Jul 23, 2026
Hi @NaderAlAwar — friendly ping on PR #2409 for this regression.
I've added repro steps, a fix, and regression tests. The PR is currently waiting on maintainer metadata (assignee, \�ug\ label, milestone) and external contributor workflow approval.
Happy to make any changes you suggest. Thanks for filing the issue!
fix(cuda.core): fall back to driver when nvJitLink < 12.3 is installed
test(cuda.core): add coverage for nvJitLink <12.3 driver fallback
docs(cuda.core): add 1.2.0 release note for nvJitLink <12.3 fallback fix
fix(cuda.core): probe nvJitLink version under DynamicLibNotFoundError…
fix(cuda.core): use explicit try/except for nvJitLink version probe
fix(cuda.core): fall back to driver when nvJitLink < 12.3 is installed
test(cuda.core): add coverage for nvJitLink <12.3 driver fallback
docs(cuda.core): add 1.2.0 release note for nvJitLink <12.3 fallback fix
fix(cuda.core): probe nvJitLink version under DynamicLibNotFoundError…
fix(cuda.core): use explicit try/except for nvJitLink version probe
fix(cuda.core): fall back to driver when nvJitLink < 12.3 is installed (
Prepare for 13.4.1 release (#2788)
Pull 13.4.1 changes into main (#2789)