NVIDIA details 8 co-design rules for sparse attention as indexing eats 47% of a 128K prefill layer

dl_weekly · x · 2026-11-23

An NVIDIA technical blog breaks down eight co-design rules for trained sparse attention in long-context inference. At 128K tokens, the indexer and Top-k stages consume 47% of a DeepSeek V3.2 prefill layer, making indexer optimization critical.

Key takeaways: the indexer is a batched matmul with fused epilogue whose intensity scales with group size and draft length within one 200-row Tensor Core tile; KH=1 with cross-head reduction avoids linear decode growth; a 128/256 indexer head dim balances compute and memory traffic, with FP16 epilogue; fusing Top-k into the indexer kernel plus reusing the previous step's selection speeds Top-k up 2.1–2.4x (Guess-Verify-Refine); block-level selection boosts key reuse across query heads. Reference implementations live in TensorRT LLM and FlashInfer.

Original post →

More from Infra

Infra channel →