[compiler-rt] r252875 - tsan: fix unused function warning in Go build

Dmitry Vyukov via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 12 03:14:36 PST 2015


Author: dvyukov
Date: Thu Nov 12 05:14:35 2015
New Revision: 252875

URL: http://llvm.org/viewvc/llvm-project?rev=252875&view=rev
Log:
tsan: fix unused function warning in Go build


Modified:
    compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc

Modified: compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc?rev=252875&r1=252874&r2=252875&view=diff
==============================================================================
--- compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc (original)
+++ compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc Thu Nov 12 05:14:35 2015
@@ -42,6 +42,7 @@
 
 namespace __tsan {
 
+#ifndef SANITIZER_GO
 static void *SignalSafeGetOrAllocate(uptr *dst, uptr size) {
   atomic_uintptr_t *a = (atomic_uintptr_t *)dst;
   void *val = (void *)atomic_load_relaxed(a);
@@ -61,7 +62,6 @@ static void *SignalSafeGetOrAllocate(upt
   return val;
 }
 
-#ifndef SANITIZER_GO
 // On OS X, accessing TLVs via __thread or manually by using pthread_key_* is
 // problematic, because there are several places where interceptors are called
 // when TLVs are not accessible (early process startup, thread cleanup, ...).




More information about the llvm-commits mailing list