https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78294
--- Comment #5 from Dmitry Vyukov <dvyukov at google dot com> --- Markus, how do you configure and build gcc? Is there anything special? Our tls accesses should not go through __tls_get_addr because we use initial-exec attribute. __tls_get_addr vs indirect access through got is chosen by compiler, right? So it's not linker. The question is why does your compiler chooses to use the call... If I am not mistaken, __tsan::ScopedInterceptor::ScopedInterceptor should have been already accesses cur_thread, and that did not crash, which suggests that there is no __tls_get_addr call.