[cfe-commits] r165937 - /cfe/trunk/lib/CodeGen/BackendUtil.cpp

Kostya Serebryany kcc at google.com
Mon Oct 15 07:22:56 PDT 2012


Author: kcc
Date: Mon Oct 15 09:22:56 2012
New Revision: 165937

URL: http://llvm.org/viewvc/llvm-project?rev=165937&view=rev
Log:
[asan] make AddressSanitizer to be a FunctionPass instead of ModulePass. clang part: for FunctionPass we need to run asan at a different point, otherwise it will run before inlining

Modified:
    cfe/trunk/lib/CodeGen/BackendUtil.cpp

Modified: cfe/trunk/lib/CodeGen/BackendUtil.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/BackendUtil.cpp?rev=165937&r1=165936&r2=165937&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/BackendUtil.cpp (original)
+++ cfe/trunk/lib/CodeGen/BackendUtil.cpp Mon Oct 15 09:22:56 2012
@@ -175,7 +175,7 @@
   }
 
   if (LangOpts.AddressSanitizer) {
-    PMBuilder.addExtension(PassManagerBuilder::EP_ScalarOptimizerLate,
+    PMBuilder.addExtension(PassManagerBuilder::EP_OptimizerLast,
                            addAddressSanitizerPass);
     PMBuilder.addExtension(PassManagerBuilder::EP_EnabledOnOptLevel0,
                            addAddressSanitizerPass);





More information about the cfe-commits mailing list