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

Additional Inherited Members

- Public Types inherited from mlir::detail::DialectInterfaceBase< ConcreteType, BaseT >
using Base = DialectInterfaceBase< ConcreteType, BaseT >
 
- Static Public Member Functions inherited from mlir::detail::DialectInterfaceBase< ConcreteType, BaseT >
static TypeID getInterfaceID ()
 Get a unique id for the derived interface type. More...
 
- Protected Member Functions inherited from mlir::detail::DialectInterfaceBase< ConcreteType, BaseT >
 DialectInterfaceBase (Dialect *dialect)
 

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 141 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 163 of file DialectResourceBlobManager.h.

References mlir::AsmResourceBuilder::buildBlob().

◆ 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 157 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 149 of file DialectResourceBlobManager.h.

References mlir::ResourceBlobManagerDialectInterface::getBlobManager(), and mlir::DialectResourceBlobManager::update().


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