MegaBlocks: Efficient Sparse Training with Mixture-of-Experts

By Trevor Gale, D. Narayanan, Cliff Young, Matei A. Zaharia. 2022

234 citations recorded by the source corpus.

We present MegaBlocks, a system for efficient Mixture-of-Experts (MoE) training on GPUs. Our system is motivated by the limitations of current frameworks, which restrict the dynamic routing in MoE layers to satisfy the constraints of existing software and hardware. These formulations force a tradeoff between model quality and hardware efficiency, as users must choose between dropping tokens from the computation or wasting computation and memory on padding. To address these limitations, we reformulate MoE computation in terms of block-sparse operations and develop new block-sparse GPU kernels that efficiently handle the dynamism present in MoEs. Our approach never drops tokens and maps efficiently to modern hardware, enabling end-to-end training speedups of up to 40% over MoEs trained with the state-of-the-art Tutel library and 2.4x over DNNs trained with the highly-optimized Megatron-LM framework.

Subfields: Artificial Intelligence, Large Language Models, Efficiency & Compression

How researchers see this paper

The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.

In Artificial Intelligence

  1. Marie-Anne Lachaux
  2. Devendra Singh Chaplot
  3. Dan Alistarh
  4. Elias Frantar
  5. Guillaume Lample
  6. Timothée Lacroix
  7. Albert Qiaochu Jiang
  8. Alexandre Sablayrolles

In Large Language Models

  1. Marie-Anne Lachaux
  2. Timothée Lacroix
  3. Elias Frantar
  4. Dan Alistarh
  5. Teven Le Scao
  6. Guillaume Lample
  7. Albert Qiaochu Jiang
  8. Lucile Saulnier

In Efficiency & Compression

  1. Elias Frantar
  2. Dan Alistarh
  3. Guillaume Lample
  4. Devendra Singh Chaplot
  5. Alexandre Sablayrolles
  6. Torsten Hoefler
  7. Saleh Ashkboos
  8. Zhuang Liu

Citations in the corpus