[llvm-commits] [compiler-rt] r164816 - /compiler-rt/trunk/lib/asan/asan_internal.h

Evgeniy Stepanov eugeni.stepanov at gmail.com
Fri Sep 28 03:07:53 PDT 2012


Author: eugenis
Date: Fri Sep 28 05:07:53 2012
New Revision: 164816

URL: http://llvm.org/viewvc/llvm-project?rev=164816&view=rev
Log:
[asan] Change defaults for Android target.

This way building without -DASAN_* in CFLAGS produces working binaries.

Modified:
    compiler-rt/trunk/lib/asan/asan_internal.h

Modified: compiler-rt/trunk/lib/asan/asan_internal.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/asan_internal.h?rev=164816&r1=164815&r2=164816&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/asan_internal.h (original)
+++ compiler-rt/trunk/lib/asan/asan_internal.h Fri Sep 28 05:07:53 2012
@@ -62,7 +62,11 @@
 
 // If set, asan will install its own SEGV signal handler.
 #ifndef ASAN_NEEDS_SEGV
-# define ASAN_NEEDS_SEGV 1
+# ifdef ASAN_ANDROID
+#  define ASAN_NEEDS_SEGV 0
+# else
+#  define ASAN_NEEDS_SEGV 1
+# endif
 #endif
 
 // If set, asan will intercept C++ exception api call(s).
@@ -79,7 +83,11 @@
 // If set, values like allocator chunk size, as well as defaults for some flags
 // will be changed towards less memory overhead.
 #ifndef ASAN_LOW_MEMORY
-# define ASAN_LOW_MEMORY 0
+# ifdef ASAN_ANDROID
+#  define ASAN_LOW_MEMORY 1
+# else
+#  define ASAN_LOW_MEMORY 0
+# endif
 #endif
 
 // All internal functions in asan reside inside the __asan namespace





More information about the llvm-commits mailing list