[Mlir-commits] [mlir] [mlir][Vector] Add a rewrite pattern for gather over a strided memref (PR #72991)

Cullen Rhodes llvmlistbot at llvm.org
Thu Nov 30 02:18:38 PST 2023


================
@@ -115,6 +198,17 @@ struct Gather1DToConditionalLoads : OpRewritePattern<vector::GatherOp> {
 
     Value condMask = op.getMask();
     Value base = op.getBase();
+
+    // vector.load requires the most minor memref dim to have unit stride
+    if (auto memType = dyn_cast<MemRefType>(base.getType())) {
+      memType.getLayout();
----------------
c-rhodes wrote:

this can be removed

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


More information about the Mlir-commits mailing list