Remove prof_threshold built-in event. It is trivial to implement it as user event if needed

This commit is contained in:
Slobodan Predolac 2026-02-12 11:49:28 -08:00 committed by Guangli Dai
parent bee30a9cd3
commit 7bf49ca689
22 changed files with 1 additions and 270 deletions

View file

@ -12,8 +12,6 @@ extern bool opt_prof_active;
extern bool opt_prof_thread_active_init;
extern unsigned opt_prof_bt_max;
extern size_t opt_lg_prof_sample; /* Mean bytes between samples. */
extern size_t
opt_experimental_lg_prof_threshold; /* Mean bytes between thresholds. */
extern ssize_t opt_lg_prof_interval; /* lg(prof_interval). */
extern bool opt_prof_gdump; /* High-water memory dumping. */
extern bool opt_prof_final; /* Final profile dumping. */
@ -70,9 +68,6 @@ prof_sample_hook_t prof_sample_hook_get(void);
void prof_sample_free_hook_set(prof_sample_free_hook_t hook);
prof_sample_free_hook_t prof_sample_free_hook_get(void);
void prof_threshold_hook_set(prof_threshold_hook_t hook);
prof_threshold_hook_t prof_threshold_hook_get(void);
/* Functions only accessed in prof_inlines.h */
prof_tdata_t *prof_tdata_init(tsd_t *tsd);
prof_tdata_t *prof_tdata_reinit(tsd_t *tsd, prof_tdata_t *tdata);

View file

@ -27,10 +27,4 @@ typedef void (*prof_sample_hook_t)(const void *ptr, size_t size,
/* ptr, size */
typedef void (*prof_sample_free_hook_t)(const void *, size_t);
/*
* A callback hook that notifies when an allocation threshold has been crossed.
*/
typedef void (*prof_threshold_hook_t)(
uint64_t alloc, uint64_t dealloc, uint64_t peak);
#endif /* JEMALLOC_INTERNAL_PROF_HOOK_H */

View file

@ -1,8 +0,0 @@
#ifndef JEMALLOC_INTERNAL_THRESHOLD_EVENT_H
#define JEMALLOC_INTERNAL_THRESHOLD_EVENT_H
#include "jemalloc/internal/tsd_types.h"
extern te_base_cb_t prof_threshold_te_handler;
#endif /* JEMALLOC_INTERNAL_THRESHOLD_EVENT_H */

View file

@ -14,7 +14,6 @@ enum te_alloc_e {
te_alloc_stats_interval,
te_alloc_tcache_gc,
#ifdef JEMALLOC_STATS
te_alloc_prof_threshold,
te_alloc_peak,
#endif
te_alloc_user0,