Making FP8 Work at Scale

DeepSeek-V3's runtime reduces waiting caused by expert communication, but moving and multiplying all those activations still consumes memory and compute. The question here is how the model uses FP8—a lower-precision number format—without allowing rounding error to destabilize training. The answer is not to convert every tensor and hope for a speedup. DeepSeek-V3 assigns precision by operation, scales values in small groups, periodically restores accumulation precision, and keeps selected weights and gradients in safer formats. That makes FP8 a systems design with explicit failure conditions.

Lower precision is a constrained budget

A matrix multiplication combines many products and sums. In a large language model, these operations account for much of the compute, so a format that uses fewer bits can increase compute density and reduce the amount of data that must be stored or moved. FP8 is attractive for that reason. But the same reduction in numerical range and detail that makes it efficient can cause trouble during training. Activations, weights, and gradients can contain outliers. A single unusually large value can force a shared scale that makes most other values too coarse, while an accumulation of many small products can lose information before the result is written down.

DeepSeek-V3's framework treats precision as a budget. The three dense linear operations associated with a matrix layer—forward propagation, the backward pass for activation gradients, and the backward pass for weight gradients—are executed in FP8. Their outputs may be produced in BF16 or FP32. This is where the dense compute benefit is concentrated. The report says this arrangement theoretically doubles computational speed compared with the original BF16 method, but that is a statement about the operation's potential, not an end-to-end measurement of training time.

Other operations remain in higher precision. The embedding module, output head, MoE gating modules, normalization operators, and attention operators use BF16 or FP32. The master weights and weight gradients remain in FP32, and the optimizer's moment states use BF16 rather than FP32. Keeping these pieces out of the lowest-precision path protects the parts of the optimization process that are more sensitive or inexpensive enough that their higher-precision cost is acceptable.

This division is easy to misunderstand. “FP8 training” does not mean that the model's entire state is eight-bit. It means that the most compute-dense matrix multiplications and selected stored activations use FP8, while numerically sensitive operations and recovery state retain more precision. A format switch applied everywhere could save memory in a narrow accounting while damaging the update signal that determines whether the model learns. Selective precision is therefore not a compromise added after the optimization; it is the mechanism that makes the optimization viable.

Activation storage is part of the same budget. Because the weight-gradient matrix multiplication consumes activations during back-propagation, DeepSeek-V3 caches many of them in FP8 rather than keeping them in BF16. In the MoE path, activations before the expert up-projections are quantized to FP8 before dispatch. Their smaller representation reduces memory use and communication volume as tokens travel to experts.