* [Bug c/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
@ 2009-01-27 1:00 ` kamaraju at gmail dot com
2009-01-27 1:02 ` [Bug middle-end/38981] " pinskia at gcc dot gnu dot org
` (16 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-01-27 1:00 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from kamaraju at gmail dot com 2009-01-27 01:00 -------
Created an attachment (id=17187)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17187&action=view)
code to reproduce the internal compiler error
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug middle-end/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
2009-01-27 1:00 ` [Bug c/38981] " kamaraju at gmail dot com
@ 2009-01-27 1:02 ` pinskia at gcc dot gnu dot org
2009-01-27 1:05 ` kamaraju at gmail dot com
` (15 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-01-27 1:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from pinskia at gcc dot gnu dot org 2009-01-27 01:01 -------
Can you provide the preprocessed source?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug middle-end/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
2009-01-27 1:00 ` [Bug c/38981] " kamaraju at gmail dot com
2009-01-27 1:02 ` [Bug middle-end/38981] " pinskia at gcc dot gnu dot org
@ 2009-01-27 1:05 ` kamaraju at gmail dot com
2009-01-27 1:08 ` [Bug bootstrap/38981] " pinskia at gcc dot gnu dot org
` (14 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-01-27 1:05 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from kamaraju at gmail dot com 2009-01-27 01:05 -------
Created an attachment (id=17188)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17188&action=view)
preprocessed source code
produced by using
gcc -E ice.c > ice.c.ppd
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (2 preceding siblings ...)
2009-01-27 1:05 ` kamaraju at gmail dot com
@ 2009-01-27 1:08 ` pinskia at gcc dot gnu dot org
2009-01-27 1:14 ` kamaraju at gmail dot com
` (13 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-01-27 1:08 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pinskia at gcc dot gnu dot org 2009-01-27 01:08 -------
So if I am reading this thread correctly this is really a bug in Solaris's
yacc?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (3 preceding siblings ...)
2009-01-27 1:08 ` [Bug bootstrap/38981] " pinskia at gcc dot gnu dot org
@ 2009-01-27 1:14 ` kamaraju at gmail dot com
2009-01-27 1:20 ` kamaraju at gmail dot com
` (12 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-01-27 1:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from kamaraju at gmail dot com 2009-01-27 01:14 -------
My initial guess was that it is a bug in yacc. But now I do not think so. I
have compiled bison (which supersedes yacc). I still see this bug with bison
(and no yacc).
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (4 preceding siblings ...)
2009-01-27 1:14 ` kamaraju at gmail dot com
@ 2009-01-27 1:20 ` kamaraju at gmail dot com
2009-01-27 2:01 ` kamaraju at gmail dot com
` (11 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-01-27 1:20 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from kamaraju at gmail dot com 2009-01-27 01:20 -------
Is there anyway to figure out if my gcc is still using yacc and not bison?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (5 preceding siblings ...)
2009-01-27 1:20 ` kamaraju at gmail dot com
@ 2009-01-27 2:01 ` kamaraju at gmail dot com
2009-01-27 13:51 ` kamaraju at gmail dot com
` (10 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-01-27 2:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from kamaraju at gmail dot com 2009-01-27 02:00 -------
I can't believe I am so dense... I installed bison, removed /usr/ccs/bin from
the PATH. But I forgot to recompile gcc with the new update. I was still trying
to bootstrap from the old compiler. Let me recompile gcc (with bison) and see
if the problem goes away. It usually takes one day to finish...
raju
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (6 preceding siblings ...)
2009-01-27 2:01 ` kamaraju at gmail dot com
@ 2009-01-27 13:51 ` kamaraju at gmail dot com
2009-02-06 19:04 ` grxnprzn at gmx dot net
` (9 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-01-27 13:51 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from kamaraju at gmail dot com 2009-01-27 13:51 -------
I would like to confirm that, even after recompiling gcc with bison, I am still
getting the internal compiler error. There is no yacc, no /usr/ccs/bin in $PATH
when gcc was compiled.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (7 preceding siblings ...)
2009-01-27 13:51 ` kamaraju at gmail dot com
@ 2009-02-06 19:04 ` grxnprzn at gmx dot net
2009-02-06 21:26 ` kamaraju at gmail dot com
` (8 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: grxnprzn at gmx dot net @ 2009-02-06 19:04 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from grxnprzn at gmx dot net 2009-02-06 19:04 -------
If someone is working on this, you might want to look at #37798, too. I have no
idea wether these two are connected, but GCC definitively has problems with
alignment on SPARC.
--
grxnprzn at gmx dot net changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |grxnprzn at gmx dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (8 preceding siblings ...)
2009-02-06 19:04 ` grxnprzn at gmx dot net
@ 2009-02-06 21:26 ` kamaraju at gmail dot com
2009-02-06 21:28 ` kamaraju at gmail dot com
` (7 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-02-06 21:26 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from kamaraju at gmail dot com 2009-02-06 21:26 -------
Created an attachment (id=17263)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17263&action=view)
reduced program which reproduces the ICE
Attaching a reduced test case which reproduces the same error.
> gcc -c ice3.c
ice3.c: In function 'd_substitution':
ice3.c:11: internal compiler error: Segmentation Fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
> gcc -v
Using built-in specs.
Target: sparc-sun-solaris2.8
Configured with:
/home/kkusuman/software/unZipped/gcc-4.4-wkly_gmp-4.2.4_mpfr-2.4.0/configure
--enable-languages=c,c++,fortran
--with-as=/mlim/u/dev/tools/apps/gnu/arch/sol8.sun4/bin/as
--with-ld=/mlim/u/dev/tools/apps/gnu/arch/sol8.sun4/bin/ld
--with-build-time-tools=/mlim/u/dev/tools/apps/gnu/arch/sol8.sun4/bin
--prefix=/home/kkusuman/software/myroot/gcc-4.4-20090123
Thread model: posix
gcc version 4.4.0 20090123 (experimental) (GCC)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (9 preceding siblings ...)
2009-02-06 21:26 ` kamaraju at gmail dot com
@ 2009-02-06 21:28 ` kamaraju at gmail dot com
2009-02-08 10:09 ` [Bug bootstrap/38981] [4.4 regression] " ebotcazou at gcc dot gnu dot org
` (6 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: kamaraju at gmail dot com @ 2009-02-06 21:28 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from kamaraju at gmail dot com 2009-02-06 21:28 -------
Created an attachment (id=17264)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17264&action=view)
preprocessed source code of ice3.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug bootstrap/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (10 preceding siblings ...)
2009-02-06 21:28 ` kamaraju at gmail dot com
@ 2009-02-08 10:09 ` ebotcazou at gcc dot gnu dot org
2009-02-08 10:12 ` [Bug target/38981] " ebotcazou at gcc dot gnu dot org
` (5 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-08 10:09 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from ebotcazou at gcc dot gnu dot org 2009-02-08 10:09 -------
Confirmed on Solaris 8, but neither on Solaris 9 nor on Solaris 10.
--
ebotcazou at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Keywords|wrong-code |
Last reconfirmed|0000-00-00 00:00:00 |2009-02-08 10:09:42
date| |
Summary|internal compiler error |[4.4 regression] internal
| |compiler error
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug target/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (11 preceding siblings ...)
2009-02-08 10:09 ` [Bug bootstrap/38981] [4.4 regression] " ebotcazou at gcc dot gnu dot org
@ 2009-02-08 10:12 ` ebotcazou at gcc dot gnu dot org
2009-02-08 10:26 ` ebotcazou at gcc dot gnu dot org
` (4 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-08 10:12 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from ebotcazou at gcc dot gnu dot org 2009-02-08 10:11 -------
Btw, the default extension for preprocessed sources is .i, just pass
-save-temps
to the compiler to get the file.
--
ebotcazou at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |ebotcazou at gcc dot gnu dot
|dot org |org
Status|NEW |ASSIGNED
Component|bootstrap |target
Last reconfirmed|2009-02-08 10:09:42 |2009-02-08 10:11:55
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug target/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (12 preceding siblings ...)
2009-02-08 10:12 ` [Bug target/38981] " ebotcazou at gcc dot gnu dot org
@ 2009-02-08 10:26 ` ebotcazou at gcc dot gnu dot org
2009-02-08 10:58 ` ebotcazou at gcc dot gnu dot org
` (3 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-08 10:26 UTC (permalink / raw)
To: gcc-bugs
------- Comment #14 from ebotcazou at gcc dot gnu dot org 2009-02-08 10:26 -------
This is a bug in the qsort implementation on Solaris 8:
Breakpoint 1, sort_coalesce_list (cl=0x1ce4b80)
at /nile.build/botcazou/gcc-head/src/gcc/tree-ssa-coalesce.c:434
434 qsort (cl->sorted, num, sizeof (coalesce_pair_p), compare_pairs);
(gdb) p cl->sorted
$22 = (coalesce_pair_p *) 0x1cc4e88
(gdb) p num
$23 = 8
(gdb) continue
Continuing.
Program received signal SIGSEGV, Segmentation fault.
0x00f1bb00 in compare_pairs (p1=0x1cc4e84, p2=0x1cc4e8c)
at /nile.build/botcazou/gcc-head/src/gcc/tree-ssa-coalesce.c:318
318 result = (* pp2)->cost - (* pp1)->cost;
i.e. the comparator is invoked on &cl->sorted[-1], which is invalid.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug target/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (13 preceding siblings ...)
2009-02-08 10:26 ` ebotcazou at gcc dot gnu dot org
@ 2009-02-08 10:58 ` ebotcazou at gcc dot gnu dot org
2009-02-08 12:33 ` [Bug middle-end/38981] " ebotcazou at gcc dot gnu dot org
` (2 subsequent siblings)
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-08 10:58 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from ebotcazou at gcc dot gnu dot org 2009-02-08 10:58 -------
> This is a bug in the qsort implementation on Solaris 8:
Browsing the Sun database shows several related tickets, but most have been
closed as "not a defect" on the ground that the comparator function fails to
impose a total order on the array. That's the case here because of overflow:
(gdb) p cl->sorted[0].cost
$29 = 2147483646
(gdb) p cl->sorted[1].cost
$30 = -2147483644
(gdb) p cl->sorted[2].cost
$31 = -2147483648
(gdb) p cl->sorted[3].cost
$32 = 2
(gdb) p cl->sorted[4].cost
$33 = -2147483648
(gdb) p cl->sorted[5].cost
$34 = 2
(gdb) p cl->sorted[6].cost
$35 = 2147483646
(gdb) p cl->sorted[7].cost
$36 = 2147483646
Breakpoint 2, compare_pairs (p1=0x1cc4e88, p2=0x1cc4e8c)
at /nile.build/botcazou/gcc-head/src/gcc/tree-ssa-coalesce.c:314
314 const_coalesce_pair_p const *const pp1 = (const_coalesce_pair_p const
*) p1;
(gdb) next
315 const_coalesce_pair_p const *const pp2 = (const_coalesce_pair_p const
*) p2;
(gdb)
318 result = (* pp2)->cost - (* pp1)->cost;
(gdb) p (* pp2)->cost
$46 = -2147483644
(gdb) p (* pp1)->cost
$47 = 2147483646
(gdb) next
322 if (result == 0)
(gdb) p result
$48 = 6
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug middle-end/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (14 preceding siblings ...)
2009-02-08 10:58 ` ebotcazou at gcc dot gnu dot org
@ 2009-02-08 12:33 ` ebotcazou at gcc dot gnu dot org
2009-02-09 11:09 ` ebotcazou at gcc dot gnu dot org
2009-02-09 11:11 ` ebotcazou at gcc dot gnu dot org
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-08 12:33 UTC (permalink / raw)
To: gcc-bugs
------- Comment #16 from ebotcazou at gcc dot gnu dot org 2009-02-08 12:33 -------
Recategorizing.
--
ebotcazou at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|target |middle-end
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug middle-end/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (15 preceding siblings ...)
2009-02-08 12:33 ` [Bug middle-end/38981] " ebotcazou at gcc dot gnu dot org
@ 2009-02-09 11:09 ` ebotcazou at gcc dot gnu dot org
2009-02-09 11:11 ` ebotcazou at gcc dot gnu dot org
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-09 11:09 UTC (permalink / raw)
To: gcc-bugs
------- Comment #17 from ebotcazou at gcc dot gnu dot org 2009-02-09 11:09 -------
Subject: Bug 38981
Author: ebotcazou
Date: Mon Feb 9 11:09:25 2009
New Revision: 144032
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=144032
Log:
PR middle-end/38981
* tree-ssa-coalesce.c (add_coalesce): Cap the costs of coalesce pairs
at MUST_COALESCE_COST-1 instead of MUST_COALESCE_COST.
Added:
trunk/gcc/testsuite/gcc.c-torture/compile/20090209-1.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-coalesce.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread
* [Bug middle-end/38981] [4.4 regression] internal compiler error
2009-01-27 0:58 [Bug c/38981] New: internal compiler error kamaraju at gmail dot com
` (16 preceding siblings ...)
2009-02-09 11:09 ` ebotcazou at gcc dot gnu dot org
@ 2009-02-09 11:11 ` ebotcazou at gcc dot gnu dot org
17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2009-02-09 11:11 UTC (permalink / raw)
To: gcc-bugs
------- Comment #18 from ebotcazou at gcc dot gnu dot org 2009-02-09 11:11 -------
Thanks for reporting the problem.
--
ebotcazou at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
URL| |http://gcc.gnu.org/ml/gcc-
| |patches/2009-
| |02/msg00380.html
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.4.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38981
^ permalink raw reply [flat|nested] 19+ messages in thread