Home
last modified time | relevance | path

Searched refs:StructType (Results 1 – 25 of 277) sorted by relevance

12345678910>>...12

/llvm-project/llvm/unittests/Target/DirectX/
H A DCBufferDataLayoutTests.cpp80 StructType *BasicMix0 = StructType::get(T16, T32, T64); in checkLegacyLayout()
81 StructType *BasicMix1 = StructType::get(T16, T64, T32); in checkLegacyLayout()
82 StructType *BasicMix2 = StructType::get(T32, T64, T16); in checkLegacyLayout()
83 StructType *BasicMix3 = StructType::get(T32, T16, T64); in checkLegacyLayout()
84 StructType *BasicMix4 = StructType::get(T64, T16, T32); in checkLegacyLayout()
85 StructType *BasicMix5 = StructType::get(T64, T32, T16); in checkLegacyLayout()
94 StructType *VecMix0 = StructType::get(T16V3, T16, T32, T64V2); in checkLegacyLayout()
95 StructType *VecMix1 = StructType::get(T16V3, T32, T64V2, T16); in checkLegacyLayout()
96 StructType *VecMix2 = StructType::get(T16V3, T64, T32V2, T16); in checkLegacyLayout()
97 StructType *VecMix3 = StructType::get(T32V3, T64, T16V2, T32); in checkLegacyLayout()
[all …]
/llvm-project/mlir/test/python/dialects/
H A Dllvm.py21 print(llvm.StructType.get_literal([]))
25 print(llvm.StructType.get_literal([i8, i32, i64]))
26 print(llvm.StructType.get_literal([i32]))
27 print(llvm.StructType.get_literal([i32, i32], packed=True))
28 literal = llvm.StructType.get_literal([i8, i32, i64])
37 assert llvm.StructType.get_literal([i32]) == llvm.StructType.get_literal([i32])
38 assert llvm.StructType.get_literal([i32]) != llvm.StructType.get_literal([i64])
40 print(llvm.StructType.get_identified("foo"))
41 print(llvm.StructType.get_identified("bar"))
45 assert llvm.StructType.get_identified("foo") == llvm.StructType.get_identified(
[all …]
/llvm-project/llvm/include/llvm/Linker/
H A DIRMover.h22 class StructType; variable
32 KeyTy(const StructType *ST);
36 static StructType *getEmptyKey();
37 static StructType *getTombstoneKey();
39 static unsigned getHashValue(const StructType *ST);
40 static bool isEqual(const KeyTy &LHS, const StructType *RHS);
41 static bool isEqual(const StructType *LHS, const StructType *RHS);
50 DenseSet<StructType *> OpaqueStructTypes;
53 DenseSet<StructType *, StructTypeKeyInfo> NonOpaqueStructTypes;
56 void addNonOpaque(StructType *Ty);
[all …]
/llvm-project/llvm/lib/IR/
H A DType.cpp65 if (const auto *STy = dyn_cast<StructType>(this)) in isScalableTy()
79 if (const auto *STy = dyn_cast<StructType>(this)) in getFltSemantics()
95 if (const auto *STy = dyn_cast<StructType>(this)) in getFloatingPointTy()
191 if (auto *STy = dyn_cast<StructType>(this)) { in getPrimitiveSizeInBits()
264 return cast<StructType>(this)->isSized(Visited); in getWasm_ExternrefTy()
401 // StructType Implementation in containsScalableVectorType()
406 StructType *StructType::get(LLVMContext &Context, ArrayRef<Type*> ETypes, in containsScalableVectorType()
411 StructType *ST; in containsScalableVectorType()
421 ST = new (Context.pImpl->Alloc) StructType(Contex in containsScalableVectorType()
[all...]
/llvm-project/mlir/lib/Dialect/SPIRV/IR/
H A DSPIRVTypes.cpp99 spirv::StructType>(type); in classof()
113 .Case<StructType>( in getElementType()
114 [index](StructType type) { return type.getElementType(index); }) in getElementType()
124 if (auto structType = llvm::dyn_cast<StructType>(*this)) in getNumElements()
148 StructType>(
162 StructType>(
180 if (auto structType = llvm::dyn_cast<StructType>(*this)) in getCapabilities()
766 // StructType in getCapabilities()
785 /// associated with such storage must call StructType::trySetBody(...) later in getSizeInBytes()
796 StructType
[all...]
H A DSPIRVDialect.cpp583 SmallVectorImpl<StructType::OffsetInfo> &offsetInfo, in parseImageType()
584 SmallVectorImpl<StructType::MemberDecorationInfo> &memberDecorationInfo) { in parseImageType()
588 StructType::OffsetInfo offset = 0; in parseImageType()
661 StructType::getIdentified(dialect.getContext(), identifier); in parseStructMemberDecorations()
690 return StructType::getEmpty(dialect.getContext(), identifier); in parseStructType()
693 StructType idStructTy; in parseStructType()
696 idStructTy = StructType::getIdentified(dialect.getContext(), identifier); in parseStructType()
699 SmallVector<StructType::OffsetInfo, 4> offsetInfo; in parseStructType()
700 SmallVector<StructType::MemberDecorationInfo, 4> memberDecorationInfo; in parseStructType()
730 return StructType in parseStructType()
[all...]
/llvm-project/llvm/unittests/IR/
H A DTypesTest.cpp17 TEST(TypesTest, StructType) { in TEST() argument
21 StructType *Struct = StructType::create(C, "FooBar"); in TEST()
33 StructType *Foo = StructType::create(C, "Foo"); in TEST()
34 StructType *Bar = StructType::create(C, "Bar"); in TEST()
55 StructType *Struct = llvm::StructType::create(Context, Elements, "MyStruct", in TEST()
68 Struct = StructType
[all...]
/llvm-project/llvm/lib/Linker/
H A DIRMover.cpp57 SmallVector<StructType *, 16> SpeculativeDstOpaqueTypes;
61 SmallVector<StructType *, 16> SrcDefinitionsToResolve;
65 SmallPtrSet<StructType *, 16> DstResolvedOpaqueTypes;
83 Type *get(Type *SrcTy, SmallPtrSet<StructType *, 8> &Visited); in get()
110 for (StructType *Ty : SpeculativeDstOpaqueTypes) in addTypeMapping()
120 if (auto *STy = dyn_cast<StructType>(Ty)) in addTypeMapping()
150 if (StructType *SSTy = dyn_cast<StructType>(SrcTy)) { in areTypesIsomorphic()
162 if (cast<StructType>(DstTy)->isOpaque()) { in areTypesIsomorphic()
164 if (!DstResolvedOpaqueTypes.insert(cast<StructType>(DstT in areTypesIsomorphic()
247 get(Type * Ty,SmallPtrSet<StructType *,8> & Visited) get() argument
[all...]
/llvm-project/mlir/lib/Dialect/SPIRV/Utils/
H A DLayoutUtils.cpp20 spirv::StructType
21 VulkanLayoutUtils::decorateType(spirv::StructType structType) { in decorateType()
27 spirv::StructType
28 VulkanLayoutUtils::decorateType(spirv::StructType structType, in decorateType()
36 SmallVector<spirv::StructType::OffsetInfo, 4> offsetInfo; in decorateType()
37 SmallVector<spirv::StructType::MemberDecorationInfo, 4> memberDecorations; in decorateType()
51 static_cast<spirv::StructType::OffsetInfo>(structMemberOffset)); in decorateType()
73 return spirv::StructType::get(memberTypes, offsetInfo, memberDecorations); in decorateType()
88 if (auto structType = dyn_cast<spirv::StructType>(type)) in decorateType()
170 auto structType = dyn_cast<spirv::StructType>(ptrType.getPointeeType()); in isLegalType()
/llvm-project/llvm/include/llvm/IR/
H A DDerivedTypes.h203 /// the StructType::get() forms.
210 /// StructType::create() forms.
218 class StructType : public Type {
219 StructType(LLVMContext &C) : Type(C, StructTyID) {}
242 StructType(const StructType &) = delete;
243 StructType &operator=(const StructType &) = delete;
246 static StructType *create(LLVMContext &Context, StringRef Name);
247 static StructType *creat
217 StructType(LLVMContext &C) : Type(C, StructTyID) {} StructType() function
[all...]
H A DGetElementPtrTypeIterator.h66 PointerUnion<StructType *, VectorType *, Type *> CurTy;
107 return cast<StructType *>(CurTy)->getTypeAtIndex(getOperand()); in getIndexedType()
119 CurTy = dyn_cast<StructType>(Ty);
145 bool isStruct() const { return isa<StructType *>(CurTy); } in isStruct()
164 StructType *getStructType() const { return cast<StructType *>(CurTy); } in getStructType()
166 StructType *getStructTypeOrNull() const { in getStructTypeOrNull()
167 return dyn_cast_if_present<StructType *>(CurTy); in getStructTypeOrNull()
H A DTypeFinder.h25 class StructType; variable
39 std::vector<StructType*> StructTypes;
48 using iterator = std::vector<StructType*>::iterator;
49 using const_iterator = std::vector<StructType*>::const_iterator;
61 StructType *&operator[](unsigned Idx) { return StructTypes[Idx]; }
/llvm-project/clang/lib/CodeGen/
H A DCGRecordLayout.h19 class StructType; variable
131 llvm::StructType *CompleteObjectType;
135 llvm::StructType *BaseSubobjectType;
163 CGRecordLayout(llvm::StructType *CompleteObjectType, in CGRecordLayout()
164 llvm::StructType *BaseSubobjectType, in CGRecordLayout()
174 llvm::StructType *getLLVMType() const { in getLLVMType()
180 llvm::StructType *getBaseSubobjectLLVMType() const { in getBaseSubobjectLLVMType()
200 /// Return llvm::StructType element number that corresponds to the in getLLVMFieldNo()
H A DCodeGenTypes.h27 class StructType; variable
71 llvm::DenseMap<const Type*, llvm::StructType *> RecordDeclTypes;
283 llvm::StructType *Ty);
287 void addRecordTypeName(const RecordDecl *RD, llvm::StructType *Ty,
293 llvm::StructType *ConvertRecordDeclType(const RecordDecl *TD);
/llvm-project/mlir/include/mlir/Dialect/SPIRV/Utils/
H A DLayoutUtils.h26 class StructType; variable
54 static spirv::StructType decorateType(spirv::StructType structType);
71 static spirv::StructType decorateType(spirv::StructType structType,
/llvm-project/llvm/lib/Target/DirectX/
H A DDXILOpBuilder.cpp121 StructType *ST = cast<StructType>(Ty); in getTypeName()
133 StructType *ST = cast<StructType>(Ty);
136 StructType *ST = cast<StructType>(Ty);
185 static StructType *getOrCreateStructType(StringRef Name, in getHandleType()
188 StructType *ST = StructType::getTypeByName(Ctx, Name); in getHandleType()
192 return StructType in getTypeFromParameterKind()
[all...]
H A DCBufferDataLayout.cpp25 StructType *ST;
43 LegacyStructLayout &getStructLayout(StructType *ST);
45 SmallDenseMap<StructType *, LegacyStructLayout> StructLayouts;
63 if (isa<StructType>(EltTy) || isa<ArrayType>(EltTy)) in applyRowAlign()
73 if (auto *ST = dyn_cast<StructType>(Ty)) { in getTypeAllocSize()
93 LegacyCBufferLayout::getStructLayout(StructType *ST) { in getStructLayout()
/llvm-project/polly/lib/CodeGen/
H A DLoopGeneratorsKMP.cpp27 Type *KMPCMicroTy = StructType::getTypeByName(M->getContext(), "kmpc_micro"); in createCallSpawnThreads()
487 StructType *IdentTy = in createCallDispatchNext()
488 StructType::getTypeByName(M->getContext(), StructName); in createCallDispatchNext()
490 // If the ident_t StructType is not available, declare it. in createCallDispatchNext()
498 StructType::create(M->getContext(), LocMembers, StructName, false);
/llvm-project/mlir/docs/Tutorials/Toy/
H A DCh-7.md87 /// This class represents the internal storage of the Toy `StructType`.
114 /// itself, see the `StructType::get` method further below.
143 `StructType` class. This is the class that we will actually interface with.
149 /// (StructType), the base class to use (Type), and the storage class
151 class StructType : public mlir::Type::TypeBase<StructType, mlir::Type,
157 /// Create an instance of a `StructType` with the given element types. There
159 static StructType get(llvm::ArrayRef<mlir::Type> elementTypes) {
185 addTypes<StructType>();
192 With this we can now use our `StructType` when generating MLIR from Toy. See
202 // Provide a definition for the Toy StructType for use in ODS. This allows for
[all …]
/llvm-project/mlir/examples/toy/Ch7/mlir/
H A DDialect.cpp234 auto resultType = llvm::cast<StructType>(type); in verifyConstantForType()
240 return op->emitError("constant of StructType must be initialized by an " in verifyConstantForType()
448 StructType structTy = llvm::cast<StructType>(input.getType()); in build()
457 StructType structTy = llvm::cast<StructType>(getInput().getType()); in verify()
507 /// This class represents the internal storage of the Toy `StructType`.
525 /// instances of the storage, see the `StructType::get` method.
562 /// Create an instance of a `StructType` with the given element types. There
564 StructType StructTyp
[all...]
/llvm-project/mlir/examples/toy/Ch7/include/toy/
H A DDialect.h60 class StructType : public mlir::Type::TypeBase<StructType, mlir::Type,
68 static StructType get(llvm::ArrayRef<mlir::Type> elementTypes);
/llvm-project/llvm/unittests/AsmParser/
H A DAsmParserTest.cpp228 StructType *ST = cast<StructType>(Ty); in TEST()
242 ST = cast<StructType>(Ty); in TEST()
268 ST = cast<StructType>(Ty); in TEST()
338 StructType *ST = cast<StructType>(Ty); in TEST()
353 ST = cast<StructType>(Ty); in TEST()
381 ST = cast<StructType>(Ty); in TEST()
/llvm-project/llvm/lib/Target/
H A DTarget.cpp130 StructType *STy = unwrap<StructType>(StructTy); in LLVMElementAtOffset()
136 StructType *STy = unwrap<StructType>(StructTy); in LLVMOffsetOfElement()
/llvm-project/mlir/include/mlir/Dialect/SPIRV/IR/
H A DSPIRVTypes.h99 // SPIR-V composite type: VectorType, SPIR-V ArrayType, or SPIR-V StructType.
291 class StructType
292 : public Type::TypeBase<StructType, CompositeType,
328 /// Construct a literal StructType with at least one member.
329 static StructType get(ArrayRef<Type> memberTypes,
333 /// Construct an identified StructType. This creates a StructType whose body
335 /// StructType::trySetBody(...) must follow when the StructType contents are
340 static StructType getIdentifie
[all...]
/llvm-project/llvm/lib/Frontend/Offloading/
H A DUtility.cpp24 StructType *offloading::getEntryTy(Module &M) { in getEntryTy()
26 StructType *EntryTy = in getEntryTy()
27 StructType::getTypeByName(C, "struct.__tgt_offload_entry"); in getEntryTy()
29 EntryTy = StructType::create( in getEntryTy()

12345678910>>...12