diff --git a/include/jemalloc/internal/san.h b/include/jemalloc/internal/san.h index f97211a7..27adddb1 100644 --- a/include/jemalloc/internal/san.h +++ b/include/jemalloc/internal/san.h @@ -76,7 +76,7 @@ san_one_side_guarded_sz(size_t size) { } static inline bool -san_enabled(void) { +san_guard_enabled(void) { return (opt_san_guard_large != 0 || opt_san_guard_small != 0); } diff --git a/test/unit/hpa_background_thread.c b/test/unit/hpa_background_thread.c index 228b771b..ad7bac4b 100644 --- a/test/unit/hpa_background_thread.c +++ b/test/unit/hpa_background_thread.c @@ -129,7 +129,7 @@ TEST_BEGIN(test_hpa_background_thread_purges) { test_skip_if(!hpa_supported()); test_skip_if(!have_background_thread); /* Skip since guarded pages cannot be allocated from hpa. */ - test_skip_if(san_enabled()); + test_skip_if(san_guard_enabled()); unsigned arena_ind = create_arena(); /* @@ -145,7 +145,7 @@ TEST_BEGIN(test_hpa_background_thread_enable_disable) { test_skip_if(!hpa_supported()); test_skip_if(!have_background_thread); /* Skip since guarded pages cannot be allocated from hpa. */ - test_skip_if(san_enabled()); + test_skip_if(san_guard_enabled()); unsigned arena_ind = create_arena(); diff --git a/test/unit/retained.c b/test/unit/retained.c index 37ff88f6..aa9f6847 100644 --- a/test/unit/retained.c +++ b/test/unit/retained.c @@ -104,7 +104,7 @@ TEST_BEGIN(test_retained) { arena_ind = do_arena_create(NULL); sz = nallocx(HUGEPAGE, 0); - size_t guard_sz = san_enabled() ? SAN_PAGE_GUARDS_SIZE : 0; + size_t guard_sz = san_guard_enabled() ? SAN_PAGE_GUARDS_SIZE : 0; esz = sz + sz_large_pad + guard_sz; atomic_store_u(&epoch, 0, ATOMIC_RELAXED);