summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2022-10-22 21:15:24 +0000
committerMarge Bot <ben+marge-bot@smart-cactus.org>2023-03-08 15:02:30 -0500
commit81d6cc551c7a843002495d3ffd2373ad00a52766 (patch)
treed465196162d8e3a90a1bc0ca87b6d653cb5806ec
parent99d144d56598965daba30aa73e6c598b3245bb0f (diff)
downloadhaskell-81d6cc551c7a843002495d3ffd2373ad00a52766.tar.gz
nonmoving: Fix tracking of FILLED_SWEEPING segments
Previously we only updated the state of the segment at the head of each allocator's filled list.
-rw-r--r--rts/sm/NonMoving.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rts/sm/NonMoving.c b/rts/sm/NonMoving.c
index d7e4d943fb..3326dc69c5 100644
--- a/rts/sm/NonMoving.c
+++ b/rts/sm/NonMoving.c
@@ -1073,6 +1073,7 @@ static void nonmovingMark_(MarkQueue *mark_queue, StgWeak **dead_weaks, StgTSO *
while (true) {
// Set snapshot
nonmovingSegmentInfo(seg)->next_free_snap = seg->next_free;
+ SET_SEGMENT_STATE(seg, FILLED_SWEEPING);
n_filled++;
if (seg->link) {
seg = seg->link;
@@ -1081,7 +1082,6 @@ static void nonmovingMark_(MarkQueue *mark_queue, StgWeak **dead_weaks, StgTSO *
}
}
// add filled segments to sweep_list
- SET_SEGMENT_STATE(seg, FILLED_SWEEPING);
seg->link = nonmovingHeap.sweep_list;
nonmovingHeap.sweep_list = filled;
}