diff --git a/core/tiny_region_id.h b/core/tiny_region_id.h index 28c58fb9..cdcd21d2 100644 --- a/core/tiny_region_id.h +++ b/core/tiny_region_id.h @@ -234,8 +234,7 @@ static inline void* tiny_region_id_write_header(void* base, int class_idx) { PTR_TRACK_MALLOC(base, 0, class_idx); // Track at BASE (where header is) // ========== ALLOCATION LOGGING (Debug builds only) ========== - // NOTE: This logging is ALWAYS active (not guarded by HAKMEM_BUILD_RELEASE) - // because we need to track allocations even in optimized debug builds +#if !HAKMEM_BUILD_RELEASE { extern _Atomic uint64_t g_debug_op_count; extern __thread TinyTLSSLL g_tls_sll[]; @@ -247,6 +246,7 @@ static inline void* tiny_region_id_write_header(void* base, int class_idx) { fflush(stderr); } } +#endif // ========== END ALLOCATION LOGGING ========== // Optional guard: log stride/base/user for targeted class