[Mlir-commits] [mlir] [MLIR] Enable pattern only for scf.forall op (PR #110230)

Matthias Springer llvmlistbot at llvm.org
Fri Sep 27 11:49:45 PDT 2024


================
@@ -131,11 +132,25 @@ struct IterArgsToInitArgs : public OpRewritePattern<tensor::DimOp> {
     auto blockArg = dyn_cast<BlockArgument>(dimOp.getSource());
     if (!blockArg)
       return failure();
-    auto loopLikeOp =
-        dyn_cast<LoopLikeOpInterface>(blockArg.getParentBlock()->getParentOp());
-    if (!loopLikeOp)
+    // TODO: Enable this for loopLikeInterface. Restricting for scf.for
----------------
matthias-springer wrote:

I think it would make sense to move this pattern to the same file.

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


More information about the Mlir-commits mailing list