From: Mark Heffernan Date: Tue, 4 Nov 2014 01:51:01 +0000 (+0000) Subject: Remove setPreservesCFG from instcombine. The pass, in particular, does not X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2e25042a937e0e2762c8ef35a3a30ec8f9930406;p=platform%2Fupstream%2Fllvm.git Remove setPreservesCFG from instcombine. The pass, in particular, does not preserve LoopSimplify because instcombine may replace branch predicates with undef which loop simplify then replaces with always exit. Replace setPreservesCFG with the more constrained preservation of DomTree and LoopInfo. llvm-svn: 221223 --- diff --git a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp index 5a0b01e..4b7f841 100644 --- a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -90,7 +90,8 @@ INITIALIZE_PASS_END(InstCombiner, "instcombine", "Combine redundant instructions", false, false) void InstCombiner::getAnalysisUsage(AnalysisUsage &AU) const { - AU.setPreservesCFG(); + AU.addPreserved(); + AU.addPreserved(); AU.addRequired(); AU.addRequired(); }