Is your batch size the problem? Revisiting the Adam-SGD gap in language modeling

Teodora Srećković, Jonas Geiping, Antonio Orvieto

Abstract

Adam is often observed to significantly outperform Stochastic Gradient Descent (SGD) on Transformer-based language models, a phenomenon that has puzzled optimization researchers for years and for which several explanations have been proposed. In this work, we revisit this "optimizer gap" by training over 1000 Transformer language models and studying how batch size, training budget, model scale, momentum, and gradient clipping affect rankings. The resulting picture is not a monolithic Adam-SGD separation: at a fixed token budget, SGD is inefficient compared to Adam when common batch size values are used; however, while Adam's performance is only marginally affected when reducing the batch size, well-tuned SGD quickly catches up in this regime, drastically shrinking the gap. Interestingly, SignSGD with momentum behaves similarly to Adam as the batch size varies. We revisit existing explanations for the optimizer gap, including heavy-tailed class imbalance, directional sharpness, and heterogeneity. These lenses describe important aspects of SGD failure, but do not explain why increasing stochasticity can shrink the Adam-SGD gap without performance deterioration. Motivated by this, we study SignSGD as the simplest algorithm that exhibits the relevant batch-size dependence. Combining intuition from stochastic differential equations with nonconvex bounds, we isolate a simple mechanism directly affecting convergence rates: signed methods have a batch-dependent mean update, whereas unclipped SGD's drift is unchanged by batch size.
BibTeX
@article{sreckovic2026is,
  author = {Teodora Srećković and Jonas Geiping and Antonio Orvieto},
  title = {{Is your batch size the problem? Revisiting the Adam-SGD gap in language modeling}},
  journal = {Accepted by TMLR},
  year = {2026},
  url = {https://openreview.net/forum?id=1spcnOJogl},
}

Loading related content...

Figure