[Mlir-commits] [mlir] [mlir][linalg] fix OuterUnitDims linalg.pack decomposition pattern (PR #141613)
Christopher McGirr
llvmlistbot at llvm.org
Wed May 28 00:22:50 PDT 2025
chrsmcgrr wrote:
> IIUC, you extend the pattern to handle the case that there are non ones in unpacked outer dimensions? I.e., should we relax the check in line 1165 - 1169? Then you are not fixing a corner case. Instead, you extend the support in general?
Thanks for the quick reply @hanhanW
Not quite, at least for my use case I am still only concerned with unit outer dimensions in the unpacked case. AFAIK, the outer dimension in my case would be index `[1]` and the inner dimensions would be `[2, 0]` when looking at the source, unpacked tensor. Correct me if I am wrong.
My change is more about the adjacent trailing dimensions as @banach-space has now explained.
I would be happy to extend [1165-1169](https://github.com/llvm/llvm-project/blob/8adcc8a669f093d6fe74645900515e4561102248/mlir/lib/Dialect/Linalg/Transforms/Transforms.cpp#L1165-L1169) if anyone needs it.
https://github.com/llvm/llvm-project/pull/141613
More information about the Mlir-commits
mailing list