[Mlir-commits] [mlir] [mlir][memref] canonicalization for erasing copying subview to identical subview (PR #125852)

Frank Schlimbach llvmlistbot at llvm.org
Wed Feb 5 08:29:03 PST 2025


fschlimb wrote:

> It sounds like we could run `cse` first, and then both subview would be the same op. Which then the original pattern would pick up. Am I missing something?

Almost.
You can get the same result by doing "canonicalize -> cse -> canonicalize". Otherwise cse it will not catch if constants in the dynamic offsets/strides are the same as static ones.

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


More information about the Mlir-commits mailing list