通过优化算法与硬件协同,实现激活低秩分解的高效计算。
D-com: Accelerating Iterative Processing to Enable Low-rank Decomposition of Activations
- 采用渐进式分解与Lanczos算法,结合专用加速架构。
- 实测在A100上降低22%端到端延迟,速度提升6.2倍。
- 适合大规模语言模型推理场景,尤其关注低延迟需求者。
大语言模型的参数规模已突破万亿级别,计算与内存开销持续增长。为应对挑战,研究者探索了低秩分解等模型压缩技术。以往工作多聚焦于权重分解以避免运行时开销,但激活分解常导致显著延迟增加(如在A100上处理4K序列长度的Llama2-7b时,端到端延迟高出38%)。本文推翻此观点,表明在合理算法与硬件支持下,输入激活分解可显著受益。我们采用渐进式分解算法、Lanczos算法,并设计专用协处理器架构;针对分解操作的内存瓶颈,提出新型计算复制方法,将其推向计算密集区,实现6.2倍加速;同时开发输出形状保持计算方案,消除连续层间的分解开销;为弥补压缩带来的性能损失,引入多通道分解策略,独立处理异常通道,在保持高精度和低困惑度的同时仅增加极少计算成本。综合效果下,我们的加速器D-com在模型质量小幅下降(如在AI2 Reasoning Challenge任务上仅降3%)的前提下,相较A100 GPU实现22%的端到端延迟降低。
原文摘要 · Abstract (English)
The computation and memory costs of large language models kept increasing over last decade, which reached over the scale of 1T parameters. To address the challenges from the large scale models, model compression techniques such as low-rank decomposition have been explored. Previous model decomposition works have focused on weight decomposition to avoid costly runtime decomposition, whose latency often significantly exceeds the benefits from decomposition (e.g., 38% more end-to-end latency when running Llama2-7b on A100 with 4K sequence length with activation decomposition compared to no decomposition). In this work, we debunk such observations and report that the input decomposition can be significantly beneficial with a proper choice of decomposition algorithm and hardware support. We adopt progressive decomposition algorithm, Lanczos algorithm, and design a co-accelerator architecture for the decomposition algorithm. To address the memory- boundness of the decomposition operation, we introduce a novel compute replication methodology that moves the op- eration toward compute-bound region, which enables 6.2x speedup in our evaluation. We also develop an output shape- preserving computation scheme that eliminates decomposi- tion costs in consecutive layers. To compensate model quality loss from compression, we introduce a multi-track decom- position approach that separately handles outlier channels for high accuracy and low perplexity with minimal compu- tational costs. Combined together, our accelerator, D-com, provides 22% end-to-end latency improvements compared to A100 GPU at the cost of small model quality degradation (e.g., 3% on AI2 Reasoning Challenge task).
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。