diff options
author | Ben Gamari <ben@smart-cactus.org> | 2022-10-22 21:04:16 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2023-03-08 15:02:30 -0500 |
commit | 58e53bc4d33dad76b3250997f1a8300d0041f387 (patch) | |
tree | 9b1f97fef6fe6d16ff6fa8e3515e548b6a27d939 /rts/sm/NonMoving.h | |
parent | 81d6cc551c7a843002495d3ffd2373ad00a52766 (diff) | |
download | haskell-58e53bc4d33dad76b3250997f1a8300d0041f387.tar.gz |
nonmoving: Assert state of swept segments
Diffstat (limited to 'rts/sm/NonMoving.h')
-rw-r--r-- | rts/sm/NonMoving.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/rts/sm/NonMoving.h b/rts/sm/NonMoving.h index 45ece3aa6a..1f82a77a93 100644 --- a/rts/sm/NonMoving.h +++ b/rts/sm/NonMoving.h @@ -47,8 +47,10 @@ enum NonmovingSegmentState { }; #define SET_SEGMENT_STATE(seg, st) RELAXED_STORE(&(seg)->state, (st)) +#define ASSERT_SEGMENT_STATE(seg, st) ASSERT(RELAXED_LOAD(&(seg)->state) == (st)) #else #define SET_SEGMENT_STATE(_seg,_st) +#define ASSERT_SEGMENT_STATE(_seg, _st) #endif // A non-moving heap segment |