diff --git a/include/jemalloc/internal/thread_event.h b/include/jemalloc/internal/thread_event.h index 3a848829..5b5bb9fb 100644 --- a/include/jemalloc/internal/thread_event.h +++ b/include/jemalloc/internal/thread_event.h @@ -5,6 +5,12 @@ /* "te" is short for "thread_event" */ +/* + * TE_MIN_START_WAIT should not exceed the minimal allocation usize. + */ +#define TE_MIN_START_WAIT ((uint64_t)1U) +#define TE_MAX_START_WAIT UINT64_MAX + /* * Maximum threshold on thread_(de)allocated_next_event_fast, so that there is * no need to check overflow in malloc fast path. (The allocation size in malloc diff --git a/include/jemalloc/internal/tsd.h b/include/jemalloc/internal/tsd.h index 0f9ec12b..18bdb8fd 100644 --- a/include/jemalloc/internal/tsd.h +++ b/include/jemalloc/internal/tsd.h @@ -86,14 +86,14 @@ typedef ql_elm(tsd_t) tsd_link_t; /* reentrancy_level */ 0, \ /* narenas_tdata */ 0, \ /* thread_allocated_last_event */ 0, \ - /* thread_allocated_next_event */ TE_MIN_START_WAIT, \ + /* thread_allocated_next_event */ 0, \ /* thread_deallocated_last_event */ 0, \ - /* thread_deallocated_next_event */ TE_MIN_START_WAIT, \ - /* tcache_gc_event_wait */ TE_MIN_START_WAIT, \ - /* tcache_gc_dalloc_event_wait */ TE_MIN_START_WAIT, \ - /* prof_sample_event_wait */ TE_MIN_START_WAIT, \ + /* thread_deallocated_next_event */ 0, \ + /* tcache_gc_event_wait */ 0, \ + /* tcache_gc_dalloc_event_wait */ 0, \ + /* prof_sample_event_wait */ 0, \ /* prof_sample_last_event */ 0, \ - /* stats_interval_event_wait */ TE_MIN_START_WAIT, \ + /* stats_interval_event_wait */ 0, \ /* stats_interval_last_event */ 0, \ /* prof_tdata */ NULL, \ /* prng_state */ 0, \ @@ -131,12 +131,6 @@ typedef ql_elm(tsd_t) tsd_link_t; /* test data */ MALLOC_TEST_TSD_INITIALIZER -/* - * TE_MIN_START_WAIT should not exceed the minimal allocation usize. - */ -#define TE_MIN_START_WAIT ((uint64_t)1U) -#define TE_MAX_START_WAIT UINT64_MAX - #define TSD_INITIALIZER { \ TSD_DATA_SLOW_INITIALIZER \ /* state */ ATOMIC_INIT(tsd_state_uninitialized), \