[Mlir-commits] [mlir] [mlir][linalg] Support `ParamType` in `vector_sizes` option of `VectorizeOp` transform (PR #87557)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Fri Apr 5 08:46:23 PDT 2024


================
@@ -3122,6 +3122,75 @@ transform::VectorizeChildrenAndApplyPatternsOp::applyToOne(
 //===----------------------------------------------------------------------===//
 // VectorizeOp
 //===----------------------------------------------------------------------===//
+ParseResult transform::VectorizeOp::parse(OpAsmParser &parser,
+                                          OperationState &result) {
+  OpAsmParser::UnresolvedOperand target;
+  SmallVector<OpAsmParser::UnresolvedOperand> dynamicSizes;
+  DenseI64ArrayAttr staticSizes;
+  SmallVector<Type> operandTypes;
+  llvm::SMLoc operandLoc;
+  DenseBoolArrayAttr scalableVals;
+
+  if (parser.parseOperand(target) || parser.getCurrentLocation(&operandLoc))
+    return ParseResult::failure();
+
+  if (succeeded(parser.parseOptionalKeyword("vector_sizes"))) {
----------------
srcarroll wrote:

i wonder if it's a dumb idea to define these as static class methods the `VectorizeOp`?

https://github.com/llvm/llvm-project/pull/87557


More information about the Mlir-commits mailing list