Adds a canonicalization for tensor.extract. When an extract occurs on
a rank-reducing (of unit-dimensions) tensor.extract_slice operation,
the tensor.extract can act on the source of the tensor.extract_slice.
Depends on D158635
Paths
| Differential D158637
[mlir][tensor] Add canonicalization of `tensor.extract` from cast-like slice Needs ReviewPublic Authored by christopherbate on Aug 23 2023, 10:09 AM.
Details
Summary Adds a canonicalization for tensor.extract. When an extract occurs on Depends on D158635
Diff Detail
Event Timeline
Revision Contents
Diff 552779 mlir/lib/Dialect/Tensor/IR/TensorOps.cpp
mlir/test/Dialect/Tensor/canonicalize.mlir
|
While this pattern seems fine to me with this check, I think the other comments in https://reviews.llvm.org/D158643 could still apply?