From 7e23576efa9ea9738acc4a2aea701bb39b71c732 Mon Sep 17 00:00:00 2001 From: Daan Date: Mon, 3 Jun 2024 09:57:03 -0700 Subject: [PATCH] remove old mi_abandoned_await_readers --- include/mimalloc/internal.h | 1 - src/segment.c | 6 ------ 2 files changed, 7 deletions(-) diff --git a/include/mimalloc/internal.h b/include/mimalloc/internal.h index 0b6cf056..71cfad41 100644 --- a/include/mimalloc/internal.h +++ b/include/mimalloc/internal.h @@ -157,7 +157,6 @@ void _mi_segment_huge_page_reset(mi_segment_t* segment, mi_page_t* page, m void _mi_segments_collect(bool force, mi_segments_tld_t* tld); void _mi_abandoned_reclaim_all(mi_heap_t* heap, mi_segments_tld_t* tld); -void _mi_abandoned_await_readers(void); bool _mi_segment_attempt_reclaim(mi_heap_t* heap, mi_segment_t* segment); bool _mi_segment_visit_blocks(mi_segment_t* segment, int heap_tag, bool visit_blocks, mi_block_visit_fun* visitor, void* arg); diff --git a/src/segment.c b/src/segment.c index e484a38f..ca334ea4 100644 --- a/src/segment.c +++ b/src/segment.c @@ -509,7 +509,6 @@ static void mi_segment_os_free(mi_segment_t* segment, size_t segment_size, mi_se MI_UNUSED(fully_committed); mi_assert_internal((fully_committed && committed_size == segment_size) || (!fully_committed && committed_size < segment_size)); - _mi_abandoned_await_readers(); // prevent ABA issue if concurrent readers try to access our memory (that might be purged) _mi_arena_free(segment, segment_size, committed_size, segment->memid, tld->stats); } @@ -784,11 +783,6 @@ by scanning the arena memory (segments outside arena memoryare only reclaimed by a free). ----------------------------------------------------------- */ -// legacy: Wait until there are no more pending reads on segments that used to be in the abandoned list -void _mi_abandoned_await_readers(void) { - // nothing needed -} - /* ----------------------------------------------------------- Abandon segment/page ----------------------------------------------------------- */