* [Bug tree-optimization/58619] ICE building in gen_combined_adhoc_loc
2013-10-04 13:01 [Bug tree-optimization/58619] New: ICE building libstdc++-v3 on arm-none-linux-gnueabihf in gen_combined_adhoc_loc ramana at gcc dot gnu.org
@ 2013-10-04 13:07 ` ramana at gcc dot gnu.org
2013-10-04 13:43 ` hubicka at gcc dot gnu.org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: ramana at gcc dot gnu.org @ 2013-10-04 13:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58619
Ramana Radhakrishnan <ramana at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target| |arm-none-linux-gnueabi,
| |arm-none-linux-gnueabihf
Status|UNCONFIRMED |NEW
Keywords| |ice-on-valid-code
Last reconfirmed| |2013-10-04
Ever confirmed|0 |1
Summary|ICE building libstdc++-v3 |ICE building in
|on arm-none-linux-gnueabihf |gen_combined_adhoc_loc
|in gen_combined_adhoc_loc |
Target Milestone|--- |4.9.0
Known to fail| |4.9.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/58619] ICE building in gen_combined_adhoc_loc
2013-10-04 13:01 [Bug tree-optimization/58619] New: ICE building libstdc++-v3 on arm-none-linux-gnueabihf in gen_combined_adhoc_loc ramana at gcc dot gnu.org
2013-10-04 13:07 ` [Bug tree-optimization/58619] ICE building " ramana at gcc dot gnu.org
@ 2013-10-04 13:43 ` hubicka at gcc dot gnu.org
2013-10-04 15:08 ` hubicka at gcc dot gnu.org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: hubicka at gcc dot gnu.org @ 2013-10-04 13:43 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58619
Jan Hubicka <hubicka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |hubicka at gcc dot gnu.org,
| |jakub at redhat dot com,
| |rguenther at suse dot de
--- Comment #1 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
The problem is only triggered by Rong's patch - changes in profile should never
provoke ICE in inliner.
We ICE in
129921 jakub }
191494 dehao locus = gimple_phi_arg_location_from_edge (phi,
old_edge);
191494 dehao if (LOCATION_BLOCK (locus))
191494 dehao {
191494 dehao tree *n;
191494 dehao n = (tree *) pointer_map_contains
(id->decl_map,
191494 dehao LOCATION_BLOCK (locus));
191494 dehao gcc_assert (n);
195509 rguenth locus = COMBINE_LOCATION_DATA (line_table,
locus, *n);
191494 dehao }
195509 rguenth else
195509 rguenth locus = LOCATION_LOCUS (locus);
191494 dehao
195509 rguenth add_phi_arg (new_phi, new_arg, new_edge, locus);
calling COMBINE_LOCAL_DATA. I am not familiar with this code.
The code in question was added by
http://gcc.gnu.org/ml/gcc-patches/2013-01/msg01311.html
Richi, Jakub, any ideas?
I am trying to reprodue this in cross.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/58619] ICE building in gen_combined_adhoc_loc
2013-10-04 13:01 [Bug tree-optimization/58619] New: ICE building libstdc++-v3 on arm-none-linux-gnueabihf in gen_combined_adhoc_loc ramana at gcc dot gnu.org
2013-10-04 13:07 ` [Bug tree-optimization/58619] ICE building " ramana at gcc dot gnu.org
2013-10-04 13:43 ` hubicka at gcc dot gnu.org
@ 2013-10-04 15:08 ` hubicka at gcc dot gnu.org
2013-10-04 18:48 ` dehao at google dot com
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: hubicka at gcc dot gnu.org @ 2013-10-04 15:08 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58619
--- Comment #2 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
The ICE is caused by *n being NULL, so it seems we did not remap the block.
This perhaps means that we have stale block in the edge location?
Honza
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/58619] ICE building in gen_combined_adhoc_loc
2013-10-04 13:01 [Bug tree-optimization/58619] New: ICE building libstdc++-v3 on arm-none-linux-gnueabihf in gen_combined_adhoc_loc ramana at gcc dot gnu.org
` (2 preceding siblings ...)
2013-10-04 15:08 ` hubicka at gcc dot gnu.org
@ 2013-10-04 18:48 ` dehao at google dot com
2013-10-08 8:34 ` ramana at gcc dot gnu.org
2013-10-08 17:00 ` ramana at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: dehao at google dot com @ 2013-10-04 18:48 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58619
Dehao Chen <dehao at google dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dehao at google dot com
--- Comment #3 from Dehao Chen <dehao at google dot com> ---
This is a bug when updating block during tree-inline. Basically, it is legal
for *n to be NULL. E.g. When gimple_block(id->gimple_call) is NULL,
remap_blocks_to_null will be called to set *n to NULL.
The problem is that we should check this before calling COMBINE_LOCATION_DATA,
which assumes block is not NULL.
The following patch can fix the problem:
Index: gcc/tree-inline.c
===================================================================
--- gcc/tree-inline.c (revision 203208)
+++ gcc/tree-inline.c (working copy)
@@ -2090,7 +2090,10 @@ copy_phis_for_bb (basic_block bb, copy_body_data *
n = (tree *) pointer_map_contains (id->decl_map,
LOCATION_BLOCK (locus));
gcc_assert (n);
- locus = COMBINE_LOCATION_DATA (line_table, locus, *n);
+ if (*n)
+ locus = COMBINE_LOCATION_DATA (line_table, locus, *n);
+ else
+ locus = LOCATION_LOCUS (locus);
}
else
locus = LOCATION_LOCUS (locus);
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/58619] ICE building in gen_combined_adhoc_loc
2013-10-04 13:01 [Bug tree-optimization/58619] New: ICE building libstdc++-v3 on arm-none-linux-gnueabihf in gen_combined_adhoc_loc ramana at gcc dot gnu.org
` (3 preceding siblings ...)
2013-10-04 18:48 ` dehao at google dot com
@ 2013-10-08 8:34 ` ramana at gcc dot gnu.org
2013-10-08 17:00 ` ramana at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: ramana at gcc dot gnu.org @ 2013-10-08 8:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58619
--- Comment #4 from Ramana Radhakrishnan <ramana at gcc dot gnu.org> ---
Author: ramana
Date: Tue Oct 8 08:34:28 2013
New Revision: 203269
URL: http://gcc.gnu.org/viewcvs?rev=203269&root=gcc&view=rev
Log:
PR tree-optimization/58619
2013-10-08 Dehao Chen <dehao@google.com>
* tree-inline.c (copy_phis_for_bb): Combine location data
only if non-null.
Modified:
trunk/gcc/ChangeLog
trunk/gcc/tree-inline.c
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/58619] ICE building in gen_combined_adhoc_loc
2013-10-04 13:01 [Bug tree-optimization/58619] New: ICE building libstdc++-v3 on arm-none-linux-gnueabihf in gen_combined_adhoc_loc ramana at gcc dot gnu.org
` (4 preceding siblings ...)
2013-10-08 8:34 ` ramana at gcc dot gnu.org
@ 2013-10-08 17:00 ` ramana at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: ramana at gcc dot gnu.org @ 2013-10-08 17:00 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58619
Ramana Radhakrishnan <ramana at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED
--- Comment #6 from Ramana Radhakrishnan <ramana at gcc dot gnu.org> ---
Fixed.
^ permalink raw reply [flat|nested] 7+ messages in thread