Saved in:
Bibliographic Details
Main Authors: Yüzügüler, Ahmet Caner, Çelik, Ahmet, Zhuang, Jiawei, Cavigelli, Lukas
Format: Preprint
Published: 2025
Subjects:
Online Access:https://arxiv.org/abs/2509.21081
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866911442888818688
author Yüzügüler, Ahmet Caner
Çelik, Ahmet
Zhuang, Jiawei
Cavigelli, Lukas
author_facet Yüzügüler, Ahmet Caner
Çelik, Ahmet
Zhuang, Jiawei
Cavigelli, Lukas
contents Multi-Head Latent Attention (MLA) is a recent attention mechanism adopted in state-of-the-art LLMs such as DeepSeek-v3 and Kimi K2. Thanks to its novel formulation, MLA allows two functionally equivalent but computationally distinct kernel implementations: naive and absorb. While the naive kernels (e.g., FlashAttention) are typically preferred in training and prefill for their computational efficiency, existing decoding kernels (e.g., FlashMLA) rely on the absorb method to minimize HBM bandwidth usage. However, the compute-bound nature of the absorb implementations prohibits performance benefits from data reuse opportunities in attention calculations, such as shared prefixes. In this work, we introduce TyphoonMLA, a hybrid approach that combines naive and absorb formulations to harness the strengths of both. TyphoonMLA effectively leverages the shared prefix by applying the naive formulation to the compute-bound parts of attention calculations, while reducing the bandwidth requirements for non-shared parts by using the absorb formulation. As a result, TyphoonMLA improves the throughput of attention calculations in MLA architectures by up to 3x and 3.24x on NPU and GPUs, with only a 3% overhead in HBM size.
format Preprint
id arxiv_https___arxiv_org_abs_2509_21081
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle TyphoonMLA: A Mixed Naive-Absorb MLA Kernel For Shared Prefix
Yüzügüler, Ahmet Caner
Çelik, Ahmet
Zhuang, Jiawei
Cavigelli, Lukas
Machine Learning
Artificial Intelligence
Multi-Head Latent Attention (MLA) is a recent attention mechanism adopted in state-of-the-art LLMs such as DeepSeek-v3 and Kimi K2. Thanks to its novel formulation, MLA allows two functionally equivalent but computationally distinct kernel implementations: naive and absorb. While the naive kernels (e.g., FlashAttention) are typically preferred in training and prefill for their computational efficiency, existing decoding kernels (e.g., FlashMLA) rely on the absorb method to minimize HBM bandwidth usage. However, the compute-bound nature of the absorb implementations prohibits performance benefits from data reuse opportunities in attention calculations, such as shared prefixes. In this work, we introduce TyphoonMLA, a hybrid approach that combines naive and absorb formulations to harness the strengths of both. TyphoonMLA effectively leverages the shared prefix by applying the naive formulation to the compute-bound parts of attention calculations, while reducing the bandwidth requirements for non-shared parts by using the absorb formulation. As a result, TyphoonMLA improves the throughput of attention calculations in MLA architectures by up to 3x and 3.24x on NPU and GPUs, with only a 3% overhead in HBM size.
title TyphoonMLA: A Mixed Naive-Absorb MLA Kernel For Shared Prefix
topic Machine Learning
Artificial Intelligence
url https://arxiv.org/abs/2509.21081