Sparser Block-Sparse Attention via Token Permutation
Not on the map. Why?
Abstract (arXiv)
Scaling the context length of large language models (LLMs) offers significant benefits but is computationally expensive. This expense stems primarily from the self-attention mechanism, whose O(N2) complexity with respect to sequence length presents a major bottleneck for both memory and latency. Fortunately, the attention matrix is often sparse, particularly for long sequences, suggesting an opportunity for optimization. Block-sparse attention has emerged as a promising solution that partitions sequences into blocks and skips computation for a subset of these blocks. However, the effectiveness of this method is highly dependent on the underlying attention patterns, which can lead to sub-optimal block-level sparsity. For instance, important key tokens for queries within a single block may be scattered across numerous other blocks, leading to computational redundancy. In this work, we propose Permuted Block-Sparse Attention (PBS-Attn), a plug-and-play method that leverages the permutation properties of attention to increase block-level sparsity and enhance the computational efficiency of LLM prefilling. We conduct comprehensive experiments on challenging real-world long-context datasets, demonstrating that PBS-Attn consistently outperforms existing block-sparse attention methods in model accuracy and closely matches the full attention baseline. Powered by our custom permuted-FlashAttention kernels, PBS-Attn achieves an end-to-end speedup of up to 2.75× in long-context prefilling, confirming its practical viability. Code available at https://github.com/xinghaow99/pbs-attn
Key facts. Cited by 5 papers in the map (data through 14 Oct 2026). Builds on 29 of its 41 references that are in the map. First posted on arXiv 24 Oct 2025.
Builds on
29 of 41 references.
References · 29
- 2017Attention Is All You Needcited by 60,361
- 2022Scalable Diffusion Models with Transformerscited by 6,054
- 2021RoFormer: Enhanced Transformer with Rotary Position Embeddingcited by 4,703
- 2022FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awarenesscited by 3,673
- 2023A Survey on Large Language Model based Autonomous Agentscited by 2,242
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,186
- 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 2,022
- 2020Reformer: The Efficient Transformercited by 1,668
- 2023LongBench: A Bilingual, Multitask Benchmark for Long Context Understandingcited by 1,417
- 2023GQA: Training Generalized Multi-Query Transformer Models from Multi-Head Checkpointscited by 1,346
- 2024RULER: What's the Real Context Size of Your Long-Context Language Models?cited by 1,346
- 2024Transformers are SSMs: Generalized Models and Efficient Algorithms Through Structured State Space Dualitycited by 1,336
17 more
- 2021Train Short, Test Long: Attention with Linear Biases Enables Input Length Extrapolationcited by 1,103
- 2023YaRN: Efficient Context Window Extension of Large Language Modelscited by 601
- 2024Gated Delta Networks: Improving Mamba2 with Delta Rulecited by 532
- 2023Ring Attention with Blockwise Transformers for Near-Infinite Contextcited by 457
- 2025Native Sparse Attention: Hardware-Aligned and Natively Trainable Sparse Attentioncited by 407
- 2024MInference 1.0: Accelerating Pre-filling for Long-Context LLMs via Dynamic Sparse Attentioncited by 383
- 2024LongBench v2: Towards Deeper Understanding and Reasoning on Realistic Long-context Multitaskscited by 379
- 2025MoBA: Mixture of Block Attention for Long-Context LLMscited by 198
- 2025XAttention: Block Sparse Attention with Antidiagonal Scoringcited by 137
- 2025A Survey of Context Engineering for Large Language Modelscited by 126
- 2024SeerAttention: Learning Intrinsic Sparse Attention in Your LLMscited by 124
- 2025FlexPrefill: A Context-Aware Sparse Attention Mechanism for Efficient Long-Sequence Inferencecited by 123
- 2025SpargeAttention: Accurate and Training-free Sparse Attention Accelerating Any Model Inferencecited by 120
- 2025Sparse VideoGen2: Accelerate Video Generation with Sparse Attention via Semantic-Aware Permutationcited by 106
- 2024P/D-Serve: Serving Disaggregated Large Language Model at Scalecited by 27
- 2025MMInference: Accelerating Pre-filling for Long-Context VLMs via Modality-Aware Permutation Sparse Attentioncited by 26
- 2025PAROAttention: Pattern-Aware ReOrdering for Efficient Sparse and Quantized Attention in Visual Generation Modelscited by 17
Built on by
Citing papers per year: 2026: 5.
5 papers.
- 2026Prism: Spectral-Aware Block-Sparse Attentioncited by 3
- 2026S2O: Early Stopping for Sparse Attention via Online Permutationcited by 1
- 2026Flux Attention: Context-Aware Hybrid Attention for Efficient LLMs Inferencecited by 0
- 2026Block-Sparse Attention with Semantic-Geometric Decoupled Routingcited by 0
- 2026The Sirens' Song: When Proximal Background Context Overshadows Distant Evidencecited by 0
- 2026The Sirens' Song: When Proximal Background Context Overshadows Distant Evidence22 Sep 2026
- 2026Block-Sparse Attention with Semantic-Geometric Decoupled Routing19 Sep 2026
- 2026Flux Attention: Context-Aware Hybrid Attention for Efficient LLMs Inference8 Apr 2026
- 2026S2O: Early Stopping for Sparse Attention via Online Permutation26 Feb 2026
- 2026Prism: Spectral-Aware Block-Sparse Attention9 Feb 2026