Live data from Hacker News

Jemalloc Postmortem

jasone.github.io

11–20 of 250 posts

Re: Jemalloc Postmortem

#11
post #5
post #3

Oh that's interesting. jemalloc is the memory allocator used by redis, among other projects. Wonder what the performance impact will be if they have to change allocators.

Why would they have to change? Sometimes software development is largely "done" and there isn't much more you need to do to a library.

Jemalloc is used as an easy performance boost probably by every major Ruby on Rails server.

Re: Jemalloc Postmortem

#12
post #8
post #5

Earlier quoted context omitted.

Why would they have to change? Sometimes software development is largely "done" and there isn't much more you need to do to a library.

Technology marches on, and in some number of years other allocators will exist that outperform/outfeature jemalloc.

Presumably then the performance impact of any switch will be positive.

Re: Jemalloc Postmortem

#14
post #4

The article mentioned the influence of large-scale profiling on both jemalloc and tcmalloc, but doesn't mention mimalloc. I consider mimalloc to be on par with these others, and now I am wondering whether Microsoft also used large scale profiling to develop theirs, or if they just did it by dead reckoning.

How does mimalloc telemetry compare to jemalloc?

Re: Jemalloc Postmortem

#16
I very recently used jemalloc to resolve a memory fragmentation issue that caused a service to OOM every few days. While jemalloc as it is will continue to work, same as it does today, I wonder what allocator I should reach for in the future. Does anyone have any experiences to share regarding tcmalloc or other allocators that aim to perform better than stock glibc?

Re: Jemalloc Postmortem

#17
post #16

I very recently used jemalloc to resolve a memory fragmentation issue that caused a service to OOM every few days. While jemalloc as it is will continue to work, same as it does today, I wonder what allocator I should reach for in the future. Does anyone have any experiences to share regarding tcmalloc or other allocators that aim to perform better than stock glibc?

snmalloc

Re: Jemalloc Postmortem

#19
I believe there’s no other allocator besides jemalloc that can seamlessly override macOS malloc/free like people do with LD_PRELOAD on Linux (at least as of ~2020). jemalloc has a very nice zone-based way of making itself the default, and manages to accommodate Apple’s odd requirements for an allocator that have tripped other third-party allocators up when trying to override malloc/free.

Re: Jemalloc Postmortem

#20
Nice post -- so does Facebook no longer use jemalloc at all? Or is it maintenance mode?

Or I wonder if they could simply use tcmalloc or another allocator these days?

Facebook infrastructure engineering reduced investment in core technology, instead emphasizing return on investment.

Post reply on HN