MLIR 22.0.0git
IRTypes.h
Go to the documentation of this file.
1//===- IRTypes.h - Type Interfaces ----------------------------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef MLIR_BINDINGS_PYTHON_IRTYPES_H
10#define MLIR_BINDINGS_PYTHON_IRTYPES_H
11
12#include "mlir-c/BuiltinTypes.h"
14
15namespace mlir {
16namespace python {
18
20
22 : public PyConcreteType<PyIntegerType> {
23public:
27 static constexpr const char *pyClassName = "IntegerType";
28 static inline const MlirStringRef name = mlirIntegerTypeGetName();
30
32
33 static void bindDerived(ClassTy &c);
34};
35
36/// Index Type subclass - IndexType.
38 : public PyConcreteType<PyIndexType> {
39public:
43 static constexpr const char *pyClassName = "IndexType";
44 static inline const MlirStringRef name = mlirIndexTypeGetName();
46
47 static void bindDerived(ClassTy &c);
48};
49
51 : public PyConcreteType<PyFloatType> {
52public:
54 static constexpr const char *pyClassName = "FloatType";
56
57 static void bindDerived(ClassTy &c);
58};
59
60/// Floating Point Type subclass - Float4E2M1FNType.
62 : public PyConcreteType<PyFloat4E2M1FNType, PyFloatType> {
63public:
67 static constexpr const char *pyClassName = "Float4E2M1FNType";
70
71 static void bindDerived(ClassTy &c);
72};
73
74/// Floating Point Type subclass - Float6E2M3FNType.
76 : public PyConcreteType<PyFloat6E2M3FNType, PyFloatType> {
77public:
81 static constexpr const char *pyClassName = "Float6E2M3FNType";
84
85 static void bindDerived(ClassTy &c);
86};
87
88/// Floating Point Type subclass - Float6E3M2FNType.
90 : public PyConcreteType<PyFloat6E3M2FNType, PyFloatType> {
91public:
95 static constexpr const char *pyClassName = "Float6E3M2FNType";
98
99 static void bindDerived(ClassTy &c);
100};
101
102/// Floating Point Type subclass - Float8E4M3FNType.
104 : public PyConcreteType<PyFloat8E4M3FNType, PyFloatType> {
105public:
109 static constexpr const char *pyClassName = "Float8E4M3FNType";
112
113 static void bindDerived(ClassTy &c);
114};
115
116/// Floating Point Type subclass - Float8E5M2Type.
118 : public PyConcreteType<PyFloat8E5M2Type, PyFloatType> {
119public:
123 static constexpr const char *pyClassName = "Float8E5M2Type";
126
127 static void bindDerived(ClassTy &c);
128};
129
130/// Floating Point Type subclass - Float8E4M3Type.
132 : public PyConcreteType<PyFloat8E4M3Type, PyFloatType> {
133public:
137 static constexpr const char *pyClassName = "Float8E4M3Type";
140
141 static void bindDerived(ClassTy &c);
142};
143
144/// Floating Point Type subclass - Float8E4M3FNUZ.
146 : public PyConcreteType<PyFloat8E4M3FNUZType, PyFloatType> {
147public:
151 static constexpr const char *pyClassName = "Float8E4M3FNUZType";
154
155 static void bindDerived(ClassTy &c);
156};
157
158/// Floating Point Type subclass - Float8E4M3B11FNUZ.
160 : public PyConcreteType<PyFloat8E4M3B11FNUZType, PyFloatType> {
161public:
165 static constexpr const char *pyClassName = "Float8E4M3B11FNUZType";
168
169 static void bindDerived(ClassTy &c);
170};
171
172/// Floating Point Type subclass - Float8E5M2FNUZ.
174 : public PyConcreteType<PyFloat8E5M2FNUZType, PyFloatType> {
175public:
179 static constexpr const char *pyClassName = "Float8E5M2FNUZType";
182
183 static void bindDerived(ClassTy &c);
184};
185
186/// Floating Point Type subclass - Float8E3M4Type.
188 : public PyConcreteType<PyFloat8E3M4Type, PyFloatType> {
189public:
193 static constexpr const char *pyClassName = "Float8E3M4Type";
196
197 static void bindDerived(ClassTy &c);
198};
199
200/// Floating Point Type subclass - Float8E8M0FNUType.
202 : public PyConcreteType<PyFloat8E8M0FNUType, PyFloatType> {
203public:
207 static constexpr const char *pyClassName = "Float8E8M0FNUType";
210
211 static void bindDerived(ClassTy &c);
212};
213
214/// Floating Point Type subclass - BF16Type.
216 : public PyConcreteType<PyBF16Type, PyFloatType> {
217public:
221 static constexpr const char *pyClassName = "BF16Type";
222 static inline const MlirStringRef name = mlirBF16TypeGetName();
224
225 static void bindDerived(ClassTy &c);
226};
227
228/// Floating Point Type subclass - F16Type.
230 : public PyConcreteType<PyF16Type, PyFloatType> {
231public:
235 static constexpr const char *pyClassName = "F16Type";
236 static inline const MlirStringRef name = mlirF16TypeGetName();
238
239 static void bindDerived(ClassTy &c);
240};
241
242/// Floating Point Type subclass - TF32Type.
244 : public PyConcreteType<PyTF32Type, PyFloatType> {
245public:
249 static constexpr const char *pyClassName = "FloatTF32Type";
250 static inline const MlirStringRef name = mlirTF32TypeGetName();
252
253 static void bindDerived(ClassTy &c);
254};
255
256/// Floating Point Type subclass - F32Type.
258 : public PyConcreteType<PyF32Type, PyFloatType> {
259public:
263 static constexpr const char *pyClassName = "F32Type";
264 static inline const MlirStringRef name = mlirF32TypeGetName();
266
267 static void bindDerived(ClassTy &c);
268};
269
270/// Floating Point Type subclass - F64Type.
272 : public PyConcreteType<PyF64Type, PyFloatType> {
273public:
277 static constexpr const char *pyClassName = "F64Type";
278 static inline const MlirStringRef name = mlirF64TypeGetName();
280
281 static void bindDerived(ClassTy &c);
282};
283
284/// None Type subclass - NoneType.
286public:
290 static constexpr const char *pyClassName = "NoneType";
291 static inline const MlirStringRef name = mlirNoneTypeGetName();
293
294 static void bindDerived(ClassTy &c);
295};
296
297/// Complex Type subclass - ComplexType.
299 : public PyConcreteType<PyComplexType> {
300public:
304 static constexpr const char *pyClassName = "ComplexType";
307
308 static void bindDerived(ClassTy &c);
309};
310
311/// Shaped Type Interface - ShapedType
313 : public PyConcreteType<PyShapedType> {
314public:
316 static constexpr const char *pyClassName = "ShapedType";
318
319 static void bindDerived(ClassTy &c);
320
321private:
322 void requireHasRank();
323};
324
325/// Vector Type subclass - VectorType.
327 : public PyConcreteType<PyVectorType, PyShapedType> {
328public:
332 static constexpr const char *pyClassName = "VectorType";
333 static inline const MlirStringRef name = mlirVectorTypeGetName();
335
336 static void bindDerived(ClassTy &c);
337
338private:
339 static PyVectorType
340 getChecked(std::vector<int64_t> shape, PyType &elementType,
341 std::optional<nanobind::list> scalable,
342 std::optional<std::vector<int64_t>> scalableDims,
344
345 static PyVectorType get(std::vector<int64_t> shape, PyType &elementType,
346 std::optional<nanobind::list> scalable,
347 std::optional<std::vector<int64_t>> scalableDims,
349};
350
351/// Ranked Tensor Type subclass - RankedTensorType.
353 : public PyConcreteType<PyRankedTensorType, PyShapedType> {
354public:
358 static constexpr const char *pyClassName = "RankedTensorType";
361
362 static void bindDerived(ClassTy &c);
363};
364
365/// Unranked Tensor Type subclass - UnrankedTensorType.
367 : public PyConcreteType<PyUnrankedTensorType, PyShapedType> {
368public:
372 static constexpr const char *pyClassName = "UnrankedTensorType";
375
376 static void bindDerived(ClassTy &c);
377};
378
379/// Ranked MemRef Type subclass - MemRefType.
381 : public PyConcreteType<PyMemRefType, PyShapedType> {
382public:
386 static constexpr const char *pyClassName = "MemRefType";
387 static inline const MlirStringRef name = mlirMemRefTypeGetName();
389
390 static void bindDerived(ClassTy &c);
391};
392
393/// Unranked MemRef Type subclass - UnrankedMemRefType.
395 : public PyConcreteType<PyUnrankedMemRefType, PyShapedType> {
396public:
400 static constexpr const char *pyClassName = "UnrankedMemRefType";
403
404 static void bindDerived(ClassTy &c);
405};
406
407/// Tuple Type subclass - TupleType.
409 : public PyConcreteType<PyTupleType> {
410public:
414 static constexpr const char *pyClassName = "TupleType";
415 static inline const MlirStringRef name = mlirTupleTypeGetName();
417
418 static void bindDerived(ClassTy &c);
419};
420
421/// Function type.
423 : public PyConcreteType<PyFunctionType> {
424public:
428 static constexpr const char *pyClassName = "FunctionType";
431
432 static void bindDerived(ClassTy &c);
433};
434
435/// Opaque Type subclass - OpaqueType.
437 : public PyConcreteType<PyOpaqueType> {
438public:
442 static constexpr const char *pyClassName = "OpaqueType";
443 static inline const MlirStringRef name = mlirOpaqueTypeGetName();
445
446 static void bindDerived(ClassTy &c);
447};
448
449MLIR_PYTHON_API_EXPORTED void populateIRTypes(nanobind::module_ &m);
450} // namespace MLIR_BINDINGS_PYTHON_DOMAIN
451} // namespace python
452} // namespace mlir
453
454#endif // MLIR_BINDINGS_PYTHON_IRTYPES_H
Used in function arguments when None should resolve to the current context manager set instance.
Definition IRCore.h:526
Used in function arguments when None should resolve to the current context manager set instance.
Definition IRCore.h:280
Floating Point Type subclass - BF16Type.
Definition IRTypes.h:216
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:218
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:219
Complex Type subclass - ComplexType.
Definition IRTypes.h:299
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:302
Floating Point Type subclass - F16Type.
Definition IRTypes.h:230
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:233
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:232
static constexpr const char * pyClassName
Definition IRTypes.h:235
Floating Point Type subclass - F32Type.
Definition IRTypes.h:258
static constexpr const char * pyClassName
Definition IRTypes.h:263
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:261
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:260
Floating Point Type subclass - F64Type.
Definition IRTypes.h:272
static constexpr const char * pyClassName
Definition IRTypes.h:277
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:275
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:274
Floating Point Type subclass - Float4E2M1FNType.
Definition IRTypes.h:62
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:65
Floating Point Type subclass - Float6E2M3FNType.
Definition IRTypes.h:76
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:79
Floating Point Type subclass - Float6E3M2FNType.
Definition IRTypes.h:90
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:93
Floating Point Type subclass - Float8E3M4Type.
Definition IRTypes.h:188
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:191
Floating Point Type subclass - Float8E4M3B11FNUZ.
Definition IRTypes.h:160
Floating Point Type subclass - Float8E4M3FNType.
Definition IRTypes.h:104
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:107
Floating Point Type subclass - Float8E4M3FNUZ.
Definition IRTypes.h:146
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:149
Floating Point Type subclass - Float8E4M3Type.
Definition IRTypes.h:132
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:135
Floating Point Type subclass - Float8E5M2FNUZ.
Definition IRTypes.h:174
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:177
Floating Point Type subclass - Float8E5M2Type.
Definition IRTypes.h:118
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:121
Floating Point Type subclass - Float8E8M0FNUType.
Definition IRTypes.h:202
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:205
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:53
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:426
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:41
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:40
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:25
Ranked MemRef Type subclass - MemRefType.
Definition IRTypes.h:381
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:384
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:288
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:287
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:440
Ranked Tensor Type subclass - RankedTensorType.
Definition IRTypes.h:353
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:356
Shaped Type Interface - ShapedType.
Definition IRTypes.h:313
Floating Point Type subclass - TF32Type.
Definition IRTypes.h:244
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:247
static constexpr IsAFunctionTy isaFunction
Definition IRTypes.h:246
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:412
Wrapper around the generic MlirType.
Definition IRCore.h:876
Unranked MemRef Type subclass - UnrankedMemRefType.
Definition IRTypes.h:395
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:398
Unranked Tensor Type subclass - UnrankedTensorType.
Definition IRTypes.h:367
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:370
static constexpr GetTypeIDFunctionTy getTypeIdFunction
Definition IRTypes.h:330
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E8M0FNUTypeGetTypeID(void)
Returns the typeID of an Float8E8M0FNU type.
MLIR_CAPI_EXPORTED MlirStringRef mlirF64TypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAMemRef(MlirType type)
Checks whether the given type is a MemRef type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat16TypeGetTypeID(void)
Returns the typeID of an Float16 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAInteger(MlirType type)
Checks whether the given type is an integer type.
MLIR_CAPI_EXPORTED MlirStringRef mlirUnrankedTensorTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat4E2M1FNTypeGetTypeID(void)
Returns the typeID of an Float4E2M1FN type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloatTF32TypeGetTypeID(void)
Returns the typeID of a TF32 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E8M0FNU(MlirType type)
Checks whether the given type is an f8E8M0FNU type.
MLIR_CAPI_EXPORTED MlirTypeID mlirNoneTypeGetTypeID(void)
Returns the typeID of an None type.
MLIR_CAPI_EXPORTED MlirStringRef mlirMemRefTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E4M3FNUZTypeGetTypeID(void)
Returns the typeID of an Float8E4M3FNUZ type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E4M3B11FNUZTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAVector(MlirType type)
Checks whether the given type is a Vector type.
MLIR_CAPI_EXPORTED MlirStringRef mlirBF16TypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirVectorTypeGetTypeID(void)
Returns the typeID of an Vector type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat6E3M2FN(MlirType type)
Checks whether the given type is an f6E3M2FN type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFunction(MlirType type)
Checks whether the given type is a function type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E4M3FNTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E3M4(MlirType type)
Checks whether the given type is an f8E3M4 type.
MLIR_CAPI_EXPORTED MlirStringRef mlirF16TypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirUnrankedTensorTypeGetTypeID(void)
Returns the typeID of an UnrankedTensor type.
MLIR_CAPI_EXPORTED MlirStringRef mlirIntegerTypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirNoneTypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirUnrankedMemRefTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirMemRefTypeGetTypeID(void)
Returns the typeID of an MemRef type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E4M3(MlirType type)
Checks whether the given type is an f8E4M3 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E5M2(MlirType type)
Checks whether the given type is an f8E5M2 type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat6E3M2FNTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAF64(MlirType type)
Checks whether the given type is an f64 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAF16(MlirType type)
Checks whether the given type is an f16 type.
MLIR_CAPI_EXPORTED MlirStringRef mlirOpaqueTypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirF32TypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E5M2FNUZTypeGetTypeID(void)
Returns the typeID of an Float8E5M2FNUZ type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat64TypeGetTypeID(void)
Returns the typeID of an Float64 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsATuple(MlirType type)
Checks whether the given type is a tuple type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E5M2TypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirComplexTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E5M2TypeGetTypeID(void)
Returns the typeID of an Float8E5M2 type.
MLIR_CAPI_EXPORTED MlirStringRef mlirRankedTensorTypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirTupleTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirTupleTypeGetTypeID(void)
Returns the typeID of an Tuple type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat4E2M1FNTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E4M3FN(MlirType type)
Checks whether the given type is an f8E4M3FN type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E4M3FNTypeGetTypeID(void)
Returns the typeID of an Float8E4M3FN type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAOpaque(MlirType type)
Checks whether the given type is an opaque type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat6E2M3FNTypeGetTypeID(void)
Returns the typeID of an Float6E2M3FN type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat6E2M3FN(MlirType type)
Checks whether the given type is an f6E2M3FN type.
MLIR_CAPI_EXPORTED MlirStringRef mlirVectorTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E3M4TypeGetTypeID(void)
Returns the typeID of an Float8E3M4 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat(MlirType type)
Checks whether the given type is a floating-point type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E4M3FNUZ(MlirType type)
Checks whether the given type is an f8E4M3FNUZ type.
MLIR_CAPI_EXPORTED MlirTypeID mlirBFloat16TypeGetTypeID(void)
Returns the typeID of an BFloat16 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAF32(MlirType type)
Checks whether the given type is an f32 type.
MLIR_CAPI_EXPORTED MlirTypeID mlirRankedTensorTypeGetTypeID(void)
Returns the typeID of an RankedTensor type.
MLIR_CAPI_EXPORTED MlirStringRef mlirTF32TypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E4M3FNUZTypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E4M3TypeGetName(void)
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E5M2FNUZTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsARankedTensor(MlirType type)
Checks whether the given type is a ranked tensor type.
MLIR_CAPI_EXPORTED bool mlirTypeIsATF32(MlirType type)
Checks whether the given type is an TF32 type.
MLIR_CAPI_EXPORTED MlirTypeID mlirComplexTypeGetTypeID(void)
Returns the typeID of an Complex type.
MLIR_CAPI_EXPORTED MlirStringRef mlirIndexTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirIntegerTypeGetTypeID(void)
Returns the typeID of an Integer type.
MLIR_CAPI_EXPORTED MlirTypeID mlirOpaqueTypeGetTypeID(void)
Returns the typeID of an Opaque type.
MLIR_CAPI_EXPORTED MlirTypeID mlirIndexTypeGetTypeID(void)
Returns the typeID of an Index type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E8M0FNUTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAComplex(MlirType type)
Checks whether the given type is a Complex type.
MLIR_CAPI_EXPORTED MlirTypeID mlirUnrankedMemRefTypeGetTypeID(void)
Returns the typeID of an UnrankedMemRef type.
MLIR_CAPI_EXPORTED bool mlirTypeIsABF16(MlirType type)
Checks whether the given type is a bf16 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAIndex(MlirType type)
Checks whether the given type is an index type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E4M3B11FNUZ(MlirType type)
Checks whether the given type is an f8E4M3B11FNUZ type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat6E2M3FNTypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAUnrankedMemRef(MlirType type)
Checks whether the given type is an UnrankedMemRef type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat8E5M2FNUZ(MlirType type)
Checks whether the given type is an f8E5M2FNUZ type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFloat8E3M4TypeGetName(void)
MLIR_CAPI_EXPORTED bool mlirTypeIsAUnrankedTensor(MlirType type)
Checks whether the given type is an unranked tensor type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat32TypeGetTypeID(void)
Returns the typeID of an Float32 type.
MLIR_CAPI_EXPORTED MlirStringRef mlirFunctionTypeGetName(void)
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E4M3TypeGetTypeID(void)
Returns the typeID of an Float8E4M3 type.
MLIR_CAPI_EXPORTED bool mlirTypeIsAFloat4E2M1FN(MlirType type)
Checks whether the given type is an f4E2M1FN type.
MLIR_CAPI_EXPORTED bool mlirTypeIsANone(MlirType type)
Checks whether the given type is a None type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFunctionTypeGetTypeID(void)
Returns the typeID of an Function type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat6E3M2FNTypeGetTypeID(void)
Returns the typeID of an Float6E3M2FN type.
MLIR_CAPI_EXPORTED MlirTypeID mlirFloat8E4M3B11FNUZTypeGetTypeID(void)
Returns the typeID of an Float8E4M3B11FNUZ type.
#define MLIR_PYTHON_API_EXPORTED
Definition Support.h:49
MLIR_PYTHON_API_EXPORTED void populateIRTypes(nanobind::module_ &m)
MLIR_PYTHON_API_EXPORTED int mlirTypeIsAIntegerOrFloat(MlirType type)
Definition IRTypes.cpp:32
Include the generated interface declarations.
A pointer to a sized fragment of a string, not necessarily null-terminated.
Definition Support.h:75