Lines Matching refs:CondCmp
807 if (CmpInst *CondCmp = dyn_cast<CmpInst>(CondInst)) { in ProcessBlock() local
813 Constant *CondConst = dyn_cast<Constant>(CondCmp->getOperand(1)); in ProcessBlock()
816 LVI->getPredicateAt(CondCmp->getPredicate(), CondCmp->getOperand(0), in ProcessBlock()
824 if (CondCmp->use_empty()) in ProcessBlock()
825 CondCmp->eraseFromParent(); in ProcessBlock()
826 else if (CondCmp->getParent() == BB) { in ProcessBlock()
830 ConstantInt::getTrue(CondCmp->getType()) : in ProcessBlock()
831 ConstantInt::getFalse(CondCmp->getType()); in ProcessBlock()
832 CondCmp->replaceAllUsesWith(CI); in ProcessBlock()
833 CondCmp->eraseFromParent(); in ProcessBlock()
839 if (CondBr && CondConst && TryToUnfoldSelect(CondCmp, BB)) in ProcessBlock()
849 if (CmpInst *CondCmp = dyn_cast<CmpInst>(SimplifyValue)) in ProcessBlock() local
850 if (isa<Constant>(CondCmp->getOperand(1))) in ProcessBlock()
851 SimplifyValue = CondCmp->getOperand(0); in ProcessBlock()
1835 bool JumpThreadingPass::TryToUnfoldSelect(CmpInst *CondCmp, BasicBlock *BB) { in TryToUnfoldSelect() argument
1837 PHINode *CondLHS = dyn_cast<PHINode>(CondCmp->getOperand(0)); in TryToUnfoldSelect()
1838 Constant *CondRHS = cast<Constant>(CondCmp->getOperand(1)); in TryToUnfoldSelect()
1861 LVI->getPredicateOnEdge(CondCmp->getPredicate(), SI->getOperand(1), in TryToUnfoldSelect()
1862 CondRHS, Pred, BB, CondCmp); in TryToUnfoldSelect()
1864 LVI->getPredicateOnEdge(CondCmp->getPredicate(), SI->getOperand(2), in TryToUnfoldSelect()
1865 CondRHS, Pred, BB, CondCmp); in TryToUnfoldSelect()