[Relax] Fix matmul and reductions with zero-size dimension return uninitialized memory#19680
[Relax] Fix matmul and reductions with zero-size dimension return uninitialized memory#19680cchung100m wants to merge 9 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces handling for zero-size dimensions during the legalization of matmul and statistical operators (such as product and sum) by returning filled tensors with appropriate identity values. However, several critical runtime issues were identified in the implementation, including typos ("trix" instead of "tirx"), a missing import for "ShapeExpr", and the use of lowercase "false" instead of "False", all of which would result in "NameError" exceptions.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
…nitialized memory
…e, ...) to avoid ShapeExpr -> Array<PrimExpr> type error
Hi Committers,
This PR fixes issues #19578. Any suggestions would be appreciated if you are available.