[PATCH] D12841: [LLVMdev] Compiler-RT - Enabling ThreadSanitizer on PPC64(BE/LE) platforms

Bill Schmidt via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 14 18:56:30 PDT 2015


wschmidt added inline comments.

================
Comment at: lib/sanitizer_common/sanitizer_linux.cc:983
@@ -981,1 +982,3 @@
 }
+#elif defined(__powerpc64__) || defined(__powerpc64le__)
+// TSAN_PPC64 - not completed
----------------
Remove LE version

================
Comment at: lib/sanitizer_common/sanitizer_linux.cc:1123
@@ -1112,1 +1122,3 @@
+#elif defined(__powerpc__) || defined(__powerpc64__) \
+  || defined(__powerpc64le__)
   ucontext_t *ucontext = (ucontext_t*)context;
----------------
Remove LE version

================
Comment at: lib/sanitizer_common/sanitizer_linux.h:48
@@ -48,1 +47,3 @@
+#if defined(__x86_64__) || defined(__mips__) || defined(__aarch64__) || \
+  defined(__powerpc64__)  || defined(__powerpc64le__)
 uptr internal_clone(int (*fn)(void *), void *child_stack, int flags, void *arg,
----------------
samsonov wrote:
> Is `__powerpc64le__` a thing? It doesn't seem to be used anywhere in sanitizer code, and we support PowerPC support in ASan, for instance.
Right, this is not a thing.  Where endianness matters, there are other macros to be used.  
```
__powerpc64le__
``` 

is #defined for both BE and LE systems.

================
Comment at: lib/sanitizer_common/sanitizer_linux_libcdep.cc:182
@@ -182,2 +181,3 @@
+#if defined(__mips__) || defined(__powerpc64__) || defined(__powerpc64le__)
 // TlsPreTcbSize includes size of struct pthread_descr and size of tcb
 // head structure. It lies before the static tls blocks.
----------------
Remove LE version, and so on to the end


http://reviews.llvm.org/D12841





More information about the llvm-commits mailing list