https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113665
--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
Well, ICF figures out the other part of the partial inlined test() are equal
and I think they are. The
if (i >= S){
return false;
}
tests are inlined and eliminated (I think correctly so). -fno-partial-inlining
also avoids the issue.
The issue is that ICF doesn't wipe (or compare) range info so we get after
inlining:
<bb 2> [local count: 10737416]:
goto <bb 6>; [100.00%]
<bb 3> [local count: 1063004409]:
# RANGE [irange] long unsigned int [0, 591] NONZERO 0x3ff
_5 = (long unsigned int) i_2;
# RANGE [irange] unsigned int [0, 287] NONZERO 0x1ff
_11 = (unsigned int) _5;