https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64218

--- Comment #14 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
Good, now it reproduces.  The problem is that inliner removes the alias target
and it leaves the alias itself to be removed by remove_unreachable_nodes.  It
however manages to crash ealrier looking if the alias shall be inlined as
called once in somewhat convoluted test whether symbol is an alias.

Index: ipa-inline.c
===================================================================
--- ipa-inline.c        (revision 219826)
+++ ipa-inline.c        (working copy)
@@ -866,7 +866,8 @@ want_inline_function_to_all_callers_p (s
 {
   bool has_hot_call = false;

-  if (node->ultimate_alias_target () != node)
+  /* Aliases gets inlined along with the function they alias.  */
+  if (node->alias)
     return false;
   /* Already inlined?  */
   if (node->global.inlined_to)

Reply via email to