forked from OSchip/llvm-project
Revert "Revert "Switch Android from TLS_SLOT_TSAN(8) to TLS_SLOT_SANITIZER(6)""
This reapplies commit r348984. llvm-svn: 350449
This commit is contained in:
parent
0184c53cbd
commit
045a83231d
|
@ -134,13 +134,13 @@ void ForEachMappedRegion(link_map *map, void (*cb)(const void *, uptr));
|
||||||
#error "Unsupported architecture."
|
#error "Unsupported architecture."
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// The Android Bionic team has allocated a TLS slot for TSan starting with N,
|
// The Android Bionic team has allocated a TLS slot for sanitizers starting
|
||||||
// given that Android currently doesn't support ELF TLS. It is used to store
|
// with Q, given that Android currently doesn't support ELF TLS. It is used to
|
||||||
// Sanitizers thread specific data.
|
// store sanitizer thread specific data.
|
||||||
static const int TLS_SLOT_TSAN = 8;
|
static const int TLS_SLOT_SANITIZER = 6;
|
||||||
|
|
||||||
ALWAYS_INLINE uptr *get_android_tls_ptr() {
|
ALWAYS_INLINE uptr *get_android_tls_ptr() {
|
||||||
return reinterpret_cast<uptr *>(&__get_tls()[TLS_SLOT_TSAN]);
|
return reinterpret_cast<uptr *>(&__get_tls()[TLS_SLOT_SANITIZER]);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // SANITIZER_ANDROID
|
#endif // SANITIZER_ANDROID
|
||||||
|
|
Loading…
Reference in New Issue