|
reference, declaration → definition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced
|
References
include/llvm/Analysis/TargetTransformInfoImpl.h 884 U->getNumOperands() == 1 ? U->getOperand(0)->getType() : nullptr);
include/llvm/CodeGen/BasicTTIImpl.h 720 I && isa<LoadInst>(I->getOperand(0))) {
include/llvm/CodeGen/TargetLowering.h 2353 EVT::getEVT(I->getOperand(0)->getType())))
2357 if (isZExtFree(I->getOperand(0)->getType(), I->getType()))
include/llvm/IR/Operator.h 483 return getOperand(0);
486 return getOperand(0);
561 return getOperand(0);
564 return getOperand(0);
589 return getOperand(0)->getType();
include/llvm/IR/PatternMatch.h 791 return X.match(FPMO->getOperand(0));
796 if (!cstfp_pred_ty<is_any_zero_fp>().match(FPMO->getOperand(0)))
800 if (!cstfp_pred_ty<is_neg_zero_fp>().match(FPMO->getOperand(0)))
804 return X.match(FPMO->getOperand(1));
928 return L.match(Op->getOperand(0)) && R.match(Op->getOperand(1));
928 return L.match(Op->getOperand(0)) && R.match(Op->getOperand(1));
1012 return this->isOpType(I->getOpcode()) && L.match(I->getOperand(0)) &&
1013 R.match(I->getOperand(1));
1175 return Op1.match(I->getOperand(0));
1191 return Op1.match(I->getOperand(0)) && Op2.match(I->getOperand(1));
1191 return Op1.match(I->getOperand(0)) && Op2.match(I->getOperand(1));
1210 return Op1.match(I->getOperand(0)) && Op2.match(I->getOperand(1)) &&
1210 return Op1.match(I->getOperand(0)) && Op2.match(I->getOperand(1)) &&
1211 Op3.match(I->getOperand(2));
1281 return O->getOpcode() == Opcode && Op.match(O->getOperand(0));
lib/Analysis/BasicAliasAnalysis.cpp 488 V = Op->getOperand(0);
641 V = GEPOp->getOperand(0);
1110 dyn_cast<ConstantInt>(GEP1->getOperand(GEP1->getNumOperands() - 1));
1112 dyn_cast<ConstantInt>(GEP2->getOperand(GEP2->getNumOperands() - 1));
1132 IntermediateIndices.push_back(GEP1->getOperand(1));
1140 IntermediateIndices.push_back(GEP1->getOperand(i + 1));
1165 if (GEP1->getOperand(i + 1) != GEP2->getOperand(i + 1))
1165 if (GEP1->getOperand(i + 1) != GEP2->getOperand(i + 1))
1179 Value *GEP1LastIdx = GEP1->getOperand(GEP1->getNumOperands() - 1);
1180 Value *GEP2LastIdx = GEP2->getOperand(GEP2->getNumOperands() - 1);
lib/Analysis/BranchProbabilityInfo.cpp 511 isa<Constant>(CmpLHS->getOperand(1))) {
516 CmpLHS = dyn_cast<Instruction>(CmpLHS->getOperand(0));
553 cast<Constant>(I->getOperand(1)), true);
685 if (ConstantInt *AndRHS = dyn_cast<ConstantInt>(LHS->getOperand(1)))
lib/Analysis/CaptureTracking.cpp 312 if (V == I->getOperand(0) || cast<StoreInst>(I)->isVolatile())
350 unsigned Idx = (I->getOperand(0) == V) ? 0 : 1;
352 if (auto *CPN = dyn_cast<ConstantPointerNull>(I->getOperand(OtherIdx))) {
360 auto *O = I->getOperand(Idx)->stripPointerCastsSameRepresentation();
371 auto *LI = dyn_cast<LoadInst>(I->getOperand(OtherIdx));
lib/Analysis/ConstantFolding.cpp 891 Ptr = cast<Constant>(GEP->getOperand(0));
992 if (NewIdxs[I] != InnermostGEP->getOperand(I + 1))
lib/Analysis/DemandedBits.cpp 185 if (match(UserI->getOperand(1), m_APInt(ShiftAmtC))) {
202 if (match(UserI->getOperand(1), m_APInt(ShiftAmtC))) {
216 if (match(UserI->getOperand(1), m_APInt(ShiftAmtC))) {
240 ComputeKnownBits(BitWidth, UserI->getOperand(0), UserI->getOperand(1));
240 ComputeKnownBits(BitWidth, UserI->getOperand(0), UserI->getOperand(1));
253 ComputeKnownBits(BitWidth, UserI->getOperand(0), UserI->getOperand(1));
253 ComputeKnownBits(BitWidth, UserI->getOperand(0), UserI->getOperand(1));
lib/Analysis/IVDescriptors.cpp 293 !VisitedInsts.count(dyn_cast<Instruction>(Cur->getOperand(0))))
479 if (!(Cmp = dyn_cast<ICmpInst>(I->getOperand(0))) &&
480 !(Cmp = dyn_cast<FCmpInst>(I->getOperand(0))))
lib/Analysis/InlineCost.cpp 1668 V = cast<Operator>(V)->getOperand(0);
lib/Analysis/InstructionSimplify.cpp 385 if (Simplified->getOperand(0) == UnsimplifiedLHS &&
386 Simplified->getOperand(1) == UnsimplifiedRHS)
389 Simplified->getOperand(1) == UnsimplifiedLHS &&
390 Simplified->getOperand(0) == UnsimplifiedRHS)
1623 if (AddInst->getOperand(1) != Op1->getOperand(1))
3246 Value *SrcOp = LI->getOperand(0);
3737 if (I->getOperand(i) == Op)
3739 else if (Constant *COp = dyn_cast<Constant>(I->getOperand(i)))
5248 Result = SimplifyFNegInst(I->getOperand(0), I->getFastMathFlags(), Q);
5251 Result = SimplifyFAddInst(I->getOperand(0), I->getOperand(1),
5251 Result = SimplifyFAddInst(I->getOperand(0), I->getOperand(1),
5256 SimplifyAddInst(I->getOperand(0), I->getOperand(1),
5256 SimplifyAddInst(I->getOperand(0), I->getOperand(1),
5261 Result = SimplifyFSubInst(I->getOperand(0), I->getOperand(1),
5261 Result = SimplifyFSubInst(I->getOperand(0), I->getOperand(1),
5266 SimplifySubInst(I->getOperand(0), I->getOperand(1),
5266 SimplifySubInst(I->getOperand(0), I->getOperand(1),
5271 Result = SimplifyFMulInst(I->getOperand(0), I->getOperand(1),
5271 Result = SimplifyFMulInst(I->getOperand(0), I->getOperand(1),
5275 Result = SimplifyMulInst(I->getOperand(0), I->getOperand(1), Q);
5275 Result = SimplifyMulInst(I->getOperand(0), I->getOperand(1), Q);
5278 Result = SimplifySDivInst(I->getOperand(0), I->getOperand(1), Q);
5278 Result = SimplifySDivInst(I->getOperand(0), I->getOperand(1), Q);
5281 Result = SimplifyUDivInst(I->getOperand(0), I->getOperand(1), Q);
5281 Result = SimplifyUDivInst(I->getOperand(0), I->getOperand(1), Q);
5284 Result = SimplifyFDivInst(I->getOperand(0), I->getOperand(1),
5284 Result = SimplifyFDivInst(I->getOperand(0), I->getOperand(1),
5288 Result = SimplifySRemInst(I->getOperand(0), I->getOperand(1), Q);
5288 Result = SimplifySRemInst(I->getOperand(0), I->getOperand(1), Q);
5291 Result = SimplifyURemInst(I->getOperand(0), I->getOperand(1), Q);
5291 Result = SimplifyURemInst(I->getOperand(0), I->getOperand(1), Q);
5294 Result = SimplifyFRemInst(I->getOperand(0), I->getOperand(1),
5294 Result = SimplifyFRemInst(I->getOperand(0), I->getOperand(1),
5299 SimplifyShlInst(I->getOperand(0), I->getOperand(1),
5299 SimplifyShlInst(I->getOperand(0), I->getOperand(1),
5304 Result = SimplifyLShrInst(I->getOperand(0), I->getOperand(1),
5304 Result = SimplifyLShrInst(I->getOperand(0), I->getOperand(1),
5308 Result = SimplifyAShrInst(I->getOperand(0), I->getOperand(1),
5308 Result = SimplifyAShrInst(I->getOperand(0), I->getOperand(1),
5312 Result = SimplifyAndInst(I->getOperand(0), I->getOperand(1), Q);
5312 Result = SimplifyAndInst(I->getOperand(0), I->getOperand(1), Q);
5315 Result = SimplifyOrInst(I->getOperand(0), I->getOperand(1), Q);
5315 Result = SimplifyOrInst(I->getOperand(0), I->getOperand(1), Q);
5318 Result = SimplifyXorInst(I->getOperand(0), I->getOperand(1), Q);
5318 Result = SimplifyXorInst(I->getOperand(0), I->getOperand(1), Q);
5322 I->getOperand(0), I->getOperand(1), Q);
5322 I->getOperand(0), I->getOperand(1), Q);
5326 SimplifyFCmpInst(cast<FCmpInst>(I)->getPredicate(), I->getOperand(0),
5327 I->getOperand(1), I->getFastMathFlags(), Q);
5330 Result = SimplifySelectInst(I->getOperand(0), I->getOperand(1),
5330 Result = SimplifySelectInst(I->getOperand(0), I->getOperand(1),
5331 I->getOperand(2), Q);
5381 SimplifyCastInst(I->getOpcode(), I->getOperand(0), I->getType(), Q);
lib/Analysis/LazyValueInfo.cpp 999 if (!hasBlockValue(I->getOperand(Op), BB))
1000 if (pushBlockValue(std::make_pair(BB, I->getOperand(Op))))
1004 DL.getTypeSizeInBits(I->getOperand(Op)->getType());
1006 if (hasBlockValue(I->getOperand(Op), BB)) {
1007 ValueLatticeElement Val = getBlockValue(I->getOperand(Op), BB);
1008 intersectAssumeOrGuardBlockValueConstantRange(I->getOperand(Op), Val, I);
1433 Value *Op = Usr->getOperand(i);
lib/Analysis/Loads.cpp 65 return isDereferenceableAndAlignedPointer(BC->getOperand(0), Alignment,
lib/Analysis/LoopAccessAnalysis.cpp 979 isa<ConstantInt>(OBO->getOperand(1))) {
980 auto *OpScev = PSE.getSCEV(OBO->getOperand(0));
lib/Analysis/LoopInfo.cpp 161 if (Inc->getOpcode() == Instruction::Add && Inc->getOperand(0) == PN)
162 if (ConstantInt *CI = dyn_cast<ConstantInt>(Inc->getOperand(1)))
210 Value *StepInstOp1 = StepInst->getOperand(1);
211 Value *StepInstOp0 = StepInst->getOperand(0);
lib/Analysis/ModuleSummaryAnalysis.cpp 295 Value *Stored = I.getOperand(0);
512 findFuncPointers(cast<Constant>(I->getOperand(Op)),
520 findFuncPointers(cast<Constant>(I->getOperand(i)),
lib/Analysis/ObjCARCInstKind.cpp 290 if (IsPotentialRetainableObjPtr(I->getOperand(1)))
lib/Analysis/PHITransAddr.cpp 35 isa<ConstantInt>(Inst->getOperand(1)))
82 if (!VerifySubExpr(I->getOperand(i), InstInputs))
138 if (Instruction *Op = dyn_cast<Instruction>(I->getOperand(i)))
179 if (Instruction *Op = dyn_cast<Instruction>(Inst->getOperand(i)))
254 isa<ConstantInt>(Inst->getOperand(1))) {
256 Constant *RHS = cast<ConstantInt>(Inst->getOperand(1));
260 Value *LHS = PHITranslateSubExpr(Inst->getOperand(0), CurBB, PredBB, DT);
287 if (LHS == Inst->getOperand(0) && RHS == Inst->getOperand(1))
287 if (LHS == Inst->getOperand(0) && RHS == Inst->getOperand(1))
lib/Analysis/ScalarEvolution.cpp 637 CompareValueComplexity(EqCacheValue, LI, LInst->getOperand(Idx),
638 RInst->getOperand(Idx), Depth + 1);
4482 : Opcode(Op->getOpcode()), LHS(Op->getOperand(0)), RHS(Op->getOperand(1)),
4482 : Opcode(Op->getOpcode()), LHS(Op->getOperand(0)), RHS(Op->getOperand(1)),
4520 if (auto *RHSC = dyn_cast<ConstantInt>(Op->getOperand(1)))
4524 return BinaryOp(Instruction::Add, Op->getOperand(0), Op->getOperand(1));
4524 return BinaryOp(Instruction::Add, Op->getOperand(0), Op->getOperand(1));
4529 if (ConstantInt *SA = dyn_cast<ConstantInt>(Op->getOperand(1))) {
4540 return BinaryOp(Instruction::UDiv, Op->getOperand(0), X);
5093 if (GEP->isInBounds() && GEP->getOperand(0) == PN) {
6015 if (!isSCEVable(I->getOperand(OpIndex)->getType()))
6017 const SCEV *Op = getSCEV(I->getOperand(OpIndex));
6023 const SCEV *OtherOp = getSCEV(I->getOperand(OtherOpIndex));
6418 const SCEV *ShlOp0SCEV = getSCEV(L->getOperand(0));
6419 if (L->getOperand(1) == BO->RHS)
6425 ConstantInt *ShlAmtCI = dyn_cast<ConstantInt>(L->getOperand(1));
6448 return getTruncateExpr(getSCEV(U->getOperand(0)), U->getType());
6451 return getZeroExtendExpr(getSCEV(U->getOperand(0)), U->getType());
6454 if (auto BO = MatchBinaryOp(U->getOperand(0), DT)) {
6469 return getSignExtendExpr(getSCEV(U->getOperand(0)), U->getType());
6473 if (isSCEVable(U->getType()) && isSCEVable(U->getOperand(0)->getType()))
6474 return getSCEV(U->getOperand(0));
6494 return createNodeForSelectOrPHI(cast<Instruction>(U), U->getOperand(0),
6495 U->getOperand(1), U->getOperand(2));
6495 U->getOperand(1), U->getOperand(2));
7824 Instruction *Operand = dyn_cast<Instruction>(I->getOperand(i));
7826 Operands[i] = dyn_cast<Constant>(I->getOperand(i));
lib/Analysis/ScalarEvolutionExpander.cpp 204 if (IP->getOpcode() == (unsigned)Opcode && IP->getOperand(0) == LHS &&
205 IP->getOperand(1) == RHS && !canGenerateIncompatiblePoison(&*IP))
536 IP->getOperand(0) == V && IP->getOperand(1) == Idx)
536 IP->getOperand(0) == V && IP->getOperand(1) == Idx)
912 IncV = dyn_cast<Instruction>(IncV->getOperand(0));
946 Instruction *OInst = dyn_cast<Instruction>(IncV->getOperand(1));
948 return dyn_cast<Instruction>(IncV->getOperand(0));
952 return dyn_cast<Instruction>(IncV->getOperand(0));
977 return dyn_cast<Instruction>(IncV->getOperand(0));
1090 InstToHoist = cast<Instruction>(InstToHoist->getOperand(0));
lib/Analysis/StackSafetyAnalysis.cpp 304 if (V == I->getOperand(0)) {
310 UI, Ptr, DL.getTypeStoreSize(I->getOperand(0)->getType())));
lib/Analysis/TargetTransformInfo.cpp 1174 Op1VK = getOperandInfo(I->getOperand(0), Op1VP);
1175 Op2VK = getOperandInfo(I->getOperand(1), Op2VP);
1183 Op1VK = getOperandInfo(I->getOperand(0), Op1VP);
1197 Type *ValTy = I->getOperand(0)->getType();
1226 Type *SrcTy = I->getOperand(0)->getType();
1231 ConstantInt *CI = dyn_cast<ConstantInt>(I->getOperand(1));
lib/Analysis/TypeMetadataUtils.cpp 146 return getPointerAtOffset(cast<Constant>(I->getOperand(Op)),
157 return getPointerAtOffset(cast<Constant>(I->getOperand(Op)),
lib/Analysis/ValueTracking.cpp 898 if (auto *SA = dyn_cast<ConstantInt>(I->getOperand(1))) {
901 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
913 computeKnownBits(I->getOperand(1), Known, Depth + 1, Q);
941 ShifterOperandIsNonZero = isKnownNonZero(I->getOperand(1), Depth + 1, Q);
946 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
963 isKnownNonZero(I->getOperand(1), Depth + 1, Q);
992 computeKnownBits(I->getOperand(1), Known, Depth + 1, Q);
993 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1016 computeKnownBits(I->getOperand(1), Known, Depth + 1, Q);
1017 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1025 computeKnownBits(I->getOperand(1), Known, Depth + 1, Q);
1026 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1037 computeKnownBitsMul(I->getOperand(0), I->getOperand(1), NSW, Known,
1037 computeKnownBitsMul(I->getOperand(0), I->getOperand(1), NSW, Known,
1045 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1049 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q);
1064 computeKnownBits(I->getOperand(2), Known, Depth + 1, Q);
1065 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q);
1131 Type *SrcTy = I->getOperand(0)->getType();
1143 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1148 Type *SrcTy = I->getOperand(0)->getType();
1153 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1160 unsigned SrcBitWidth = I->getOperand(0)->getType()->getScalarSizeInBits();
1163 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1223 computeKnownBitsAddSub(false, I->getOperand(0), I->getOperand(1), NSW,
1223 computeKnownBitsAddSub(false, I->getOperand(0), I->getOperand(1), NSW,
1229 computeKnownBitsAddSub(true, I->getOperand(0), I->getOperand(1), NSW,
1229 computeKnownBitsAddSub(true, I->getOperand(0), I->getOperand(1), NSW,
1234 if (ConstantInt *Rem = dyn_cast<ConstantInt>(I->getOperand(1))) {
1238 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1261 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1268 if (ConstantInt *Rem = dyn_cast<ConstantInt>(I->getOperand(1))) {
1272 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1281 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1282 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q);
1305 computeKnownBits(I->getOperand(0), LocalKnown, Depth + 1, Q);
1310 Value *Index = I->getOperand(i);
1368 Value *LL = LU->getOperand(0);
1369 Value *LR = LU->getOperand(1);
1474 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1479 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1484 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1495 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1506 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1519 if (!match(I->getOperand(2), m_APInt(SA)))
1528 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q);
1529 computeKnownBits(I->getOperand(1), Known3, Depth + 1, Q);
1540 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1541 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q);
1579 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q);
1582 if (IntrinsicInst *II = dyn_cast<IntrinsicInst>(I->getOperand(0))) {
1828 return isKnownToBeAPowerOfTwo(cast<Operator>(V)->getOperand(0), OrZero,
2099 return isKnownNonZero(BCO->getOperand(0), Depth, Q);
2123 return isKnownNonZero(cast<Instruction>(V)->getOperand(0), Depth, Q);
2399 Tmp = TyBits - U->getOperand(0)->getType()->getScalarSizeInBits();
2400 return ComputeNumSignBits(U->getOperand(0), Depth + 1, Q) + Tmp;
2405 if (match(U->getOperand(1), m_APInt(Denominator))) {
2412 unsigned NumBits = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2425 if (match(U->getOperand(1), m_APInt(Denominator))) {
2433 unsigned NumrBits = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2455 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2458 if (match(U->getOperand(1), m_APInt(ShAmt))) {
2469 if (match(U->getOperand(1), m_APInt(ShAmt))) {
2471 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2483 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2485 Tmp2 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q);
2501 Tmp = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q);
2503 Tmp2 = ComputeNumSignBits(U->getOperand(2), Depth + 1, Q);
2510 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2514 if (const auto *CRHS = dyn_cast<Constant>(U->getOperand(1)))
2517 computeKnownBits(U->getOperand(0), Known, Depth + 1, Q);
2530 Tmp2 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q);
2535 Tmp2 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q);
2539 if (const auto *CLHS = dyn_cast<Constant>(U->getOperand(0)))
2542 computeKnownBits(U->getOperand(1), Known, Depth + 1, Q);
2559 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2566 unsigned SignBitsOp0 = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2568 unsigned SignBitsOp1 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q);
2604 return ComputeNumSignBits(U->getOperand(0), Depth + 1, Q);
2710 return ComputeMultiple(I->getOperand(0), Base, Multiple,
2714 Value *Op0 = I->getOperand(0);
2715 Value *Op1 = I->getOperand(1);
2989 if (I->getOperand(0) == I->getOperand(1) &&
2989 if (I->getOperand(0) == I->getOperand(1) &&
2997 return cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI, SignBitOnly,
2999 cannotBeOrderedLessThanZeroImpl(I->getOperand(1), TLI, SignBitOnly,
3002 return cannotBeOrderedLessThanZeroImpl(I->getOperand(1), TLI, SignBitOnly,
3004 cannotBeOrderedLessThanZeroImpl(I->getOperand(2), TLI, SignBitOnly,
3009 return cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI, SignBitOnly,
3015 return cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI, SignBitOnly,
3024 return (isKnownNeverNaN(I->getOperand(0), TLI) &&
3025 cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI,
3027 (isKnownNeverNaN(I->getOperand(1), TLI) &&
3028 cannotBeOrderedLessThanZeroImpl(I->getOperand(1), TLI,
3032 return cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI, SignBitOnly,
3034 cannotBeOrderedLessThanZeroImpl(I->getOperand(1), TLI, SignBitOnly,
3038 return cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI, SignBitOnly,
3040 cannotBeOrderedLessThanZeroImpl(I->getOperand(1), TLI, SignBitOnly,
3055 if (ConstantInt *Exponent = dyn_cast<ConstantInt>(I->getOperand(1))) {
3073 return cannotBeOrderedLessThanZeroImpl(I->getOperand(0), TLI, SignBitOnly,
3079 return I->getOperand(0) == I->getOperand(1) &&
3079 return I->getOperand(0) == I->getOperand(1) &&
3081 cannotBeOrderedLessThanZeroImpl(I->getOperand(2), TLI, SignBitOnly,
3125 return isKnownNeverNaN(Inst->getOperand(1), TLI, Depth + 1) &&
3126 isKnownNeverNaN(Inst->getOperand(2), TLI, Depth + 1);
3133 return isKnownNeverNaN(Inst->getOperand(0), TLI, Depth + 1);
3277 if (!(Val = Merge(Val, isBytewiseValue(C->getOperand(I), DL))))
3467 const ConstantInt *FirstIdx = dyn_cast<ConstantInt>(GEP->getOperand(1));
3494 if (const ConstantInt *CI = dyn_cast<ConstantInt>(GEP->getOperand(2)))
3498 return getConstantDataArrayInfo(GEP->getOperand(0), Slice, ElementSize,
3723 V = cast<Operator>(V)->getOperand(0);
3813 return U->getOperand(0);
3821 (!isa<ConstantInt>(U->getOperand(1)) &&
3822 Operator::getOpcode(U->getOperand(1)) != Instruction::Mul &&
3823 !isa<PHINode>(U->getOperand(1))))
3825 V = U->getOperand(0);
3852 getUnderlyingObjectFromInt(cast<User>(V)->getOperand(0));
3902 if (Constant *C = dyn_cast<Constant>(Inst->getOperand(i)))
3913 if (match(Inst->getOperand(1), m_APInt(V)))
3921 if (!match(Inst->getOperand(1), m_APInt(Denominator)))
3931 if (match(Inst->getOperand(0), m_APInt(Numerator)))
4231 return ::computeOverflowForSignedAdd(Add->getOperand(0), Add->getOperand(1),
4231 return ::computeOverflowForSignedAdd(Add->getOperand(0), Add->getOperand(1),
4371 return I->getOperand(1);
5724 ConstantInt *OpC = dyn_cast<ConstantInt>(GEP->getOperand(i));
5778 auto Op0 = GEP_T->getOperand(0)->stripPointerCasts();
5806 if (!GEP1 || !GEP2 || GEP1->getOperand(0) != GEP2->getOperand(0))
5806 if (!GEP1 || !GEP2 || GEP1->getOperand(0) != GEP2->getOperand(0))
5812 if (GEP1->getOperand(Idx) != GEP2->getOperand(Idx))
5812 if (GEP1->getOperand(Idx) != GEP2->getOperand(Idx))
lib/Analysis/VectorUtils.cpp 389 !TTI->isTypeLegal(I.getOperand(0)->getType()))
395 I.getOperand(0)->getType()->getScalarSizeInBits() <= 64) {
500 Ty = cast<Instruction>(*MI)->getOperand(0)->getType();
lib/Bitcode/Writer/BitcodeWriter.cpp 2433 Record.push_back(VE.getTypeID(C->getOperand(0)->getType()));
2434 Record.push_back(VE.getValueID(C->getOperand(0)));
2440 Record.push_back(VE.getValueID(C->getOperand(0)));
2441 Record.push_back(VE.getValueID(C->getOperand(1)));
2451 Record.push_back(VE.getValueID(C->getOperand(0)));
2467 Record.push_back(VE.getTypeID(C->getOperand(i)->getType()));
2468 Record.push_back(VE.getValueID(C->getOperand(i)));
2474 Record.push_back(VE.getValueID(C->getOperand(0)));
2475 Record.push_back(VE.getValueID(C->getOperand(1)));
2476 Record.push_back(VE.getValueID(C->getOperand(2)));
2480 Record.push_back(VE.getTypeID(C->getOperand(0)->getType()));
2481 Record.push_back(VE.getValueID(C->getOperand(0)));
2482 Record.push_back(VE.getTypeID(C->getOperand(1)->getType()));
2483 Record.push_back(VE.getValueID(C->getOperand(1)));
2487 Record.push_back(VE.getValueID(C->getOperand(0)));
2488 Record.push_back(VE.getValueID(C->getOperand(1)));
2489 Record.push_back(VE.getTypeID(C->getOperand(2)->getType()));
2490 Record.push_back(VE.getValueID(C->getOperand(2)));
2497 if (C->getType() == C->getOperand(0)->getType()) {
2501 Record.push_back(VE.getTypeID(C->getOperand(0)->getType()));
2503 Record.push_back(VE.getValueID(C->getOperand(0)));
2504 Record.push_back(VE.getValueID(C->getOperand(1)));
2505 Record.push_back(VE.getValueID(C->getOperand(2)));
2510 Record.push_back(VE.getTypeID(C->getOperand(0)->getType()));
2511 Record.push_back(VE.getValueID(C->getOperand(0)));
2512 Record.push_back(VE.getValueID(C->getOperand(1)));
2610 if (!pushValueAndType(I.getOperand(0), InstID, Vals))
2617 if (!pushValueAndType(I.getOperand(0), InstID, Vals))
2619 pushValue(I.getOperand(1), InstID, Vals);
2631 if (!pushValueAndType(I.getOperand(0), InstID, Vals))
2649 pushValueAndType(I.getOperand(i), InstID, Vals);
2654 pushValueAndType(I.getOperand(0), InstID, Vals);
2661 pushValueAndType(I.getOperand(0), InstID, Vals);
2662 pushValueAndType(I.getOperand(1), InstID, Vals);
2669 pushValueAndType(I.getOperand(1), InstID, Vals);
2670 pushValue(I.getOperand(2), InstID, Vals);
2671 pushValueAndType(I.getOperand(0), InstID, Vals);
2679 pushValueAndType(I.getOperand(0), InstID, Vals);
2680 pushValueAndType(I.getOperand(1), InstID, Vals);
2684 pushValueAndType(I.getOperand(0), InstID, Vals);
2685 pushValue(I.getOperand(1), InstID, Vals);
2686 pushValueAndType(I.getOperand(2), InstID, Vals);
2690 pushValueAndType(I.getOperand(0), InstID, Vals);
2691 pushValue(I.getOperand(1), InstID, Vals);
2692 pushValue(I.getOperand(2), InstID, Vals);
2698 pushValueAndType(I.getOperand(0), InstID, Vals);
2699 pushValue(I.getOperand(1), InstID, Vals);
2714 if (!pushValueAndType(I.getOperand(0), InstID, Vals))
2718 pushValueAndType(I.getOperand(i), InstID, Vals);
2748 Vals.push_back(VE.getTypeID(I.getOperand(0)->getType()));
2750 pushValue(I.getOperand(0), InstID, Vals);
2752 Vals.push_back(VE.getValueID(I.getOperand(i)));
2774 pushValue(I.getOperand(i), InstID, Vals); // fixed param.
2780 pushValueAndType(I.getOperand(i), InstID, Vals); // vararg
2786 pushValueAndType(I.getOperand(0), InstID, Vals);
2856 pushValue(I.getOperand(i), InstID, Vals); // fixed param.
2862 pushValueAndType(I.getOperand(i), InstID, Vals); // vararg
2914 Vals.push_back(VE.getTypeID(I.getOperand(0)->getType()));
2915 Vals.push_back(VE.getValueID(I.getOperand(0))); // size.
2930 pushValueAndType(I.getOperand(0), InstID, Vals);
2933 if (!pushValueAndType(I.getOperand(0), InstID, Vals)) // ptr
2949 pushValueAndType(I.getOperand(1), InstID, Vals); // ptrty + ptr
2950 pushValueAndType(I.getOperand(0), InstID, Vals); // valty + val
2961 pushValueAndType(I.getOperand(0), InstID, Vals); // ptrty + ptr
2962 pushValueAndType(I.getOperand(1), InstID, Vals); // cmp.
2963 pushValue(I.getOperand(2), InstID, Vals); // newval.
2975 pushValueAndType(I.getOperand(0), InstID, Vals); // ptrty + ptr
2976 pushValue(I.getOperand(1), InstID, Vals); // val.
3032 Vals.push_back(VE.getTypeID(I.getOperand(0)->getType())); // valistty
3033 pushValue(I.getOperand(0), InstID, Vals); // valist.
lib/CodeGen/Analysis.cpp 285 Value *Op = I->getOperand(0);
lib/CodeGen/CodeGenPrepare.cpp 1445 if (!isa<ConstantInt>(AndI->getOperand(0)) &&
1446 !isa<ConstantInt>(AndI->getOperand(1)) &&
1447 AndI->getOperand(0)->hasOneUse() && AndI->getOperand(1)->hasOneUse())
1447 AndI->getOperand(0)->hasOneUse() && AndI->getOperand(1)->hasOneUse())
1457 auto *CmpC = dyn_cast<ConstantInt>(User->getOperand(1));
1485 BinaryOperator::Create(Instruction::And, AndI->getOperand(0),
1486 AndI->getOperand(1), "", InsertPt);
1509 !isa<ConstantInt>(User->getOperand(1)))
1512 const APInt &Cimm = cast<ConstantInt>(User->getOperand(1))->getValue();
2362 Origin = Inst->getOperand(Idx);
2389 Value *Val = Inst->getOperand(It);
3542 if (I->getType() == I->getOperand(0)->getType())
3556 return isa<ConstantInt>(I->getOperand(1));
3751 const ConstantInt *Cst = dyn_cast<ConstantInt>(Inst->getOperand(1));
3775 const auto *Cst = dyn_cast<ConstantInt>(AndInst->getOperand(1));
3788 Value *OpndVal = Inst->getOperand(0);
3811 OpndType = Opnd->getOperand(0)->getType();
3825 Instruction *ExtOpnd = dyn_cast<Instruction>(Ext->getOperand(0));
3860 Instruction *SExtOpnd = cast<Instruction>(SExt->getOperand(0));
3868 TPT.createZExt(SExt, SExtOpnd->getOperand(0), SExt->getType());
3875 TPT.setOperand(SExt, 0, SExtOpnd->getOperand(0));
3885 if (!ExtInst || ExtInst->getType() != ExtInst->getOperand(0)->getType()) {
3896 Value *NextVal = ExtInst->getOperand(0);
3909 Instruction *ExtOpnd = cast<Instruction>(Ext->getOperand(0));
3948 LLVM_DEBUG(dbgs() << "Operand:\n" << *(ExtOpnd->getOperand(OpIdx)) << '\n');
3949 if (ExtOpnd->getOperand(OpIdx)->getType() == Ext->getType() ||
3955 Value *Opnd = ExtOpnd->getOperand(OpIdx);
4051 return matchAddr(AddrInst->getOperand(0), Depth);
4056 if (TLI.getValueType(DL, AddrInst->getOperand(0)->getType()) == PtrTy)
4057 return matchAddr(AddrInst->getOperand(0), Depth);
4063 if (AddrInst->getOperand(0)->getType()->isIntOrPtrTy() &&
4067 AddrInst->getOperand(0)->getType() != AddrInst->getType())
4068 return matchAddr(AddrInst->getOperand(0), Depth);
4072 = AddrInst->getOperand(0)->getType()->getPointerAddressSpace();
4075 return matchAddr(AddrInst->getOperand(0), Depth);
4090 if (matchAddr(AddrInst->getOperand(1), Depth+1) &&
4091 matchAddr(AddrInst->getOperand(0), Depth+1))
4100 if (matchAddr(AddrInst->getOperand(0), Depth+1) &&
4101 matchAddr(AddrInst->getOperand(1), Depth+1))
4117 ConstantInt *RHS = dyn_cast<ConstantInt>(AddrInst->getOperand(1));
4124 return matchScaledValue(AddrInst->getOperand(0), Scale, Depth);
4138 cast<ConstantInt>(AddrInst->getOperand(i))->getZExtValue();
4142 if (ConstantInt *CI = dyn_cast<ConstantInt>(AddrInst->getOperand(i))) {
4168 if (matchAddr(AddrInst->getOperand(0), Depth+1)) {
4180 Value *Base = AddrInst->getOperand(0);
4208 if (!matchAddr(AddrInst->getOperand(0), Depth+1)) {
4216 AddrMode.BaseReg = AddrInst->getOperand(0);
4220 if (!matchScaledValue(AddrInst->getOperand(VariableOperand), VariableScale,
4229 AddrMode.BaseReg = AddrInst->getOperand(0);
4231 if (!matchScaledValue(AddrInst->getOperand(VariableOperand),
4594 Value *Address = User->getOperand(OpNo);
5120 if (isa<LoadInst>(I->getOperand(0))) {
5181 Value *ExtOperand = MovedExt->getOperand(0);
5214 Inst->getOperand(0) != Entry.first)
5399 if (isa<LoadInst>(MovedExtInst->getOperand(0))) {
5400 LI = cast<LoadInst>(MovedExtInst->getOperand(0));
5521 Value *HeadOfChain = I->getOperand(0);
5539 Value *HeadOfChain = I->getOperand(0);
5550 Value *HeadOfChain = I->getOperand(0);
5569 Value *HeadOfChain = I->getOperand(0);
5583 Value *Src = I->getOperand(0);
5740 auto *AndC = dyn_cast<ConstantInt>(I->getOperand(1));
5748 if (AndBits == WidestAndBits && I->getOperand(0) == Load)
5754 auto *ShlC = dyn_cast<ConstantInt>(I->getOperand(1));
5815 if (cast<ConstantInt>(And->getOperand(1))->getValue() == DemandBits) {
6340 return Transition->getOperand(getTransitionOriginalValueIdx())->getType();
6355 Value *ValIdx = Transition->getOperand(getTransitionOriginalValueIdx());
6384 Value *Arg0 = Inst->getOperand(0);
6417 Value *ValExtractIdx = Transition->getOperand(getTransitionIdx());
6569 NewVal = Transition->getOperand(getTransitionOriginalValueIdx());
6593 !TLI->canCombineStoreAndExtract(Inst->getOperand(0)->getType(),
6594 Inst->getOperand(1), CombineCost)))
6980 Modified |= optimizeMemoryInst(I, I->getOperand(0), LI->getType(), AS);
lib/CodeGen/GlobalISel/IRTranslator.cpp 293 Register Op0 = getOrCreateVReg(*U.getOperand(0));
294 Register Op1 = getOrCreateVReg(*U.getOperand(1));
308 if (isa<Constant>(U.getOperand(0)) &&
309 U.getOperand(0) == ConstantFP::getZeroValueForNegation(U.getType())) {
310 Register Op1 = getOrCreateVReg(*U.getOperand(1));
325 Register Op0 = getOrCreateVReg(*U.getOperand(0));
339 Register Op0 = getOrCreateVReg(*U.getOperand(0));
340 Register Op1 = getOrCreateVReg(*U.getOperand(1));
943 const Value *Src = U.getOperand(0);
959 Indices.push_back(U.getOperand(i));
968 const Value *Src = U.getOperand(0);
983 const Value *Src = U.getOperand(0);
988 ArrayRef<Register> InsertedRegs = getOrCreateVRegs(*U.getOperand(1));
1003 Register Tst = getOrCreateVReg(*U.getOperand(0));
1005 ArrayRef<Register> Op0Regs = getOrCreateVRegs(*U.getOperand(1));
1006 ArrayRef<Register> Op1Regs = getOrCreateVRegs(*U.getOperand(2));
1024 if (getLLTForType(*U.getOperand(0)->getType(), *DL) ==
1026 Register SrcReg = getOrCreateVReg(*U.getOperand(0));
1043 Register Op = getOrCreateVReg(*U.getOperand(0));
1055 Value &Op0 = *U.getOperand(0);
1851 .addUse(getOrCreateVReg(*U.getOperand(0)))
1861 Register Elt = getOrCreateVReg(*U.getOperand(1));
1873 Register Val = getOrCreateVReg(*U.getOperand(0));
1874 Register Elt = getOrCreateVReg(*U.getOperand(1));
1875 Register Idx = getOrCreateVReg(*U.getOperand(2));
1884 if (U.getOperand(0)->getType()->getVectorNumElements() == 1) {
1885 Register Elt = getOrCreateVReg(*U.getOperand(0));
1896 Register Val = getOrCreateVReg(*U.getOperand(0));
1900 if (auto *CI = dyn_cast<ConstantInt>(U.getOperand(1))) {
1908 Idx = getOrCreateVReg(*U.getOperand(1));
1921 .addUse(getOrCreateVReg(*U.getOperand(0)))
1922 .addUse(getOrCreateVReg(*U.getOperand(1)))
1923 .addShuffleMask(cast<Constant>(U.getOperand(2)));
lib/CodeGen/SafeStack.cpp 305 if (V == I->getOperand(0)) {
313 if (!IsAccessSafe(UI, DL.getTypeStoreSize(I->getOperand(0)->getType()),
lib/CodeGen/SafeStackColoring.cpp 58 auto *Op = dyn_cast<Instruction>(I->getOperand(1));
lib/CodeGen/SelectionDAG/FastISel.cpp 606 if (const auto *CI = dyn_cast<ConstantInt>(I->getOperand(0)))
608 unsigned Op1 = getRegForValue(I->getOperand(1));
611 bool Op1IsKill = hasTrivialKill(I->getOperand(1));
624 unsigned Op0 = getRegForValue(I->getOperand(0));
627 bool Op0IsKill = hasTrivialKill(I->getOperand(0));
630 if (const auto *CI = dyn_cast<ConstantInt>(I->getOperand(1))) {
657 unsigned Op1 = getRegForValue(I->getOperand(1));
660 bool Op1IsKill = hasTrivialKill(I->getOperand(1));
676 unsigned N = getRegForValue(I->getOperand(0));
679 bool NIsKill = hasTrivialKill(I->getOperand(0));
1490 EVT SrcVT = TLI.getValueType(DL, I->getOperand(0)->getType());
1506 unsigned InputReg = getRegForValue(I->getOperand(0));
1511 bool InputRegIsKill = hasTrivialKill(I->getOperand(0));
1524 if (I->getType() == I->getOperand(0)->getType()) {
1525 unsigned Reg = getRegForValue(I->getOperand(0));
1533 EVT SrcEVT = TLI.getValueType(DL, I->getOperand(0)->getType());
1542 unsigned Op0 = getRegForValue(I->getOperand(0));
1545 bool Op0IsKill = hasTrivialKill(I->getOperand(0));
1836 return selectFNeg(I, I->getOperand(0));
1896 EVT SrcVT = TLI.getValueType(DL, I->getOperand(0)->getType());
1902 unsigned Reg = getRegForValue(I->getOperand(0));
2385 return isa<ConstantInt>(cast<AddOperator>(Add)->getOperand(1));
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp 1243 V = VAsInst.getOperand(0);
2109 !InBlock(BOp->getOperand(0), CurBB->getBasicBlock()) ||
2110 !InBlock(BOp->getOperand(1), CurBB->getBasicBlock())) {
2146 FindMergedConditions(BOp->getOperand(0), TBB, TmpBB, CurBB, SwitchBB, Opc,
2153 FindMergedConditions(BOp->getOperand(1), TBB, FBB, TmpBB, SwitchBB, Opc,
2179 FindMergedConditions(BOp->getOperand(0), TmpBB, FBB, CurBB, SwitchBB, Opc,
2186 FindMergedConditions(BOp->getOperand(1), TBB, FBB, TmpBB, SwitchBB, Opc,
2964 if (isa<Constant>(I.getOperand(0)) &&
2965 I.getOperand(0) == ConstantFP::getZeroValueForNegation(Ty)) {
2966 SDValue Op2 = getValue(I.getOperand(1));
3060 if (!isa<UndefValue>(U->getOperand(1)))
3079 if ((U2->getOperand(0) == U->getOperand(0) && U2->getOperand(1) == U) ||
3079 if ((U2->getOperand(0) == U->getOperand(0) && U2->getOperand(1) == U) ||
3079 if ((U2->getOperand(0) == U->getOperand(0) && U2->getOperand(1) == U) ||
3080 (U2->getOperand(1) == U->getOperand(0) && U2->getOperand(0) == U)) {
3080 (U2->getOperand(1) == U->getOperand(0) && U2->getOperand(0) == U)) {
3080 (U2->getOperand(1) == U->getOperand(0) && U2->getOperand(0) == U)) {
3090 const ConstantInt *Val = dyn_cast<ConstantInt>(U->getOperand(1));
3105 SDValue Op = getValue(I.getOperand(0));
3125 SDValue Op1 = getValue(I.getOperand(0));
3126 SDValue Op2 = getValue(I.getOperand(1));
3133 SDValue Op1 = getValue(I.getOperand(0));
3134 SDValue Op2 = getValue(I.getOperand(1));
3186 SDValue Op1 = getValue(I.getOperand(0));
3187 SDValue Op2 = getValue(I.getOperand(1));
3202 SDValue Op1 = getValue(I.getOperand(0));
3203 SDValue Op2 = getValue(I.getOperand(1));
3208 TLI.getMemValueType(DAG.getDataLayout(), I.getOperand(0)->getType());
3229 SDValue Op1 = getValue(I.getOperand(0));
3230 SDValue Op2 = getValue(I.getOperand(1));
3258 SDValue Cond = getValue(I.getOperand(0));
3259 SDValue LHSVal = getValue(I.getOperand(1));
3260 SDValue RHSVal = getValue(I.getOperand(2));
3380 SDValue N = getValue(I.getOperand(0));
3389 SDValue N = getValue(I.getOperand(0));
3398 SDValue N = getValue(I.getOperand(0));
3406 SDValue N = getValue(I.getOperand(0));
3417 SDValue N = getValue(I.getOperand(0));
3425 SDValue N = getValue(I.getOperand(0));
3433 SDValue N = getValue(I.getOperand(0));
3441 SDValue N = getValue(I.getOperand(0));
3449 SDValue N = getValue(I.getOperand(0));
3458 SDValue N = getValue(I.getOperand(0));
3463 TLI.getMemValueType(DAG.getDataLayout(), I.getOperand(0)->getType());
3472 SDValue N = getValue(I.getOperand(0));
3482 SDValue N = getValue(I.getOperand(0));
3496 else if(ConstantInt *C = dyn_cast<ConstantInt>(I.getOperand(0)))
3505 const Value *SV = I.getOperand(0);
3520 SDValue InVec = getValue(I.getOperand(0));
3521 SDValue InVal = getValue(I.getOperand(1));
3522 SDValue InIdx = DAG.getSExtOrTrunc(getValue(I.getOperand(2)), getCurSDLoc(),
3531 SDValue InVec = getValue(I.getOperand(0));
3532 SDValue InIdx = DAG.getSExtOrTrunc(getValue(I.getOperand(1)), getCurSDLoc(),
3540 SDValue Src1 = getValue(I.getOperand(0));
3541 SDValue Src2 = getValue(I.getOperand(1));
3542 Constant *MaskV = cast<Constant>(I.getOperand(2));
3747 const Value *Op0 = I.getOperand(0);
3748 const Value *Op1 = I.getOperand(1);
3801 const Value *Op0 = I.getOperand(0);
3835 Value *Op0 = I.getOperand(0);
8762 SDValue Callee = getValue(CS->getOperand(PatchPointOpers::TargetPos));
8808 SDValue IDVal = getValue(CS->getOperand(PatchPointOpers::IDPos));
8811 SDValue NBytesVal = getValue(CS->getOperand(PatchPointOpers::NBytesPos));
lib/IR/AsmWriter.cpp 3716 const Value *Operand = I.getNumOperands() ? I.getOperand(0) : nullptr;
3752 writeOperand(I.getOperand(i), true);
3768 writeOperand(I.getOperand(0), true);
3773 writeOperand(I.getOperand(0), true); Out << ", ";
3774 writeOperand(I.getOperand(1), true);
4034 Operand = I.getOperand(i);
4052 writeOperand(I.getOperand(i), PrintAllTypes);
lib/IR/AutoUpgrade.cpp 857 auto Ctor = cast<Constant>(Init->getOperand(i));
lib/IR/Constants.cpp 549 Result |= cast<Constant>(getOperand(i))->needsRelocation();
lib/IR/Core.cpp 994 return wrap(cast<User>(V)->getOperand(Index));
lib/IR/Instruction.cpp 487 getOperand(i)->getType()->getScalarType() !=
488 I->getOperand(i)->getType()->getScalarType() :
489 getOperand(i)->getType() != I->getOperand(i)->getType())
489 getOperand(i)->getType() != I->getOperand(i)->getType())
lib/IR/SafepointIRVerifier.cpp 810 containsGCPtrType(I.getOperand(0)->getType())) {
811 Value *LHS = I.getOperand(0), *RHS = I.getOperand(1);
811 Value *LHS = I.getOperand(0), *RHS = I.getOperand(1);
lib/IR/User.cpp 27 if (getOperand(i) == From) { // Is This operand is pointing to oldval?
lib/IR/Value.cpp 496 V = cast<Operator>(V)->getOperand(0);
501 V = cast<Operator>(V)->getOperand(0);
590 V = cast<Operator>(V)->getOperand(0);
lib/IR/Verifier.cpp 547 Assert(I.getOperand(i) != nullptr, "Operand is null", &I);
3982 Instruction *Op = cast<Instruction>(I.getOperand(i));
4105 Assert(I.getOperand(i) != nullptr, "Instruction has null operand!", &I);
4109 if (!I.getOperand(i)->getType()->isFirstClassType()) {
4113 if (Function *F = dyn_cast<Function>(I.getOperand(i))) {
4133 } else if (BasicBlock *OpBB = dyn_cast<BasicBlock>(I.getOperand(i))) {
4136 } else if (Argument *OpArg = dyn_cast<Argument>(I.getOperand(i))) {
4139 } else if (GlobalValue *GV = dyn_cast<GlobalValue>(I.getOperand(i))) {
4142 } else if (isa<Instruction>(I.getOperand(i))) {
4144 } else if (isa<InlineAsm>(I.getOperand(i))) {
4147 } else if (ConstantExpr *CE = dyn_cast<ConstantExpr>(I.getOperand(i))) {
lib/Target/AArch64/AArch64FastISel.cpp 315 if (const auto *LI = dyn_cast<LoadInst>(I->getOperand(0)))
319 if (const auto *Arg = dyn_cast<Argument>(I->getOperand(0)))
568 if (const auto *C = dyn_cast<ConstantInt>(MI->getOperand(0)))
571 if (const auto *C = dyn_cast<ConstantInt>(MI->getOperand(1)))
607 return computeAddress(U->getOperand(0), Addr, Ty);
611 if (TLI.getValueType(DL, U->getOperand(0)->getType()) ==
613 return computeAddress(U->getOperand(0), Addr, Ty);
619 return computeAddress(U->getOperand(0), Addr, Ty);
646 cast<ConstantInt>(cast<AddOperator>(Op)->getOperand(1));
649 Op = cast<AddOperator>(Op)->getOperand(0);
660 if (computeAddress(U->getOperand(0), Addr, Ty))
682 const Value *LHS = U->getOperand(0);
683 const Value *RHS = U->getOperand(1);
702 const Value *LHS = U->getOperand(0);
703 const Value *RHS = U->getOperand(1);
715 const auto *CI = dyn_cast<ConstantInt>(U->getOperand(1));
737 const Value *Src = U->getOperand(0);
793 const Value *LHS = U->getOperand(0);
794 const Value *RHS = U->getOperand(1);
854 const Value *LHS = U->getOperand(0);
855 const Value *RHS = U->getOperand(1);
947 return computeCallAddress(U->getOperand(0), Addr);
952 TLI.getValueType(DL, U->getOperand(0)->getType()) ==
954 return computeCallAddress(U->getOperand(0), Addr);
959 return computeCallAddress(U->getOperand(0), Addr);
1254 const Value *MulLHS = cast<MulOperator>(RHS)->getOperand(0);
1255 const Value *MulRHS = cast<MulOperator>(RHS)->getOperand(1);
1621 if (isa<ConstantInt>(SI->getOperand(1)))
1640 const Value *MulLHS = cast<MulOperator>(RHS)->getOperand(0);
1641 const Value *MulRHS = cast<MulOperator>(RHS)->getOperand(1);
1664 if (const auto *C = dyn_cast<ConstantInt>(SI->getOperand(1))) {
1666 unsigned RHSReg = getRegForValue(SI->getOperand(0));
1669 bool RHSIsKill = hasTrivialKill(SI->getOperand(0));
1935 ResultReg = emitAdd(VT, I->getOperand(0), I->getOperand(1));
1935 ResultReg = emitAdd(VT, I->getOperand(0), I->getOperand(1));
1938 ResultReg = emitSub(VT, I->getOperand(0), I->getOperand(1));
1938 ResultReg = emitSub(VT, I->getOperand(0), I->getOperand(1));
1961 ResultReg = emitLogicalOp(ISD::AND, VT, I->getOperand(0), I->getOperand(1));
1961 ResultReg = emitLogicalOp(ISD::AND, VT, I->getOperand(0), I->getOperand(1));
1964 ResultReg = emitLogicalOp(ISD::OR, VT, I->getOperand(0), I->getOperand(1));
1964 ResultReg = emitLogicalOp(ISD::OR, VT, I->getOperand(0), I->getOperand(1));
1967 ResultReg = emitLogicalOp(ISD::XOR, VT, I->getOperand(0), I->getOperand(1));
1967 ResultReg = emitLogicalOp(ISD::XOR, VT, I->getOperand(0), I->getOperand(1));
1986 const Value *SV = I->getOperand(0);
2003 if (!computeAddress(I->getOperand(0), Addr, I->getType()))
2181 const Value *Op0 = I->getOperand(0);
2188 const Value *PtrV = I->getOperand(1);
2840 Value *V = I->getOperand(0);
2856 Value *V = I->getOperand(0);
2877 unsigned SrcReg = getRegForValue(I->getOperand(0));
2881 EVT SrcVT = TLI.getValueType(DL, I->getOperand(0)->getType(), true);
2916 unsigned SrcReg = getRegForValue(I->getOperand(0));
2919 bool SrcIsKill = hasTrivialKill(I->getOperand(0));
2921 EVT SrcVT = TLI.getValueType(DL, I->getOperand(0)->getType(), true);
3942 Value *Op = I->getOperand(0);
4526 const auto *LI = dyn_cast<LoadInst>(I->getOperand(0));
4586 if (!isTypeSupported(I->getOperand(0)->getType(), SrcVT))
4593 unsigned SrcReg = getRegForValue(I->getOperand(0));
4596 bool SrcIsKill = hasTrivialKill(I->getOperand(0));
4600 if (const auto *Arg = dyn_cast<Argument>(I->getOperand(0))) {
4654 unsigned Src0Reg = getRegForValue(I->getOperand(0));
4657 bool Src0IsKill = hasTrivialKill(I->getOperand(0));
4659 unsigned Src1Reg = getRegForValue(I->getOperand(1));
4662 bool Src1IsKill = hasTrivialKill(I->getOperand(1));
4686 const Value *Src0 = I->getOperand(0);
4687 const Value *Src1 = I->getOperand(1);
4732 unsigned Src0Reg = getRegForValue(I->getOperand(0));
4735 bool Src0IsKill = hasTrivialKill(I->getOperand(0));
4737 unsigned Src1Reg = getRegForValue(I->getOperand(1));
4740 bool Src1IsKill = hasTrivialKill(I->getOperand(1));
4759 if (const auto *C = dyn_cast<ConstantInt>(I->getOperand(1))) {
4764 const Value *Op0 = I->getOperand(0);
4809 unsigned Op0Reg = getRegForValue(I->getOperand(0));
4812 bool Op0IsKill = hasTrivialKill(I->getOperand(0));
4814 unsigned Op1Reg = getRegForValue(I->getOperand(1));
4817 bool Op1IsKill = hasTrivialKill(I->getOperand(1));
4843 if (!isTypeLegal(I->getOperand(0)->getType(), SrcVT))
4868 unsigned Op0Reg = getRegForValue(I->getOperand(0));
4871 bool Op0IsKill = hasTrivialKill(I->getOperand(0));
4924 if (!isa<ConstantInt>(I->getOperand(1)))
4927 const APInt &C = cast<ConstantInt>(I->getOperand(1))->getValue();
4933 unsigned Src0Reg = getRegForValue(I->getOperand(0));
4936 bool Src0IsKill = hasTrivialKill(I->getOperand(0));
5014 unsigned N = getRegForValue(I->getOperand(0));
5017 bool NIsKill = hasTrivialKill(I->getOperand(0));
lib/Target/AArch64/AArch64ISelLowering.cpp 8528 EVT VT = getValueType(DL, User->getOperand(0)->getType());
8586 if (!isa<ConstantInt>(Instr->getOperand(1)))
8609 if (Instr->getType() == Ext->getOperand(0)->getType())
8667 2 * Ext->getOperand(0)->getType()->getScalarSizeInBits();
8703 if (!areExtractExts(I->getOperand(0), I->getOperand(1)))
8703 if (!areExtractExts(I->getOperand(0), I->getOperand(1)))
8708 auto Ext1 = cast<Instruction>(I->getOperand(0));
8709 auto Ext2 = cast<Instruction>(I->getOperand(1));
12341 ConstantInt* Mask = dyn_cast<ConstantInt>(AndI.getOperand(1));
lib/Target/AArch64/AArch64TargetTransformInfo.cpp 275 if (I == SingleUser->getOperand(1))
280 if (auto *Cast = dyn_cast<CastInst>(SingleUser->getOperand(1)))
lib/Target/AMDGPU/AMDGPUAtomicOptimizer.cpp 444 Value *const V = I.getOperand(ValIdx);
lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp 495 Value *OtherOp = Inst->getOperand(OpIdx0);
497 OtherOp = Inst->getOperand(OpIdx1);
lib/Target/AMDGPU/AMDGPUUnifyDivergentExitNodes.cpp 145 PN->addIncoming(BB->getTerminator()->getOperand(0), BB);
lib/Target/AMDGPU/SIISelLowering.cpp10957 if (V == U->getOperand(1)) {
10969 if (V == U->getOperand(0)) {
lib/Target/ARM/ARMCodeGenPrepare.cpp 347 !isa<ConstantInt>(I->getOperand(1)))
350 ConstantInt *OverflowConst = cast<ConstantInt>(I->getOperand(1));
483 assert((isa<ConstantInt>(I->getOperand(1)) &&
484 cast<ConstantInt>(I->getOperand(1))->isNegative()) &&
487 auto Const = cast<ConstantInt>(I->getOperand(1));
490 Value *NewVal = Builder.CreateSub(I->getOperand(0), NewConst);
557 Value *Op = I->getOperand(i);
596 Value *Args[] = { I->getOperand(0), I->getOperand(1) };
596 Value *Args[] = { I->getOperand(0), I->getOperand(1) };
655 if (Instruction *Trunc = InsertTrunc(I->getOperand(i), Ty)) {
765 TruncTysMap[I].push_back(I->getOperand(i)->getType());
823 return isSupportedType(I->getOperand(0));
829 if (isa<PointerType>(I->getOperand(0)->getType()))
831 return EqualTypeSize(I->getOperand(0));
lib/Target/ARM/ARMFastISel.cpp 741 return ARMComputeAddress(U->getOperand(0), Addr);
744 if (TLI.getValueType(DL, U->getOperand(0)->getType()) ==
746 return ARMComputeAddress(U->getOperand(0), Addr);
751 return ARMComputeAddress(U->getOperand(0), Addr);
778 cast<ConstantInt>(cast<AddOperator>(Op)->getOperand(1));
781 Op = cast<AddOperator>(Op)->getOperand(0);
792 if (ARMComputeAddress(U->getOperand(0), Addr)) return true;
1024 const Value *SV = I->getOperand(0);
1046 if (!ARMComputeAddress(I->getOperand(0), Addr)) return false;
1149 Value *Op0 = I->getOperand(0);
1156 const Value *PtrV = I->getOperand(1);
1173 if (!isLoadTypeLegal(I->getOperand(0)->getType(), VT))
1182 if (!ARMComputeAddress(I->getOperand(1), Addr))
1334 unsigned AddrReg = getRegForValue(I->getOperand(0));
1503 Value *V = I->getOperand(0);
1522 Value *V = I->getOperand(0);
1546 Value *Src = I->getOperand(0);
1591 unsigned Op = getRegForValue(I->getOperand(0));
1595 Type *OpTy = I->getOperand(0)->getType();
1623 unsigned CondReg = getRegForValue(I->getOperand(0));
1625 unsigned Op1Reg = getRegForValue(I->getOperand(1));
1632 if (const ConstantInt *ConstInt = dyn_cast<ConstantInt>(I->getOperand(2))) {
1645 Op2Reg = getRegForValue(I->getOperand(2));
1771 unsigned SrcReg1 = getRegForValue(I->getOperand(0));
1776 unsigned SrcReg2 = getRegForValue(I->getOperand(1));
1822 unsigned Op1 = getRegForValue(I->getOperand(0));
1825 unsigned Op2 = getRegForValue(I->getOperand(1));
2579 Value *Op = I->getOperand(0);
2742 Value *Src = I->getOperand(0);
2777 Value *Src2Value = I->getOperand(1);
2789 Value *Src1Value = I->getOperand(0);
lib/Target/ARM/ARMISelLowering.cpp14736 2 * Ext->getOperand(0)->getType()->getScalarSizeInBits();
14760 if (!areExtractExts(I->getOperand(0), I->getOperand(1)))
14760 if (!areExtractExts(I->getOperand(0), I->getOperand(1)))
14787 if (!isa<ShuffleVectorInst>(I->getOperand(Op)))
14791 if (!match(I->getOperand(Op),
14796 Instruction *Shuffle = cast<Instruction>(I->getOperand(Op));
lib/Target/ARM/ARMParallelDSP.cpp 114 Value *LHS = cast<Instruction>(I->getOperand(0))->getOperand(0);
114 Value *LHS = cast<Instruction>(I->getOperand(0))->getOperand(0);
115 Value *RHS = cast<Instruction>(I->getOperand(1))->getOperand(0);
115 Value *RHS = cast<Instruction>(I->getOperand(1))->getOperand(0);
122 if (auto *Mul = GetMulOperand(Add->getOperand(0)))
124 if (auto *Mul = GetMulOperand(Add->getOperand(1)))
461 Value *LHS = I->getOperand(0);
462 Value *RHS = I->getOperand(1);
472 Value *MulOp0 = I->getOperand(0);
473 Value *MulOp1 = I->getOperand(1);
477 return Search(I->getOperand(0), BB, R);
lib/Target/ARM/ARMTargetTransformInfo.cpp 175 if (I && isa<LoadInst>(I->getOperand(0))) {
lib/Target/Hexagon/HexagonISelLowering.cpp 1715 V = cast<Operator>(V)->getOperand(0);
1717 V = cast<Instruction>(V)->getOperand(0);
lib/Target/Hexagon/HexagonLoopIdiomRecognition.cpp 335 auto F = M.find(U->getOperand(i));
392 Value *Op = U->getOperand(i);
462 Value *OpI = I->getOperand(i), *OpJ = J->getOperand(i);
462 Value *OpI = I->getOperand(i), *OpJ = J->getOperand(i);
1046 if (ConstantInt *CI = dyn_cast<ConstantInt>(In->getOperand(i)))
1187 Value *TV = UseI->getOperand(1), *FV = UseI->getOperand(2);
1187 Value *TV = UseI->getOperand(1), *FV = UseI->getOperand(2);
1288 return Op != I->getOperand(1);
1571 if (const auto SI = dyn_cast<const ConstantInt>(I->getOperand(1)))
1576 return hasZeroSignBit(I->getOperand(0)) &&
1577 hasZeroSignBit(I->getOperand(1));
1579 return hasZeroSignBit(I->getOperand(0)) ||
1580 hasZeroSignBit(I->getOperand(1));
1591 Instruction *T = dyn_cast<Instruction>(I->getOperand(0));
1604 B.CreateZExt(T->getOperand(0), I->getType()),
1605 B.CreateZExt(T->getOperand(1), I->getType()));
1612 Instruction *And0 = dyn_cast<Instruction>(I->getOperand(0));
1613 Instruction *And1 = dyn_cast<Instruction>(I->getOperand(1));
1619 if (And0->getOperand(1) != And1->getOperand(1))
1619 if (And0->getOperand(1) != And1->getOperand(1))
1622 return B.CreateAnd(B.CreateXor(And0->getOperand(0), And1->getOperand(0)),
1622 return B.CreateAnd(B.CreateXor(And0->getOperand(0), And1->getOperand(0)),
1623 And0->getOperand(1));
1675 ConstantInt *Msb = dyn_cast<ConstantInt>(I->getOperand(1));
1678 if (!hasZeroSignBit(I->getOperand(0)))
1680 return IRBuilder<>(Ctx).CreateXor(I->getOperand(0), Msb);
1687 BinaryOperator *BitOp = dyn_cast<BinaryOperator>(I->getOperand(0));
1699 Value *S = I->getOperand(1);
1738 Instruction *Xor = dyn_cast<Instruction>(I->getOperand(0));
1739 ConstantInt *C0 = dyn_cast<ConstantInt>(I->getOperand(1));
1744 Instruction *And0 = dyn_cast<Instruction>(Xor->getOperand(0));
1745 Instruction *And1 = dyn_cast<Instruction>(Xor->getOperand(1));
1749 ConstantInt *C1 = dyn_cast<ConstantInt>(And0->getOperand(1));
1757 return B.CreateAnd(B.CreateXor(And0->getOperand(0), And1), C0);
lib/Target/Hexagon/HexagonOptimizeSZextends.cpp 118 Value *Intr = Shl->getOperand(0);
119 Value *ShlOp1 = Shl->getOperand(1);
lib/Target/Hexagon/HexagonVectorLoopCarriedReuse.cpp 420 ConstantInt *C1 = dyn_cast<ConstantInt>(I1->getOperand(i));
421 ConstantInt *C2 = dyn_cast<ConstantInt>(I2->getOperand(i));
521 Value *Op = I->getOperand(OpNo);
525 Value *BEOp = BEUser->getOperand(T);
553 Value *Op = I->getOperand(OpNo);
554 Value *BEOp = BEUser->getOperand(OpNo);
616 Instruction *I = dyn_cast<Instruction>(Inst2Replace->getOperand(j));
lib/Target/Mips/MipsFastISel.cpp 485 return computeAddress(U->getOperand(0), Addr);
510 cast<ConstantInt>(cast<AddOperator>(Op)->getOperand(1));
513 Op = cast<AddOperator>(Op)->getOperand(0);
523 if (computeAddress(U->getOperand(0), Addr))
567 return computeCallAddress(U->getOperand(0), Addr);
571 if (TLI.getValueType(DL, U->getOperand(0)->getType()) ==
573 return computeCallAddress(U->getOperand(0), Addr);
578 return computeCallAddress(U->getOperand(0), Addr);
875 ResultReg = emitLogicalOp(ISD::AND, VT, I->getOperand(0), I->getOperand(1));
875 ResultReg = emitLogicalOp(ISD::AND, VT, I->getOperand(0), I->getOperand(1));
878 ResultReg = emitLogicalOp(ISD::OR, VT, I->getOperand(0), I->getOperand(1));
878 ResultReg = emitLogicalOp(ISD::OR, VT, I->getOperand(0), I->getOperand(1));
881 ResultReg = emitLogicalOp(ISD::XOR, VT, I->getOperand(0), I->getOperand(1));
881 ResultReg = emitLogicalOp(ISD::XOR, VT, I->getOperand(0), I->getOperand(1));
904 if (!computeAddress(I->getOperand(0), Addr))
915 Value *Op0 = I->getOperand(0);
924 if (!isLoadTypeLegal(I->getOperand(0)->getType(), VT))
934 if (!computeAddress(I->getOperand(1), Addr))
999 Value *Src = I->getOperand(0);
1078 Value *Src = I->getOperand(0);
1113 Value *Src = I->getOperand(0);
1783 Value *Op = I->getOperand(0);
1806 Value *Src = I->getOperand(0);
1941 unsigned Src0Reg = getRegForValue(I->getOperand(0));
1942 unsigned Src1Reg = getRegForValue(I->getOperand(1));
1973 const Value *Op0 = I->getOperand(0);
1992 if (const auto *C = dyn_cast<ConstantInt>(I->getOperand(1))) {
2014 unsigned Op1Reg = getRegForValue(I->getOperand(1));
lib/Target/NVPTX/NVPTXAsmPrinter.cpp 106 DiscoverDependentGlobals(U->getOperand(i), Globals);
1934 bufferLEByte(cast<Constant>(CPV->getOperand(i)), 0, aggBuffer);
1958 bufferLEByte(cast<Constant>(CPV->getOperand(i)), Bytes, aggBuffer);
lib/Target/NVPTX/NVPTXGenericToNVVM.cpp 112 Value *Operand = II->getOperand(i);
204 Value *Operand = C->getOperand(i);
lib/Target/NVPTX/NVPTXImageOptimizer.cpp 93 Value *TexHandle = cleanupValue(I.getOperand(0));
109 Value *TexHandle = cleanupValue(I.getOperand(0));
128 Value *TexHandle = cleanupValue(I.getOperand(0));
lib/Target/NVPTX/NVVMReflect.cpp 142 const Value *Operand = cast<Constant>(Sym)->getOperand(0);
lib/Target/PowerPC/PPCBoolRetToInt.cpp 259 Second->setOperand(i, BoolToIntMap[First->getOperand(i)]);
lib/Target/PowerPC/PPCFastISel.cpp 331 return PPCComputeAddress(U->getOperand(0), Addr);
334 if (TLI.getValueType(DL, U->getOperand(0)->getType()) ==
336 return PPCComputeAddress(U->getOperand(0), Addr);
341 return PPCComputeAddress(U->getOperand(0), Addr);
368 cast<ConstantInt>(cast<AddOperator>(Op)->getOperand(1));
371 Op = cast<AddOperator>(Op)->getOperand(0);
382 if (PPCComputeAddress(U->getOperand(0), Addr)) return true;
605 if (!PPCComputeAddress(I->getOperand(0), Addr))
740 Value *Op0 = I->getOperand(0);
759 if (!PPCComputeAddress(I->getOperand(1), Addr))
959 Value *Src = I->getOperand(0);
977 Value *Src = I->getOperand(0);
1073 Value *Src = I->getOperand(0);
1203 Value *Src = I->getOperand(0);
1301 unsigned SrcReg1 = getRegForValue(I->getOperand(0));
1305 if (const ConstantInt *ConstInt = dyn_cast<ConstantInt>(I->getOperand(1))) {
1359 unsigned SrcReg2 = getRegForValue(I->getOperand(1));
1857 unsigned AddrReg = getRegForValue(I->getOperand(0));
1874 Value *Src = I->getOperand(0);
1899 Value *Src = I->getOperand(0);
lib/Target/PowerPC/PPCISelLowering.cpp15451 const Value *Mask = AndI.getOperand(1);
lib/Target/SystemZ/SystemZISelLowering.cpp 853 if (auto *C = dyn_cast<ConstantInt>(SingleUser->getOperand(1)))
878 I->getOperand(0)->getType());
885 Value *DataOp = I->getOperand(0);
lib/Target/SystemZ/SystemZTargetTransformInfo.cpp 261 Type *MemAccessTy = I.getOperand(0)->getType();
630 if (CmpInst *CI = dyn_cast<CmpInst>(I->getOperand(0)))
632 else if (Instruction *LogicI = dyn_cast<Instruction>(I->getOperand(0)))
634 if (CmpInst *CI0 = dyn_cast<CmpInst>(LogicI->getOperand(0)))
635 if (isa<CmpInst>(LogicI->getOperand(1)))
768 (I != nullptr && isa<LoadInst>(I->getOperand(0))))
867 if (LoadInst *Ld = dyn_cast<LoadInst>(I->getOperand(0)))
868 if (const ConstantInt *C = dyn_cast<ConstantInt>(I->getOperand(1)))
936 UserI->getOperand(1) != FoldedValue)
979 if (ConstantInt *CI = dyn_cast<ConstantInt>(UserI->getOperand(1)))
1012 if (UserI->getOperand(i) == FoldedValue)
1015 if (Instruction *OtherOp = dyn_cast<Instruction>(UserI->getOperand(i))){
1020 OtherLoad = dyn_cast<LoadInst>(OtherOp->getOperand(0));
lib/Target/WebAssembly/WebAssemblyFastISel.cpp 247 return computeAddress(U->getOperand(0), Addr);
251 if (TLI.getValueType(DL, U->getOperand(0)->getType()) ==
253 return computeAddress(U->getOperand(0), Addr);
259 return computeAddress(U->getOperand(0), Addr);
295 auto *CI = cast<ConstantInt>(cast<AddOperator>(Op)->getOperand(1));
298 Op = cast<AddOperator>(Op)->getOperand(0);
310 if (computeAddress(U->getOperand(0), Addr))
334 const Value *LHS = U->getOperand(0);
335 const Value *RHS = U->getOperand(1);
357 const Value *LHS = U->getOperand(0);
358 const Value *RHS = U->getOperand(1);
1129 EVT VT = TLI.getValueType(DL, I->getOperand(0)->getType());
1134 unsigned In = getRegForValue(I->getOperand(0));
1145 In, I->getOperand(0)->hasOneUse());
lib/Target/X86/X86FastISel.cpp 857 return X86SelectAddress(U->getOperand(0), AM);
861 if (TLI.getValueType(DL, U->getOperand(0)->getType()) ==
863 return X86SelectAddress(U->getOperand(0), AM);
869 return X86SelectAddress(U->getOperand(0), AM);
887 if (const ConstantInt *CI = dyn_cast<ConstantInt>(U->getOperand(1))) {
892 return X86SelectAddress(U->getOperand(0), AM);
929 cast<ConstantInt>(cast<AddOperator>(Op)->getOperand(1));
932 Op = cast<AddOperator>(Op)->getOperand(0);
960 dyn_cast<GetElementPtrInst>(U->getOperand(0))) {
965 } else if (X86SelectAddress(U->getOperand(0), AM)) {
1031 return X86SelectCallAddress(U->getOperand(0), AM);
1037 TLI.getValueType(DL, U->getOperand(0)->getType()) ==
1039 return X86SelectCallAddress(U->getOperand(0), AM);
1045 return X86SelectCallAddress(U->getOperand(0), AM);
1108 const Value *PtrV = I->getOperand(1);
1299 const Value *SV = I->getOperand(0);
1429 if (!isTypeLegal(I->getOperand(0)->getType(), VT))
1524 unsigned ResultReg = getRegForValue(I->getOperand(0));
1529 MVT SrcVT = TLI.getSimpleValueType(DL, I->getOperand(0)->getType());
1583 unsigned ResultReg = getRegForValue(I->getOperand(0));
1588 MVT SrcVT = TLI.getSimpleValueType(DL, I->getOperand(0)->getType());
1826 unsigned Op0Reg = getRegForValue(I->getOperand(0));
1829 unsigned Op1Reg = getRegForValue(I->getOperand(1));
1935 unsigned Op0Reg = getRegForValue(I->getOperand(0));
1938 unsigned Op1Reg = getRegForValue(I->getOperand(1));
2023 const Value *Cond = I->getOperand(0);
2121 const Value *LHS = I->getOperand(1);
2122 const Value *RHS = I->getOperand(2);
2150 const auto *CI = dyn_cast<FCmpInst>(I->getOperand(0));
2181 const Value *LHS = I->getOperand(1);
2182 const Value *RHS = I->getOperand(2);
2296 const Value *Cond = I->getOperand(0);
2339 const Value *LHS = I->getOperand(1);
2340 const Value *RHS = I->getOperand(2);
2365 if (const auto *CI = dyn_cast<CmpInst>(I->getOperand(0))) {
2370 case CmpInst::FCMP_FALSE: Opnd = I->getOperand(2); break;
2371 case CmpInst::FCMP_TRUE: Opnd = I->getOperand(1); break;
2416 MVT SrcVT = TLI.getSimpleValueType(DL, I->getOperand(0)->getType());
2421 unsigned OpReg = getRegForValue(I->getOperand(0));
2476 unsigned OpReg = getRegForValue(I->getOperand(0));
2503 I->getOperand(0)->getType()->isFloatTy()) {
2517 I->getOperand(0)->getType()->isDoubleTy()) {
2530 EVT SrcVT = TLI.getValueType(DL, I->getOperand(0)->getType());
2539 unsigned InputReg = getRegForValue(I->getOperand(0));
3643 EVT SrcVT = TLI.getValueType(DL, I->getOperand(0)->getType());
3649 unsigned Reg = getRegForValue(I->getOperand(0));
3660 if (!isTypeLegal(I->getOperand(0)->getType(), SrcVT) ||
3670 unsigned Reg = getRegForValue(I->getOperand(0));
lib/Target/X86/X86TargetTransformInfo.cpp 3095 Value *Ptr = U->getOperand(1);
lib/Transforms/AggressiveInstCombine/AggressiveInstCombine.cpp 283 Value *Op0 = I.getOperand(0);
284 Value *Op1 = I.getOperand(1);
lib/Transforms/AggressiveInstCombine/TruncInstCombine.cpp 56 Ops.push_back(I->getOperand(0));
57 Ops.push_back(I->getOperand(1));
251 I->getOperand(0)->getType()->getScalarSizeInBits();
318 if (I->getOperand(0)->getType() == Ty) {
320 NodeInfo.NewValue = I->getOperand(0);
325 Res = Builder.CreateIntCast(I->getOperand(0), Ty,
349 Value *LHS = getReducedOperand(I->getOperand(0), SclTy);
350 Value *RHS = getReducedOperand(I->getOperand(1), SclTy);
lib/Transforms/IPO/Attributor.cpp 3574 auto *Num = cast<ConstantInt>(MallocCall->getOperand(0));
3575 auto *SizeT = dyn_cast<ConstantInt>(MallocCall->getOperand(1));
3578 ConstantInt::get(MallocCall->getOperand(0)->getType(), TotalSize);
3580 Size = cast<ConstantInt>(MallocCall->getOperand(0));
3608 Type *Tys[] = {BI->getType(), MallocCall->getOperand(0)->getType()};
3719 if (auto *Size = dyn_cast<ConstantInt>(I.getOperand(0)))
3727 if (auto *Num = dyn_cast<ConstantInt>(I.getOperand(0)))
3728 if (auto *Size = dyn_cast<ConstantInt>(I.getOperand(1)))
lib/Transforms/IPO/DeadArgumentElimination.cpp 446 == CS->getOperand(U->getOperandNo())
lib/Transforms/IPO/FunctionAttrs.cpp 886 FlowsToReturn.insert(RVI->getOperand(0));
999 FlowsToReturn.insert(RVI->getOperand(0));
lib/Transforms/IPO/GlobalOpt.cpp 181 V = I->getOperand(0);
259 Instruction *J = dyn_cast<Instruction>(I->getOperand(0));
370 if (U->getNumOperands() < 3 || !isa<Constant>(U->getOperand(1)) ||
371 !cast<Constant>(U->getOperand(1))->isNullValue())
561 unsigned Val = cast<ConstantInt>(GEP->getOperand(2))->getZExtValue();
650 isa<ConstantPointerNull>(U->getOperand(1))) {
773 assert(GlobalUser->getOperand(1) == GV &&
1724 StoreVal = StoredVal->getOperand(0);
lib/Transforms/IPO/GlobalSplit.cpp 61 !isa<ConstantInt>(GEP->getOperand(1)) ||
62 !cast<ConstantInt>(GEP->getOperand(1))->isZero() ||
63 !isa<ConstantInt>(GEP->getOperand(2)))
117 unsigned I = cast<ConstantInt>(GEP->getOperand(2))->getZExtValue();
124 Ops.push_back(GEP->getOperand(I));
lib/Transforms/IPO/LowerTypeTests.cpp 716 return isKnownTypeIdMember(TypeId, DL, Op->getOperand(0), COffset);
719 return isKnownTypeIdMember(TypeId, DL, Op->getOperand(1), COffset) &&
720 isKnownTypeIdMember(TypeId, DL, Op->getOperand(2), COffset);
lib/Transforms/InstCombine/InstCombineAddSub.cpp 356 Value *Opnd0 = I->getOperand(0);
357 Value *Opnd1 = I->getOperand(1);
390 Value *V0 = I->getOperand(0);
391 Value *V1 = I->getOperand(1);
468 Value *V0 = I->getOperand(0);
469 Value *V1 = I->getOperand(1);
1600 if (LHSGEP->getOperand(0) == RHS) {
1605 if (LHSGEP->getOperand(0)->stripPointerCasts() ==
1606 RHSGEP->getOperand(0)->stripPointerCasts()) {
1616 if (RHSGEP->getOperand(0) == LHS) {
1621 if (RHSGEP->getOperand(0)->stripPointerCasts() ==
1622 LHSGEP->getOperand(0)->stripPointerCasts()) {
1788 Value *ShAmtOp = cast<Instruction>(Op1Wide)->getOperand(1);
1800 Value *ShAmtOp = cast<Instruction>(Op1Wide)->getOperand(1);
lib/Transforms/InstCombine/InstCombineAndOrXor.cpp 1985 Op0 = Ext->getOperand(0);
1988 Op1 = Ext->getOperand(0);
2038 if (!match(Or.getOperand(0), m_BinOp(Or0)) ||
2039 !match(Or.getOperand(1), m_BinOp(Or1)))
lib/Transforms/InstCombine/InstCombineCasts.cpp 187 Value *LHS = EvaluateInDifferentType(I->getOperand(0), Ty, isSigned);
188 Value *RHS = EvaluateInDifferentType(I->getOperand(1), Ty, isSigned);
198 if (I->getOperand(0)->getType() == Ty)
199 return I->getOperand(0);
203 Res = CastInst::CreateIntegerCast(I->getOperand(0), Ty,
207 Value *True = EvaluateInDifferentType(I->getOperand(1), Ty, isSigned);
208 Value *False = EvaluateInDifferentType(I->getOperand(2), Ty, isSigned);
209 Res = SelectInst::Create(I->getOperand(0), True, False);
358 return canEvaluateTruncated(I->getOperand(0), Ty, IC, CxtI) &&
359 canEvaluateTruncated(I->getOperand(1), Ty, IC, CxtI);
368 if (IC.MaskedValueIsZero(I->getOperand(0), Mask, 0, CxtI) &&
369 IC.MaskedValueIsZero(I->getOperand(1), Mask, 0, CxtI)) {
370 return canEvaluateTruncated(I->getOperand(0), Ty, IC, CxtI) &&
371 canEvaluateTruncated(I->getOperand(1), Ty, IC, CxtI);
379 if (match(I->getOperand(1), m_APInt(Amt))) {
382 return canEvaluateTruncated(I->getOperand(0), Ty, IC, CxtI);
391 if (match(I->getOperand(1), m_APInt(Amt))) {
395 IC.MaskedValueIsZero(I->getOperand(0),
397 return canEvaluateTruncated(I->getOperand(0), Ty, IC, CxtI);
409 if (match(I->getOperand(1), m_APInt(Amt))) {
414 IC.ComputeNumSignBits(I->getOperand(0), 0, CxtI))
415 return canEvaluateTruncated(I->getOperand(0), Ty, IC, CxtI);
788 Value *SExt = cast<Instruction>(Src)->getOperand(0);
1003 if (!canEvaluateZExtd(I->getOperand(0), Ty, BitsToClear, IC, CxtI) ||
1004 !canEvaluateZExtd(I->getOperand(1), Ty, Tmp, IC, CxtI))
1016 if (IC.MaskedValueIsZero(I->getOperand(1),
1034 if (match(I->getOperand(1), m_APInt(Amt))) {
1035 if (!canEvaluateZExtd(I->getOperand(0), Ty, BitsToClear, IC, CxtI))
1047 if (match(I->getOperand(1), m_APInt(Amt))) {
1048 if (!canEvaluateZExtd(I->getOperand(0), Ty, BitsToClear, IC, CxtI))
1059 if (!canEvaluateZExtd(I->getOperand(1), Ty, Tmp, IC, CxtI) ||
1060 !canEvaluateZExtd(I->getOperand(2), Ty, BitsToClear, IC, CxtI) ||
1333 return canEvaluateSExtd(I->getOperand(0), Ty) &&
1334 canEvaluateSExtd(I->getOperand(1), Ty);
1340 return canEvaluateSExtd(I->getOperand(1), Ty) &&
1341 canEvaluateSExtd(I->getOperand(2), Ty);
1688 if (!isa<UIToFPInst>(FI.getOperand(0)) && !isa<SIToFPInst>(FI.getOperand(0)))
1688 if (!isa<UIToFPInst>(FI.getOperand(0)) && !isa<SIToFPInst>(FI.getOperand(0)))
1690 Instruction *OpI = cast<Instruction>(FI.getOperand(0));
1692 Value *SrcI = OpI->getOperand(0);
1964 return collectInsertionElements(I->getOperand(0), Shift, Elements, VecEltTy,
1968 I->getOperand(0)->getType()->getPrimitiveSizeInBits(),
1971 return collectInsertionElements(I->getOperand(0), Shift, Elements, VecEltTy,
1974 return collectInsertionElements(I->getOperand(0), Shift, Elements, VecEltTy,
1976 collectInsertionElements(I->getOperand(1), Shift, Elements, VecEltTy,
1980 ConstantInt *CI = dyn_cast<ConstantInt>(I->getOperand(1));
1984 return collectInsertionElements(I->getOperand(0), Shift, Elements, VecEltTy,
lib/Transforms/InstCombine/InstCombineCompares.cpp 437 if (ConstantInt *CI = dyn_cast<ConstantInt>(GEP->getOperand(i))) {
458 Value *VariableIdx = GEP->getOperand(i);
465 ConstantInt *CI = dyn_cast<ConstantInt>(GEP->getOperand(i));
483 Type *IntPtrTy = DL.getIntPtrType(GEP->getOperand(0)->getType());
570 if (Explored.count(GEP->getOperand(0)) == 0)
571 WorkList.push_back(GEP->getOperand(0));
685 Value *Index = NewInsts[GEP->getOperand(1)] ? NewInsts[GEP->getOperand(1)]
685 Value *Index = NewInsts[GEP->getOperand(1)] ? NewInsts[GEP->getOperand(1)]
686 : GEP->getOperand(1);
691 NewInsts[GEP->getOperand(0)]->getType()->getScalarSizeInBits()) {
693 Index, NewInsts[GEP->getOperand(0)]->getType(),
694 GEP->getOperand(0)->getName() + ".sext");
697 auto *Op = NewInsts[GEP->getOperand(0)];
702 Op, Index, GEP->getOperand(0)->getName() + ".add");
776 V = GEP->getOperand(0);
777 Constant *GEPIndex = static_cast<Constant *>(GEP->getOperand(1));
860 Value *PtrBase = GEPLHS->getOperand(0);
909 if (PtrBase != GEPRHS->getOperand(0)) {
911 IndicesTheSame &= GEPLHS->getOperand(0)->getType() ==
912 GEPRHS->getOperand(0)->getType();
915 if (GEPLHS->getOperand(i) != GEPRHS->getOperand(i)) {
915 if (GEPLHS->getOperand(i) != GEPRHS->getOperand(i)) {
921 Type *BaseType = GEPLHS->getOperand(0)->getType();
923 return new ICmpInst(Cond, GEPLHS->getOperand(0), GEPRHS->getOperand(0));
923 return new ICmpInst(Cond, GEPLHS->getOperand(0), GEPRHS->getOperand(0));
933 GEPRHS->getOperand(0)->stripPointerCasts() &&
965 return foldGEPICmp(GEPRHS, GEPLHS->getOperand(0),
971 return foldGEPICmp(GEPLHS, GEPRHS->getOperand(0), Cond, I);
979 if (GEPLHS->getOperand(i) != GEPRHS->getOperand(i)) {
979 if (GEPLHS->getOperand(i) != GEPRHS->getOperand(i)) {
980 Type *LHSType = GEPLHS->getOperand(i)->getType();
981 Type *RHSType = GEPRHS->getOperand(i)->getType();
1001 Value *LHSV = GEPLHS->getOperand(DiffOperand);
1002 Value *RHSV = GEPRHS->getOperand(DiffOperand);
1296 Instruction *OrigAdd = cast<Instruction>(AddWithCst->getOperand(0));
3181 I.getPredicate(), LHSI->getOperand(0),
3182 Constant::getNullValue(LHSI->getOperand(0)->getType()));
3198 if (Constant *C = dyn_cast<Constant>(LHSI->getOperand(1))) {
3202 if (Constant *C = dyn_cast<Constant>(LHSI->getOperand(2))) {
3231 Op1 = Builder.CreateICmp(I.getPredicate(), LHSI->getOperand(1), RHSC,
3234 Op2 = Builder.CreateICmp(I.getPredicate(), LHSI->getOperand(2), RHSC,
3236 return SelectInst::Create(LHSI->getOperand(0), Op1, Op2);
3243 DL.getIntPtrType(RHSC->getType()) == LHSI->getOperand(0)->getType())
3245 I.getPredicate(), LHSI->getOperand(0),
3246 Constant::getNullValue(LHSI->getOperand(0)->getType()));
3252 dyn_cast<GetElementPtrInst>(LHSI->getOperand(0))) {
3509 !NarrowestShift->getOperand(1)->hasOneUse())
3552 if (auto *C = dyn_cast<Constant>(NarrowestShift->getOperand(0))) {
3563 if (auto *C = dyn_cast<Constant>(WidestShift->getOperand(0))) {
4415 Value *PtrSrc = PtrToIntOp1->getOperand(0);
4418 NewOp1 = PtrToIntOp1->getOperand(0);
4541 auto *LHS = cast<ZExtOperator>(MulInstr->getOperand(0)),
4542 *RHS = cast<ZExtOperator>(MulInstr->getOperand(1));
4545 Value *A = LHS->getOperand(0), *B = RHS->getOperand(0);
4545 Value *A = LHS->getOperand(0), *B = RHS->getOperand(0);
5614 IntegerType *IntTy = cast<IntegerType>(LHSI->getOperand(0)->getType());
5839 return new ICmpInst(Pred, LHSI->getOperand(0), RHSInt);
5876 if (!match(LHSI->getOperand(0), m_APFloat(C)))
5886 return new FCmpInst(Pred, LHSI->getOperand(1), RHSC, "", &I);
6059 if (auto *GEP = dyn_cast<GetElementPtrInst>(LHSI->getOperand(0)))
lib/Transforms/InstCombine/InstCombinePHI.cpp 287 Value *LHSVal = FirstInst->getOperand(0);
288 Value *RHSVal = FirstInst->getOperand(1);
299 I->getOperand(0)->getType() != LHSType ||
300 I->getOperand(1)->getType() != RHSType)
309 if (I->getOperand(0) != LHSVal) LHSVal = nullptr;
310 if (I->getOperand(1) != RHSVal) RHSVal = nullptr;
322 Value *InLHS = FirstInst->getOperand(0);
323 Value *InRHS = FirstInst->getOperand(1);
327 FirstInst->getOperand(0)->getName() + ".pn");
335 FirstInst->getOperand(1)->getName() + ".pn");
346 Value *NewInLHS = InInst->getOperand(0);
350 Value *NewInRHS = InInst->getOperand(1);
746 CastSrcTy = FirstInst->getOperand(0)->getType();
757 ConstantOp = dyn_cast<Constant>(FirstInst->getOperand(1));
770 if (I->getOperand(0)->getType() != CastSrcTy)
772 } else if (I->getOperand(1) != ConstantOp) {
779 PHINode *NewPN = PHINode::Create(FirstInst->getOperand(0)->getType(),
783 Value *InVal = FirstInst->getOperand(0);
788 Value *NewInVal = cast<Instruction>(PN.getIncomingValue(i))->getOperand(0);
1004 !isa<ConstantInt>(UserI->getOperand(1)))
1009 if (cast<ConstantInt>(UserI->getOperand(1))->getValue().uge(SizeInBits))
1012 unsigned Shift = cast<ConstantInt>(UserI->getOperand(1))->getZExtValue();
lib/Transforms/InstCombine/InstCombineSelect.cpp 298 Type *FIOpndTy = FI->getOperand(0)->getType();
299 if (TI->getOperand(0)->getType() != FIOpndTy)
330 Builder.CreateSelect(Cond, TI->getOperand(0), FI->getOperand(0),
330 Builder.CreateSelect(Cond, TI->getOperand(0), FI->getOperand(0),
360 if (TI->getOperand(0) == FI->getOperand(0)) {
360 if (TI->getOperand(0) == FI->getOperand(0)) {
361 MatchOp = TI->getOperand(0);
362 OtherOpT = TI->getOperand(1);
363 OtherOpF = FI->getOperand(1);
365 } else if (TI->getOperand(1) == FI->getOperand(1)) {
365 } else if (TI->getOperand(1) == FI->getOperand(1)) {
366 MatchOp = TI->getOperand(1);
367 OtherOpT = TI->getOperand(0);
368 OtherOpF = FI->getOperand(0);
372 } else if (TI->getOperand(0) == FI->getOperand(1)) {
372 } else if (TI->getOperand(0) == FI->getOperand(1)) {
373 MatchOp = TI->getOperand(0);
374 OtherOpT = TI->getOperand(1);
375 OtherOpF = FI->getOperand(0);
377 } else if (TI->getOperand(1) == FI->getOperand(0)) {
377 } else if (TI->getOperand(1) == FI->getOperand(0)) {
378 MatchOp = TI->getOperand(1);
379 OtherOpT = TI->getOperand(0);
380 OtherOpF = FI->getOperand(1);
1692 if (SubOp->getOperand(0) == AddOp->getOperand(0)) {
1692 if (SubOp->getOperand(0) == AddOp->getOperand(0)) {
1693 OtherAddOp = AddOp->getOperand(1);
1694 } else if (SubOp->getOperand(0) == AddOp->getOperand(1)) {
1694 } else if (SubOp->getOperand(0) == AddOp->getOperand(1)) {
1695 OtherAddOp = AddOp->getOperand(0);
1703 NegVal = Builder.CreateFNeg(SubOp->getOperand(1));
1710 NegVal = Builder.CreateNeg(SubOp->getOperand(1));
1722 BinaryOperator::CreateFAdd(SubOp->getOperand(0), NewSel);
1729 return BinaryOperator::CreateAdd(SubOp->getOperand(0), NewSel);
1752 Value *X = ExtInst->getOperand(0);
lib/Transforms/InstCombine/InstCombineShifts.cpp 350 if (!match(InnerShift->getOperand(1), m_APInt(InnerShiftConst)))
378 if (IC.MaskedValueIsZero(InnerShift->getOperand(0), Mask, 0, CxtI))
439 return canEvaluateShifted(I->getOperand(0), NumBits, IsLeftShift, IC, I) &&
440 canEvaluateShifted(I->getOperand(1), NumBits, IsLeftShift, IC, I);
557 0, getShiftedValue(I->getOperand(0), NumBits, isLeftShift, IC, DL));
559 1, getShiftedValue(I->getOperand(1), NumBits, isLeftShift, IC, DL));
569 1, getShiftedValue(I->getOperand(1), NumBits, isLeftShift, IC, DL));
571 2, getShiftedValue(I->getOperand(2), NumBits, isLeftShift, IC, DL));
642 isa<ConstantInt>(TrOp->getOperand(1))) {
lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp 45 Value *Op = I->getOperand(OpNo);
187 return I->getOperand(0);
189 return I->getOperand(1);
221 return I->getOperand(0);
223 return I->getOperand(1);
255 return I->getOperand(0);
257 return I->getOperand(1);
264 BinaryOperator::CreateOr(I->getOperand(0), I->getOperand(1),
264 BinaryOperator::CreateOr(I->getOperand(0), I->getOperand(1),
277 Instruction *And = BinaryOperator::CreateAnd(I->getOperand(0), AndC);
290 if (Instruction *LHSInst = dyn_cast<Instruction>(I->getOperand(0)))
292 isa<ConstantInt>(I->getOperand(1)) &&
293 isa<ConstantInt>(LHSInst->getOperand(1)) &&
295 ConstantInt *AndRHS = cast<ConstantInt>(LHSInst->getOperand(1));
296 ConstantInt *XorRHS = cast<ConstantInt>(I->getOperand(1));
301 Instruction *NewAnd = BinaryOperator::CreateAnd(I->getOperand(0), AndC);
362 unsigned SrcBitWidth = I->getOperand(0)->getType()->getScalarSizeInBits();
375 if (!I->getOperand(0)->getType()->isIntOrIntVectorTy())
380 dyn_cast<VectorType>(I->getOperand(0)->getType())) {
387 } else if (I->getOperand(0)->getType()->isVectorTy())
397 unsigned SrcBitWidth = I->getOperand(0)->getType()->getScalarSizeInBits();
415 CastInst *NewCast = new ZExtInst(I->getOperand(0), VTy, I->getName());
451 return I->getOperand(0);
457 return I->getOperand(1);
467 if (match(I->getOperand(1), m_APInt(SA))) {
469 if (match(I->getOperand(0), m_Shr(m_Value(), m_APInt(ShrAmt))))
470 if (Instruction *Shr = dyn_cast<Instruction>(I->getOperand(0)))
498 if (match(I->getOperand(1), m_APInt(SA))) {
527 I->getOperand(0), I->getOperand(1), I->getName());
527 I->getOperand(0), I->getOperand(1), I->getName());
534 return I->getOperand(0);
537 if (match(I->getOperand(1), m_APInt(SA))) {
555 unsigned SignBits = ComputeNumSignBits(I->getOperand(0), Depth + 1, CxtI);
569 BinaryOperator *LShr = BinaryOperator::CreateLShr(I->getOperand(0),
570 I->getOperand(1));
582 if (match(I->getOperand(1), m_APInt(SA))) {
601 if (ConstantInt *Rem = dyn_cast<ConstantInt>(I->getOperand(1))) {
609 return I->getOperand(0);
638 computeKnownBits(I->getOperand(0), LHSKnown, Depth + 1, CxtI);
694 if (!match(I->getOperand(2), m_APInt(SA)))
780 computeKnownBits(I->getOperand(1), RHSKnown, Depth + 1, CxtI);
781 computeKnownBits(I->getOperand(0), LHSKnown, Depth + 1,
798 return I->getOperand(0);
800 return I->getOperand(1);
811 computeKnownBits(I->getOperand(1), RHSKnown, Depth + 1, CxtI);
812 computeKnownBits(I->getOperand(0), LHSKnown, Depth + 1,
829 return I->getOperand(0);
831 return I->getOperand(1);
841 computeKnownBits(I->getOperand(1), RHSKnown, Depth + 1, CxtI);
842 computeKnownBits(I->getOperand(0), LHSKnown, Depth + 1,
860 return I->getOperand(0);
862 return I->getOperand(1);
911 Value *VarX = Shr->getOperand(0);
1170 Value *Op = II ? II->getArgOperand(OpNum) : Inst->getOperand(OpNum);
1204 if (isa<UndefValue>(I->getOperand(i))) {
1209 if (I->getOperand(i)->getType()->isVectorTy()) {
1221 ConstantInt *Idx = dyn_cast<ConstantInt>(I->getOperand(2));
1242 return I->getOperand(0);
1397 VectorType *VTy = dyn_cast<VectorType>(I->getOperand(0)->getType());
lib/Transforms/InstCombine/InstCombineVectorOps.cpp 710 if (!UserInsInst || U->getOperand(0) != V)
1191 ConstantInt *CI = dyn_cast<ConstantInt>(I->getOperand(2));
1205 return canEvaluateShuffled(I->getOperand(0), Mask, Depth - 1);
1353 if (I->getOperand(i)->getType()->isVectorTy())
1354 V = evaluateInDifferentElementOrder(I->getOperand(i), Mask);
1356 V = I->getOperand(i);
1358 NeedsRebuild |= (V != I->getOperand(i));
1366 int Element = cast<ConstantInt>(I->getOperand(2))->getLimitedValue();
1383 return evaluateInDifferentElementOrder(I->getOperand(0), Mask);
1385 Value *V = evaluateInDifferentElementOrder(I->getOperand(0), Mask);
1386 return InsertElementInst::Create(V, I->getOperand(1),
lib/Transforms/InstCombine/InstructionCombining.cpp 835 bool ConstIsRHS = isa<Constant>(I.getOperand(1));
836 Constant *ConstOperand = cast<Constant>(I.getOperand(ConstIsRHS));
1032 Constant *C = cast<Constant>(I.getOperand(1));
1210 for (;; Op = Parent.first->getOperand(Parent.second)) { // Drill down
1360 assert(Op != Parent.first->getOperand(Parent.second) &&
1780 NewPN->addIncoming(cast<GEPOperator>(I)->getOperand(DI),
1805 Value *SO1 = Src->getOperand(1);
1827 auto *SO0 = Src->getOperand(0);
1853 if (auto *SrcGEP = dyn_cast<GEPOperator>(Src->getOperand(0)))
1869 Value *SO1 = Src->getOperand(Src->getNumOperands()-1);
1888 GEP.setOperand(0, Src->getOperand(0));
1906 Src->getSourceElementType(), Src->getOperand(0), Indices,
1909 Src->getOperand(0), Indices,
1943 Value *NewSub = Builder.CreateSub(PtrToInt, Index->getOperand(1));
3176 ValueAsMetadata::get(I->getOperand(0))));
3225 (I->getNumOperands() == 0 || isa<Constant>(I->getOperand(0)))) {
3404 (Inst->getNumOperands() == 0 || isa<Constant>(Inst->getOperand(0))))
lib/Transforms/Instrumentation/AddressSanitizer.cpp 1451 return isPointerOperand(I->getOperand(0)) &&
1452 isPointerOperand(I->getOperand(1));
1465 return isPointerOperand(I->getOperand(0)) &&
1466 isPointerOperand(I->getOperand(1));
1483 Value *Param[2] = {I->getOperand(0), I->getOperand(1)};
1483 Value *Param[2] = {I->getOperand(0), I->getOperand(1)};
lib/Transforms/Instrumentation/ControlHeightReduction.cpp 1626 if (UI->getOperand(J) == &I) {
lib/Transforms/Instrumentation/DataFlowSanitizer.cpp 1169 Value *Shadow = getShadow(Inst->getOperand(0));
1171 Shadow = combineShadows(Shadow, getShadow(Inst->getOperand(i)), Inst);
lib/Transforms/Instrumentation/MemorySanitizer.cpp 1675 return getShadow(I->getOperand(i));
1696 return getOrigin(I->getOperand(i));
1827 Value *Addr = I.getOperand(0);
1839 insertShadowCheck(I.getOperand(1), &I);
2191 insertShadowCheck(I.getOperand(1), &I);
3724 Value *Operand = I.getOperand(i);
lib/Transforms/Instrumentation/PoisonChecking.cpp 110 Value *LHS = I.getOperand(0);
111 Value *RHS = I.getOperand(1);
196 Value *Vec = I.getOperand(0);
199 Value *Idx = I.getOperand(1);
208 Value *Vec = I.getOperand(0);
211 Value *Idx = I.getOperand(2);
lib/Transforms/ObjCARC/ObjCARC.h 78 const auto *Opnd = Inst.getOperand(0)->stripPointerCasts();
lib/Transforms/ObjCARC/ObjCARCOpts.cpp 766 Value *Opnd = Inst->getOperand(0);
lib/Transforms/Scalar/ConstantHoisting.cpp 174 Value *Opnd = Inst->getOperand(Idx);
381 LLVM_DEBUG(if (isa<ConstantInt>(Inst->getOperand(Idx))) dbgs()
386 << *Inst->getOperand(Idx) << " with cost " << Cost
436 Value *Opnd = Inst->getOperand(Idx);
451 if (auto *ConstInt = dyn_cast<ConstantInt>(CastInst->getOperand(0))) {
754 LLVM_DEBUG(dbgs() << "Materialize constant (" << *Base->getOperand(0)
760 Value *Opnd = ConstUser.Inst->getOperand(ConstUser.OpndIdx);
lib/Transforms/Scalar/DCE.cpp 95 Value *OpV = I->getOperand(i);
lib/Transforms/Scalar/DeadStoreElimination.cpp 126 Value *Op = DeadInst->getOperand(op);
lib/Transforms/Scalar/DivRemPairs.cpp 100 Value *getDividend() const { return DivInst->getOperand(0); }
101 Value *getDivisor() const { return DivInst->getOperand(1); }
130 DivMap[DivRemMapKey(true, I.getOperand(0), I.getOperand(1))] = &I;
130 DivMap[DivRemMapKey(true, I.getOperand(0), I.getOperand(1))] = &I;
132 DivMap[DivRemMapKey(false, I.getOperand(0), I.getOperand(1))] = &I;
132 DivMap[DivRemMapKey(false, I.getOperand(0), I.getOperand(1))] = &I;
134 RemMap[DivRemMapKey(true, I.getOperand(0), I.getOperand(1))] = &I;
134 RemMap[DivRemMapKey(true, I.getOperand(0), I.getOperand(1))] = &I;
136 RemMap[DivRemMapKey(false, I.getOperand(0), I.getOperand(1))] = &I;
136 RemMap[DivRemMapKey(false, I.getOperand(0), I.getOperand(1))] = &I;
lib/Transforms/Scalar/Float2Int.cpp 206 unsigned BW = I->getOperand(0)->getType()->getPrimitiveSizeInBits();
lib/Transforms/Scalar/GVN.cpp 1759 Value *Operand = Instr->getOperand(OpNum);
2204 Value *Op = Instr->getOperand(i);
lib/Transforms/Scalar/GVNHoist.cpp 856 if (Instruction *Op = dyn_cast<Instruction>(Gep->getOperand(i))) {
lib/Transforms/Scalar/GVNSink.cpp 269 Values.push_back(I->getOperand(OpNum));
842 return I->getOperand(O) != I0->getOperand(O);
842 return I->getOperand(O) != I0->getOperand(O);
845 NewOperands.push_back(I0->getOperand(O));
850 auto *Op = I0->getOperand(O);
855 PN->addIncoming(I->getOperand(O), I->getParent());
lib/Transforms/Scalar/IndVarSimplify.cpp 1121 Value *LHS = (NarrowUse->getOperand(0) == NarrowDef)
1123 : createExtendInst(NarrowUse->getOperand(0), WideType,
1125 Value *RHS = (NarrowUse->getOperand(1) == NarrowDef)
1127 : createExtendInst(NarrowUse->getOperand(1), WideType,
1147 unsigned IVOpIdx = (NarrowUse->getOperand(0) == NarrowDef) ? 0 : 1;
1170 const SCEV *NarrowRHS = SE->getSCEV(NarrowUse->getOperand(1));
1173 const SCEV *NarrowLHS = SE->getSCEV(NarrowUse->getOperand(0));
1212 Value *LHS = (NarrowUse->getOperand(0) == NarrowDef)
1214 : createExtendInst(NarrowUse->getOperand(0), WideType,
1216 Value *RHS = (NarrowUse->getOperand(1) == NarrowDef)
1218 : createExtendInst(NarrowUse->getOperand(1), WideType,
1265 DU.NarrowUse->getOperand(0) == DU.NarrowDef ? 1 : 0;
1266 assert(DU.NarrowUse->getOperand(1-ExtendOperIdx) == DU.NarrowDef && "bad DU");
1274 SE->getSCEV(DU.NarrowUse->getOperand(ExtendOperIdx)), WideType);
1277 SE->getSCEV(DU.NarrowUse->getOperand(ExtendOperIdx)), WideType);
1428 unsigned ExtendOperIdx = DU.NarrowUse->getOperand(0) == NarrowDef ? 1 : 0;
1429 assert(DU.NarrowUse->getOperand(1 - ExtendOperIdx) == DU.NarrowDef &&
1438 SE->getSCEV(NarrowUse->getOperand(ExtendOperIdx)), WideType);
1441 SE->getSCEV(NarrowUse->getOperand(ExtendOperIdx)), WideType);
1447 auto *I = dyn_cast<Instruction>(NarrowUse->getOperand(ExtendOperIdx));
1494 Value *LHS = (NarrowUse->getOperand(0) == NarrowDef)
1496 : createExtendInst(NarrowUse->getOperand(0), WideType,
1498 Value *RHS = (NarrowUse->getOperand(1) == NarrowDef)
1500 : createExtendInst(NarrowUse->getOperand(1), WideType,
2038 PHINode *Phi = dyn_cast<PHINode>(IncI->getOperand(0));
2040 if (L->isLoopInvariant(IncI->getOperand(1)))
2048 Phi = dyn_cast<PHINode>(IncI->getOperand(1));
2050 if (L->isLoopInvariant(IncI->getOperand(0)))
lib/Transforms/Scalar/InferAddressSpaces.cpp 254 return {Op.getOperand(0)};
256 return {Op.getOperand(1), Op.getOperand(2)};
256 return {Op.getOperand(1), Op.getOperand(2)};
329 if (ConstantExpr *CE = dyn_cast<ConstantExpr>(Op->getOperand(I))) {
449 Value *Src = I->getOperand(0);
493 return SelectInst::Create(I->getOperand(0), NewPointerOperands[1],
704 Value *Src0 = Op.getOperand(1);
705 Value *Src1 = Op.getOperand(2);
851 return isSafeToCastConstAddrSpace(cast<Constant>(Op->getOperand(0)), NewAS);
897 assert(isa<UndefValue>(NewV->getOperand(OperandNo)));
lib/Transforms/Scalar/JumpThreading.cpp 695 ComputeValueKnownInPredecessorsImpl(I->getOperand(0), BB, LHSVals,
697 ComputeValueKnownInPredecessorsImpl(I->getOperand(1), BB, RHSVals,
731 isa<ConstantInt>(I->getOperand(1)) &&
732 cast<ConstantInt>(I->getOperand(1))->isOne()) {
733 ComputeValueKnownInPredecessorsImpl(I->getOperand(0), BB, Result,
897 ComputeValueKnownInPredecessorsImpl(I->getOperand(0), BB, LHSVals,
2017 if (Instruction *Inst = dyn_cast<Instruction>(New->getOperand(i))) {
2330 if (Instruction *Inst = dyn_cast<Instruction>(New->getOperand(i))) {
2356 if (BasicBlock *SuccBB = dyn_cast<BasicBlock>(New->getOperand(i)))
lib/Transforms/Scalar/LICM.cpp 867 CurLoop->isLoopInvariant(I.getOperand(1)) &&
869 auto Divisor = I.getOperand(1);
877 BinaryOperator::CreateFMul(I.getOperand(0), ReciprocalDivisor);
1993 if (UI->getOperand(1) != ASIV)
lib/Transforms/Scalar/LoopIdiomRecognize.cpp 1315 if ((SubOneOp = dyn_cast<BinaryOperator>(DefX2->getOperand(0))))
1316 VarX1 = DefX2->getOperand(1);
1318 VarX1 = DefX2->getOperand(0);
1319 SubOneOp = dyn_cast<BinaryOperator>(DefX2->getOperand(1));
1348 ConstantInt *Inc = dyn_cast<ConstantInt>(Inst->getOperand(1));
1352 PHINode *Phi = getRecurrenceVar(Inst->getOperand(0), Inst, LoopEntry);
1443 ConstantInt *Shft = dyn_cast<ConstantInt>(DefX->getOperand(1));
1446 VarX = DefX->getOperand(0);
1473 ConstantInt *Inc = dyn_cast<ConstantInt>(Inst->getOperand(1));
1477 PHINode *Phi = getRecurrenceVar(Inst->getOperand(0), Inst, LoopEntry);
lib/Transforms/Scalar/LoopRerollPass.cpp 473 return I->hasOneUse() && TI->getOperand(0) == I;
1349 Value *Op2 = RootInst->getOperand(j);
1371 if (BaseInst->getOperand(Swapped ? unsigned(!j) : j) != Op2) {
1378 BaseInst->getOperand(!j) == Op2) {
lib/Transforms/Scalar/LoopStrengthReduce.cpp 2109 PHINode *PH = dyn_cast<PHINode>(ShadowUse->getOperand(0));
2316 if (ConstantInt *BO1 = dyn_cast<ConstantInt>(BO->getOperand(1)))
2317 if (BO1->isOne() && SE.getSCEV(BO->getOperand(0)) == MaxRHS)
2318 NewRHS = BO->getOperand(0);
2320 if (ConstantInt *BO1 = dyn_cast<ConstantInt>(BO->getOperand(1)))
2321 if (BO1->isOne() && SE.getSCEV(BO->getOperand(0)) == MaxRHS)
2322 NewRHS = BO->getOperand(0);
lib/Transforms/Scalar/LoopUnswitch.cpp 1422 if (Instruction *Use = dyn_cast<Instruction>(I->getOperand(i)))
1593 if (Instruction *Use = dyn_cast<Instruction>(I->getOperand(i)))
lib/Transforms/Scalar/LowerExpectIntrinsic.cpp 149 Result ^= cast<ConstantInt>(Op->getOperand(1))->getValue();
lib/Transforms/Scalar/MemCpyOptimizer.cpp 516 if (auto *A = dyn_cast<Instruction>(C->getOperand(k))) {
lib/Transforms/Scalar/NaryReassociate.cpp 351 Value *LHS = AO->getOperand(0), *RHS = AO->getOperand(1);
351 Value *LHS = AO->getOperand(0), *RHS = AO->getOperand(1);
lib/Transforms/Scalar/NewGVN.cpp 1148 assert(I->getOperand(0)->getType() == I->getOperand(1)->getType() &&
1148 assert(I->getOperand(0)->getType() == I->getOperand(1)->getType() &&
1150 assert((E->getOperand(0)->getType() == I->getOperand(0)->getType() &&
1151 E->getOperand(1)->getType() == I->getOperand(1)->getType()));
1159 assert(E->getOperand(1)->getType() == I->getOperand(1)->getType() &&
1160 E->getOperand(2)->getType() == I->getOperand(2)->getType());
1544 auto *CopyOf = I->getOperand(0);
lib/Transforms/Scalar/Reassociate.cpp 125 Value *V0 = I->getOperand(0);
126 Value *V1 = I->getOperand(1);
205 Rank = std::max(Rank, getRank(I->getOperand(i)));
224 Value *LHS = I->getOperand(0);
225 Value *RHS = I->getOperand(1);
277 BinaryOperator *Res = CreateMul(Neg->getOperand(OpNo), NegOne, "", Neg, Neg);
502 Value *Op = I->getOperand(OpIdx);
928 if (isa<UndefValue>(Sub->getOperand(1)))
933 Value *V0 = Sub->getOperand(0);
937 Value *V1 = Sub->getOperand(1);
959 Value *NegVal = NegateValue(Sub->getOperand(1), Sub, ToRedo);
960 BinaryOperator *New = CreateAdd(Sub->getOperand(0), NegVal, "", Sub, Sub);
977 MulCst = ConstantExpr::getShl(MulCst, cast<Constant>(Shl->getOperand(1)));
980 BinaryOperator::CreateMul(Shl->getOperand(0), MulCst, "", Shl);
1958 if (match(I->getOperand(0), m_Constant()))
1961 if (match(I->getOperand(1), m_APFloat(C)) && C->isNegative()) {
1965 getNegatibleInsts(I->getOperand(0), Candidates);
1966 getNegatibleInsts(I->getOperand(1), Candidates);
1970 if (match(I->getOperand(0), m_Constant()) &&
1971 match(I->getOperand(1), m_Constant()))
1974 if ((match(I->getOperand(0), m_APFloat(C)) && C->isNegative()) ||
1975 (match(I->getOperand(1), m_APFloat(C)) && C->isNegative())) {
1979 getNegatibleInsts(I->getOperand(0), Candidates);
1980 getNegatibleInsts(I->getOperand(1), Candidates);
2013 if (match(Negatible->getOperand(0), m_APFloat(C))) {
2014 assert(!match(Negatible->getOperand(1), m_Constant()) &&
2020 if (match(Negatible->getOperand(1), m_APFloat(C))) {
2021 assert(!match(Negatible->getOperand(0), m_Constant()) &&
2076 if (I->getOpcode() == Instruction::Shl && isa<ConstantInt>(I->getOperand(1)))
2079 if (isReassociableOp(I->getOperand(0), Instruction::Mul) ||
2123 if (isReassociableOp(I->getOperand(1), Instruction::Mul) &&
2148 Value *Op = isa<BinaryOperator>(I) ? I->getOperand(1) :
2149 I->getOperand(0);
2339 SmallVector<Value *, 8> Worklist = { I.getOperand(0), I.getOperand(1) };
2339 SmallVector<Value *, 8> Worklist = { I.getOperand(0), I.getOperand(1) };
2349 if (OpI->getOperand(0) != OpI)
2350 Worklist.push_back(OpI->getOperand(0));
2351 if (OpI->getOperand(1) != OpI)
2352 Worklist.push_back(OpI->getOperand(1));
lib/Transforms/Scalar/RewriteStatepointsForGC.cpp 2610 if (I.getOperand(i)->getType()->isVectorTy()) {
2612 VF == I.getOperand(i)->getType()->getVectorNumElements());
2613 VF = I.getOperand(i)->getType()->getVectorNumElements();
2618 if (!I.getOperand(0)->getType()->isVectorTy() && VF != 0) {
2620 auto *Splat = B.CreateVectorSplat(VF, I.getOperand(0));
lib/Transforms/Scalar/SCCP.cpp 977 LatticeVal V0State = getValueState(I.getOperand(0));
1000 LatticeVal V1State = getValueState(I.getOperand(0));
1001 LatticeVal V2State = getValueState(I.getOperand(1));
1211 Value *CopyOf = I->getOperand(0);
1495 if (I.getOperand(0)->getType()->isStructTy()) {
1499 LatticeVal Op0LV = getValueState(I.getOperand(0));
1502 if (I.getOperand(1)->getType()->isStructTy()) {
1507 Op1LV = getValueState(I.getOperand(1));
1621 Op1LV = getValueState(I.getOperand(1));
1625 Op1LV = getValueState(I.getOperand(2));
1628 Op1LV = getValueState(I.getOperand(2));
1648 Op0LV = getValueState(I.getOperand(0));
1649 Op1LV = getValueState(I.getOperand(1));
lib/Transforms/Scalar/SROA.cpp 1645 Ptr = cast<Operator>(Ptr)->getOperand(0);
lib/Transforms/Scalar/Scalarizer.cpp 362 Op->setOperand(I, UndefValue::get(Op->getOperand(I)->getType()));
448 Scatterer Op = scatter(&I, I.getOperand(0));
468 Scatterer Op0 = scatter(&I, I.getOperand(0));
469 Scatterer Op1 = scatter(&I, I.getOperand(1));
692 V = VI->getOperand(0);
lib/Transforms/Scalar/SeparateConstOffsetFromGEP.cpp 591 find(U->getOperand(0), SignExtended, ZeroExtended, NonNegative)
594 ConstantOffset = find(U->getOperand(0), /* SignExtended */ true,
602 find(U->getOperand(0), /* SignExtended */ false,
1264 isa<ConstantInt>(FirstOffsetDef->getOperand(1)))
1265 FirstOffsetDef = dyn_cast<Instruction>(FirstOffsetDef->getOperand(0));
lib/Transforms/Scalar/SpeculateAroundPHIs.cpp 685 isa<Constant>(NewI->getOperand(0)) &&
686 !isa<Constant>(NewI->getOperand(1)))
lib/Transforms/Scalar/StraightLineStrengthReduce.cpp 393 Value *LHS = I->getOperand(0), *RHS = I->getOperand(1);
393 Value *LHS = I->getOperand(0), *RHS = I->getOperand(1);
461 Value *LHS = I->getOperand(0), *RHS = I->getOperand(1);
461 Value *LHS = I->getOperand(0), *RHS = I->getOperand(1);
732 Value *Op = UnlinkedInst->getOperand(I);
lib/Transforms/Scalar/TailRecursionElimination.cpp 428 if ((I->getOperand(0) == CI && I->getOperand(1) == CI) ||
428 if ((I->getOperand(0) == CI && I->getOperand(1) == CI) ||
429 (I->getOperand(0) != CI && I->getOperand(1) != CI))
429 (I->getOperand(0) != CI && I->getOperand(1) != CI))
658 AccRecInstr->setOperand(AccRecInstr->getOperand(0) != CI, AccPN);
lib/Transforms/Utils/BypassSlowDivision.cpp 157 Value *Dividend = SlowDivOrRem->getOperand(0);
158 Value *Divisor = SlowDivOrRem->getOperand(1);
203 Value *Op1 = I->getOperand(1);
268 Value *Dividend = SlowDivOrRem->getOperand(0);
269 Value *Divisor = SlowDivOrRem->getOperand(1);
291 Value *Dividend = SlowDivOrRem->getOperand(0);
292 Value *Divisor = SlowDivOrRem->getOperand(1);
351 Value *Dividend = SlowDivOrRem->getOperand(0);
352 Value *Divisor = SlowDivOrRem->getOperand(1);
lib/Transforms/Utils/CloneFunction.cpp 870 if (Instruction *Inst = dyn_cast<Instruction>(New->getOperand(i))) {
lib/Transforms/Utils/FunctionComparator.cpp 531 cmpTypes(L->getOperand(i)->getType(), R->getOperand(i)->getType()))
531 cmpTypes(L->getOperand(i)->getType(), R->getOperand(i)->getType()))
686 if (int Res = cmpValues(GEPL->getOperand(i), GEPR->getOperand(i)))
686 if (int Res = cmpValues(GEPL->getOperand(i), GEPR->getOperand(i)))
775 Value *OpL = InstL->getOperand(i);
776 Value *OpR = InstR->getOperand(i);
lib/Transforms/Utils/LibCallsShrinkWrap.cpp 454 unsigned BW = I->getOperand(0)->getType()->getPrimitiveSizeInBits();
lib/Transforms/Utils/Local.cpp 554 Value *OpV = I->getOperand(i);
1222 if (DVI->getValue() == I->getOperand(0) &&
1633 DII->setOperand(0, wrapMD(I.getOperand(0)));
1687 auto *ConstInt = dyn_cast<ConstantInt>(I.getOperand(1));
2695 auto &A = collectBitParts(I->getOperand(0), MatchBSwaps,
2697 auto &B = collectBitParts(I->getOperand(1), MatchBSwaps,
2723 if (I->isLogicalShift() && isa<ConstantInt>(I->getOperand(1))) {
2725 cast<ConstantInt>(I->getOperand(1))->getLimitedValue(~0U);
2730 auto &Res = collectBitParts(I->getOperand(0), MatchBSwaps,
2752 isa<ConstantInt>(I->getOperand(1))) {
2754 const APInt &AndMask = cast<ConstantInt>(I->getOperand(1))->getValue();
2762 auto &Res = collectBitParts(I->getOperand(0), MatchBSwaps,
2777 auto &Res = collectBitParts(I->getOperand(0), MatchBSwaps,
2903 if (I->getOperand(OpIdx)->getType()->isMetadataTy())
2907 if (!isa<Constant>(I->getOperand(OpIdx)))
lib/Transforms/Utils/LoopRotationUtils.cpp 556 !isa<Constant>(I->getOperand(0))
557 ? I->getOperand(0)
558 : !isa<Constant>(I->getOperand(1)) ? I->getOperand(1) : nullptr;
558 : !isa<Constant>(I->getOperand(1)) ? I->getOperand(1) : nullptr;
lib/Transforms/Utils/LoopUnroll.cpp 69 Value *Op = I->getOperand(op);
lib/Transforms/Utils/ModuleUtils.cpp 37 CurrentCtors.push_back(cast<Constant>(Init->getOperand(i)));
lib/Transforms/Utils/PromoteMemoryToRegister.cpp 192 return (isa<LoadInst>(I) && isa<AllocaInst>(I->getOperand(0))) ||
193 (isa<StoreInst>(I) && isa<AllocaInst>(I->getOperand(1)));
lib/Transforms/Utils/SimplifyCFG.cpp 276 if (!(Cond->getOperand(0) == Ci2->getOperand(0) &&
277 Cond->getOperand(1) == Ci2->getOperand(1)) &&
278 !(Cond->getOperand(0) == Ci2->getOperand(1) &&
279 Cond->getOperand(1) == Ci2->getOperand(0)))
495 (C = GetConstantInt(I->getOperand(1), DL)))) {
600 Value *CandidateVal = I->getOperand(0);
601 if (match(I->getOperand(0), m_Add(m_Value(RHSVal), m_APInt(RHSC)))) {
651 if (Visited.insert(I->getOperand(1)).second)
652 DFT.push_back(I->getOperand(1));
653 if (Visited.insert(I->getOperand(0)).second)
654 DFT.push_back(I->getOperand(0));
1504 return isa<AllocaInst>(I->getOperand(1)->stripPointerCasts());
1508 return isa<AllocaInst>(I->getOperand(0)->stripPointerCasts());
1512 return isa<AllocaInst>(I->getOperand(1)->stripPointerCasts());
1517 if (I0->getOperand(OI)->getType()->isTokenTy())
1523 return I->getOperand(OI) == I0->getOperand(OI);
1523 return I->getOperand(OI) == I0->getOperand(OI);
1535 PHIOperands[I].push_back(I->getOperand(OI));
1584 return I->getOperand(O) != I0->getOperand(O);
1584 return I->getOperand(O) != I0->getOperand(O);
1587 NewOperands.push_back(I0->getOperand(O));
1592 auto *Op = I0->getOperand(O);
1597 PN->addIncoming(I->getOperand(O), I->getParent());
2655 if (ConstantExpr *CE = dyn_cast<ConstantExpr>(Cond->getOperand(0)))
2658 if (ConstantExpr *CE = dyn_cast<ConstantExpr>(Cond->getOperand(1)))
4659 if (Constant *A = LookupConstant(I->getOperand(N), ConstantPool))
lib/Transforms/Utils/SimplifyIndVar.cpp 120 if (IVOperand != UseInst->getOperand(OperIdx) ||
121 !isa<ConstantInt>(UseInst->getOperand(1)))
127 || !isa<ConstantInt>(IVOperand->getOperand(1)))
130 IVSrc = IVOperand->getOperand(0);
134 ConstantInt *D = cast<ConstantInt>(UseInst->getOperand(1));
lib/Transforms/Utils/SimplifyLibCalls.cpp 666 if (getConstantDataArrayInfo(GEP->getOperand(0), Slice, CharSize)) {
684 Value *Offset = GEP->getOperand(2);
701 (GEP->isInBounds() && isa<GlobalVariable>(GEP->getOperand(0)) &&
1413 Value *Op = cast<Instruction>(I2F)->getOperand(0);
1983 Value *Op0 = I->getOperand(0);
1984 Value *Op1 = I->getOperand(1);
lib/Transforms/Utils/UnifyFunctionExitNodes.cpp 107 PN->addIncoming(BB->getTerminator()->getOperand(0), BB);
lib/Transforms/Utils/ValueMapper.cpp 431 Value *Op = C->getOperand(OpNo);
454 Ops.push_back(cast<Constant>(C->getOperand(j)));
462 Mapped = mapValueOrNull(C->getOperand(OpNo));
lib/Transforms/Vectorize/LoadStoreVectorizer.cpp 442 Value *ValA = OpA->getOperand(0);
443 OpB = dyn_cast<Instruction>(OpB->getOperand(0));
452 isa<ConstantInt>(OpB->getOperand(1)) &&
453 IdxDiff.sle(cast<ConstantInt>(OpB->getOperand(1))->getSExtValue())) {
514 Instruction *IM = dyn_cast<Instruction>(IW->getOperand(i));
1208 unsigned Idx = cast<ConstantInt>(UI->getOperand(1))->getZExtValue();
lib/Transforms/Vectorize/LoopVectorize.cpp 2501 auto *NewOp = getOrCreateScalarValue(Instr->getOperand(op), Instance);
4057 Value *Divisor = I.getOperand(1);
4181 SE->isLoopInvariant(PSE.getSCEV(I.getOperand(0)), OrigLoop);
4189 auto *ScalarCond = getOrCreateScalarValue(I.getOperand(0), {0, 0});
4192 Value *Cond = getOrCreateVectorValue(I.getOperand(0), Part);
4193 Value *Op0 = getOrCreateVectorValue(I.getOperand(1), Part);
4194 Value *Op1 = getOrCreateVectorValue(I.getOperand(2), Part);
4487 if (!isLoopVaryingBitCastOrGEP(Dst->getOperand(0)))
4489 auto *Src = cast<Instruction>(Dst->getOperand(0));
4674 auto *Cmp = dyn_cast<Instruction>(Latch->getTerminator()->getOperand(0));
5724 return Legal->hasStride(I->getOperand(0)) ||
5725 Legal->hasStride(I->getOperand(1));
6205 Value *Op2 = I->getOperand(1);
6224 I->getOperand(0));
6238 Type *ValTy = I->getOperand(0)->getType();
6239 Instruction *Op0AsInstruction = dyn_cast<Instruction>(I->getOperand(0));
6279 Type *SrcScalarTy = I->getOperand(0)->getType();
6529 auto *Cmp = dyn_cast<Instruction>(Latch->getTerminator()->getOperand(0));
6803 return new VPWidenIntOrFpInductionRecipe(cast<PHINode>(I->getOperand(0)),
lib/Transforms/Vectorize/SLPVectorizer.cpp 388 Type *Ty0 = cast<Instruction>(VL[BaseIndex])->getOperand(0)->getType();
389 Type *Ty1 = cast<Instruction>(VL[Cnt])->getOperand(0)->getType();
426 auto *CI = dyn_cast<ConstantInt>(E->getOperand(1));
910 OpsVec[OpIdx][Lane] = {cast<Instruction>(VL[Lane])->getOperand(OpIdx),
1271 Operands[OpIdx][Lane] = I->getOperand(OpIdx);
2365 Op0.assign(VL.size(), VL0->getOperand(0));
2388 Op0.assign(VL.size(), VL0->getOperand(0));
2491 Type *SrcTy = VL0->getOperand(0)->getType();
2493 Type *Ty = cast<Instruction>(V)->getOperand(0)->getType();
2512 Operands.push_back(cast<Instruction>(V)->getOperand(i));
2523 Type *ComparedTy = VL0->getOperand(0)->getType();
2606 Operands.push_back(cast<Instruction>(j)->getOperand(i));
2626 Type *Ty0 = VL0->getOperand(0)->getType();
2628 Type *CurTy = cast<Instruction>(V)->getOperand(0)->getType();
2641 auto Op = cast<Instruction>(V)->getOperand(1);
2660 Operands.push_back(cast<Instruction>(V)->getOperand(i));
2683 Operands.push_back(cast<Instruction>(V)->getOperand(0));
2793 Operands.push_back(cast<Instruction>(V)->getOperand(i));
2841 Value *Vec = E0->getOperand(0);
2875 if (Inst->getOperand(0) != Vec)
3047 Type *SrcTy = VL0->getOperand(0)->getType();
3119 ConstantInt *CInt = dyn_cast<ConstantInt>(I->getOperand(OpIdx));
3257 Type *Src0SclTy = E->getMainOp()->getOperand(0)->getType();
3258 Type *Src1SclTy = E->getAltOp()->getOperand(0)->getType();
4412 auto *Op0 = dyn_cast<Instruction>(I->getOperand(0));
4413 auto *Op1 = dyn_cast<Instruction>(I->getOperand(1));
5005 Roots.push_back(I->getOperand(0));
5019 if (!collectValuesToDemote(I->getOperand(0), Expr, ToDemote, Roots) ||
5020 !collectValuesToDemote(I->getOperand(1), Expr, ToDemote, Roots))
5645 auto *Op0 = dyn_cast<Instruction>(I->getOperand(0));
5646 auto *Op1 = dyn_cast<Instruction>(I->getOperand(1));
5964 cast<Instruction>(I->getOperand(0))->isFast();
6315 Value *NextV = TreeN->getOperand(EdgeToVist);
lib/Transforms/Vectorize/VPlan.cpp 637 Inst->getOperand(0)->printAsOperand(RSO, false);
639 Inst->getOperand(I)->printAsOperand(RSO << ", ", false);
tools/clang/lib/CodeGen/CGBlocks.cpp 234 if (cast<llvm::Function>(copyHelper->getOperand(0))->hasInternalLinkage() ||
235 cast<llvm::Function>(disposeHelper->getOperand(0))
tools/clang/lib/CodeGen/CGDecl.cpp 874 llvm::Constant *Elt = cast<llvm::Constant>(Init->getOperand(i));
928 llvm::Constant *Elt = cast<llvm::Constant>(Init->getOperand(i));
1263 auto *OpValue = cast<llvm::Constant>(constant->getOperand(Op));
tools/clang/lib/CodeGen/CGVTables.cpp 205 I.getOperand(0) == ThisPtr.getPointer();
214 ThisStore->getOperand(0)->getType());
222 RValue RV = RValue::get(T->getOperand(0));
tools/clang/unittests/CodeGen/IRMatchers.h 195 return C.top<Value>() == Insn->getOperand(OpNo);
262 C.push(I->getOperand(N), N);
tools/lldb/source/Expression/IRInterpreter.cpp 598 Value *operand = ii->getOperand(oi);
722 Value *lhs = inst->getOperand(0);
723 Value *rhs = inst->getOperand(1);
1092 Value *lhs = inst->getOperand(0);
1093 Value *rhs = inst->getOperand(1);
tools/llvm-diff/DifferenceEngine.cpp 371 Value *LO = L->getOperand(I), *RO = R->getOperand(I);
371 Value *LO = L->getOperand(I), *RO = R->getOperand(I);
tools/polly/lib/Analysis/ScopBuilder.cpp 1480 Value *Descriptor = dyn_cast<Value>(BitcastOperator->getOperand(0));
tools/polly/lib/Support/SCEVAffinator.cpp 500 auto *Divisor = SDiv->getOperand(1);
506 auto *Dividend = SDiv->getOperand(0);
517 auto *Divisor = SRem->getOperand(1);
523 auto *Dividend = SRem->getOperand(0);
534 return visit(SE.getSCEVAtScope(I->getOperand(0), getScope()));
536 return visit(SE.getSCEVAtScope(I->getOperand(0), getScope()));
tools/polly/lib/Support/SCEVValidator.cpp 411 auto *Dividend = SE.getSCEV(SDiv->getOperand(0));
412 auto *Divisor = SE.getSCEV(SDiv->getOperand(1));
420 auto *Divisor = SRem->getOperand(1);
425 auto *Dividend = SRem->getOperand(0);
446 return visit(SE.getSCEVAtScope(I->getOperand(0), Scope));
448 return visit(SE.getSCEVAtScope(I->getOperand(0), Scope));
597 auto *Dividend = SE.getSCEV(Inst->getOperand(1));
601 auto *Divisor = SE.getSCEV(Inst->getOperand(0));
tools/polly/lib/Support/ScopHelper.cpp 315 const SCEV *LHSScev = SE.getSCEV(Inst->getOperand(0));
316 const SCEV *RHSScev = SE.getSCEV(Inst->getOperand(1));
tools/polly/lib/Transform/DeLICM.cpp 1043 auto *WrittenVal = TargetStoreMA->getAccessInstruction()->getOperand(0);
unittests/Analysis/ScalarEvolutionTest.cpp 205 EXPECT_TRUE(isa<ConstantInt>(Gep->getOperand(1)));
206 EXPECT_EQ(cast<ConstantInt>(Gep->getOperand(1))->getSExtValue(), -1);
unittests/IR/ConstantsTest.cpp 382 ASSERT_EQ(GEP->getOperand(0), Placeholder);
394 ASSERT_EQ(GEP->getOperand(0), Alias);
unittests/Linker/LinkModulesTest.cpp 115 Value *Elem = Init->getOperand(0);
122 Elem = Init->getOperand(1);
unittests/Transforms/Utils/CloningTest.cpp 242 EXPECT_EQ(AddSplit->getOperand(0), V);
243 EXPECT_EQ(AddSplit->getOperand(1), V);
248 EXPECT_EQ(MulSplit->getOperand(0), AddSplit);
249 EXPECT_EQ(MulSplit->getOperand(1), V);
292 EXPECT_EQ(AddSplit->getOperand(0), V);
293 EXPECT_EQ(AddSplit->getOperand(1), V);
298 EXPECT_EQ(MulSplit->getOperand(0), AddSplit);
299 EXPECT_EQ(MulSplit->getOperand(1), V);
344 EXPECT_EQ(AddSplit->getOperand(0), V);
345 EXPECT_EQ(AddSplit->getOperand(1), V);
350 EXPECT_EQ(MulSplit->getOperand(0), AddSplit);
351 EXPECT_EQ(MulSplit->getOperand(1), V);
unittests/Transforms/Utils/IntegerDivisionTest.cpp 48 Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
78 Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
108 Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
138 Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
169 Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
199 Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
229 Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
259 Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
unittests/Transforms/Utils/SSAUpdaterBulkTest.cpp 91 PHINode *UpdatePhiA = dyn_cast_or_null<PHINode>(I1->getOperand(0));
95 EXPECT_EQ(UpdatePhiA, dyn_cast_or_null<PHINode>(I1->getOperand(0)));
98 PHINode *UpdatePhiB = dyn_cast_or_null<PHINode>(I3->getOperand(0));
101 EXPECT_EQ(UpdatePhiB, dyn_cast_or_null<PHINode>(I3->getOperand(1)));
104 EXPECT_EQ(I4->getOperand(0), SubOp1);
105 EXPECT_EQ(I4->getOperand(1), SubOp2);
186 EXPECT_EQ(I1->getOperand(0), AddOp1);
190 PHINode *UpdatePhi = dyn_cast_or_null<PHINode>(I2->getOperand(0));