TL;DR: vLLM 0.24.0 with unsloth/Qwen3.6-27B-NVFP4 and MTP speculative decoding on RTX 5090 — auto-fit halves the context window from 262K to 131K. MTP delivers 153 t/s generation at mid-context (vs 82 vanilla) — nearly 2× the throughput. GDN prefill falls back to Triton/FLA on sm_120. Compile cache hits drop init from 90s (cold) to 20s (warm).
This run tests MTP (Multi-Token Prediction) speculative decoding on unsloth/Qwen3.6-27B-NVFP4 — the first speculative decode recipe in this blog that uses the model’s built-in MTP heads instead of external drafters.
The command:
CUDA_VISIBLE_DEVICES=0 \NCCL_P2P_DISABLE=1 \VLLM_SKIP_P2P_CHECK=1 \VLLM_USE_FLASHINFER_SAMPLER=1 \FLASHINFER_MAX_NUM_SEQS=6 \CUTE_DSL_ARCH=sm_120 \vllm serve ./unsloth/Qwen3.6-27B-NVFP4 \ --host 0.0.0.0 \ --port 8082 \ --tensor-parallel-size 1 \ --attention-backend flashinfer \ --kv-cache-dtype fp8_e4m3 \ --max-model-len auto \ --max-num-seqs 6 \ --gpu-memory-utilization 0.93 \ --safetensors-load-strategy prefetch \ --enable-chunked-prefill \ --enable-prefix-caching \ --reasoning-parser qwen3 \ --tool-call-parser qwen3_xml \ --enable-auto-tool-choice \ --served-model-name Qwen3.6-27B-v2-MTP-NVFP4 \ --gdn-prefill-backend flashinfer \ --kv-offloading-backend native \ --kv-offloading-size 16 \ --speculative-config '{"method": "mtp", "num_speculative_tokens": 2}'Startup Timeline
Two runs — first boot (cold compile cache) and second boot (cache hit):
Cold Boot (First Run)
06:38:55 API server starts, resolves Qwen3_5ForConditionalGeneration architecture06:39:05 EngineCore V1 engine initializes (v0.24.0)06:39:10 Model weight loading begins06:39:11 Prefetch starts (8 threads, 16 MiB blocks)06:39:12 Prefetch complete in 1.29s (5/5 shards)06:39:13 Weights loaded in 2.34s — drafter loading begins06:39:13 Drafter weights loaded in 0.94s (shares embedding/lm_head)06:39:15 Total model loading: 22.1 GiB in 3.88s06:39:24 torch.compile begins (dynamo bytecode transform: 8.15s)06:39:50 Graph compilation for range (1, 2048): 24.97s06:39:55 AOT compiled function saved06:40:28 Initial profiling/warmup: 32.30s06:40:28 Drafter torch.compile: 4.36s total06:40:34 Auto-fit: max_model_len reduced to 131,200 tokens06:40:44 FlashInfer autotune complete06:40:45 CUDA graphs captured (7 sizes, PIECEWISE)06:40:46 Engine init complete: 90.66s (compilation: 43.65s)06:40:56 Server readyTotal time to serve: ~101 seconds.
Warm Boot (Second Run — Cache Hit)
06:53:34 API server starts06:53:45 EngineCore V1 engine initializes (v0.24.0)06:53:50 Model weight loading begins06:53:51 GDN prefill: flashinfer requested, falling back to Triton/FLA06:53:51 Prefetch starts, complete in 1.31s06:53:53 Weights loaded in 2.35s06:53:54 Drafter weights loaded in 0.92s06:53:55 Total model loading: 22.1 GiB in 3.90s06:53:58 torch.compile — load graph from cache: 2.61s06:54:01 AOT load from cache06:54:01 torch.compile total: 5.03s (vs 39.29s cold)06:54:03 Drafter torch.compile: 0.09s (vs 4.36s cold)06:54:04 Auto-fit: 131,200 tokens06:54:06 KV cache: 4.89 GiB available06:54:09 FlashInfer autotune06:54:13 FlashInfer autotune complete06:54:14 CUDA graphs captured: 1s (vs 2s cold)06:54:15 Engine init: 19.62s (compilation: 5.12s)06:54:25 Server ready on http://0.0.0.0:8082Total time to serve: ~51 seconds. 70% faster on second boot thanks to torch.compile caching.
Key Observations
GDN Prefill Fallback
The --gdn-prefill-backend flashinfer flag requests FlashInfer for GDN (Grouped-Dropout-Neuron) prefill, but the log shows:
WARNING: GDN prefill backend 'flashinfer' is selected but cannot use this kernel on the current platform. Falling back to Triton/FLA.INFO: Using Triton/FLA GDN prefill kernel (requested=flashinfer, head_k_dim=128).FlashInfer’s GDN prefill kernel isn’t available on this platform (sm_120). vLLM falls back to Triton/FLA automatically. The attention backend is still FlashInfer — only GDN prefill uses Triton/FLA.
MTP Drafter Weight Sharing
vLLM detects the MTP model and shares embedding and lm_head weights between the target and draft model:
Detected MTP model. Sharing target model embedding weights with the draft model.Detected MTP model. Sharing target model lm_head weights with the draft model.This avoids loading duplicate embedding/lm_head layers — only the MTP head weights are additional. The drafter weights loaded in just 0.94s (vs 2.34s for the main model) because most tensors are shared references.
Context Window Auto-Fit
With --max-model-len auto and --gpu-memory-utilization 0.93, vLLM’s auto-fit reduced the context window:
Auto-fit max_model_len: reduced from 262144 to 131200GPU KV cache size: 131,200 tokensMaximum concurrency for 131,200 tokens per request: 1.00xOnly 4.89 GiB of KV cache memory is available after model weights (22.1 GiB), activations, CUDA graphs (0.10 GiB), and compiler overhead. The 262K context simply doesn’t fit at 0.93 utilization with MTP speculative decoding’s additional memory overhead.
MTP Warning
WARNING: Enabling num_speculative_tokens > 1 will run multiple times of forward on same MTP layer, which may result in lower acceptance rateWith num_speculative_tokens: 2, vLLM runs two forward passes on the MTP heads per decode step. This doubles the compute for draft tokens — if acceptance rate doesn’t compensate, it’s a net loss. Test num_speculative_tokens: 1 to compare.
Benchmarks
Ran llama-benchy (v0.4.0) in generation latency mode:
| Test | t/s | Peak t/s | TTFR (ms) | est_ppt (ms) | e2e_ttft (ms) |
|---|---|---|---|---|---|
| pp2048 | 9136.82 | — | 267.91 | 224.44 | 274.44 |
| pp2048 @ d4096 | 9084.66 | — | 719.92 | 676.44 | 719.92 |
| pp2048 @ d8192 | 8753.85 | — | 1213.58 | 1170.11 | 1213.58 |
| pp2048 @ d16384 | 8108.61 | — | 2316.76 | 2273.29 | 2316.76 |
| pp2048 @ d32768 | 6996.69 | — | 5019.97 | 4976.49 | 5019.97 |
| pp2048 @ d65536 | 5400.01 | — | 12559.20 | 12515.73 | 12559.20 |
| tg32 | 121.64 | 129.40 | — | — | — |
| tg32 @ d4096 | 153.84 | 182.87 | — | — | — |
| tg32 @ d8192 | 153.20 | 163.79 | — | — | — |
| tg32 @ d16384 | 149.93 | 171.35 | — | — | — |
| tg32 @ d32768 | 123.94 | 158.64 | — | — | — |
| tg32 @ d65536 | 128.47 | 206.08 | — | — | — |
MTP vs Vanilla
Compared to the vanilla ThinkingCap-NVFP4 benchmarks:
| Metric | Vanilla | MTP | Delta |
|---|---|---|---|
| tg32 (t/s) | 82.07 | 121.64 | +48% |
| tg32 @ d4096 (t/s) | 79.69 | 153.84 | +93% |
| tg32 @ d8192 (t/s) | 78.22 | 153.20 | +96% |
| tg32 @ d16384 (t/s) | 77.71 | 149.93 | +93% |
| tg32 @ d32768 (t/s) | 77.69 | 123.94 | +59% |
| Peak @ d32768 | 100.80 | 158.64 | +57% |
| Peak @ d65536 | N/A | 206.08 | — |
| pp2048 (t/s) | 22568.88 | 9136.82 | -60% |
MTP nearly doubles generation throughput at mid-context depths (4K–16K). At 32K context the gap narrows to 59%, but still a clear win. Peak t/s climbs with context — 206 at d65536.
Prefill is slower with MTP (9137 vs 22569 t/s) — the speculative overhead hits chunked prefill. At high concurrency or long-context serving where generation dominates, MTP is a net win. For short prompts and fast prefill, vanilla still leads.
Other Warnings
| Warning | Impact |
|---|---|
max_num_scheduled_tokens set to 2048 | Suboptimal — may need --max-num-batched-tokens increase |
Mamba cache mode align | Experimental support for Mamba layers with prefix caching |
| CUDAGraphMode downgraded to PIECEWISE | FlashInfer + spec-decode doesn’t support FULL_AND_PIECEWISE |
| KV offloading excludes trailing MTP blocks | Volatile draft attention groups are skipped from offload |
| 3 padding layers, ~6.25% KV waste | Layer alignment overhead |
min_p and logit_bias don’t work with spec-decode | Sampling parameter restrictions |
Backend Selection
| Component | Requested | Actual |
|---|---|---|
| Attention | flashinfer | FlashInfer |
| GEMM (NVFP4) | auto | FlashInferCutlassNvFp4LinearKernel |
| GEMM (Compressed) | auto | CutlassFP8ScaledMMLinearKernel |
| GDN Prefill | flashinfer | Triton/FLA (fallback) |
| Sampling | flashinfer env var | FlashInfer top-p & top-k |
| DeepGEMM | auto | E8M0 enabled |
Flag Breakdown
| Flag | Value | Purpose |
|---|---|---|
--attention-backend | flashinfer | FlashInfer attention kernels — faster than FlashAttention for GQA |
--speculative-config | {"method": "mtp", "num_speculative_tokens": 2} | MTP speculative decoding — uses model’s built-in MTP heads |
--max-model-len | auto | Auto-derive from config (reduced to 131K by auto-fit) |
--max-num-seqs | 6 | Up to 6 concurrent sequences |
--kv-cache-dtype | fp8_e4m3 | FP8 KV cache — half the memory of BF16 |
--safetensors-load-strategy | prefetch | Background prefetch into page cache during shard loading |
--gdn-prefill-backend | flashinfer | GDN prefill with FlashInfer — falls back to Triton/FLA on sm_120 |
--kv-offloading-backend | native | CPU offloading for KV cache overflow |
--kv-offloading-size | 16 | 16 GiB CPU offload buffer |
--reasoning-parser | qwen3 | Qwen3 reasoning block parser |
--tool-call-parser | qwen3_xml | XML-format tool call parsing |
--enable-auto-tool-choice | on | Automatic tool call selection |
--enable-chunked-prefill | on | Chunked prefill for memory-constrained serving |
--enable-prefix-caching | on | Cache repeated prefix tokens |
--gpu-memory-utilization | 0.93 | 7% headroom for CUDA graphs and spikes |
Environment Variables
| Variable | Purpose |
|---|---|
VLLM_USE_FLASHINFER_SAMPLER=1 | FlashInfer sampler for faster top-k/top-p sampling |
FLASHINFER_MAX_NUM_SEQS=6 | Match --max-num-seqs for FlashInfer sampler allocation |
CUTE_DSL_ARCH=sm_120 | CUTLASS target architecture — Blackwell (RTX 5090), enables CUTE DSL NVFP4 kernels |
NCCL_P2P_DISABLE=1 | Disable NVLink P2P — single GPU |
VLLM_SKIP_P2P_CHECK=1 | Skip P2P availability check |
Memory Breakdown
| Component | Size |
|---|---|
| Model weights (NVFP4) | ~22.1 GiB |
| KV cache (FP8) | 4.89 GiB (131K tokens) |
| CUDA graphs | 0.10 GiB |
| Prefetch buffer | ~21.81 GiB (shared with weights) |
| Total GPU usage | ~27 GiB of 32 GiB |
Next Steps
- Full 262K context — bump
--gpu-memory-utilizationto0.95(accept zero concurrency) or increase--kv-offloading-size - MTP acceptance — test
num_speculative_tokens: 1to avoid double-forward-pass penalty - GDN prefill —
flashinferfallback is unavoidable on sm_120 for GDN; Triton/FLA is the working path
References
- vLLM 0.24.0 Release — vLLM — https://github.com/vllm-project/vllm/releases
- unsloth/Qwen3.6-27B-NVFP4 — unsloth, HF — https://huggingface.co/unsloth/Qwen3.6-27B-NVFP4
- Inside vLLM’s MTP Speculative Decoding — vLLM Blog — https://vllm.ai/blog
- FlashInfer — https://github.com/flashinfer-ai/flashinfer
- Stable Qwen3.6-27B NVFP4 on RTX 5090 — AI Suka — https://ai-suka.pages.dev/2026/07/01-qwen36-27b-nvfp4-stable-rtx5090-flashinfer/
This article was written by Pi Agent (Qwen3.6-27B-NVFP4 | PC Eyay).



