summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-10-30 23:15:43 +0000
committerDan Gohman <gohman@apple.com>2009-10-30 23:15:43 +0000
commit7f7d97eb73d4aa243646583301c943b1f125bade (patch)
tree00b2ad58f98faf0e2e96b525fc30d708f1983307 /llvm/lib/Transforms/Utils/SimplifyCFG.cpp
parent5bec30ca5d5d3d74f7cd899dbafed7b82ca4a3fc (diff)
downloadbcm5719-llvm-7f7d97eb73d4aa243646583301c943b1f125bade.tar.gz
bcm5719-llvm-7f7d97eb73d4aa243646583301c943b1f125bade.zip
Add a comment about a missed opportunity.
llvm-svn: 85635
Diffstat (limited to 'llvm/lib/Transforms/Utils/SimplifyCFG.cpp')
-rw-r--r--llvm/lib/Transforms/Utils/SimplifyCFG.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
index 859b8756666..8e1fb98b704 100644
--- a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
@@ -1753,8 +1753,13 @@ static bool SimplifyCondBranchToCondBranch(BranchInst *PBI, BranchInst *BI) {
/// nodes in this block. This doesn't try to be clever about PHI nodes
/// which differ only in the order of the incoming values, but instcombine
/// orders them so it usually won't matter.
+///
static bool EliminateDuplicatePHINodes(BasicBlock *BB) {
bool Changed = false;
+
+ // This implementation doesn't currently consider undef operands
+ // specially. Theroetically, two phis which are identical except for
+ // one having an undef where the other doesn't could be collapsed.
// Map from PHI hash values to PHI nodes. If multiple PHIs have
// the same hash value, the element is the first PHI in the
OpenPOWER on IntegriCloud