POD-Attention: Unlocking Full Prefill-Decode Overlap for Faster LLM Inference

Aditya K Kamath, Ramya Prabhu, Jayashree Mohan, Simon Peter, Ramachandran Ramjee +1 more
10/23/2024
cs.LGcs.DC

No official code found. Best implementation: microsoft/vattention (504 stars, MIT, last commit 2025-05-30).

Abstract

Each request in LLM inference goes through two phases: compute-bound prefill and memory-bandwidth-bound decode. To improve GPU utilization, recent systems use hybrid batching that combines the prefill and decode phases of different requests into the same batch. This approach optimizes linear operations but remains inefficient for attention computation because existing attention kernels specialize execution independently for the prefill and decode phases. In this paper, we present POD-Attention - the first GPU kernel that efficiently computes attention for hybrid batches. POD-Attention aims to maximize the utilization of both compute and memory bandwidth by carefully allocating the GPU's resources such that prefill and decode operations happen concurrently on the same multiprocessor. POD-Attention speeds up attention computation by up to $59\%$ (mean $28\%$), enabling higher throughput and lower latency LLM inference compared to the use of independently optimized prefill and decode attention kernels.

View on arXivView PDF

Code Implementations(1)

MIT

Dynamic Memory Management for Serving LLMs without PagedAttention

50442C, C++May 13, 20241 years agoMIT

Similar Papers

Cite this paper

@article{kamath2024podattention,
  title  = {POD-Attention: Unlocking Full Prefill-Decode Overlap for Faster LLM Inference},
  author = {Aditya K Kamath and Ramya Prabhu and Jayashree Mohan and Simon Peter and Ramachandran Ramjee and Ashish Panwar},
  year   = {2024},
  eprint = {2410.18038},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2410.18038v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2410.18038.svg)](https://codeofpaper.com/paper/2410.18038)

Discussion