[Mlir-commits] [mlir] [mlir][tosa] Fix crash in inferReturnTypes for ReduceOps (PR #69843)
Georgios Pinitas
llvmlistbot at llvm.org
Mon Oct 23 04:32:54 PDT 2023
GeorgeARM wrote:
> When writing the test, I noticed that the ReduceOp folder has a similar issue where it crashes when the `axis` argument of the Op is too large for the shape. What is the desired behaviour for a `tosa.reduce_*` Op when the axis is out of range? Is it supposed to be a No-Op, i.e. folded away or should we emit an error?
Behavior is debatable but my assumption would be that an error should be triggered if the `axis` parameter is `>=` than the input rank. Find it cleaner with well defined preconditions.
https://github.com/llvm/llvm-project/pull/69843
More information about the Mlir-commits
mailing list