* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
@ 2012-01-15 14:30 ` dominiq at lps dot ens.fr
2012-01-15 17:01 ` jakub at gcc dot gnu.org
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: dominiq at lps dot ens.fr @ 2012-01-15 14:30 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
Dominique d'Humieres <dominiq at lps dot ens.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-01-15
Summary|ICE in insert_vi_for_tree, |[4.7 Regression] ICE in
|at |insert_vi_for_tree, at
|tree-ssa-structalias.c:2642 |tree-ssa-structalias.c:2642
Ever Confirmed|0 |1
--- Comment #1 from Dominique d'Humieres <dominiq at lps dot ens.fr> 2012-01-15 14:05:50 UTC ---
Confirmed on powerpc-apple-darwin9 and x86_64-apple-darwin10 with revision
183181. Revision 183001 is OK. The ICE is also triggered with '-O1
-finline-small-functions -finline-functions -fipa-pta -fpartial-inlining' up to
'-O3 -fipa-pta'. If I set a break point for insert_vi_for_tree, I see it
called several time before reaching:
Breakpoint 1, insert_vi_for_tree (t=<value optimized out>, vi=<value optimized
out>) at ../../work/gcc/tree-ssa-structalias.c:2639
2639 {
(gdb) bt
#0 insert_vi_for_tree (t=<value optimized out>, vi=<value optimized out>) at
../../work/gcc/tree-ssa-structalias.c:2639
#1 0x00000001008deb61 in ipa_pta_execute () at
../../work/gcc/tree-ssa-structalias.c:5343
#2 0x000000010068d299 in execute_one_pass (pass=0x100da2120) at
../../work/gcc/passes.c:2081
#3 0x000000010068db32 in execute_ipa_pass_list (pass=0x100da2120) at
../../work/gcc/passes.c:2448
#4 0x0000000100399c06 in cgraph_optimize () at
../../work/gcc/cgraphunit.c:2183
#5 0x000000010039a90a in cgraph_finalize_compilation_unit () at
../../work/gcc/cgraphunit.c:1327
#6 0x0000000100020613 in c_write_global_declarations () at
../../work/gcc/c-decl.c:10030
#7 0x0000000100750640 in toplev_main (argc=4, argv=0x7fff5fbfd808) at
../../work/gcc/toplev.c:573
#8 0x00000001000014d4 in start ()
(gdb) c
Continuing.
pr51865.c:6:1: internal compiler error: in insert_vi_for_tree, at
tree-ssa-structalias.c:2642
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
Program exited with code 04.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
2012-01-15 14:30 ` [Bug tree-optimization/51865] [4.7 Regression] " dominiq at lps dot ens.fr
@ 2012-01-15 17:01 ` jakub at gcc dot gnu.org
2012-01-15 17:12 ` dominiq at lps dot ens.fr
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-01-15 17:01 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-15 15:30:58 UTC ---
Please attach preprocessed testcase.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
2012-01-15 14:30 ` [Bug tree-optimization/51865] [4.7 Regression] " dominiq at lps dot ens.fr
2012-01-15 17:01 ` jakub at gcc dot gnu.org
@ 2012-01-15 17:12 ` dominiq at lps dot ens.fr
2012-01-15 17:22 ` steven at gcc dot gnu.org
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: dominiq at lps dot ens.fr @ 2012-01-15 17:12 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
--- Comment #3 from Dominique d'Humieres <dominiq at lps dot ens.fr> 2012-01-15 16:09:20 UTC ---
Created attachment 26333
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26333
preprocessed testcase
> Please attach preprocessed testcase.
r183091 is OK
r183136 gives the ICE.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (2 preceding siblings ...)
2012-01-15 17:12 ` dominiq at lps dot ens.fr
@ 2012-01-15 17:22 ` steven at gcc dot gnu.org
2012-01-15 17:31 ` jakub at gcc dot gnu.org
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: steven at gcc dot gnu.org @ 2012-01-15 17:22 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
Steven Bosscher <steven at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |steven at gcc dot gnu.org
--- Comment #4 from Steven Bosscher <steven at gcc dot gnu.org> 2012-01-15 17:12:29 UTC ---
Confirmed also on x86_64-unknown-linux-gnu
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (3 preceding siblings ...)
2012-01-15 17:22 ` steven at gcc dot gnu.org
@ 2012-01-15 17:31 ` jakub at gcc dot gnu.org
2012-01-15 17:40 ` jakub at gcc dot gnu.org
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-01-15 17:31 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-15 17:22:03 UTC ---
/* { dg-do compile } */
/* { dg-options "-O2 -fipa-pta" } */
void fn (const char *, const char *) __attribute__ ((__noreturn__));
int var;
inline void
foo (void)
{
if (__builtin_expect (var != 0, 0))
fn ("a", "b");
};
void
bar (void)
{
foo ();
};
void
baz (void)
{
foo ();
};
Started with http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=183102
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (4 preceding siblings ...)
2012-01-15 17:31 ` jakub at gcc dot gnu.org
@ 2012-01-15 17:40 ` jakub at gcc dot gnu.org
2012-01-15 18:03 ` steven at gcc dot gnu.org
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-01-15 17:40 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.7.0
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (5 preceding siblings ...)
2012-01-15 17:40 ` jakub at gcc dot gnu.org
@ 2012-01-15 18:03 ` steven at gcc dot gnu.org
2012-01-15 19:15 ` jakub at gcc dot gnu.org
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: steven at gcc dot gnu.org @ 2012-01-15 18:03 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
--- Comment #6 from Steven Bosscher <steven at gcc dot gnu.org> 2012-01-15 17:31:14 UTC ---
(In reply to comment #5)
> Started with http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=183102
That is the patch here:
http://gcc.gnu.org/ml/gcc-patches/2012-01/msg00510.html
So if someone comes up with a fix for this: Please also test with Ada enabled.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (6 preceding siblings ...)
2012-01-15 18:03 ` steven at gcc dot gnu.org
@ 2012-01-15 19:15 ` jakub at gcc dot gnu.org
2012-01-16 11:18 ` jakub at gcc dot gnu.org
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-01-15 19:15 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
AssignedTo|unassigned at gcc dot |jakub at gcc dot gnu.org
|gnu.org |
--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-15 19:11:55 UTC ---
Created attachment 26334
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26334
gcc47-pr51865.patch
Untested fix. If DECL_RESULT has void type, it must have remap_decl called on
it, otherwise we share the same RESULT_DECL between multiple functions.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (7 preceding siblings ...)
2012-01-15 19:15 ` jakub at gcc dot gnu.org
@ 2012-01-16 11:18 ` jakub at gcc dot gnu.org
2012-01-16 12:14 ` jakub at gcc dot gnu.org
2012-01-22 11:40 ` gcc@Denis-Excoffier.org
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-01-16 11:18 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-16 11:12:58 UTC ---
Author: jakub
Date: Mon Jan 16 11:12:53 2012
New Revision: 183207
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=183207
Log:
PR tree-optimization/51865
* tree-inline.c (tree_function_versioning): Call remap_decl
on DECL_RESULT whenever it has VOID_TYPE_P type.
* gcc.dg/pr51865.c: New test.
Added:
trunk/gcc/testsuite/gcc.dg/pr51865.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-inline.c
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (8 preceding siblings ...)
2012-01-16 11:18 ` jakub at gcc dot gnu.org
@ 2012-01-16 12:14 ` jakub at gcc dot gnu.org
2012-01-22 11:40 ` gcc@Denis-Excoffier.org
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-01-16 12:14 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
--- Comment #9 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-16 11:16:41 UTC ---
Fixed.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug tree-optimization/51865] [4.7 Regression] ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642
2012-01-15 14:06 [Bug tree-optimization/51865] New: ICE in insert_vi_for_tree, at tree-ssa-structalias.c:2642 gcc@Denis-Excoffier.org
` (9 preceding siblings ...)
2012-01-16 12:14 ` jakub at gcc dot gnu.org
@ 2012-01-22 11:40 ` gcc@Denis-Excoffier.org
10 siblings, 0 replies; 12+ messages in thread
From: gcc@Denis-Excoffier.org @ 2012-01-22 11:40 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51865
--- Comment #10 from Denis Excoffier <gcc@Denis-Excoffier.org> 2012-01-22 10:18:47 UTC ---
(In reply to comment #9)
> Fixed.
Confirmed, using gcc-4.7-20120121. Thank you.
^ permalink raw reply [flat|nested] 12+ messages in thread