// available if cmp executes.
IterIfcvt = false;
}
- std::copy(Cond.begin(), Cond.end(), std::back_inserter(BBI.Predicate));
// Update block info. BB can be iteratively if-converted.
if (IterIfcvt)
// Remove entry to false edge if false block is merged in as well.
if (FalseBBDead)
BBI.BB->removeSuccessor(FalseBBI.BB);
- std::copy(BBI.BrCond.begin(), BBI.BrCond.end(),
- std::back_inserter(BBI.Predicate));
// Update block info. BB can be iteratively if-converted.
if (IterIfcvt)
// Merge the combined block into the entry of the diamond.
MergeBlocks(BBI, *BBI1);
- std::copy(Cond1->begin(), Cond1->end(),
- std::back_inserter(BBI.Predicate));
- if (!NeedBr1)
- std::copy(Cond2->begin(), Cond2->end(),
- std::back_inserter(BBI.Predicate));
// 'True' and 'false' aren't combined, see if we need to add a unconditional
// branch to the 'false' block.
}
BBI.NonPredSize = 0;
+ std::copy(Cond.begin(), Cond.end(), std::back_inserter(BBI.Predicate));
+
NumIfConvBBs++;
}
ToBBI.ModifyPredicate |= FromBBI.ModifyPredicate;
ToBBI.hasFallThrough = FromBBI.hasFallThrough;
+
+ std::copy(FromBBI.Predicate.begin(), FromBBI.Predicate.end(),
+ std::back_inserter(ToBBI.Predicate));
+ FromBBI.Predicate.clear();
}