<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Paged Attention - 标签 - 华华的小站</title><link>http://blog.zyhector.com/tags/paged-attention/</link><description>Paged Attention - 标签 - 华华的小站</description><generator>Hugo -- gohugo.io</generator><language>zh-CN</language><lastBuildDate>Tue, 24 Mar 2026 14:55:00 -0700</lastBuildDate><atom:link href="http://blog.zyhector.com/tags/paged-attention/" rel="self" type="application/rss+xml"/><item><title>「从零开始学大模型」PagedAttention</title><link>http://blog.zyhector.com/2026/03/05-pagedattention/</link><pubDate>Tue, 24 Mar 2026 14:55:00 -0700</pubDate><author>Hector</author><guid>http://blog.zyhector.com/2026/03/05-pagedattention/</guid><description><![CDATA[<h2 id="概述">概述</h2>
<p>Paged Attention 要解决的，是 KV Cache 显存浪费的问题。</p>
<p>一般来说，为了放下 KV Cache，会预先 alloc 出一大块显存，但是 KV Cache 大学又是随着推理进行不断增长，是一个动态的逐渐增大的存储需求。此外，在多个序列同时进行推理时，各个序列的长度不同，对应的 KV Cache 也不一样，此时也不方便为不同序列配置不一样大小的显存。</p>]]></description></item></channel></rss>