mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-06-04 11:14:20 +03:00
Prof: Add prof_unbias.
This gives more accurate attribution of bytes and counts to stack traces, without introducing backwards incompatibilities in heap-profile parsing tools. We track the ideal reported (to the end user) number of bytes more carefully inside core jemalloc. When dumping heap profiles, insteading of outputting our counts directly, we output counts that will cause parsing tools to give a result close to the value we want. We retain the old version as an opt setting, to let users who are tracking values on a per-component basis to keep their metrics stable until they decide to switch.
This commit is contained in:
parent
81c2f841e5
commit
60993697d8
5 changed files with 241 additions and 2 deletions
|
|
@ -1517,6 +1517,16 @@ malloc_conf_init_helper(sc_data_t *sc_data, unsigned bin_shard_sizes[SC_NBINS],
|
|||
}
|
||||
CONF_CONTINUE;
|
||||
}
|
||||
/*
|
||||
* Undocumented. When set to false, don't
|
||||
* correct for an unbiasing bug in jeprof
|
||||
* attribution. This can be handy if you want
|
||||
* to get consistent numbers from your binary
|
||||
* across different jemalloc versions, even if
|
||||
* those numbers are incorrect. The default is
|
||||
* true.
|
||||
*/
|
||||
CONF_HANDLE_BOOL(opt_prof_unbias, "prof_unbias")
|
||||
}
|
||||
if (config_log) {
|
||||
if (CONF_MATCH("log")) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue