English

Mesh: Compacting Memory Management for C/C++ Applications

Programming Languages 2020-04-30 v2 Data Structures and Algorithms Performance

Abstract

Programs written in C/C++ can suffer from serious memory fragmentation, leading to low utilization of memory, degraded performance, and application failure due to memory exhaustion. This paper introduces Mesh, a plug-in replacement for malloc that, for the first time, eliminates fragmentation in unmodified C/C++ applications. Mesh combines novel randomized algorithms with widely-supported virtual memory operations to provably reduce fragmentation, breaking the classical Robson bounds with high probability. Mesh generally matches the runtime performance of state-of-the-art memory allocators while reducing memory consumption; in particular, it reduces the memory of consumption of Firefox by 16% and Redis by 39%.

Keywords

Cite

@article{arxiv.1902.04738,
  title  = {Mesh: Compacting Memory Management for C/C++ Applications},
  author = {Bobby Powers and David Tench and Emery D. Berger and Andrew McGregor},
  journal= {arXiv preprint arXiv:1902.04738},
  year   = {2020}
}

Comments

Draft version, accepted at PLDI 2019

R2 v1 2026-06-23T07:39:30.749Z