When we unroll a multiple exit loop, we can chose to pick our split point such that we know *all* the exits (not just latch) become dead on Count-1 iterations of the unrolled loop. Doing this trades a bit more upfront cost (e.g. computing the whole trip count expression) for reduced code size and runtime cost in the main loop.
Reviewers, while the purpose of this patch is sound, I really really dislike the structure of it. I've spent a bunch of time trying to message SCEV into eliminating the checks while only changing the loop entry condition (i.e. the split point), but all of my attempts have failed. Suggestions on how to structure this more cleanly are very very welcome.
FYI, this patch only includes the epilogue case. If we move forward with this structure, I'll post a following review to do the same thing when unrolling with a prolog.
What's that needed for?