Table of Contents
Fetching ...

Load Balancing for AI Training Workloads

Sarah McClure, Evyatar Cohen, Alex Shpiner, Mark Silberstein, Sylvia Ratnasamy, Scott Shenker, Isaac Keslassy

TL;DR

It is found that load-balancing based on packet spraying dominates traditional approaches that load balance traffic at flow, flowlet, or subflow granularities and that no leading approach achieves optimal O(1) queue scaling at maximum utilization.

Abstract

The extreme bandwidth demands of AI training has made load-balancing a critical component in AI fabrics, and a variety of load-balancing designs have emerged in recent work from both industry and research. However, there is currently little consensus on which design approach dominates or the conditions under which an approach dominates. We also lack an understanding of how far these approaches are from optimal. We provide a technical foundation for answering these questions by systematically evaluating leading load-balancing designs, while decoupling them from specific congestion control and loss recovery stacks. We find that load-balancing based on packet spraying dominates traditional approaches that load balance traffic at flow, flowlet, or subflow granularities. When comparing host- vs switch-based approaches to packet spraying, we find that they perform similarly in failure-free scenarios but that a host-based approach dominates under link failure because of its rapid visibility into end-to-end path conditions. We also identify that no leading approach achieves optimal O(1) queue scaling at maximum utilization. We demonstrate why a destination-based rotation (DR) discipline can reach this optimum and introduce Ofan, a switch-based implementation of DR that we show offers valuable performance gains over other packet spraying approaches.

Load Balancing for AI Training Workloads

TL;DR

It is found that load-balancing based on packet spraying dominates traditional approaches that load balance traffic at flow, flowlet, or subflow granularities and that no leading approach achieves optimal O(1) queue scaling at maximum utilization.

Abstract

The extreme bandwidth demands of AI training has made load-balancing a critical component in AI fabrics, and a variety of load-balancing designs have emerged in recent work from both industry and research. However, there is currently little consensus on which design approach dominates or the conditions under which an approach dominates. We also lack an understanding of how far these approaches are from optimal. We provide a technical foundation for answering these questions by systematically evaluating leading load-balancing designs, while decoupling them from specific congestion control and loss recovery stacks. We find that load-balancing based on packet spraying dominates traditional approaches that load balance traffic at flow, flowlet, or subflow granularities. When comparing host- vs switch-based approaches to packet spraying, we find that they perform similarly in failure-free scenarios but that a host-based approach dominates under link failure because of its rapid visibility into end-to-end path conditions. We also identify that no leading approach achieves optimal O(1) queue scaling at maximum utilization. We demonstrate why a destination-based rotation (DR) discipline can reach this optimum and introduce Ofan, a switch-based implementation of DR that we show offers valuable performance gains over other packet spraying approaches.

Paper Structure

This paper contains 35 sections, 7 theorems, 6 equations, 18 figures, 3 tables.

Key Result

Theorem 1

Simple RR and JSQ suffer from a linear growth of the queue size with the message size:

Figures (18)

  • Figure 1: Completion times (increase over ideal) for different load balancing schemes with a perfect loss recovery protocol. Adaptive techniques are denoted with "AR" (adaptive routing).
  • Figure 2: Switches that must update routing and/or load balancing state based on a link failure. The pod with the failure must update state for all routes, and many nodes in other pods must update routes and weights for traffic destined to Pod 1.
  • Figure 3: CCT increase for randomized failures with a per-link failure rate of 1%, with $\boldsymbol{G=\infty}$ (i.e., convergence time $>$ CCT).
  • Figure 4: CCT increase over best possible under random link failures (1% fail rate) for host adaptive (dashed and shaded) compared to an in-network rebalancing approach with different delays (x-axis). The CCT lower bound accounts for the failure (uses $\rho_{\text{max}}$).
  • Figure 5: Impact of randomized link failure rates with $G=0$. CCT is normalized to best-case without failures.
  • ...and 13 more figures

Theorems & Definitions (7)

  • Theorem 1
  • Theorem 2
  • Theorem 3
  • Theorem 4
  • Theorem 5
  • Theorem 6
  • Theorem 7