MLIR  17.0.0git
Namespaces | Classes | Typedefs | Functions | Variables
mlir::python Namespace Reference

Namespaces

 adaptors
 

Classes

class  PyGlobals
 Globals that are always accessible once the extension has been initialized. More...
 
class  PyConcreteOpInterface
 CRTP base class for Python classes representing MLIR Op interfaces. More...
 
class  PyInferTypeOpInterface
 Python wrapper for InterTypeOpInterface. More...
 
class  PyObjectRef
 Template for a reference to a concrete type which captures a python reference to its underlying python object. More...
 
class  PyThreadContextEntry
 Tracks an entry in the thread context stack. More...
 
class  PyMlirContext
 
class  DefaultingPyMlirContext
 Used in function arguments when None should resolve to the current context manager set instance. More...
 
class  BaseContextObject
 Base class for all objects that directly or indirectly depend on an MlirContext. More...
 
class  PyDiagnostic
 Python class mirroring the C MlirDiagnostic struct. More...
 
class  PyDiagnosticHandler
 Represents a diagnostic handler attached to the context. More...
 
class  PyDialectDescriptor
 Wrapper around an MlirDialect. More...
 
class  PyDialects
 User-level object for accessing dialects with dotted syntax such as: ctx.dialect.std. More...
 
class  PyDialect
 User-level dialect object. More...
 
class  PyDialectRegistry
 Wrapper around an MlirDialectRegistry. More...
 
class  PyLocation
 Wrapper around an MlirLocation. More...
 
class  DefaultingPyLocation
 Used in function arguments when None should resolve to the current context manager set instance. More...
 
class  PyModule
 
class  PyOperationBase
 Base class for PyOperation and PyOpView which exposes the primary, user visible methods for manipulating it. More...
 
class  PyOperation
 
class  PyOpView
 A PyOpView is equivalent to the C++ "Op" wrappers: these are the basis for providing more instance-specific accessors and serve as the base class for custom ODS-style operation classes. More...
 
class  PyRegion
 Wrapper around an MlirRegion. More...
 
class  PyBlock
 Wrapper around an MlirBlock. More...
 
class  PyInsertionPoint
 An insertion point maintains a pointer to a Block and a reference operation. More...
 
class  PyType
 Wrapper around the generic MlirType. More...
 
class  PyConcreteType
 CRTP base classes for Python types that subclass Type and should be castable from it (i.e. More...
 
class  PyAttribute
 Wrapper around the generic MlirAttribute. More...
 
class  PyNamedAttribute
 Represents a Python MlirNamedAttr, carrying an optional owned name. More...
 
class  PyConcreteAttribute
 CRTP base classes for Python attributes that subclass Attribute and should be castable from it (i.e. More...
 
class  PyValue
 Wrapper around the generic MlirValue. More...
 
class  PyAffineExpr
 Wrapper around MlirAffineExpr. Affine expressions are owned by the context. More...
 
class  PyAffineMap
 
class  PyIntegerSet
 
class  PySymbolTable
 Bindings for MLIR symbol tables. More...
 
class  Defaulting
 CRTP template for special wrapper types that are allowed to be passed in as 'None' function arguments and can be resolved by some global mechanic if so. More...
 

Typedefs

using PyMlirContextRef = PyObjectRef< PyMlirContext >
 Wrapper around MlirContext. More...
 
using PyModuleRef = PyObjectRef< PyModule >
 
using PyOperationRef = PyObjectRef< PyOperation >
 

Functions

void populateIRInterfaces (py::module &m)
 
void populateIRAffine (pybind11::module &m)
 
void populateIRAttributes (pybind11::module &m)
 
void populateIRCore (pybind11::module &m)
 
void populateIRInterfaces (pybind11::module &m)
 
void populateIRTypes (pybind11::module &m)
 
void populatePassManagerSubmodule (pybind11::module &m)
 
pybind11::error_already_set SetPyError (PyObject *excClass, const llvm::Twine &message)
 

Variables

constexpr static const char * constructorDoc
 
constexpr static const char * operationDoc
 
constexpr static const char * opviewDoc
 
constexpr static const char * inferReturnTypesDoc
 

Typedef Documentation

◆ PyMlirContextRef

Wrapper around MlirContext.

Definition at line 157 of file IRModule.h.

◆ PyModuleRef

Definition at line 462 of file IRModule.h.

◆ PyOperationRef

Definition at line 533 of file IRModule.h.

Function Documentation

◆ populateIRAffine()

void mlir::python::populateIRAffine ( pybind11::module &  m)

Referenced by PYBIND11_MODULE().

◆ populateIRAttributes()

void mlir::python::populateIRAttributes ( pybind11::module &  m)

Referenced by PYBIND11_MODULE().

◆ populateIRCore()

void mlir::python::populateIRCore ( pybind11::module &  m)

Referenced by PYBIND11_MODULE().

◆ populateIRInterfaces() [1/2]

void mlir::python::populateIRInterfaces ( py::module &  m)

◆ populateIRInterfaces() [2/2]

void mlir::python::populateIRInterfaces ( pybind11::module &  m)

◆ populateIRTypes()

void mlir::python::populateIRTypes ( pybind11::module &  m)

Referenced by PYBIND11_MODULE().

◆ populatePassManagerSubmodule()

void mlir::python::populatePassManagerSubmodule ( pybind11::module &  m)

Referenced by PYBIND11_MODULE().

◆ SetPyError()

pybind11::error_already_set mlir::python::SetPyError ( PyObject *  excClass,
const llvm::Twine &  message 
)

Variable Documentation

◆ constructorDoc

constexpr static const char* mlir::python::constructorDoc
staticconstexpr
Initial value:
=
R"(Creates an interface from a given operation/opview object or from a
subclass of OpView. Raises ValueError if the operation does not implement the
interface.)"

Definition at line 22 of file IRInterfaces.cpp.

Referenced by mlir::python::PyConcreteOpInterface< ConcreteIface >::bind().

◆ inferReturnTypesDoc

constexpr static const char* mlir::python::inferReturnTypesDoc
staticconstexpr
Initial value:
=
R"(Given the arguments required to build an operation, attempts to infer
its return types. Raises ValueError on failure.)"

Definition at line 34 of file IRInterfaces.cpp.

Referenced by mlir::python::PyInferTypeOpInterface::bindDerived().

◆ operationDoc

constexpr static const char* mlir::python::operationDoc
staticconstexpr
Initial value:
=
R"(Returns an Operation for which the interface was constructed.)"

Definition at line 27 of file IRInterfaces.cpp.

Referenced by mlir::python::PyConcreteOpInterface< ConcreteIface >::bind().

◆ opviewDoc

constexpr static const char* mlir::python::opviewDoc
staticconstexpr
Initial value:
=
R"(Returns an OpView subclass _instance_ for which the interface was
constructed)"

Definition at line 30 of file IRInterfaces.cpp.

Referenced by mlir::python::PyConcreteOpInterface< ConcreteIface >::bind().