mirror of
https://github.com/microsoft/mimalloc.git
synced 2024-12-28 13:58:30 +08:00
reduce tsan warning by ensuring a require edge; issue #130
This commit is contained in:
parent
8aa18d3661
commit
70be91d6b8
@ -978,7 +978,7 @@ static mi_segment_t* mi_abandoned_pop(void) {
|
||||
mi_atomic_increment(&abandoned_readers); // ensure no segment gets decommitted
|
||||
mi_tagged_segment_t next = 0;
|
||||
do {
|
||||
ts = mi_atomic_read_relaxed(&abandoned);
|
||||
ts = mi_atomic_read(&abandoned);
|
||||
segment = mi_tagged_segment_ptr(ts);
|
||||
if (segment != NULL) {
|
||||
next = mi_tagged_segment(segment->abandoned_next, ts); // note: reads the segment's `abandoned_next` field so should not be decommitted
|
||||
|
Loading…
x
Reference in New Issue
Block a user