/*===- TableGen'erated file -------------------------------------*- C++ -*-===*\ |* *| |* Interface Declarations *| |* *| |* Automatically generated file, do not edit! *| |* *| \*===----------------------------------------------------------------------===*/ namespace mlir { /// This interface allows operation to control the serialization of their /// properties. class BytecodeOpInterface; } // namespace mlir namespace mlir { /// This interface allows operation to control the serialization of their /// properties. namespace detail { struct BytecodeOpInterfaceInterfaceTraits { struct Concept { /// The methods defined by the interface. LogicalResult (*readProperties)(::mlir::DialectBytecodeReader &, ::mlir::OperationState &); void (*writeProperties)(const Concept *impl, ::mlir::Operation *, ::mlir::DialectBytecodeWriter &); }; template class Model : public Concept { public: using Interface = ::mlir::BytecodeOpInterface; Model() : Concept{readProperties, writeProperties} {} static inline LogicalResult readProperties(::mlir::DialectBytecodeReader & reader, ::mlir::OperationState & state); static inline void writeProperties(const Concept *impl, ::mlir::Operation *tablegen_opaque_val, ::mlir::DialectBytecodeWriter & writer); }; template class FallbackModel : public Concept { public: using Interface = ::mlir::BytecodeOpInterface; FallbackModel() : Concept{readProperties, writeProperties} {} static inline LogicalResult readProperties(::mlir::DialectBytecodeReader & reader, ::mlir::OperationState & state); static inline void writeProperties(const Concept *impl, ::mlir::Operation *tablegen_opaque_val, ::mlir::DialectBytecodeWriter & writer); }; template class ExternalModel : public FallbackModel { public: using ConcreteEntity = ConcreteOp; }; }; template struct BytecodeOpInterfaceTrait; } // namespace detail class BytecodeOpInterface : public ::mlir::OpInterface { public: using ::mlir::OpInterface::OpInterface; template struct Trait : public detail::BytecodeOpInterfaceTrait {}; /// Read the properties for this operation from the bytecode and populate the state. LogicalResult readProperties(::mlir::DialectBytecodeReader & reader, ::mlir::OperationState & state); /// Write the properties for this operation to the bytecode. void writeProperties(::mlir::DialectBytecodeWriter & writer); }; } // namespace mlir namespace mlir::detail { template struct BytecodeOpInterfaceTrait : public ::mlir::OpInterface::Trait { }; } // namespace mlir::detail namespace mlir { template LogicalResult detail::BytecodeOpInterfaceInterfaceTraits::Model::readProperties(::mlir::DialectBytecodeReader & reader, ::mlir::OperationState & state) { return ConcreteOp::readProperties(reader, state); } template void detail::BytecodeOpInterfaceInterfaceTraits::Model::writeProperties(const Concept *impl, ::mlir::Operation *tablegen_opaque_val, ::mlir::DialectBytecodeWriter & writer) { return (llvm::cast(tablegen_opaque_val)).writeProperties(writer); } template LogicalResult detail::BytecodeOpInterfaceInterfaceTraits::FallbackModel::readProperties(::mlir::DialectBytecodeReader & reader, ::mlir::OperationState & state) { return ConcreteOp::readProperties(reader, state); } template void detail::BytecodeOpInterfaceInterfaceTraits::FallbackModel::writeProperties(const Concept *impl, ::mlir::Operation *tablegen_opaque_val, ::mlir::DialectBytecodeWriter & writer) { return static_cast(impl)->writeProperties(tablegen_opaque_val, writer); } } // namespace mlir