arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2610.15629cs.LG
收藏

精度的代价:面向混合精度大语言模型(LLM)服务的校准成本模型

The Price of Precision: A Calibrated Cost Model for Mixed-Precision LLM Serving

Advanced Micro Devices Inc. (AMD)(超威半导体公司(AMD));Cornell University(康奈尔大学)

Mukund Athmaram, Manoj Rao, Liang Ma

AI总结:

该研究针对混合精度LLM服务的速度-精度权衡问题,构建了考虑计算、权重加载、KV缓存等绑定资源的校准成本模型,将其作为预测器和分配器,通过动态规划选择配置并在三类硬件上验证了效果。

摘要:

为大语言模型(LLM)服务选择混合精度配置时,需要在速度与精度之间进行权衡。使用平均位宽或内存预算作为速度代理的分配器,可能会忽略限制执行的资源变化。我们认为,服务速度会受计算、权重加载或键值(KV)缓存访问的限制,具体取决于执行阶段、批量大小和上下文长度。基于字节的代理无法捕捉所有这些成本,因此更少的位并不总是意味着更快的服务。为解决这一差距,我们构建了一个考虑绑定资源的成本模型,并将其用于两个方面:第一,作为预测器,给定配置和操作点,它使用针对模型、GPU和服务栈校准的常数来估计服务延迟,我们在三类硬件上评估了其准确性;第二,作为分配器,我们将建模的时间成本与测得的每张量精度成本相结合,使用动态规划在延迟或精度预算下选择配置,我们将其配置与仅字节感知和仅灵敏度的分配进行了比较。

英文摘要:

Choosing a mixed-precision configuration for large language model (LLM) serving trades speed against accuracy. Allocators that use average bit-width or a memory budget as a speed proxy can miss changes in the resource that limits execution. We argue that served speed can be limited by compute, weight loading, or key-value (KV) cache access, depending on the phase, batch size, and context length. A byte-based proxy does not capture all of these costs, so fewer bits do not always mean faster serving. To address this gap, we build a cost model that accounts for the binding resource and use it in two ways. First, as a predictor: given a configuration and operating point, it estimates serving latency using constants calibrated for the model, GPU, and serving stack. We evaluate its accuracy across three hardware classes. Second, as an allocator: we combine modeled time costs with measured per-tensor accuracy costs and use a dynamic program to select a configuration under a latency or accuracy budget. We compare its configurations against byte-aware and sensitivity-only allocation.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑