WiSP:极低资源硬件上混合专家模型服务的工作集视角
WiSP: A Working-Set View of Mixture-of-Experts Serving on Extremely Low-Resource Hardware
AI总结:
针对低资源GPU上MoE模型因专家层CPU卸载导致稀疏性优势丧失的问题,提出工作集分页(WiSP)和边际价值工作集分配(MV-WSA),实现专家与KV缓存间VRAM动态分配,解码吞吐量提升至1.95倍。
摘要:
现代混合专家(MoE)模型将其大部分参数放置在专家层中,但对于任何令牌,仅使用这些专家中的一小部分。未使用的权重仍必须存储在GPU可以访问的地方。在商用GPU上,常见的解决方案是层级CPU卸载,这保持了较低的内存使用,但每次前向传播时会将一层的所有专家通过PCIe流式传输,从而失去了MoE稀疏性的大部分优势。我们将低资源MoE服务视为GPU上的工作集管理问题:路由专家权重和键值(KV)缓存是竞争有限VRAM的两个内存需求流。我们通过WiSP(工作集分页)实现了这一点,这是一个路由感知的专家分页器,可插入到未修改的服务引擎中,输出字节相同。通过仅保留工作负载重用的专家,当模型无法完全装入时,WiSP在相同内存预算下实现了高达静态卸载1.95倍的解码吞吐量。我们还发现,从预测路由中预取专家对单流解码帮助不大:瓶颈是PCIe带宽,而非预测准确性。这将问题从预取转向分配:VRAM应如何在专家和KV缓存之间分配?我们通过MV-WSA(边际价值工作集分配)来回答,它在给定KV准入下限的情况下,使每字节的边际延迟收益相等。MV-WSA既可以作为离线配置器运行,也可以作为在线控制器在服务过程中调整两个池的大小。在实际服务中,离线配置器是我们测试的唯一在预填充和解码上都表现良好的策略;在轨迹驱动模拟中,它保持在每个工作流预言机的几个百分点之内,而固定分割则差约20%。在线控制器在不改变模型输出的情况下进一步提升了1.20倍。
英文摘要:
Modern local and agentic workloads often need large-model capacity at low concurrency, but run on GPUs that cannot keep a frontier-scale model resident. Mixture-of-Experts (MoE) models are a natural fit because they activate only a small subset of experts per token, but their sparsity saves computation, not residency: the full expert pool still has to be stored, and any expert used by a layer must be in GPU memory when that layer runs. Static layer-level CPU offload makes such models fit, but transfers the expert layer in bulk on every forward pass, losing much of the sparsity advantage. We view low-resource MoE serving as a working-set problem on the GPU. Routed expert weights and the KV cache are two memory-demand streams competing for the same limited VRAM. We implement this view in WiSP (Working-Set Paging), a routing-aware expert pager that plugs into an unmodified serving engine and preserves byte-identical outputs. On a real 24 GiB RTX 3090, WiSP achieves up to 2.0x the decode throughput of static offload at the same memory budget when the model does not fit. A natural next step is to predict future experts and prefetch them. We find that this does not help in single-stream decode: the bottleneck is PCIe bandwidth, not prediction quality, so speculative transfers compete with demand transfers instead of hiding them. This shifts the design question from prefetching to allocation: how should one VRAM budget be divided between resident experts and the KV cache? We answer with MV-WSA (Marginal-Value Working-Set Allocation), which splits memory by marginal latency benefit per byte while enforcing a KV-admission floor. As a startup configurator, MV-WSA is the only policy we test that stays near-best on both prefill and decode; as a live controller, it resizes both pools while serving and reduces end-to-end time by up to 1.19x over a fixed offline split, without changing model outputs.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。