Commit 4b56345
authored
[mlir][SCF] Unify tileUsingFor and tileReductionUsingFor implementation (llvm#120115)
This patch unifies the tiling implementation for tileUsingFor and
tileReductionUsingFor. This is done by passing an addition option to
SCFTilingOptions, allowing it to set how reduction dimensions should be
tiled. Currently, there are 3 different options for reduction tiling:
FullReduction (old tileUsingFor), PartialReductionOuterReduction (old
tileReductionUsingFor) and PartialReductionOuterParallel
(linalg::tileReductionUsingForall, this isn't implemented in this
patch).
The patch makes tileReductionUsingFor use the tileUsingFor
implementation with the new reduction tiling options.
There are no test changes because the implementation was doing almost
the exactly same thing. This was also tested in IREE (which uses both
these APIs heavily) and there were no test changes.1 parent e7303fe commit 4b56345
File tree
4 files changed
+305
-225
lines changed- mlir
- include/mlir/Dialect/SCF/Transforms
- lib/Dialect
- Linalg/TransformOps
- SCF/Transforms
- test/lib/Interfaces/TilingInterface
4 files changed
+305
-225
lines changedLines changed: 39 additions & 18 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
88 | 118 | | |
89 | 119 | | |
90 | 120 | | |
| |||
102 | 132 | | |
103 | 133 | | |
104 | 134 | | |
| 135 | + | |
| 136 | + | |
105 | 137 | | |
106 | 138 | | |
107 | | - | |
108 | | - | |
109 | | - | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
110 | 145 | | |
111 | 146 | | |
112 | 147 | | |
| |||
300 | 335 | | |
301 | 336 | | |
302 | 337 | | |
303 | | - | |
304 | | - | |
305 | | - | |
306 | | - | |
307 | | - | |
308 | | - | |
309 | | - | |
310 | | - | |
311 | | - | |
312 | | - | |
313 | | - | |
314 | | - | |
315 | | - | |
316 | | - | |
317 | 338 | | |
318 | 339 | | |
319 | 340 | | |
| |||
338 | 359 | | |
339 | 360 | | |
340 | 361 | | |
341 | | - | |
| 362 | + | |
342 | 363 | | |
343 | 364 | | |
344 | 365 | | |
| |||
Lines changed: 7 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2223 | 2223 | | |
2224 | 2224 | | |
2225 | 2225 | | |
2226 | | - | |
| 2226 | + | |
2227 | 2227 | | |
2228 | 2228 | | |
2229 | 2229 | | |
| |||
2630 | 2630 | | |
2631 | 2631 | | |
2632 | 2632 | | |
2633 | | - | |
| 2633 | + | |
2634 | 2634 | | |
2635 | 2635 | | |
2636 | 2636 | | |
2637 | 2637 | | |
2638 | 2638 | | |
| 2639 | + | |
2639 | 2640 | | |
2640 | 2641 | | |
2641 | | - | |
| 2642 | + | |
2642 | 2643 | | |
2643 | | - | |
| 2644 | + | |
2644 | 2645 | | |
2645 | 2646 | | |
2646 | 2647 | | |
| |||
3064 | 3065 | | |
3065 | 3066 | | |
3066 | 3067 | | |
3067 | | - | |
| 3068 | + | |
3068 | 3069 | | |
3069 | 3070 | | |
3070 | 3071 | | |
| |||
3303 | 3304 | | |
3304 | 3305 | | |
3305 | 3306 | | |
3306 | | - | |
| 3307 | + | |
3307 | 3308 | | |
3308 | 3309 | | |
3309 | 3310 | | |
| |||
0 commit comments