MLIR 22.0.0git
mlir::DataLayoutDialectInterface Class Reference

An interface to be implemented by dialects that can have identifiers in the data layout specification entries. More...

#include "mlir/Interfaces/DataLayoutInterfaces.h"

Inheritance diagram for mlir::DataLayoutDialectInterface:

Public Member Functions

 DataLayoutDialectInterface (Dialect *dialect)
virtual LogicalResult verifyEntry (DataLayoutEntryInterface entry, Location loc) const
 Checks whether the given data layout entry is valid and reports any errors at the provided location.
virtual LogicalResult verifyEntry (TargetDeviceSpecInterface entry, Location loc) const
 Checks whether the given data layout entry is valid and reports any errors at the provided location.
virtual DataLayoutEntryInterface combine (DataLayoutEntryInterface outer, DataLayoutEntryInterface inner) const
 Combines two entries with identifiers that belong to this dialect.
Public Member Functions inherited from mlir::DialectInterface
virtual ~DialectInterface ()
DialectgetDialect () const
 Return the dialect that this interface represents.
MLIRContextgetContext () const
 Return the context that holds the parent dialect of this interface.
TypeID getID () const
 Return the derived interface id.

Static Public Member Functions

static DataLayoutEntryInterface defaultCombine (DataLayoutEntryInterface outer, DataLayoutEntryInterface inner)
 Default implementation of entry combination that combines identical entries and returns null otherwise.
Static Public Member Functions inherited from mlir::detail::DialectInterfaceBase< ConcreteType, DialectInterface >
static TypeID getInterfaceID ()
 Get a unique id for the derived interface type.

Additional Inherited Members

Public Types inherited from mlir::detail::DialectInterfaceBase< ConcreteType, DialectInterface >
using Base
Public Types inherited from mlir::DialectInterface
template<typename ConcreteType>
using Base = detail::DialectInterfaceBase<ConcreteType, DialectInterface>
 The base class used for all derived interface types.
Protected Member Functions inherited from mlir::detail::DialectInterfaceBase< ConcreteType, DialectInterface >
 DialectInterfaceBase (Dialect *dialect)
Protected Member Functions inherited from mlir::DialectInterface
 DialectInterface (Dialect *dialect, TypeID id)

Detailed Description

An interface to be implemented by dialects that can have identifiers in the data layout specification entries.

Provides hooks for verifying the entry validity and combining two entries.

Definition at line 168 of file DataLayoutInterfaces.h.

Constructor & Destructor Documentation

◆ DataLayoutDialectInterface()

mlir::DataLayoutDialectInterface::DataLayoutDialectInterface ( Dialect * dialect)
inline

Definition at line 171 of file DataLayoutInterfaces.h.

Member Function Documentation

◆ combine()

virtual DataLayoutEntryInterface mlir::DataLayoutDialectInterface::combine ( DataLayoutEntryInterface outer,
DataLayoutEntryInterface inner ) const
inlinevirtual

Combines two entries with identifiers that belong to this dialect.

Returns the combined entry or null if the entries are not compatible. Derived classes likely need to reimplement this.

Definition at line 201 of file DataLayoutInterfaces.h.

References defaultCombine().

◆ defaultCombine()

DataLayoutEntryInterface mlir::DataLayoutDialectInterface::defaultCombine ( DataLayoutEntryInterface outer,
DataLayoutEntryInterface inner )
inlinestatic

Default implementation of entry combination that combines identical entries and returns null otherwise.

Definition at line 190 of file DataLayoutInterfaces.h.

Referenced by combine(), and combineOneSpec().

◆ verifyEntry() [1/2]

virtual LogicalResult mlir::DataLayoutDialectInterface::verifyEntry ( DataLayoutEntryInterface entry,
Location loc ) const
inlinevirtual

Checks whether the given data layout entry is valid and reports any errors at the provided location.

Derived classes should override this.

Definition at line 175 of file DataLayoutInterfaces.h.

References success().

◆ verifyEntry() [2/2]

virtual LogicalResult mlir::DataLayoutDialectInterface::verifyEntry ( TargetDeviceSpecInterface entry,
Location loc ) const
inlinevirtual

Checks whether the given data layout entry is valid and reports any errors at the provided location.

Derived classes should override this.

Definition at line 182 of file DataLayoutInterfaces.h.

References success().


The documentation for this class was generated from the following file: