ipa.c (walk_polymorphic_call_targets): Fix updating of overall summary.
authorJan Hubicka <hubicka@ucw.cz>
Wed, 1 Jan 2020 10:47:21 +0000 (11:47 +0100)
committerJan Hubicka <hubicka@gcc.gnu.org>
Wed, 1 Jan 2020 10:47:21 +0000 (10:47 +0000)
* ipa.c (walk_polymorphic_call_targets): Fix updating of overall
summary.

From-SVN: r279810

gcc/ChangeLog
gcc/ipa.c

index 70caa829f79d0cb38632133c3a5b293f6bc68df2..76211fc34d86b15d5eeebc69a3a7018ea6654c7a 100644 (file)
@@ -1,3 +1,8 @@
+2020-01-01  Jan Hubicka  <hubicka@ucw.cz>
+
+       * ipa.c (walk_polymorphic_call_targets): Fix updating of overall
+       summary.
+
 2020-01-01  Jakub Jelinek  <jakub@redhat.com>
 
        PR tree-optimization/93098
index 2404024d722e29d58725f590668694faf7fb3fab..7eabecf6c950a94a55fb1fee7b22bf8e13743175 100644 (file)
--- a/gcc/ipa.c
+++ b/gcc/ipa.c
@@ -244,7 +244,8 @@ walk_polymorphic_call_targets (hash_set<void *> *reachable_call_targets,
            }
          edge = edge->make_direct (target);
          if (ipa_fn_summaries)
-           ipa_update_overall_fn_summary (node);
+           ipa_update_overall_fn_summary (node->inlined_to
+                                          ? node->inlined_to : node);
          else if (edge->call_stmt)
            edge->redirect_call_stmt_to_callee ();
        }