Command line:
gcc -O1 -fschedule-insns2 -fsched2-use-superblocks -m32 testcase.c && ./a.out
or
gcc -O2 -fsched2-use-superblocks -m32 testcase.c && ./a.out

Tested revisions:
r157965 - fail
r157877 - fail
r153685 - OK
4.4.3, 4.3.4, 4.2.4, 4.1.2, 3.4.6 - OK

Output:
$ /mnt/svn/gcc-trunk/binary-157965-lto/bin/gcc -O1 -fschedule-insns2
-fsched2-use-superblocks -m32 testcase.c && ./a.out
Aborted

The problem is the value is read before stored:
(reduced testcase, -O1 version)
...
        pxor    %xmm0, %xmm0    # tmp63
...
        cmpl    $0, 4(%esp)     #, u.i
        movdqa  %xmm0, (%esp)   # tmp63, u.v
        jne     .L2     #,
...
.L2:
        call    abort   #


-- 
           Summary: -fsched2-use-superblocks -m32 causes FAIL:
                    gcc.dg/pr32912-1.c execution test
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: zsojka at seznam dot cz
  GCC host triplet: x86_64-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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

Reply via email to