Commit 66a8341
authored
[VPlan] Skip disconnected exit blocks in hasEarlyExit. (#151718)
Currently hasEarlyExit returns true, if there are multiple exit blocks.
ExitBlocks contains the wrapped original IR exit blocks. Without
checking the predecessors we incorrectly return true for loops with
multiple countable exits, that have been vectorized by requiring a
scalar epilogue. In that case, the exit blocks will get disconnected.
Fix this by filtering out disconnected exit blocks.
Currently this should only impact the 'early-exit vectorized' statistic.
PR: llvm/llvm-project#1517181 parent 0824811 commit 66a8341
File tree
2 files changed
+5
-2
lines changed- llvm
- lib/Transforms/Vectorize
- test/Transforms/LoopVectorize
2 files changed
+5
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4228 | 4228 | | |
4229 | 4229 | | |
4230 | 4230 | | |
4231 | | - | |
| 4231 | + | |
| 4232 | + | |
| 4233 | + | |
| 4234 | + | |
4232 | 4235 | | |
4233 | 4236 | | |
4234 | 4237 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| |||
0 commit comments