Fuse-All MoE:面向TPU的负载均衡MoE推理内核
Fuse-All MoE Inference Kernel with Load Balancing on TPUs
Fuse-All MoE是一种TPU内核设计,将token收集、专家投影、门控激活与输出写回融合,并把专家计算中间结果保留在片上。在PD分离服务中,它通过调度与专家重分布平衡EP16 prefill负载,decode阶段用对称EP8TP2在两个TensorCore间共享活跃专家计算。
arXiv:2611.17857v1 Announce Type: new Abstract: Mixture-of-Experts (MoE) architectures activate only a subset of experts for each token, allowing large language models (LLMs) to scale parameter capacity without a proportional increase in computation per token. However, intermediate data movement and uneven expert loads limit the efficiency of MoE inference on TPUs. To address these bottlenecks, we introduce Fuse-All MoE, a TPU kernel design that jointly optimizes expert computation, output communication, and load balancing. The kernel fuses token collection, expert projections, gated activation, and output writes, retaining expert computation intermediates on chip. Fixed token-slot destinations allow scheduling and expert placement to change while preserving routing semantics. In prefill-decode (PD) disaggregated serving, Fuse-All MoE balances EP16 prefill workloads through scheduling and expert redistribution, while symmetric EP8TP2 shares active expert computation between the two TensorCore devices within each chip during decode. Our experiments show that Fuse-All MoE reduces kernel runtime for a measured skewed EP16 prefill workload from 2.3x to 1.09x the same fixed reference time for a balanced workload. Across 32-512 decode tokens, symmetric EP8TP2 reduces kernel latency by up to 21.3% relative to fused EP16. With accompanying serving stack optimizations, the integrated system improves serving throughput by up to 34.5% over the Megablox EP16 baseline.
来源:arXiv (AI + Vision + Imaging) · arxiv.org