diff --git a/src/bthread/work_stealing_queue.h b/src/bthread/work_stealing_queue.h index 06e9ed074c..138aaa6ba8 100644 --- a/src/bthread/work_stealing_queue.h +++ b/src/bthread/work_stealing_queue.h @@ -128,7 +128,7 @@ class WorkStealingQueue { return false; } *val = _buffer[t & (_capacity - 1)]; - } while (!_top.compare_exchange_strong(t, t + 1, + } while (!_top.compare_exchange_weak(t, t + 1, butil::memory_order_seq_cst, butil::memory_order_relaxed)); return true;