Skip to content

Collect jemalloc stats

We should consider providing a mechanism that collects jemalloc statistics so that we can see how heap growth and fragmentation develop over time. This is not visible from the perspective of the Ruby VM or Ruby GC'ed heap.

jemalloc implements malloc_stats_print for this: https://github.com/jemalloc/jemalloc/wiki/Getting-Started

It can generate a JSON report to stderr.

Edited by Matthias Käppler