forked from OSchip/llvm-project
[tsan] force tls_model='initial-exec' for tsan's cur_thread_placeholder so that we don't depend on the compiler flags
llvm-svn: 208536
This commit is contained in:
parent
aeb18fc787
commit
e61f4d5155
|
@ -473,6 +473,7 @@ struct ThreadState {
|
|||
};
|
||||
|
||||
#ifndef TSAN_GO
|
||||
__attribute__((tls_model("initial-exec")))
|
||||
extern THREADLOCAL char cur_thread_placeholder[];
|
||||
INLINE ThreadState *cur_thread() {
|
||||
return reinterpret_cast<ThreadState *>(&cur_thread_placeholder);
|
||||
|
|
Loading…
Reference in New Issue