[llvm-commits] [compiler-rt] r168358 - /compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc

Kostya Serebryany kcc at google.com
Tue Nov 20 00:57:26 PST 2012


Author: kcc
Date: Tue Nov 20 02:57:26 2012
New Revision: 168358

URL: http://llvm.org/viewvc/llvm-project?rev=168358&view=rev
Log:
[asan] better support for powerpc and sparc targets (thanks to H.J. Liu and David Miller)

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

Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc?rev=168358&r1=168357&r2=168358&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc (original)
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc Tue Nov 20 02:57:26 2012
@@ -32,10 +32,9 @@
 #include <errno.h>
 
 // Are we using 32-bit or 64-bit syscalls?
-// We need to list the 64-bit architecures explicitly because for x32
-// (which defines __x86_64__) we have __WORDSIZE == 32,
-// but we still need to use 64-bit syscalls.
-#if defined(__x86_64__) || defined(__powerpc64__) || defined(__sparc64__)
+// x32 (which defines __x86_64__) has __WORDSIZE == 32
+// but it still needs to use 64-bit syscalls.
+#if defined(__x86_64__) || __WORDSIZE == 64
 # define SANITIZER_LINUX_USES_64BIT_SYSCALLS 1
 #else
 # define SANITIZER_LINUX_USES_64BIT_SYSCALLS 0





More information about the llvm-commits mailing list