|
MLIR 22.0.0git
|
Refinement of the PyDenseElementsAttribute for attributes containing integer (and boolean) values. More...
#include "mlir/Bindings/Python/IRAttributes.h"
Static Public Member Functions | |
| static void | bindDerived (ClassTy &c) |
| Static Public Member Functions inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyConcreteAttribute< PyDenseIntElementsAttribute, PyDenseElementsAttribute > | |
| static MlirAttribute | castFrom (PyAttribute &orig) |
| static void | bind (nanobind::module_ &m, PyType_Slot *slots=nullptr) |
| static void | bindDerived (ClassTy &m) |
| Implemented by derived classes to add methods to the Python subclass. | |
| Static Public Member Functions inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDenseElementsAttribute | |
| static PyDenseElementsAttribute | getFromList (const nanobind::list &attributes, std::optional< PyType > explicitType, DefaultingPyMlirContext contextWrapper) |
| static PyDenseElementsAttribute | getFromBuffer (const nb_buffer &array, bool signless, const std::optional< PyType > &explicitType, std::optional< std::vector< int64_t > > explicitShape, DefaultingPyMlirContext contextWrapper) |
| static PyDenseElementsAttribute | getSplat (const PyType &shapedType, PyAttribute &elementAttr) |
| static void | bindDerived (ClassTy &c) |
| Static Public Member Functions inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyConcreteAttribute< PyDenseElementsAttribute > | |
| static MlirAttribute | castFrom (PyAttribute &orig) |
| static void | bind (nanobind::module_ &m, PyType_Slot *slots=nullptr) |
| static void | bindDerived (ClassTy &m) |
| Implemented by derived classes to add methods to the Python subclass. | |
| Static Public Member Functions inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyAttribute | |
| static PyAttribute | createFromCapsule (const nanobind::object &capsule) |
| Creates a PyAttribute from the MlirAttribute wrapped by a capsule. | |
Static Public Attributes | |
| static constexpr IsAFunctionTy | isaFunction = mlirAttributeIsADenseIntElements |
| static constexpr const char * | pyClassName = "DenseIntElementsAttr" |
| Static Public Attributes inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyConcreteAttribute< PyDenseIntElementsAttribute, PyDenseElementsAttribute > | |
| static constexpr GetTypeIDFunctionTy | getTypeIdFunction |
| static const MlirStringRef | name |
| Static Public Attributes inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDenseElementsAttribute | |
| static constexpr IsAFunctionTy | isaFunction = mlirAttributeIsADenseElements |
| static constexpr const char * | pyClassName = "DenseElementsAttr" |
| static PyType_Slot | slots [] |
| Static Public Attributes inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyConcreteAttribute< PyDenseElementsAttribute > | |
| static constexpr GetTypeIDFunctionTy | getTypeIdFunction |
| static const MlirStringRef | name |
Additional Inherited Members | |
| Public Types inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyConcreteAttribute< PyDenseIntElementsAttribute, PyDenseElementsAttribute > | |
| using | ClassTy |
| using | IsAFunctionTy |
| using | GetTypeIDFunctionTy |
| using | Base |
| Public Types inherited from mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyConcreteAttribute< PyDenseElementsAttribute > | |
| using | ClassTy |
| using | IsAFunctionTy |
| using | GetTypeIDFunctionTy |
| using | Base |
Refinement of the PyDenseElementsAttribute for attributes containing integer (and boolean) values.
Supports element access.
Definition at line 495 of file IRAttributes.h.
|
static |
Definition at line 1026 of file IRAttributes.cpp.
References dunderGetItem().
| nb::int_ mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDenseIntElementsAttribute::dunderGetItem | ( | intptr_t | pos | ) | const |
Returns the element at the given linear position.
Asserts if the index is out of range.
Definition at line 968 of file IRAttributes.cpp.
References mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDenseElementsAttribute::dunderLen(), mlirAttributeGetType(), mlirDenseElementsAttrGetBoolValue(), mlirDenseElementsAttrGetIndexValue(), mlirDenseElementsAttrGetInt16Value(), mlirDenseElementsAttrGetInt32Value(), mlirDenseElementsAttrGetInt64Value(), mlirDenseElementsAttrGetInt8Value(), mlirDenseElementsAttrGetUInt16Value(), mlirDenseElementsAttrGetUInt32Value(), mlirDenseElementsAttrGetUInt64Value(), mlirDenseElementsAttrGetUInt8Value(), mlirIntegerTypeGetWidth(), mlirIntegerTypeIsUnsigned(), mlirShapedTypeGetElementType(), mlirTypeIsAIndex(), and mlirTypeIsAInteger().
Referenced by bindDerived().
|
default |
|
inline |
|
inline |
|
staticconstexpr |
Definition at line 499 of file IRAttributes.h.
Referenced by mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::denseIntOrFPElementsAttributeCaster().
|
staticconstexpr |
Definition at line 500 of file IRAttributes.h.