summaryrefslogtreecommitdiff
path: root/rts/sm/GCThread.h
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2021-01-01 20:56:02 -0500
committerMarge Bot <ben+marge-bot@smart-cactus.org>2021-01-09 21:21:37 -0500
commit83ac5594d101440f72dc0ead97f0d1583056c07d (patch)
treeeefd71c530bab1cd245c13dadf9bffd6dbc13729 /rts/sm/GCThread.h
parent3d15d8d008307a19314c23eeb65b8ead448f0b37 (diff)
downloadhaskell-83ac5594d101440f72dc0ead97f0d1583056c07d.tar.gz
rts: Use SEQ_CST accesses when touching `wakeup`
These are the two remaining non-atomic accesses to `wakeup` which were missed by the original TSAN patch.
Diffstat (limited to 'rts/sm/GCThread.h')
-rw-r--r--rts/sm/GCThread.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/rts/sm/GCThread.h b/rts/sm/GCThread.h
index 723bb00bf1..d15189988d 100644
--- a/rts/sm/GCThread.h
+++ b/rts/sm/GCThread.h
@@ -127,7 +127,7 @@ typedef struct gc_thread_ {
OSThreadId id; // The OS thread that this struct belongs to
SpinLock gc_spin;
SpinLock mut_spin;
- volatile StgWord wakeup; // NB not StgWord8; only StgWord is guaranteed atomic
+ StgWord wakeup; // This should only be accessed via atomic accesses
#endif
uint32_t thread_index; // a zero based index identifying the thread