In this series / On this page· 5 of 9

The Draft's LM Head: What vLLM 0.33's Quantized Copy Saves at Batch 1

An MTP draft reads the full LM head for every guessed token; vLLM 0.33's quantized copy cuts that read, and a two-line formula predicts the gain.

17 min readUpdated
vLLM pull request #59973 on GitHub, merged: 'Quantized draft lm_head for drafters that share the target head', its overview claiming +18% decode at concurrency 1 and the one-line speculative config
vLLM PR #59973, the change behind the option, as merged on 15 October.Image: vLLM project, PR by stecasta

An MTP draft layer is small, but every token it guesses ends in the full LM head: on Qwen3.6-35B-A3B that is a 248,320 × 2,048 BF16 projection, 1 GB read per guess, three times per round before the target checks anything. vLLM 0.33 lets the drafter read a 4-bit copy of that head while the target keeps verifying with its own, and on that model it raised decode speed per user by 38% at concurrency 1 without moving the acceptance length. Here is what the option builds, a two-line formula that predicts the gain for your model, and when to leave it off.

The option, the number, the rule

draft_lm_head_quantization gives the drafter a private quantized copy of the target's LM head, built at load time from the same weights. The target still verifies every drafted token with its BF16 head, so the tokens you get are the target's; only the acceptance length can move. One key in the speculative config turns it on:

$ vllm serve Qwen/Qwen3.6-35B-A3B-FP8 \
    --max-model-len 16384 \
    --max-num-seqs 8 \
    --generation-config vllm \
    --no-enable-prefix-caching \
    --speculative-config '{"method": "mtp", "num_speculative_tokens": 3, "draft_lm_head_quantization": "nvfp4"}'

"nvfp4" stores the copy as E2M1 codes with an E4M3 scale per 16 values (NVFP4 on Blackwell) and runs it weight-only (W4A16, Marlin on Blackwell desktop parts); "fp8" uses per-row weight scales and per-token activation scales on the platform's FP8 kernel (FP8). The option arrived in PR #59973 and shipped in vLLM 0.33.0.

The PR reports +18% decode tok/s per user at concurrency 1 (39.4 to 46.5) on Qwen3.8-Flash-Next-NVFP4 with MTP k = 3 on one DGX Spark, SPEED-Bench, greedy, 256 output tokens, and +9 to 11% at concurrency 4. We ran the same workload on a model the PR did not: one GB10 (DGX Spark class, 128 GB unified memory), vLLM 0.33.0, Qwen/Qwen3.6-35B-A3B-FP8, MTP k = 3, SPEED-Bench qualitative, 256 output tokens, greedy (--temperature 0, server on --generation-config vllm), thinking off, prefix caching off, at most 8 sequences. The NVFP4 copy took mean TPOT from 15.59 to 11.28 ms at concurrency 1, which is +38% tok/s per user, and acceptance length went from 2.993 to 2.979.

The rule: turn on nvfp4 for an MTP or EAGLE drafter that shares a BF16 head, when you serve at low concurrency on a bandwidth-bound GPU and the vocabulary is large. Use fp8 where NVFP4 has no W4A16 kernel. Check acceptance on your own traffic once.

Why a draft step is mostly head

A speculative round at concurrency c runs k draft steps, each one the MTP layer followed by the full head on c rows, then one verify pass of the target on c × (k + 1) tokens. The head dominates the draft step because it is much larger than the draft layer. On Qwen3.6-35B-A3B-FP8, lm_head is excluded from FP8 quantization and stays BF16: 248,320 × 2,048 = 508.6 M weights, 1.02 GB. The MTP layer reads about 73 MB per token (its 8 routed experts, attention in FP8, a BF16 fc). The head is about 93% of the bytes a draft step moves, and at batch 1 decode is bound by bytes (see The Roofline for LLMs).

Measured on the same machine, the head projection alone at M = 1 takes 5.89 ms in BF16, 2.24 ms as the FP8 copy and 1.25 ms as the NVFP4 copy. Three draft steps of BF16 head are 17.7 ms of a 46.7 ms round: 38%.

Two time bars for one speculative round at concurrency 1 on Qwen3.6-35B-A3B-FP8, MTP k = 3. Stock: three BF16 head projections of 5.9 ms each plus 29.0 ms for the verify, the MTP layer and sampling, 46.7 ms in all. NVFP4 copy: three head projections of 1.25 ms each plus 29.9 ms, 33.7 ms in all.Two time bars for one speculative round at concurrency 1 on Qwen3.6-35B-A3B-FP8, MTP k = 3. Stock: three BF16 head projections of 5.9 ms each plus 29.0 ms for the verify, the MTP layer and sampling, 46.7 ms in all. NVFP4 copy: three head projections of 1.25 ms each plus 29.9 ms, 33.7 ms in all. The copy cuts the head reads by 13.9 ms per round; everything else stays at about 29-30 ms.

That gives the formula. From one run of your stock configuration and two kernel timings:

  • round = AL × TPOT (acceptance length times time per output token, both from vllm bench serve)
  • saved = k × (t_head,BF16 − t_head,quantized), both at M = c
  • new TPOT = (round − saved) / AL_quantized

For our model at concurrency 1: round = 2.991 × 15.61 = 46.7 ms, saved = 3 × (5.89 − 1.25) = 13.9 ms, predicted TPOT 11.0 ms, predicted gain +42%. Measured: +38%. The 4-point gap is the rest of the round, which grew from 29.0 to 29.9 ms with the copy; the formula assumes it stays fixed, so read its answer as a ceiling. Run on the PR's own numbers (its kernel table, its stock round), the same two lines give +17% against its measured +18%, and +28.5% against +27.1% for its earlier run before a faster BF16 GEMV landed.

Two terms decide whether the gain is large on your model:

  • How slow your stock head is. PR #59753 added skinny-GEMM plans that make a BF16 head 1.45× faster at M = 1 on SM121, but they are keyed by the exact local weight shape and installed only by the Qwen4Exp model code (low_latency_gemm.py). Every other model's head goes through UnquantizedEmbeddingMethod to a plain cuBLAS GEMM, which reads at 173 GB/s at M = 1 here. A slower baseline leaves more to save, which is part of why our gain is twice the PR's: on our shape, cuBLAS's slow single-row path alone accounts for about 13 points of the 38.
  • How long the rest of the round is. A 3B-active target verifies quickly, so the head's 17.7 ms weighs more than it does next to a larger model's verify.

Concurrency shrinks the share, but on this GPU the first step down is mostly a kernel quirk. cuBLAS reads the BF16 head at M = 1 in 5.89 ms and at M = 2 in 4.38 ms. Give the stock head its M = 2 speed at concurrency 1 and the copy is worth about +25%, not +38%. Past that, one head read serves all c rows of a draft step while the verify grows with c × (k + 1): at concurrency 4 our round is 80.4 ms and three BF16 head reads are 13.2 ms of it, so the formula predicts +12.9% and we measured +13.3%.

Shrinking the head's vocabulary attacks the same term differently. EAGLE-3 drafters ship heads with a reduced vocabulary, FR-Spec and VocabTrim keep the most frequent tokens, and Nebius's SlimSpec trains a low-rank head. Each cuts rows or rank, and each needs a frequency list or retraining and changes which tokens the draft can propose. Quantizing keeps every row and needs nothing but the target's own weights. The two compose: open PR #59740 reuses this quantizer for a sparse head. Quantizing the head the target verifies with is a different trade, since it can change outputs; it is not what this option does.

What vLLM 0.33 builds

The copy is a second ParallelLMHead that points at the target head's storage and is quantized once at load. No BF16 duplicate is kept:

# vllm/model_executor/layers/quantization/online/lm_head.py (lines 103-117, v0.33.0)
dtype = lm_head.weight.dtype
with set_default_torch_dtype(dtype):
    head = ParallelLMHead(
        lm_head.num_embeddings,
        lm_head.embedding_dim,
        params_dtype=dtype,
        org_num_embeddings=lm_head.org_vocab_size,
        padding_size=lm_head.padding_size,
        prefix=lm_head.prefix,
        disable_tp=lm_head.disable_tp,
        quant_method=_LM_HEAD_METHODS[quantization](),
    )
# Never loaded: a new param sharing the source storage, never a copy of it.
head.weight = torch.nn.Parameter(lm_head.weight.data, requires_grad=False)
head.quant_method.process_weights_after_loading(head)

The drafter loader then swaps the copy in. MTP layers compute their logits through their own shared_head.head, not the drafter's lm_head, so it patches those too:

# vllm/v1/worker/gpu/spec_decode/eagle/utils.py (lines 109-119, v0.33.0)
if target_lm_head is not None and _should_share(
    eagle_model, "has_own_lm_head", draft_lm_head, target_lm_head
):
    draft_head = target_lm_head
    if speculative_config.draft_lm_head_quantization is not None:
        draft_head = quantized_lm_head_copy(
            target_lm_head, speculative_config.draft_lm_head_quantization
        )
    if draft_lm_head is not None:
        del eagle_model.lm_head
    eagle_model.lm_head = draft_head

The next lines set the same copy as every MTP layer's shared_head.head, and raise if the drafter has its own head.

The target's head is never touched, which is why the outputs are the target's. In speculative decoding the target computes p for every drafted position and accepts or resamples against the draft's q (see Speculative Decoding from First Principles). With the default greedy drafting (draft_sample_method: greedy), q is one-hot on the token the quantized head picked; with probabilistic, q is the quantized distribution itself, the one the draft sampled from. Either way rejection sampling stays exact in distribution. A noisier head can only propose worse guesses, which shows up as a lower acceptance length.

"Exact in distribution" is not "byte-identical text". A different acceptance length changes the verify pass's batch shapes, and that can flip a near-tied greedy token, as the PR's own test says. On the first 20 prompts, two runs of the stock head gave identical text on all 20, two runs of the NVFP4 copy on 18, and the stock head against the copy on 19: the copy's differences are the size of its own run-to-run noise.

Turning it on and checking it

Model Runner V2 is the default in 0.33, and the option needs it. Anything that forces the V1 runner makes the server refuse to start rather than silently drop the copy.

Check the startup log for the copy:

(EngineCore pid=2630879) INFO 11-08 20:48:07 [lm_head.py:147] Quantized a nvfp4 copy of the lm_head (248320 x 2048 per rank).

No line, no copy. Then compare acceptance with and without the key. vllm bench serve reads the vllm:spec_decode_* counters before and after a run and prints the acceptance length and per-position rates; to reproduce the PR's workload use --dataset-name speed_bench (the SPEED-Bench prompts need NVIDIA's builder, and the HLE rows are gated):

$ vllm bench serve --backend vllm \
    --base-url http://localhost:8000 \
    --model Qwen/Qwen3.6-35B-A3B-FP8 \
    --dataset-name speed_bench \
    --dataset-path ./speed-bench \
    --speed-bench-dataset-subset qualitative \
    --speed-bench-output-len 256 \
    --chat-template-kwargs '{"enable_thinking": false}' \
    --temperature 0 \
    --max-concurrency 1 \
    --num-prompts 66

--temperature 0 has to be explicit: 0.33's bench no longer defaults to greedy. Our 66 prompts were 6 per category in a fixed order (--disable-shuffle on our own build of the file); the shuffled 66 this command takes give comparable, not identical, numbers. Start the server with --generation-config vllm too, or the model's own generation_config.json (sampling defaults, for Qwen) applies to requests that leave a parameter out.

The copy costs memory, counted in the model weights: Model loading took went from 34.10 GiB to 34.37 GiB with the NVFP4 copy (+0.27) and to 34.58 GiB with FP8 (+0.48). If you size the KV cache with --kv-cache-memory-bytes, that has to come out of the headroom you left.

The option refuses these setups at startup, never by falling back:

Setup What happens
Method other than mtp, eagle, eagle3 (draft models, n-gram, DFlash, DSpark) config error
Gemma-4 MTP config error: it scores tied embedding rows directly
A drafter with its own head (most EAGLE-3 heads, reduced vocabulary) draft_lm_head_quantization needs a drafter that shares the target lm_head.
A head already quantized in the checkpoint (for example nvidia/Qwen3.6-35B-A3B-NVFP4) load error; the draft already reads a 4-bit head there
A head with a bias load error
A head dtype different from the model dtype config error
V1 model runner Model Runner V1 does not support: draft lm_head quantization

On ROCm only fp8 applies. SGLang 0.5.23 has no equivalent for MTP or EAGLE: its only quantized draft head is SGLANG_ROCM_OPT_DSPARK_FP8_LM_HEAD, for DSpark drafts on gfx95x (source).

Measured

Same setup as above. Mean TPOT, tok/s per user = 1000 / mean TPOT, acceptance length (AL) from the spec-decode counters. The stock and NVFP4 arms ran twice in ABBA order (stock, NVFP4, FP8, NVFP4, stock) and the table shows their mean; between the two runs of an arm, TPOT moved by 1.8% at most and AL by 0.4%. That is the noise band for every gain below.

Concurrency Arm TPOT (ms) tok/s per user AL Gain measured Gain predicted
1 no speculation 19.12 52.3
1 MTP, BF16 head 15.59 64.1 2.993
1 MTP, FP8 copy 12.11 82.6 2.993 +28.7% +30.7%
1 MTP, NVFP4 copy 11.28 88.7 2.979 +38.2% +41.9%
2 no speculation 24.48 40.9
2 MTP, BF16 head 19.62 51.0 2.993
2 MTP, FP8 copy 17.09 58.5 2.999 +14.8% +12.5%
2 MTP, NVFP4 copy 16.38 61.1 2.974 +19.8% +18.3%
4 no speculation 34.71 28.8
4 MTP, BF16 head 26.77 37.4 3.002
4 MTP, FP8 copy 24.61 40.6 3.002 +8.8% +8.7%
4 MTP, NVFP4 copy 23.62 42.3 2.993 +13.3% +12.9%
1, sampled MTP, BF16 head 16.04 62.3 2.969
1, sampled MTP, NVFP4 copy 11.68 85.6 2.929 +37.3% +39.5%

Per-position acceptance was 0.83-0.84, 0.65-0.66 and 0.49-0.51 in every greedy arm. The quantized head proposes the same tokens often enough that nothing measurable is lost.

Sampling is the case the PR did not measure (its runs are greedy), and it is where a noisier draft distribution should show first. At temperature 0.7 and top-p 0.95 with the default greedy drafting, the NVFP4 copy cost 1.3% of acceptance length (2.969 to 2.929, per position 0.82 / 0.65 / 0.50 to 0.82 / 0.63 / 0.48) and still bought +37% tok/s per user.

The copy also changes what MTP is worth on this model. Against no speculation, MTP with the stock head gives 1.23× at concurrency 1; with the NVFP4 copy, 1.70×. On a small-active MoE the BF16 head was eating most of what drafting bought.

Predicted against measured gain, one point per case: the PR's NVFP4 runs at concurrency 1 and 4, its FP8 run at concurrency 1 and its run before #59753, and ours for NVFP4 and FP8 at concurrency 1, 2 and 4, all close to the diagonal.Predicted against measured gain, one point per case: the PR's NVFP4 runs at concurrency 1 and 4, its FP8 run at concurrency 1 and its run before #59753, and ours for NVFP4 and FP8 at concurrency 1, 2 and 4, all close to the diagonal. Two kernel timings and one stock run predict the gain within about 2 points everywhere except our NVFP4 run at concurrency 1, where the formula overshoots by 4.

To get the two kernel timings for your own head, run the microbenchmark we used. It builds the heads exactly as the server does, with vLLM's own quantized_lm_head_copy, and times one projection in a CUDA graph:

$ python head_gemv.py --shapes 248320x2048 --ms 1,2,4 --out head.json

Pass your model's vocab x hidden in --shapes; it needs vLLM 0.33.0 and an idle GPU.

Gotchas

The stock baseline is not one number. The BF16 head's speed depends on which GEMM it gets: shape-keyed skinny plans for one model family, cuBLAS for the rest, and cuBLAS at M = 1 is slower than at M = 2 on this GPU (5.89 against 4.38 ms). Measure your stock round before quoting anyone's gain.

The gain is a low-concurrency gain. The head read is shared by all rows of a draft step while the verify grows with the batch. +38% at concurrency 1 (about +25% against a stock head that avoids cuBLAS's slow M = 1 path) became +13% at 4; on a compute-bound batch it disappears.

Check for the copy in every deployment. The refusals are loud, but a deploy template that drops the key is silent. Grep for Quantized a once per rollout.

A greedy benchmark has to be greedy twice. Pass --temperature 0 to the bench and run the server with --generation-config vllm; otherwise Qwen's sampling defaults turn your greedy comparison into a sampled one.

Expect a few different texts, as many as two stock runs give. Compare greedy outputs against the run-to-run floor of your stock config, not against zero.

Verdict

Turn on nvfp4 for an MTP or EAGLE drafter that shares a BF16 head when you serve at concurrency 1 to 4 on a bandwidth-bound GPU, when k head reads are a large share of your round (38% here): on Qwen3.6-35B-A3B it was the difference between MTP giving 1.23× and 1.70×, with acceptance length within 0.5% under greedy decoding and 1.3% under sampling. Use fp8 where NVFP4 has no kernel. Leave it off at high concurrency, with a drafter that brings its own head, or on a checkpoint whose head is already quantized. Compute the expected gain with the two-line formula first: if k BF16 head reads are under a tenth of your round, the NVFP4 copy buys under 9%, about the noise of one run against another.

The speedup only holds if you measure it the same way twice; Benchmark an Inference Server Without Lying to Yourself covers the run discipline.

Sources

  1. Serving in ProductionBenchmark an Inference Server Without Lying to Yourself
  2. The GPU for Inference EngineersMegakernels for Decode: What a Kernel Boundary Costs, and When Fusing a Layer Pays
  3. Serving in ProductionServing Ripple-65B: What a Dense Model with 1M Context Costs, and When It Beats an MoE

Inference Notes

Once a week: what changed in serving AI models, and what it means if you build, run or pay for them, in about five minutes.

Read past issues