[Mlir-commits] [mlir] [mlir][Linalg] Allow more control in drop unit dims (PR #171796)
Lukas Sommer
llvmlistbot at llvm.org
Wed Dec 17 01:00:36 PST 2025
sommerlukas wrote:
Thanks for the feedback @banach-space!
> One note re testing ...
>
> > With the changes from this PR, the transformation is now aborted in these cases, i.e., the operation is not changed.
>
> When changing behaviour like this, I would expect to see some new negative tests that demonstrate cases in which the transformation bails out.
The two new test-cases added in `test-drop-unit-dims.mlir` also do negative testing. The test is processed twice, once with the default behavior, where the transformation bails out (`NOENCODE` prefix) and once with folding of encoded tensors enabled (`ENCODE` prefix).
> Also, the two newly added tests exercise two edge cases:
>
> * Encoding added to an operand.
> * Encoding added to the output tensor.
>
> What should happen when encoding is added to both? Why if different encodings are used? It feels like we are missing two more tests, no?
With the default behavior, the transformation is aborted in all those cases. I've added two test cases to check that.
https://github.com/llvm/llvm-project/pull/171796
More information about the Mlir-commits
mailing list