From: Chris Lattner Date: Thu, 5 Feb 2004 22:33:26 +0000 (+0000) Subject: Fix bug updating dominators X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=3e0b870def750929512ebe86e9b589fbab9d538e;p=oota-llvm.git Fix bug updating dominators git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11140 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Transforms/Utils/LoopSimplify.cpp b/lib/Transforms/Utils/LoopSimplify.cpp index 798dac10f26..53c8542b143 100644 --- a/lib/Transforms/Utils/LoopSimplify.cpp +++ b/lib/Transforms/Utils/LoopSimplify.cpp @@ -533,12 +533,12 @@ void LoopSimplify::UpdateDomInfoForRevectoredPreds(BasicBlock *NewBB, DS.addBasicBlock(NewBB, NewBBDomSet); // If NewBB dominates some blocks, then it will dominate all blocks that - // PredBlocks[0] used to except for PredBlocks[0] itself. + // NewBBSucc does. if (NewBBDominatesNewBBSucc) { BasicBlock *PredBlock = PredBlocks[0]; Function *F = NewBB->getParent(); for (Function::iterator I = F->begin(), E = F->end(); I != E; ++I) - if (DS.properlyDominates(PredBlock, I)) + if (DS.dominates(NewBBSucc, I)) DS.addDominator(I, NewBB); }