[mlir][Linalg] Allow folding to rank-zero tensor when using rank-reducing subtensors.
The pattern to convert subtensor ops to their rank-reduced versions (by dropping unit-dims in the result) can also convert to a zero-rank tensor. Handle that case. This also fixes a OOB access bug in the existing pattern for such cases. Differential Revision: https://reviews.llvm.org/D101949
Loading
Please register or sign in to comment