libitm.exp: Reorder lib loads into dependency order.
[gcc.git] / gcc / ipa-inline-transform.c
index 0fb8940b82b5cd3128dc17e5cd0e66418857fd44..9e131a4aa0e78c9ea428004196fbc4763c0ed711 100644 (file)
@@ -92,9 +92,7 @@ can_remove_node_now_p_1 (struct cgraph_node *node)
             those only after all devirtualizable virtual calls are processed.
             Lacking may edges in callgraph we just preserve them post
             inlining.  */
-         && (!DECL_VIRTUAL_P (node->symbol.decl)
-             || (!DECL_COMDAT (node->symbol.decl)
-                 && !DECL_EXTERNAL (node->symbol.decl)))
+         && !DECL_VIRTUAL_P (node->symbol.decl)
          /* During early inlining some unanalyzed cgraph nodes might be in the
             callgraph and they might reffer the function in question.  */
          && !cgraph_new_nodes);
@@ -155,7 +153,7 @@ clone_inlined_nodes (struct cgraph_edge *e, bool duplicate,
             cgraph_remove_unreachable_functions gets rid of them.  */
          gcc_assert (!e->callee->global.inlined_to);
           symtab_dissolve_same_comdat_group_list ((symtab_node) e->callee);
-         if (e->callee->analyzed && !DECL_EXTERNAL (e->callee->symbol.decl))
+         if (e->callee->symbol.definition && !DECL_EXTERNAL (e->callee->symbol.decl))
            {
              if (overall_size)
                *overall_size -= inline_summary (e->callee)->size;
@@ -238,7 +236,7 @@ inline_call (struct cgraph_edge *e, bool update_original,
          if (!alias->callers
              && can_remove_node_now_p (alias, e))
            {
-             next_alias = cgraph_alias_aliased_node (alias);
+             next_alias = cgraph_alias_target (alias);
              cgraph_remove_node (alias);
              alias = next_alias;
            }
@@ -262,7 +260,7 @@ inline_call (struct cgraph_edge *e, bool update_original,
 #ifdef ENABLE_CHECKING
   /* Verify that estimated growth match real growth.  Allow off-by-one
      error due to INLINE_SIZE_SCALE roudoff errors.  */
-  gcc_assert (!update_overall_summary || !overall_size
+  gcc_assert (!update_overall_summary || !overall_size || new_edges_found
              || abs (estimated_growth - (new_size - old_size)) <= 1
              /* FIXME: a hack.  Edges with false predicate are accounted
                 wrong, we should remove them from callgraph.  */
@@ -383,7 +381,7 @@ static bool
 preserve_function_body_p (struct cgraph_node *node)
 {
   gcc_assert (cgraph_global_info_ready);
-  gcc_assert (!node->alias && !node->thunk.thunk_p);
+  gcc_assert (!node->symbol.alias && !node->thunk.thunk_p);
 
   /* Look if there is any clone around.  */
   if (node->clones)