[Mlir-commits] [mlir] [mlir][vector] Drop innermost unit dims on transfer_write. (PR #78554)

Han-Chung Wang llvmlistbot at llvm.org
Fri Jan 19 00:36:44 PST 2024


================
@@ -1152,8 +1152,71 @@ struct FoldI1Select : public OpRewritePattern<arith::SelectOp> {
   }
 };
 
-// Drop inner most contiguous unit dimensions from transfer_read operand.
-class DropInnerMostUnitDims : public OpRewritePattern<vector::TransferReadOp> {
+/// Returns the number of dims can be folded away from transfer ops. It returns
+/// a failure if strides and offsets can not be resolved.
----------------
hanhanW wrote:

I think we are not able to test that, it is mostly added for safety (IMHO). The logic was copied from the previous implementation, and I don't want to update other conditions in a PR.

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


More information about the Mlir-commits mailing list