[Mlir-commits] [mlir] [MLIR][Affine] Normalize memref.alloc ops with non trivial layout map (PR #129875)

Uday Bondhugula llvmlistbot at llvm.org
Fri Apr 4 17:24:07 PDT 2025


================
@@ -1819,8 +1817,40 @@ LogicalResult mlir::affine::normalizeMemRef(AllocLikeOp *allocOp) {
         b.create<AllocLikeOp>(allocOp->getLoc(), newMemRefType, newDynamicSizes,
                               allocOp->getAlignmentAttr());
   } else {
-    newAlloc = b.create<AllocLikeOp>(allocOp->getLoc(), newMemRefType,
-                                     allocOp->getAlignmentAttr());
+    mlir::ValueRange dynamicSizes = allocOp->getDynamicSizes();
----------------
bondhugula wrote:

Need a comment as to what this `else` block is meant to handle.

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


More information about the Mlir-commits mailing list