public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/36008] New: Function produces wrong results when inlined.
@ 2008-04-22 13:51 xavier at tddft dot org
2008-04-22 13:53 ` [Bug c/36008] " xavier at tddft dot org
` (15 more replies)
0 siblings, 16 replies; 17+ messages in thread
From: xavier at tddft dot org @ 2008-04-22 13:51 UTC (permalink / raw)
To: gcc-bugs
When the attached source file is compiled with 'gcc -O3 -c', the code that uses
it produces wrong results. The problem disappears if 'gcc -O3 -fno-inline -c'
or if the variables inside 'generate_point_symmetry' are declared as 'static'.
This is the output of gcc-4.3 -v :
Using built-in specs.
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-4.3/configure --prefix=/opt/gcc/ --program-suffix=-4.3
--enable-languages=c,fortran,c++ --with-arch=core2 --enable-libgomp
Thread model: posix
gcc version 4.3.1 20080419 (prerelease) (GCC)
This is the system:
Linux corvo 2.6.24.2-corvo-001 #3 SMP PREEMPT x86_64 GNU/Linux
distribution is Debian GNU/Linux 4.0
--
Summary: Function produces wrong results when inlined.
Product: gcc
Version: 4.3.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: xavier at tddft dot org
GCC target triplet: x86_64-unknown-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
@ 2008-04-22 13:53 ` xavier at tddft dot org
2008-04-22 14:14 ` aldot at gcc dot gnu dot org
` (14 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: xavier at tddft dot org @ 2008-04-22 13:53 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from xavier at tddft dot org 2008-04-22 13:53 -------
Created an attachment (id=15510)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15510&action=view)
the code
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
2008-04-22 13:53 ` [Bug c/36008] " xavier at tddft dot org
@ 2008-04-22 14:14 ` aldot at gcc dot gnu dot org
2008-04-22 17:17 ` xavier at tddft dot org
` (13 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: aldot at gcc dot gnu dot org @ 2008-04-22 14:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from aldot at gcc dot gnu dot org 2008-04-22 14:13 -------
Please provide a self-contained testcase (see http://gcc.gnu.org/bugs.html )
that ideally abort()s on a wrong result.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
2008-04-22 13:53 ` [Bug c/36008] " xavier at tddft dot org
2008-04-22 14:14 ` aldot at gcc dot gnu dot org
@ 2008-04-22 17:17 ` xavier at tddft dot org
2008-04-22 22:49 ` [Bug middle-end/36008] " xavier at tddft dot org
` (12 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: xavier at tddft dot org @ 2008-04-22 17:17 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from xavier at tddft dot org 2008-04-22 17:16 -------
The code comes from spglib, a library to calculate symmetry groups from
crystals, so it is quite complex. The problem is that I didn't wrote it I don't
understand it enough to be able to produce a small self-contained test case. I
will try to do it, but this may take me some time.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug middle-end/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (2 preceding siblings ...)
2008-04-22 17:17 ` xavier at tddft dot org
@ 2008-04-22 22:49 ` xavier at tddft dot org
2008-04-22 22:50 ` xavier at tddft dot org
` (11 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: xavier at tddft dot org @ 2008-04-22 22:49 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from xavier at tddft dot org 2008-04-22 22:49 -------
Created an attachment (id=15513)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15513&action=view)
Test case, 1st file (no includes)
--
xavier at tddft dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #15510|0 |1
is obsolete| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug middle-end/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (3 preceding siblings ...)
2008-04-22 22:49 ` [Bug middle-end/36008] " xavier at tddft dot org
@ 2008-04-22 22:50 ` xavier at tddft dot org
2008-04-22 22:52 ` xavier at tddft dot org
` (10 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: xavier at tddft dot org @ 2008-04-22 22:50 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from xavier at tddft dot org 2008-04-22 22:49 -------
Created an attachment (id=15514)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15514&action=view)
Test case 2nd file
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug middle-end/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (4 preceding siblings ...)
2008-04-22 22:50 ` xavier at tddft dot org
@ 2008-04-22 22:52 ` xavier at tddft dot org
2008-04-23 10:04 ` rguenth at gcc dot gnu dot org
` (9 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: xavier at tddft dot org @ 2008-04-22 22:52 UTC (permalink / raw)
To: gcc-bugs
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 740 bytes --]
------- Comment #6 from xavier at tddft dot org 2008-04-22 22:51 -------
I have managed to create a test case:
Correct case:
xavier@corvo:~$ gcc-4.3 bravais.c mathfunc.c -O3 -fno-inline
bravais.c: In function âmainâ:
bravais.c:83: warning: incompatible implicit declaration of built-in function
âprintfâ
xavier@corvo:~$ ./a.out
0
Wrong case:
xavier@corvo:~$ gcc-4.3 bravais.c mathfunc.c -O3
bravais.c: In function âmainâ:
bravais.c:83: warning: incompatible implicit declaration of built-in function
âprintfâ
xavier@corvo:~$ ./a.out
-1
Sorry for using two files, but the problem disappears if all functions are in a
single file.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug middle-end/36008] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (5 preceding siblings ...)
2008-04-22 22:52 ` xavier at tddft dot org
@ 2008-04-23 10:04 ` rguenth at gcc dot gnu dot org
2008-04-23 11:02 ` [Bug rtl-optimization/36008] [4.3/4.4 Regression] " rguenth at gcc dot gnu dot org
` (8 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-04-23 10:04 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from rguenth at gcc dot gnu dot org 2008-04-23 10:03 -------
Created an attachment (id=15515)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15515&action=view)
simplified bravais.c
gcc -c mathfunc.c
gcc -o t.ok bravais.c mathfunc.o -O
gcc -o t.fail bravais.c mathfunc.o -O -funroll-loops
./t.ok
./t.fail
Aborted
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #15513|0 |1
is obsolete| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug rtl-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (6 preceding siblings ...)
2008-04-23 10:04 ` rguenth at gcc dot gnu dot org
@ 2008-04-23 11:02 ` rguenth at gcc dot gnu dot org
2008-04-23 16:36 ` jakub at gcc dot gnu dot org
` (7 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-04-23 11:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from rguenth at gcc dot gnu dot org 2008-04-23 11:02 -------
This goes wrong somewhere during RTL optimization.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Component|middle-end |rtl-optimization
Ever Confirmed|0 |1
Keywords| |wrong-code
Last reconfirmed|0000-00-00 00:00:00 |2008-04-23 11:02:01
date| |
Summary|Function produces wrong |[4.3/4.4 Regression]
|results when inlined. |Function produces wrong
| |results when inlined.
Target Milestone|--- |4.3.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug rtl-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (7 preceding siblings ...)
2008-04-23 11:02 ` [Bug rtl-optimization/36008] [4.3/4.4 Regression] " rguenth at gcc dot gnu dot org
@ 2008-04-23 16:36 ` jakub at gcc dot gnu dot org
2008-04-23 16:54 ` jakub at gcc dot gnu dot org
` (6 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-23 16:36 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from jakub at gcc dot gnu dot org 2008-04-23 16:35 -------
Even more simplified testcase, with just one CU. Works at -O0/-O/-O2, fails at
-O{,2} -funroll-loops or -O3.
extern void abort (void);
void __attribute__ ((noinline))
bar (int m[3][3], int a[3][3], int b[3][3])
{
int i, j;
for (i = 0; i < 3; i++)
for (j = 0; j < 3; j++)
m[i][j] = a[i][0] * b[0][j] + a[i][1] * b[1][j] + a[i][2] * b[2][j];
}
static inline void __attribute__ ((always_inline))
foo (int x[][3][3], int g[3][3], int y, int z)
{
int i, j, k;
for (i = 0; i < y; i++)
for (j = 0; j < z - 1; j++)
{
k = i * (z - 1) + j + y;
bar (x[k], g, x[k - y]);
}
}
int g1[48][3][3] = { { {1, 0, 0}, {0, 1, 0}, {0, 0, 1} } };
int g2[3][3] = { {-1, 0, 0}, {0, -1, 0}, {0, 0, -1} };
int g3[3][3] = { {0, 1, 0}, {1, 0, 0}, {0, 0, 1} };
int g4[3][3] = { {-1, 0, 0}, {0, 1, 0}, {0, 0, -1} };
int g5[3][3] = { {-1, 0, 0}, {0, -1, 0}, {0, 0, 1} };
int
main ()
{
foo (g1, g2, 1, 2);
foo (g1, g4, 2, 2);
foo (g1, g5, 4, 2);
foo (g1, g3, 8, 2);
if (g1[1][1][0] != 0)
abort ();
return 0;
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug rtl-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (8 preceding siblings ...)
2008-04-23 16:36 ` jakub at gcc dot gnu dot org
@ 2008-04-23 16:54 ` jakub at gcc dot gnu dot org
2008-04-24 9:34 ` jakub at gcc dot gnu dot org
` (5 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-23 16:54 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from jakub at gcc dot gnu dot org 2008-04-23 16:53 -------
And one with just one inlined fn:
extern void abort (void);
void __attribute__ ((noinline))
bar (int m[3][3], int a[3][3], int b[3][3])
{
int i, j;
for (i = 0; i < 3; i++)
for (j = 0; j < 3; j++)
m[i][j] = a[i][0] * b[0][j] + a[i][1] * b[1][j] + a[i][2] * b[2][j];
}
static inline void __attribute__ ((always_inline))
foo (int x[][3][3], int g[3][3], int y, int z)
{
int i, j, k;
for (i = 0; i < y; i++)
for (j = 0; j < z - 1; j++)
{
k = i * (z - 1) + j + y;
bar (x[k], g, x[k - y]);
}
}
int g[48][3][3] = {
{ {1, 0, 0}, {0, 1, 0}, {0, 0, 1} }, { {-1, 0, 0}, {0, -1, 0}, {0, 0, -1} },
{ {-1, 0, 0}, {0, 1, 0}, {0, 0, -1} }, { {1, 0, 0}, {0, -1, 0}, {0, 0, 1} },
{ {-1, 0, 0}, {0, -1, 0}, {0, 0, 1} }, { {1, 0, 0}, {0, 1, 0}, {0, 0, -1} },
{ {1, 0, 0}, {0, -1, 0}, { 0, 0, -1} }, { {-1, 0, 0}, {0, 1, 0}, {0, 0, 1} } };
int h[3][3] = { {0, 1, 0}, {1, 0, 0}, {0, 0, 1} };
int
main ()
{
foo (g, h, 8, 2);
if (g[1][1][0] != 0)
abort ();
return 0;
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug rtl-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (9 preceding siblings ...)
2008-04-23 16:54 ` jakub at gcc dot gnu dot org
@ 2008-04-24 9:34 ` jakub at gcc dot gnu dot org
2008-04-24 10:00 ` [Bug tree-optimization/36008] " jakub at gcc dot gnu dot org
` (4 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-24 9:34 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from jakub at gcc dot gnu dot org 2008-04-24 09:33 -------
extern void abort (void);
int g[48][3][3];
void __attribute__ ((noinline))
bar (int x[3][3], int y[3][3])
{
static int i;
if (x != g[i + 8] || y != g[i++])
abort ();
}
static inline void __attribute__ ((always_inline))
foo (int x[][3][3])
{
int i;
for (i = 0; i < 8; i++)
#ifdef GOOD
bar (x[i + 8], x[i]);
#else
{
int k = i + 8;
bar (x[k], x[k - 8]);
}
#endif
}
int
main ()
{
foo (g);
return 0;
}
with -DGOOD doesn't fail at any optimization level, without it fails again with
-O2 -funroll-loops, -O3 etc.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug tree-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (10 preceding siblings ...)
2008-04-24 9:34 ` jakub at gcc dot gnu dot org
@ 2008-04-24 10:00 ` jakub at gcc dot gnu dot org
2008-04-24 11:29 ` jakub at gcc dot gnu dot org
` (3 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-24 10:00 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from jakub at gcc dot gnu dot org 2008-04-24 09:59 -------
This is actually a tree optimization issue. In optimized dump without -DGOOD
we have:
bar (&g[0][0] + 288, &g[0][0]);
bar (&g[0][0] + 324, &g[1][0]);
bar (&g[0][0] + 360, &g[2][0]);
bar (&g[0][0] + 396, &g[3][0]);
bar (&g[1][0], &g[4][0]);
bar (&g[0][0] + 468, &g[5][0]);
bar (&g[0][0] + 504, &g[6][0]);
bar (&g[0][0] + 540, &g[7][0]);
note the bogus first argument for 5th bar call, should have been &g[0][0] + 432
aka &g[12][0].
In *.reassoc2 we have for the 4th and 5th bar calls:
i_73 = i_56 + 1;
k_80 = i_73 + 8;
D.1588_81 = (long unsigned int) k_80;
D.1589_82 = D.1588_81 * 36;
D.1590_83 = D.1589_82 + -288;
D.1591_84 = &g + D.1590_83;
D.1592_85 = &(*D.1591_84)[0];
D.1594_86 = &g[0][0] + D.1589_82;
bar (D.1594_86, D.1592_85);
i_90 = i_73 + 1;
k_97 = i_90 + 8;
D.1588_98 = (long unsigned int) k_97;
D.1589_99 = D.1588_98 * 36;
D.1590_100 = D.1589_99 + -288;
D.1591_101 = &g + D.1590_100;
D.1592_102 = &(*D.1591_101)[0];
D.1594_103 = &g[0][0] + D.1589_99;
bar (D.1594_103, D.1592_102);
which looks correct, but in *.vrp2:
i_73 = 3;
k_80 = 11;
D.1588_81 = 11;
D.1589_82 = 396;
D.1590_83 = 108;
D.1591_84 = &g[3];
D.1592_85 = &(*D.1591_84)[0];
D.1594_86 = &g[0][0] + 396;
bar (D.1594_86, D.1592_85);
i_90 = 4;
k_97 = 12;
D.1588_98 = 12;
D.1589_99 = 432;
D.1590_100 = 144;
D.1591_101 = &g[4];
D.1592_102 = &(*D.1591_101)[0];
D.1594_103 = &g[1][0];
bar (&g[1][0], D.1592_102);
which is wrong. So to me this looks like vrp bug.
--
jakub at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|rtl-optimization |tree-optimization
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug tree-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (11 preceding siblings ...)
2008-04-24 10:00 ` [Bug tree-optimization/36008] " jakub at gcc dot gnu dot org
@ 2008-04-24 11:29 ` jakub at gcc dot gnu dot org
2008-04-24 16:09 ` jakub at gcc dot gnu dot org
` (2 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-24 11:29 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from jakub at gcc dot gnu dot org 2008-04-24 11:29 -------
Created an attachment (id=15524)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15524&action=view)
gcc43-pr36008.patch
Fix I'm bootstrapping/regtesting ATM.
--
jakub at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |jakub at gcc dot gnu dot org
|dot org |
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug tree-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (12 preceding siblings ...)
2008-04-24 11:29 ` jakub at gcc dot gnu dot org
@ 2008-04-24 16:09 ` jakub at gcc dot gnu dot org
2008-04-24 16:20 ` jakub at gcc dot gnu dot org
2008-04-24 16:33 ` jakub at gcc dot gnu dot org
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-24 16:09 UTC (permalink / raw)
To: gcc-bugs
------- Comment #14 from jakub at gcc dot gnu dot org 2008-04-24 16:08 -------
Subject: Bug 36008
Author: jakub
Date: Thu Apr 24 16:08:11 2008
New Revision: 134634
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=134634
Log:
PR tree-optimization/36008
* fold-const.c (try_move_mult_to_index): If s == NULL, divide
the original op1, rather than delta by step.
* gcc.c-torture/execute/20080424-1.c: New test.
Added:
trunk/gcc/testsuite/gcc.c-torture/execute/20080424-1.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/fold-const.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug tree-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (13 preceding siblings ...)
2008-04-24 16:09 ` jakub at gcc dot gnu dot org
@ 2008-04-24 16:20 ` jakub at gcc dot gnu dot org
2008-04-24 16:33 ` jakub at gcc dot gnu dot org
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-24 16:20 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from jakub at gcc dot gnu dot org 2008-04-24 16:20 -------
Subject: Bug 36008
Author: jakub
Date: Thu Apr 24 16:19:22 2008
New Revision: 134636
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=134636
Log:
PR tree-optimization/36008
* fold-const.c (try_move_mult_to_index): If s == NULL, divide
the original op1, rather than delta by step.
* gcc.c-torture/execute/20080424-1.c: New test.
Added:
branches/gcc-4_3-branch/gcc/testsuite/gcc.c-torture/execute/20080424-1.c
Modified:
branches/gcc-4_3-branch/gcc/ChangeLog
branches/gcc-4_3-branch/gcc/fold-const.c
branches/gcc-4_3-branch/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug tree-optimization/36008] [4.3/4.4 Regression] Function produces wrong results when inlined.
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
` (14 preceding siblings ...)
2008-04-24 16:20 ` jakub at gcc dot gnu dot org
@ 2008-04-24 16:33 ` jakub at gcc dot gnu dot org
15 siblings, 0 replies; 17+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-04-24 16:33 UTC (permalink / raw)
To: gcc-bugs
------- Comment #16 from jakub at gcc dot gnu dot org 2008-04-24 16:32 -------
Fixed.
--
jakub at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36008
^ permalink raw reply [flat|nested] 17+ messages in thread
end of thread, other threads:[~2008-04-24 16:33 UTC | newest]
Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-04-22 13:51 [Bug c/36008] New: Function produces wrong results when inlined xavier at tddft dot org
2008-04-22 13:53 ` [Bug c/36008] " xavier at tddft dot org
2008-04-22 14:14 ` aldot at gcc dot gnu dot org
2008-04-22 17:17 ` xavier at tddft dot org
2008-04-22 22:49 ` [Bug middle-end/36008] " xavier at tddft dot org
2008-04-22 22:50 ` xavier at tddft dot org
2008-04-22 22:52 ` xavier at tddft dot org
2008-04-23 10:04 ` rguenth at gcc dot gnu dot org
2008-04-23 11:02 ` [Bug rtl-optimization/36008] [4.3/4.4 Regression] " rguenth at gcc dot gnu dot org
2008-04-23 16:36 ` jakub at gcc dot gnu dot org
2008-04-23 16:54 ` jakub at gcc dot gnu dot org
2008-04-24 9:34 ` jakub at gcc dot gnu dot org
2008-04-24 10:00 ` [Bug tree-optimization/36008] " jakub at gcc dot gnu dot org
2008-04-24 11:29 ` jakub at gcc dot gnu dot org
2008-04-24 16:09 ` jakub at gcc dot gnu dot org
2008-04-24 16:20 ` jakub at gcc dot gnu dot org
2008-04-24 16:33 ` jakub at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).