Skip to content

feat: CUDA Q2_0 support (Bonsai-27B ternary/binary on Qwen3.6 arch) - #2

Merged
thecodacus merged 2 commits into
perffrom
fable5/cuda-q2_0
Jul 18, 2026
Merged

feat: CUDA Q2_0 support (Bonsai-27B ternary/binary on Qwen3.6 arch)#2
thecodacus merged 2 commits into
perffrom
fable5/cuda-q2_0

Conversation

@thecodacus

Copy link
Copy Markdown
Owner

Carries upstream PR ggml-org#25707 (CUDA Q2_0, authored by PrismML's khosravipasha) onto perf, enabling PrismML's Bonsai-27B family (Qwen3.6-derived, qwen35 arch — already registered upstream) to run on CUDA. No PrismML fork code is carried: Q1_0/Q2_0 CPU+Metal are already in mainline (which perf tracks); this adds the last missing piece, CUDA Q2_0, from the maintainer's own upstream PR. When ggml-org#25707 merges upstream, a routine perf sync deduplicates it.

Format note: upstream Q2_0 uses group-size 64 (18-byte block). PrismML publishes matching ggufs as *_Q2_g64.gguf alongside their older fork-format group-128 files. Use the g64 variant — the group-128 file will not load (block-size mismatch, verified: 420 MB overrun).

Verified on RTX 3060 (full offload, -ngl 99 -fa 1):

Model Quant Weights pp512 t/s tg128 t/s
Bonsai-27B (binary) Q1_0 3.53 GiB 596 37.2
Ternary-Bonsai-27B Q2_0 (g64) 7.05 GiB 534 22.5

Both generate coherent text (e.g. ternary Q2_0: "The capital of France is → Paris."). Q2_0 CUDA output matches the CPU codec.

6GB-card reality (these are dense models, no MoE offload): the 3.53 GiB binary fits a 6GB card fully offloaded with room for KV; the 7.05 GiB ternary needs ~8GB fully offloaded, or partial CPU offload on 6GB.

@thecodacus
thecodacus merged commit 9338207 into perf Jul 18, 2026
12 of 31 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants