Lines Matching defs:AddrInst
3825 bool matchOperationAddr(User *AddrInst, unsigned Opcode, unsigned Depth,
5091 /// not AddrInst has to be folded into the addressing mode on success.
5092 /// If \p MovedAway == true, \p AddrInst will not be part of the addressing
5094 /// Thus AddrInst must not be added in the matched instructions.
5095 /// This state can happen when AddrInst is a sext, since it may be moved away.
5096 /// Therefore, AddrInst may not be valid when MovedAway is true and it must
5098 bool AddressingModeMatcher::matchOperationAddr(User *AddrInst, unsigned Opcode,
5112 return matchAddr(AddrInst->getOperand(0), Depth);
5114 auto AS = AddrInst->getType()->getPointerAddressSpace();
5117 if (TLI.getValueType(DL, AddrInst->getOperand(0)->getType()) == PtrTy)
5118 return matchAddr(AddrInst->getOperand(0), Depth);
5124 if (AddrInst->getOperand(0)->getType()->isIntOrPtrTy() &&
5128 AddrInst->getOperand(0)->getType() != AddrInst->getType())
5129 return matchAddr(AddrInst->getOperand(0), Depth);
5133 AddrInst->getOperand(0)->getType()->getPointerAddressSpace();
5134 unsigned DestAS = AddrInst->getType()->getPointerAddressSpace();
5136 return matchAddr(AddrInst->getOperand(0), Depth);
5154 if (isa<ConstantInt>(AddrInst->getOperand(First))
5155 && !isa<ConstantInt>(AddrInst->getOperand(Second)))
5158 if (matchAddr(AddrInst->getOperand(First), Depth + 1) &&
5159 matchAddr(AddrInst->getOperand(Second), Depth + 1))
5169 if (matchAddr(AddrInst->getOperand(Second), Depth + 1) &&
5170 matchAddr(AddrInst->getOperand(First), Depth + 1))
5186 ConstantInt *RHS = dyn_cast<ConstantInt>(AddrInst->getOperand(1));
5193 return matchScaledValue(AddrInst->getOperand(0), Scale, Depth);
5202 gep_type_iterator GTI = gep_type_begin(AddrInst);
5203 for (unsigned i = 1, e = AddrInst->getNumOperands(); i != e; ++i, ++GTI) {
5207 cast<ConstantInt>(AddrInst->getOperand(i))->getZExtValue();
5217 dyn_cast<ConstantInt>(AddrInst->getOperand(i))) {
5239 if (matchAddr(AddrInst->getOperand(0), Depth + 1)) {
5240 if (!cast<GEPOperator>(AddrInst)->isInBounds())
5246 if (EnableGEPOffsetSplit && isa<GetElementPtrInst>(AddrInst) &&
5253 Value *Base = AddrInst->getOperand(0);
5255 auto *GEP = cast<GetElementPtrInst>(AddrInst);
5277 if (!cast<GEPOperator>(AddrInst)->isInBounds())
5281 if (!matchAddr(AddrInst->getOperand(0), Depth + 1)) {
5289 AddrMode.BaseReg = AddrInst->getOperand(0);
5293 if (!matchScaledValue(AddrInst->getOperand(VariableOperand), VariableScale,
5302 AddrMode.BaseReg = AddrInst->getOperand(0);
5304 if (!matchScaledValue(AddrInst->getOperand(VariableOperand),
5317 Instruction *Ext = dyn_cast<Instruction>(AddrInst);
5371 if (IntrinsicInst *II = dyn_cast<IntrinsicInst>(AddrInst)) {
5375 return matchAddr(AddrInst->getOperand(0), Depth);