Relationship between opt.prof and opt.prof_leak

Evan Jones ejones at twitter.com
Fri Nov 6 09:50:38 PST 2015


Jemalloc's profiling and leak debugging features are super useful, and I've
used them multiple times to figure out Java native memory leak issues.
However, I realized I'm not actually sure how the opt.prof and
opt.prof_leak options relate. I *think* they work like the following, but I
didn't find the docs super clear, and I only looked at the code for about
10 minutes. I'm happy to submit a patch to the docs to try and clarify
this, once I understand it completely:


* There is only one type of dump. It contains both "allocated" counts and
"in use" counts (or free counts which can be used to calculate in use).
* By default, jeprof will show you the *in use* counts. However, it can
show you the *allocated* counts instead with --alloc_space or
--alloc_objects.
* By default, dumps are "incremental": They contain the objects allocated
since the last dump. If you want dumps that contain everything since the
process was started, enable opt.prof_accum.


Are these statements accurate? Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://jemalloc.net/mailman/jemalloc-discuss/attachments/20151106/44b9a0e6/attachment.html>


More information about the jemalloc-discuss mailing list