From f1185aa63edcf1ba355434c1d6eaa95095801cb1 Mon Sep 17 00:00:00 2001 From: Yi Lin Date: Mon, 4 Mar 2024 23:30:12 +0000 Subject: [PATCH] disable other heuristics to trigger full heap gc --- src/gc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/gc.c b/src/gc.c index 627acb2b7dc4e..b1a1fa09289a0 100644 --- a/src/gc.c +++ b/src/gc.c @@ -2724,6 +2724,10 @@ static int _jl_gc_collect(jl_ptls_t ptls, jl_gc_collection_t collection) sweep_full = 1; recollect = 1; } + if (jl_options.fixed_heap_size) { + // For fixed heap size, do not trigger full sweep for any other heuristics + sweep_full = 0; + } if (next_sweep_full) { next_sweep_full = 0; sweep_full = 1;