#include "mlir/Dialect/MLProgram/Transforms/BufferizableOpInterfaceImpl.h"
#include "mlir/Dialect/Bufferization/IR/BufferizableOpInterface.h"
#include "mlir/Dialect/MLProgram/IR/MLProgram.h"
#include "mlir/Dialect/MemRef/IR/MemRef.h"
usingnamespacemlir;
usingnamespacemlir::bufferization;
usingnamespacemlir::ml_program;
namespace mlir {
namespace ml_program {
namespace {
template <typename Interface, typename Op>
struct ExternalModelBase
: public BufferizableOpInterface::ExternalModel<Interface, Op> { … };
struct GlobalOpInterface
: public ExternalModelBase<GlobalOpInterface, GlobalOp> { … };
struct GlobalLoadOpInterface
: public ExternalModelBase<GlobalLoadOpInterface, GlobalLoadOp> { … };
struct GlobalStoreOpInterface
: public ExternalModelBase<GlobalStoreOpInterface, GlobalStoreOp> { … };
}
void registerBufferizableOpInterfaceExternalModels(DialectRegistry ®istry) { … }
}
}