2026-11-27 16:19 UTC

JAX linear-attention project reports H100 kernel and training speedups

state: expiredheat: mediumuncertainty: mediumrelevance: mediumlinear-attention jax-pallas gpu-kernels training-efficiencyjla-org

What is this?

jax-linear-attention is an early-stage (0.1.0), Apache-2.0 project from jla-org that provides JAX Pallas Mosaic GPU kernels and a training stack for linear-attention and state-space models. Its repository reports H100/H200 benchmark speedups against named upstream implementations, including up to 5.37Γ— for a Mamba-3 MIMO kernel and 1.04–1.67Γ— end-to-end training speed versus the PyTorch-based flame baseline on selected 1.3B presets. These are project-reported measurements, taken on H100s in October 2026; the fast kernels require NVIDIA Hopper, and the project notes cases where it is slower than alternatives.

Why it matters

This is a useful, technically ambitious JAX option for researchers training linear-attention and state-space models: custom Hopper kernels are paired with a broader training stack, and the project reports gains over named alternatives on selected workloads. If independently reproduced, the results could make some JAX experiments faster or more practical. The immediate audience is specialized, however: kernel speedups require H100/H200 GPUs, the project is at 0.1.0, and its benchmark claims come from the project itself rather than independent validation.

Current assessment

New project: jla-org’s Apache-2.0 jax-linear-attention offers JAX Pallas Mosaic GPU kernels, forward and backward, for Mamba-family, Gated DeltaNet, KDA, RWKV-7, GLA and other attention or recurrence operations, plus a configurable LLM training stack. The repository reports H100 measurements from 20 Oct 2026: up to 5.37Γ— for a Mamba-3 MIMO kernel against official recurrence kernels; selected 1.3B end-to-end presets are 1.04–1.67Γ— flame in bf16 and 1.10–1.77Γ— in FP8, with reported 72.3% MFU for a single-H100 FP8 transformer and 68.2% per GPU on eight H100s. These are self-reported results, generally one run per configuration; comparisons depend on workload, baseline and settings. The project also documents regressions: for example, its softmax-attention path trails FlashAttention-3 in some settings, and Gated DeltaNet can trail FlashQLA on long sequences. The optimized kernels require Hopper hardware and the project pins JAX 0.11.2; other devices use plain-JAX fallbacks. It is early development (0.1.0), so API stability and independent reproduction remain open questions. Worth monitoring as a specialized efficiency and JAX-ecosystem development, not evidence that linear-attention models broadly outperform standard attention or that the reported gains generalize to other hardware and workloads.

Measured heat

no measured readings yet β€” the hourly heat pass fills this in

How the heat travelled

10-21 13:00⭐ origin echo-reconstructedThe repository presents JAX Pallas Mosaic GPU kernels and a training stack for linear-attention and state-space models on NVIDIA Hopper, rep
jla-org on github (echo) Β· attributed from hn.story.50195262
β€”
10-22 13:46first on hacker news Β· published Β· +24.8hShow HN: We ported FLA's Triton kernels to Jax Pallas; they're faster on H100
KarLexAI
β€”
10-22 13:46amplified on hacker news πŸ‘‘hn.story.50195262
KarLexAI
peak 1 Β· 0 comments Β· 105% of case engagement
10-22 14:27our radar first saw it Β· +25.5hdiscovery anchor: hn.story.50195262β€”

Evidence (2) β€” ⭐ canonical anchor

sourceobjectauthorscorecomments
🟧 hnShow HN: We ported FLA's Triton kernels to Jax Pallas; they're faster on H100
Retrieved article excerpt

Open article Β· Retrieved 2026-10-22T14:29:42.508084+00:00

jax-linear-attention: fast linear attention, SSM and attention kernels for JAX on NVIDIA Hopper. 72.3% MFU on one H100 (1.3B transformer, FP8), 68.2% MFU per GPU on 8 H100s, kernels up to 5.37x faster (Mamba-3 MIMO against the official recurrence kernels), 1.04-1.67x flame end to end in bf16

[CI](https://github.com/jla-org/jax-linear-attention/actions/workflows/ci.yml)
[PyPI](https://pypi.org/project/jax-linear-attention/)
[License: Apache-2.0](https://github.com/jla-org/jax-linear-attention/blob/main/LICENSE)
[Python 3.12+](https://github.com/jla-org/jax-linear-attention#install)
[JAX 0.11.2](https://github.com/jla-org/jax-linear-attention#install)
[NVIDIA Hopper](https://github.com/jla-org/jax-linear-attention#install)
[Chat on Discord](https://discord.com/invite/rWuU7cWU4E)

**jax-linear-attention** brings FLA-class linear-attention kernels to JAX: Pallas Mosaic
GPU kernels for NVIDIA Hopper, forward and backward, for Mamba-2, Mamba-3, Gated DeltaNet, KDA, RWKV-7,
GLA and more, with an FA3-style attention kernel and a full LLM training stack around them. It is built
for researchers and engineers who train linear-attention, state-space and hybrid models in JAX. Every
kernel is exact by default and measured against the latest upstream code, and this page shows where we
lose as plainly as where we win.

[Quick start](https://github.com/jla-org/jax-linear-attention#quick-start) Β· [Architectures](https://github.com/jla-org/jax-linear-attention#supported-architectures) Β·
[Benchmarks](https://github.com/jla-org/jax-linear-attention#benchmarks) Β· [Where we lose](https://github.com/jla-org/jax-linear-attention#where-we-lose) Β·
[FAQ](https://github.com/jla-org/jax-linear-attention#faq) Β· [Docs](https://github.com/jla-org/jax-linear-attention/blob/main/docs) Β· [Discord](https://discord.com/invite/rWuU7cWU4E)

## Highlights

Measured on H100 GPUs on 20 Oct 2026 with no other jobs on the GPUs, unless noted. Kernel ratios are forward +
backward, the other implementation's time over ours.

- **72.3% MFU on one H100**: `transformer-1p3b` in FP8 with the TOML as written, 77,094 tokens/s
  ([results](https://github.com/jla-org/jax-linear-attention/blob/main/docs/results.md#one-h100)).
- **68.2% MFU per GPU on 8 H100s** (FSDP 8): 72,709 tokens/s per GPU, **1.47x flame**
  ([results](https://github.com/jla-org/jax-linear-attention/blob/main/docs/results.md#8-gpus)).
- **1.04-1.67x flame in bf16 and 1.10-1.77x in FP8** on one H100 for the transformer, sliding-window,
  Gated DeltaNet, KDA and Mamba-2 1.3B presets, and 1.55x for Mamba-3 in bf16, on the same tokens
  ([results](https://github.com/jla-org/jax-linear-attention/blob/main/docs/results.md#one-h100)).
- **In the Gated DeltaNet-2 paper's own throughput setting** (its Figure 2: 1.3B hybrids on one H100,
  16K tokens per step), every model of the figure trains 1.14-1.41x faster than the paper reports with a
  32,000-token vocabulary, and 0.99-1.23x with Llama-3's 128,256. The Gated DeltaNet-2 hybrid runs at 52.1
  against 38.0 thousand tokens/s at 2K Γ— 8 ([gdn2\_paper.md](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/gdn2_paper.md)).
- **Mamba kernels**: the Mamba-2 scan 1.20-1.96x the official Triton kernels and the whole Mamba-2 layer
  1.17-1.41x the official fused training path, Mamba-3 SISO 1.58-2.32x and MIMO 2.70-5.37x the official
  recurrence kernels, Mamba-1 1.72-1.85x the official CUDA selective scan (`d_state` 16)
  ([Mamba-2](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/mamba2.md), [Mamba-3](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/mamba3.md),
  [MIMO](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/mamba3.md#mimo), [Mamba-1](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/mamba1.md)).
- **Delta-rule, RWKV-7 and GLA kernels**: GLA 1.52-1.77x FLA (dense), KDA 1.47-1.78x FLA, RWKV-7
  1.06-1.46x FLA, Gated DeltaNet 1.71-2.68x FLA's Triton kernels and 0.73-1.26x FlashQLA
  ([GLA](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/gla.md), [KDA](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/kda.md), [RWKV-7](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/rwkv7.md),
  [Gated DeltaNet](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/gdn.md)).
- **Exact, packed and long**: fp32 states and accumulation, exact packed-document masks in every kernel,
  and single calls of 1,064,960 tokens that match chained halves ([long contexts](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/long_context.md)).

Kernel speed against the strongest latest upstream code, forward + backward, on one H100

*Forward + backward on one H100 against the latest upstream code named on each row: bars are medians over
the benchmark shapes, whiskers the range, and right of 1x ours is faster. Every shape and version:
[docs/kernels.md](https://github.com/jla-org/jax-linear-attention/blob/main/docs/kernels.md#kernels).*

## Start here

| You want to | Go to |
| --- | --- |
| Call a kernel from your own JAX model | [Quick start](https://github.com/jla-org/jax-linear-attention#quick-start): `jla.ops.linear_attention(..., impl="auto")` |
| Train a model from one TOML file | [Quick start](https://github.com/jla-org/jax-linear-attention#quick-start): `jla train --config ...`, then [docs/training.md](https://github.com/jla-org/jax-linear-attention/blob/main/docs/training.md) |
| See which layers have kernels and how fast they are | [Supported architectures](https://github.com/jla-org/jax-linear-attention#supported-architectures) and [docs/kernels.md](https://github.com/jla-org/jax-linear-attention/blob/main/docs/kernels.md) |
| Check the speed claims or reproduce them | [Benchmarks](https://github.com/jla-org/jax-linear-attention#benchmarks) and [benchmarks/README.md](https://github.com/jla-org/jax-linear-attention/blob/main/benchmarks/README.md) |
| Know where it is slower than the alternatives | [Where we lose](https://github.com/jla-org/jax-linear-attention#where-we-lose) |
| Contribute a kernel, a layer or a fix | [Contributing](https://github.com/jla-org/jax-linear-attention#contributing) |

## Why jax-linear-attention

The layers behind newer language models (Mamba, Gated DeltaNet, KDA, RWKV-7, GLA) are recurrences, and
they need dedicated kernels to train fast. PyTorch has them in Flash Linear Attention's Triton kernels.
In JAX these layers have mostly run as plain JAX ops (MaxText's Gated DeltaNet, for example), which XLA
cannot fuse into one efficient pass. jax-linear-attention brings kernels of FLA's class to JAX on
NVIDIA Hopper, with the training stack to use them, and keeps every kernel exact, so switching the
implementation never changes the model.

## Supported architectures

Kernels are Pallas Mosaic GPU kernels for H100 (sm\_90a), picked by `impl="auto"` unless marked opt-in.
Speed is forward + backward against the strongest latest upstream code (the other implementation's time
over ours); "-" means no upstream comparison, and "provisional" marks a cell measured while other jobs could
share the machine.

| Architecture | Paper | Kernels | Speed against upstream | Notes |
| --- | --- | --- | --- | --- |
| **Mamba-2** (SSD) | [2405.21060](https://arxiv.org/abs/2405.21060) | fwd + bwd | 1.20-1.96x official Triton scan | whole layer 1.17-1.41x the official fused path (forward + backward; forward 1.12-1.34x) |
| **Mamba-3** SISO | [2603.15569](https://arxiv.org/abs/2603.15569) | fwd + bwd | 1.58-2.32x official Triton | fused layer core (biases, angles, rotation) |
| **Mamba-3** MIMO | [2603.15569](https://arxiv.org/abs/2603.15569) | fwd + bwd | 2.70-5.37x official TileLang recurrence kernels | ranks 1, 2, 4 and 8 |
| **Mamba-1** | [2312.00752](https://arxiv.org/abs/2312.00752) | fwd + bwd | 1.72-1.85x official CUDA scan (`d_state` 16) | `d_state` 4-32; Jamba, Falcon-Mamba |
| **Gated DeltaNet**, DeltaNet | [2412.06464](https://arxiv.org/abs/2412.06464), [2406.06484](https://arxiv.org/abs/2406.06484) | fwd + bwd | 0.73-1.26x FlashQLA, 1.71-2.68x FLA Triton | exact sequence split; `K = 256` kernels 1.17-1.24x FLA |
| **Gated DeltaNet-2** | [2605.22791](https://arxiv.org/abs/2605.22791) | fwd + bwd | - (clean-room, no upstream code) | 6.7-10.8x our plain-JAX op |
| **KDA** | [2510.26692](https://arxiv.org/abs/2510.26692) | fwd + bwd | 1.47-1.78x FLA | 1.47-1.78x dense, 1.61-1.63x with 16 packed documents |
| **RWKV-7** | [2503.14456](https://arxiv.org/abs/2503.14456) | fwd + bwd | 1.06-1.46x FLA | 1.06x at the 1.3B layer shape, 1.16-1.29x with 16 packed documents |
| **GLA** | [2312.06635](https://arxiv.org/abs/2312.06635) | fwd + bwd | 1.52-1.77x FLA (dense) | 1.01-1.41x with 16 packed documents |
| **HGRN2** | [2404.07904](https://arxiv.org/abs/2404.07904) | GLA core | as GLA | no layer-wise forget-gate lower bound |
| **mLSTM** (xLSTM) | [2405.04517](https://arxiv.org/abs/2405.04517) | opt-in fwd + bwd | 1.03-1.06x TFLA Triton | `auto` keeps the float32 chunked op |
| **Gated DeltaProduct** | [2502.10297](https://arxiv.org/abs/2502.10297) | opt-in (GDN kernels) | - | 11.4x our plain-JAX op (provisional) |
| **RWKV-6** | [2404.05892](https://arxiv.org/abs/2404.05892) | plain JAX | - |  |
| **Log-linear Mamba-2** | [2506.04761](https://arxiv.org/abs/2506.04761) | plain JAX | - | training only |
| **TTT-Linear** | [2407.04620](https://arxiv.org/abs/2407.04620) | plain JAX | - |  |
| **Lightning attention** (MiniMax-01) | [2501.08313](https://arxiv.org/abs/2501.08313) | `simple_gla` kernels | - | bf16, head dim 64 or 128 |
| **Softmax attention** (FA3-style kernel) | [2407.08608](https://arxiv.org/abs/2407.08608) | fwd + bwd | 0.77-0.92x FA3 (causal; 0.87-1.00x with the opt-in fused backward) | `auto` runs it for packed documents, cuDNN for dense causal and windowed calls |
| **Sliding window** | - | fwd + bwd | 1.10-1.38x FA3 at 128 tokens, 0.81-0.96x at 1K-4K | GQA, sinks, mixed local and global layers |
| **MLA** | [2405.04434](https://arxiv.org/abs/2405.04434) | fwd + bwd | 1.01-1.05x cuDNN, 1.01-1.06x FA3 (causal) | DeepSeek-V3, Kimi K2, Kimi Linear heads |
| **DSA** (DeepSeek Sparse Attention) | [DeepSeek-V3.2-Exp](https://github.com/deepseek-ai/DeepSeek-V3.2-Exp) | fwd + bwd | indexer + top-k 1.16-1.43x DeepGEMM + `torch.topk` (provisional) | forward, kernel time; selected-key attention is masked-dense |
| **FoX**, **PaTH** | [2503.02130](https://arxiv.org/abs/2503.02130), [2505.16381](https://arxiv.org/abs/2505.16381) | plain JAX | - | full `[T, T]` scores |
| **MoBA**, **NSA** | [2502.13189](https://arxiv.org/abs/2502.13189), [2502.11089](https://arxiv.org/abs/2502.11089) | plain JAX | - | NSA is training only |
| **MoE** (dropless) | - | grouped GEMM fwd + bwd | 0.94-1.04x `torch._grouped_mm` (provisional) | shared experts, expert parallelism, MTP |
| **Qwen3-Next-like** hybrid | [model card](https://huggingface.co/Qwen/Qwen3-Next-80B-A3B-Instruct) | GDN + attention + MoE | - | 3 Gated DeltaNet : 1 gated attention, MoE, MTP (`qwen3-next-1p3b`) |
| **Kimi-Linear-like** hybrid | [2510.26692](https://arxiv.org/abs/2510.26692) | KDA + MLA + MoE | - | 3 KDA : 1 NoPE MLA, MoE (`kimi-linear-1p3b`) |

Presets also follow the layouts of Nemotron-H, Granite-4.0-H, gpt-oss, Gemma 3, MiniMax-01, Jamba and
DeepSeek-V3 at small scale, and the 1.3B presets take FLA's published shapes. Every preset, the ops API
and the ports: [docs/architectures.md](https://github.com/jla-org/jax-linear-attention/blob/main/docs/architectures.md) and [docs/kernels.md](https://github.com/jla-org/jax-linear-attention/blob/main/docs/kernels.md).

## Install

Requirements: Python 3.12 or newer and JAX 0.11.2 (the version is pinned). The Mosaic GPU
kernels need an NVIDIA Hopper GPU (H100/H200, sm\_90a) and a driver for CUDA 13. On any other device
every op falls back to its plain-JAX implementation.

```
pip install "jax-linear-attention[cuda]"   # Linux + NVIDIA GPU (C
KarLexAI10
🟧 echo.github ⭐The repository presents JAX Pallas Mosaic GPU kernels and a training stack for linear-attention and state-space models on NVIDIA Hopper, repjla-orgβ€”β€”

Interpretation history

Decision trace