FlashRNN: I/O-Aware Optimization of Traditional RNNs on modern hardware
Korbinian Pöppel, Maximilian Beck, Sepp Hochreiter
摘要
While Transformers and other sequence-parallelizable neural network architectures seem like the current state of the art in sequence modeling, they specifically lack state-tracking capabilities. These are important for time-series tasks and logical reasoning. Traditional RNNs like LSTMs and GRUs, as well as modern variants like sLSTM do have these capabilities at the cost of strictly sequential processing. While this is often seen as a strong limitation, we show how fast these networks can get with our hardware-optimization FlashRNN in Triton and CUDA, optimizing kernels to the register level on modern GPUs. We extend traditional RNNs with a parallelization variant that processes multiple RNNs of smaller hidden state in parallel, similar to the head-wise processing in Transformers. To enable flexibility on different GPU variants, we introduce a new optimization framework for hardware-internal cache sizes, memory and compute handling. It models the hardware in a setting using polyhedral-like constraints, including the notion of divisibility. This speeds up the solution process in our ConstrINT library for general integer constraint satisfaction problems (integer CSPs). We show that our kernels can achieve 50x speed-ups over a vanilla PyTorch implementation and allow 40x larger hidden sizes compared to our Triton implementation. Our open-source kernels and the optimization library are released here to boost research in the direction of state-tracking enabled RNNs and sequence modeling: https://github.com/NX-AI/flashrnn
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper3
- TiRex: Zero-Shot Forecasting Across Long and Short Horizons with Enhanced In-Context LearningAndreas Auer, Patrick Podest, Daniel Klotz, Sebastian Böck 等NeurIPS 2025 · 被引用 126 次
- Tiled Flash Linear Attention: More Efficient Linear RNN and xLSTM KernelsMaximilian Beck, Korbinian Pöppel, Phillip Lippe, Sepp HochreiterNeurIPS 2025 · 被引用 17 次
- pLSTM: parallelizable Linear Source Transition Mark networksKorbinian Pöppel, Richard Freinschlag, Thomas Schmied, Wei Lin 等NeurIPS 2025 · 被引用 2 次
它引用的顶会 Paper9
- FlashAttention: Fast and Memory-Efficient Exact Attention with IO-AwarenessTri Dao, Daniel Y. Fu, Stefano Ermon, Atri Rudra 等NeurIPS 2022 · 被引用 5,493 次
- Transformers are RNNs: Fast Autoregressive Transformers with Linear AttentionAngelos Katharopoulos, Apoorv Vyas, Nikolaos Pappas, François FleuretICML 2020 · 被引用 2,665 次
- FlashAttention-2: Faster Attention with Better Parallelism and Work PartitioningTri DaoICLR 2024 · 被引用 2,600 次
- Transformers are SSMs: Generalized Models and Efficient Algorithms Through Structured State Space DualityTri Dao, Albert GuICML 2024 · 被引用 1,407 次
- FlashAttention-3: Fast and Accurate Attention with Asynchrony and Low-precisionJay Shah, Ganesh Bikshandi, Ying Zhang, Vijay Thakkar 等NeurIPS 2024 · 被引用 727 次
相关 Paper
- ParaRNN: Unlocking Parallel Training of Nonlinear RNNs for Large Language ModelsFederico Danieli, Pau Rodríguez, Miguel Sarabia, Xavier Suau 等ICLR 2026 · 被引用 18 次
- ThunderKittens: Simple, Fast, and Adorable KernelsBenjamin Frederick Spector, Simran Arora, Aaryan Singhal, Arjun Parthasarathy 等ICLR 2025
- PRISM: Parallel Residual Iterative Sequence ModelJie Jiang, Ke Cheng, XIN XU, Mengyang Pang 等ICML 2026
- Implicit Language Models are RNNs: Balancing Parallelization and ExpressivityMark Schöne, Babak Rahmani, Heiner Kremer, Fabian Falck 等ICML 2025
- FlashEKGR: Fast Embedding-Based Knowledge Graph Reasoning Models TrainingWentai Zhang, Teng Xu, Weiguang Wang, Junxing Li 等ICDE 2026
