Don't use AtomicFreeList to squash TSAN complains

The previous fix attempt didn't work on some test. There are no known
bugs with AtomicFreeList other than tripping TSAN, and it's unclear
that TSAN isn't at fault.

However, switching to using a mutex works fine and doesn't appear to
be slower (it's actually faster with synthetic benchmarks on macOS)

BUGS=[377369108]
This commit is contained in:
Mathias Agopian
2024-11-13 22:53:35 -08:00
committed by Mathias Agopian
parent d075a877f2
commit 8aa9c4d004

View File

@@ -446,7 +446,7 @@ private:
Condition mWaiterCondition;
std::atomic<int32_t> mActiveJobs = { 0 };
utils::Arena<utils::ThreadSafeObjectPoolAllocator<Job>, LockingPolicy::NoLock> mJobPool;
utils::Arena<utils::ObjectPoolAllocator<Job>, LockingPolicy::Mutex> mJobPool;
template <typename T>
using aligned_vector = std::vector<T, utils::STLAlignedAllocator<T>>;