[llvm-branch-commits] [mlir] [MLIR] Fix incorrect slice contiguity inference in `vector::isContiguousSlice` (PR #142422)
    James Newling via llvm-branch-commits 
    llvm-branch-commits at lists.llvm.org
       
    Thu Jun  5 12:11:01 PDT 2025
    
    
  
================
@@ -630,7 +639,10 @@ class FlattenContiguousRowMajorTransferReadPattern
     if (transferReadOp.getMask())
       return failure();
 
-    int64_t firstDimToCollapse = sourceType.getRank() - vectorType.getRank();
----------------
newling wrote:
Why does this need to change? 
If memref is rank n+2 and vector is rank n, isn't it always fine to flatten the memref from index 2? So that memref becomes rank 3 and vector becomes rank 1. Isn't having a rank-1 vector the goal here? 
https://github.com/llvm/llvm-project/pull/142422
    
    
More information about the llvm-branch-commits
mailing list