Commit 889bbf6
committed
[LoopInterchange] Hoist isCompuatableLoopNest() in the control flow
The profiling of the LLVM Test-suite reveals that a significant portion,
specifically 14,090 out of 139,323, loop nests were identified as non-viable
candidates for transformation, leading to the transform exiting from isComputableLoopNest()
without any action.
More importantly, dependence information was computed for these loop nests before
reaching the function isComputableLoopNest(), which does not require
DI and relies solely on scalar evolution (SE).
To enhance compile-time efficiency, this patch moves the call to isComputableLoopNest()
earlier in the control-flow, thereby avoiding unnecessary dependence calculations.
The impact of this change is evident on the compile-time-tracker, with the
overall geometric mean improvement recorded at 0.11%, while the lencode benchmark
gets a more substantial benefit of 0.44%.
This improvement can be tracked in the isc-ln-exp-2 branch under my repo.1 parent df3bc54 commit 889bbf6
1 file changed
+28
-24
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
271 | 271 | | |
272 | 272 | | |
273 | 273 | | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
274 | 294 | | |
275 | 295 | | |
276 | 296 | | |
| |||
426 | 446 | | |
427 | 447 | | |
428 | 448 | | |
429 | | - | |
430 | | - | |
431 | | - | |
432 | | - | |
433 | | - | |
434 | | - | |
435 | | - | |
436 | | - | |
437 | | - | |
438 | | - | |
439 | | - | |
440 | | - | |
441 | | - | |
442 | | - | |
443 | | - | |
444 | | - | |
445 | | - | |
446 | | - | |
447 | | - | |
448 | 449 | | |
449 | 450 | | |
450 | 451 | | |
| |||
459 | 460 | | |
460 | 461 | | |
461 | 462 | | |
462 | | - | |
463 | | - | |
464 | | - | |
465 | | - | |
466 | 463 | | |
467 | 464 | | |
468 | 465 | | |
| |||
1755 | 1752 | | |
1756 | 1753 | | |
1757 | 1754 | | |
| 1755 | + | |
| 1756 | + | |
| 1757 | + | |
| 1758 | + | |
| 1759 | + | |
| 1760 | + | |
| 1761 | + | |
1758 | 1762 | | |
1759 | 1763 | | |
1760 | 1764 | | |
1761 | | - | |
| 1765 | + | |
1762 | 1766 | | |
1763 | 1767 | | |
1764 | 1768 | | |
| |||
0 commit comments