mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 20:23:11 +01:00
call ::pthread_detach on llvm_execute_on_thread_impl
Fixes all TSAN bugs in clangd Reviewed By: sammccall Differential Revision: https://reviews.llvm.org/D83039
This commit is contained in:
parent
5d2157065e
commit
888ea87b16
@ -94,6 +94,10 @@ llvm_execute_on_thread_impl(void *(*ThreadFunc)(void *), void *Arg,
|
||||
if ((errnum = ::pthread_join(Thread, nullptr)) != 0) {
|
||||
ReportErrnumFatal("pthread_join failed", errnum);
|
||||
}
|
||||
} else if (JP == JoiningPolicy::Detach) {
|
||||
if ((errnum = ::pthread_detach(Thread)) != 0) {
|
||||
ReportErrnumFatal("pthread_detach failed", errnum);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user