AI
Continuous Batching:按迭代粒度调度
· ☕ 8 分钟 · ✍️ k4i
为什么按 decode iteration 做调度能消除静态 batch 的 GPU 空转,以及 prefill 和 decode 如何被打包进同一次 forward。
Continuous Batching:按迭代粒度调度
Paged Attention:GPU 上的虚拟内存
· ☕ 7 分钟 · ✍️ k4i
vLLM 如何借鉴操作系统分页思想,消除 KV cache 显存碎片,将 GPU 显存利用率从约 30% 推到约 96%。
Paged Attention:GPU 上的虚拟内存
Triton 中的融合 Softmax
· ☕ 5 分钟 · ✍️ k4i
如何在 Triton 中编写融合 softmax kernel,消除冗余内存访问,性能超越 PyTorch 原生实现。
Triton 中的融合 Softmax