public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/28003]  New: optimizer bug
@ 2006-06-12 19:28 rwgk at yahoo dot com
  2006-06-12 19:43 ` [Bug c++/28003] " rwgk at yahoo dot com
                   ` (15 more replies)
  0 siblings, 16 replies; 18+ messages in thread
From: rwgk at yahoo dot com @ 2006-06-12 19:28 UTC (permalink / raw)
  To: gcc-bugs

I will attach a small reproducer.

/* Reproducer for optimizer bug in gcc svn trunk revision 114570
   (as checked out 2006_06_12_0834 PDT)

   To produce correct output:
     g++ -Wall -O0 gcc_trunk_2006_06_12_0834_fc5_x86_64.cpp
     ./a.out

   To see the bug:
     g++ -Wall -O1 gcc_trunk_2006_06_12_0834_fc5_x86_64.cpp
     ./a.out

   Note the difference in the last line of the output:
       Correct: 1 0 0
     Incorrect: 0 0 0

   The output is also incorrect for -O2 and -O3.

   The last line of the output is correct if compiled with:
     g++ -Wall -O1 -DBAD_WORKAROUND gcc_trunk_2006_06_12_0834_fc5_x86_64.cpp
     ./a.out

   Platform:
     Fedora Core release 5 (Bordeaux)
     Linux rosie.lbl.gov 2.6.15-1.2054_FC5 #1 SMP Tue Mar 14 15:48:20 EST 2006
x
86_64 x86_64 x86_64 GNU/Linux

     % g++ -v
     Using built-in specs.
     Target: x86_64-unknown-linux-gnu
     Configured with: /net/rosie/scratch1/rwgk/gcc_trunk/configure
--prefix=/usr
/local_cci/gcc_trunk_2006_06_12_0834_fc5_x86_64 --enable-languages=c,c++
     Thread model: posix
     gcc version 4.2.0 20060612 (experimental)
 */


-- 
           Summary: optimizer bug
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rwgk at yahoo dot com
 GCC build triplet: x86_64-unknown-linux-gnu
  GCC host triplet: x86_64-unknown-linux-gnu
GCC target triplet: x86_64-unknown-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28003


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

end of thread, other threads:[~2006-08-22 14:05 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-12 19:28 [Bug c++/28003] New: optimizer bug rwgk at yahoo dot com
2006-06-12 19:43 ` [Bug c++/28003] " rwgk at yahoo dot com
2006-06-13  6:26 ` [Bug tree-optimization/28003] [4.2 Regression] " pinskia at gcc dot gnu dot org
2006-06-13 13:29   ` Daniel Berlin
2006-06-13 13:29 ` reichelt at gcc dot gnu dot org
2006-06-13 13:59 ` dberlin at dberlin dot org
2006-06-13 14:40 ` pinskia at gcc dot gnu dot org
2006-06-13 17:24 ` dberlin at gcc dot gnu dot org
2006-06-29 21:35 ` pinskia at gcc dot gnu dot org
2006-07-05 18:01 ` mmitchel at gcc dot gnu dot org
2006-07-20 21:29 ` steven at gcc dot gnu dot org
2006-07-21 10:18 ` reichelt at gcc dot gnu dot org
2006-08-08 15:51 ` janis at gcc dot gnu dot org
2006-08-09 14:40 ` dberlin at gcc dot gnu dot org
2006-08-21  2:17 ` dberlin at gcc dot gnu dot org
2006-08-22 14:04 ` dberlin at gcc dot gnu dot org
2006-08-22 14:05 ` dberlin at gcc dot gnu dot org
2006-08-22 14:05 ` dberlin at gcc dot gnu dot 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).