Home
last modified time | relevance | path

Searched refs:IdxList (Results 1 – 20 of 20) sorted by relevance

/llvm-project-15.0.7/llvm/include/llvm/IR/
H A DConstantFolder.h106 Value *FoldGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
110 if (any_of(IdxList, [](Value *V) { return !isa<Constant>(V); }))
114 return ConstantExpr::getInBoundsGetElementPtr(Ty, PC, IdxList);
116 return ConstantExpr::getGetElementPtr(Ty, PC, IdxList);
131 ArrayRef<unsigned> IdxList) const override { in FoldExtractValue() argument
133 return ConstantFoldExtractValueInstruction(CAgg, IdxList); in FoldExtractValue()
138 ArrayRef<unsigned> IdxList) const override { in FoldInsertValue() argument
142 return ConstantFoldInsertValueInstruction(CAgg, CVal, IdxList); in FoldInsertValue()
H A DIRBuilderFolder.h54 virtual Value *FoldGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
60 ArrayRef<unsigned> IdxList) const = 0;
63 ArrayRef<unsigned> IdxList) const = 0;
H A DNoFolder.h77 Value *FoldGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
87 ArrayRef<unsigned> IdxList) const override { in FoldExtractValue() argument
92 ArrayRef<unsigned> IdxList) const override { in FoldInsertValue() argument
H A DConstants.h1227 ArrayRef<Constant *> IdxList,
1232 Ty, C, makeArrayRef((Value *const *)IdxList.data(), IdxList.size()),
1246 ArrayRef<Value *> IdxList,
1254 ArrayRef<Constant *> IdxList) {
1255 return getGetElementPtr(Ty, C, IdxList, true);
1265 ArrayRef<Value *> IdxList) {
1266 return getGetElementPtr(Ty, C, IdxList, true);
H A DInstructions.h956 ArrayRef<Value *> IdxList,
959 unsigned Values = 1 + unsigned(IdxList.size());
968 ArrayRef<Value *> IdxList,
971 unsigned Values = 1 + unsigned(IdxList.size());
996 Create(PointeeType, Ptr, IdxList, NameStr, InsertAtEnd);
1076 ArrayRef<Value *> IdxList) {
1088 for (Value *Index : IdxList)
1156 ResultElementType(getIndexedType(PointeeType, IdxList)) {
1159 init(Ptr, IdxList, NameStr);
1170 ResultElementType(getIndexedType(PointeeType, IdxList)) {
[all …]
H A DIRBuilder.h1725 Value *CreateGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
1727 if (auto *V = Folder.FoldGEP(Ty, Ptr, IdxList, IsInBounds))
1730 ? GetElementPtrInst::CreateInBounds(Ty, Ptr, IdxList)
1731 : GetElementPtrInst::Create(Ty, Ptr, IdxList),
1735 Value *CreateInBoundsGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
1737 return CreateGEP(Ty, Ptr, IdxList, Name, /* IsInBounds */ true);
/llvm-project-15.0.7/llvm/include/llvm/Analysis/
H A DTargetFolder.h117 Value *FoldGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
121 if (any_of(IdxList, [](Value *V) { return !isa<Constant>(V); }))
124 return Fold(ConstantExpr::getInBoundsGetElementPtr(Ty, PC, IdxList));
126 return Fold(ConstantExpr::getGetElementPtr(Ty, PC, IdxList));
142 ArrayRef<unsigned> IdxList) const override { in FoldExtractValue() argument
144 return ConstantFoldExtractValueInstruction(CAgg, IdxList); in FoldExtractValue()
149 ArrayRef<unsigned> IdxList) const override { in FoldInsertValue() argument
153 return ConstantFoldInsertValueInstruction(CAgg, CVal, IdxList); in FoldInsertValue()
H A DInstSimplifyFolder.h79 Value *FoldGEP(Type *Ty, Value *Ptr, ArrayRef<Value *> IdxList,
81 return simplifyGEPInst(Ty, Ptr, IdxList, IsInBounds, SQ);
89 ArrayRef<unsigned> IdxList) const override { in FoldExtractValue() argument
90 return simplifyExtractValueInst(Agg, IdxList, SQ); in FoldExtractValue()
94 ArrayRef<unsigned> IdxList) const override { in FoldInsertValue() argument
95 return simplifyInsertValueInst(Agg, Val, IdxList, SQ); in FoldInsertValue()
/llvm-project-15.0.7/clang/test/Parser/
H A DDelayedTemplateParsing.cpp95 ArrayRef<> IdxList; in CreateConstInBoundsGEP2_32() local
/llvm-project-15.0.7/llvm/lib/IR/
H A DConstantsContext.h219 ArrayRef<Constant *> IdxList, Type *DestTy);
223 ArrayRef<Constant *> IdxList, in Create() argument
225 GetElementPtrConstantExpr *Result = new (IdxList.size() + 1) in Create()
226 GetElementPtrConstantExpr(SrcElementTy, C, IdxList, DestTy); in Create()
H A DCore.cpp1657 ArrayRef<Constant *> IdxList(unwrap<Constant>(ConstantIndices, NumIndices), in LLVMConstGEP() local
1661 return wrap(ConstantExpr::getGetElementPtr(Ty, Val, IdxList)); in LLVMConstGEP()
1666 ArrayRef<Constant *> IdxList(unwrap<Constant>(ConstantIndices, NumIndices), in LLVMConstGEP2() local
1669 return wrap(ConstantExpr::getGetElementPtr(unwrap(Ty), Val, IdxList)); in LLVMConstGEP2()
1679 return wrap(ConstantExpr::getInBoundsGetElementPtr(Ty, Val, IdxList)); in LLVMConstInBoundsGEP()
3649 ArrayRef<Value *> IdxList(unwrap(Indices), NumIndices); in LLVMBuildGEP() local
3652 return wrap(unwrap(B)->CreateGEP(Ty, Val, IdxList, Name)); in LLVMBuildGEP()
3658 ArrayRef<Value *> IdxList(unwrap(Indices), NumIndices); in LLVMBuildGEP2() local
3665 ArrayRef<Value *> IdxList(unwrap(Indices), NumIndices); in LLVMBuildInBoundsGEP() local
3668 return wrap(unwrap(B)->CreateInBoundsGEP(Ty, Val, IdxList, Name)); in LLVMBuildInBoundsGEP()
[all …]
H A DInstructions.cpp1733 void GetElementPtrInst::init(Value *Ptr, ArrayRef<Value *> IdxList, in init() argument
1735 assert(getNumOperands() == 1 + IdxList.size() && in init()
1738 llvm::copy(IdxList, op_begin() + 1); in init()
1782 static Type *getIndexedTypeInternal(Type *Ty, ArrayRef<IndexTy> IdxList) { in getIndexedTypeInternal() argument
1783 if (IdxList.empty()) in getIndexedTypeInternal()
1785 for (IndexTy V : IdxList.slice(1)) { in getIndexedTypeInternal()
1793 Type *GetElementPtrInst::getIndexedType(Type *Ty, ArrayRef<Value *> IdxList) { in getIndexedType() argument
1794 return getIndexedTypeInternal(Ty, IdxList); in getIndexedType()
1798 ArrayRef<Constant *> IdxList) { in getIndexedType() argument
1799 return getIndexedTypeInternal(Ty, IdxList); in getIndexedType()
[all …]
H A DIRBuilder.cpp1199 SmallVector<Value *, 4> IdxList(Dimension, Zero); in CreatePreserveArrayAccessIndex() local
1200 IdxList.push_back(LastIndexV); in CreatePreserveArrayAccessIndex()
1203 GetElementPtrInst::getGEPReturnType(ElTy, Base, IdxList); in CreatePreserveArrayAccessIndex()
H A DConstantFold.cpp121 SmallVector<Value*, 8> IdxList; in FoldBitCast() local
124 IdxList.push_back(Zero); in FoldBitCast()
128 IdxList.push_back(Zero); in FoldBitCast()
134 PTy->getNonOpaquePointerElementType(), V, IdxList); in FoldBitCast()
H A DConstants.cpp2818 Type *SrcElementTy, Constant *C, ArrayRef<Constant *> IdxList, Type *DestTy) in GetElementPtrConstantExpr() argument
2821 (IdxList.size() + 1), in GetElementPtrConstantExpr()
2822 IdxList.size() + 1), in GetElementPtrConstantExpr()
2824 ResElementTy(GetElementPtrInst::getIndexedType(SrcElementTy, IdxList)) { in GetElementPtrConstantExpr()
2827 for (unsigned i = 0, E = IdxList.size(); i != E; ++i) in GetElementPtrConstantExpr()
2828 OperandList[i+1] = IdxList[i]; in GetElementPtrConstantExpr()
/llvm-project-15.0.7/llvm/lib/Target/BPF/
H A DBPFAbstractMemberAccess.cpp448 SmallVector<Value *, 4> IdxList; in replaceWithGEP() local
450 IdxList.push_back(Zero); in replaceWithGEP()
451 IdxList.push_back(Call->getArgOperand(GEPIndex)); in replaceWithGEP()
454 getBaseElementType(Call), Call->getArgOperand(0), IdxList, "", Call); in replaceWithGEP()
/llvm-project-15.0.7/llvm/lib/Target/Hexagon/
H A DHexagonCommonGEP.cpp1092 SmallVector<Value*, 4> IdxList; in fabricateGEP() local
1098 IdxList.push_back(ConstantInt::get(Int32Ty, 0)); in fabricateGEP()
1105 IdxList.push_back(N->Idx); in fabricateGEP()
1112 NewInst = GetElementPtrInst::Create(InpTy, Input, IdxList, "cgep", &*At); in fabricateGEP()
/llvm-project-15.0.7/llvm/utils/TableGen/
H A DRegisterInfoEmitter.cpp1337 typedef std::vector<const CodeGenSubRegIndex*> IdxList; in runTargetDesc() typedef
1338 SmallVector<IdxList, 8> SuperRegIdxLists(RegisterClasses.size()); in runTargetDesc()
1339 SequenceToOffsetTable<IdxList, deref<std::less<>>> SuperRegIdxSeqs; in runTargetDesc()
1349 IdxList &SRIList = SuperRegIdxLists[RC.EnumValue]; in runTargetDesc()
/llvm-project-15.0.7/clang/lib/CodeGen/
H A DCGExprScalar.cpp5084 ArrayRef<Value *> IdxList, in EmitCheckedInBoundsGEP() argument
5088 Value *GEPVal = Builder.CreateInBoundsGEP(ElemTy, Ptr, IdxList, Name); in EmitCheckedInBoundsGEP()
H A DCodeGenFunction.h4579 ArrayRef<llvm::Value *> IdxList,