28 #define GEN_PASS_DEF_TENSORBUFFERIZE
29 #include "mlir/Dialect/Tensor/Transforms/Passes.h.inc"
34 using namespace bufferization;
37 struct TensorBufferizePass
38 :
public tensor::impl::TensorBufferizeBase<TensorBufferizePass> {
39 void runOnOperation()
override {
41 options.opFilter.allowDialect<tensor::TensorDialect>();
49 .
insert<bufferization::BufferizationDialect, memref::MemRefDialect,
50 tensor::TensorDialect, scf::SCFDialect, arith::ArithDialect>();
57 return std::make_unique<TensorBufferizePass>();
static llvm::ManagedStatic< PassManagerOptions > options
The DialectRegistry maps a dialect namespace to a constructor for the matching dialect.
LogicalResult bufferizeOp(Operation *op, const BufferizationOptions &options, BufferizationStatistics *statistics=nullptr)
Bufferize op and its nested ops that implement BufferizableOpInterface.
BufferizationOptions getPartialBufferizationOptions()
Return BufferizationOptions such that the bufferizeOp behaves like the old (deprecated) partial,...
void registerBufferizableOpInterfaceExternalModels(DialectRegistry ®istry)
std::unique_ptr< Pass > createTensorBufferizePass()
Creates an instance of the tensor dialect bufferization pass.
Include the generated interface declarations.
bool failed(LogicalResult result)
Utility function that returns true if the provided LogicalResult corresponds to a failure value.
Options for BufferizableOpInterface-based bufferization.