bug: Backend auto-selection ignores the detected compute capability and defaults new installs to a CUDA 13 build that cannot run on Pascal GPUs
Version: v0.8.4 OS: Windows 11 IoT Enterprise LTSC 2024 (10.0.26100)
Describe the Bug
On a fresh install, Jan selects win-cuda-13-common_cpus-x64 as the "best available backend" and uses it as the default, even though Jan's own hardware probe has already recorded that this machine's GPU is compute capability 6.1 (Pascal). The CUDA 13 backend is built only for CMAKE_CUDA_ARCHITECTURES='75;80;86;87;89;120;121' (per #6979), so it contains no kernel image for sm_61 and every model load dies at startup.
The hardware is not the problem, and neither is the driver. Selecting win-cuda-12-common_cpus-x64 — already present in the very same dropdown, same version tag b9967, same GPU, same model file — works immediately.
This is not a request to re-add Pascal to the CUDA 13 build
I understand that dropping sm_50–sm_70 from the CUDA 13 binaries is intentional, and that #6979 is closed on that basis. I'm not asking for that to change.
The defect I'm reporting is in the selection logic: Jan collects the compute capability, then picks a backend that provably cannot execute on the reported device, with no capability check and no fallback — on the default path, for every fresh install of an affected machine.
Evidence
1. Jan records compute capability 6.1
From settings.json → setting-hardware, written by Jan's own probe:
"gpus": [{
"name": "NVIDIA GeForce GTX 1080",
"total_memory": 8192,
"vendor": "NVIDIA",
"driver_version": "582.66",
"nvidia_info": { "index": 0, "compute_capability": "6.1" },
"vulkan_info": { "index": 0, "device_type": "DiscreteGpu", "api_version": "1.4.312" },
"activated": false
}]2. Selection picks the CUDA 13 build anyway, on the fresh-install path
[2026-09-28][16:57:49][tauri_plugin_llamacpp::backend][INFO] Determined best available backend: b9967/win-cuda-13-common_cpus-x64 (Category: "cuda-cu13.0")
[2026-09-28][16:57:49][webview:...][INFO] Initial UI defaults: llamacpp_version='b9967', llamacpp_backend='win-cuda-13-common_cpus-x64'
[2026-09-28][16:57:49][webview:...][INFO] Fresh installation or invalid backend detected, using: b9967/win-cuda-13-common_cpus-x64The GPU is also enumerated correctly at this point, so this isn't a detection failure:
Available devices:
CUDA0: NVIDIA GeForce GTX 1080 (8191 MiB, 7185 MiB free)3. Model load fails, with a raw CUDA error and no actionable message
[59865] 0.02.758.488 E CUDA error: no kernel image is available for execution on the device
[59865] C:\w\llama.cpp\llama.cpp\ggml\src\ggml-cuda\ggml-cuda.cu:104: CUDA error
...
{"code":"INTERNAL_ERROR","details":"exit_code=Some(99)","message":"Model Jan-v3.5-4B-Q4_K_XL failed to load"}The user sees "GGML backend encountered an error" in the UI. Nothing in the surfaced message points at the GPU architecture or suggests another backend.
4. Same machine, same model, same driver, backend from the same dropdown → works
After switching only the backend preference to win-cuda-12-common_cpus-x64:
[2026-09-28][17:21:58][webview:...][INFO] Backend b9967/win-cuda-12-common_cpus-x64 dependency verification passed (16 libraries resolved)
...
I slot print_timing: id 0 | task 21 | eval time = 2296.82 ms / 96 tokens (23.93 ms per token, 41.80 tokens per second)No configuration change other than the backend was required. This is a direct A/B: identical driver (582.66), identical model file, identical version tag b9967 — one backend works, the other cannot launch a single kernel.
Why this needs a fix rather than a workaround
- It's the default path, not an edge case. Every fresh install on a pre-Turing NVIDIA GPU lands on the broken backend before the user has configured anything.
- A working backend ships in the same release.
win-cuda-11-common_cpus-x64andwin-cuda-12-common_cpus-x64are published asb9967assets alongside the CUDA 13 build. No extra download, no extra maintenance. - "Auto update engine" re-selects it. The
best availablelogic ranks by CUDA version category only (Category: "cuda-cu13.0") and doesn't consult device capability, so the next engine update can re-select an incompatible build even after a user manually chose a working one.
Suggested fix
Either of these would resolve it, and either is small:
- Filter at selection time — have
determine best available backendskip any backend whose supported architecture list excludes the detectedcompute_capability, falling back to the next-highest compatible CUDA build (or Vulkan). - Fail over on launch failure — if the server exits with a CUDA
no kernel image is availableerror during startup, automatically retry with the next compatible backend and surface a message like "GPU architecture not supported by this backend — switched to X" instead ofGGML backend encountered an error.
Option 2 also covers users who already have a stored preference and covers backend/driver combinations that weren't known at install time.
Additional note (possibly separate)
After setting the stored preference to win-cuda-12-common_cpus-x64, the following startup line reports a different backend name:
[INFO] Using stored backend preference: b9967/win-avx-cuda-cu12.0-x64while the server that actually gets launched is the win-cuda-12-common_cpus-x64 one. This looks like a legacy backend-key mapping that may be unrelated to this issue — flagging it in case it's the same code path.
Environment
| Jan | v0.8.4 |
| OS | Windows 11 IoT Enterprise LTSC 2024 (10.0.26100) |
| GPU | NVIDIA GeForce GTX 1080, 8192 MiB, compute capability 6.1 (Pascal) |
| Driver | 582.66 (nvidia-smi reports CUDA 13.0) |
| llama.cpp | b9967 |
| Model | Jan-v3.5-4B-Q4_K_XL |
| CPU / RAM | i5-4590 / 32 GB |
Source: janhq/jan