[PATCH] D79658: [mlir][Affine] Introduce affine.vload and affine.vstore

Uday Bondhugula via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri May 8 19:21:16 PDT 2020


bondhugula added a comment.

Thanks for initiating this - this would be a great addition to the affine dialect.



================
Comment at: mlir/include/mlir/Conversion/Passes.td:18
 
 def ConvertAffineToStandard : FunctionPass<"lower-affine"> {
   let summary = "Lower Affine operations to a combination of Standard and Loop "
----------------
dcaballe wrote:
> Should we rename this to `convert-affine-to-loops`?
The reasons this is still called lower-affine is that it's actually converting affine not just to SCF (formerly loop) but SCF + std. Because the affine.apply's as well as the expressions in the affine for bounds, affine if conditionals, and load/store subscripts are lowered to add/mul/div etc.  -convert-affine-to-<something> is perhaps more consistent / better. 


================
Comment at: mlir/lib/Conversion/AffineToVector/AffineToVector.cpp:55
+        op, op.getVectorType(), op.getMemRef(), *resultOperands,
+        AffineMapAttr::get(permMap), padding);
+    return success();
----------------
dcaballe wrote:
> I would be great if we could have a builder that sets `getMinorIdentityMap` as the default value of the permutation map for those cases where no permutation is needed.
+1. 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D79658





More information about the llvm-commits mailing list