summaryrefslogtreecommitdiff
path: root/rts/sm/NonMovingMark.c
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2019-10-18 16:21:19 -0400
committerBen Gamari <ben@smart-cactus.org>2019-10-20 21:15:52 -0400
commit4a44ab330285643a6bee6acc6bd47d44118a6def (patch)
tree9ec6b94725cf9bda4fc418a43eb4c5b87a25750d /rts/sm/NonMovingMark.c
parentdd1b4fddacf398f120099268538a358c6f6f4761 (diff)
downloadhaskell-4a44ab330285643a6bee6acc6bd47d44118a6def.tar.gz
rts: Shrink size of STACK's dirty and marking fields
Diffstat (limited to 'rts/sm/NonMovingMark.c')
-rw-r--r--rts/sm/NonMovingMark.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/rts/sm/NonMovingMark.c b/rts/sm/NonMovingMark.c
index b273b09b05..9d046ce068 100644
--- a/rts/sm/NonMovingMark.c
+++ b/rts/sm/NonMovingMark.c
@@ -595,9 +595,9 @@ void updateRemembSetPushStack(Capability *cap, StgStack *stack)
{
// N.B. caller responsible for checking nonmoving_write_barrier_enabled
if (needs_upd_rem_set_mark((StgClosure *) stack)) {
- StgWord marking = stack->marking;
+ StgWord8 marking = stack->marking;
// See Note [StgStack dirtiness flags and concurrent marking]
- if (cas(&stack->marking, marking, nonmovingMarkEpoch)
+ if (cas_word8(&stack->marking, marking, nonmovingMarkEpoch)
!= nonmovingMarkEpoch) {
// We have claimed the right to mark the stack.
debugTrace(DEBUG_nonmoving_gc, "upd_rem_set: STACK %p", stack->sp);
@@ -1341,11 +1341,11 @@ mark_closure (MarkQueue *queue, StgClosure *p, StgClosure **origin)
case STACK: {
// See Note [StgStack dirtiness flags and concurrent marking]
StgStack *stack = (StgStack *) p;
- StgWord marking = stack->marking;
+ StgWord8 marking = stack->marking;
// N.B. stack->marking must be != nonmovingMarkEpoch unless
// someone has already marked it.
- if (cas(&stack->marking, marking, nonmovingMarkEpoch)
+ if (cas_word8(&stack->marking, marking, nonmovingMarkEpoch)
!= nonmovingMarkEpoch) {
// We have claimed the right to mark the stack.
mark_stack(queue, stack);