[compiler-rt] r350449 - Revert "Revert "Switch Android from TLS_SLOT_TSAN(8) to TLS_SLOT_SANITIZER(6)""

Evgeniy Stepanov via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 4 16:45:14 PST 2019


Author: eugenis
Date: Fri Jan  4 16:45:14 2019
New Revision: 350449

URL: http://llvm.org/viewvc/llvm-project?rev=350449&view=rev
Log:
Revert "Revert "Switch Android from TLS_SLOT_TSAN(8) to TLS_SLOT_SANITIZER(6)""

This reapplies commit r348984.

Modified:
    compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.h

Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.h?rev=350449&r1=350448&r2=350449&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.h (original)
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.h Fri Jan  4 16:45:14 2019
@@ -134,13 +134,13 @@ void ForEachMappedRegion(link_map *map,
 #error "Unsupported architecture."
 #endif
 
-// The Android Bionic team has allocated a TLS slot for TSan starting with N,
-// given that Android currently doesn't support ELF TLS. It is used to store
-// Sanitizers thread specific data.
-static const int TLS_SLOT_TSAN = 8;
+// The Android Bionic team has allocated a TLS slot for sanitizers starting
+// with Q, given that Android currently doesn't support ELF TLS. It is used to
+// store sanitizer thread specific data.
+static const int TLS_SLOT_SANITIZER = 6;
 
 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




More information about the llvm-commits mailing list