[llvm] r344659 - [Sanitizer][PassManager] Fix for failing ASan tests on arm-linux-gnueabihf

Leonard Chan via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 16 17:16:07 PDT 2018


Author: leonardchan
Date: Tue Oct 16 17:16:07 2018
New Revision: 344659

URL: http://llvm.org/viewvc/llvm-project?rev=344659&view=rev
Log:
[Sanitizer][PassManager] Fix for failing ASan tests on arm-linux-gnueabihf

Forgot to initialize the legacy pass in it's constructor.

Differential Revision: https://reviews.llvm.org/D53350

Modified:
    llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp

Modified: llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp?rev=344659&r1=344658&r2=344659&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp (original)
+++ llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp Tue Oct 16 17:16:07 2018
@@ -1056,7 +1056,9 @@ public:
                                       bool Recover = false,
                                       bool UseAfterScope = false)
       : FunctionPass(ID), CompileKernel(CompileKernel), Recover(Recover),
-        UseAfterScope(UseAfterScope) {}
+        UseAfterScope(UseAfterScope) {
+    initializeAddressSanitizerLegacyPassPass(*PassRegistry::getPassRegistry());
+  }
 
   StringRef getPassName() const override {
     return "AddressSanitizerFunctionPass";




More information about the llvm-commits mailing list