Lines Matching refs:CondCmp
165 bool TryToUnfoldSelect(CmpInst *CondCmp, BasicBlock *BB);
808 if (CmpInst *CondCmp = dyn_cast<CmpInst>(CondInst)) { in ProcessBlock() local
814 Constant *CondConst = dyn_cast<Constant>(CondCmp->getOperand(1)); in ProcessBlock()
817 LVI->getPredicateAt(CondCmp->getPredicate(), CondCmp->getOperand(0), in ProcessBlock()
825 if (CondCmp->use_empty()) in ProcessBlock()
826 CondCmp->eraseFromParent(); in ProcessBlock()
827 else if (CondCmp->getParent() == BB) { in ProcessBlock()
831 ConstantInt::getTrue(CondCmp->getType()) : in ProcessBlock()
832 ConstantInt::getFalse(CondCmp->getType()); in ProcessBlock()
833 CondCmp->replaceAllUsesWith(CI); in ProcessBlock()
834 CondCmp->eraseFromParent(); in ProcessBlock()
840 if (CondBr && CondConst && TryToUnfoldSelect(CondCmp, BB)) in ProcessBlock()
850 if (CmpInst *CondCmp = dyn_cast<CmpInst>(SimplifyValue)) in ProcessBlock() local
851 if (isa<Constant>(CondCmp->getOperand(1))) in ProcessBlock()
852 SimplifyValue = CondCmp->getOperand(0); in ProcessBlock()
1822 bool JumpThreading::TryToUnfoldSelect(CmpInst *CondCmp, BasicBlock *BB) { in TryToUnfoldSelect() argument
1824 PHINode *CondLHS = dyn_cast<PHINode>(CondCmp->getOperand(0)); in TryToUnfoldSelect()
1825 Constant *CondRHS = cast<Constant>(CondCmp->getOperand(1)); in TryToUnfoldSelect()
1848 LVI->getPredicateOnEdge(CondCmp->getPredicate(), SI->getOperand(1), in TryToUnfoldSelect()
1849 CondRHS, Pred, BB, CondCmp); in TryToUnfoldSelect()
1851 LVI->getPredicateOnEdge(CondCmp->getPredicate(), SI->getOperand(2), in TryToUnfoldSelect()
1852 CondRHS, Pred, BB, CondCmp); in TryToUnfoldSelect()