Replace any rank(shape_of(tensor)) that relies on a ranked tensor with the
corresponding constant const_size.
Depends On D82076
Paths
| Differential D82077
[MLIR][Shape] Add canonicalization pattern for `shape.rank` ClosedPublic Authored by frgossen on Jun 18 2020, 2:52 AM.
Details Summary Replace any rank(shape_of(tensor)) that relies on a ranked tensor with the Depends On D82076
Diff Detail
Event TimelineComment Actions Awesome, thanks!
frgossen retitled this revision from [MLIR][Shape] Add canonicalization pattern for `shape.get_size` to [MLIR][Shape] Add canonicalization pattern for `shape.rank` .Jun 19 2020, 7:09 AM frgossen retitled this revision from [MLIR][Shape] Add canonicalization pattern for `shape.rank` to [MLIR][Shape] Add canonicalization pattern for `shape.rank`. Comment Actions Nice, thanks
This revision is now accepted and ready to land.Jun 22 2020, 2:43 PM
Closed by commit rG7bca97d960ab: [MLIR][Shape] Add canonicalization pattern for `shape.rank` (authored by frgossen). · Explain WhyJun 25 2020, 1:57 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 273250 mlir/include/mlir/Dialect/Shape/IR/ShapeOps.td
mlir/lib/Dialect/Shape/IR/Shape.cpp
mlir/test/Dialect/Shape/canonicalize.mlir
|
nit: inline this variable into its only use.