diff options
author | Hans Wennborg <hans@hanshq.net> | 2019-08-20 07:58:32 +0000 |
---|---|---|
committer | Hans Wennborg <hans@hanshq.net> | 2019-08-20 07:58:32 +0000 |
commit | 612450792b64df6ad80dc81297f99bb7088d6d05 (patch) | |
tree | 1f42cac5623a4d896cc73e9c4c3a529dd346a84e | |
parent | 8e97004d98bd807bdf32cd7017e7831c3ae4fc6b (diff) | |
download | compiler-rt-612450792b64df6ad80dc81297f99bb7088d6d05.tar.gz |
Merge r368219 (PR42988)
Restrict the NetBSD ASan TSD fallback to !ASAN_DYNAMIC
The fallback to the alternative implementation of TSD with TLS
is only needed for the static version of ASan for NetBSD.
The same code cannot be reused for the dynamic version of ASan as
TLS breaks and TSD code works.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/branches/release_90@369341 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/asan/asan_posix.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/asan/asan_posix.cc b/lib/asan/asan_posix.cc index f3fbda07a..cb2dab2ec 100644 --- a/lib/asan/asan_posix.cc +++ b/lib/asan/asan_posix.cc @@ -39,8 +39,8 @@ void AsanOnDeadlySignal(int signo, void *siginfo, void *context) { // ---------------------- TSD ---------------- {{{1 -#if SANITIZER_NETBSD -// Thread Static Data cannot be used in early init on NetBSD. +#if SANITIZER_NETBSD && !ASAN_DYNAMIC +// Thread Static Data cannot be used in early static ASan init on NetBSD. // Reuse the Asan TSD API for compatibility with existing code // with an alternative implementation. |