Efficient Memory Management for Large Language Model Serving with PagedAttention
Woosuk Kwon, Z. Li, Siyuan Zhuang, Ying Sheng, L Zheng, Cody Hao Yu, Joseph E. Gonzalez, Hao Zhang 等 9 位
Berkeley College University of California, Berkeley Stanford University University of California San Diego
阅读操作
确认中在文库中上传 PDF 后可生成中文音频讲解。
摘要与影响
High throughput serving of large language models (LLMs) requires batching sufficiently many requests at a time. However, existing systems struggle because the key-value cache (KV cache) memory for each request is huge and grows and shrinks dynamically. When managed inefficiently, this memory can be significantly wasted by fragmentation and redundant duplication, limiting the batch size. To address this problem, we propose PagedAttention, an attention algorithm inspired by the classical virtual memory and paging techniques in operating systems. On top of it, we build vLLM, an LLM serving system that achieves (1) near-zero waste in KV cache memory and (2) flexible sharing of KV cache within and across requests to further reduce memory usage. Our evaluations show that vLLM improves the throughput of popular LLMs by 2--4× with the same level of latency compared to the state-of-the-art systems, such as FasterTransformer and Orca. The improvement is more pronounced with longer sequences, larger models, and more complex decoding algorithms. vLLM's source code is publicly available at https://github.com/vllm-project/vllm.
逐年被引趋势
关键指标
同类平均 = 1
同领域 · 同年份 · 同类型
Google Scholar 与 OpenAlex 的被引统计范围不同,数值存在差异属正常。
AI 辅助阅读
依据:摘要
可就本文提问;依据不足时会说明。
学术脉络
学科主题
计算机 / AITopic Modeling
Natural Language Processing Techniques · Caching and Content Delivery
参考文献 19
此处列出前 3 条
引用本文 1,457
按被引量排序,此处列出前 3 条