[compiler-rt] r181422 - [nolibc] Disable the GCC stack protector when building sanitizer runtimes.

Peter Collingbourne peter at pcc.me.uk
Wed May 8 03:39:06 PDT 2013


Author: pcc
Date: Wed May  8 05:39:05 2013
New Revision: 181422

URL: http://llvm.org/viewvc/llvm-project?rev=181422&view=rev
Log:
[nolibc] Disable the GCC stack protector when building sanitizer runtimes.

This is the first in a sequence of changes designed to eliminate the
libc dependency in sanitizer_common.  The main motivation for these
changes is to be able to provide an alternative for the current
interceptor-based technique for instrumenting functions in libc.
In this new technique, we compile libc with instrumentation.  This has
the potential advantages of being more accurate than interception and
reducing the amount of custom code required for each libc function.
As a side effect of this, we cannot depend on libc in the sanitizer
runtime due to mutual dependency issues.

This change disables the GCC stack protector, which introduces a libc
dependency and is enabled by default in Ubuntu.

Differential Revision: http://llvm-reviews.chandlerc.com/D755

Modified:
    compiler-rt/trunk/CMakeLists.txt

Modified: compiler-rt/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/CMakeLists.txt?rev=181422&r1=181421&r2=181422&view=diff
==============================================================================
--- compiler-rt/trunk/CMakeLists.txt (original)
+++ compiler-rt/trunk/CMakeLists.txt Wed May  8 05:39:05 2013
@@ -126,6 +126,7 @@ set(SANITIZER_COMMON_CFLAGS
   -fno-exceptions
   -fomit-frame-pointer
   -funwind-tables
+  -fno-stack-protector
   -O3
   )
 if(NOT WIN32)





More information about the llvm-commits mailing list