FlashAttention-4 Adds Low-Precision Blackwell Support

A kernel upgrade could unlock multi-PFLOPS attention performance on Blackwell GPUs.
30-Second TL;DR
What Changed
MXFP8 is supported for both forward and backward attention passes.
Why It Matters
Lower-precision attention can improve training and inference throughput while reducing memory and bandwidth pressure. Teams using Blackwell GPUs may gain substantial performance by upgrading kernels rather than changing model architecture.
What To Do Next
Run your training kernels with FlashAttention-4 MXFP8 on a Blackwell test node and compare throughput, loss stability, and memory use.
Key Points
- •MXFP8 is supported for both forward and backward attention passes.
- •Reported performance reaches 2.85 PFLOPS forward and 2 PFLOPS backward.
- •Internal-shape testing reports 2.54 PFLOPS with FA4 MX8.
Deep Insight
Background and context from public sources — not the original article. 13 sources cited.
Enhanced Key Takeaways
- •FlashAttention-4 re-architects the attention pipeline around Blackwell SM100's new TCGEN05 instructions and 256 KB per-SM Tensor Memory (TMEM), abandoning Hopper's WGMMA paradigm.
- •The implementation is authored via NVIDIA's CuTeDSL in Python rather than monolithic CUDA C++, cutting JIT compilation time from roughly 55 seconds to 2.5 seconds.
- •FA4 addresses Blackwell's 'asymmetric hardware scaling' bottleneck, where non-MMA operations like softmax threatened to consume 25% to 60% more runtime due to unscaled shared memory and exponential units.
- •Hardware support is strictly limited to datacenter Blackwell chips (SM100/SM103 like B100, B200, GB200) and Hopper, completely excluding consumer Blackwell GPUs (SM120) which lack TMEM hardware.
- •On Blackwell HGX B200 systems, FA4 delivers a 1.2× to 1.3× speedup over NVIDIA cuDNN v9.13 and a 2.1× to 2.7× speedup over Triton implementations.
Competitor Analysis
- Relative Blackwell Performance
- Reference standard (up to 2.85 PF/s)
- Core Architecture / Language
- Python via CuTeDSL; TMEM & TCGEN05
- Integration & Accessibility
- Native FlexAttention, vLLM (v0.17+), SGLang
- Relative Blackwell Performance
- 1.2× – 1.3× slower than FA4
- Core Architecture / Language
- Closed-source C++/CUDA vendor binaries
- Integration & Accessibility
- Standard NVIDIA runtime library
- Relative Blackwell Performance
- 2.1× – 2.7× slower than FA4
- Core Architecture / Language
- Python-based Triton compiler IR
- Integration & Accessibility
- PyTorch Inductor default backend
| Implementation | Relative Blackwell Performance | Core Architecture / Language | Integration & Accessibility |
|---|---|---|---|
| FlashAttention-4 (FA4 MX8) | Reference standard (up to 2.85 PF/s) | Python via CuTeDSL; TMEM & TCGEN05 | Native FlexAttention, vLLM (v0.17+), SGLang |
| NVIDIA cuDNN (v9.13) | 1.2× – 1.3× slower than FA4 | Closed-source C++/CUDA vendor binaries | Standard NVIDIA runtime library |
| OpenAI / PyTorch Triton | 2.1× – 2.7× slower than FA4 | Python-based Triton compiler IR | PyTorch Inductor default backend |
Technical Deep Dive
- TMEM & TCGEN05 Co-Design: Blackwell SM100 removed Hopper's WGMMA instruction set; FlashAttention-4 restructures data flow around the 256 KB Tensor Memory (TMEM) subsystem and hardware-managed Tensor Memory Accelerator (TMA).
- Asymmetric Scaling Mitigation: While raw Blackwell Tensor Core math throughput doubled over Hopper, exponential and shared memory bandwidth did not scale proportionally; FA4 uses selective rescaling and pipelining to keep non-MMA ops from bottlenecking execution.
- CuTeDSL Python Kernel Implementation: Built using NVIDIA's CuTeDSL Python dialect instead of C++/CUDA, reducing JIT compilation latency from ~55 seconds down to ~2.5 seconds while sustaining peak compute efficiency.
- End-to-End Block Scaling (MXFP8): Uses microscopic scaling factor formats across both forward and backward attention loops to maximize Tensor Core throughput without accuracy degradation.
- Hardware Portability Gate: Requires datacenter compute capabilities (SM100/SM103) with dedicated TMEM blocks, rendering the kernel unsupported on consumer chips like the RTX 5090 (SM120).
Future ImplicationsAI analysis grounded in cited sources
Timeline
- 2026-03FlashAttention-4 architecture paper published and FlexAttention backend integration launched
- 2026-09PyTorch team adds native end-to-end MXFP8 forward and backward support for NVIDIA Blackwell in FlashAttention-4
Sources (13)
Factual claims are grounded in the sources below. Forward-looking analysis is AI-generated interpretation.
Weekly AI Recap
Read this week's curated digest of top AI events →
AI-curated news aggregator. All content rights belong to original publishers.
Original source: PyTorch Blog ↗
This is a summary, not the original. Read the source, or get the weekly briefing.
The weekly digest
One email a week. Unsubscribe anytime.