MLIR
20.0.0git
|
Base class for DenseResourceElementsAttr that is instantiated and specialized for each supported element type below. More...
#include "mlir/IR/BuiltinAttributes.h"
Public Member Functions | |
std::optional< ArrayRef< T > > | tryGetAsArrayRef () const |
Return the data of this attribute as an ArrayRef<T> if it is present, returns std::nullopt otherwise. More... | |
Static Public Member Functions | |
static DenseResourceElementsAttrBase< T > | get (ShapedType type, StringRef blobName, AsmResourceBlob blob) |
A builder that inserts a new resource using the provided blob. More... | |
static bool | classof (Attribute attr) |
Support for isa<>/cast<>. More... | |
Base class for DenseResourceElementsAttr that is instantiated and specialized for each supported element type below.
Definition at line 780 of file BuiltinAttributes.h.
|
static |
Support for isa<>/cast<>.
Definition at line 1631 of file BuiltinAttributes.cpp.
|
static |
A builder that inserts a new resource using the provided blob.
The handle of the inserted blob is used when building the attribute. The provided blobName
is used as a hint for the key of the new handle for the blob
resource, but may be changed if necessary to ensure uniqueness during insertion.
Definition at line 1609 of file BuiltinAttributes.cpp.
References mlir::get(), mlir::AsmResourceBlob::getData(), and mlir::AsmResourceBlob::getDataAlignment().
std::optional< ArrayRef< T > > DenseResourceElementsAttrBase::tryGetAsArrayRef |
Return the data of this attribute as an ArrayRef<T> if it is present, returns std::nullopt otherwise.
Definition at line 1624 of file BuiltinAttributes.cpp.