Commit f3fa54a
authored
[mlir][Vector] Handle 0-rank case in fold instead of RewriterPattern (#130168)
For vector.extract, the folder always canonicalizes to a vector.extract
operation, while the rewrite pattern canonicalizes to a vector.broadcast
except in the case of 0-rank vectors.
Remove this special casing, and instead handle the 0-rank vector case in
the folder.1 parent dc28e0d commit f3fa54a
File tree
2 files changed
+7
-9
lines changed- mlir
- lib/Dialect/Vector/IR
- test/Dialect/Vector
2 files changed
+7
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1675 | 1675 | | |
1676 | 1676 | | |
1677 | 1677 | | |
1678 | | - | |
| 1678 | + | |
1679 | 1679 | | |
1680 | 1680 | | |
1681 | 1681 | | |
| |||
2156 | 2156 | | |
2157 | 2157 | | |
2158 | 2158 | | |
| 2159 | + | |
| 2160 | + | |
| 2161 | + | |
| 2162 | + | |
2159 | 2163 | | |
2160 | | - | |
2161 | | - | |
2162 | | - | |
2163 | | - | |
2164 | | - | |
2165 | | - | |
2166 | 2164 | | |
2167 | 2165 | | |
2168 | 2166 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
736 | 736 | | |
737 | 737 | | |
738 | 738 | | |
739 | | - | |
| 739 | + | |
740 | 740 | | |
741 | 741 | | |
742 | 742 | | |
| |||
2834 | 2834 | | |
2835 | 2835 | | |
2836 | 2836 | | |
2837 | | - | |
| 2837 | + | |
2838 | 2838 | | |
2839 | 2839 | | |
2840 | 2840 | | |
| |||
0 commit comments