* [Bug middle-end/53688] [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled
2012-06-15 18:07 [Bug middle-end/53688] New: [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled hjl.tools at gmail dot com
@ 2012-06-15 18:09 ` hjl.tools at gmail dot com
2012-06-17 11:42 ` rguenth at gcc dot gnu.org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: hjl.tools at gmail dot com @ 2012-06-15 18:09 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53688
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |areg.melikadamyan at gmail
| |dot com
Target Milestone|--- |4.8.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/53688] [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled
2012-06-15 18:07 [Bug middle-end/53688] New: [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled hjl.tools at gmail dot com
2012-06-15 18:09 ` [Bug middle-end/53688] " hjl.tools at gmail dot com
@ 2012-06-17 11:42 ` rguenth at gcc dot gnu.org
2012-06-18 13:51 ` rguenth at gcc dot gnu.org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-06-17 11:42 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53688
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2012-06-17
AssignedTo|unassigned at gcc dot |rguenth at gcc dot gnu.org
|gnu.org |
Ever Confirmed|0 |1
--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-06-17 11:41:54 UTC ---
Mine.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/53688] [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled
2012-06-15 18:07 [Bug middle-end/53688] New: [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled hjl.tools at gmail dot com
2012-06-15 18:09 ` [Bug middle-end/53688] " hjl.tools at gmail dot com
2012-06-17 11:42 ` rguenth at gcc dot gnu.org
@ 2012-06-18 13:51 ` rguenth at gcc dot gnu.org
2012-06-19 8:45 ` ebotcazou at gcc dot gnu.org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-06-18 13:51 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53688
--- Comment #2 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-06-18 13:50:28 UTC ---
NEW_PAGE seems to be miscompiled - we fail to output JOB_ID_RECORD%VERSION
('SPEC CPU'), the comparison difference is lots of
@@ -146,7 +146,7 @@
43255/3 1.1579E+03 -8.1233E+02 0.0000E+00 2.5290E+02
0.0000E+00 0.0000E+00 1 41 1.42E+02 43255
43255/4 -3.5068E+03 -4.3304E+03 0.0000E+00 2.0702E+04
0.0000E+00 0.0000E+00 1 41 1.42E+02 43255
43255/5 -3.5204E+03 -3.2181E+03 0.0000E+00 2.4813E+04
0.0000E+00 0.0000E+00 1 41 1.42E+02 43255
-1 FMA-3D SPEC CPU Impulse Loaded Cylindrical Panel (w/ Subcycling) -
100MB Data Set Page No: 10
+1 FMA-3D Impulse Loaded Cylindrical Panel (w/ Subcycling) -
100MB Data Set Page No: 10
Time T = 4.57200E-07 Time Step = 360
0 NP X-DISPLACE Y-DISPLACE Z-DISPLACE X-VELOCITY Y-VELOCITY
Z-VELOCITY X-ACCELERATE Y-ACCELERATE Z-ACCELERATE NP
by inspecting with gdb you can see that JOB_ID_RECORD%VERSION is properly
populated but HEADLINE is not properly built.
It is sched2 who re-orders
(insn:TI 102 100 250 8 (parallel [
(set (reg:DI 2 cx [143])
(const_int 0 [0]))
(set (reg/f:DI 5 di [141])
(plus:DI (reg/f:DI 5 di [141])
(reg:DI 2 cx [143])))
(set (mem/c:BLK (reg/f:DI 5 di [141]) [0 MEM[(void *)&headline +
9B]+0 A8])
(const_int 0 [0]))
(use (reg:QI 0 ax [142]))
(use (reg:DI 2 cx [143]))
]) t.f90:43848 896 {*rep_stosqi}
(expr_list:REG_UNUSED (reg/f:DI 5 di [141])
(nil)))
and
(insn:TI 106 96 107 8 (set (mem/c:DI (const:DI (plus:DI (symbol_ref:DI
("headline.65670") [flags 0x2] <var_decl 0x7fc398ffbdc0 headline>)
(const_int 10 [0xa]))) [0 MEM[(c_char * {ref-all})&headline
+ 10B]+0 S8 A16])
(reg:DI 1 dx [orig:146 MEM[(c_char * {ref-all})&job_id_record + 12B] ]
[146])) t.f90:43850 62 {*movdi_internal_rex64}
(expr_list:REG_DEAD (reg:DI 1 dx [orig:146 MEM[(c_char *
{ref-all})&job_id_record + 12B] ] [146])
(nil)))
quite possibly because the MEM_ATTRs in the setmem pattern do not have
a MEM_EXPR that has a suitable size.
Testcase:
char headline[256];
struct hdr {
char part1[9];
char part2[8];
} p;
void __attribute__((noinline,noclone))
init()
{
__builtin_memcpy (p.part1, "FOOBARFOO", sizeof (p.part1));
__builtin_memcpy (p.part2, "SPEC CPU", sizeof (p.part2));
}
int main()
{
char *x;
int c;
init();
__builtin_memcpy (&headline[0], p.part1, 9);
c = 9;
x = &headline[0];
x = x + c;
__builtin_memset (x, ' ', 245);
__builtin_memcpy (&headline[10], p.part2, 8);
c = 18;
x = &headline[0];
x = x + c;
__builtin_memset (x, ' ', 238);
if (headline[10] != 'S')
__builtin_abort ();
return 0;
}
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/53688] [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled
2012-06-15 18:07 [Bug middle-end/53688] New: [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled hjl.tools at gmail dot com
` (2 preceding siblings ...)
2012-06-18 13:51 ` rguenth at gcc dot gnu.org
@ 2012-06-19 8:45 ` ebotcazou at gcc dot gnu.org
2012-06-21 12:18 ` matz at gcc dot gnu.org
2012-06-21 12:52 ` matz at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-19 8:45 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53688
Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |georggcc at googlemail dot
| |com
--- Comment #3 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-19 08:44:30 UTC ---
*** Bug 53686 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/53688] [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled
2012-06-15 18:07 [Bug middle-end/53688] New: [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled hjl.tools at gmail dot com
` (3 preceding siblings ...)
2012-06-19 8:45 ` ebotcazou at gcc dot gnu.org
@ 2012-06-21 12:18 ` matz at gcc dot gnu.org
2012-06-21 12:52 ` matz at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: matz at gcc dot gnu.org @ 2012-06-21 12:18 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53688
--- Comment #4 from Michael Matz <matz at gcc dot gnu.org> 2012-06-21 12:18:31 UTC ---
Author: matz
Date: Thu Jun 21 12:18:23 2012
New Revision: 188852
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=188852
Log:
PR middle-end/53688
* builtins.c (get_memory_rtx): Always build an all-aliasing MEM_REF
with correct size.
testsuite/
* gcc.c-torture/execute/pr53688.c: New test.
Added:
trunk/gcc/testsuite/gcc.c-torture/execute/pr53688.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/builtins.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/53688] [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled
2012-06-15 18:07 [Bug middle-end/53688] New: [4.8 Regression] 191.fma3d in SPEC CPU 2000 miscompiled hjl.tools at gmail dot com
` (4 preceding siblings ...)
2012-06-21 12:18 ` matz at gcc dot gnu.org
@ 2012-06-21 12:52 ` matz at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: matz at gcc dot gnu.org @ 2012-06-21 12:52 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53688
Michael Matz <matz at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
CC| |matz at gcc dot gnu.org
Resolution| |FIXED
--- Comment #5 from Michael Matz <matz at gcc dot gnu.org> 2012-06-21 12:52:18 UTC ---
Fixed.
^ permalink raw reply [flat|nested] 7+ messages in thread