[Mlir-commits] [mlir] [mlir][linalg] Propagate filter tensor encoding in im2col (PR #160099)

Andrzej WarzyƄski llvmlistbot at llvm.org
Wed Sep 24 11:26:12 PDT 2025


================
@@ -124,6 +125,10 @@ rewriteInIm2Col(RewriterBase &rewriter, linalg::Conv2DNhwcHwcfOp convOp) {
   auto filterType = cast<ShapedType>(convOp.getInputs()[1].getType());
   auto outputType = cast<ShapedType>(convOp.getOutputs()[0].getType());
 
+  if (!convOp.hasPureTensorSemantics())
+    return rewriter.notifyMatchFailure(
+        convOp, "expected op to have pure tensor semantics");
+
----------------
banach-space wrote:

This is saying that this transformation only works for "convs on tensors" and disables it for "convs on memrefs" - could you double check that it wouldn't work for MemRefs? Thanks!

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


More information about the Mlir-commits mailing list