hackertube.io

"Compacting the Uncompactable" by Bobby Powers

Strange Loop Conference · talk · Watch on YouTube

What it is

Bobby Powers presents Mesh, a drop-in malloc replacement that eliminates memory fragmentation in unmodified C/C++ programs by compacting memory. The talk covers how it works despite C's fixed object addresses, and its benefits for programs like Redis.

Why Hacker News recommends it

Recommended as a great talk on solving fragmentation for C/C++ and runtimes like Ruby and Python without code changes.

  • 3 people recommended it
  • 3 different months
  • 0 strong recommendations
  • first 2020, last 2025

What HN commenters said

  1. “how to make a malloc() and free() that perform compaction”

    Talk on a malloc that compacts memory to return it to the OS.

    remexre, 2020-12 · Recommendation · in “How the Python object system works”

  2. “There was a great talk at Strange Loop about a drop-in malloc replacement which compacts.”

    Drop-in compacting malloc replacement that improved memory use in projects like Redis.

    rtfeldman, 2022-07 · Recommendation · in “Reference count, don't garbage collect”

  3. “also a good presentation about it on youtube.”

    Presentation on merging sparse memory pages, a kind of garbage collection for C/C++.

    superjan, 2025-01 · Recommendation · in “Using black magic to make a fast circular buffer (2017)”

Excerpts from Hacker News comments, linked to the originals. Summaries and labels were written by a language model from those comments.

Topics: malloc, memory fragmentation, compaction, mesh, c++

Also recommended by the same people