summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2022-12-04 16:41:15 -0500
committerBen Gamari <ben@smart-cactus.org>2023-01-09 15:22:49 -0500
commitb2763a5124f572925b2070a07a98dade35027cb2 (patch)
treef8af00e744d1d79b40bdd4d5ac70cf7757b6c093
parent2ab54d88a93558ae380844089db3683bc8f872f1 (diff)
downloadhaskell-b2763a5124f572925b2070a07a98dade35027cb2.tar.gz
nonmoving: Don't push if nonmoving collector isn't enabled
-rw-r--r--rts/sm/NonMoving.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/rts/sm/NonMoving.h b/rts/sm/NonMoving.h
index 64b4d74158..fe1d8eea99 100644
--- a/rts/sm/NonMoving.h
+++ b/rts/sm/NonMoving.h
@@ -344,7 +344,7 @@ INLINE_HEADER bool nonmovingClosureBeingSwept(StgClosure *p)
INLINE_HEADER bool isNonmovingClosure(StgClosure *p)
{
- return !HEAP_ALLOCED_GC(p) || Bdescr((P_)p)->flags & BF_NONMOVING;
+ return RtsFlags.GcFlags.useNonmoving && (!HEAP_ALLOCED_GC(p) || Bdescr((P_)p)->flags & BF_NONMOVING);
}
#if defined(DEBUG)