+ BBInfo &FalseBBI = BBAnalysis[BBI.FalseBB->getNumber()];
+ BBInfo *CvtBBI = &TrueBBI;
+ BBInfo *NextBBI = &FalseBBI;
+
+ std::vector<MachineOperand> Cond(BBI.BrCond);
+ if (BBI.Kind == ICTriangleFalse || BBI.Kind == ICTriangleFRev) {
+ if (BBI.Kind == ICTriangleFRev) {
+ ReverseBranchCondition(*NextBBI);
+ // False BB has been changed, modify its predecessors (except for this
+ // one) so they don't get ifcvt'ed based on bad intel.
+ for (MachineBasicBlock::pred_iterator PI = NextBBI->BB->pred_begin(),
+ E = NextBBI->BB->pred_end(); PI != E; ++PI) {
+ MachineBasicBlock *PBB = *PI;
+ if (PBB == BBI.BB)
+ continue;
+ BBInfo &PBBI = BBAnalysis[PBB->getNumber()];
+ PBBI.Kind = ICReAnalyze;
+ }
+ }
+ std::swap(CvtBBI, NextBBI);
+ TII->ReverseBranchCondition(Cond);
+ }