SP-MoE:面向基于MoE模型推理加速的投机解码与预取技术
SP-MoE: Speculative Decoding and Prefetching for Accelerating MoE-based Model Inference
AI总结:
SP-MoE是首个SD感知的MoE专家卸载与流水线框架,通过投机性专家预取、截止层策略和异步流水线运行时,在多种模型和数据集上实现1.07-3.5倍TPOT加速。
摘要:
专家混合(MoE)架构已在大语言模型(LLM)中被广泛采用,以通过模型稀疏性降低计算成本。采用投机解码(SD)可以通过每步草拟多个token并并行验证来进一步加速MoE推理。然而,将MoE与SD结合会膨胀GPU内存,并在多token验证期间加剧CPU-GPU带宽争用。现有的MoE卸载系统不具备SD感知能力,无法解决这一瓶颈。我们提出SP-MoE,这是首个具备SD感知能力的专家卸载与计算-通信流水线框架。SP-MoE引入:(1)投机性专家预取,利用草稿模型与目标模型之间的结构对应关系,在验证之前预取可能需要的专家;(2)截止层策略,基于经验画像和分析性延迟模型限制每层预取深度,保证即时可用而不过度预取;(3)带异步预取线程和批量I/O的流水线运行时,以隐藏加载延迟。大量实验表明,SP-MoE在多种数据集、环境和基于MoE的模型上,相比最先进方法实现了1.07至3.5倍的TPOT加速。
英文摘要:
The Mixture-of-Experts (MoE) architecture has been widely adopted in large language models (LLMs) to reduce computation cost through model sparsity. Employing speculative decoding (SD) can further accelerate MoE inference by drafting multiple tokens per step and verifying them in parallel. However, combining MoE with SD inflates GPU memory and aggravates CPU-GPU bandwidth contention during multi-token verification. Existing MoE offloading systems are SD-agnostic and do not address this bottleneck. We present SP-MoE, the first SD-aware expert-offloading and compute-communication pipelining framework. SP-MoE introduces: (1) speculative expert prefetching that exploits structural correspondence between the draft and target models to prefetch likely experts ahead of verification; (2) a cutoff-layer policy that bounds per-layer prefetch depth based on empirical profiles and an analytical latency model, guaranteeing just-in-time availability without overfetch; and (3) a pipelined runtime with asynchronous prefetch threads and batched I/O to hide loading latency. Extensive experiments demonstrate that SP-MoE achieves a 1.07-3.5 times TPOT speedup over state-of-the-art methods across diverse datasets, environments, and MoE-based models.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。