summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/CondPropagate.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Transforms/Scalar/CondPropagate.cpp')
-rw-r--r--llvm/lib/Transforms/Scalar/CondPropagate.cpp11
1 files changed, 0 insertions, 11 deletions
diff --git a/llvm/lib/Transforms/Scalar/CondPropagate.cpp b/llvm/lib/Transforms/Scalar/CondPropagate.cpp
index d3ad5778bb4..101acef6dcb 100644
--- a/llvm/lib/Transforms/Scalar/CondPropagate.cpp
+++ b/llvm/lib/Transforms/Scalar/CondPropagate.cpp
@@ -80,17 +80,6 @@ void CondProp::SimplifyBlock(BasicBlock *BB) {
SimplifyPredecessors(SI);
}
- // See if we can fold any PHI nodes in this block now.
- // FIXME: This would not be required if removePredecessor did this for us!!
- PHINode *PN;
- for (BasicBlock::iterator I = BB->begin(); (PN = dyn_cast<PHINode>(I++)); )
- if (Value *PNV = hasConstantValue(PN))
- if (!isa<Instruction>(PNV)) {
- PN->replaceAllUsesWith(PNV);
- PN->eraseFromParent();
- MadeChange = true;
- }
-
// If possible, simplify the terminator of this block.
if (ConstantFoldTerminator(BB))
MadeChange = true;
OpenPOWER on IntegriCloud