https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120704

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|rguenth at gcc dot gnu.org         |unassigned at gcc dot 
gnu.org
             Status|ASSIGNED                    |NEW
           Keywords|                            |needs-reduction

--- Comment #10 from Richard Biener <rguenth at gcc dot gnu.org> ---
-O2 -funswitch-loops is enough to trigger

t.c:6:11: runtime error: signed integer overflow: -2147203927 * -14 cannot be
represented in type 'int'
t.c:6:11: runtime error: signed integer overflow: -2146205926 * -14 cannot be
represented in type 'int'
t.c:6:23: runtime error: signed integer overflow: -2840684 - 2147483647 cannot
be represented in type 'int'

the unswitching looks OK, so it must be some followup transform messing
things up.  Disabling phiopt and LIM after unswitching doesn't cure things
though.  We do (late) thread the hell out of this though, creating many
loop (copies?).  -fdisable-tree-thread2 -fdisable-tree-threadfull2 removes one
UBSAN diagnostic.

The flow through the program is quite complicated (at -O0), so it's difficult
to verify correctness :/  I'm not working on this for the moment.

Reply via email to