diff options
-rw-r--r-- | rts/sm/NonMoving.h | 1 | ||||
-rw-r--r-- | rts/sm/NonMovingMark.c | 6 |
2 files changed, 3 insertions, 4 deletions
diff --git a/rts/sm/NonMoving.h b/rts/sm/NonMoving.h index 25208aceb2..3d7b5771e6 100644 --- a/rts/sm/NonMoving.h +++ b/rts/sm/NonMoving.h @@ -296,7 +296,6 @@ INLINE_HEADER void nonmovingSetClosureMark(StgPtr p) nonmovingSetMark(nonmovingGetSegment(p), nonmovingGetBlockIdx(p)); } -// TODO: Audit the uses of these /* Was the given closure marked this major GC cycle? */ INLINE_HEADER bool nonmovingClosureMarkedThisCycle(StgPtr p) { diff --git a/rts/sm/NonMovingMark.c b/rts/sm/NonMovingMark.c index 2fd85dc4f0..bde650d0de 100644 --- a/rts/sm/NonMovingMark.c +++ b/rts/sm/NonMovingMark.c @@ -1872,7 +1872,7 @@ void nonmovingMarkDeadWeak (struct MarkQueue_ *queue, StgWeak *w) void nonmovingMarkLiveWeak (struct MarkQueue_ *queue, StgWeak *w) { - ASSERT(nonmovingClosureMarkedThisCycle((P_)w)); + ASSERT(nonmovingIsNowAlive((P_)w)); markQueuePushClosure_(queue, w->value); markQueuePushClosure_(queue, w->finalizer); markQueuePushClosure_(queue, w->cfinalizers); @@ -1886,9 +1886,9 @@ void nonmovingMarkDeadWeaks (struct MarkQueue_ *queue, StgWeak **dead_weaks) { StgWeak *next_w; for (StgWeak *w = nonmoving_old_weak_ptr_list; w; w = next_w) { - ASSERT(!nonmovingClosureMarkedThisCycle((P_)(w->key))); + ASSERT(!nonmovingIsNowAlive((P_)(w->key))); nonmovingMarkDeadWeak(queue, w); - next_w = w ->link; + next_w = w->link; w->link = *dead_weaks; *dead_weaks = w; } |