{"slug": "benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips", "title": "Benchmarking MoE Training on Ironwood, Part 1: Scaling to 8K Chips", "summary": "Google Cloud benchmarked DeepSeek-V3 671B pre-training on its seventh-generation Ironwood (TPU7x) TPUs, training the model in 1.70 minutes on 8,192 chips with all communication kept inside a single inter-chip interconnect domain. The FSDP + EP track, built on MaxText and JAX, reached 56% effective model FLOPs utilization (EMFU) at 2,048 chips, with convergence scaling efficiency of 96% from 2,048 to 4,096 chips and 74% from 2,048 to 8,192 chips. Between September 28 and October 5, one week of optimization raised throughput per chip by 1.56–1.82× at all three scales while holding the model, dataset, global batch of 16,384 sequences of 4,096 tokens, and target log perplexity of 3.6 fixed.", "body_md": "Large Mixture-of-Experts (MoE) models stress every part of a training system: compute, memory, and interconnect. To evaluate how [Ironwood (TPU7x)](https://docs.cloud.google.com/tpu/docs/tpu7x), Google Cloud's seventh-generation TPU, handles this class of workload, we benchmarked DeepSeek-V3 671B pre-training. As an open-weight, industry-standard model combining multi-head latent attention (MLA), 256 fine-grained routed experts, and multi-token prediction (MTP), DeepSeek-V3 reflects the architectural demands of today's large-scale MoEs. Holding the model, dataset, global batch size, and target validation loss fixed, we measured time to train—the wall-clock time to reach that target—at 2,048, 4,096, and 8,192 chips.\n\nEach Ironwood chip delivers 4,614 TFLOP/s of FP8 compute and 192 GiB of HBM at 7.38 TB/s, and a single pod connects up to 9,216 chips over the inter-chip interconnect (ICI). We trained DeepSeek-V3 in 1.70 minutes on 8,192 chips, with all communication inside one ICI domain. At 2,048 chips, the final result reached an effective model FLOPs utilization (EMFU) of 56%. Convergence scaling efficiency was 96% from 2,048 to 4,096 chips and 74% from 2,048 to 8,192 chips. In internal runs, we also measured nearly 100% efficiency from 512 to 2,048 chips, using gradient accumulation to keep the global batch size the same.\n\nWe pursued this work in two workstreams. This post covers the first, the FSDP + EP track that built a MaxText recipe matching the reference training setup, scaled it to 8,192 chips, and developed many of the features our final configuration relies on: the FP8 quantization recipe, Pallas kernels for grouped matmuls and token sorting, attention optimizations, MoE token chunking with dropless fallback, rematerialization and tile size tuning, and pre-run warm-up. This track could not hide every collective. At 8,192 chips, the small per-device batch leaves little compute to overlap with communication, so the EP reduce-scatter remains exposed. The batch-split schedule hides nearly all of these collectives, and we will share details about it in Part 2 of this series later this month.\n\nThis post explains how we scaled and optimized a 671B-parameter Mixture-of-Experts (MoE) model with MaxText and JAX on Google Cloud TPUs in a matter of weeks. For each optimization, we describe the bottleneck it addressed, how it works, and what it gained, and we close with the lessons that carry over to other large MoE models.\n\nWe trained with a global batch of 16,384 sequences of 4,096 tokens at every scale, and each run stops at the first evaluation at or below a log perplexity of 3.6. In one week of optimization, from September 28 to October 5, the FSDP + EP track raised throughput per chip by 1.56–1.82× at all three scales while keeping the model, dataset, global batch size, and target loss unchanged.\n\nWe kept the global batch at 16,384 sequences at every scale, so adding chips divides the same work more finely. Two settings share the batch: the per-device batch size (PBS), the number of sequences each JAX device processes per micro-step, and gradient accumulation (GA), the number of micro-steps per optimizer step. Each Ironwood chip is built from two chiplets, each with one TensorCore, two SparseCores, and 96 GiB of HBM, joined by a die-to-die (D2D) link six times faster than a 1D ICI link. JAX exposes each TensorCore as a device, so chips × 2 × PBS × GA = 16,384. We swept PBS 1, 2, and 4 from 512 to 8,192 chips.\n\nAn Ironwood pod connects up to 9,216 chips in a 3D torus with 1.2 TB/s of bidirectional ICI bandwidth per chip, so a single slice can keep all of its communication on ICI rather than the data center network (DCN), which provides 100 Gb/s per chip. To take advantage of this, our device mesh uses two axes: heavy fully sharded data parallelism (FSDP) and modest expert parallelism (EP). The 3D torus lets FSDP span the whole slice, but pure FSDP at 8,192 chips would all-gather all 256 experts' weights onto every chip for every layer. Each chip's tokens would also be spread so thinly across the experts that the expert matmuls become HBM-bound. Also, most of the model's tensor dimensions don't divide evenly 16,384 ways, so splitting every weight that finely would require costly padding or relayouts. Adding EP fixes both problems. Each chip gathers only its own experts' weights, which cuts weight traffic and HBM footprint by the EP degree, and pooling tokens across the EP group keeps the expert matmuls compute-bound. We ruled out tensor parallelism (TP), which lowers arithmetic intensity on the small expert dimension (see the [arithmetic intensity guide](https://github.com/AI-Hypercomputer/maxtext/blob/15bee862df851916df65fe81da5cc284be9372ce/docs/guides/optimization/sharding.md)), and pipeline parallelism (PP), whose bubbles outweighed its communication savings at these scales. Table 1 lists the best configuration at each scale in our setting.\n\nThe two axes play different roles in different layers. The details vary slightly by scale, but at a high level:\n\nUp to 2,048 chips, scaling is nearly linear. In Figure 2, each PBS line runs parallel to the dashed linear-scaling line: doubling the chips at a fixed PBS halves GA and speeds up the run by 1.93–2.07×. The linear fits in Figure 2 show why. At a fixed PBS, end-to-end time is a straight line in GA (R² > 0.999). Most of it is micro-step work, which scales with GA, plus a fixed 15–30 seconds per run of once-per-step work such as gradient reduction and the optimizer update. Because that fixed part is small next to end-to-end times at these scales, halving GA nearly halves the time. As Table 2 shows, the fastest configuration from 512 to 2,048 chips (PBS 4) reaches 97–100% scaling efficiency relative to 512 chips, at essentially constant chip time.\n\nPast 2,048 chips, there is no gradient accumulation left to remove. At 2,048 chips with PBS 4, GA is already 1, so each further doubling of chips must halve the PBS instead: to 2 at 4,096 chips and to 1 at 8,192. Smaller PBS are less efficient. At 512–2,048 chips, where all three PBS values fit, Figure 2 shows PBS 2 running 6–9% slower than PBS 4 at the same chip count, and PBS 1 running 33–35% slower. As a result, the fastest configuration drops to 81% scaling efficiency at 4,096 chips and 66% at 8,192 (Table 2). Most of the loss at 8,192 chips comes from the smaller PBS, not from the extra chips: compared with PBS 1 at 512 chips, the PBS 1 run at 8,192 chips still reaches 89% of linear scaling. Recovering the rest requires hiding communication behind less compute per device, which is the focus of the batch-split schedule in Part 2.\n\nWe worked in two phases. First, a roofline analysis bounded what each part of the step could achieve under the FSDP + EP sharding, given Ironwood's per-chip compute, HBM bandwidth, and ICI bandwidth. Then we profiled the step, picked the largest gap between measured and achievable time, optimized it, and measured again. The optimizations fall into five categories, described below.\n\n**GMM v2****.** Each routed expert processes only the tokens assigned to it, so the expert layers are grouped matrix multiplications (GMMs) whose per-expert row counts change at every step. Switching from Tokamax's ragged-dot kernel (v1) to MaxText's GMM v2 kernel, which is built on Tokamax GMM v2, improved end-to-end throughput by ~10%. The ragged-dot kernel tiles rows on a fixed grid, so each tile that straddles an expert boundary is loaded (DMA) and computed in full once per expert, then masked. GMM v2 starts tiles at each expert's first row and sizes both the memory loads and the matmul to the valid rows, which cuts most of that waste.\n\n[**Splash attention**](https://github.com/openxla/tokamax/tree/714a68df36a8c42e7a58077cb8665a94fa4b0761/tokamax/_src/ops/splash_attention). Two changes reduce wasted attention work:\n\n[**Ragged sort**](https://github.com/AI-Hypercomputer/maxtext/tree/92c9a9e2491bc9d6744b33a7ae10b0a3322f2e79/src/maxtext/kernels/ragged). Before the expert GMMs, each device sorts the tokens routed to its local experts; afterward, it unsorts them, applies the routing weights, and sums the top-k outputs from its local experts (the EP reduce-scatter then completes each token's sum). In the all-gather/reduce-scatter EP path, each device first all-gathers tokens across the EP group, but only a dynamically determined subset of them is routed to the experts on any given rank, so each rank's active token slice is ragged. Without a ragged kernel, the sort and unsort permute the full EP-all-gathered buffer, moving 8× or 16× (the EP degree) more token data than the rank needs. We integrated ragged gather and ragged gather-reduce kernels into MaxText for this path: they read the rank's start and end offsets, computed from the per-expert group sizes at runtime, and use indirect DMA to move only the tokens routed to its local experts. Because gather and gather-reduce are each other's transpose, the backward pass reuses the same two kernels with their roles swapped.\n\nFP8 was the largest single win: on 512 chips with PBS=1, it cuts step time by 31%, from 4.375 s to 3.015 s (Figure 4). Ironwood runs FP8 natively in its matrix units: each chip peaks at 4,614 TFLOP/s in FP8, twice its 2,307 TFLOP/s in BF16, and FP8 tensors take half the bytes of BF16 in HBM and over ICI. Our recipe takes advantage of both. Faster matmuls were the smaller part of the gain: switching the matmuls to FP8 saved only 4.7%, because matmuls are only part of each step and quantization adds work outside the matrix units. Even with FP8 splash attention included, compute accounts for only 19% of the total saving. About two-thirds (68%) came from quantized-collective features. Most came from the quantized weight all-gather, which turns the expert weight-gradient all-reduce into a reduce-scatter; the quantized token all-gather and backward pre-quantization add the rest by sending FP8 payloads, which halves their bytes and avoids re-quantizing downstream. Static scaling and weight layout account for the remaining 13%.\n\nPer-feature gains are config-dependent: our 2,048–8,192-chip recipes use a wider FSDP axis than this ablation, and at 2,048 and 4,096 chips a larger PBS, which changes which collectives are exposed and how much of the step is spent in matmuls. The split between compute and communication savings can therefore differ at those scales.\n\nFigure 5 shows how a routed MoE layer uses FP8. In the forward pass, each device quantizes its weight shard to E4M3 before the FSDP all-gather (quantized weight all-gather, QWAG) and its tokens before the EP all-gather (quantized token all-gather, QTAG). Both collectives move half the bytes. The ragged sort moves FP8 rows, and the up-projection GMM consumes FP8 on both sides without re-quantizing. The down-projection input, the BF16 output of SwiGLU, is quantized inside the GMM kernel. In the backward pass, the gradient of the combine is quantized to E5M2 with a fixed scale before the EP all-gather, so the all-gather and unsort (a ragged gather) also move FP8. The router stays in FP32, and the weight-gradient reduce-scatter stays in BF16.\n\nStatic scales are fast, but they need care. A dynamic scale computes the absolute maximum of each tensor on every step, which adds a reduction and, for sharded tensors, a cross-device collective. Static scales remove that work, and they let each device cast its own shard to FP8 before an all-gather without first agreeing on a global maximum. The cost is tuning. We calibrated the backward bounds from runs with dynamic scales and tuned them per scale. For numerical stability, the router and gate logits stay in FP32, and the LM head stays in BF16.\n\n**Token chunking**. The flag [num_moe_token_chunks](https://github.com/AI-Hypercomputer/maxtext/blob/92c9a9e2491bc9d6744b33a7ae10b0a3322f2e79/src/maxtext/configs/base.yml#L308) splits a routed MoE layer's tokens into N chunks along the sequence. Each chunk runs the full path (token all-gather, top-k, sort, GMMs, unsort, reduce-scatter), so the routing buffers and intermediate activations only need to hold one chunk at a time. Chunking also gives XLA the opportunity to overlap one chunk's token communication with another chunk's expert compute.\n\n**Ragged buffer factor**. Each device needs a buffer for the tokens routed to its experts. A balanced load needs `(all-gathered tokens / EP) × top_k` rows. In the worst case, every token sends all of its copies to the experts on one device, which needs an EP times the balanced buffer: 8× at EP 8 and 16× at EP 16. Reserving that much HBM for every layer is not affordable, so [ragged_buffer_factor](https://github.com/AI-Hypercomputer/maxtext/blob/92c9a9e2491bc9d6744b33a7ae10b0a3322f2e79/src/maxtext/configs/base.yml#L318) sizes the buffer between the two, trading HBM against the chance of overflow. Like the original DeepSeek-V3 training, our recipe is dropless, so an overflow must never drop tokens. We added two fallback modes, selected with `moe_dropless_fallback`.\n\nAt 2,048 chips with a PBS of 4, HBM usage is already about 90%, so that recipe uses full rematerialization. The 4,096- and 8,192-chip recipes use a custom [rematerialization policy](https://github.com/AI-Hypercomputer/maxtext/blob/92c9a9e2491bc9d6744b33a7ae10b0a3322f2e79/src/maxtext/configs/base.yml#L588-L620) (remat_policy: custom) that keeps selected tensors in HBM, so the backward pass reads them instead of recomputing them:\n\nWe also tuned the tile sizes of the flash attention and GMM v2 kernels separately at each scale. For example, up-projection forward tiles drop from 512 rows at 2,048 chips to 256 rows at 4,096 and 8,192 chips, and up-projection weight-gradient tiles drop from 1,024 to 512 rows. Evaluation, which splits each sequence across chips, also uses smaller attention blocks at 8,192 chips: 256 tokens instead of 512.\n\nWe measure time to train from the start of training, so a slow first step counts directly toward it. On 8,192 chips, our first step took about 55s, compared with about 4s at steady state, and most of that was spent waiting for the first training batch. Two causes stood out:\n\nIn one week, the FSDP + EP track turned a reference-matching MaxText recipe into one that scales to 8,192 Ironwood chips at 1.56–1.82x its starting throughput per chip with every run inside a single ICI domain. At 2,048 chips, it reached 3,736 tokens/s/chip with an EMFU of 42.8%, and scaling from 512 to 2,048 chips was nearly 100% efficient, using gradient accumulation to keep the global batch size the same. Past 2,048 chips, efficiency fell to 66% at 8,192 chips, mostly because each device's batch shrank: at a fixed PBS of 1, 8,192 chips still reached 89% of linear scaling from 512 chips.\n\nFive lessons carry over to other large MoE models:\n\nMuch of this work carried into our final configuration. What this track could not solve was the large, exposed EP reduce-scatter at 8,192 chips, where each device has the least compute to hide it behind. Part 2 describes the batch-split schedule that hides nearly all of it.\n\nThe recipes for all three scales (2,048, 4,096, and 8,192 Ironwood chips) are available in the MaxText repository at [benchmarks/deepseek3_671b_tpu7x](https://github.com/AI-Hypercomputer/maxtext/tree/32eb86f05e50557f844c18433c9bcf44a47cf8ce/benchmarks/deepseek3_671b_tpu7x). Each recipe includes the full configuration used in this post, so you can reproduce our results or use them as a starting point for your own MoE models.\n\nThis optimization work was a massive collaborative effort across engineering and management teams. We would like to express our gratitude to the following contributors who drove this initiative to success:\n\n<sup>Ran Ran, Matt Davidow, Nuojin Cheng, Shuning Jin, Suraj Kolla, Zhengxian He, Daniel Mandragona, Shuwen Fang, Snehal Verma, Amanda Tomlinson, Burkay Donderici, Kevin Wang, Jesse Lu, Caitlin Stanton, Mohamed Omar, Vipul Aneja, Cory Kleinheksel, Xiongfei Wei, Ani Udipi, Vaibhav Singh, Jet Jiang, Andi Gavrilescu, Durlabh Malik ,Deepak Patil, Carlos Araya.</sup>", "url": "https://wpnews.pro/news/benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips", "canonical_source": "https://developers.googleblog.com/benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips/", "published_at": "2026-11-30 17:13:34.693816+00:00", "updated_at": "2026-11-30 17:13:37.712709+00:00", "lang": "en", "topics": ["ai-infrastructure", "ai-chips", "machine-learning", "ai-research"], "entities": ["Google Cloud", "Ironwood", "TPU7x", "DeepSeek-V3", "MaxText", "JAX"], "also_reported_by": [], "takeaway": "On Ironwood, DeepSeek-V3 671B pre-training reached a 3.6 log-perplexity target in 1.70 minutes on 8,192 chips at 56% EMFU on 2,048 chips, with convergence scaling efficiency of 96% from 2,048 to 4,096 chips and 74% from 2,048 to 8,192 chips.", "recommendation": {"advice": "Keep the global batch fixed at 16,384 sequences and sweep per-device batch size 1, 2, and 4 with gradient accumulation to hold it constant as you scale chips; this yielded 96% scaling efficiency from 2,048 to 4,096 chips.", "playbook": "training-data", "playbook_url": "https://wpnews.pro/playbooks/training-data"}, "alternates": {"html": "https://wpnews.pro/news/benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips", "markdown": "https://wpnews.pro/news/benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips.md", "text": "https://wpnews.pro/news/benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips.txt", "jsonld": "https://wpnews.pro/news/benchmarking-moe-training-on-ironwood-part-1-scaling-to-8k-chips.jsonld"}}