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



             Bug #: 56866

           Summary: gcc 4.7.x/gcc-4.8.x with '-O3 -march=bdver2'

                    misscompiles glibc-2.17/crypt/sha512.c

    Classification: Unclassified

           Product: gcc

           Version: 4.8.0

            Status: UNCONFIRMED

          Severity: normal

          Priority: P3

         Component: c

        AssignedTo: unassig...@gcc.gnu.org

        ReportedBy: winfried.mag...@t-online.de





compiling glibc-2.17 with 'O3 -march=bdver2' fails crypt-test when running

'make check' after glibc-build. I've already tested with different

compilers/settings and the problem exists with gcc-4.7.x and gcc-4.8.x when

using '-O3 -march=bdver1' or '-O3 -march=bdver2' (-O2 is fine) and the affected

file is glibc-2.17/crypt/sha512.c.



I've attached a tar-file which includes necessary files from glibc-2.17

(sha512-block.c/sha512.c/sha512.h) and a modified version of sha512c-test.c

(removed dependency to glibc-test-environment). Might not work if system-libc

is not 2.17

(recompiling glibc and run test-suite should always work.

A small test-script test-gcc.sh to demonstrate the problem. Verified on:



gcc (GCC) 4.8.1 20130407 / glibc-2.17

gcc (GCC) 4.7.2 20130108 / opensuse-12.3 / glibc-2.17

Reply via email to