One request in the radix tree#
Precision and stack economics in main.py#
| Factor | H100 + BF16 + vLLM | H100 + FP8 + vLLM | B200 + NVFP4 + FP8 + TRT-LLM | GB200 NVL72 + TRT-LLM + Dyn |
|---|
| HBM per GPU, GB | 80 | 80 | 192 | 192 |
|---|
| HBM bandwidth, TB/s | 3.35 | 3.35 | 8.00 | 8.00 |
|---|
| Weight bits | 16 | 8 | 4 | 4 |
|---|
| KV cache bits | 16 | 8 | 8 | 8 |
|---|
| MTP factor | 1.0 | 1.0 | 1.8 | 1.8 |
|---|
| Disaggregation factor | 1.0 | 1.0 | 1.6 | 2.5 |
|---|
| Price per GPU hour | 2.50 | 2.50 | 4.80 | 6.20 |
|---|
Run the simulators#
| Task | Code |
|---|
| Static batching | simulate_static(reqs, batch=16) |
|---|
| Continuous plus chunked | simulate_continuous(reqs, chunked=True) |
|---|
| Cache-aware radix order | simulate(requests, "CACHE_AWARE") |
|---|
| Scrambled prefix order | workload_scrambled(n=80, docs=4) |
|---|
| HBM footprint per stack | hbm_footprint_gb(params_b, active_b, seq_len, stack) |
|---|
| Cost per million tokens | cost_per_million_tokens(active_b, stack) |
|---|
| LMCache under HBM pressure | simulate("LMCACHE", reqs) |
|---|
| Engine for your constraints | pick_engine(hardware, scale, workload) |
|---|
Troubleshooting#
| Symptom | Cause | Fix |
|---|
| Decode stalls during a long prompt | Prefill freezes decode | Chunked prefill. P99 ITL ~50 ms to ~15 ms |
|---|
| Hit rate 7% on shared prompts | Dynamic content in the prefix | Immutable parts first. 7% to 74% |
|---|
| 6.4x gain gone | Template order changes per request | Fix one component order |
|---|
| HBM 100%, same prompt prefilled again | Preemption evicts KV | Native CPU offload or LMCache |
|---|
| 3-5% slower with LMCache | Small HBM pressure | Turn LMCache off |
|---|
| Accuracy drops after NVFP4 | FP4 weights on reasoning tasks | FP8 weights plus FP4 activations |
|---|
| Attention collapses at FP4 KV | KV needs dynamic range | Keep KV cache in FP8 |
|---|
| Features break together | Combination not in the matrix | Check the matrix for your version |
|---|
Q&A#
- Why is FCFS wrong for prefix traffic?
- It evicts the hot branch to admit a short-prefix request.
- What does chunked prefill protect?
- The TTFT tail and ITL, not mean throughput.
- Where does the 7x TRT-LLM gap come from?
- HBM bandwidth, NVFP4 weights, MTP and disaggregation.
- LMCache for prompts under 1K tokens?
- No. Transfer time is more than re-prefill.
- Do you enable PagedAttention?
- No flag. It is the only allocator vLLM ships.
- Does vLLM reuse prefixes?
- Yes, with
--enable-prefix-caching. SGLang is radix-first.
Glossary#
- ITL
- inter-token latency. Time between two decode tokens.
- TTFT
- first token time. Prefill plus queue plus network.
- FCFS
- first-come first-served. Breaks prefix locality.
- NVFP4
- NVIDIA 4-bit microscaling format for weights and activations.
- MTP
- multi-token prediction. TRT-LLM integrated draft.
- MXFP8
- microscaling FP8 variant on Blackwell Tensor Cores.
- Connector API
- vLLM 0.9.0+ pluggable KV store interface.
- Preemption
- KV cache shuffle when HBM is full.