/*===- TableGen'erated file -------------------------------------*- C++ -*-===*\ |* *| |* Op Declarations *| |* *| |* Automatically generated file, do not edit! *| |* *| \*===----------------------------------------------------------------------===*/ #if defined(GET_OP_CLASSES) || defined(GET_OP_FWD_DEFINES) #undef GET_OP_FWD_DEFINES class AddOp; class ConstantOp; class GenericCallOp; class MulOp; class PrintOp; class ReshapeOp; class ReturnOp; class TransposeOp; #endif #ifdef GET_OP_CLASSES #undef GET_OP_CLASSES //===----------------------------------------------------------------------===// // toy::AddOp declarations //===----------------------------------------------------------------------===// class AddOpAdaptor { public: AddOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); AddOpAdaptor(AddOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::Value lhs(); ::mlir::Value rhs(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class AddOp : public ::mlir::Op::Impl> { public: using Op::Op; using Adaptor = AddOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Value lhs(); ::mlir::Value rhs(); ::mlir::MutableOperandRange lhsMutable(); ::mlir::MutableOperandRange rhsMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); static void build(OpBuilder &b, OperationState &state, Value lhs, Value rhs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::mlir::Value lhs, ::mlir::Value rhs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::Value lhs, ::mlir::Value rhs); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(::mlir::OpAsmPrinter &p); ::mlir::LogicalResult verify(); }; //===----------------------------------------------------------------------===// // toy::ConstantOp declarations //===----------------------------------------------------------------------===// class ConstantOpAdaptor { public: ConstantOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); ConstantOpAdaptor(ConstantOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::DenseElementsAttr value(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class ConstantOp : public ::mlir::Op { public: using Op::Op; using Adaptor = ConstantOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); ::mlir::DenseElementsAttr valueAttr(); ::mlir::DenseElementsAttr value(); void valueAttr(::mlir::DenseElementsAttr attr); static void build(OpBuilder &builder, OperationState &state, DenseElementsAttr value); static void build(OpBuilder &builder, OperationState &state, double value); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::mlir::DenseElementsAttr value); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::DenseElementsAttr value); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(::mlir::OpAsmPrinter &p); ::mlir::LogicalResult verify(); void getEffects(::mlir::SmallVectorImpl<::mlir::SideEffects::EffectInstance> &effects); }; //===----------------------------------------------------------------------===// // toy::GenericCallOp declarations //===----------------------------------------------------------------------===// class GenericCallOpAdaptor { public: GenericCallOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); GenericCallOpAdaptor(GenericCallOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::ValueRange inputs(); ::mlir::FlatSymbolRefAttr callee(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class GenericCallOp : public ::mlir::Op { public: using Op::Op; using Adaptor = GenericCallOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Operation::operand_range inputs(); ::mlir::MutableOperandRange inputsMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); ::mlir::FlatSymbolRefAttr calleeAttr(); ::llvm::StringRef callee(); void calleeAttr(::mlir::FlatSymbolRefAttr attr); static void build(OpBuilder &builder, OperationState &state, StringRef callee, ArrayRef arguments); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::mlir::FlatSymbolRefAttr callee, ::mlir::ValueRange inputs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::FlatSymbolRefAttr callee, ::mlir::ValueRange inputs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::llvm::StringRef callee, ::mlir::ValueRange inputs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::llvm::StringRef callee, ::mlir::ValueRange inputs); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); ::mlir::LogicalResult verify(); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(OpAsmPrinter &p); }; //===----------------------------------------------------------------------===// // toy::MulOp declarations //===----------------------------------------------------------------------===// class MulOpAdaptor { public: MulOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); MulOpAdaptor(MulOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::Value lhs(); ::mlir::Value rhs(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class MulOp : public ::mlir::Op::Impl> { public: using Op::Op; using Adaptor = MulOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Value lhs(); ::mlir::Value rhs(); ::mlir::MutableOperandRange lhsMutable(); ::mlir::MutableOperandRange rhsMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); static void build(OpBuilder &b, OperationState &state, Value lhs, Value rhs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::mlir::Value lhs, ::mlir::Value rhs); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::Value lhs, ::mlir::Value rhs); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(::mlir::OpAsmPrinter &p); ::mlir::LogicalResult verify(); }; //===----------------------------------------------------------------------===// // toy::PrintOp declarations //===----------------------------------------------------------------------===// class PrintOpAdaptor { public: PrintOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); PrintOpAdaptor(PrintOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::Value input(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class PrintOp : public ::mlir::Op { public: using Op::Op; using Adaptor = PrintOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Value input(); ::mlir::MutableOperandRange inputMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value input); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::Value input); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); ::mlir::LogicalResult verify(); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(OpAsmPrinter &p); }; //===----------------------------------------------------------------------===// // toy::ReshapeOp declarations //===----------------------------------------------------------------------===// class ReshapeOpAdaptor { public: ReshapeOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); ReshapeOpAdaptor(ReshapeOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::Value input(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class ReshapeOp : public ::mlir::Op { public: using Op::Op; using Adaptor = ReshapeOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Value input(); ::mlir::MutableOperandRange inputMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::mlir::Value input); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::Value input); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); ::mlir::LogicalResult verify(); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(OpAsmPrinter &p); }; //===----------------------------------------------------------------------===// // toy::ReturnOp declarations //===----------------------------------------------------------------------===// class ReturnOpAdaptor { public: ReturnOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); ReturnOpAdaptor(ReturnOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::ValueRange input(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class ReturnOp : public ::mlir::Op::Impl, OpTrait::IsTerminator> { public: using Op::Op; using Adaptor = ReturnOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Operation::operand_range input(); ::mlir::MutableOperandRange inputMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); static void build(OpBuilder &b, OperationState &state); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::ValueRange input); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); ::mlir::LogicalResult verify(); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(OpAsmPrinter &p); void getEffects(::mlir::SmallVectorImpl<::mlir::SideEffects::EffectInstance> &effects); bool hasOperand() { return getNumOperands() != 0; } }; //===----------------------------------------------------------------------===// // toy::TransposeOp declarations //===----------------------------------------------------------------------===// class TransposeOpAdaptor { public: TransposeOpAdaptor(::mlir::ValueRange values, ::mlir::DictionaryAttr attrs = nullptr); TransposeOpAdaptor(TransposeOp& op); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::ValueRange getODSOperands(unsigned index); ::mlir::Value input(); ::mlir::LogicalResult verify(::mlir::Location loc); private: ::mlir::ValueRange odsOperands; ::mlir::DictionaryAttr odsAttrs; }; class TransposeOp : public ::mlir::Op { public: using Op::Op; using Adaptor = TransposeOpAdaptor; static ::llvm::StringRef getOperationName(); std::pair getODSOperandIndexAndLength(unsigned index); ::mlir::Operation::operand_range getODSOperands(unsigned index); ::mlir::Value input(); ::mlir::MutableOperandRange inputMutable(); std::pair getODSResultIndexAndLength(unsigned index); ::mlir::Operation::result_range getODSResults(unsigned index); static void build(OpBuilder &b, OperationState &state, Value input); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type resultType0, ::mlir::Value input); static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::Value input); static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::llvm::ArrayRef<::mlir::Type> resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {}); ::mlir::LogicalResult verify(); static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result); void print(OpAsmPrinter &p); }; #endif // GET_OP_CLASSES