LLZK 3.0.0
An open-source IR for Zero Knowledge (ZK) circuits
Loading...
Searching...
No Matches
Ops.h.inc
Go to the documentation of this file.
1/*===- TableGen'erated file -------------------------------------*- C++ -*-===*\
2|* *|
3|* Op Declarations *|
4|* *|
5|* Automatically generated file, do not edit! *|
6|* From: Ops.td *|
7|* *|
8\*===----------------------------------------------------------------------===*/
9
10namespace llzk {
11namespace verif {
12class ContractEndOp;
13} // namespace verif
14} // namespace llzk
15namespace llzk {
16namespace verif {
17class ContractOp;
18} // namespace verif
19} // namespace llzk
20namespace llzk {
21namespace verif {
22class DecreasesOp;
23} // namespace verif
24} // namespace llzk
25namespace llzk {
26namespace verif {
27class EnsureComputeOp;
28} // namespace verif
29} // namespace llzk
30namespace llzk {
31namespace verif {
33} // namespace verif
34} // namespace llzk
35namespace llzk {
36namespace verif {
37class IncludeOp;
38} // namespace verif
39} // namespace llzk
40namespace llzk {
41namespace verif {
42class IncreasesOp;
43} // namespace verif
44} // namespace llzk
45namespace llzk {
46namespace verif {
47class InvariantOp;
48} // namespace verif
49} // namespace llzk
50namespace llzk {
51namespace verif {
52class OldOp;
53} // namespace verif
54} // namespace llzk
55namespace llzk {
56namespace verif {
58} // namespace verif
59} // namespace llzk
60namespace llzk {
61namespace verif {
63} // namespace verif
64} // namespace llzk
65namespace llzk {
66namespace verif {
67class StepOp;
68} // namespace verif
69} // namespace llzk
70namespace llzk {
71namespace verif {
72class StepYieldOp;
73} // namespace verif
74} // namespace llzk
75namespace llzk {
76namespace verif {
77class VerifAssertOp;
78} // namespace verif
79} // namespace llzk
80namespace llzk {
81namespace verif {
82class VerifProveOp;
83} // namespace verif
84} // namespace llzk
85namespace llzk {
86namespace verif {
87class VerifSMTProveOp;
88} // namespace verif
89} // namespace llzk
90#ifdef GET_OP_CLASSES
91#undef GET_OP_CLASSES
92
93namespace llzk {
94namespace verif {
95
96//===----------------------------------------------------------------------===//
97// ::llzk::verif::ContractEndOp declarations
98//===----------------------------------------------------------------------===//
99
100namespace detail {
102public:
103protected:
104 ::mlir::DictionaryAttr odsAttrs;
105 ::std::optional<::mlir::OperationName> odsOpName;
106 ::mlir::RegionRange odsRegions;
107public:
108 ContractEndOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
109 odsOpName.emplace("verif.contract_end", odsAttrs.getContext());
110 }
111
112 ContractEndOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
113
114 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
115 return {index, 1};
116 }
117
118 ::mlir::DictionaryAttr getAttributes() {
119 return odsAttrs;
120 }
121
122};
123} // namespace detail
124template <typename RangeT>
126 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
128public:
129 ContractEndOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
130
131 ContractEndOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : ContractEndOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
132
133 ContractEndOpGenericAdaptor(RangeT values, const ContractEndOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
134
135 template <typename LateInst = ContractEndOp, typename = std::enable_if_t<std::is_same_v<LateInst, ContractEndOp>>>
136 ContractEndOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
137
138 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
139 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
140 }
141
142 RangeT getODSOperands(unsigned index) {
143 auto valueRange = getODSOperandIndexAndLength(index);
144 return {std::next(odsOperands.begin(), valueRange.first),
145 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
146 }
147
148 RangeT getOperands() {
149 return odsOperands;
150 }
151
152private:
153 RangeT odsOperands;
154};
155class ContractEndOpAdaptor : public ContractEndOpGenericAdaptor<::mlir::ValueRange> {
156public:
159
160 ::llvm::LogicalResult verify(::mlir::Location loc);
161};
162class ContractEndOp : public ::mlir::Op<ContractEndOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::mlir::OpTrait::HasParent<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait, ::mlir::OpTrait::IsTerminator> {
163public:
164 using Op::Op;
165 using Op::print;
167 template <typename RangeT>
170 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
171 return {};
172 }
173
174 static constexpr ::llvm::StringLiteral getOperationName() {
175 return ::llvm::StringLiteral("verif.contract_end");
176 }
177
178 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
179 return {index, 1};
180 }
181
182 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
183 auto valueRange = getODSOperandIndexAndLength(index);
184 return {std::next(getOperation()->operand_begin(), valueRange.first),
185 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
186 }
187
188 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
189 return {index, 1};
190 }
191
192 ::mlir::Operation::result_range getODSResults(unsigned index) {
193 auto valueRange = getODSResultIndexAndLength(index);
194 return {std::next(getOperation()->result_begin(), valueRange.first),
195 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
196 }
197
198 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState);
199 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes);
200 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
201 ::llvm::LogicalResult verifyInvariantsImpl();
202 ::llvm::LogicalResult verifyInvariants();
203 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
204 void print(::mlir::OpAsmPrinter &_odsPrinter);
205 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
206public:
207};
208} // namespace verif
209} // namespace llzk
210MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::ContractEndOp)
211
212namespace llzk {
213namespace verif {
214
215//===----------------------------------------------------------------------===//
216// ::llzk::verif::ContractOp declarations
217//===----------------------------------------------------------------------===//
218
219namespace detail {
221public:
222 struct Properties {
223 using arg_attrsTy = ::mlir::ArrayAttr;
225
226 auto getArgAttrs() {
227 auto &propStorage = this->arg_attrs;
228 return ::llvm::dyn_cast_or_null<::mlir::ArrayAttr>(propStorage);
229 }
230 void setArgAttrs(const ::mlir::ArrayAttr &propValue) {
231 this->arg_attrs = propValue;
232 }
233 using function_typeTy = ::mlir::TypeAttr;
235
237 auto &propStorage = this->function_type;
238 return ::llvm::cast<::mlir::TypeAttr>(propStorage);
239 }
240 void setFunctionType(const ::mlir::TypeAttr &propValue) {
241 this->function_type = propValue;
242 }
243 using sym_nameTy = ::mlir::StringAttr;
245
246 auto getSymName() {
247 auto &propStorage = this->sym_name;
248 return ::llvm::cast<::mlir::StringAttr>(propStorage);
249 }
250 void setSymName(const ::mlir::StringAttr &propValue) {
251 this->sym_name = propValue;
252 }
253 using targetTy = ::mlir::SymbolRefAttr;
255
256 auto getTarget() {
257 auto &propStorage = this->target;
258 return ::llvm::cast<::mlir::SymbolRefAttr>(propStorage);
259 }
260 void setTarget(const ::mlir::SymbolRefAttr &propValue) {
261 this->target = propValue;
262 }
263 bool operator==(const Properties &rhs) const {
264 return
265 rhs.arg_attrs == this->arg_attrs &&
266 rhs.function_type == this->function_type &&
267 rhs.sym_name == this->sym_name &&
268 rhs.target == this->target &&
269 true;
270 }
271 bool operator!=(const Properties &rhs) const {
272 return !(*this == rhs);
273 }
274 };
275protected:
276 ::mlir::DictionaryAttr odsAttrs;
277 ::std::optional<::mlir::OperationName> odsOpName;
279 ::mlir::RegionRange odsRegions;
280public:
281 ContractOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
282 odsOpName.emplace("verif.contract", odsAttrs.getContext());
283 }
284
286
287 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
288 return {index, 1};
289 }
290
292 return properties;
293 }
294
295 ::mlir::DictionaryAttr getAttributes() {
296 return odsAttrs;
297 }
298
299 ::mlir::StringAttr getSymNameAttr() {
300 auto attr = ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
301 return attr;
302 }
303
304 ::llvm::StringRef getSymName();
305 ::mlir::SymbolRefAttr getTargetAttr() {
306 auto attr = ::llvm::cast<::mlir::SymbolRefAttr>(getProperties().target);
307 return attr;
308 }
309
310 ::mlir::SymbolRefAttr getTarget();
311 ::mlir::TypeAttr getFunctionTypeAttr() {
312 auto attr = ::llvm::cast<::mlir::TypeAttr>(getProperties().function_type);
313 return attr;
314 }
315
316 ::mlir::FunctionType getFunctionType();
317 ::mlir::ArrayAttr getArgAttrsAttr() {
318 auto attr = ::llvm::dyn_cast_or_null<::mlir::ArrayAttr>(getProperties().arg_attrs);
319 return attr;
320 }
321
322 ::std::optional< ::mlir::ArrayAttr > getArgAttrs();
323 ::mlir::Region &getBody() {
324 return *odsRegions[0];
325 }
326
327 ::mlir::RegionRange getRegions() {
328 return odsRegions;
329 }
330
331};
332} // namespace detail
333template <typename RangeT>
335 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
337public:
338 ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
339
340 ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : ContractOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
341
342 ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : ContractOpGenericAdaptor(values, attrs, Properties{}, {}) {}
343
344 ContractOpGenericAdaptor(RangeT values, const ContractOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
345
346 template <typename LateInst = ContractOp, typename = std::enable_if_t<std::is_same_v<LateInst, ContractOp>>>
347 ContractOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
348
349 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
350 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
351 }
352
353 RangeT getODSOperands(unsigned index) {
354 auto valueRange = getODSOperandIndexAndLength(index);
355 return {std::next(odsOperands.begin(), valueRange.first),
356 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
357 }
358
359 RangeT getOperands() {
360 return odsOperands;
361 }
362
363private:
364 RangeT odsOperands;
365};
366class ContractOpAdaptor : public ContractOpGenericAdaptor<::mlir::ValueRange> {
367public:
370
371 ::llvm::LogicalResult verify(::mlir::Location loc);
372};
373class ContractOp : public ::mlir::Op<ContractOp, ::mlir::OpTrait::OneRegion, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::mlir::OpTrait::HasParent<::mlir::ModuleOp, ::llzk::polymorphic::TemplateOp>::Impl, ::mlir::OpTrait::SingleBlock, ::mlir::OpTrait::SingleBlockImplicitTerminator<::llzk::verif::ContractEndOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::SymbolUserOpInterface::Trait, ::mlir::OpTrait::AffineScope, ::mlir::OpTrait::AutomaticAllocationScope, ::mlir::SymbolOpInterface::Trait, ::mlir::CallableOpInterface::Trait, ::mlir::FunctionOpInterface::Trait, ::mlir::OpTrait::IsIsolatedFromAbove> {
374public:
375 using Op::Op;
376 using Op::print;
378 template <typename RangeT>
382 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
383 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("arg_attrs"), ::llvm::StringRef("function_type"), ::llvm::StringRef("sym_name"), ::llvm::StringRef("target")};
384 return ::llvm::ArrayRef(attrNames);
385 }
386
387 ::mlir::StringAttr getArgAttrsAttrName() {
388 return getAttributeNameForIndex(0);
389 }
390
391 static ::mlir::StringAttr getArgAttrsAttrName(::mlir::OperationName name) {
392 return getAttributeNameForIndex(name, 0);
393 }
394
395 ::mlir::StringAttr getFunctionTypeAttrName() {
396 return getAttributeNameForIndex(1);
397 }
398
399 static ::mlir::StringAttr getFunctionTypeAttrName(::mlir::OperationName name) {
400 return getAttributeNameForIndex(name, 1);
401 }
402
403 ::mlir::StringAttr getSymNameAttrName() {
404 return getAttributeNameForIndex(2);
405 }
406
407 static ::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name) {
408 return getAttributeNameForIndex(name, 2);
409 }
410
411 ::mlir::StringAttr getTargetAttrName() {
412 return getAttributeNameForIndex(3);
413 }
414
415 static ::mlir::StringAttr getTargetAttrName(::mlir::OperationName name) {
416 return getAttributeNameForIndex(name, 3);
417 }
418
419 static constexpr ::llvm::StringLiteral getOperationName() {
420 return ::llvm::StringLiteral("verif.contract");
421 }
422
423 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
424 return {index, 1};
425 }
426
427 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
428 auto valueRange = getODSOperandIndexAndLength(index);
429 return {std::next(getOperation()->operand_begin(), valueRange.first),
430 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
431 }
432
433 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
434 return {index, 1};
435 }
436
437 ::mlir::Operation::result_range getODSResults(unsigned index) {
438 auto valueRange = getODSResultIndexAndLength(index);
439 return {std::next(getOperation()->result_begin(), valueRange.first),
440 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
441 }
442
443 ::mlir::Region &getBody() {
444 return (*this)->getRegion(0);
445 }
446
447 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
448 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
449 static llvm::hash_code computePropertiesHash(const Properties &prop);
450 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
451 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
452 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
453 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
454 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
455 void writeProperties(::mlir::DialectBytecodeWriter &writer);
456 ::mlir::StringAttr getSymNameAttr() {
457 return ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
458 }
459
460 ::llvm::StringRef getSymName();
461 ::mlir::SymbolRefAttr getTargetAttr() {
462 return ::llvm::cast<::mlir::SymbolRefAttr>(getProperties().target);
463 }
464
465 ::mlir::SymbolRefAttr getTarget();
466 ::mlir::TypeAttr getFunctionTypeAttr() {
467 return ::llvm::cast<::mlir::TypeAttr>(getProperties().function_type);
468 }
469
470 ::mlir::FunctionType getFunctionType();
471 ::mlir::ArrayAttr getArgAttrsAttr() {
472 return ::llvm::dyn_cast_or_null<::mlir::ArrayAttr>(getProperties().arg_attrs);
473 }
474
475 ::std::optional< ::mlir::ArrayAttr > getArgAttrs();
476 void setSymNameAttr(::mlir::StringAttr attr) {
477 getProperties().sym_name = attr;
478 }
479
480 void setSymName(::llvm::StringRef attrValue);
481 void setTargetAttr(::mlir::SymbolRefAttr attr) {
482 getProperties().target = attr;
483 }
484
485 void setFunctionTypeAttr(::mlir::TypeAttr attr) {
486 getProperties().function_type = attr;
487 }
488
489 void setFunctionType(::mlir::FunctionType attrValue);
490 void setArgAttrsAttr(::mlir::ArrayAttr attr) {
491 getProperties().arg_attrs = attr;
492 }
493
494 ::mlir::Attribute removeArgAttrsAttr() {
495 auto &attr = getProperties().arg_attrs;
496 attr = {};
497 return attr;
498 }
499
500 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name, ::mlir::SymbolRefAttr target, ::mlir::TypeAttr function_type, ::mlir::ArrayAttr arg_attrs = {});
501 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::StringAttr sym_name, ::mlir::SymbolRefAttr target, ::mlir::TypeAttr function_type, ::mlir::ArrayAttr arg_attrs = {});
502 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef sym_name, ::mlir::SymbolRefAttr target, ::mlir::FunctionType function_type, ::mlir::ArrayAttr arg_attrs = {});
503 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::llvm::StringRef sym_name, ::mlir::SymbolRefAttr target, ::mlir::FunctionType function_type, ::mlir::ArrayAttr arg_attrs = {});
504 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef name, llvm::StringRef target);
505 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef name, ::mlir::SymbolRefAttr target);
506 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
507 void print(::mlir::OpAsmPrinter &p);
508 ::llvm::LogicalResult verifyInvariantsImpl();
509 ::llvm::LogicalResult verifyInvariants();
510 ::llvm::LogicalResult verify();
511 ::llvm::LogicalResult verifyRegions();
512 ::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable);
513private:
514 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
515 return getAttributeNameForIndex((*this)->getName(), index);
516 }
517
518 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
519 assert(index < 4 && "invalid attribute index");
520 assert(name.getStringRef() == getOperationName() && "invalid operation name");
521 assert(name.isRegistered() && "Operation isn't registered, missing a "
522 "dependent dialect loading?");
523 return name.getAttributeNames()[index];
524 }
525
526public:
534 ContractOp clone(::mlir::IRMapping &mapper);
536
541 void cloneInto(ContractOp dest, ::mlir::IRMapping &mapper);
542
544 bool hasArgPublicAttr(unsigned index);
545
547 bool hasArgName(unsigned index);
548
550 ::std::optional<::mlir::StringAttr> getArgNameAttr(unsigned index);
551
553 void setArgNameAttr(unsigned index, const ::mlir::StringAttr &attr);
554
556 void setArgName(unsigned index, ::llvm::StringRef name);
557
560 ::mlir::Region *getCallableRegion() { return &getBody(); }
561
564 ::llvm::ArrayRef<::mlir::Type> getArgumentTypes() { return getFunctionType().getInputs(); }
565
569 ::llvm::ArrayRef<::mlir::Type> getResultTypes() { return getFunctionType().getResults(); }
570
572 bool isDeclaration() { return false; }
573
576 ::mlir::SymbolRefAttr getFullyQualifiedName(bool requireParent = true);
577
579 bool hasStructTarget() { return succeeded(getStructTarget()); }
580
583 ::mlir::FailureOr<SymbolLookupResult<component::StructDefOp>> getStructTarget(::mlir::SymbolTableCollection &tables);
584
585 ::mlir::FailureOr<SymbolLookupResult<component::StructDefOp>> getStructTarget() {
586 ::mlir::SymbolTableCollection tables;
587 return getStructTarget(tables);
588 }
589
592 ::mlir::FailureOr<::mlir::Value> getSelfValue();
593
595 bool hasFuncTarget() { return succeeded(getFuncTarget()); }
596
599 ::mlir::FailureOr<SymbolLookupResult<function::FuncDefOp>> getFuncTarget(::mlir::SymbolTableCollection &tables);
600
601 ::mlir::FailureOr<SymbolLookupResult<function::FuncDefOp>> getFuncTarget() {
602 ::mlir::SymbolTableCollection tables;
603 return getFuncTarget(tables);
604 }
605
608 ::mlir::FailureOr<SymbolLookupResult<::llzk::verif::ContractTargetOpInterface>> getTargetOp(::mlir::SymbolTableCollection &tables);
609
610 ::mlir::FailureOr<SymbolLookupResult<::llzk::verif::ContractTargetOpInterface>> getTargetOp() {
611 ::mlir::SymbolTableCollection tables;
612 return getTargetOp(tables);
613 }
614
615 private:
618 static void initializeEmptyBody(
619 ::mlir::OpBuilder &builder, ::mlir::OperationState &state,
620 ::mlir::FunctionType functionType
621 );
622};
623} // namespace verif
624} // namespace llzk
625MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::ContractOp)
626
627namespace llzk {
628namespace verif {
629
630//===----------------------------------------------------------------------===//
631// ::llzk::verif::DecreasesOp declarations
632//===----------------------------------------------------------------------===//
633
634namespace detail {
636public:
637protected:
638 ::mlir::DictionaryAttr odsAttrs;
639 ::std::optional<::mlir::OperationName> odsOpName;
640 ::mlir::RegionRange odsRegions;
641public:
642 DecreasesOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
643 odsOpName.emplace("verif.decreases", odsAttrs.getContext());
644 }
645
646 DecreasesOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
647
648 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
649 return {index, 1};
650 }
651
652 ::mlir::DictionaryAttr getAttributes() {
653 return odsAttrs;
654 }
655
656};
657} // namespace detail
658template <typename RangeT>
660 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
662public:
663 DecreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
664
665 DecreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : DecreasesOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
666
667 DecreasesOpGenericAdaptor(RangeT values, const DecreasesOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
668
669 template <typename LateInst = DecreasesOp, typename = std::enable_if_t<std::is_same_v<LateInst, DecreasesOp>>>
670 DecreasesOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
671
672 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
673 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
674 }
675
676 RangeT getODSOperands(unsigned index) {
677 auto valueRange = getODSOperandIndexAndLength(index);
678 return {std::next(odsOperands.begin(), valueRange.first),
679 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
680 }
681
682 ValueT getValue() {
683 return (*getODSOperands(0).begin());
684 }
685
686 RangeT getOperands() {
687 return odsOperands;
688 }
689
690private:
691 RangeT odsOperands;
692};
693class DecreasesOpAdaptor : public DecreasesOpGenericAdaptor<::mlir::ValueRange> {
694public:
697
698 ::llvm::LogicalResult verify(::mlir::Location loc);
699};
700class DecreasesOp : public ::mlir::Op<DecreasesOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::InvariantOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait> {
701public:
702 using Op::Op;
703 using Op::print;
705 template <typename RangeT>
708 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
709 return {};
710 }
711
712 static constexpr ::llvm::StringLiteral getOperationName() {
713 return ::llvm::StringLiteral("verif.decreases");
714 }
715
716 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
717 return {index, 1};
718 }
719
720 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
721 auto valueRange = getODSOperandIndexAndLength(index);
722 return {std::next(getOperation()->operand_begin(), valueRange.first),
723 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
724 }
725
726 ::mlir::TypedValue<::llzk::felt::FeltType> getValue() {
727 return ::llvm::cast<::mlir::TypedValue<::llzk::felt::FeltType>>(*getODSOperands(0).begin());
728 }
729
730 ::mlir::OpOperand &getValueMutable() {
731 auto range = getODSOperandIndexAndLength(0);
732 return getOperation()->getOpOperand(range.first);
733 }
734
735 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
736 return {index, 1};
737 }
738
739 ::mlir::Operation::result_range getODSResults(unsigned index) {
740 auto valueRange = getODSResultIndexAndLength(index);
741 return {std::next(getOperation()->result_begin(), valueRange.first),
742 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
743 }
744
745 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value);
746 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value value);
747 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
748 ::llvm::LogicalResult verifyInvariantsImpl();
749 ::llvm::LogicalResult verifyInvariants();
750 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
751 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
752 void print(::mlir::OpAsmPrinter &_odsPrinter);
753public:
754};
755} // namespace verif
756} // namespace llzk
757MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::DecreasesOp)
758
759namespace llzk {
760namespace verif {
761
762//===----------------------------------------------------------------------===//
763// ::llzk::verif::EnsureComputeOp declarations
764//===----------------------------------------------------------------------===//
765
766namespace detail {
768public:
769protected:
770 ::mlir::DictionaryAttr odsAttrs;
771 ::std::optional<::mlir::OperationName> odsOpName;
772 ::mlir::RegionRange odsRegions;
773public:
774 EnsureComputeOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
775 odsOpName.emplace("verif.ensure_compute", odsAttrs.getContext());
776 }
777
778 EnsureComputeOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
779
780 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
781 return {index, 1};
782 }
783
784 ::mlir::DictionaryAttr getAttributes() {
785 return odsAttrs;
786 }
787
788};
789} // namespace detail
790template <typename RangeT>
792 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
794public:
795 EnsureComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
796
797 EnsureComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : EnsureComputeOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
798
799 EnsureComputeOpGenericAdaptor(RangeT values, const EnsureComputeOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
800
801 template <typename LateInst = EnsureComputeOp, typename = std::enable_if_t<std::is_same_v<LateInst, EnsureComputeOp>>>
802 EnsureComputeOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
803
804 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
805 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
806 }
807
808 RangeT getODSOperands(unsigned index) {
809 auto valueRange = getODSOperandIndexAndLength(index);
810 return {std::next(odsOperands.begin(), valueRange.first),
811 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
812 }
813
814 ValueT getCondition() {
815 return (*getODSOperands(0).begin());
816 }
817
818 RangeT getOperands() {
819 return odsOperands;
820 }
821
822private:
823 RangeT odsOperands;
824};
825class EnsureComputeOpAdaptor : public EnsureComputeOpGenericAdaptor<::mlir::ValueRange> {
826public:
829
830 ::llvm::LogicalResult verify(::mlir::Location loc);
831};
832class EnsureComputeOp : public ::mlir::Op<EnsureComputeOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait, ::llzk::verif::ConditionOpInterface::Trait, ::llzk::verif::PostconditionOpInterface::Trait> {
833public:
834 using Op::Op;
835 using Op::print;
837 template <typename RangeT>
840 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
841 return {};
842 }
843
844 static constexpr ::llvm::StringLiteral getOperationName() {
845 return ::llvm::StringLiteral("verif.ensure_compute");
846 }
847
848 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
849 return {index, 1};
850 }
851
852 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
853 auto valueRange = getODSOperandIndexAndLength(index);
854 return {std::next(getOperation()->operand_begin(), valueRange.first),
855 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
856 }
857
858 ::mlir::TypedValue<::mlir::IntegerType> getCondition() {
859 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
860 }
861
862 ::mlir::OpOperand &getConditionMutable() {
863 auto range = getODSOperandIndexAndLength(0);
864 return getOperation()->getOpOperand(range.first);
865 }
866
867 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
868 return {index, 1};
869 }
870
871 ::mlir::Operation::result_range getODSResults(unsigned index) {
872 auto valueRange = getODSResultIndexAndLength(index);
873 return {std::next(getOperation()->result_begin(), valueRange.first),
874 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
875 }
876
877 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
878 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
879 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
880 ::llvm::LogicalResult verifyInvariantsImpl();
881 ::llvm::LogicalResult verifyInvariants();
882 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
883 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
884 void print(::mlir::OpAsmPrinter &_odsPrinter);
885public:
886};
887} // namespace verif
888} // namespace llzk
889MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::EnsureComputeOp)
890
891namespace llzk {
892namespace verif {
893
894//===----------------------------------------------------------------------===//
895// ::llzk::verif::EnsureConstrainOp declarations
896//===----------------------------------------------------------------------===//
897
898namespace detail {
900public:
901protected:
902 ::mlir::DictionaryAttr odsAttrs;
903 ::std::optional<::mlir::OperationName> odsOpName;
904 ::mlir::RegionRange odsRegions;
905public:
906 EnsureConstrainOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
907 odsOpName.emplace("verif.ensure_constrain", odsAttrs.getContext());
908 }
909
910 EnsureConstrainOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
911
912 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
913 return {index, 1};
914 }
915
916 ::mlir::DictionaryAttr getAttributes() {
917 return odsAttrs;
918 }
919
920};
921} // namespace detail
922template <typename RangeT>
924 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
926public:
927 EnsureConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
928
929 EnsureConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : EnsureConstrainOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
930
931 EnsureConstrainOpGenericAdaptor(RangeT values, const EnsureConstrainOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
932
933 template <typename LateInst = EnsureConstrainOp, typename = std::enable_if_t<std::is_same_v<LateInst, EnsureConstrainOp>>>
934 EnsureConstrainOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
935
936 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
937 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
938 }
939
940 RangeT getODSOperands(unsigned index) {
941 auto valueRange = getODSOperandIndexAndLength(index);
942 return {std::next(odsOperands.begin(), valueRange.first),
943 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
944 }
945
946 ValueT getCondition() {
947 return (*getODSOperands(0).begin());
948 }
949
950 RangeT getOperands() {
951 return odsOperands;
952 }
953
954private:
955 RangeT odsOperands;
956};
958public:
961
962 ::llvm::LogicalResult verify(::mlir::Location loc);
963};
964class EnsureConstrainOp : public ::mlir::Op<EnsureConstrainOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait, ::llzk::verif::ConditionOpInterface::Trait, ::llzk::verif::PostconditionOpInterface::Trait> {
965public:
966 using Op::Op;
967 using Op::print;
969 template <typename RangeT>
972 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
973 return {};
974 }
975
976 static constexpr ::llvm::StringLiteral getOperationName() {
977 return ::llvm::StringLiteral("verif.ensure_constrain");
978 }
979
980 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
981 return {index, 1};
982 }
983
984 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
985 auto valueRange = getODSOperandIndexAndLength(index);
986 return {std::next(getOperation()->operand_begin(), valueRange.first),
987 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
988 }
989
990 ::mlir::TypedValue<::mlir::IntegerType> getCondition() {
991 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
992 }
993
994 ::mlir::OpOperand &getConditionMutable() {
995 auto range = getODSOperandIndexAndLength(0);
996 return getOperation()->getOpOperand(range.first);
997 }
998
999 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1000 return {index, 1};
1001 }
1002
1003 ::mlir::Operation::result_range getODSResults(unsigned index) {
1004 auto valueRange = getODSResultIndexAndLength(index);
1005 return {std::next(getOperation()->result_begin(), valueRange.first),
1006 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1007 }
1008
1009 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
1010 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
1011 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1012 ::llvm::LogicalResult verifyInvariantsImpl();
1013 ::llvm::LogicalResult verifyInvariants();
1014 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
1015 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1016 void print(::mlir::OpAsmPrinter &_odsPrinter);
1017public:
1018};
1019} // namespace verif
1020} // namespace llzk
1021MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::EnsureConstrainOp)
1022
1023namespace llzk {
1024namespace verif {
1025
1026//===----------------------------------------------------------------------===//
1027// ::llzk::verif::IncludeOp declarations
1028//===----------------------------------------------------------------------===//
1029
1030namespace detail {
1032public:
1033 struct Properties {
1034 using calleeTy = ::mlir::SymbolRefAttr;
1036
1037 auto getCallee() {
1038 auto &propStorage = this->callee;
1039 return ::llvm::cast<::mlir::SymbolRefAttr>(propStorage);
1040 }
1041 void setCallee(const ::mlir::SymbolRefAttr &propValue) {
1042 this->callee = propValue;
1043 }
1044 using mapOpGroupSizesTy = ::mlir::DenseI32ArrayAttr;
1046
1048 auto &propStorage = this->mapOpGroupSizes;
1049 return ::llvm::cast<::mlir::DenseI32ArrayAttr>(propStorage);
1050 }
1051 void setMapOpGroupSizes(const ::mlir::DenseI32ArrayAttr &propValue) {
1052 this->mapOpGroupSizes = propValue;
1053 }
1054 using numDimsPerMapTy = ::mlir::DenseI32ArrayAttr;
1056
1058 auto &propStorage = this->numDimsPerMap;
1059 return ::llvm::dyn_cast_or_null<::mlir::DenseI32ArrayAttr>(propStorage);
1060 }
1061 void setNumDimsPerMap(const ::mlir::DenseI32ArrayAttr &propValue) {
1062 this->numDimsPerMap = propValue;
1063 }
1064 using templateParamsTy = ::mlir::ArrayAttr;
1066
1068 auto &propStorage = this->templateParams;
1069 return ::llvm::dyn_cast_or_null<::mlir::ArrayAttr>(propStorage);
1070 }
1071 void setTemplateParams(const ::mlir::ArrayAttr &propValue) {
1072 this->templateParams = propValue;
1073 }
1074 using operandSegmentSizesTy = std::array<int32_t, 2>;
1076 ::llvm::ArrayRef<int32_t> getOperandSegmentSizes() const {
1077 auto &propStorage = this->operandSegmentSizes;
1078 return propStorage;
1079 }
1080 void setOperandSegmentSizes(::llvm::ArrayRef<int32_t> propValue) {
1081 auto &propStorage = this->operandSegmentSizes;
1082 ::llvm::copy(propValue, propStorage.begin());
1083 }
1084 bool operator==(const Properties &rhs) const {
1085 return
1086 rhs.callee == this->callee &&
1087 rhs.mapOpGroupSizes == this->mapOpGroupSizes &&
1088 rhs.numDimsPerMap == this->numDimsPerMap &&
1089 rhs.templateParams == this->templateParams &&
1090 rhs.operandSegmentSizes == this->operandSegmentSizes &&
1091 true;
1092 }
1093 bool operator!=(const Properties &rhs) const {
1094 return !(*this == rhs);
1095 }
1096 };
1097protected:
1098 ::mlir::DictionaryAttr odsAttrs;
1099 ::std::optional<::mlir::OperationName> odsOpName;
1101 ::mlir::RegionRange odsRegions;
1102public:
1103 IncludeOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
1104 odsOpName.emplace("verif.include", odsAttrs.getContext());
1105 }
1106
1108
1109 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize);
1111 return properties;
1112 }
1113
1114 ::mlir::DictionaryAttr getAttributes() {
1115 return odsAttrs;
1116 }
1117
1118 ::mlir::SymbolRefAttr getCalleeAttr() {
1119 auto attr = ::llvm::cast<::mlir::SymbolRefAttr>(getProperties().callee);
1120 return attr;
1121 }
1122
1123 ::mlir::SymbolRefAttr getCallee();
1124 ::mlir::ArrayAttr getTemplateParamsAttr() {
1125 auto attr = ::llvm::dyn_cast_or_null<::mlir::ArrayAttr>(getProperties().templateParams);
1126 return attr;
1127 }
1128
1129 ::std::optional< ::mlir::ArrayAttr > getTemplateParams();
1130 ::mlir::DenseI32ArrayAttr getNumDimsPerMapAttr();
1131 ::llvm::ArrayRef<int32_t> getNumDimsPerMap();
1132 ::mlir::DenseI32ArrayAttr getMapOpGroupSizesAttr() {
1133 auto attr = ::llvm::cast<::mlir::DenseI32ArrayAttr>(getProperties().mapOpGroupSizes);
1134 return attr;
1135 }
1136
1137 ::llvm::ArrayRef<int32_t> getMapOpGroupSizes();
1138};
1139} // namespace detail
1140template <typename RangeT>
1142 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1144public:
1145 IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1146
1147 IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : IncludeOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
1148
1149 IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs) : IncludeOpGenericAdaptor(values, attrs, Properties{}, {}) {}
1150
1151 IncludeOpGenericAdaptor(RangeT values, const IncludeOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1152
1153 template <typename LateInst = IncludeOp, typename = std::enable_if_t<std::is_same_v<LateInst, IncludeOp>>>
1154 IncludeOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1155
1156 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1157 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1158 }
1159
1160 RangeT getODSOperands(unsigned index) {
1161 auto valueRange = getODSOperandIndexAndLength(index);
1162 return {std::next(odsOperands.begin(), valueRange.first),
1163 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1164 }
1165
1167 return getODSOperands(0);
1168 }
1169
1170 ::llvm::SmallVector<RangeT> getMapOperands() {
1171 auto tblgenTmpOperands = getODSOperands(1);
1172 auto sizes = getMapOpGroupSizes();
1173
1174 ::llvm::SmallVector<RangeT> tblgenTmpOperandGroups;
1175 for (int i = 0, e = sizes.size(); i < e; ++i) {
1176 tblgenTmpOperandGroups.push_back(tblgenTmpOperands.take_front(sizes[i]));
1177 tblgenTmpOperands = tblgenTmpOperands.drop_front(sizes[i]);
1178 }
1179 return tblgenTmpOperandGroups;
1180 }
1181
1182 RangeT getOperands() {
1183 return odsOperands;
1184 }
1185
1186private:
1187 RangeT odsOperands;
1188};
1189class IncludeOpAdaptor : public IncludeOpGenericAdaptor<::mlir::ValueRange> {
1190public:
1193
1194 ::llvm::LogicalResult verify(::mlir::Location loc);
1195};
1196class IncludeOp : public ::mlir::Op<IncludeOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::VariadicOperands, ::mlir::OpTrait::AttrSizedOperandSegments, ::llzk::VerifySizesForMultiAffineOps<1>::Impl, ::llzk::HasAncestor<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::OpTrait::MemRefsNormalizable, ::mlir::CallOpInterface::Trait, ::mlir::SymbolUserOpInterface::Trait> {
1197public:
1198 using Op::Op;
1199 using Op::print;
1201 template <typename RangeT>
1205 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1206 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("callee"), ::llvm::StringRef("mapOpGroupSizes"), ::llvm::StringRef("numDimsPerMap"), ::llvm::StringRef("templateParams"), ::llvm::StringRef("operandSegmentSizes")};
1207 return ::llvm::ArrayRef(attrNames);
1208 }
1209
1210 ::mlir::StringAttr getCalleeAttrName() {
1211 return getAttributeNameForIndex(0);
1212 }
1213
1214 static ::mlir::StringAttr getCalleeAttrName(::mlir::OperationName name) {
1215 return getAttributeNameForIndex(name, 0);
1216 }
1217
1218 ::mlir::StringAttr getMapOpGroupSizesAttrName() {
1219 return getAttributeNameForIndex(1);
1220 }
1221
1222 static ::mlir::StringAttr getMapOpGroupSizesAttrName(::mlir::OperationName name) {
1223 return getAttributeNameForIndex(name, 1);
1224 }
1225
1226 ::mlir::StringAttr getNumDimsPerMapAttrName() {
1227 return getAttributeNameForIndex(2);
1228 }
1229
1230 static ::mlir::StringAttr getNumDimsPerMapAttrName(::mlir::OperationName name) {
1231 return getAttributeNameForIndex(name, 2);
1232 }
1233
1234 ::mlir::StringAttr getTemplateParamsAttrName() {
1235 return getAttributeNameForIndex(3);
1236 }
1237
1238 static ::mlir::StringAttr getTemplateParamsAttrName(::mlir::OperationName name) {
1239 return getAttributeNameForIndex(name, 3);
1240 }
1241
1242 ::mlir::StringAttr getOperandSegmentSizesAttrName() {
1243 return (*this)->getName().getAttributeNames().back();
1244 }
1245
1246 static ::mlir::StringAttr getOperandSegmentSizesAttrName(::mlir::OperationName name) {
1247 return name.getAttributeNames().back();
1248 }
1249
1250 static constexpr ::llvm::StringLiteral getOperationName() {
1251 return ::llvm::StringLiteral("verif.include");
1252 }
1253
1254 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index);
1255 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1256 auto valueRange = getODSOperandIndexAndLength(index);
1257 return {std::next(getOperation()->operand_begin(), valueRange.first),
1258 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1259 }
1260
1261 ::mlir::Operation::operand_range getArgOperands() {
1262 return getODSOperands(0);
1263 }
1264
1265 ::mlir::OperandRangeRange getMapOperands() {
1266 return getODSOperands(1).split(getMapOpGroupSizesAttr());
1267 }
1268
1269 ::mlir::MutableOperandRange getArgOperandsMutable();
1270 ::mlir::MutableOperandRangeRange getMapOperandsMutable();
1271 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1272 return {index, 1};
1273 }
1274
1275 ::mlir::Operation::result_range getODSResults(unsigned index) {
1276 auto valueRange = getODSResultIndexAndLength(index);
1277 return {std::next(getOperation()->result_begin(), valueRange.first),
1278 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1279 }
1280
1281 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1282 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
1283 static llvm::hash_code computePropertiesHash(const Properties &prop);
1284 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
1285 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
1286 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
1287 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1288 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
1289 void writeProperties(::mlir::DialectBytecodeWriter &writer);
1290 ::mlir::SymbolRefAttr getCalleeAttr() {
1291 return ::llvm::cast<::mlir::SymbolRefAttr>(getProperties().callee);
1292 }
1293
1294 ::mlir::SymbolRefAttr getCallee();
1295 ::mlir::ArrayAttr getTemplateParamsAttr() {
1296 return ::llvm::dyn_cast_or_null<::mlir::ArrayAttr>(getProperties().templateParams);
1297 }
1298
1299 ::std::optional< ::mlir::ArrayAttr > getTemplateParams();
1300 ::mlir::DenseI32ArrayAttr getNumDimsPerMapAttr() {
1301 return ::llvm::dyn_cast_or_null<::mlir::DenseI32ArrayAttr>(getProperties().numDimsPerMap);
1302 }
1303
1304 ::llvm::ArrayRef<int32_t> getNumDimsPerMap();
1305 ::mlir::DenseI32ArrayAttr getMapOpGroupSizesAttr() {
1306 return ::llvm::cast<::mlir::DenseI32ArrayAttr>(getProperties().mapOpGroupSizes);
1307 }
1308
1309 ::llvm::ArrayRef<int32_t> getMapOpGroupSizes();
1310 void setCalleeAttr(::mlir::SymbolRefAttr attr) {
1311 getProperties().callee = attr;
1312 }
1313
1314 void setTemplateParamsAttr(::mlir::ArrayAttr attr) {
1315 getProperties().templateParams = attr;
1316 }
1317
1318 void setNumDimsPerMapAttr(::mlir::DenseI32ArrayAttr attr) {
1319 getProperties().numDimsPerMap = attr;
1320 }
1321
1322 void setNumDimsPerMap(::llvm::ArrayRef<int32_t> attrValue);
1323 void setMapOpGroupSizesAttr(::mlir::DenseI32ArrayAttr attr) {
1324 getProperties().mapOpGroupSizes = attr;
1325 }
1326
1327 void setMapOpGroupSizes(::llvm::ArrayRef<int32_t> attrValue);
1328 ::mlir::Attribute removeTemplateParamsAttr() {
1329 auto &attr = getProperties().templateParams;
1330 attr = {};
1331 return attr;
1332 }
1333
1334 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::SymbolRefAttr callee, ::mlir::ValueRange argOperands = {}, ::llvm::ArrayRef<::mlir::Attribute> templateParams = {});
1335 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::SymbolRefAttr callee, ::llvm::ArrayRef<::mlir::ValueRange> mapOperands, ::mlir::DenseI32ArrayAttr numDimsPerMap, ::mlir::ValueRange argOperands = {}, ::llvm::ArrayRef<::mlir::Attribute> templateParams = {});
1336 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::SymbolRefAttr callee, ::llvm::ArrayRef<::mlir::ValueRange> mapOperands, ::llvm::ArrayRef<int32_t> numDimsPerMap, ::mlir::ValueRange argOperands = {}, ::llvm::ArrayRef<::mlir::Attribute> templateParams = {});
1337 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llzk::verif::ContractOp callee, ::mlir::ValueRange argOperands = {}, ::llvm::ArrayRef<::mlir::Attribute> templateParams = {});
1338 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llzk::verif::ContractOp callee, ::llvm::ArrayRef<::mlir::ValueRange> mapOperands, ::mlir::DenseI32ArrayAttr numDimsPerMap, ::mlir::ValueRange argOperands = {}, ::llvm::ArrayRef<::mlir::Attribute> templateParams = {});
1339 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llzk::verif::ContractOp callee, ::llvm::ArrayRef<::mlir::ValueRange> mapOperands, ::llvm::ArrayRef<int32_t> numDimsPerMap, ::mlir::ValueRange argOperands = {}, ::llvm::ArrayRef<::mlir::Attribute> templateParams = {});
1340 static void populateDefaultProperties(::mlir::OperationName opName, Properties &properties);
1341 ::llvm::LogicalResult verifyInvariantsImpl();
1342 ::llvm::LogicalResult verifyInvariants();
1343 ::mlir::CallInterfaceCallable getCallableForCallee();
1344 void setCalleeFromCallable(::mlir::CallInterfaceCallable callee);
1345 ::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable);
1346 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1347 static ::llvm::LogicalResult setPropertiesFromParsedAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1348 void print(::mlir::OpAsmPrinter &_odsPrinter);
1349private:
1350 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
1351 return getAttributeNameForIndex((*this)->getName(), index);
1352 }
1353
1354 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
1355 assert(index < 4 && "invalid attribute index");
1356 assert(name.getStringRef() == getOperationName() && "invalid operation name");
1357 assert(name.isRegistered() && "Operation isn't registered, missing a "
1358 "dependent dialect loading?");
1359 return name.getAttributeNames()[index];
1360 }
1361
1362public:
1364 ::mlir::Operation *resolveCallableInTable(::mlir::SymbolTableCollection *symbolTable);
1365
1367 ::mlir::Operation *resolveCallable();
1368
1372 ::mlir::FunctionType getTypeSignature();
1373
1377 ::mlir::FailureOr<UnificationMap> unifyTypeSignature(::mlir::FunctionType other);
1378
1380 bool contractTargetsStruct();
1381
1384 ::mlir::Value getSelfValue();
1385
1387 ::mlir::FailureOr<::llzk::SymbolLookupResult<::llzk::verif::ContractOp>>
1388 getCalleeTarget(::mlir::SymbolTableCollection &tables);
1389
1392 static ::llvm::SmallVector<::mlir::ValueRange> toVectorOfValueRange(::mlir::OperandRangeRange);
1393
1397 ::mlir::Attribute paramFromCallOp, ::llzk::polymorphic::TemplateParamOp targetParam
1398 );
1399
1407 ::llvm::iterator_range<::mlir::Region::op_iterator<::llzk::polymorphic::TemplateParamOp>> targetParamDefs
1408 );
1409
1418 ::mlir::LogicalResult verifyTemplateParamsMatchInferred(
1419 ::llvm::iterator_range<::mlir::Region::op_iterator<::llzk::polymorphic::TemplateParamOp>> targetParamDefs,
1420 const UnificationMap &unifications
1421 );
1422};
1423} // namespace verif
1424} // namespace llzk
1425MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::IncludeOp)
1426
1427namespace llzk {
1428namespace verif {
1429
1430//===----------------------------------------------------------------------===//
1431// ::llzk::verif::IncreasesOp declarations
1432//===----------------------------------------------------------------------===//
1433
1434namespace detail {
1436public:
1437protected:
1438 ::mlir::DictionaryAttr odsAttrs;
1439 ::std::optional<::mlir::OperationName> odsOpName;
1440 ::mlir::RegionRange odsRegions;
1441public:
1442 IncreasesOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
1443 odsOpName.emplace("verif.increases", odsAttrs.getContext());
1444 }
1445
1446 IncreasesOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
1447
1448 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1449 return {index, 1};
1450 }
1451
1452 ::mlir::DictionaryAttr getAttributes() {
1453 return odsAttrs;
1454 }
1455
1456};
1457} // namespace detail
1458template <typename RangeT>
1460 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1462public:
1463 IncreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1464
1465 IncreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : IncreasesOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
1466
1467 IncreasesOpGenericAdaptor(RangeT values, const IncreasesOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1468
1469 template <typename LateInst = IncreasesOp, typename = std::enable_if_t<std::is_same_v<LateInst, IncreasesOp>>>
1470 IncreasesOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1471
1472 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1473 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1474 }
1475
1476 RangeT getODSOperands(unsigned index) {
1477 auto valueRange = getODSOperandIndexAndLength(index);
1478 return {std::next(odsOperands.begin(), valueRange.first),
1479 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1480 }
1481
1482 ValueT getValue() {
1483 return (*getODSOperands(0).begin());
1484 }
1485
1486 RangeT getOperands() {
1487 return odsOperands;
1488 }
1489
1490private:
1491 RangeT odsOperands;
1492};
1493class IncreasesOpAdaptor : public IncreasesOpGenericAdaptor<::mlir::ValueRange> {
1494public:
1497
1498 ::llvm::LogicalResult verify(::mlir::Location loc);
1499};
1500class IncreasesOp : public ::mlir::Op<IncreasesOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::InvariantOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait> {
1501public:
1502 using Op::Op;
1503 using Op::print;
1505 template <typename RangeT>
1508 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1509 return {};
1510 }
1511
1512 static constexpr ::llvm::StringLiteral getOperationName() {
1513 return ::llvm::StringLiteral("verif.increases");
1514 }
1515
1516 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1517 return {index, 1};
1518 }
1519
1520 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1521 auto valueRange = getODSOperandIndexAndLength(index);
1522 return {std::next(getOperation()->operand_begin(), valueRange.first),
1523 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1524 }
1525
1526 ::mlir::TypedValue<::llzk::felt::FeltType> getValue() {
1527 return ::llvm::cast<::mlir::TypedValue<::llzk::felt::FeltType>>(*getODSOperands(0).begin());
1528 }
1529
1530 ::mlir::OpOperand &getValueMutable() {
1531 auto range = getODSOperandIndexAndLength(0);
1532 return getOperation()->getOpOperand(range.first);
1533 }
1534
1535 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1536 return {index, 1};
1537 }
1538
1539 ::mlir::Operation::result_range getODSResults(unsigned index) {
1540 auto valueRange = getODSResultIndexAndLength(index);
1541 return {std::next(getOperation()->result_begin(), valueRange.first),
1542 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1543 }
1544
1545 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value);
1546 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value value);
1547 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1548 ::llvm::LogicalResult verifyInvariantsImpl();
1549 ::llvm::LogicalResult verifyInvariants();
1550 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
1551 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1552 void print(::mlir::OpAsmPrinter &_odsPrinter);
1553public:
1554};
1555} // namespace verif
1556} // namespace llzk
1557MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::IncreasesOp)
1558
1559namespace llzk {
1560namespace verif {
1561
1562//===----------------------------------------------------------------------===//
1563// ::llzk::verif::InvariantOp declarations
1564//===----------------------------------------------------------------------===//
1565
1566namespace detail {
1568public:
1569 struct Properties {
1570 using loop_arg_typesTy = ::mlir::ArrayAttr;
1572
1574 auto &propStorage = this->loop_arg_types;
1575 return ::llvm::cast<::mlir::ArrayAttr>(propStorage);
1576 }
1577 void setLoopArgTypes(const ::mlir::ArrayAttr &propValue) {
1578 this->loop_arg_types = propValue;
1579 }
1580 using loop_nameTy = ::mlir::StringAttr;
1582
1584 auto &propStorage = this->loop_name;
1585 return ::llvm::cast<::mlir::StringAttr>(propStorage);
1586 }
1587 void setLoopName(const ::mlir::StringAttr &propValue) {
1588 this->loop_name = propValue;
1589 }
1590 bool operator==(const Properties &rhs) const {
1591 return
1592 rhs.loop_arg_types == this->loop_arg_types &&
1593 rhs.loop_name == this->loop_name &&
1594 true;
1595 }
1596 bool operator!=(const Properties &rhs) const {
1597 return !(*this == rhs);
1598 }
1599 };
1600protected:
1601 ::mlir::DictionaryAttr odsAttrs;
1602 ::std::optional<::mlir::OperationName> odsOpName;
1604 ::mlir::RegionRange odsRegions;
1605public:
1606 InvariantOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
1607 odsOpName.emplace("verif.invariant", odsAttrs.getContext());
1608 }
1609
1611
1612 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1613 return {index, 1};
1614 }
1615
1617 return properties;
1618 }
1619
1620 ::mlir::DictionaryAttr getAttributes() {
1621 return odsAttrs;
1622 }
1623
1624 ::mlir::StringAttr getLoopNameAttr() {
1625 auto attr = ::llvm::cast<::mlir::StringAttr>(getProperties().loop_name);
1626 return attr;
1627 }
1628
1629 ::llvm::StringRef getLoopName();
1630 ::mlir::ArrayAttr getLoopArgTypesAttr() {
1631 auto attr = ::llvm::cast<::mlir::ArrayAttr>(getProperties().loop_arg_types);
1632 return attr;
1633 }
1634
1635 ::mlir::ArrayAttr getLoopArgTypes();
1636 ::mlir::Region &getRegion() {
1637 return *odsRegions[0];
1638 }
1639
1640 ::mlir::RegionRange getRegions() {
1641 return odsRegions;
1642 }
1643
1644};
1645} // namespace detail
1646template <typename RangeT>
1648 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1650public:
1651 InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1652
1653 InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : InvariantOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
1654
1655 InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : InvariantOpGenericAdaptor(values, attrs, Properties{}, {}) {}
1656
1657 InvariantOpGenericAdaptor(RangeT values, const InvariantOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1658
1659 template <typename LateInst = InvariantOp, typename = std::enable_if_t<std::is_same_v<LateInst, InvariantOp>>>
1660 InvariantOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1661
1662 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1663 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1664 }
1665
1666 RangeT getODSOperands(unsigned index) {
1667 auto valueRange = getODSOperandIndexAndLength(index);
1668 return {std::next(odsOperands.begin(), valueRange.first),
1669 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1670 }
1671
1672 RangeT getOperands() {
1673 return odsOperands;
1674 }
1675
1676private:
1677 RangeT odsOperands;
1678};
1679class InvariantOpAdaptor : public InvariantOpGenericAdaptor<::mlir::ValueRange> {
1680public:
1683
1684 ::llvm::LogicalResult verify(::mlir::Location loc);
1685};
1686class InvariantOp : public ::mlir::Op<InvariantOp, ::mlir::OpTrait::OneRegion, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::llzk::HasAncestor<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::NoTerminator, ::mlir::OpTrait::SingleBlock, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait> {
1687public:
1688 using Op::Op;
1689 using Op::print;
1691 template <typename RangeT>
1695 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1696 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("loop_arg_types"), ::llvm::StringRef("loop_name")};
1697 return ::llvm::ArrayRef(attrNames);
1698 }
1699
1700 ::mlir::StringAttr getLoopArgTypesAttrName() {
1701 return getAttributeNameForIndex(0);
1702 }
1703
1704 static ::mlir::StringAttr getLoopArgTypesAttrName(::mlir::OperationName name) {
1705 return getAttributeNameForIndex(name, 0);
1706 }
1707
1708 ::mlir::StringAttr getLoopNameAttrName() {
1709 return getAttributeNameForIndex(1);
1710 }
1711
1712 static ::mlir::StringAttr getLoopNameAttrName(::mlir::OperationName name) {
1713 return getAttributeNameForIndex(name, 1);
1714 }
1715
1716 static constexpr ::llvm::StringLiteral getOperationName() {
1717 return ::llvm::StringLiteral("verif.invariant");
1718 }
1719
1720 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1721 return {index, 1};
1722 }
1723
1724 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1725 auto valueRange = getODSOperandIndexAndLength(index);
1726 return {std::next(getOperation()->operand_begin(), valueRange.first),
1727 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1728 }
1729
1730 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1731 return {index, 1};
1732 }
1733
1734 ::mlir::Operation::result_range getODSResults(unsigned index) {
1735 auto valueRange = getODSResultIndexAndLength(index);
1736 return {std::next(getOperation()->result_begin(), valueRange.first),
1737 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1738 }
1739
1740 ::mlir::Region &getRegion() {
1741 return (*this)->getRegion(0);
1742 }
1743
1744 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1745 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
1746 static llvm::hash_code computePropertiesHash(const Properties &prop);
1747 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
1748 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
1749 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
1750 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1751 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
1752 void writeProperties(::mlir::DialectBytecodeWriter &writer);
1753 ::mlir::StringAttr getLoopNameAttr() {
1754 return ::llvm::cast<::mlir::StringAttr>(getProperties().loop_name);
1755 }
1756
1757 ::llvm::StringRef getLoopName();
1758 ::mlir::ArrayAttr getLoopArgTypesAttr() {
1759 return ::llvm::cast<::mlir::ArrayAttr>(getProperties().loop_arg_types);
1760 }
1761
1762 ::mlir::ArrayAttr getLoopArgTypes();
1763 void setLoopNameAttr(::mlir::StringAttr attr) {
1764 getProperties().loop_name = attr;
1765 }
1766
1767 void setLoopName(::llvm::StringRef attrValue);
1768 void setLoopArgTypesAttr(::mlir::ArrayAttr attr) {
1769 getProperties().loop_arg_types = attr;
1770 }
1771
1772 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringRef loop_name, ::llvm::ArrayRef<::mlir::Type> loop_arg_types = {}, ::llvm::ArrayRef<::mlir::Location> loop_arg_locs = {});
1773 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1774 void print(::mlir::OpAsmPrinter &p);
1775 ::llvm::LogicalResult verifyInvariantsImpl();
1776 ::llvm::LogicalResult verifyInvariants();
1777 ::llvm::LogicalResult verify();
1778private:
1779 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
1780 return getAttributeNameForIndex((*this)->getName(), index);
1781 }
1782
1783 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
1784 assert(index < 2 && "invalid attribute index");
1785 assert(name.getStringRef() == getOperationName() && "invalid operation name");
1786 assert(name.isRegistered() && "Operation isn't registered, missing a "
1787 "dependent dialect loading?");
1788 return name.getAttributeNames()[index];
1789 }
1790
1791public:
1793 ::llzk::verif::ContractOp getParentContract();
1795 ::mlir::FailureOr<::llzk::verif::InvariantTargetOpInterface> getTarget();
1796};
1797} // namespace verif
1798} // namespace llzk
1799MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::InvariantOp)
1800
1801namespace llzk {
1802namespace verif {
1803
1804//===----------------------------------------------------------------------===//
1805// ::llzk::verif::OldOp declarations
1806//===----------------------------------------------------------------------===//
1807
1808namespace detail {
1810public:
1811protected:
1812 ::mlir::DictionaryAttr odsAttrs;
1813 ::std::optional<::mlir::OperationName> odsOpName;
1814 ::mlir::RegionRange odsRegions;
1815public:
1816 OldOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
1817 odsOpName.emplace("verif.old", odsAttrs.getContext());
1818 }
1819
1820 OldOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
1821
1822 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1823 return {index, 1};
1824 }
1825
1826 ::mlir::DictionaryAttr getAttributes() {
1827 return odsAttrs;
1828 }
1829
1830};
1831} // namespace detail
1832template <typename RangeT>
1834 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1836public:
1837 OldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1838
1839 OldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : OldOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
1840
1841 OldOpGenericAdaptor(RangeT values, const OldOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1842
1843 template <typename LateInst = OldOp, typename = std::enable_if_t<std::is_same_v<LateInst, OldOp>>>
1844 OldOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1845
1846 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1847 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1848 }
1849
1850 RangeT getODSOperands(unsigned index) {
1851 auto valueRange = getODSOperandIndexAndLength(index);
1852 return {std::next(odsOperands.begin(), valueRange.first),
1853 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1854 }
1855
1856 ValueT getValue() {
1857 return (*getODSOperands(0).begin());
1858 }
1859
1860 RangeT getOperands() {
1861 return odsOperands;
1862 }
1863
1864private:
1865 RangeT odsOperands;
1866};
1867class OldOpAdaptor : public OldOpGenericAdaptor<::mlir::ValueRange> {
1868public:
1870 OldOpAdaptor(OldOp op);
1871
1872 ::llvm::LogicalResult verify(::mlir::Location loc);
1873};
1874class OldOp : public ::mlir::Op<OldOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::OneResult, ::mlir::OpTrait::OneTypedResult<::mlir::Type>::Impl, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::StepOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait, ::mlir::InferTypeOpInterface::Trait> {
1875public:
1876 using Op::Op;
1877 using Op::print;
1879 template <typename RangeT>
1882 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1883 return {};
1884 }
1885
1886 static constexpr ::llvm::StringLiteral getOperationName() {
1887 return ::llvm::StringLiteral("verif.old");
1888 }
1889
1890 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1891 return {index, 1};
1892 }
1893
1894 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1895 auto valueRange = getODSOperandIndexAndLength(index);
1896 return {std::next(getOperation()->operand_begin(), valueRange.first),
1897 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1898 }
1899
1900 ::mlir::TypedValue<::mlir::Type> getValue() {
1901 return ::llvm::cast<::mlir::TypedValue<::mlir::Type>>(*getODSOperands(0).begin());
1902 }
1903
1904 ::mlir::OpOperand &getValueMutable() {
1905 auto range = getODSOperandIndexAndLength(0);
1906 return getOperation()->getOpOperand(range.first);
1907 }
1908
1909 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1910 return {index, 1};
1911 }
1912
1913 ::mlir::Operation::result_range getODSResults(unsigned index) {
1914 auto valueRange = getODSResultIndexAndLength(index);
1915 return {std::next(getOperation()->result_begin(), valueRange.first),
1916 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1917 }
1918
1919 ::mlir::TypedValue<::mlir::Type> getResult() {
1920 return ::llvm::cast<::mlir::TypedValue<::mlir::Type>>(*getODSResults(0).begin());
1921 }
1922
1923 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value value);
1924 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value);
1925 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value value);
1926 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1927 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1928 ::llvm::LogicalResult verifyInvariantsImpl();
1929 ::llvm::LogicalResult verifyInvariants();
1930 static ::llvm::LogicalResult inferReturnTypes(::mlir::MLIRContext *context, ::std::optional<::mlir::Location> location, ::mlir::ValueRange operands, ::mlir::DictionaryAttr attributes, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions, ::llvm::SmallVectorImpl<::mlir::Type>&inferredReturnTypes);
1931 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1932 void print(::mlir::OpAsmPrinter &_odsPrinter);
1933 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
1934public:
1935};
1936} // namespace verif
1937} // namespace llzk
1938MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::OldOp)
1939
1940namespace llzk {
1941namespace verif {
1942
1943//===----------------------------------------------------------------------===//
1944// ::llzk::verif::RequireComputeOp declarations
1945//===----------------------------------------------------------------------===//
1946
1947namespace detail {
1949public:
1950protected:
1951 ::mlir::DictionaryAttr odsAttrs;
1952 ::std::optional<::mlir::OperationName> odsOpName;
1953 ::mlir::RegionRange odsRegions;
1954public:
1955 RequireComputeOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
1956 odsOpName.emplace("verif.require_compute", odsAttrs.getContext());
1957 }
1958
1959 RequireComputeOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
1960
1961 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1962 return {index, 1};
1963 }
1964
1965 ::mlir::DictionaryAttr getAttributes() {
1966 return odsAttrs;
1967 }
1968
1969};
1970} // namespace detail
1971template <typename RangeT>
1973 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1975public:
1976 RequireComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1977
1978 RequireComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : RequireComputeOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
1979
1980 RequireComputeOpGenericAdaptor(RangeT values, const RequireComputeOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1981
1982 template <typename LateInst = RequireComputeOp, typename = std::enable_if_t<std::is_same_v<LateInst, RequireComputeOp>>>
1983 RequireComputeOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1984
1985 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1986 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1987 }
1988
1989 RangeT getODSOperands(unsigned index) {
1990 auto valueRange = getODSOperandIndexAndLength(index);
1991 return {std::next(odsOperands.begin(), valueRange.first),
1992 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1993 }
1994
1995 ValueT getCondition() {
1996 return (*getODSOperands(0).begin());
1997 }
1998
1999 RangeT getOperands() {
2000 return odsOperands;
2001 }
2002
2003private:
2004 RangeT odsOperands;
2005};
2007public:
2010
2011 ::llvm::LogicalResult verify(::mlir::Location loc);
2012};
2013class RequireComputeOp : public ::mlir::Op<RequireComputeOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait, ::llzk::verif::ConditionOpInterface::Trait, ::llzk::verif::PreconditionOpInterface::Trait> {
2014public:
2015 using Op::Op;
2016 using Op::print;
2018 template <typename RangeT>
2021 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2022 return {};
2023 }
2024
2025 static constexpr ::llvm::StringLiteral getOperationName() {
2026 return ::llvm::StringLiteral("verif.require_compute");
2027 }
2028
2029 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2030 return {index, 1};
2031 }
2032
2033 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2034 auto valueRange = getODSOperandIndexAndLength(index);
2035 return {std::next(getOperation()->operand_begin(), valueRange.first),
2036 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2037 }
2038
2039 ::mlir::TypedValue<::mlir::IntegerType> getCondition() {
2040 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
2041 }
2042
2043 ::mlir::OpOperand &getConditionMutable() {
2044 auto range = getODSOperandIndexAndLength(0);
2045 return getOperation()->getOpOperand(range.first);
2046 }
2047
2048 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2049 return {index, 1};
2050 }
2051
2052 ::mlir::Operation::result_range getODSResults(unsigned index) {
2053 auto valueRange = getODSResultIndexAndLength(index);
2054 return {std::next(getOperation()->result_begin(), valueRange.first),
2055 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2056 }
2057
2058 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
2059 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
2060 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2061 ::llvm::LogicalResult verifyInvariantsImpl();
2062 ::llvm::LogicalResult verifyInvariants();
2063 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
2064 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2065 void print(::mlir::OpAsmPrinter &_odsPrinter);
2066public:
2067};
2068} // namespace verif
2069} // namespace llzk
2070MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::RequireComputeOp)
2071
2072namespace llzk {
2073namespace verif {
2074
2075//===----------------------------------------------------------------------===//
2076// ::llzk::verif::RequireConstrainOp declarations
2077//===----------------------------------------------------------------------===//
2078
2079namespace detail {
2081public:
2082protected:
2083 ::mlir::DictionaryAttr odsAttrs;
2084 ::std::optional<::mlir::OperationName> odsOpName;
2085 ::mlir::RegionRange odsRegions;
2086public:
2087 RequireConstrainOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
2088 odsOpName.emplace("verif.require_constrain", odsAttrs.getContext());
2089 }
2090
2091 RequireConstrainOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
2092
2093 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
2094 return {index, 1};
2095 }
2096
2097 ::mlir::DictionaryAttr getAttributes() {
2098 return odsAttrs;
2099 }
2100
2101};
2102} // namespace detail
2103template <typename RangeT>
2105 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
2107public:
2108 RequireConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
2109
2110 RequireConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : RequireConstrainOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
2111
2112 RequireConstrainOpGenericAdaptor(RangeT values, const RequireConstrainOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
2113
2114 template <typename LateInst = RequireConstrainOp, typename = std::enable_if_t<std::is_same_v<LateInst, RequireConstrainOp>>>
2115 RequireConstrainOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
2116
2117 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2118 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
2119 }
2120
2121 RangeT getODSOperands(unsigned index) {
2122 auto valueRange = getODSOperandIndexAndLength(index);
2123 return {std::next(odsOperands.begin(), valueRange.first),
2124 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
2125 }
2126
2127 ValueT getCondition() {
2128 return (*getODSOperands(0).begin());
2129 }
2130
2131 RangeT getOperands() {
2132 return odsOperands;
2133 }
2134
2135private:
2136 RangeT odsOperands;
2137};
2139public:
2142
2143 ::llvm::LogicalResult verify(::mlir::Location loc);
2144};
2145class RequireConstrainOp : public ::mlir::Op<RequireConstrainOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::llzk::HasAncestor<::llzk::verif::ContractOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait, ::llzk::verif::ConditionOpInterface::Trait, ::llzk::verif::PreconditionOpInterface::Trait> {
2146public:
2147 using Op::Op;
2148 using Op::print;
2150 template <typename RangeT>
2153 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2154 return {};
2155 }
2156
2157 static constexpr ::llvm::StringLiteral getOperationName() {
2158 return ::llvm::StringLiteral("verif.require_constrain");
2159 }
2160
2161 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2162 return {index, 1};
2163 }
2164
2165 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2166 auto valueRange = getODSOperandIndexAndLength(index);
2167 return {std::next(getOperation()->operand_begin(), valueRange.first),
2168 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2169 }
2170
2171 ::mlir::TypedValue<::mlir::IntegerType> getCondition() {
2172 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
2173 }
2174
2175 ::mlir::OpOperand &getConditionMutable() {
2176 auto range = getODSOperandIndexAndLength(0);
2177 return getOperation()->getOpOperand(range.first);
2178 }
2179
2180 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2181 return {index, 1};
2182 }
2183
2184 ::mlir::Operation::result_range getODSResults(unsigned index) {
2185 auto valueRange = getODSResultIndexAndLength(index);
2186 return {std::next(getOperation()->result_begin(), valueRange.first),
2187 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2188 }
2189
2190 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
2191 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
2192 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2193 ::llvm::LogicalResult verifyInvariantsImpl();
2194 ::llvm::LogicalResult verifyInvariants();
2195 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
2196 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2197 void print(::mlir::OpAsmPrinter &_odsPrinter);
2198public:
2199};
2200} // namespace verif
2201} // namespace llzk
2202MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::RequireConstrainOp)
2203
2204namespace llzk {
2205namespace verif {
2206
2207//===----------------------------------------------------------------------===//
2208// ::llzk::verif::StepOp declarations
2209//===----------------------------------------------------------------------===//
2210
2211namespace detail {
2213public:
2214protected:
2215 ::mlir::DictionaryAttr odsAttrs;
2216 ::std::optional<::mlir::OperationName> odsOpName;
2217 ::mlir::RegionRange odsRegions;
2218public:
2219 StepOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
2220 odsOpName.emplace("verif.step", odsAttrs.getContext());
2221 }
2222
2223 StepOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
2224
2225 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
2226 return {index, 1};
2227 }
2228
2229 ::mlir::DictionaryAttr getAttributes() {
2230 return odsAttrs;
2231 }
2232
2233 ::mlir::Region &getRegion() {
2234 return *odsRegions[0];
2235 }
2236
2237 ::mlir::RegionRange getRegions() {
2238 return odsRegions;
2239 }
2240
2241};
2242} // namespace detail
2243template <typename RangeT>
2245 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
2247public:
2248 StepOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
2249
2250 StepOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : StepOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
2251
2252 StepOpGenericAdaptor(RangeT values, const StepOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
2253
2254 template <typename LateInst = StepOp, typename = std::enable_if_t<std::is_same_v<LateInst, StepOp>>>
2255 StepOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
2256
2257 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2258 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
2259 }
2260
2261 RangeT getODSOperands(unsigned index) {
2262 auto valueRange = getODSOperandIndexAndLength(index);
2263 return {std::next(odsOperands.begin(), valueRange.first),
2264 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
2265 }
2266
2267 RangeT getOperands() {
2268 return odsOperands;
2269 }
2270
2271private:
2272 RangeT odsOperands;
2273};
2274class StepOpAdaptor : public StepOpGenericAdaptor<::mlir::ValueRange> {
2275public:
2278
2279 ::llvm::LogicalResult verify(::mlir::Location loc);
2280};
2281class StepOp : public ::mlir::Op<StepOp, ::mlir::OpTrait::OneRegion, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::llzk::HasAncestor<::llzk::verif::InvariantOp>::Impl, ::mlir::OpTrait::NoRegionArguments, ::mlir::OpTrait::SingleBlock, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait> {
2282public:
2283 using Op::Op;
2284 using Op::print;
2286 template <typename RangeT>
2289 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2290 return {};
2291 }
2292
2293 static constexpr ::llvm::StringLiteral getOperationName() {
2294 return ::llvm::StringLiteral("verif.step");
2295 }
2296
2297 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2298 return {index, 1};
2299 }
2300
2301 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2302 auto valueRange = getODSOperandIndexAndLength(index);
2303 return {std::next(getOperation()->operand_begin(), valueRange.first),
2304 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2305 }
2306
2307 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2308 return {index, 1};
2309 }
2310
2311 ::mlir::Operation::result_range getODSResults(unsigned index) {
2312 auto valueRange = getODSResultIndexAndLength(index);
2313 return {std::next(getOperation()->result_begin(), valueRange.first),
2314 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2315 }
2316
2317 ::mlir::Region &getRegion() {
2318 return (*this)->getRegion(0);
2319 }
2320
2321 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState);
2322 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes);
2323 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2324 ::llvm::LogicalResult verifyInvariantsImpl();
2325 ::llvm::LogicalResult verifyInvariants();
2326 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
2327 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2328 void print(::mlir::OpAsmPrinter &_odsPrinter);
2329public:
2330};
2331} // namespace verif
2332} // namespace llzk
2333MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::StepOp)
2334
2335namespace llzk {
2336namespace verif {
2337
2338//===----------------------------------------------------------------------===//
2339// ::llzk::verif::StepYieldOp declarations
2340//===----------------------------------------------------------------------===//
2341
2342namespace detail {
2344public:
2345protected:
2346 ::mlir::DictionaryAttr odsAttrs;
2347 ::std::optional<::mlir::OperationName> odsOpName;
2348 ::mlir::RegionRange odsRegions;
2349public:
2350 StepYieldOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
2351 odsOpName.emplace("verif.step.yield", odsAttrs.getContext());
2352 }
2353
2354 StepYieldOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
2355
2356 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
2357 return {index, 1};
2358 }
2359
2360 ::mlir::DictionaryAttr getAttributes() {
2361 return odsAttrs;
2362 }
2363
2364};
2365} // namespace detail
2366template <typename RangeT>
2368 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
2370public:
2371 StepYieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
2372
2373 StepYieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : StepYieldOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
2374
2375 StepYieldOpGenericAdaptor(RangeT values, const StepYieldOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
2376
2377 template <typename LateInst = StepYieldOp, typename = std::enable_if_t<std::is_same_v<LateInst, StepYieldOp>>>
2378 StepYieldOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
2379
2380 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2381 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
2382 }
2383
2384 RangeT getODSOperands(unsigned index) {
2385 auto valueRange = getODSOperandIndexAndLength(index);
2386 return {std::next(odsOperands.begin(), valueRange.first),
2387 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
2388 }
2389
2390 ValueT getValue() {
2391 return (*getODSOperands(0).begin());
2392 }
2393
2394 RangeT getOperands() {
2395 return odsOperands;
2396 }
2397
2398private:
2399 RangeT odsOperands;
2400};
2401class StepYieldOpAdaptor : public StepYieldOpGenericAdaptor<::mlir::ValueRange> {
2402public:
2405
2406 ::llvm::LogicalResult verify(::mlir::Location loc);
2407};
2408class StepYieldOp : public ::mlir::Op<StepYieldOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::HasParent<StepOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::OpTrait::IsTerminator> {
2409public:
2410 using Op::Op;
2411 using Op::print;
2413 template <typename RangeT>
2416 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2417 return {};
2418 }
2419
2420 static constexpr ::llvm::StringLiteral getOperationName() {
2421 return ::llvm::StringLiteral("verif.step.yield");
2422 }
2423
2424 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2425 return {index, 1};
2426 }
2427
2428 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2429 auto valueRange = getODSOperandIndexAndLength(index);
2430 return {std::next(getOperation()->operand_begin(), valueRange.first),
2431 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2432 }
2433
2434 ::mlir::TypedValue<::mlir::IntegerType> getValue() {
2435 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
2436 }
2437
2438 ::mlir::OpOperand &getValueMutable() {
2439 auto range = getODSOperandIndexAndLength(0);
2440 return getOperation()->getOpOperand(range.first);
2441 }
2442
2443 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2444 return {index, 1};
2445 }
2446
2447 ::mlir::Operation::result_range getODSResults(unsigned index) {
2448 auto valueRange = getODSResultIndexAndLength(index);
2449 return {std::next(getOperation()->result_begin(), valueRange.first),
2450 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2451 }
2452
2453 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value);
2454 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value value);
2455 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2456 ::llvm::LogicalResult verifyInvariantsImpl();
2457 ::llvm::LogicalResult verifyInvariants();
2458 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2459 void print(::mlir::OpAsmPrinter &_odsPrinter);
2460public:
2461};
2462} // namespace verif
2463} // namespace llzk
2464MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::StepYieldOp)
2465
2466namespace llzk {
2467namespace verif {
2468
2469//===----------------------------------------------------------------------===//
2470// ::llzk::verif::VerifAssertOp declarations
2471//===----------------------------------------------------------------------===//
2472
2473namespace detail {
2475public:
2476protected:
2477 ::mlir::DictionaryAttr odsAttrs;
2478 ::std::optional<::mlir::OperationName> odsOpName;
2479 ::mlir::RegionRange odsRegions;
2480public:
2481 VerifAssertOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
2482 odsOpName.emplace("verif.assert", odsAttrs.getContext());
2483 }
2484
2485 VerifAssertOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
2486
2487 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
2488 return {index, 1};
2489 }
2490
2491 ::mlir::DictionaryAttr getAttributes() {
2492 return odsAttrs;
2493 }
2494
2495};
2496} // namespace detail
2497template <typename RangeT>
2499 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
2501public:
2502 VerifAssertOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
2503
2504 VerifAssertOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : VerifAssertOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
2505
2506 VerifAssertOpGenericAdaptor(RangeT values, const VerifAssertOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
2507
2508 template <typename LateInst = VerifAssertOp, typename = std::enable_if_t<std::is_same_v<LateInst, VerifAssertOp>>>
2509 VerifAssertOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
2510
2511 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2512 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
2513 }
2514
2515 RangeT getODSOperands(unsigned index) {
2516 auto valueRange = getODSOperandIndexAndLength(index);
2517 return {std::next(odsOperands.begin(), valueRange.first),
2518 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
2519 }
2520
2521 ValueT getCondition() {
2522 return (*getODSOperands(0).begin());
2523 }
2524
2525 RangeT getOperands() {
2526 return odsOperands;
2527 }
2528
2529private:
2530 RangeT odsOperands;
2531};
2532class VerifAssertOpAdaptor : public VerifAssertOpGenericAdaptor<::mlir::ValueRange> {
2533public:
2536
2537 ::llvm::LogicalResult verify(::mlir::Location loc);
2538};
2539class VerifAssertOp : public ::mlir::Op<VerifAssertOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait, ::llzk::verif::ConditionOpInterface::Trait> {
2540public:
2541 using Op::Op;
2542 using Op::print;
2544 template <typename RangeT>
2547 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2548 return {};
2549 }
2550
2551 static constexpr ::llvm::StringLiteral getOperationName() {
2552 return ::llvm::StringLiteral("verif.assert");
2553 }
2554
2555 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2556 return {index, 1};
2557 }
2558
2559 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2560 auto valueRange = getODSOperandIndexAndLength(index);
2561 return {std::next(getOperation()->operand_begin(), valueRange.first),
2562 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2563 }
2564
2565 ::mlir::TypedValue<::mlir::IntegerType> getCondition() {
2566 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
2567 }
2568
2569 ::mlir::OpOperand &getConditionMutable() {
2570 auto range = getODSOperandIndexAndLength(0);
2571 return getOperation()->getOpOperand(range.first);
2572 }
2573
2574 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2575 return {index, 1};
2576 }
2577
2578 ::mlir::Operation::result_range getODSResults(unsigned index) {
2579 auto valueRange = getODSResultIndexAndLength(index);
2580 return {std::next(getOperation()->result_begin(), valueRange.first),
2581 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2582 }
2583
2584 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
2585 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
2586 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2587 ::llvm::LogicalResult verifyInvariantsImpl();
2588 ::llvm::LogicalResult verifyInvariants();
2589 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
2590 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2591 void print(::mlir::OpAsmPrinter &_odsPrinter);
2592public:
2593};
2594} // namespace verif
2595} // namespace llzk
2596MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::VerifAssertOp)
2597
2598namespace llzk {
2599namespace verif {
2600
2601//===----------------------------------------------------------------------===//
2602// ::llzk::verif::VerifProveOp declarations
2603//===----------------------------------------------------------------------===//
2604
2605namespace detail {
2607public:
2608protected:
2609 ::mlir::DictionaryAttr odsAttrs;
2610 ::std::optional<::mlir::OperationName> odsOpName;
2611 ::mlir::RegionRange odsRegions;
2612public:
2613 VerifProveOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
2614 odsOpName.emplace("verif.prove", odsAttrs.getContext());
2615 }
2616
2617 VerifProveOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
2618
2619 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
2620 return {index, 1};
2621 }
2622
2623 ::mlir::DictionaryAttr getAttributes() {
2624 return odsAttrs;
2625 }
2626
2627};
2628} // namespace detail
2629template <typename RangeT>
2631 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
2633public:
2634 VerifProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
2635
2636 VerifProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : VerifProveOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
2637
2638 VerifProveOpGenericAdaptor(RangeT values, const VerifProveOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
2639
2640 template <typename LateInst = VerifProveOp, typename = std::enable_if_t<std::is_same_v<LateInst, VerifProveOp>>>
2641 VerifProveOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
2642
2643 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2644 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
2645 }
2646
2647 RangeT getODSOperands(unsigned index) {
2648 auto valueRange = getODSOperandIndexAndLength(index);
2649 return {std::next(odsOperands.begin(), valueRange.first),
2650 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
2651 }
2652
2653 ValueT getCondition() {
2654 return (*getODSOperands(0).begin());
2655 }
2656
2657 RangeT getOperands() {
2658 return odsOperands;
2659 }
2660
2661private:
2662 RangeT odsOperands;
2663};
2664class VerifProveOpAdaptor : public VerifProveOpGenericAdaptor<::mlir::ValueRange> {
2665public:
2668
2669 ::llvm::LogicalResult verify(::mlir::Location loc);
2670};
2671class VerifProveOp : public ::mlir::Op<VerifProveOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait, ::llzk::verif::ConditionOpInterface::Trait> {
2672public:
2673 using Op::Op;
2674 using Op::print;
2676 template <typename RangeT>
2679 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2680 return {};
2681 }
2682
2683 static constexpr ::llvm::StringLiteral getOperationName() {
2684 return ::llvm::StringLiteral("verif.prove");
2685 }
2686
2687 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2688 return {index, 1};
2689 }
2690
2691 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2692 auto valueRange = getODSOperandIndexAndLength(index);
2693 return {std::next(getOperation()->operand_begin(), valueRange.first),
2694 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2695 }
2696
2697 ::mlir::TypedValue<::mlir::IntegerType> getCondition() {
2698 return ::llvm::cast<::mlir::TypedValue<::mlir::IntegerType>>(*getODSOperands(0).begin());
2699 }
2700
2701 ::mlir::OpOperand &getConditionMutable() {
2702 auto range = getODSOperandIndexAndLength(0);
2703 return getOperation()->getOpOperand(range.first);
2704 }
2705
2706 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2707 return {index, 1};
2708 }
2709
2710 ::mlir::Operation::result_range getODSResults(unsigned index) {
2711 auto valueRange = getODSResultIndexAndLength(index);
2712 return {std::next(getOperation()->result_begin(), valueRange.first),
2713 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2714 }
2715
2716 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
2717 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
2718 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2719 ::llvm::LogicalResult verifyInvariantsImpl();
2720 ::llvm::LogicalResult verifyInvariants();
2721 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
2722 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2723 void print(::mlir::OpAsmPrinter &_odsPrinter);
2724public:
2725};
2726} // namespace verif
2727} // namespace llzk
2728MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::VerifProveOp)
2729
2730namespace llzk {
2731namespace verif {
2732
2733//===----------------------------------------------------------------------===//
2734// ::llzk::verif::VerifSMTProveOp declarations
2735//===----------------------------------------------------------------------===//
2736
2737namespace detail {
2739public:
2740protected:
2741 ::mlir::DictionaryAttr odsAttrs;
2742 ::std::optional<::mlir::OperationName> odsOpName;
2743 ::mlir::RegionRange odsRegions;
2744public:
2745 VerifSMTProveOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
2746 odsOpName.emplace("verif.smt_prove", odsAttrs.getContext());
2747 }
2748
2749 VerifSMTProveOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
2750
2751 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
2752 return {index, 1};
2753 }
2754
2755 ::mlir::DictionaryAttr getAttributes() {
2756 return odsAttrs;
2757 }
2758
2759};
2760} // namespace detail
2761template <typename RangeT>
2763 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
2765public:
2766 VerifSMTProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
2767
2768 VerifSMTProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : VerifSMTProveOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
2769
2770 VerifSMTProveOpGenericAdaptor(RangeT values, const VerifSMTProveOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
2771
2772 template <typename LateInst = VerifSMTProveOp, typename = std::enable_if_t<std::is_same_v<LateInst, VerifSMTProveOp>>>
2773 VerifSMTProveOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
2774
2775 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2776 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
2777 }
2778
2779 RangeT getODSOperands(unsigned index) {
2780 auto valueRange = getODSOperandIndexAndLength(index);
2781 return {std::next(odsOperands.begin(), valueRange.first),
2782 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
2783 }
2784
2785 ValueT getCondition() {
2786 return (*getODSOperands(0).begin());
2787 }
2788
2789 RangeT getOperands() {
2790 return odsOperands;
2791 }
2792
2793private:
2794 RangeT odsOperands;
2795};
2796class VerifSMTProveOpAdaptor : public VerifSMTProveOpGenericAdaptor<::mlir::ValueRange> {
2797public:
2800
2801 ::llvm::LogicalResult verify(::mlir::Location loc);
2802};
2803class VerifSMTProveOp : public ::mlir::Op<VerifSMTProveOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::OpInvariants> {
2804public:
2805 using Op::Op;
2806 using Op::print;
2808 template <typename RangeT>
2811 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
2812 return {};
2813 }
2814
2815 static constexpr ::llvm::StringLiteral getOperationName() {
2816 return ::llvm::StringLiteral("verif.smt_prove");
2817 }
2818
2819 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
2820 return {index, 1};
2821 }
2822
2823 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
2824 auto valueRange = getODSOperandIndexAndLength(index);
2825 return {std::next(getOperation()->operand_begin(), valueRange.first),
2826 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
2827 }
2828
2829 ::mlir::TypedValue<::llzk::smt::BoolType> getCondition() {
2830 return ::llvm::cast<::mlir::TypedValue<::llzk::smt::BoolType>>(*getODSOperands(0).begin());
2831 }
2832
2833 ::mlir::OpOperand &getConditionMutable() {
2834 auto range = getODSOperandIndexAndLength(0);
2835 return getOperation()->getOpOperand(range.first);
2836 }
2837
2838 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
2839 return {index, 1};
2840 }
2841
2842 ::mlir::Operation::result_range getODSResults(unsigned index) {
2843 auto valueRange = getODSResultIndexAndLength(index);
2844 return {std::next(getOperation()->result_begin(), valueRange.first),
2845 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
2846 }
2847
2848 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition);
2849 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value condition);
2850 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
2851 ::llvm::LogicalResult verifyInvariantsImpl();
2852 ::llvm::LogicalResult verifyInvariants();
2853 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
2854 void print(::mlir::OpAsmPrinter &_odsPrinter);
2855public:
2856};
2857} // namespace verif
2858} // namespace llzk
2859MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::verif::VerifSMTProveOp)
2860
2861
2862#endif // GET_OP_CLASSES
2863
ContractEndOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:129
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:234
ContractEndOpAdaptor(ContractEndOp op)
Definition Ops.cpp.inc:232
ContractEndOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:129
ContractEndOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:131
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:142
ContractEndOpGenericAdaptor(RangeT values, const ContractEndOpGenericAdaptorBase &base)
Definition Ops.h.inc:133
ContractEndOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:136
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:138
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:174
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:192
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:262
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:254
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:170
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:258
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:188
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:182
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState)
Definition Ops.cpp.inc:238
ContractEndOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:168
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:169
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:271
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:276
ContractEndOpAdaptor Adaptor
Definition Ops.h.inc:166
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:178
ContractOpAdaptor(ContractOp op)
Definition Ops.cpp.inc:314
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:316
ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:338
ContractOpGenericAdaptor(RangeT values, const ContractOpGenericAdaptorBase &base)
Definition Ops.h.inc:344
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:349
ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:342
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:353
ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:338
ContractOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:340
ContractOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:347
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:496
::mlir::StringAttr getFunctionTypeAttrName()
Definition Ops.h.inc:395
::llvm::LogicalResult verifyRegions()
Definition Ops.cpp:664
void setSymNameAttr(::mlir::StringAttr attr)
Definition Ops.h.inc:476
ContractOpAdaptor Adaptor
Definition Ops.h.inc:377
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:464
void setArgNameAttr(unsigned index, const ::mlir::StringAttr &attr)
Set the function.arg_name attribute for the argument at the given index.
Definition Ops.cpp:383
::mlir::FailureOr< SymbolLookupResult< function::FuncDefOp > > getFuncTarget(::mlir::SymbolTableCollection &tables)
Return the FuncDefOp that this contract targets, or failure if it does not target a function or the f...
void setTargetAttr(::mlir::SymbolRefAttr attr)
Definition Ops.h.inc:481
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:382
bool hasArgName(unsigned index)
Return true iff the argument at the given index has a function.arg_name attribute.
Definition Ops.cpp:371
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:449
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:441
::llvm::ArrayRef<::mlir::Type > getResultTypes()
Required by FunctionOpInterface.
Definition Ops.h.inc:569
bool hasArgPublicAttr(unsigned index)
Return true iff the argument at the given index has pub attribute.
Definition Ops.cpp:363
void cloneInto(ContractOp dest, ::mlir::IRMapping &mapper)
Clone the internal blocks and attributes from this contract into dest.
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:419
void setFunctionTypeAttr(::mlir::TypeAttr attr)
Definition Ops.h.inc:485
::mlir::StringAttr getTargetAttrName()
Definition Ops.h.inc:411
void setFunctionType(::mlir::FunctionType attrValue)
Definition Ops.cpp.inc:572
::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable)
Definition Ops.cpp:396
::mlir::StringAttr getSymNameAttr()
Definition Ops.h.inc:456
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:644
::llvm::LogicalResult verify()
Definition Ops.cpp:610
void print(::mlir::OpAsmPrinter &p)
Definition Ops.cpp:583
::std::optional< ::mlir::ArrayAttr > getArgAttrs()
Definition Ops.cpp.inc:563
::mlir::FunctionType getFunctionType()
Definition Ops.cpp.inc:558
void setArgName(unsigned index, ::llvm::StringRef name)
Set the function.arg_name attribute for the argument at the given index from a string.
Definition Ops.cpp:388
::mlir::Attribute removeArgAttrsAttr()
Definition Ops.h.inc:494
ContractOp clone(::mlir::IRMapping &mapper)
Create a deep copy of this contract and all of its blocks, remapping any operands that use values out...
::mlir::FailureOr< SymbolLookupResult<::llzk::verif::ContractTargetOpInterface > > getTargetOp(::mlir::SymbolTableCollection &tables)
Return the operation that this contract targets, or failure if it does not target an operation that i...
::mlir::StringAttr getSymNameAttrName()
Definition Ops.h.inc:403
bool hasStructTarget()
Return true iff the contract targets a struct type.
Definition Ops.h.inc:579
::std::optional<::mlir::StringAttr > getArgNameAttr(unsigned index)
Return the function.arg_name attribute for the argument at the given index.
Definition Ops.cpp:373
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:380
::llvm::ArrayRef<::mlir::Type > getArgumentTypes()
Required by FunctionOpInterface.
Definition Ops.h.inc:564
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:437
::mlir::Region & getBody()
Definition Ops.h.inc:443
void setArgAttrsAttr(::mlir::ArrayAttr attr)
Definition Ops.h.inc:490
::mlir::StringAttr getArgAttrsAttrName()
Definition Ops.h.inc:387
::mlir::StringAttr getArgAttrsAttrName(::mlir::OperationName name)
Definition Ops.h.inc:391
::mlir::TypeAttr getFunctionTypeAttr()
Definition Ops.h.inc:466
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:423
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:433
::mlir::FailureOr< SymbolLookupResult< component::StructDefOp > > getStructTarget(::mlir::SymbolTableCollection &tables)
Return the StructDefOp that this contract targets, or failure if it does not target a struct or the s...
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:404
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:486
::mlir::StringAttr getFunctionTypeAttrName(::mlir::OperationName name)
Definition Ops.h.inc:399
::mlir::Region * getCallableRegion()
Required by FunctionOpInterface.
Definition Ops.h.inc:560
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef name, llvm::StringRef target)
::mlir::SymbolRefAttr getTargetAttr()
Definition Ops.h.inc:461
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:427
::mlir::SymbolRefAttr getFullyQualifiedName(bool requireParent=true)
Return the full name for this contract from the root module, including all surrounding symbol table n...
Definition Ops.cpp:392
::mlir::FailureOr< SymbolLookupResult<::llzk::verif::ContractTargetOpInterface > > getTargetOp()
Definition Ops.h.inc:610
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:614
::mlir::FailureOr<::mlir::Value > getSelfValue()
Return the "self" value (i.e.
Definition Ops.cpp:720
::mlir::ArrayAttr getArgAttrsAttr()
Definition Ops.h.inc:471
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:539
void setSymName(::llvm::StringRef attrValue)
Definition Ops.cpp.inc:568
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:339
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:523
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp:476
::mlir::SymbolRefAttr getTarget()
Definition Ops.cpp.inc:553
FoldAdaptor::Properties Properties
Definition Ops.h.inc:381
::mlir::FailureOr< SymbolLookupResult< component::StructDefOp > > getStructTarget()
Definition Ops.h.inc:585
::mlir::FailureOr< SymbolLookupResult< function::FuncDefOp > > getFuncTarget()
Definition Ops.h.inc:601
::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name)
Definition Ops.h.inc:407
ContractOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:379
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name, ::mlir::SymbolRefAttr target, ::mlir::TypeAttr function_type, ::mlir::ArrayAttr arg_attrs={})
Definition Ops.cpp.inc:576
bool hasFuncTarget()
Return true iff the contract targets a function.
Definition Ops.h.inc:595
::llvm::StringRef getSymName()
Definition Ops.cpp.inc:548
::mlir::StringAttr getTargetAttrName(::mlir::OperationName name)
Definition Ops.h.inc:415
bool isDeclaration()
Required by SymbolOpInterface.
Definition Ops.h.inc:572
DecreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:663
DecreasesOpAdaptor(DecreasesOp op)
Definition Ops.cpp.inc:663
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:665
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:672
DecreasesOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:670
DecreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:663
DecreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:665
DecreasesOpGenericAdaptor(RangeT values, const DecreasesOpGenericAdaptorBase &base)
Definition Ops.h.inc:667
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:676
DecreasesOpAdaptor Adaptor
Definition Ops.h.inc:704
::mlir::OpOperand & getValueMutable()
Definition Ops.h.inc:730
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:708
::mlir::TypedValue<::llzk::felt::FeltType > getValue()
Definition Ops.h.inc:726
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:732
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:704
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:712
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value)
Definition Ops.cpp.inc:669
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:735
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:687
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:720
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:707
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:716
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:700
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:739
DecreasesOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:706
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:723
EnsureComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:795
EnsureComputeOpAdaptor(EnsureComputeOp op)
Definition Ops.cpp.inc:750
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:752
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:804
EnsureComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:795
EnsureComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:797
EnsureComputeOpGenericAdaptor(RangeT values, const EnsureComputeOpGenericAdaptorBase &base)
Definition Ops.h.inc:799
EnsureComputeOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:802
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:808
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:791
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:819
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:862
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:787
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:840
EnsureComputeOpAdaptor Adaptor
Definition Ops.h.inc:836
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:848
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:839
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:844
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:810
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:852
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:871
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:756
EnsureComputeOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:838
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:774
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:867
::mlir::TypedValue<::mlir::IntegerType > getCondition()
Definition Ops.h.inc:858
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:839
EnsureConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:927
EnsureConstrainOpAdaptor(EnsureConstrainOp op)
Definition Ops.cpp.inc:837
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:936
EnsureConstrainOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:934
EnsureConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:929
EnsureConstrainOpGenericAdaptor(RangeT values, const EnsureConstrainOpGenericAdaptorBase &base)
Definition Ops.h.inc:931
EnsureConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:927
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:994
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:971
EnsureConstrainOpAdaptor Adaptor
Definition Ops.h.inc:968
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:999
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:984
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:906
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:976
EnsureConstrainOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:970
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:874
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:897
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:861
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:980
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:843
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:878
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:972
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1003
::mlir::TypedValue<::mlir::IntegerType > getCondition()
Definition Ops.h.inc:990
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:962
IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1145
IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs)
Definition Ops.h.inc:1149
::llvm::SmallVector< RangeT > getMapOperands()
Definition Ops.h.inc:1170
IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1145
IncludeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1147
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1156
IncludeOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1154
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:1160
IncludeOpGenericAdaptor(RangeT values, const IncludeOpGenericAdaptorBase &base)
Definition Ops.h.inc:1151
void setNumDimsPerMap(::llvm::ArrayRef< int32_t > attrValue)
Definition Ops.cpp.inc:1305
::mlir::LogicalResult verifyTemplateParamCompatibility(::mlir::Attribute paramFromCallOp, ::llzk::polymorphic::TemplateParamOp targetParam)
Check type compatibility of the given template parameter value from this CallOp against the declared ...
::mlir::MutableOperandRange getArgOperandsMutable()
Definition Ops.cpp.inc:993
::mlir::StringAttr getMapOpGroupSizesAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1222
::mlir::ArrayAttr getTemplateParamsAttr()
Definition Ops.h.inc:1295
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:1081
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1347
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:1126
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1255
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:1222
IncludeOpAdaptor Adaptor
Definition Ops.h.inc:1200
void setMapOpGroupSizes(::llvm::ArrayRef< int32_t > attrValue)
Definition Ops.cpp.inc:1309
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1205
::mlir::OperandRangeRange getMapOperands()
Definition Ops.h.inc:1265
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1203
::llvm::LogicalResult setPropertiesFromParsedAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1465
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1390
::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable)
Definition Ops.cpp:991
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.cpp.inc:984
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1195
void setNumDimsPerMapAttr(::mlir::DenseI32ArrayAttr attr)
Definition Ops.h.inc:1318
::llvm::ArrayRef< int32_t > getMapOpGroupSizes()
Definition Ops.cpp.inc:1300
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:1262
::mlir::StringAttr getNumDimsPerMapAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1230
::mlir::SymbolRefAttr getCalleeAttr()
Definition Ops.h.inc:1290
FoldAdaptor::Properties Properties
Definition Ops.h.inc:1204
void setMapOpGroupSizesAttr(::mlir::DenseI32ArrayAttr attr)
Definition Ops.h.inc:1323
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:1138
::mlir::Operation::operand_range getArgOperands()
Definition Ops.h.inc:1261
void setCalleeAttr(::mlir::SymbolRefAttr attr)
Definition Ops.h.inc:1310
::mlir::FailureOr<::llzk::SymbolLookupResult<::llzk::verif::ContractOp > > getCalleeTarget(::mlir::SymbolTableCollection &tables)
Resolve and return the target Contract for this CallOp.
Definition Ops.cpp:1043
::mlir::Operation * resolveCallable()
Required by CallOpInterface.
Definition Ops.cpp:1099
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:1184
::mlir::SymbolRefAttr getCallee()
Definition Ops.cpp.inc:1285
::mlir::StringAttr getCalleeAttrName()
Definition Ops.h.inc:1210
::mlir::StringAttr getTemplateParamsAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1238
::mlir::StringAttr getMapOpGroupSizesAttrName()
Definition Ops.h.inc:1218
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1005
::mlir::StringAttr getOperandSegmentSizesAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1246
::mlir::Value getSelfValue()
Return the "self" value (i.e.
Definition Ops.cpp:1056
::mlir::MutableOperandRangeRange getMapOperandsMutable()
Definition Ops.cpp.inc:999
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1271
::mlir::StringAttr getOperandSegmentSizesAttrName()
Definition Ops.h.inc:1242
::std::optional< ::mlir::ArrayAttr > getTemplateParams()
Definition Ops.cpp.inc:1290
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:1154
void setCalleeFromCallable(::mlir::CallInterfaceCallable callee)
Set the callee for this operation.
Definition Ops.cpp:1071
bool contractTargetsStruct()
Return true iff the contract targets a struct type.
Definition Ops.cpp:1050
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1275
void setTemplateParamsAttr(::mlir::ArrayAttr attr)
Definition Ops.h.inc:1314
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::SymbolRefAttr callee, ::mlir::ValueRange argOperands={}, ::llvm::ArrayRef<::mlir::Attribute > templateParams={})
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1493
::mlir::StringAttr getCalleeAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1214
::mlir::LogicalResult verifyTemplateParamCompatibility(::llvm::iterator_range<::mlir::Region::op_iterator<::llzk::polymorphic::TemplateParamOp > > targetParamDefs)
Check type compatibility of each template parameter value provided in this CallOp against the declare...
static void populateDefaultProperties(::mlir::OperationName opName, Properties &properties)
Definition Ops.cpp.inc:1341
::llvm::ArrayRef< int32_t > getNumDimsPerMap()
Definition Ops.cpp.inc:1295
::mlir::FunctionType getTypeSignature()
Return the FunctionType inferred from the arg operands of this CallOp.
Definition Ops.cpp:1030
::mlir::Attribute removeTemplateParamsAttr()
Definition Ops.h.inc:1328
::mlir::LogicalResult verifyTemplateParamsMatchInferred(::llvm::iterator_range<::mlir::Region::op_iterator<::llzk::polymorphic::TemplateParamOp > > targetParamDefs, const UnificationMap &unifications)
Verify that each template parameter value provided in this CallOp is consistent with the value inferr...
Definition Ops.cpp:823
::mlir::StringAttr getNumDimsPerMapAttrName()
Definition Ops.h.inc:1226
::mlir::DenseI32ArrayAttr getNumDimsPerMapAttr()
Definition Ops.h.inc:1300
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1386
::mlir::FailureOr< UnificationMap > unifyTypeSignature(::mlir::FunctionType other)
Attempt type unfication between the inferred FunctionType from this CallOp (as LHS) and the given Fun...
Definition Ops.cpp:1034
::mlir::Operation * resolveCallableInTable(::mlir::SymbolTableCollection *symbolTable)
Required by CallOpInterface.
Definition Ops.cpp:1082
IncludeOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1202
static ::llvm::SmallVector<::mlir::ValueRange > toVectorOfValueRange(::mlir::OperandRangeRange)
Allocate consecutive storage of the ValueRange instances in the parameter so it can be passed to the ...
Definition Ops.cpp:1075
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::SymbolRefAttr callee, ::llvm::ArrayRef<::mlir::ValueRange > mapOperands, ::mlir::DenseI32ArrayAttr numDimsPerMap, ::mlir::ValueRange argOperands={}, ::llvm::ArrayRef<::mlir::Attribute > templateParams={})
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1250
::mlir::DenseI32ArrayAttr getMapOpGroupSizesAttr()
Definition Ops.h.inc:1305
::mlir::CallInterfaceCallable getCallableForCallee()
Return the callee of this operation.
Definition Ops.cpp:1068
::mlir::StringAttr getTemplateParamsAttrName()
Definition Ops.h.inc:1234
IncreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1463
IncreasesOpAdaptor(IncreasesOp op)
Definition Ops.cpp.inc:1529
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1531
IncreasesOpGenericAdaptor(RangeT values, const IncreasesOpGenericAdaptorBase &base)
Definition Ops.h.inc:1467
IncreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1463
IncreasesOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1470
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:1476
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1472
IncreasesOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1465
IncreasesOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1506
IncreasesOpAdaptor Adaptor
Definition Ops.h.inc:1504
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1570
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1512
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1507
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1539
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1566
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1589
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1553
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value)
Definition Ops.cpp.inc:1535
::mlir::OpOperand & getValueMutable()
Definition Ops.h.inc:1530
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1520
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1516
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1508
::mlir::TypedValue<::llzk::felt::FeltType > getValue()
Definition Ops.h.inc:1526
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1535
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:1598
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1630
InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1651
InvariantOpAdaptor(InvariantOp op)
Definition Ops.cpp.inc:1628
InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1653
InvariantOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1660
InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1651
InvariantOpGenericAdaptor(RangeT values, const InvariantOpGenericAdaptorBase &base)
Definition Ops.h.inc:1657
InvariantOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:1655
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:1666
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1662
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1693
::mlir::FailureOr<::llzk::verif::InvariantTargetOpInterface > getTarget()
Returns the loop target.
Definition Ops.cpp:1237
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1737
InvariantOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1692
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1730
void setLoopArgTypesAttr(::mlir::ArrayAttr attr)
Definition Ops.h.inc:1768
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:1719
::mlir::StringAttr getLoopArgTypesAttrName()
Definition Ops.h.inc:1700
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1724
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1716
InvariantOpAdaptor Adaptor
Definition Ops.h.inc:1690
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp:1167
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:1762
::mlir::StringAttr getLoopArgTypesAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1704
void setLoopName(::llvm::StringRef attrValue)
Definition Ops.cpp.inc:1778
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:1710
::mlir::ArrayAttr getLoopArgTypesAttr()
Definition Ops.h.inc:1758
void print(::mlir::OpAsmPrinter &p)
Definition Ops.cpp:1216
::mlir::StringAttr getLoopNameAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1712
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1734
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:1681
void setLoopNameAttr(::mlir::StringAttr attr)
Definition Ops.h.inc:1763
::mlir::ArrayAttr getLoopArgTypes()
Definition Ops.cpp.inc:1773
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:1704
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1695
::mlir::StringAttr getLoopNameAttr()
Definition Ops.h.inc:1753
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:1752
::llvm::StringRef getLoopName()
Definition Ops.cpp.inc:1768
::llzk::verif::ContractOp getParentContract()
Returns the contract operation that contains this invariant.
Definition Ops.cpp:1233
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringRef loop_name, ::llvm::ArrayRef<::mlir::Type > loop_arg_types={}, ::llvm::ArrayRef<::mlir::Location > loop_arg_locs={})
Definition Ops.cpp:1108
FoldAdaptor::Properties Properties
Definition Ops.h.inc:1694
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1720
::llvm::LogicalResult verify()
Definition Ops.cpp:1158
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:1731
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1782
::mlir::Region & getRegion()
Definition Ops.h.inc:1740
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1803
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1644
::mlir::StringAttr getLoopNameAttrName()
Definition Ops.h.inc:1708
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1824
OldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1837
OldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1839
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1846
OldOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1844
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:1850
OldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1837
OldOpGenericAdaptor(RangeT values, const OldOpGenericAdaptorBase &base)
Definition Ops.h.inc:1841
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1909
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1948
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1886
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1882
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1880
OldOpAdaptor Adaptor
Definition Ops.h.inc:1878
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1918
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1894
::mlir::TypedValue<::mlir::Type > getResult()
Definition Ops.h.inc:1919
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1904
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1890
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:1964
::mlir::TypedValue<::mlir::Type > getValue()
Definition Ops.h.inc:1900
::mlir::OpOperand & getValueMutable()
Definition Ops.h.inc:1904
::llvm::LogicalResult inferReturnTypes(::mlir::MLIRContext *context, ::std::optional<::mlir::Location > location, ::mlir::ValueRange operands, ::mlir::DictionaryAttr attributes, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions, ::llvm::SmallVectorImpl<::mlir::Type > &inferredReturnTypes)
Definition Ops.cpp.inc:1908
OldOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1880
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1913
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1881
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value value)
Definition Ops.cpp.inc:1828
RequireComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1976
RequireComputeOpAdaptor(RequireComputeOp op)
Definition Ops.cpp.inc:1980
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1982
RequireComputeOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1983
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1985
RequireComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1978
RequireComputeOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1976
RequireComputeOpGenericAdaptor(RangeT values, const RequireComputeOpGenericAdaptorBase &base)
Definition Ops.h.inc:1980
RequireComputeOpAdaptor Adaptor
Definition Ops.h.inc:2017
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2020
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2025
RequireComputeOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2019
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2029
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2004
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:2049
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2017
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2048
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2021
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2021
::mlir::TypedValue<::mlir::IntegerType > getCondition()
Definition Ops.h.inc:2039
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2033
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:1986
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2052
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2040
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:2043
RequireConstrainOpAdaptor(RequireConstrainOp op)
Definition Ops.cpp.inc:2067
RequireConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2108
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:2069
RequireConstrainOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:2115
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2117
RequireConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2110
RequireConstrainOpGenericAdaptor(RangeT values, const RequireConstrainOpGenericAdaptorBase &base)
Definition Ops.h.inc:2112
RequireConstrainOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2108
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2153
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:2175
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2180
RequireConstrainOpAdaptor Adaptor
Definition Ops.h.inc:2149
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2152
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2184
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2104
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2161
::mlir::TypedValue<::mlir::IntegerType > getCondition()
Definition Ops.h.inc:2171
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:2136
RequireConstrainOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2151
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2091
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:2073
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2108
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2157
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2165
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2127
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:2156
StepOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2248
StepOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2248
StepOpGenericAdaptor(RangeT values, const StepOpGenericAdaptorBase &base)
Definition Ops.h.inc:2252
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2257
StepOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:2255
StepOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2250
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:2261
StepOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2287
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2307
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2195
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2180
StepOpAdaptor Adaptor
Definition Ops.h.inc:2285
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2191
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2297
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:2220
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2293
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2288
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2301
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2289
::mlir::Region & getRegion()
Definition Ops.h.inc:2317
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2211
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2311
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState)
Definition Ops.cpp.inc:2160
StepYieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2371
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:2240
StepYieldOpAdaptor(StepYieldOp op)
Definition Ops.cpp.inc:2238
StepYieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2371
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2380
StepYieldOpGenericAdaptor(RangeT values, const StepYieldOpGenericAdaptorBase &base)
Definition Ops.h.inc:2375
StepYieldOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:2378
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:2384
StepYieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2373
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2420
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2416
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2447
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2415
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2424
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value value)
Definition Ops.cpp.inc:2244
StepYieldOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2414
::mlir::TypedValue<::mlir::IntegerType > getValue()
Definition Ops.h.inc:2434
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2279
StepYieldOpAdaptor Adaptor
Definition Ops.h.inc:2412
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2262
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2428
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2275
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2443
::mlir::OpOperand & getValueMutable()
Definition Ops.h.inc:2438
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2298
VerifAssertOpAdaptor(VerifAssertOp op)
Definition Ops.cpp.inc:2318
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:2320
VerifAssertOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2502
VerifAssertOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:2509
VerifAssertOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2504
VerifAssertOpGenericAdaptor(RangeT values, const VerifAssertOpGenericAdaptorBase &base)
Definition Ops.h.inc:2506
VerifAssertOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2502
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2511
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:2515
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2578
::mlir::TypedValue<::mlir::IntegerType > getCondition()
Definition Ops.h.inc:2565
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2342
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2574
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2551
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2547
VerifAssertOpAdaptor Adaptor
Definition Ops.h.inc:2543
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2559
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:2387
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2359
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2378
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2555
VerifAssertOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2545
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2355
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:2569
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:2324
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2546
VerifProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2634
VerifProveOpAdaptor(VerifProveOp op)
Definition Ops.cpp.inc:2405
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:2407
VerifProveOpGenericAdaptor(RangeT values, const VerifProveOpGenericAdaptorBase &base)
Definition Ops.h.inc:2638
VerifProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2634
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:2647
VerifProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2636
VerifProveOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:2641
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2643
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2687
::mlir::TypedValue<::mlir::IntegerType > getCondition()
Definition Ops.h.inc:2697
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2446
VerifProveOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2677
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2710
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2679
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2429
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2442
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:2701
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2683
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:2474
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2691
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2678
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2706
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:2411
VerifProveOpAdaptor Adaptor
Definition Ops.h.inc:2675
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2465
VerifSMTProveOpAdaptor(VerifSMTProveOp op)
Definition Ops.cpp.inc:2492
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:2494
VerifSMTProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2766
VerifSMTProveOpGenericAdaptor(RangeT values, const VerifSMTProveOpGenericAdaptorBase &base)
Definition Ops.h.inc:2770
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:2779
VerifSMTProveOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:2773
VerifSMTProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2766
VerifSMTProveOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2768
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2775
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:2811
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value condition)
Definition Ops.cpp.inc:2498
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:2823
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:2819
VerifSMTProveOpAdaptor Adaptor
Definition Ops.h.inc:2807
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:2533
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:2529
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:2810
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:2516
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:2842
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:2838
::mlir::TypedValue<::llzk::smt::BoolType > getCondition()
Definition Ops.h.inc:2829
VerifSMTProveOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:2809
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:2815
::mlir::OpOperand & getConditionMutable()
Definition Ops.h.inc:2833
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:2552
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:114
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:105
ContractEndOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:108
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:287
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:277
ContractOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:281
::std::optional< ::mlir::ArrayAttr > getArgAttrs()
Definition Ops.cpp.inc:308
DecreasesOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:642
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:639
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:648
DecreasesOpGenericAdaptorBase(::mlir::Operation *op)
Definition Ops.h.inc:646
EnsureComputeOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:774
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:771
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:780
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:903
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:912
EnsureConstrainOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:906
::llvm::ArrayRef< int32_t > getNumDimsPerMap()
Definition Ops.cpp.inc:949
::mlir::DenseI32ArrayAttr getNumDimsPerMapAttr()
Definition Ops.cpp.inc:944
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1099
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.cpp.inc:925
::llvm::ArrayRef< int32_t > getMapOpGroupSizes()
Definition Ops.cpp.inc:954
::std::optional< ::mlir::ArrayAttr > getTemplateParams()
Definition Ops.cpp.inc:939
IncludeOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1103
::mlir::DenseI32ArrayAttr getMapOpGroupSizesAttr()
Definition Ops.h.inc:1132
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1439
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1448
IncreasesOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1442
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1602
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1612
InvariantOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1606
::mlir::DictionaryAttr getAttributes()
Definition Ops.h.inc:1826
OldOpGenericAdaptorBase(::mlir::Operation *op)
Definition Ops.h.inc:1820
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1813
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1822
OldOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1816
RequireComputeOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1955
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1961
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1952
RequireConstrainOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2087
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:2084
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:2093
StepOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2219
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:2225
StepOpGenericAdaptorBase(::mlir::Operation *op)
Definition Ops.h.inc:2223
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:2216
StepYieldOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2350
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:2356
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:2347
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:2478
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:2487
VerifAssertOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2481
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:2619
VerifProveOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2613
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:2610
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:2742
VerifSMTProveOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:2745
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:2751
mlir::DenseMap< std::pair< mlir::SymbolRefAttr, Side >, mlir::Attribute > UnificationMap
Optional result from type unifications.
Definition TypeHelper.h:223
llvm::StringLiteral getOperationName()
Get the operation name, like "constrain.eq" for the given OpClass.
Definition OpHelpers.h:32
void setTarget(const ::mlir::SymbolRefAttr &propValue)
Definition Ops.h.inc:260
void setFunctionType(const ::mlir::TypeAttr &propValue)
Definition Ops.h.inc:240
void setSymName(const ::mlir::StringAttr &propValue)
Definition Ops.h.inc:250
void setArgAttrs(const ::mlir::ArrayAttr &propValue)
Definition Ops.h.inc:230
void setMapOpGroupSizes(const ::mlir::DenseI32ArrayAttr &propValue)
Definition Ops.h.inc:1051
::llvm::ArrayRef< int32_t > getOperandSegmentSizes() const
Definition Ops.h.inc:1076
void setNumDimsPerMap(const ::mlir::DenseI32ArrayAttr &propValue)
Definition Ops.h.inc:1061
void setOperandSegmentSizes(::llvm::ArrayRef< int32_t > propValue)
Definition Ops.h.inc:1080
void setCallee(const ::mlir::SymbolRefAttr &propValue)
Definition Ops.h.inc:1041
void setTemplateParams(const ::mlir::ArrayAttr &propValue)
Definition Ops.h.inc:1071
void setLoopArgTypes(const ::mlir::ArrayAttr &propValue)
Definition Ops.h.inc:1577
void setLoopName(const ::mlir::StringAttr &propValue)
Definition Ops.h.inc:1587