Mixture-of-Experts kernel engineering on Amazon SageMaker AI
AWS engineers share kernel optimizations for fused Mixture-of-Experts (MoE) models on Amazon SageMaker AI: Swap-AB for WGMMA utilization, Triton backend routing for FP8 quantization, and eliminating Triton JIT recompilation.

This article discusses kernel optimizations for fused Mixture-of-Experts (MoE) models on Amazon SageMaker AI, focusing on techniques like Swap-AB for WGMMA utilization, Triton backend routing for FP8 quantization, and eliminating Triton JIT recompilation.
What happened
AWS engineers detailed kernel optimizations for fused Mixture-of-Experts (MoE) models on Amazon SageMaker AI, including Swap-AB for WGMMA utilization, Triton backend routing for FP8 quantization, and eliminating Triton JIT recompilation. These techniques aim to improve performance and efficiency in MoE model inference.
Why it matters
These optimizations are crucial for AI developers and technology professionals as they enhance the performance of large-scale MoE models, reducing latency and improving throughput. This is particularly important for businesses relying on efficient AI inference and users benefiting from faster response times.
- Fused MoE models require kernel optimizations to handle their complexity and improve performance.
- Matrix transposition techniques like Swap-AB can significantly enhance hardware utilization in MoE models.
- Using the Triton backend for FP8 quantization reduces memory overhead and improves throughput.
- Eliminating JIT recompilation through annotations can reduce latency and improve multi-GPU coordination.
- These optimizations are available in AWS LMI and vLLM, making them accessible for practical implementation.
The bigger picture
The optimizations improve the efficiency and performance of MoE models, leading to higher throughput and lower latency. This benefits businesses by reducing costs and improving user experience, and it supports the development of more scalable AI systems.
AWS engineers have implemented and open-sourced kernel optimizations for fused MoE models on Amazon SageMaker AI, resulting in improved performance and efficiency. These techniques are available in AWS LMI and vLLM, offering significant benefits for AI developers and businesses.
Technical details
- Fused MoE: Merges token routing, data shuffling, and expert computations into a single GPU operation.
- WGMMA (Warp Group Matrix Multiply Accumulate): A NVIDIA Hopper architecture instruction protocol for maximizing tensor processing throughput.
- FP8 quantization: A method to reduce memory usage and improve inference speed by using 8-bit floating-point numbers.
- Triton backend: A compiler framework that optimizes kernel execution by consolidating operations into a single hardware pass.
- JIT (Just-In-Time) recompilation: A process where kernels are compiled at runtime, which can introduce latency if not managed properly.
FAQ
What is a Fused Mixture-of-Experts (MoE) model?
A Fused MoE model is an architecture that merges token routing, data shuffling, and expert computations into a single GPU operation, improving latency but increasing kernel complexity.
How does the Swap-AB technique improve performance?
Swap-AB transposes matrices to align with the Hopper GPU's WGMMA requirements, improving hardware utilization and throughput by 2-4%.
What is the benefit of using the Triton backend for FP8 quantization?
The Triton backend consolidates operations into a single hardware pass, reducing memory overhead and improving throughput by 10% compared to CUTLASS.
How does eliminating JIT recompilation help in MoE model inference?
By using do_not_specialize annotations, JIT recompilation is eliminated, reducing TTFT by 9% and improving multi-GPU coordination.
Where can these optimizations be accessed?
These optimizations are available in AWS LMI v28 and vLLM 0.22.0 or later, and are implemented in the LMI Deep Learning Container on Amazon SageMaker AI.
This summary and analysis were generated with AI from the original article and may contain errors. Read the original for the full story.
Read the full story
Originally published by AWS ML Blog on Oct 13, 2026.
Comments
Sign in to join the discussion.