FlashMLA is an open-source GPU kernel library developed by the Chinese AI company DeepSeek. It is designed to run the decoding stage of Multi-head Latent Attention (MLA), the attention mechanism used in DeepSeek's models, efficiently on NVIDIA GPUs, and was first released in February 2025 during DeepSeek's open-source week.
It supports variable-length sequences and a paged KV cache, and is one of the kernel libraries on which DeepSeek's inference engine DeepInfer is built.