Lines Matching refs:IBI
161 bool SimplifyIndirectBr(IndirectBrInst *IBI);
633 } else if (IndirectBrInst *IBI = dyn_cast<IndirectBrInst>(TI)) { in EraseTerminatorInstAndDCECond() local
634 Cond = dyn_cast<Instruction>(IBI->getAddress()); in EraseTerminatorInstAndDCECond()
3108 static bool SimplifyIndirectBrOnSelect(IndirectBrInst *IBI, SelectInst *SI) { in SimplifyIndirectBrOnSelect() argument
3120 return SimplifyTerminatorOnSelect(IBI, SI->getCondition(), TrueBB, FalseBB, 0, in SimplifyIndirectBrOnSelect()
5087 bool SimplifyCFGOpt::SimplifyIndirectBr(IndirectBrInst *IBI) { in SimplifyIndirectBr() argument
5088 BasicBlock *BB = IBI->getParent(); in SimplifyIndirectBr()
5093 for (unsigned i = 0, e = IBI->getNumDestinations(); i != e; ++i) { in SimplifyIndirectBr()
5094 BasicBlock *Dest = IBI->getDestination(i); in SimplifyIndirectBr()
5097 IBI->removeDestination(i); in SimplifyIndirectBr()
5104 if (IBI->getNumDestinations() == 0) { in SimplifyIndirectBr()
5106 new UnreachableInst(IBI->getContext(), IBI); in SimplifyIndirectBr()
5107 EraseTerminatorInstAndDCECond(IBI); in SimplifyIndirectBr()
5111 if (IBI->getNumDestinations() == 1) { in SimplifyIndirectBr()
5113 BranchInst::Create(IBI->getDestination(0), IBI); in SimplifyIndirectBr()
5114 EraseTerminatorInstAndDCECond(IBI); in SimplifyIndirectBr()
5118 if (SelectInst *SI = dyn_cast<SelectInst>(IBI->getAddress())) { in SimplifyIndirectBr()
5119 if (SimplifyIndirectBrOnSelect(IBI, SI)) in SimplifyIndirectBr()
5518 } else if (IndirectBrInst *IBI = in run() local
5520 if (SimplifyIndirectBr(IBI)) in run()