mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-07-24 05:33:06 +00:00
Add forking handling for stats
This commit is contained in:
15
src/stats.c
15
src/stats.c
@@ -1526,3 +1526,18 @@ stats_boot(void) {
|
||||
|
||||
return counter_accum_init(&stats_interval_accumulated, stats_interval);
|
||||
}
|
||||
|
||||
void
|
||||
stats_prefork(tsdn_t *tsdn) {
|
||||
counter_prefork(tsdn, &stats_interval_accumulated);
|
||||
}
|
||||
|
||||
void
|
||||
stats_postfork_parent(tsdn_t *tsdn) {
|
||||
counter_postfork_parent(tsdn, &stats_interval_accumulated);
|
||||
}
|
||||
|
||||
void
|
||||
stats_postfork_child(tsdn_t *tsdn) {
|
||||
counter_postfork_child(tsdn, &stats_interval_accumulated);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user