electronicarts/EASTL

Usage of atomic_thread_fence in shared_ptr.h can cause false-positives w/ TSAN

romasandu-gaijin opened this issue · 0 comments

Thread sanitizer does not work with atomic_thread_fences and unlikely ever will. Every usage of atomic_thread_fence must be guarded by an #if !TSAN or a similar construction for correctness of synchronization to be verifiable via TSAN.

This also breaks TSAN compilation with latest GCC, as it now warns about usage of fences when TSAN is enabled (and rightly so!)