MLIR 22.0.0git
mlir::ResourceBlobManagerDialectInterfaceBase< HandleT > Class Template Reference

This class provides a base class for dialects implementing the resource blob interface. More...

#include "mlir/IR/DialectResourceBlobManager.h"

Inheritance diagram for mlir::ResourceBlobManagerDialectInterfaceBase< HandleT >:

Public Member Functions

void update (StringRef name, AsmResourceBlob &&newBlob)
 Update the blob for the entry defined by the provided name.
HandleT insert (StringRef name, std::optional< AsmResourceBlob > blob={})
 Insert a new resource blob entry with the provided name and optional blob data.
void buildResources (AsmResourceBuilder &provider, ArrayRef< AsmDialectResourceHandle > referencedResources)
 Build resources for each of the referenced blobs within this manager.
Public Member Functions inherited from mlir::ResourceBlobManagerDialectInterface
 ResourceBlobManagerDialectInterface (Dialect *dialect)
DialectResourceBlobManagergetBlobManager ()
 Return the blob manager held by this interface.
const DialectResourceBlobManagergetBlobManager () const
void setBlobManager (std::shared_ptr< DialectResourceBlobManager > newBlobManager)
 Set the blob manager held by this interface.
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.

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.
Static Public Member Functions inherited from mlir::detail::DialectInterfaceBase< ConcreteType, DialectInterface >
static TypeID getInterfaceID ()
 Get a unique id for the derived interface type.
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

template<typename HandleT>
class mlir::ResourceBlobManagerDialectInterfaceBase< HandleT >

This class provides a base class for dialects implementing the resource blob interface.

It provides several additional dialect specific utilities on top of the generic interface. HandleT is the type of the handle used to reference a resource blob.

Definition at line 146 of file DialectResourceBlobManager.h.

Member Function Documentation

◆ buildResources()

template<typename HandleT>
void mlir::ResourceBlobManagerDialectInterfaceBase< HandleT >::buildResources ( AsmResourceBuilder & provider,
ArrayRef< AsmDialectResourceHandle > referencedResources )
inline

Build resources for each of the referenced blobs within this manager.

Definition at line 168 of file DialectResourceBlobManager.h.

◆ insert()

template<typename HandleT>
HandleT mlir::ResourceBlobManagerDialectInterfaceBase< HandleT >::insert ( StringRef name,
std::optional< AsmResourceBlob > blob = {} )
inline

Insert a new resource blob entry with the provided name and optional blob data.

The name may be modified during insertion if another entry already exists with that name. Returns a dialect specific handle to the inserted entry.

Definition at line 162 of file DialectResourceBlobManager.h.

◆ update()

template<typename HandleT>
void mlir::ResourceBlobManagerDialectInterfaceBase< HandleT >::update ( StringRef name,
AsmResourceBlob && newBlob )
inline

Update the blob for the entry defined by the provided name.

This method asserts that an entry for the given name exists in the manager.

Definition at line 154 of file DialectResourceBlobManager.h.


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