https://gcc.gnu.org/bugzilla/show_bug.cgi?id=36748
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Known to fail| |4.7.1 --- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- With a slighly different testcase (to get SCCP to do something, I have not looked into why it is not doing anything in newer version), GCC 4.9 and above provides the following: # value_10 = PHI <value_8(3), value_6(4)> [/app/example.cpp : 29:11] value_6 = value_10 + 1; _3 = (unsigned int) value_6; _1 = (unsigned int) value_4(D); _12 = _3 - _1; _11 = (int) _12; [/app/example.cpp : 28:2] if (value_6 > _11) So I don't know if that is enough though.