mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-04-19 00:43:16 +03:00
Bypass witness_fork in TSD when !config_debug.
With the tcache change, we plan to leave some blank space when !config_debug (unused tbins, witnesses) at the end of the tsd. Let's not touch the memory.
This commit is contained in:
parent
0fba57e579
commit
4dec507546
1 changed files with 9 additions and 0 deletions
|
|
@ -96,16 +96,25 @@ witnesses_cleanup(tsd_t *tsd) {
|
|||
|
||||
void
|
||||
witness_prefork(tsd_t *tsd) {
|
||||
if (!config_debug) {
|
||||
return;
|
||||
}
|
||||
tsd_witness_fork_set(tsd, true);
|
||||
}
|
||||
|
||||
void
|
||||
witness_postfork_parent(tsd_t *tsd) {
|
||||
if (!config_debug) {
|
||||
return;
|
||||
}
|
||||
tsd_witness_fork_set(tsd, false);
|
||||
}
|
||||
|
||||
void
|
||||
witness_postfork_child(tsd_t *tsd) {
|
||||
if (!config_debug) {
|
||||
return;
|
||||
}
|
||||
#ifndef JEMALLOC_MUTEX_INIT_CB
|
||||
witness_list_t *witnesses;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue