From: Matt Morehouse Date: Mon, 23 Jul 2018 17:00:45 +0000 (+0000) Subject: [ARM] Add doFinalization() to ARMCodeGenPrepare pass. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=524f8982b8581ebbdb41522e23aea16781b0ef15;p=llvm [ARM] Add doFinalization() to ARMCodeGenPrepare pass. Attempt to fix the leak introduced in r337687 and make sanitizer buildbots green again. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@337709 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/ARM/ARMCodeGenPrepare.cpp b/lib/Target/ARM/ARMCodeGenPrepare.cpp index a450b15f30e..39b9813feec 100644 --- a/lib/Target/ARM/ARMCodeGenPrepare.cpp +++ b/lib/Target/ARM/ARMCodeGenPrepare.cpp @@ -108,6 +108,7 @@ public: bool doInitialization(Module &M) override; bool runOnFunction(Function &F) override; + bool doFinalization(Module &M) override; }; } @@ -734,6 +735,11 @@ bool ARMCodeGenPrepare::runOnFunction(Function &F) { return MadeChange; } +bool ARMCodeGenPrepare::doFinalization(Module &M) { + delete Promoter; + return false; +} + INITIALIZE_PASS_BEGIN(ARMCodeGenPrepare, DEBUG_TYPE, "ARM IR optimizations", false, false) INITIALIZE_PASS_END(ARMCodeGenPrepare, DEBUG_TYPE, "ARM IR optimizations",