public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/103063] New: Wrong code while using -O3
@ 2021-11-03 16:04 stefansf at linux dot ibm.com
  2021-11-03 17:23 ` [Bug tree-optimization/103063] " marxin at gcc dot gnu.org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: stefansf at linux dot ibm.com @ 2021-11-03 16:04 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 103063
           Summary: Wrong code while using -O3
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: stefansf at linux dot ibm.com
  Target Milestone: ---

int a = 0;
unsigned char b = 0;

int main() {
  a - 6;
  for (; a >= -13; a = a - 8)
    while((unsigned char)(b-- * 6))
      ;
  if (b != 127)
    __builtin_abort();
  return 0;
}

Running the example while compiled with -O{0,1,2} works fine whereas it fails
with -O{3,fast} using gcc-12-4860-g73658e70d9e. Couldn't find a good commit so
far. Fails on IBM Z as well as x64.

Still not sure where it fails. ifcvt looks good to me.

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-01-24 13:16 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-03 16:04 [Bug tree-optimization/103063] New: Wrong code while using -O3 stefansf at linux dot ibm.com
2021-11-03 17:23 ` [Bug tree-optimization/103063] " marxin at gcc dot gnu.org
2021-11-03 17:25 ` [Bug tree-optimization/103063] [9/10/11/12 Regression] Wrong code while using -O3 since r7-2373-g69b806f6a60efcf1 pinskia at gcc dot gnu.org
2021-11-04  9:02 ` rguenth at gcc dot gnu.org
2022-01-19 16:33 ` jakub at gcc dot gnu.org
2022-01-19 16:35 ` jakub at gcc dot gnu.org
2022-01-19 17:42 ` jakub at gcc dot gnu.org
2022-01-20  7:04 ` rguenth at gcc dot gnu.org
2022-01-24 13:16 ` rguenth at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).