Summary (Overview)
- Core contribution: TEMPO introduces a makespan-aware expert-parallel (EP) load balancer for Mixture-of-Experts (MoE) serving, replacing token-count or activation-count proxies with a calibrated two-regime time model of expert computation.
- Key finding: Real hardware measurements show expert cost is neither linear in tokens nor in expert count—it's flat below ~156-168 tokens per expert (weight streaming dominates) and linear above (compute dominates), with a tile-staircase mechanism underlying both.
- Main result: On real batches, the dispatches produced by existing proxy policies differ by 1.4-1.6× in modeled block time (p95 up to 1.7×), and the best policy flips with the operating regime—no fixed proxy wins everywhere.
- Algorithm: A millisecond-scale solver combining cost-aware seeding, augmenting-chain activation rebalancing, bottleneck local search with partial migrations, and an ensemble with switching tolerance; achieves within 1.02% of a 10-second MILP at ~2 ms.
- Deployment: SGLang integration with zero in-graph kernels and collectives; end-to-end results show 4-6% throughput gains on Qwen3-235B (inside win region), ~15.6% p99 latency reduction, while DeepSeek-V3 (outside win region) shows no gain—a falsifiable phase diagram predicts both outcomes.
Introduction and Theoretical Foundation
The EP Synchronization Problem
In expert-parallel (EP) Mixture-of-Experts serving, each MoE layer ends at a synchronization point: the time a batch spends in the MoE block equals the time of the slowest GPU. Production dispatchers balance proxies—token counts (EPLB, LPLB, UltraEP) or activated-expert counts (METRO)—implicitly assuming expert time is linear in one of these two quantities.
The Measured Cost Model
Measurements on two generations of datacenter GPUs show the cost is two-regime:
where:
- = number of activated (expert, replica) pairs on GPU
- = token count on GPU
- = activation floor (cost of streaming one more replica's weights from HBM): 1.74 µs (Qwen3-30B) to 14.8 µs (DeepSeek-V3)—an 8.5× spread
- = per-token compute cost in the linear regime
Key hardware mechanisms:
- Weight streaming floor: Below ≈156-168 tokens per expert, cost attaches to activated replicas, not tokens—the expert's weights must be streamed from HBM regardless of token count.
- M-tile padding: Grouped GEMM rounds tokens to 128-token M-tiles, so splitting an expert across replicas rounds up times—fragmenting experts manufactures padded compute.
The tile-aware extension:
Mixed Regimes Are the Common Case
92-100% of real decode batches contain both regimes simultaneously: hot experts sit deep in the linear region carrying ~91% of tokens, while roughly half of activated experts remain in the flat region. This is the pivotal empirical fact that makes proxy-based balancing systematically wrong.
Methodology
Problem Formulation: Fixed-Charge Makespan Dispatch
Given per-expert token counts , replica sets , token shares (supported on ), and activation indicators :
Theorem 1 (NP-hardness): Deciding whether a dispatch with makespan ≤ T exists is NP-complete, already with 2 GPUs, full replication, and . Reduction from Balanced PARTITION.
Degenerate cases are polynomial:
- : reduces to min-max token LP (LPLB/UltraEP objective)
- : reduces to optimal semi-matching (polynomial via augmenting paths)
Theorem 2 (Additive approximation): Under full replication, a descending-token round-robin placement achieves .
The Phase Diagram
Sweeping synthetic Zipf(s) routing over batch size per GPU, skew , replication {1.25, 1.5}×, EP {8..64}:
- Best fixed policy flips across the map: activation balancing wins at small B (memory-bound), token-LP at large B (compute-bound)
- The flip boundary is analytically predictable: where and
The tempo fast Solver
Four stages, each targeting a failure mode:
- Cost-aware greedy seeding: Experts placed whole on replica with lowest marginal cost—fragmenting cold experts is the token-LP mistake
- Activation rebalancing via augmenting chains: 1- and 2-step chains (truncated semi-matching augmenting paths)
- Bottleneck local search with partial migrations: Ternary-search partial splits in the linear regime
- Ensemble with switching tolerance: Score token-LP and round-robin certificates under the model; switch only if >1% better
Calibration Method
Black-box calibration on the deployed pipeline: run a (G,N) grid, log per-GPU (G,N,t), fit the two-piece max-affine by alternating assignment. About ten minutes per (kernel, dtype, hardware) combination.
Empirical Validation / Results
Phase Diagram and Scale (Calibrated Simulation)
- TEMPO tracks the per-cell best everywhere (min gain ≥ -0.3%, inside the 1% ensemble band)
- Wins by up to 8.5% (DSv3) / 10.2% (Qwen3) / 11.8% (DSv2, 1.5× replication) in the mixed zone
- At EP 8→64: mean 6-6.5% at s=0 on EP32-64 (max 15.5%), collapsing to 0 exactly where theory predicts
Wall-Clock Microbenchmark (8-GPU Testbed A, EP8)
- At B=32 (memory-bound): TEMPO beats EPLB-even by 11-14% and token-LP by 7%
- At B=2048 (compute-bound): METRO is 7-11% off best; TEMPO ties token-LP at top
- TEMPO within 5% of per-B best fixed policy across all B; every fixed policy has a ≥7% failure region
End-to-End Serving Results (Testbed B)
Qwen3-235B (inside win region):
- GovReport (long-prefill): +5.0% median throughput (non-overlapping ranges)
- Under Poisson load: p99 TPOT −15.6% (191 vs 226 ms), median TTFT −12.5%
- ShareGPT: parity (−0.2% throughput, −8.9% p99)
DeepSeek-V3 (outside win region):
- Every workload lands at −2 to −3%, indistinguishable from noop control
- The pair of models brackets the phase diagram's win region
Multi-Node EP16 (Testbed B)
- With fresh placement: static, TEMPO, and noop tie within noise (zero-tax result)
- Under drift-16: flat table loses −3.5% at 1024 requests; topology-aware split recovers +4.1%
- Qwen3-235B EP16: TEMPO +4.1% decode-heavy, +7.2% with topology-aware split; SGLang dynamic rebalancer negative throughout
Table 1: Modeled Block Time of Proxy Dispatches vs. TEMPO
| B | static | uniform | token-LP | METRO | spread |
|---|---|---|---|---|---|
| 128 | 1.17/1.27 | 1.51/1.60 | 1.17/1.27 | 1.11/1.18 | 1.37/1.46 |
| 512 | 1.47/1.58 | 1.12/1.20 | 1.00/1.00 | 1.05/1.10 | 1.47/1.58 |
| 1024 | 1.56/1.70 | 1.04/1.10 | 1.00/1.00 | 1.06/1.12 | 1.56/1.70 |
Table 4: Policy Landscape (Block Makespan Relative to Static)
| Policy kernel | 0.25×(floor-bound) | 1×(mixed) | 4×(token-bound) |
|---|---|---|---|
| uniform (dynamic) | 1.299 | 1.052 | 0.659 |
| token-LP (LPLB/UltraEP) | 1.006 | 0.836 | 0.630 |
| METRO (activation) | 0.950 | 0.815 | 0.672 |
| LLEP-R (least-loaded) | 0.984 | 0.835 | 0.662 |
| TEMPO (time model) | 0.856 | 0.764 | 0.630 |
Table 5: Four-Way Attribution on Qwen3-235B 2-Node EP16
| workload | dynamic | noop | flat | hier |
|---|---|---|---|---|
| decode-heavy (128/256) | -2.6% | +5.4% | +4.1% | +7.2% |
| GovReport (long prefill) | -1.9% | +4.6% | +4.4% | +6.1% |
| ShareGPT | -0.7% | +0.4% | +2.1% | +0.4% |
| oasst1 (saturated) | -1.2% | +2.0% | +0.7% | +0.9% |
| oasst1 (Poisson 16 req/s) | -0.6% | -2.5% | -1.8% | -2.9% |
| short decode (64/256) | -0.4% | -0.8% | +0.3% | -0.1% |
Table 3: Prediction vs. Measurement
| B | regime | block ratio | Δthr. (w1/w2) | expert share |
|---|---|---|---|---|
| 32 | floor | 0.902 | -1.5%/-1.5% | 46% |
| 64 | floor | 0.902 | +4.6%/+4.1% | — |
| 128 | floor | 0.902 | +3.3%/+2.9% | 51% |
| 256 | floor | 0.907 | +4.0%/+2.6% | — |
| 512 | traffic | 0.880 | -2.8%/+0.0% | 31% |
| 768 | traffic | 0.871 | -1.3%/-2.1% | — |
| 1024 | traffic | 0.865 | -0.6%/-1.1% | 27% |
Component Ablation (Table 2)
| variant | mean | p95 | max (region) |
|---|---|---|---|
| no partial moves | 0.6% | 4.1% | 16.3% (EP32 transition) |
| no aug. chains | 0.3% | 1.8% | 2.7% (mid-B flat) |
| no ensemble | 0.4% | 2.8% | 4.5% (EP64 compute) |
Theoretical and Practical Implications
Theoretical Contributions
- Formal hardness framework: The fixed-charge makespan problem is PN-complete even at 2 GPUs with full replication, yet polynomial in each degenerate limit—the hardness lives in the regime interaction, mirroring the systems observation that each proxy works at home and fails in the transition zone
- Additive approximation guarantee: Round-robin whole-expert placement achieves OPT + max(b, βn_max) under full replication, with a certificate that the deployed solver inherits
- Analytically predictable phase boundary: The flip between activation-balancing and token-LP winners follows a closed-form prediction matching observed behavior in 12/12 grid columns
Practical Implications
- Deployment-ready: Solver runs out-of-process in milliseconds; zero kernels and zero collectives on the critical path
- Win region is conditional and mapped: Adaptive dispatch pays only within a batch-size band (B=64-256 at EP8) bracketing , with placement staleness, tight replica budgets, and sufficient expert compute share
- Architecture matters as much as objective: Like-for-like port of token-LP shows most of the gap between TEMPO and SGLang's shipped dispatcher is due to integration architecture, not the objective
- Complementary to placement: Dispatch repairs the latency tail; only placement repairs the mean—the two layers partition the problem
Conclusion
TEMPO's core claim is "balance time, not tokens." A ten-minute black-box calibration reveals the two-regime structure of expert cost; a phase diagram shows every fixed proxy has a failure region while the regimes coexist inside single batches 92-100% of the time; and a makespan solver over the calibrated model tracks the per-regime best everywhere at millisecond cost.
The win region requires three coordinates: moderate experts-per-GPU, sufficient skew, and expert compute a large enough share of the step. The measured results bracket the predicted region: Qwen3-235B (inside) gains 4-6% throughput and cuts p99 latency by ~15.6%; DeepSeek-V3 (outside) returns only mechanism cost.
The paper carefully disclaims limitations: headline numbers are model-space (L1), testbeds are limited to 8-16 GPUs (L2), the win region is conditional and mapped (L3), calibration is static (L4), the (G,N) model has a floor (L5), and the deployed system is not the theoretical optimum by design (L6). The durable contribution is the map itself—as MoE serving consolidates around fp8 grouped kernels, large-expert flagships, and multi-node expert parallelism, dispatching on measured time rather than counted tokens is both principled and profitable.
Related papers
- Dense Contexts Are Hard Contexts: Lexical Density Limits Effective Context in LLMs
Lexical density, not just length, causally degrades LLM retrieval, activating lost-in-the-middle effects at contexts far below advertised limits.
- OasisKV: Scaling In-Decode KV Cache Beyond HBM with Lookahead Sparse Prefetching
OasisKV uses speculative decoding's draft tokens to predict future KV-cache access, enabling asynchronous prefetching that boosts LLM inference throughput up to 2.1x with negligible accuracy loss.
- EvoMem: Memory-Augmented Evolution for Code Optimization
EvoMem's persistent memory of successful mutation strategies yields a 6.40% average performance gain and 5.93x speedup in LLM-based evolutionary code search.