Lines Matching refs:Op
145 const SCEV *Op = Trunc->getOperand();
146 OS << "(trunc " << *Op->getType() << " " << *Op << " to "
152 const SCEV *Op = ZExt->getOperand();
153 OS << "(zext " << *Op->getType() << " " << *Op << " to "
159 const SCEV *Op = SExt->getOperand();
160 OS << "(sext " << *Op->getType() << " " << *Op << " to "
336 unsigned SCEVTy, const SCEV *op, Type *ty)
337 : SCEV(ID, SCEVTy), Op(op), Ty(ty) {}
340 const SCEV *op, Type *ty)
341 : SCEVCastExpr(ID, scTruncate, op, ty) {
342 assert((Op->getType()->isIntegerTy() || Op->getType()->isPointerTy()) &&
348 const SCEV *op, Type *ty)
349 : SCEVCastExpr(ID, scZeroExtend, op, ty) {
350 assert((Op->getType()->isIntegerTy() || Op->getType()->isPointerTy()) &&
356 const SCEV *op, Type *ty)
357 : SCEVCastExpr(ID, scSignExtend, op, ty) {
358 assert((Op->getType()->isIntegerTy() || Op->getType()->isPointerTy()) &&
822 const SCEV *ScalarEvolution::getTruncateExpr(const SCEV *Op,
824 assert(getTypeSizeInBits(Op->getType()) > getTypeSizeInBits(Ty) &&
832 ID.AddPointer(Op);
838 if (const SCEVConstant *SC = dyn_cast<SCEVConstant>(Op))
843 if (const SCEVTruncateExpr *ST = dyn_cast<SCEVTruncateExpr>(Op))
847 if (const SCEVSignExtendExpr *SS = dyn_cast<SCEVSignExtendExpr>(Op))
851 if (const SCEVZeroExtendExpr *SZ = dyn_cast<SCEVZeroExtendExpr>(Op))
856 if (const SCEVAddExpr *SA = dyn_cast<SCEVAddExpr>(Op)) {
871 if (const SCEVMulExpr *SM = dyn_cast<SCEVMulExpr>(Op)) {
885 if (const SCEVAddRecExpr *AddRec = dyn_cast<SCEVAddRecExpr>(Op)) {
896 Op, Ty);
901 const SCEV *ScalarEvolution::getZeroExtendExpr(const SCEV *Op,
903 assert(getTypeSizeInBits(Op->getType()) < getTypeSizeInBits(Ty) &&
910 if (const SCEVConstant *SC = dyn_cast<SCEVConstant>(Op))
915 if (const SCEVZeroExtendExpr *SZ = dyn_cast<SCEVZeroExtendExpr>(Op))
919 // computed a SCEV for this Op and Ty.
922 ID.AddPointer(Op);
928 if (const SCEVTruncateExpr *ST = dyn_cast<SCEVTruncateExpr>(Op)) {
944 if (const SCEVAddRecExpr *AR = dyn_cast<SCEVAddRecExpr>(Op))
1055 Op, Ty);
1159 const SCEV *ScalarEvolution::getSignExtendExpr(const SCEV *Op,
1161 assert(getTypeSizeInBits(Op->getType()) < getTypeSizeInBits(Ty) &&
1168 if (const SCEVConstant *SC = dyn_cast<SCEVConstant>(Op))
1173 if (const SCEVSignExtendExpr *SS = dyn_cast<SCEVSignExtendExpr>(Op))
1177 if (const SCEVZeroExtendExpr *SZ = dyn_cast<SCEVZeroExtendExpr>(Op))
1181 // computed a SCEV for this Op and Ty.
1184 ID.AddPointer(Op);
1190 if (isKnownNonNegative(Op))
1191 return getZeroExtendExpr(Op, Ty);
1194 if (const SCEVTruncateExpr *ST = dyn_cast<SCEVTruncateExpr>(Op)) {
1210 if (const SCEVAddRecExpr *AR = dyn_cast<SCEVAddRecExpr>(Op))
1303 Op, Ty);
1311 const SCEV *ScalarEvolution::getAnyExtendExpr(const SCEV *Op,
1313 assert(getTypeSizeInBits(Op->getType()) < getTypeSizeInBits(Ty) &&
1320 if (const SCEVConstant *SC = dyn_cast<SCEVConstant>(Op))
1322 return getSignExtendExpr(Op, Ty);
1325 if (const SCEVTruncateExpr *T = dyn_cast<SCEVTruncateExpr>(Op)) {
1333 const SCEV *ZExt = getZeroExtendExpr(Op, Ty);
1338 const SCEV *SExt = getSignExtendExpr(Op, Ty);
1343 if (const SCEVAddRecExpr *AR = dyn_cast<SCEVAddRecExpr>(Op)) {
1352 if (isa<SCEVSMaxExpr>(Op))
2192 const SCEV *Op = M->getOperand(i);
2193 const SCEV *Div = getUDivExpr(Op, RHSC);
2194 if (!isa<SCEVUDivExpr>(Div) && getMulExpr(Div, RHSC) == Op) {
2210 const SCEV *Op = getUDivExpr(A->getOperand(i), RHS);
2211 if (isa<SCEVUDivExpr>(Op) ||
2212 getMulExpr(Op, RHS) != A->getOperand(i))
2214 Operands.push_back(Op);
3650 for (Value *Op = U->getOperand(0); ; Op = U->getOperand(0)) {
3651 unsigned Opcode = Op->getValueID() - Value::InstructionVal;
3654 U = cast<Operator>(Op);
3668 for (Value *Op = U->getOperand(0);
3669 Op->getValueID() == Instruction::Mul + Value::InstructionVal;
3670 Op = U->getOperand(0)) {
3671 U = cast<Operator>(Op);
3854 // BitCasts are no-op casts so we just eliminate the cast.
4666 /// 'icmp op load X, cst', try to see if we can compute the backedge
5215 Value *Op = I->getOperand(i);
5216 if (Constant *C = dyn_cast<Constant>(Op)) {
5224 if (!isSCEVable(Op->getType()))
5227 const SCEV *OrigV = getSCEV(Op);
5233 if (C->getType() != Op->getType())
5235 Op->getType(),
5237 C, Op->getType());
5350 const SCEV *Op = getSCEVAtScope(Cast->getOperand(), L);
5351 if (Op == Cast->getOperand())
5353 return getZeroExtendExpr(Op, Cast->getType());
5357 const SCEV *Op = getSCEVAtScope(Cast->getOperand(), L);
5358 if (Op == Cast->getOperand())
5360 return getSignExtendExpr(Op, Cast->getType());
5364 const SCEV *Op = getSCEVAtScope(Cast->getOperand(), L);
5365 if (Op == Cast->getOperand())
5367 return getTruncateExpr(Op, Cast->getType());
7022 bool ScalarEvolution::hasOperand(const SCEV *S, const SCEV *Op) const {
7023 SCEVSearch Search(Op);