forked from OSchip/llvm-project
parent
1108d6eef3
commit
a1ec89fbf1
|
@ -11389,7 +11389,9 @@ bool InstCombiner::DoOneIteration(Function &F, unsigned Iteration) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// See if we can trivially sink this instruction to a successor basic block.
|
// See if we can trivially sink this instruction to a successor basic block.
|
||||||
if (I->hasOneUse()) {
|
// FIXME: Remove GetREsultInst test when first class support for aggregates is
|
||||||
|
// implemented.
|
||||||
|
if (I->hasOneUse() && !isa<GetResultInst>(I)) {
|
||||||
BasicBlock *BB = I->getParent();
|
BasicBlock *BB = I->getParent();
|
||||||
BasicBlock *UserParent = cast<Instruction>(I->use_back())->getParent();
|
BasicBlock *UserParent = cast<Instruction>(I->use_back())->getParent();
|
||||||
if (UserParent != BB) {
|
if (UserParent != BB) {
|
||||||
|
|
Loading…
Reference in New Issue