Bug 45663 - [4.6 regression] New test failures
Summary: [4.6 regression] New test failures
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: testsuite (show other bugs)
Version: 4.6.0
: P3 normal
Target Milestone: 4.6.0
Assignee: Not yet assigned to anyone
URL:
Keywords:
: 45675 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-09-13 19:39 UTC by H.J. Lu
Modified: 2010-11-09 19:23 UTC (History)
4 users (show)

See Also:
Host:
Target: i?86-*-*
Build:
Known to work:
Known to fail:
Last reconfirmed: 2010-09-14 10:20:40


Attachments
gcc46-pr45663.patch (467 bytes, patch)
2010-09-14 11:26 UTC, Jakub Jelinek
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description H.J. Lu 2010-09-13 19:39:14 UTC
On Linux/x86, revision 164252:

http://gcc.gnu.org/ml/gcc-cvs/2010-09/msg00546.html

caused:

FAIL: gcc.dg/guality/sra-1.c  -O2  line 42 a.j == 14
FAIL: gcc.dg/guality/sra-1.c  -O2 -flto  line 42 a.j == 14
FAIL: gcc.dg/guality/sra-1.c  -O2 -fwhopr  line 42 a.j == 14
FAIL: gcc.dg/guality/sra-1.c  -O3 -fomit-frame-pointer  line 42 a.j == 14
FAIL: gcc.dg/guality/sra-1.c  -O3 -g  line 42 a.j == 14
FAIL: gcc.dg/guality/sra-1.c  -Os  line 42 a.j == 14
Comment 1 Richard Biener 2010-09-14 10:20:40 UTC
Confirmed.
Comment 2 Jakub Jelinek 2010-09-14 11:26:35 UTC
Created attachment 21789 [details]
gcc46-pr45663.patch

A sign extension insn for the first bar call is scheduled before the a.j++ insns
with the debug_insn for a$j.  While at the call itself the vars already have expected values, at the first insn on the same line as the first bar call (the sign extension) a.j is still 13, not 14.

I think we could fix this up by adjusting the testcase (with current trunk it gives no failures on both x86_64-linux and i686-linux), though haven't tested other targets.
Comment 3 Pat Haugen 2010-09-14 20:04:59 UTC
Not sure I understand everything involved here, but isn't the test a little suspect any time higher optimization levels and instruction scheduling are enabled?
Comment 4 H.J. Lu 2010-09-15 05:45:06 UTC
*** Bug 45675 has been marked as a duplicate of this bug. ***
Comment 5 Jakub Jelinek 2010-11-09 19:06:09 UTC
Author: jakub
Date: Tue Nov  9 19:06:06 2010
New Revision: 166505

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=166505
Log:
	PR middle-end/45663
	* gcc.dg/guality/sra-1.c: Move all gdb-test lines to the second bar invocation
	instead of first.

Modified:
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/gcc.dg/guality/sra-1.c
Comment 6 Jakub Jelinek 2010-11-09 19:23:28 UTC
.