10#if defined(GET_OP_CLASSES) || defined(GET_OP_FWD_DEFINES)
11#undef GET_OP_FWD_DEFINES
47 FeltToIndexOpGenericAdaptorBase(::mlir::DictionaryAttr attrs =
nullptr, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {});
55template <
typename RangeT>
57 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
60 FeltToIndexOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs =
nullptr, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
64 template <
typename LateInst = FeltToIndexOp,
typename = std::enable_if_t<std::is_same_v<LateInst, FeltToIndexOp>>>
73 return {std::next(odsOperands.begin(), valueRange.first),
74 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
93 ::mlir::LogicalResult
verify(::mlir::Location loc);
95class FeltToIndexOp :
public ::mlir::Op<FeltToIndexOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::OneResult, ::mlir::OpTrait::OneTypedResult<::mlir::IndexType>::Impl, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::OpInvariants, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait> {
100 template <
typename RangeT>
108 return ::llvm::StringLiteral(
"cast.toindex");
113 ::mlir::TypedValue<::llzk::felt::FeltType>
getValue();
116 ::mlir::Operation::result_range
getODSResults(
unsigned index);
117 ::mlir::TypedValue<::mlir::IndexType>
getResult();
118 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value value);
119 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value value);
120 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
123 ::mlir::LogicalResult
verify();
124 static ::mlir::ParseResult
parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
125 void print(::mlir::OpAsmPrinter &_odsPrinter);
126 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
148 IntToFeltOpGenericAdaptorBase(::mlir::DictionaryAttr attrs =
nullptr, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {});
156template <
typename RangeT>
158 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
161 IntToFeltOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs =
nullptr, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
165 template <
typename LateInst = IntToFeltOp,
typename = std::enable_if_t<std::is_same_v<LateInst, IntToFeltOp>>>
174 return {std::next(odsOperands.begin(), valueRange.first),
175 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
194 ::mlir::LogicalResult
verify(::mlir::Location loc);
196class IntToFeltOp :
public ::mlir::Op<IntToFeltOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::OneResult, ::mlir::OpTrait::OneTypedResult<::llzk::felt::FeltType>::Impl, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::OpInvariants, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait> {
201 template <
typename RangeT>
209 return ::llvm::StringLiteral(
"cast.tofelt");
217 ::mlir::Operation::result_range
getODSResults(
unsigned index);
218 ::mlir::TypedValue<::llzk::felt::FeltType>
getResult();
219 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value value);
220 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value value);
221 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
224 static ::mlir::ParseResult
parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
225 void print(::mlir::OpAsmPrinter &_odsPrinter);
226 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
::mlir::LogicalResult verify(::mlir::Location loc)
FeltToIndexOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
FeltToIndexOpAdaptor(FeltToIndexOp op)
FeltToIndexOpGenericAdaptor(RangeT values, LateInst op)
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
FeltToIndexOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
FeltToIndexOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
RangeT getODSOperands(unsigned index)
::mlir::OpOperand & getValueMutable()
::mlir::TypedValue<::mlir::IndexType > getResult()
::mlir::Operation::operand_range getODSOperands(unsigned index)
::mlir::Operation::result_range getODSResults(unsigned index)
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
::mlir::LogicalResult verify()
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value value)
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
void print(::mlir::OpAsmPrinter &_odsPrinter)
::mlir::LogicalResult verifyInvariants()
::mlir::LogicalResult verifyInvariantsImpl()
::mlir::TypedValue<::llzk::felt::FeltType > getValue()
FeltToIndexOpAdaptor Adaptor
FeltToIndexOpGenericAdaptor< RangeT > GenericAdaptor
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
static constexpr ::llvm::StringLiteral getOperationName()
IntToFeltOpAdaptor(IntToFeltOp op)
IntToFeltOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
::mlir::LogicalResult verify(::mlir::Location loc)
IntToFeltOpGenericAdaptor(RangeT values, LateInst op)
IntToFeltOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
IntToFeltOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
RangeT getODSOperands(unsigned index)
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
::mlir::LogicalResult verifyInvariantsImpl()
void print(::mlir::OpAsmPrinter &_odsPrinter)
::mlir::Operation::operand_range getODSOperands(unsigned index)
static constexpr ::llvm::StringLiteral getOperationName()
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
::mlir::LogicalResult verifyInvariants()
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
IntToFeltOpAdaptor Adaptor
::mlir::TypedValue<::llzk::felt::FeltType > getResult()
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
IntToFeltOpGenericAdaptor< RangeT > GenericAdaptor
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value value)
::mlir::Operation::result_range getODSResults(unsigned index)
::mlir::OpOperand & getValueMutable()
::mlir::RegionRange odsRegions
::std::optional<::mlir::OperationName > odsOpName
FeltToIndexOpGenericAdaptorBase(::mlir::DictionaryAttr attrs=nullptr, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
::mlir::DictionaryAttr getAttributes()
::mlir::DictionaryAttr odsAttrs
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
::std::optional<::mlir::OperationName > odsOpName
IntToFeltOpGenericAdaptorBase(::mlir::DictionaryAttr attrs=nullptr, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
::mlir::DictionaryAttr odsAttrs
::mlir::RegionRange odsRegions
::mlir::DictionaryAttr getAttributes()
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)