What this thread does
As of November 2026, q8_0 remains a suggested memory-saving starting point, not a quality guarantee; llama.cpp still defaults to f16 for both caches. Do first: compare your long-context reasoning tasks with f16 before lowering precision. llama.cpp options.
The question
How much VRAM can you save by quantizing the KV cache of a local 27B model, and what do you lose? An r/LocalLLaMA post (imgroot9) compared Qwen3.6-27B at Q5_K_M weights on a single RTX 3090, comparing f16, q8_0, q4_0 and two TurboQuant 3/4-bit cache types (those need a separate llama.cpp fork build). The author separately reports using a 200k context for inference. The poster is new to local models and says they used an AI assistant to format the write-up.
What the poster measured
- Method:
llama-perplexityon wikitext, then again with the--cache-type-kand--cache-type-voptions set to each type. - Result: perplexity differences were tiny (about 6.92 for f16 and q8_0, about 6.94 for q4_0, about 7.01 for the 3-bit type), and a KL-divergence run agreed. Their first conclusion was that q4 is almost free on dense models above 20B.
- A later edit walks that back: after a commenter pointed out the problem (below), the poster ran a small AIME and ARC check. AIME scores were low and noisy for every type, including q8_0 and f16, so they say they have no firm conclusion and will keep using the 3-4 bit type for now. They also report loops with a 35B mixture-of-experts model at 3-bit cache.
What commenters said
- A comment says perplexity and KLD are poor guides to KV-quantization damage, that q4 shows minimal loss on both yet drops sharply on AIME even after a llama.cpp change that improved it, and links the pull request.
- Another commenter cites a SGLang table against 4-bit KV. The current SGLang reference concerns FP8 and FP4 E2M1 formats, not llama.cpp
q8_0andq4_0. Its preliminary table shows workload-dependent FP4 losses, especially on reasoning tasks; it does not establish a universal quality ranking for these llama.cpp cache types. - A commenter said q8 is much less harmful in recent llama.cpp builds than it used to be; compare your own version.
- A short wikitext perplexity run does not establish long-context reasoning quality; compare those tasks separately.
How to read it
Consider q8_0 as a starting point if you need to save VRAM, and treat q4 and 3-bit types as something to test on your own long-context and reasoning tasks first. The poster's perplexity numbers alone do not show that q4 is safe. A cheap check is the hidden-fact test from the post: bury one odd sentence deep in a long prompt and ask for it back, at the context size you actually use.
This is about the KV cache; the choice of weight quantization (Q4_K_M vs Q8 weights) is a separate topic covered by the gguf quant-level thread.
Sources
- Original comparison and edits: one user’s measurements and comments.
- llama.cpp server options: cache flags, accepted types and f16 defaults.
- Activation-rotation PR and SGLang quantized KV cache: different implementations and workload-dependent quality evidence.
Started from a post by @imgroot9, packaged by the editor. Original post