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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2023-02-13
             Blocks|                            |56456
             Status|UNCONFIRMED                 |NEW
           Keywords|                            |diagnostic
     Ever confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
We've "optimized" the loop to

  while (1)
    {
     if (i == 2) { put (2); if (arr[2] == 0) break; put (2); }
     else { if (arr[i] == 0) break; }
     i++;
    }

and diagnose the appearing out-of-bounds accesses.  It's like some other
bugs where jump threading isolates a path that's not reachable at runtime
but we fail to prove that and thus fail to eliminate the isolated path.


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56456
[Bug 56456] [meta-bug] bogus/missing -Warray-bounds

Reply via email to