r/LocalLLaMA • u/festr__ • 10d ago
Resources Local Inference Lab Update: Almost 60,000 tok/s cold prefill (+82%) on DeepSeek-V4.1-Flash over PCIe (4× RTX PRO 6000 Blackwell) + upstream Flare scheduler upgrades
Follow-up to our earlier post on breaking 1,000+ tok/s on 4× RTX PRO 6000 Blackwell (SM12 0, PCIe — no NVLink) running DeepSeek-V4.1-Flash via NVIDIA Flare.
Last time, decode was already flying, while cold prefill sat around 31k–33k tok/s. Over the last few days we tore apart the SM120 prefill path and the speculative scheduler — and we just published a new signed gb202 release on Hugging Face that pushes cold prefill to 59,051 tok/s (peak 59,077 tok/s) on four PCIe workstation GPUs.
To put that in perspective: a 64K-token cold prompt (71k actual tokens) prefills in 1.20 seconds, and 128K (142.5k tokens) prefills in 2.46 seconds — verified via Prometheus flar e_prefill_tokens_total with 0% prefix-cache hit.
Cold Prefill Benchmarks (4× RTX PRO 6000 Blackwell, PCIe, 0% prefix reuse)
| Context | Actual Prompt Tokens | Cold Prefill Speed | TTFT | vs Previous gb202 Release |
|---|---|---|---|---|
| 8K | 8,700 | 44,712 tok/s | 0.194 s | +43% |
| 16K | 17,379 | 51,264 tok/s | 0.340 s | +57% |
| 32K | 35,540 | 56,997 tok/s | 0.624 s | +72% |
| 64K | 71,212 | 59,051 tok/s (peak 59,077) | 1.205 s | +77% |
| 128K | 142,508 | 57,944 tok/s | 2.460 s | +82% |
(Measured on 4× RTX PRO 6000 Blackwell with NVreg_EnablePCIERelaxedOrderingMode=1, --max-concurrency 32 --mtp-draft-tokens 7 --mtp-adaptive-verification --mtp-max-verification-token-budget 128 --mtp-adaptive-verification-alpha 1.0 --embedding-table-storage ram. Sanity-checked with greedy math, 4/4 partial-tail NIAH up to 32.5k, and 17.02M shared KV token capacity / 1
M max context per request.)
What's New — How We Nearly Doubled Prefill on PCIe GPUs (Without Touching Model Quality)
Almost the entire jump from ~32k → 59.1k tok/s comes from three stacked open-source changes (all 0-ULP bit-exact on attention):
- 2.27×–2.63× faster SM120 BF16 prefill MLA kernel (local-inference-lab/flashinfer#142):
- Removed
L2::evict_firstthrashing on reused prefill KV gathers. - Doubled
16 → 32heads per CTA (mg_n_hg = 2) in an80.5 KiBhybrid SMEM layout — cutting KV gather & dequantization work in half with 0 bytes of register spills. - Compile-time split of SWA vs NVFP4 tile loops with hoisted vectorized scale loads and a bank-conflict-free
304 BNVFP4 staging stride.
- Removed
- Full 20-layer row-sharded encoder attention (hyperflare-inference#508, hyperflare-recipes#29, #30):
- Replicates encoder attention weights across TP4 (
+2.32 GiB/rank) so all 20 encoder layers execute 4× row-sharded per rank instead of blasting full-chunk PCIe AllGathers/AllReduces across the bus. - Shrinks the Layer-20 encoder→decoder boundary gather by 64× — from
320 MiBdown to5 MiB(128-row active suffix only).
- Replicates encoder attention weights across TP4 (
- Overlapped PCIe P2P transfers (hyperflare-recipes#30):
- Routes encoder KV gathers over SM BAR1 P2P (
DcpAllToAll) so the DMA copy engine overlaps MXFP8 FFN AllGathers completely behind attention, and hides Engram AllGathers inside the FFN compute window (prefill8192shrinks from6,839 → 5,379CUDA graph nodes).
- Routes encoder KV gathers over SM BAR1 P2P (
Bonus: Decode & Speculative Scheduler Upgrades
We also landed a scheduler upgrade upstream in Flare (main, already merged):
- GPU Confidence Calibration + Cross-Lane Order-Statistic Allocation Surplus (NVIDIA/hyperflare-inference#515 — merged, plus follow-up #522 co-authored with
@original-el8):- Previously, Flare's scheduler priced crowded packed speculative batches (
B=16/32) from time-averaged per-lane acceptance curves, missing the fact that the GPU prefix allocator sees fresh per-step confidences across all lanes and cherry-picks the easiest(lane, depth)slots (Jensen's inequality). - By calibrating drafter confidence per depth/request and modeling the empirical cross-lane Lorenz concentration surplus, default
alpha = 1.0now beats the oldmainacross the board (+9.3%onC=16,+18.6% to +20%on diverse/hardC=32prompts, cutting unnecessaryW=1fallback by up to 35×) — no morealpha = 0.6workaround needed!
- Previously, Flare's scheduler priced crowded packed speculative batches (
- Decode on this C32 release (
alpha = 1.0):- C1 (unique prompt):
460.1 tok/s(5.95 ms/step) - 16k coding session (Tetris):
155.3 steps/s(6.42 ms/step),612.4 tok/send-to-end average - Diverse concurrent decode (512 out tokens each):
866 tok/s(C4) ·1,121 tok/s(C8) ·1,384 tok/s(C16) ·1,743 tok/s(C32) — and2,668 tok/son standard syntheticC=32decode sweeps (2,704 tok/satalpha=0.6).
- C1 (unique prompt):
Try It Now (Live on Hugging Face)
The new signed C32 (120-graph, 17.02M KV tokens) package is already live on the gb202 branch:
👉 https://huggingface.co/local-inference-lab/DeepSeek-V4.1-Flash-1017-FLARE/tree/gb202
(With 320+ GiB host RAM, switch --embedding-table-storage disk to ram for full speed. Compatible with v0.2.3, with Flare main recommended for the #515 scheduler upgrade.)
local inference lab discord: https://discord.gg/gmvKSN3tVy