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 polymorphic {
12class ApplyMapOp;
13} // namespace polymorphic
14} // namespace llzk
15namespace llzk {
16namespace polymorphic {
17class ConstReadOp;
18} // namespace polymorphic
19} // namespace llzk
20namespace llzk {
21namespace polymorphic {
22class TemplateExprOp;
23} // namespace polymorphic
24} // namespace llzk
25namespace llzk {
26namespace polymorphic {
27class TemplateOp;
28} // namespace polymorphic
29} // namespace llzk
30namespace llzk {
31namespace polymorphic {
32class TemplateParamOp;
33} // namespace polymorphic
34} // namespace llzk
35namespace llzk {
36namespace polymorphic {
37class UnifiableCastOp;
38} // namespace polymorphic
39} // namespace llzk
40namespace llzk {
41namespace polymorphic {
42class YieldOp;
43} // namespace polymorphic
44} // namespace llzk
45#ifdef GET_OP_CLASSES
46#undef GET_OP_CLASSES
47
48namespace llzk {
49namespace polymorphic {
50
51//===----------------------------------------------------------------------===//
52// ::llzk::polymorphic::ApplyMapOp declarations
53//===----------------------------------------------------------------------===//
54
55namespace detail {
57public:
58 struct Properties {
59 using mapTy = ::mlir::AffineMapAttr;
61
62 auto getMap() {
63 auto &propStorage = this->map;
64 return ::llvm::cast<::mlir::AffineMapAttr>(propStorage);
65 }
66 void setMap(const ::mlir::AffineMapAttr &propValue) {
67 this->map = propValue;
68 }
69 using numDimsTy = ::mlir::IntegerAttr;
71
72 auto getNumDims() {
73 auto &propStorage = this->numDims;
74 return ::llvm::cast<::mlir::IntegerAttr>(propStorage);
75 }
76 void setNumDims(const ::mlir::IntegerAttr &propValue) {
77 this->numDims = propValue;
78 }
79 bool operator==(const Properties &rhs) const {
80 return
81 rhs.map == this->map &&
82 rhs.numDims == this->numDims &&
83 true;
84 }
85 bool operator!=(const Properties &rhs) const {
86 return !(*this == rhs);
87 }
88 };
89protected:
90 ::mlir::DictionaryAttr odsAttrs;
91 ::std::optional<::mlir::OperationName> odsOpName;
93 ::mlir::RegionRange odsRegions;
94public:
95 ApplyMapOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
96 odsOpName.emplace("poly.applymap", odsAttrs.getContext());
97 }
98
100
101 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize);
103 return properties;
104 }
105
106 ::mlir::DictionaryAttr getAttributes() {
107 return odsAttrs;
108 }
109
110 ::mlir::AffineMapAttr getMapAttr() {
111 auto attr = ::llvm::cast<::mlir::AffineMapAttr>(getProperties().map);
112 return attr;
113 }
114
115 ::mlir::AffineMap getMap();
116 ::mlir::IntegerAttr getNumDimsAttr() {
117 auto attr = ::llvm::cast<::mlir::IntegerAttr>(getProperties().numDims);
118 return attr;
119 }
120
121 ::llvm::APInt getNumDims();
122};
123} // namespace detail
124template <typename RangeT>
126 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
128public:
129 ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
130
131 ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : ApplyMapOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
132
133 ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : ApplyMapOpGenericAdaptor(values, attrs, Properties{}, {}) {}
134
135 ApplyMapOpGenericAdaptor(RangeT values, const ApplyMapOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
136
137 template <typename LateInst = ApplyMapOp, typename = std::enable_if_t<std::is_same_v<LateInst, ApplyMapOp>>>
138 ApplyMapOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
139
140 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
141 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
142 }
143
144 RangeT getODSOperands(unsigned index) {
145 auto valueRange = getODSOperandIndexAndLength(index);
146 return {std::next(odsOperands.begin(), valueRange.first),
147 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
148 }
149
150 RangeT getMapOperands() {
151 return getODSOperands(0);
152 }
153
154 RangeT getOperands() {
155 return odsOperands;
156 }
157
158private:
159 RangeT odsOperands;
160};
161class ApplyMapOpAdaptor : public ApplyMapOpGenericAdaptor<::mlir::ValueRange> {
162public:
165
166 ::llvm::LogicalResult verify(::mlir::Location loc);
167};
168class ApplyMapOp : public ::mlir::Op<ApplyMapOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::OneResult, ::mlir::OpTrait::OneTypedResult<::mlir::IndexType>::Impl, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::VariadicOperands, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait, ::mlir::InferTypeOpInterface::Trait> {
169public:
170 using Op::Op;
171 using Op::print;
173 template <typename RangeT>
177 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
178 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("map"), ::llvm::StringRef("numDims")};
179 return ::llvm::ArrayRef(attrNames);
180 }
181
182 ::mlir::StringAttr getMapAttrName() {
183 return getAttributeNameForIndex(0);
184 }
185
186 static ::mlir::StringAttr getMapAttrName(::mlir::OperationName name) {
187 return getAttributeNameForIndex(name, 0);
188 }
189
190 ::mlir::StringAttr getNumDimsAttrName() {
191 return getAttributeNameForIndex(1);
192 }
193
194 static ::mlir::StringAttr getNumDimsAttrName(::mlir::OperationName name) {
195 return getAttributeNameForIndex(name, 1);
196 }
197
198 static constexpr ::llvm::StringLiteral getOperationName() {
199 return ::llvm::StringLiteral("poly.applymap");
200 }
201
202 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index);
203 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
204 auto valueRange = getODSOperandIndexAndLength(index);
205 return {std::next(getOperation()->operand_begin(), valueRange.first),
206 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
207 }
208
209 ::mlir::Operation::operand_range getMapOperands() {
210 return getODSOperands(0);
211 }
212
213 ::mlir::MutableOperandRange getMapOperandsMutable();
214 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
215 return {index, 1};
216 }
217
218 ::mlir::Operation::result_range getODSResults(unsigned index) {
219 auto valueRange = getODSResultIndexAndLength(index);
220 return {std::next(getOperation()->result_begin(), valueRange.first),
221 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
222 }
223
224 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
225 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
226 static llvm::hash_code computePropertiesHash(const Properties &prop);
227 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
228 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
229 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
230 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
231 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
232 void writeProperties(::mlir::DialectBytecodeWriter &writer);
233 ::mlir::AffineMapAttr getMapAttr() {
234 return ::llvm::cast<::mlir::AffineMapAttr>(getProperties().map);
235 }
236
237 ::mlir::AffineMap getMap();
238 ::mlir::IntegerAttr getNumDimsAttr() {
239 return ::llvm::cast<::mlir::IntegerAttr>(getProperties().numDims);
240 }
241
242 ::llvm::APInt getNumDims();
243 void setMapAttr(::mlir::AffineMapAttr attr) {
244 getProperties().map = attr;
245 }
246
247 void setMap(::mlir::AffineMap attrValue);
248 void setNumDimsAttr(::mlir::IntegerAttr attr) {
249 getProperties().numDims = attr;
250 }
251
252 void setNumDims(::llvm::APInt attrValue);
253 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::AffineMapAttr map, ::mlir::ValueRange mapOperands = {});
254 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::AffineMap map, ::mlir::ValueRange mapOperands = {});
255 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::AffineExpr expr, ::mlir::ValueRange mapOperands = {});
256 ::llvm::LogicalResult verifyInvariantsImpl();
257 ::llvm::LogicalResult verifyInvariants();
258 ::llvm::LogicalResult verify();
259 ::mlir::OpFoldResult fold(FoldAdaptor adaptor);
260 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);
261 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
262 void print(::mlir::OpAsmPrinter &_odsPrinter);
263 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
264private:
265 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
266 return getAttributeNameForIndex((*this)->getName(), index);
267 }
268
269 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
270 assert(index < 2 && "invalid attribute index");
271 assert(name.getStringRef() == getOperationName() && "invalid operation name");
272 assert(name.isRegistered() && "Operation isn't registered, missing a "
273 "dependent dialect loading?");
274 return name.getAttributeNames()[index];
275 }
276
277public:
279 ::mlir::AffineMap inline getAffineMap() { return getMap(); }
280
282 ::mlir::affine::AffineValueMap getAffineValueMap() {
283 return ::mlir::affine::AffineValueMap(getAffineMap(), getOperands(), getResult());
284 }
285
287 ::mlir::ValueRange getDimOperands() {
288 return ::mlir::OperandRange{
289 getOperands().begin(),
290 getOperands().begin() + getMap().getNumDims()};
291 }
292
294 ::mlir::ValueRange getSymbolOperands() {
295 return ::mlir::OperandRange{
296 getOperands().begin() + getMap().getNumDims(),
297 getOperands().end()};
298 }
299};
300} // namespace polymorphic
301} // namespace llzk
302MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::ApplyMapOp)
303
304namespace llzk {
305namespace polymorphic {
306
307//===----------------------------------------------------------------------===//
308// ::llzk::polymorphic::ConstReadOp declarations
309//===----------------------------------------------------------------------===//
310
311namespace detail {
313public:
314 struct Properties {
315 using const_nameTy = ::mlir::FlatSymbolRefAttr;
317
319 auto &propStorage = this->const_name;
320 return ::llvm::cast<::mlir::FlatSymbolRefAttr>(propStorage);
321 }
322 void setConstName(const ::mlir::FlatSymbolRefAttr &propValue) {
323 this->const_name = propValue;
324 }
325 bool operator==(const Properties &rhs) const {
326 return
327 rhs.const_name == this->const_name &&
328 true;
329 }
330 bool operator!=(const Properties &rhs) const {
331 return !(*this == rhs);
332 }
333 };
334protected:
335 ::mlir::DictionaryAttr odsAttrs;
336 ::std::optional<::mlir::OperationName> odsOpName;
338 ::mlir::RegionRange odsRegions;
339public:
340 ConstReadOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
341 odsOpName.emplace("poly.read_const", odsAttrs.getContext());
342 }
343
345
346 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
347 return {index, 1};
348 }
349
351 return properties;
352 }
353
354 ::mlir::DictionaryAttr getAttributes() {
355 return odsAttrs;
356 }
357
358 ::mlir::FlatSymbolRefAttr getConstNameAttr() {
359 auto attr = ::llvm::cast<::mlir::FlatSymbolRefAttr>(getProperties().const_name);
360 return attr;
361 }
362
363 ::llvm::StringRef getConstName();
364};
365} // namespace detail
366template <typename RangeT>
368 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
370public:
371 ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
372
373 ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : ConstReadOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
374
375 ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : ConstReadOpGenericAdaptor(values, attrs, Properties{}, {}) {}
376
377 ConstReadOpGenericAdaptor(RangeT values, const ConstReadOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
378
379 template <typename LateInst = ConstReadOp, typename = std::enable_if_t<std::is_same_v<LateInst, ConstReadOp>>>
380 ConstReadOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
381
382 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
383 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
384 }
385
386 RangeT getODSOperands(unsigned index) {
387 auto valueRange = getODSOperandIndexAndLength(index);
388 return {std::next(odsOperands.begin(), valueRange.first),
389 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
390 }
391
392 RangeT getOperands() {
393 return odsOperands;
394 }
395
396private:
397 RangeT odsOperands;
398};
399class ConstReadOpAdaptor : public ConstReadOpGenericAdaptor<::mlir::ValueRange> {
400public:
403
404 ::llvm::LogicalResult verify(::mlir::Location loc);
405};
406class ConstReadOp : public ::mlir::Op<ConstReadOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::OneResult, ::mlir::OpTrait::OneTypedResult<::mlir::Type>::Impl, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait, ::mlir::SymbolUserOpInterface::Trait> {
407public:
408 using Op::Op;
409 using Op::print;
411 template <typename RangeT>
415 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
416 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("const_name")};
417 return ::llvm::ArrayRef(attrNames);
418 }
419
420 ::mlir::StringAttr getConstNameAttrName() {
421 return getAttributeNameForIndex(0);
422 }
423
424 static ::mlir::StringAttr getConstNameAttrName(::mlir::OperationName name) {
425 return getAttributeNameForIndex(name, 0);
426 }
427
428 static constexpr ::llvm::StringLiteral getOperationName() {
429 return ::llvm::StringLiteral("poly.read_const");
430 }
431
432 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
433 return {index, 1};
434 }
435
436 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
437 auto valueRange = getODSOperandIndexAndLength(index);
438 return {std::next(getOperation()->operand_begin(), valueRange.first),
439 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
440 }
441
442 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
443 return {index, 1};
444 }
445
446 ::mlir::Operation::result_range getODSResults(unsigned index) {
447 auto valueRange = getODSResultIndexAndLength(index);
448 return {std::next(getOperation()->result_begin(), valueRange.first),
449 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
450 }
451
452 ::mlir::TypedValue<::mlir::Type> getVal() {
453 return ::llvm::cast<::mlir::TypedValue<::mlir::Type>>(*getODSResults(0).begin());
454 }
455
456 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
457 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
458 static llvm::hash_code computePropertiesHash(const Properties &prop);
459 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
460 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
461 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
462 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
463 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
464 void writeProperties(::mlir::DialectBytecodeWriter &writer);
465 ::mlir::FlatSymbolRefAttr getConstNameAttr() {
466 return ::llvm::cast<::mlir::FlatSymbolRefAttr>(getProperties().const_name);
467 }
468
469 ::llvm::StringRef getConstName();
470 void setConstNameAttr(::mlir::FlatSymbolRefAttr attr) {
471 getProperties().const_name = attr;
472 }
473
474 void setConstName(::llvm::StringRef attrValue);
475 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type val, ::mlir::FlatSymbolRefAttr const_name);
476 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::FlatSymbolRefAttr const_name);
477 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type val, ::llvm::StringRef const_name);
478 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::llvm::StringRef const_name);
479 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
480 ::llvm::LogicalResult verifyInvariantsImpl();
481 ::llvm::LogicalResult verifyInvariants();
482 ::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable);
483 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
484 void print(::mlir::OpAsmPrinter &_odsPrinter);
485 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
486private:
487 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
488 return getAttributeNameForIndex((*this)->getName(), index);
489 }
490
491 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
492 assert(index < 1 && "invalid attribute index");
493 assert(name.getStringRef() == getOperationName() && "invalid operation name");
494 assert(name.isRegistered() && "Operation isn't registered, missing a "
495 "dependent dialect loading?");
496 return name.getAttributeNames()[index];
497 }
498
499public:
500};
501} // namespace polymorphic
502} // namespace llzk
503MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::ConstReadOp)
504
505namespace llzk {
506namespace polymorphic {
507
508//===----------------------------------------------------------------------===//
509// ::llzk::polymorphic::TemplateExprOp declarations
510//===----------------------------------------------------------------------===//
511
512namespace detail {
514public:
515 struct Properties {
516 using sym_nameTy = ::mlir::StringAttr;
518
519 auto getSymName() {
520 auto &propStorage = this->sym_name;
521 return ::llvm::cast<::mlir::StringAttr>(propStorage);
522 }
523 void setSymName(const ::mlir::StringAttr &propValue) {
524 this->sym_name = propValue;
525 }
526 bool operator==(const Properties &rhs) const {
527 return
528 rhs.sym_name == this->sym_name &&
529 true;
530 }
531 bool operator!=(const Properties &rhs) const {
532 return !(*this == rhs);
533 }
534 };
535protected:
536 ::mlir::DictionaryAttr odsAttrs;
537 ::std::optional<::mlir::OperationName> odsOpName;
539 ::mlir::RegionRange odsRegions;
540public:
541 TemplateExprOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
542 odsOpName.emplace("poly.expr", odsAttrs.getContext());
543 }
544
546
547 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
548 return {index, 1};
549 }
550
552 return properties;
553 }
554
555 ::mlir::DictionaryAttr getAttributes() {
556 return odsAttrs;
557 }
558
559 ::mlir::StringAttr getSymNameAttr() {
560 auto attr = ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
561 return attr;
562 }
563
564 ::llvm::StringRef getSymName();
565 ::mlir::Region &getInitializerRegion() {
566 return *odsRegions[0];
567 }
568
569 ::mlir::RegionRange getRegions() {
570 return odsRegions;
571 }
572
573};
574} // namespace detail
575template <typename RangeT>
577 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
579public:
580 TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
581
582 TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : TemplateExprOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
583
584 TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : TemplateExprOpGenericAdaptor(values, attrs, Properties{}, {}) {}
585
586 TemplateExprOpGenericAdaptor(RangeT values, const TemplateExprOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
587
588 template <typename LateInst = TemplateExprOp, typename = std::enable_if_t<std::is_same_v<LateInst, TemplateExprOp>>>
589 TemplateExprOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
590
591 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
592 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
593 }
594
595 RangeT getODSOperands(unsigned index) {
596 auto valueRange = getODSOperandIndexAndLength(index);
597 return {std::next(odsOperands.begin(), valueRange.first),
598 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
599 }
600
601 RangeT getOperands() {
602 return odsOperands;
603 }
604
605private:
606 RangeT odsOperands;
607};
608class TemplateExprOpAdaptor : public TemplateExprOpGenericAdaptor<::mlir::ValueRange> {
609public:
612
613 ::llvm::LogicalResult verify(::mlir::Location loc);
614};
615class TemplateExprOp : public ::mlir::Op<TemplateExprOp, ::mlir::OpTrait::OneRegion, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::mlir::OpTrait::HasParent<::llzk::polymorphic::TemplateOp>::Impl, ::mlir::OpTrait::NoRegionArguments, ::mlir::OpTrait::SingleBlock, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::SymbolOpInterface::Trait, ::llzk::polymorphic::TemplateSymbolBindingOpInterface::Trait, ::mlir::SymbolUserOpInterface::Trait, ::mlir::OpTrait::IsIsolatedFromAbove> {
616public:
617 using Op::Op;
618 using Op::print;
620 template <typename RangeT>
624 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
625 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("sym_name")};
626 return ::llvm::ArrayRef(attrNames);
627 }
628
629 ::mlir::StringAttr getSymNameAttrName() {
630 return getAttributeNameForIndex(0);
631 }
632
633 static ::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name) {
634 return getAttributeNameForIndex(name, 0);
635 }
636
637 static constexpr ::llvm::StringLiteral getOperationName() {
638 return ::llvm::StringLiteral("poly.expr");
639 }
640
641 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
642 return {index, 1};
643 }
644
645 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
646 auto valueRange = getODSOperandIndexAndLength(index);
647 return {std::next(getOperation()->operand_begin(), valueRange.first),
648 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
649 }
650
651 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
652 return {index, 1};
653 }
654
655 ::mlir::Operation::result_range getODSResults(unsigned index) {
656 auto valueRange = getODSResultIndexAndLength(index);
657 return {std::next(getOperation()->result_begin(), valueRange.first),
658 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
659 }
660
661 ::mlir::Region &getInitializerRegion() {
662 return (*this)->getRegion(0);
663 }
664
665 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
666 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
667 static llvm::hash_code computePropertiesHash(const Properties &prop);
668 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
669 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
670 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
671 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
672 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
673 void writeProperties(::mlir::DialectBytecodeWriter &writer);
674 ::mlir::StringAttr getSymNameAttr() {
675 return ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
676 }
677
678 ::llvm::StringRef getSymName();
679 void setSymNameAttr(::mlir::StringAttr attr) {
680 getProperties().sym_name = attr;
681 }
682
683 void setSymName(::llvm::StringRef attrValue);
684 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name);
685 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::StringAttr sym_name);
686 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef sym_name);
687 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::llvm::StringRef sym_name);
688 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
689 ::llvm::LogicalResult verifyInvariantsImpl();
690 ::llvm::LogicalResult verifyInvariants();
691 ::llvm::LogicalResult verifyRegions();
692 ::std::optional<::mlir::Type> getTypeOpt();
693 ::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable);
694 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
695 void print(::mlir::OpAsmPrinter &_odsPrinter);
696private:
697 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
698 return getAttributeNameForIndex((*this)->getName(), index);
699 }
700
701 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
702 assert(index < 1 && "invalid attribute index");
703 assert(name.getStringRef() == getOperationName() && "invalid operation name");
704 assert(name.isRegistered() && "Operation isn't registered, missing a "
705 "dependent dialect loading?");
706 return name.getAttributeNames()[index];
707 }
708
709public:
711 ::mlir::Type getType();
712};
713} // namespace polymorphic
714} // namespace llzk
715MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::TemplateExprOp)
716
717namespace llzk {
718namespace polymorphic {
719
720//===----------------------------------------------------------------------===//
721// ::llzk::polymorphic::TemplateOp declarations
722//===----------------------------------------------------------------------===//
723
724namespace detail {
726public:
727 struct Properties {
728 using sym_nameTy = ::mlir::StringAttr;
730
731 auto getSymName() {
732 auto &propStorage = this->sym_name;
733 return ::llvm::cast<::mlir::StringAttr>(propStorage);
734 }
735 void setSymName(const ::mlir::StringAttr &propValue) {
736 this->sym_name = propValue;
737 }
738 bool operator==(const Properties &rhs) const {
739 return
740 rhs.sym_name == this->sym_name &&
741 true;
742 }
743 bool operator!=(const Properties &rhs) const {
744 return !(*this == rhs);
745 }
746 };
747protected:
748 ::mlir::DictionaryAttr odsAttrs;
749 ::std::optional<::mlir::OperationName> odsOpName;
751 ::mlir::RegionRange odsRegions;
752public:
753 TemplateOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
754 odsOpName.emplace("poly.template", odsAttrs.getContext());
755 }
756
758
759 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
760 return {index, 1};
761 }
762
764 return properties;
765 }
766
767 ::mlir::DictionaryAttr getAttributes() {
768 return odsAttrs;
769 }
770
771 ::mlir::StringAttr getSymNameAttr() {
772 auto attr = ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
773 return attr;
774 }
775
776 ::llvm::StringRef getSymName();
777 ::mlir::Region &getBodyRegion() {
778 return *odsRegions[0];
779 }
780
781 ::mlir::RegionRange getRegions() {
782 return odsRegions;
783 }
784
785};
786} // namespace detail
787template <typename RangeT>
789 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
791public:
792 TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
793
794 TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : TemplateOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
795
796 TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : TemplateOpGenericAdaptor(values, attrs, Properties{}, {}) {}
797
798 TemplateOpGenericAdaptor(RangeT values, const TemplateOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
799
800 template <typename LateInst = TemplateOp, typename = std::enable_if_t<std::is_same_v<LateInst, TemplateOp>>>
801 TemplateOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
802
803 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
804 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
805 }
806
807 RangeT getODSOperands(unsigned index) {
808 auto valueRange = getODSOperandIndexAndLength(index);
809 return {std::next(odsOperands.begin(), valueRange.first),
810 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
811 }
812
813 RangeT getOperands() {
814 return odsOperands;
815 }
816
817private:
818 RangeT odsOperands;
819};
820class TemplateOpAdaptor : public TemplateOpGenericAdaptor<::mlir::ValueRange> {
821public:
824
825 ::llvm::LogicalResult verify(::mlir::Location loc);
826};
827class TemplateOp : public ::mlir::Op<TemplateOp, ::mlir::OpTrait::OneRegion, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::mlir::OpTrait::HasParent<::mlir::ModuleOp>::Impl, ::mlir::OpTrait::NoRegionArguments, ::mlir::OpTrait::NoTerminator, ::mlir::OpTrait::SingleBlock, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::SymbolOpInterface::Trait, ::llzk::LLZKSymbolTableImplTrait, ::mlir::OpTrait::SymbolTable, ::mlir::OpTrait::IsIsolatedFromAbove> {
828public:
829 using Op::Op;
830 using Op::print;
832 template <typename RangeT>
836 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
837 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("sym_name")};
838 return ::llvm::ArrayRef(attrNames);
839 }
840
841 ::mlir::StringAttr getSymNameAttrName() {
842 return getAttributeNameForIndex(0);
843 }
844
845 static ::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name) {
846 return getAttributeNameForIndex(name, 0);
847 }
848
849 static constexpr ::llvm::StringLiteral getOperationName() {
850 return ::llvm::StringLiteral("poly.template");
851 }
852
853 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
854 return {index, 1};
855 }
856
857 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
858 auto valueRange = getODSOperandIndexAndLength(index);
859 return {std::next(getOperation()->operand_begin(), valueRange.first),
860 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
861 }
862
863 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
864 return {index, 1};
865 }
866
867 ::mlir::Operation::result_range getODSResults(unsigned index) {
868 auto valueRange = getODSResultIndexAndLength(index);
869 return {std::next(getOperation()->result_begin(), valueRange.first),
870 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
871 }
872
873 ::mlir::Region &getBodyRegion() {
874 return (*this)->getRegion(0);
875 }
876
877 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
878 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
879 static llvm::hash_code computePropertiesHash(const Properties &prop);
880 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
881 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
882 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
883 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
884 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
885 void writeProperties(::mlir::DialectBytecodeWriter &writer);
886 ::mlir::StringAttr getSymNameAttr() {
887 return ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
888 }
889
890 ::llvm::StringRef getSymName();
891 void setSymNameAttr(::mlir::StringAttr attr) {
892 getProperties().sym_name = attr;
893 }
894
895 void setSymName(::llvm::StringRef attrValue);
896 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name);
897 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::StringAttr sym_name);
898 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef sym_name);
899 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::llvm::StringRef sym_name);
900 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
901 ::llvm::LogicalResult verifyInvariantsImpl();
902 ::llvm::LogicalResult verifyInvariants();
903 ::llvm::LogicalResult verify();
904 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
905 void print(::mlir::OpAsmPrinter &_odsPrinter);
906private:
907 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
908 return getAttributeNameForIndex((*this)->getName(), index);
909 }
910
911 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
912 assert(index < 1 && "invalid attribute index");
913 assert(name.getStringRef() == getOperationName() && "invalid operation name");
914 assert(name.isRegistered() && "Operation isn't registered, missing a "
915 "dependent dialect loading?");
916 return name.getAttributeNames()[index];
917 }
918
919public:
922 template <TemplateSymbolBindingOp OpT>
923 inline ::llvm::iterator_range<::mlir::Region::op_iterator<OpT>> getConstOps() {
924 return getBodyRegion().getOps<OpT>();
925 }
926
928 template <TemplateSymbolBindingOp OpT>
929 inline bool hasConstOps() {
930 return !getConstOps<OpT>().empty();
931 }
932
934 template <TemplateSymbolBindingOp OpT>
935 inline size_t numConstOps() {
936 return llvm::range_size(getConstOps<OpT>());
937 }
938
942 template <TemplateSymbolBindingOp OpT>
943 ::llvm::SmallVector<::mlir::Attribute> getConstNames() {
944 return ::llvm::to_vector(::llvm::map_range(getConstOps<OpT>(), [](auto p) -> ::mlir::Attribute {
945 return ::mlir::FlatSymbolRefAttr::get(p.getNameAttr());
946 }));
947 }
948
950 template <TemplateSymbolBindingOp OpT>
951 inline bool hasConstNamed(::mlir::StringRef find) {
952 return ::llvm::any_of(getConstOps<OpT>(), [&](OpT op) {
953 return op.getName() == find;
954 });
955 }
956
958 template <TemplateSymbolBindingOp OpT>
959 inline bool hasConstNamed(::mlir::StringAttr find) {
960 return hasConstNamed<OpT>(find.strref());
961 }
962
964 template <TemplateSymbolBindingOp OpT>
965 inline bool hasConstNamed(::mlir::FlatSymbolRefAttr find) {
966 return hasConstNamed<OpT>(find.getRootReference());
967 }
968
970 template <TemplateSymbolBindingOp OpT>
971 inline OpT getConstNamed(::mlir::StringRef find) {
972 auto range = getConstOps<OpT>();
973 auto it = ::llvm::find_if(range, [&find](OpT op) { return op.getName() == find; });
974 return it != range.end() ? *it : OpT{};
975 }
976
978 template <TemplateSymbolBindingOp OpT>
979 inline OpT getConstNamed(::mlir::StringAttr find) {
980 return getConstNamed<OpT>(find.strref());
981 }
982
984 template <TemplateSymbolBindingOp OpT>
985 inline OpT getConstNamed(::mlir::FlatSymbolRefAttr find) {
986 return getConstNamed<OpT>(find.getRootReference());
987 }
988};
989} // namespace polymorphic
990} // namespace llzk
991MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::TemplateOp)
992
993namespace llzk {
994namespace polymorphic {
995
996//===----------------------------------------------------------------------===//
997// ::llzk::polymorphic::TemplateParamOp declarations
998//===----------------------------------------------------------------------===//
999
1000namespace detail {
1002public:
1003 struct Properties {
1004 using sym_nameTy = ::mlir::StringAttr;
1006
1007 auto getSymName() {
1008 auto &propStorage = this->sym_name;
1009 return ::llvm::cast<::mlir::StringAttr>(propStorage);
1010 }
1011 void setSymName(const ::mlir::StringAttr &propValue) {
1012 this->sym_name = propValue;
1013 }
1014 using type_optTy = ::mlir::TypeAttr;
1016
1017 auto getTypeOpt() {
1018 auto &propStorage = this->type_opt;
1019 return ::llvm::dyn_cast_or_null<::mlir::TypeAttr>(propStorage);
1020 }
1021 void setTypeOpt(const ::mlir::TypeAttr &propValue) {
1022 this->type_opt = propValue;
1023 }
1024 bool operator==(const Properties &rhs) const {
1025 return
1026 rhs.sym_name == this->sym_name &&
1027 rhs.type_opt == this->type_opt &&
1028 true;
1029 }
1030 bool operator!=(const Properties &rhs) const {
1031 return !(*this == rhs);
1032 }
1033 };
1034protected:
1035 ::mlir::DictionaryAttr odsAttrs;
1036 ::std::optional<::mlir::OperationName> odsOpName;
1038 ::mlir::RegionRange odsRegions;
1039public:
1040 TemplateParamOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), properties(properties), odsRegions(regions) { if (odsAttrs)
1041 odsOpName.emplace("poly.param", odsAttrs.getContext());
1042 }
1043
1045
1046 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1047 return {index, 1};
1048 }
1049
1051 return properties;
1052 }
1053
1054 ::mlir::DictionaryAttr getAttributes() {
1055 return odsAttrs;
1056 }
1057
1058 ::mlir::StringAttr getSymNameAttr() {
1059 auto attr = ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
1060 return attr;
1061 }
1062
1063 ::llvm::StringRef getSymName();
1064 ::mlir::TypeAttr getTypeOptAttr() {
1065 auto attr = ::llvm::dyn_cast_or_null<::mlir::TypeAttr>(getProperties().type_opt);
1066 return attr;
1067 }
1068
1069 ::std::optional<::mlir::Type> getTypeOpt();
1070};
1071} // namespace detail
1072template <typename RangeT>
1074 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1076public:
1077 TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1078
1079 TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : TemplateParamOpGenericAdaptor(values, attrs, (properties ? *properties.as<Properties *>() : Properties{}), regions) {}
1080
1081 TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = nullptr) : TemplateParamOpGenericAdaptor(values, attrs, Properties{}, {}) {}
1082
1083 TemplateParamOpGenericAdaptor(RangeT values, const TemplateParamOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1084
1085 template <typename LateInst = TemplateParamOp, typename = std::enable_if_t<std::is_same_v<LateInst, TemplateParamOp>>>
1086 TemplateParamOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1087
1088 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1089 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1090 }
1091
1092 RangeT getODSOperands(unsigned index) {
1093 auto valueRange = getODSOperandIndexAndLength(index);
1094 return {std::next(odsOperands.begin(), valueRange.first),
1095 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1096 }
1097
1098 RangeT getOperands() {
1099 return odsOperands;
1100 }
1101
1102private:
1103 RangeT odsOperands;
1104};
1105class TemplateParamOpAdaptor : public TemplateParamOpGenericAdaptor<::mlir::ValueRange> {
1106public:
1109
1110 ::llvm::LogicalResult verify(::mlir::Location loc);
1111};
1112class TemplateParamOp : public ::mlir::Op<TemplateParamOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::ZeroOperands, ::mlir::OpTrait::HasParent<::llzk::polymorphic::TemplateOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::BytecodeOpInterface::Trait, ::mlir::SymbolOpInterface::Trait, ::llzk::polymorphic::TemplateSymbolBindingOpInterface::Trait, ::mlir::SymbolUserOpInterface::Trait> {
1113public:
1114 using Op::Op;
1115 using Op::print;
1117 template <typename RangeT>
1121 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1122 static ::llvm::StringRef attrNames[] = {::llvm::StringRef("sym_name"), ::llvm::StringRef("type_opt")};
1123 return ::llvm::ArrayRef(attrNames);
1124 }
1125
1126 ::mlir::StringAttr getSymNameAttrName() {
1127 return getAttributeNameForIndex(0);
1128 }
1129
1130 static ::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name) {
1131 return getAttributeNameForIndex(name, 0);
1132 }
1133
1134 ::mlir::StringAttr getTypeOptAttrName() {
1135 return getAttributeNameForIndex(1);
1136 }
1137
1138 static ::mlir::StringAttr getTypeOptAttrName(::mlir::OperationName name) {
1139 return getAttributeNameForIndex(name, 1);
1140 }
1141
1142 static constexpr ::llvm::StringLiteral getOperationName() {
1143 return ::llvm::StringLiteral("poly.param");
1144 }
1145
1146 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1147 return {index, 1};
1148 }
1149
1150 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1151 auto valueRange = getODSOperandIndexAndLength(index);
1152 return {std::next(getOperation()->operand_begin(), valueRange.first),
1153 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1154 }
1155
1156 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1157 return {index, 1};
1158 }
1159
1160 ::mlir::Operation::result_range getODSResults(unsigned index) {
1161 auto valueRange = getODSResultIndexAndLength(index);
1162 return {std::next(getOperation()->result_begin(), valueRange.first),
1163 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1164 }
1165
1166 static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1167 static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop);
1168 static llvm::hash_code computePropertiesHash(const Properties &prop);
1169 static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name);
1170 static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value);
1171 static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs);
1172 static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError);
1173 static ::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state);
1174 void writeProperties(::mlir::DialectBytecodeWriter &writer);
1175 ::mlir::StringAttr getSymNameAttr() {
1176 return ::llvm::cast<::mlir::StringAttr>(getProperties().sym_name);
1177 }
1178
1179 ::llvm::StringRef getSymName();
1180 ::mlir::TypeAttr getTypeOptAttr() {
1181 return ::llvm::dyn_cast_or_null<::mlir::TypeAttr>(getProperties().type_opt);
1182 }
1183
1184 ::std::optional<::mlir::Type> getTypeOpt();
1185 void setSymNameAttr(::mlir::StringAttr attr) {
1186 getProperties().sym_name = attr;
1187 }
1188
1189 void setSymName(::llvm::StringRef attrValue);
1190 void setTypeOptAttr(::mlir::TypeAttr attr) {
1191 getProperties().type_opt = attr;
1192 }
1193
1194 void setTypeOpt(::std::optional<::mlir::Type> attrValue);
1195 ::mlir::Attribute removeTypeOptAttr() {
1196 auto &attr = getProperties().type_opt;
1197 attr = {};
1198 return attr;
1199 }
1200
1201 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name, /*optional*/::mlir::TypeAttr type_opt);
1202 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::StringAttr sym_name, /*optional*/::mlir::TypeAttr type_opt);
1203 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::llvm::StringRef sym_name, /*optional*/::mlir::TypeAttr type_opt);
1204 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::llvm::StringRef sym_name, /*optional*/::mlir::TypeAttr type_opt);
1205 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1206 ::llvm::LogicalResult verifyInvariantsImpl();
1207 ::llvm::LogicalResult verifyInvariants();
1208 ::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable);
1209 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1210 void print(::mlir::OpAsmPrinter &_odsPrinter);
1211private:
1212 ::mlir::StringAttr getAttributeNameForIndex(unsigned index) {
1213 return getAttributeNameForIndex((*this)->getName(), index);
1214 }
1215
1216 static ::mlir::StringAttr getAttributeNameForIndex(::mlir::OperationName name, unsigned index) {
1217 assert(index < 2 && "invalid attribute index");
1218 assert(name.getStringRef() == getOperationName() && "invalid operation name");
1219 assert(name.isRegistered() && "Operation isn't registered, missing a "
1220 "dependent dialect loading?");
1221 return name.getAttributeNames()[index];
1222 }
1223
1224public:
1225};
1226} // namespace polymorphic
1227} // namespace llzk
1228MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::TemplateParamOp)
1229
1230namespace llzk {
1231namespace polymorphic {
1232
1233//===----------------------------------------------------------------------===//
1234// ::llzk::polymorphic::UnifiableCastOp declarations
1235//===----------------------------------------------------------------------===//
1236
1237namespace detail {
1239public:
1240protected:
1241 ::mlir::DictionaryAttr odsAttrs;
1242 ::std::optional<::mlir::OperationName> odsOpName;
1243 ::mlir::RegionRange odsRegions;
1244public:
1245 UnifiableCastOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
1246 odsOpName.emplace("poly.unifiable_cast", odsAttrs.getContext());
1247 }
1248
1249 UnifiableCastOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
1250
1251 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1252 return {index, 1};
1253 }
1254
1255 ::mlir::DictionaryAttr getAttributes() {
1256 return odsAttrs;
1257 }
1258
1259};
1260} // namespace detail
1261template <typename RangeT>
1263 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1265public:
1266 UnifiableCastOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1267
1268 UnifiableCastOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : UnifiableCastOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
1269
1270 UnifiableCastOpGenericAdaptor(RangeT values, const UnifiableCastOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1271
1272 template <typename LateInst = UnifiableCastOp, typename = std::enable_if_t<std::is_same_v<LateInst, UnifiableCastOp>>>
1273 UnifiableCastOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1274
1275 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1276 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1277 }
1278
1279 RangeT getODSOperands(unsigned index) {
1280 auto valueRange = getODSOperandIndexAndLength(index);
1281 return {std::next(odsOperands.begin(), valueRange.first),
1282 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1283 }
1284
1285 ValueT getInput() {
1286 return (*getODSOperands(0).begin());
1287 }
1288
1289 RangeT getOperands() {
1290 return odsOperands;
1291 }
1292
1293private:
1294 RangeT odsOperands;
1295};
1296class UnifiableCastOpAdaptor : public UnifiableCastOpGenericAdaptor<::mlir::ValueRange> {
1297public:
1300
1301 ::llvm::LogicalResult verify(::mlir::Location loc);
1302};
1303class UnifiableCastOp : public ::mlir::Op<UnifiableCastOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::OneResult, ::mlir::OpTrait::OneTypedResult<::mlir::Type>::Impl, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::OpInvariants, ::mlir::ConditionallySpeculatable::Trait, ::mlir::OpTrait::AlwaysSpeculatableImplTrait, ::mlir::MemoryEffectOpInterface::Trait> {
1304public:
1305 using Op::Op;
1306 using Op::print;
1308 template <typename RangeT>
1311 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1312 return {};
1313 }
1314
1315 static constexpr ::llvm::StringLiteral getOperationName() {
1316 return ::llvm::StringLiteral("poly.unifiable_cast");
1317 }
1318
1319 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1320 return {index, 1};
1321 }
1322
1323 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1324 auto valueRange = getODSOperandIndexAndLength(index);
1325 return {std::next(getOperation()->operand_begin(), valueRange.first),
1326 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1327 }
1328
1329 ::mlir::TypedValue<::mlir::Type> getInput() {
1330 return ::llvm::cast<::mlir::TypedValue<::mlir::Type>>(*getODSOperands(0).begin());
1331 }
1332
1333 ::mlir::OpOperand &getInputMutable() {
1334 auto range = getODSOperandIndexAndLength(0);
1335 return getOperation()->getOpOperand(range.first);
1336 }
1337
1338 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1339 return {index, 1};
1340 }
1341
1342 ::mlir::Operation::result_range getODSResults(unsigned index) {
1343 auto valueRange = getODSResultIndexAndLength(index);
1344 return {std::next(getOperation()->result_begin(), valueRange.first),
1345 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1346 }
1347
1348 ::mlir::TypedValue<::mlir::Type> getResult() {
1349 return ::llvm::cast<::mlir::TypedValue<::mlir::Type>>(*getODSResults(0).begin());
1350 }
1351
1352 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value input);
1353 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value input);
1354 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1355 ::llvm::LogicalResult verifyInvariantsImpl();
1356 ::llvm::LogicalResult verifyInvariants();
1357 ::llvm::LogicalResult verify();
1358 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1359 void print(::mlir::OpAsmPrinter &_odsPrinter);
1360 void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect>> &effects);
1361public:
1362};
1363} // namespace polymorphic
1364} // namespace llzk
1365MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::UnifiableCastOp)
1366
1367namespace llzk {
1368namespace polymorphic {
1369
1370//===----------------------------------------------------------------------===//
1371// ::llzk::polymorphic::YieldOp declarations
1372//===----------------------------------------------------------------------===//
1373
1374namespace detail {
1376public:
1377protected:
1378 ::mlir::DictionaryAttr odsAttrs;
1379 ::std::optional<::mlir::OperationName> odsOpName;
1380 ::mlir::RegionRange odsRegions;
1381public:
1382 YieldOpGenericAdaptorBase(::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : odsAttrs(attrs), odsRegions(regions) { if (odsAttrs)
1383 odsOpName.emplace("poly.yield", odsAttrs.getContext());
1384 }
1385
1386 YieldOpGenericAdaptorBase(::mlir::Operation *op) : odsAttrs(op->getRawDictionaryAttrs()), odsOpName(op->getName()), odsRegions(op->getRegions()) {}
1387
1388 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize) {
1389 return {index, 1};
1390 }
1391
1392 ::mlir::DictionaryAttr getAttributes() {
1393 return odsAttrs;
1394 }
1395
1396};
1397} // namespace detail
1398template <typename RangeT>
1400 using ValueT = ::llvm::detail::ValueOfRange<RangeT>;
1402public:
1403 YieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs = {}, const ::mlir::EmptyProperties &properties = {}, ::mlir::RegionRange regions = {}) : Base(attrs, properties, regions), odsOperands(values) {}
1404
1405 YieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions = {}) : YieldOpGenericAdaptor(values, attrs, (properties ? *properties.as<::mlir::EmptyProperties *>() : ::mlir::EmptyProperties{}), regions) {}
1406
1407 YieldOpGenericAdaptor(RangeT values, const YieldOpGenericAdaptorBase &base) : Base(base), odsOperands(values) {}
1408
1409 template <typename LateInst = YieldOp, typename = std::enable_if_t<std::is_same_v<LateInst, YieldOp>>>
1410 YieldOpGenericAdaptor(RangeT values, LateInst op) : Base(op), odsOperands(values) {}
1411
1412 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1413 return Base::getODSOperandIndexAndLength(index, odsOperands.size());
1414 }
1415
1416 RangeT getODSOperands(unsigned index) {
1417 auto valueRange = getODSOperandIndexAndLength(index);
1418 return {std::next(odsOperands.begin(), valueRange.first),
1419 std::next(odsOperands.begin(), valueRange.first + valueRange.second)};
1420 }
1421
1422 ValueT getVal() {
1423 return (*getODSOperands(0).begin());
1424 }
1425
1426 RangeT getOperands() {
1427 return odsOperands;
1428 }
1429
1430private:
1431 RangeT odsOperands;
1432};
1433class YieldOpAdaptor : public YieldOpGenericAdaptor<::mlir::ValueRange> {
1434public:
1437
1438 ::llvm::LogicalResult verify(::mlir::Location loc);
1439};
1440class YieldOp : public ::mlir::Op<YieldOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::OneOperand, ::mlir::OpTrait::HasParent<::llzk::polymorphic::TemplateExprOp>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::RegionBranchTerminatorOpInterface::Trait, ::mlir::OpTrait::ReturnLike, ::mlir::OpTrait::IsTerminator> {
1441public:
1442 using Op::Op;
1443 using Op::print;
1445 template <typename RangeT>
1448 static ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames() {
1449 return {};
1450 }
1451
1452 static constexpr ::llvm::StringLiteral getOperationName() {
1453 return ::llvm::StringLiteral("poly.yield");
1454 }
1455
1456 std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index) {
1457 return {index, 1};
1458 }
1459
1460 ::mlir::Operation::operand_range getODSOperands(unsigned index) {
1461 auto valueRange = getODSOperandIndexAndLength(index);
1462 return {std::next(getOperation()->operand_begin(), valueRange.first),
1463 std::next(getOperation()->operand_begin(), valueRange.first + valueRange.second)};
1464 }
1465
1466 ::mlir::TypedValue<::mlir::Type> getVal() {
1467 return ::llvm::cast<::mlir::TypedValue<::mlir::Type>>(*getODSOperands(0).begin());
1468 }
1469
1470 ::mlir::OpOperand &getValMutable() {
1471 auto range = getODSOperandIndexAndLength(0);
1472 return getOperation()->getOpOperand(range.first);
1473 }
1474
1475 std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index) {
1476 return {index, 1};
1477 }
1478
1479 ::mlir::Operation::result_range getODSResults(unsigned index) {
1480 auto valueRange = getODSResultIndexAndLength(index);
1481 return {std::next(getOperation()->result_begin(), valueRange.first),
1482 std::next(getOperation()->result_begin(), valueRange.first + valueRange.second)};
1483 }
1484
1485 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value val);
1486 static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::Value val);
1487 static void build(::mlir::OpBuilder &, ::mlir::OperationState &odsState, ::mlir::TypeRange resultTypes, ::mlir::ValueRange operands, ::llvm::ArrayRef<::mlir::NamedAttribute> attributes = {});
1488 ::llvm::LogicalResult verifyInvariantsImpl();
1489 ::llvm::LogicalResult verifyInvariants();
1490 ::mlir::MutableOperandRange getMutableSuccessorOperands(::mlir::RegionBranchPoint point);
1491 static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result);
1492 void print(::mlir::OpAsmPrinter &_odsPrinter);
1493public:
1494};
1495} // namespace polymorphic
1496} // namespace llzk
1497MLIR_DECLARE_EXPLICIT_TYPE_ID(::llzk::polymorphic::YieldOp)
1498
1499
1500#endif // GET_OP_CLASSES
1501
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:196
ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:129
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:140
ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:133
ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:131
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:144
ApplyMapOpGenericAdaptor(RangeT values, const ApplyMapOpGenericAdaptorBase &base)
Definition Ops.h.inc:135
ApplyMapOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:138
ApplyMapOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:129
::mlir::ValueRange getSymbolOperands()
Returns all symbol operands.
Definition Ops.h.inc:294
::mlir::AffineMapAttr getMapAttr()
Definition Ops.h.inc:233
::mlir::IntegerAttr getNumDimsAttr()
Definition Ops.h.inc:238
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.cpp.inc:210
::mlir::ValueRange getDimOperands()
Returns all dimension operands.
Definition Ops.h.inc:287
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:218
::mlir::affine::AffineValueMap getAffineValueMap()
Returns the affine value map computed from this operation.
Definition Ops.h.inc:282
::mlir::Operation::operand_range getMapOperands()
Definition Ops.h.inc:209
::mlir::StringAttr getNumDimsAttrName(::mlir::OperationName name)
Definition Ops.h.inc:194
::mlir::OpFoldResult fold(FoldAdaptor adaptor)
Definition Ops.cpp:247
::llvm::LogicalResult verify()
Definition Ops.cpp:227
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:476
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:175
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:198
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:443
::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:435
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:429
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:294
FoldAdaptor::Properties Properties
Definition Ops.h.inc:176
::mlir::StringAttr getMapAttrName(::mlir::OperationName name)
Definition Ops.h.inc:186
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:203
ApplyMapOpAdaptor Adaptor
Definition Ops.h.inc:172
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::AffineMapAttr map, ::mlir::ValueRange mapOperands={})
Definition Ops.cpp.inc:376
::mlir::StringAttr getMapAttrName()
Definition Ops.h.inc:182
::mlir::AffineMap getMap()
Definition Ops.cpp.inc:358
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:177
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:321
ApplyMapOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:174
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:352
void setMap(::mlir::AffineMap attrValue)
Definition Ops.cpp.inc:368
void setNumDimsAttr(::mlir::IntegerAttr attr)
Definition Ops.h.inc:248
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:271
::mlir::StringAttr getNumDimsAttrName()
Definition Ops.h.inc:190
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:327
::mlir::MutableOperandRange getMapOperandsMutable()
Definition Ops.cpp.inc:228
::mlir::AffineMap getAffineMap()
Returns the affine map to be applied by this operation.
Definition Ops.h.inc:279
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:397
void setMapAttr(::mlir::AffineMapAttr attr)
Definition Ops.h.inc:243
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:309
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:342
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:234
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:487
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:300
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:214
void setNumDims(::llvm::APInt attrValue)
Definition Ops.cpp.inc:372
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:512
ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:371
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:382
ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:373
ConstReadOpGenericAdaptor(RangeT values, const ConstReadOpGenericAdaptorBase &base)
Definition Ops.h.inc:377
ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:371
ConstReadOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:380
ConstReadOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:375
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:598
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:432
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:436
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:674
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:428
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:415
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:705
FoldAdaptor::Properties Properties
Definition Ops.h.inc:414
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:582
::mlir::TypedValue<::mlir::Type > getVal()
Definition Ops.h.inc:452
::mlir::StringAttr getConstNameAttrName()
Definition Ops.h.inc:420
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:544
ConstReadOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:412
::mlir::StringAttr getConstNameAttrName(::mlir::OperationName name)
Definition Ops.h.inc:424
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:571
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:446
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:521
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:560
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:442
void setConstName(::llvm::StringRef attrValue)
Definition Ops.cpp.inc:608
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:652
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:722
void setConstNameAttr(::mlir::FlatSymbolRefAttr attr)
Definition Ops.h.inc:470
::mlir::FlatSymbolRefAttr getConstNameAttr()
Definition Ops.h.inc:465
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type val, ::mlir::FlatSymbolRefAttr const_name)
Definition Ops.cpp.inc:612
ConstReadOpAdaptor Adaptor
Definition Ops.h.inc:410
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:565
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:578
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:591
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:670
::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable)
Definition Ops.cpp:185
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:413
::llvm::StringRef getConstName()
Definition Ops.cpp.inc:603
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:747
TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:580
TemplateExprOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:589
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:591
TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:580
TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:584
TemplateExprOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:582
TemplateExprOpGenericAdaptor(RangeT values, const TemplateExprOpGenericAdaptorBase &base)
Definition Ops.h.inc:586
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:817
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:806
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:651
::mlir::StringAttr getSymNameAttr()
Definition Ops.h.inc:674
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:800
::llvm::LogicalResult verifyRegions()
Definition Ops.cpp:141
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:779
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:622
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:813
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:645
::mlir::Region & getInitializerRegion()
Definition Ops.h.inc:661
::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable)
Definition Ops.cpp:104
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:795
TemplateExprOpAdaptor Adaptor
Definition Ops.h.inc:619
::mlir::Type getType()
Returns the type of the poly.yield op in the initializer region.
Definition Ops.cpp:171
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:624
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:911
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:891
::llvm::StringRef getSymName()
Definition Ops.cpp.inc:838
void setSymName(::llvm::StringRef attrValue)
Definition Ops.cpp.inc:843
::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name)
Definition Ops.h.inc:633
void setSymNameAttr(::mlir::StringAttr attr)
Definition Ops.h.inc:679
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:833
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:756
TemplateExprOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:621
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:826
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:655
FoldAdaptor::Properties Properties
Definition Ops.h.inc:623
::std::optional<::mlir::Type > getTypeOpt()
Definition Ops.cpp:179
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name)
Definition Ops.cpp.inc:847
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:641
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:637
::mlir::StringAttr getSymNameAttrName()
Definition Ops.h.inc:629
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:907
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:936
TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:792
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:968
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:803
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:807
TemplateOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:801
TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:792
TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:794
TemplateOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:796
TemplateOpGenericAdaptor(RangeT values, const TemplateOpGenericAdaptorBase &base)
Definition Ops.h.inc:798
::mlir::Region & getBodyRegion()
Definition Ops.h.inc:873
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1038
::mlir::StringAttr getSymNameAttrName()
Definition Ops.h.inc:841
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:1016
OpT getConstNamed(::mlir::StringRef find)
Return the op of type OpT with the given name within the body region if it exists,...
Definition Ops.h.inc:971
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:1000
::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name)
Definition Ops.h.inc:845
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:1054
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1159
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1134
::llvm::SmallVector<::mlir::Attribute > getConstNames()
Return the names of all ops of type OpT within the body region in the order they are defined.
Definition Ops.h.inc:943
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:1034
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name)
Definition Ops.cpp.inc:1068
OpT getConstNamed(::mlir::FlatSymbolRefAttr find)
Return the op of type OpT with the given name within the body region if it exists,...
Definition Ops.h.inc:985
bool hasConstNamed(::mlir::StringRef find)
Return true if there is an op of type OpT with the given name within the body region.
Definition Ops.h.inc:951
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:1021
FoldAdaptor::Properties Properties
Definition Ops.h.inc:835
OpT getConstNamed(::mlir::StringAttr find)
Return the op of type OpT with the given name within the body region if it exists,...
Definition Ops.h.inc:979
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:853
::mlir::StringAttr getSymNameAttr()
Definition Ops.h.inc:886
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:834
TemplateOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:833
void setSymNameAttr(::mlir::StringAttr attr)
Definition Ops.h.inc:891
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1112
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:857
::llvm::LogicalResult verify()
Verify the optional transform-carried name pattern against current parameters.
Definition Ops.cpp:48
bool hasConstNamed(::mlir::FlatSymbolRefAttr find)
Return true if there is an op of type OpT with the given name within the body region.
Definition Ops.h.inc:965
void setSymName(::llvm::StringRef attrValue)
Definition Ops.cpp.inc:1064
bool hasConstOps()
Return true if there are ops of type OpT within the body region.
Definition Ops.h.inc:929
bool hasConstNamed(::mlir::StringAttr find)
Return true if there is an op of type OpT with the given name within the body region.
Definition Ops.h.inc:959
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:1027
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:1047
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:867
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:849
::llvm::StringRef getSymName()
Definition Ops.cpp.inc:1059
size_t numConstOps()
Return the number of ops of type OpT within the body region.
Definition Ops.h.inc:935
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:977
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:863
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1128
TemplateOpAdaptor Adaptor
Definition Ops.h.inc:831
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:836
inline ::llvm::iterator_range<::mlir::Region::op_iterator< OpT > > getConstOps()
Return ops of type OpT within the body region.
Definition Ops.h.inc:923
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1196
TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1077
TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1077
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1088
TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs=nullptr)
Definition Ops.h.inc:1081
TemplateParamOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1086
TemplateParamOpGenericAdaptor(RangeT values, const TemplateParamOpGenericAdaptorBase &base)
Definition Ops.h.inc:1083
TemplateParamOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1079
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1419
::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1302
void setSymName(::llvm::StringRef attrValue)
Definition Ops.cpp.inc:1344
::mlir::StringAttr getTypeOptAttrName()
Definition Ops.h.inc:1134
void setTypeOpt(::std::optional<::mlir::Type > attrValue)
Definition Ops.cpp.inc:1348
::mlir::Attribute removeTypeOptAttr()
Definition Ops.h.inc:1195
::mlir::TypeAttr getTypeOptAttr()
Definition Ops.h.inc:1180
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::StringAttr sym_name, ::mlir::TypeAttr type_opt)
Definition Ops.cpp.inc:1356
TemplateParamOpAdaptor Adaptor
Definition Ops.h.inc:1116
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1121
::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
Definition Ops.cpp.inc:1246
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
Definition Ops.cpp.inc:1284
void setSymNameAttr(::mlir::StringAttr attr)
Definition Ops.h.inc:1185
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1146
FoldAdaptor::Properties Properties
Definition Ops.h.inc:1120
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1160
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1423
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1150
void writeProperties(::mlir::DialectBytecodeWriter &writer)
Definition Ops.cpp.inc:1327
TemplateParamOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1118
::llvm::LogicalResult verifySymbolUses(::mlir::SymbolTableCollection &symbolTable)
Definition Ops.cpp:96
::mlir::StringAttr getTypeOptAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1138
::llvm::LogicalResult readProperties(::mlir::DialectBytecodeReader &reader, ::mlir::OperationState &state)
Definition Ops.cpp.inc:1317
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1449
::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
Definition Ops.cpp.inc:1209
::mlir::StringAttr getSymNameAttrName()
Definition Ops.h.inc:1126
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1156
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1119
::mlir::StringAttr getSymNameAttr()
Definition Ops.h.inc:1175
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1142
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
Definition Ops.cpp.inc:1296
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1406
::std::optional<::mlir::Type > getTypeOpt()
Definition Ops.cpp.inc:1339
static std::optional< mlir::Attribute > getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
Definition Ops.cpp.inc:1275
void setTypeOptAttr(::mlir::TypeAttr attr)
Definition Ops.h.inc:1190
static llvm::hash_code computePropertiesHash(const Properties &prop)
Definition Ops.cpp.inc:1269
::mlir::StringAttr getSymNameAttrName(::mlir::OperationName name)
Definition Ops.h.inc:1130
UnifiableCastOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1266
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1478
UnifiableCastOpGenericAdaptor(RangeT values, const UnifiableCastOpGenericAdaptorBase &base)
Definition Ops.h.inc:1270
UnifiableCastOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1266
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1275
UnifiableCastOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1273
UnifiableCastOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1268
::llvm::LogicalResult verify()
Definition Ops.cpp:270
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1338
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Type result, ::mlir::Value input)
Definition Ops.cpp.inc:1482
void getEffects(::llvm::SmallVectorImpl<::mlir::SideEffects::EffectInstance<::mlir::MemoryEffects::Effect > > &effects)
Definition Ops.cpp.inc:1568
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1310
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1323
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1315
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1311
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1319
::mlir::OpOperand & getInputMutable()
Definition Ops.h.inc:1333
UnifiableCastOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1309
::mlir::TypedValue<::mlir::Type > getInput()
Definition Ops.h.inc:1329
::mlir::TypedValue<::mlir::Type > getResult()
Definition Ops.h.inc:1348
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1501
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1523
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1342
UnifiableCastOpAdaptor Adaptor
Definition Ops.h.inc:1307
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1529
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1558
::llvm::LogicalResult verify(::mlir::Location loc)
Definition Ops.cpp.inc:1586
YieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1403
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1412
YieldOpGenericAdaptor(RangeT values, LateInst op)
Definition Ops.h.inc:1410
RangeT getODSOperands(unsigned index)
Definition Ops.h.inc:1416
YieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs, ::mlir::OpaqueProperties properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1405
YieldOpGenericAdaptor(RangeT values, const YieldOpGenericAdaptorBase &base)
Definition Ops.h.inc:1407
YieldOpGenericAdaptor(RangeT values, ::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1403
::mlir::OpOperand & getValMutable()
Definition Ops.h.inc:1470
::mlir::MutableOperandRange getMutableSuccessorOperands(::mlir::RegionBranchPoint point)
Definition Ops.cpp.inc:1670
::llvm::LogicalResult verifyInvariantsImpl()
Definition Ops.cpp.inc:1608
void print(::mlir::OpAsmPrinter &_odsPrinter)
Definition Ops.cpp.inc:1654
static ::llvm::ArrayRef<::llvm::StringRef > getAttributeNames()
Definition Ops.h.inc:1448
static constexpr ::llvm::StringLiteral getOperationName()
Definition Ops.h.inc:1452
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index)
Definition Ops.h.inc:1456
GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute > > FoldAdaptor
Definition Ops.h.inc:1447
YieldOpAdaptor Adaptor
Definition Ops.h.inc:1444
::mlir::Operation::result_range getODSResults(unsigned index)
Definition Ops.h.inc:1479
::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)
Definition Ops.cpp.inc:1625
YieldOpGenericAdaptor< RangeT > GenericAdaptor
Definition Ops.h.inc:1446
::llvm::LogicalResult verifyInvariants()
Definition Ops.cpp.inc:1621
::mlir::Operation::operand_range getODSOperands(unsigned index)
Definition Ops.h.inc:1460
::mlir::TypedValue<::mlir::Type > getVal()
Definition Ops.h.inc:1466
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, ::mlir::Value val)
Definition Ops.cpp.inc:1590
std::pair< unsigned, unsigned > getODSResultIndexAndLength(unsigned index)
Definition Ops.h.inc:1475
ApplyMapOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:95
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.cpp.inc:165
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:91
ConstReadOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:340
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:346
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:336
TemplateExprOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:541
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:537
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:547
TemplateOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:753
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:759
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:749
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1036
TemplateParamOpGenericAdaptorBase(::mlir::DictionaryAttr attrs, const Properties &properties, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1040
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1046
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1242
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1251
UnifiableCastOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1245
::std::optional<::mlir::OperationName > odsOpName
Definition Ops.h.inc:1379
std::pair< unsigned, unsigned > getODSOperandIndexAndLength(unsigned index, unsigned odsOperandsSize)
Definition Ops.h.inc:1388
YieldOpGenericAdaptorBase(::mlir::DictionaryAttr attrs={}, const ::mlir::EmptyProperties &properties={}, ::mlir::RegionRange regions={})
Definition Ops.h.inc:1382
void setMap(const ::mlir::AffineMapAttr &propValue)
Definition Ops.h.inc:66
void setNumDims(const ::mlir::IntegerAttr &propValue)
Definition Ops.h.inc:76
void setConstName(const ::mlir::FlatSymbolRefAttr &propValue)
Definition Ops.h.inc:322
void setSymName(const ::mlir::StringAttr &propValue)
Definition Ops.h.inc:735