[Mlir-commits] [mlir] [mlir] [linalg] Add canonicalize pattern to swap transpose with broadcast (PR #97063)

donald chen llvmlistbot at llvm.org
Tue Jul 9 06:01:10 PDT 2024


cxy-1993 wrote:

> As noted in my above comment, if there is a consensus that this is a canonicalization, please include that justification in the pr description vs justifying as an optimization. Marking change requested for that point. It seems to me that making this judgment would be part of a bit more analysis of adjacent ops vs a one off, but I won't stick on that point if others believe this is justified on its own.
> 
> (I do tend to agree this might be reasonable to do but the bar for calling something a canonicalization is high, and I'd like to see it justified and documented in such a way. Some of that commentary is presented inline and needs to be moved to the PR description and agreed on)

Thank you for your suggestion. After receiving multiple concerns about placing this pattern in canonicalize, I have reconsidered the validity of this pattern in canonicalize. For some backends, doing so would indeed introduce unnecessary risks, so I have move this pattern from canonicalize to transform. Thanks again  @MaheshRavishankar @stellaraccident @dcaballe 

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


More information about the Mlir-commits mailing list