[Mlir-commits] [mlir] [mlir][TilingInterface] Avoid looking at operands for getting slices to continue tile + fuse. (PR #107882)
    llvmlistbot at llvm.org 
    llvmlistbot at llvm.org
       
    Tue Sep 10 14:41:04 PDT 2024
    
    
  
================
@@ -120,16 +120,21 @@ struct LinalgOpTilingInterface
     Location loc = op->getLoc();
     LinalgOp linalgOp = cast<LinalgOp>(op);
     SmallVector<Value> valuesToTile = linalgOp->getOperands();
-    SmallVector<Value, 4> tiledOperands = makeTiledShapes(
+    SmallVector<Value> tiledOperands = makeTiledShapes(
         b, loc, linalgOp, valuesToTile, offsets, sizes, {}, true);
+    SmallVector<Operation *> generatedSlices = llvm::map_to_vector(
+        llvm::make_filter_range(
+            tiledOperands, [](Value v) -> bool { return v.getDefiningOp(); }),
+        [](Value v) -> Operation * { return v.getDefiningOp(); });
----------------
MaheshRavishankar wrote:
This could be a `memref.subview` as well. I left the fusion implementation to account for what kind of operation it can index on. Ill leave it as is for now, but we can come back and revisit.
EDIT: Actually fixed it to return filter out extract slices and subview operations.
https://github.com/llvm/llvm-project/pull/107882
    
    
More information about the Mlir-commits
mailing list