[PATCH] D73190: [mlir] Adds affine loop fusion transformation function to LoopFusionUtils.

Uday Bondhugula via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 23 02:00:34 PST 2020


bondhugula added inline comments.


================
Comment at: mlir/include/mlir/Transforms/LoopFusionUtils.h:56
+/// Fuses 'srcForOp' into 'dstForOp' with destination loop block insertion point
+/// and source slice loop bounds specified in 'srcSlice'.
+void fuseLoops(AffineForOp srcForOp, AffineForOp dstForOp,
----------------
A bit strange to have the destination insertion point stored in srcSlice! Separate arg?


================
Comment at: mlir/lib/Transforms/Utils/LoopFusionUtils.cpp:257
+  BlockAndValueMapping mapper;
+  b.clone(*srcForOp.getOperation(), mapper);
+  // Update 'sliceLoopNest' upper and lower bounds from computed 'srcSlice'.
----------------
srcForOp should do?


================
Comment at: mlir/test/lib/Transforms/TestLoopFusion.cpp:45
+static llvm::cl::opt<bool> clTestLoopFusionTransformation(
+    "test-loop-fusion-transformation",
+    llvm::cl::desc("Enable testing of loop fusion transformation"),
----------------
"test-loop-fusion" sounds fine?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73190/new/

https://reviews.llvm.org/D73190





More information about the llvm-commits mailing list