← All notes

FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness

Summary

FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness (2022) made exact attention much faster and less memory-hungry by taking the GPU memory hierarchy seriously. It does not approximate the attention matrix; it reorders the computation so that fewer reads and writes go to high-bandwidth memory.

What it introduced: an IO-aware exact-attention kernel, with large wall-clock and memory gains on long sequences, which made longer-context Transformer training and inference much more practical.

What it led to: FlashAttention becoming a default kernel in modern training stacks, and a follow-up (FlashAttention-2) pointed to in batch D. Live notes: hf-transformers-attention-backends. Longer context also connects to ao-context-long-context-limits.

If you are choosing an attention backend or asking why long-context training became feasible, start here. Where to read it: https://arxiv.org/abs/2205.14135 (v2, last revised 23 Jun 2022).

The paper is posted on arXiv under the arXiv non-exclusive distribution license. This note links to it rather than reproducing it. The note itself is CC BY 4.0.

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Pointer by iinventedlight (AI-assisted). Paper license: arXiv non-exclusive distribution; this note links to it and does not reproduce it.

License: CC-BY-4.0 · Pointer by iinventedlight (AI-assisted). Source: Tri Dao, Daniel Y. Fu, Stefano Ermon, Atri Rudra, Christopher Ré, FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness (arXiv non-exclusive distribution license). This note links to the paper rather than reproducing it.

Cite this

Permanent ID: iil:note:x25vm1f6

'iinventedlight (AI-assisted)'. 2026. "FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness." iinventedlight Library, iil:note:x25vm1f6, version of 2026-11-11. https://iinventedlight.com/library/notes/2205-14135-flashattention/. License: CC-BY-4.0.

@misc{iil_note_x25vm1f6,
  author = {{'iinventedlight (AI-assisted)'}},
  title = {{FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness}},
  howpublished = {iinventedlight Library},
  year = {2026},
  date = {2026-11-11},
  url = {https://iinventedlight.com/library/notes/2205-14135-flashattention/},
  note = {Permanent ID iil:note:x25vm1f6. License: CC-BY-4.0.},
}

Markdown

Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com.

For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/2205-14135-flashattention.md.