diff --git a/client/tracy_SPSCQueue.h b/client/tracy_SPSCQueue.h index e9a97f39..7f1752b5 100644 --- a/client/tracy_SPSCQueue.h +++ b/client/tracy_SPSCQueue.h @@ -112,7 +112,10 @@ public: return static_cast(diff); } - bool empty() const noexcept { return size() == 0; } + bool empty() const noexcept { + return writeIdx_.load(std::memory_order_acquire) == + readIdx_.load(std::memory_order_acquire); + } size_t capacity() const noexcept { return capacity_ - 1; }