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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2023-08-30
           Priority|P3                          |P1
     Ever confirmed|0                           |1

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
Confirmed.  Also miscompiled with -O2 -fsplit-loops.  Note enabling
-fsplit-loops yields

t.c: In function 'main':
t.c:9:26: warning: iteration 3 invokes undefined behavior
[-Waggressive-loop-optimizations]
    9 |     for (; f <= 0; f = f + 7) {
      |                        ~~^~~
t.c:9:14: note: within this loop
    9 |     for (; f <= 0; f = f + 7) {
      |            ~~^~~~

when this happens we usually end up with an endless loop.

Reply via email to