This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/71259] New: GCC trunk emits wrong code


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

            Bug ID: 71259
           Summary: GCC trunk emits wrong code
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: anton.mitrokhin at phystech dot edu
  Target Milestone: ---

Created attachment 38552
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38552&action=edit
Reproducer

GCC trunk generates wrong code with -O3/Ofast on 'ivybridge' target (not sure
about other targets though)

crash.cpp is attached.

Run:
> g++ -static-libgcc -static-libstdc++ -std=c++11 -O2 -march=ivybridge -o out0 crash.cpp
> g++ -static-libgcc -static-libstdc++ -std=c++11 -O3 -march=ivybridge -o out1 crash.cpp

Output:
> ./out0: -5105075050047261684
> ./out1: -5105075050047261682

> gcc -v:
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/export/users/amitrokh/gcc_trunk/bin/../libexec/gcc/x86_64-pc-linux-gnu/7.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /export/users/gnutester/stability/svn/trunk/configure
--with-arch=corei7 --with-cpu=corei7 --enable-clocale=gnu --with-system-zlib
--enable-shared --with-demangler-in-ld --enable-cloog-backend=isl
--with-fpmath=sse --with-pkgversion=Revision=236614/svn-rev:236614/
--prefix=/export/users/gnutester/stability/work/trunk/64/install
--enable-languages=c,c++,fortran,java,lto
Thread model: posix
gcc version 7.0.0 20160523 (experimental) (Revision=236614/svn-rev:236614/)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]