Ignore dbg intrinsics while propagating conditional expression info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63876 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Devang Patel
2009-02-05 19:15:39 +00:00
parent ca940bb630
commit 1851db6b0f
5 changed files with 72 additions and 16 deletions

View File

@@ -137,7 +137,7 @@ void CondProp::SimplifyPredecessors(BranchInst *BI) {
if (!PN->hasOneUse()) return;
BasicBlock *BB = BI->getParent();
if (&*BB->begin() != PN || &*next(BB->begin()) != BI)
if (!isTerminatorFirstRelevantInsn (BB, BI))
return;
// Ok, we have this really simple case, walk the PHI operands, looking for
@@ -171,7 +171,7 @@ void CondProp::SimplifyPredecessors(SwitchInst *SI) {
if (!PN->hasOneUse()) return;
BasicBlock *BB = SI->getParent();
if (&*BB->begin() != PN || &*next(BB->begin()) != SI)
if (!isTerminatorFirstRelevantInsn (BB, SI))
return;
bool RemovedPreds = false;