From b9fb922ad7439b38119aaca7a38b839d62fcaf23 Mon Sep 17 00:00:00 2001 From: Martin Liska Date: Tue, 13 Aug 2019 09:31:25 +0200 Subject: [PATCH] Simplify dump_printf in value-prof.c 2019-08-13 Martin Liska * value-prof.c (gimple_ic_transform): Add new line. Print details with MSG_NOTE. 2019-08-13 Martin Liska * gcc.dg/tree-prof/ic-misattribution-1.c: Use -fdump-ipa-profile-node. From-SVN: r274330 --- gcc/ChangeLog | 5 +++++ gcc/testsuite/ChangeLog | 4 ++++ gcc/testsuite/gcc.dg/tree-prof/ic-misattribution-1.c | 2 +- gcc/value-prof.c | 9 ++++----- 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 684c30e56cd..cc06158cf4e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2019-08-13 Martin Liska + + * value-prof.c (gimple_ic_transform): Add new line. + Print details with MSG_NOTE. + 2019-08-13 Martin Liska * doc/invoke.texi: Document automatic detection of jobserver. diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 18dac06e77e..839772170de 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2019-08-13 Martin Liska + + * gcc.dg/tree-prof/ic-misattribution-1.c: Use -fdump-ipa-profile-node. + 2019-08-12 Thomas Koenig PR fortran/91424 diff --git a/gcc/testsuite/gcc.dg/tree-prof/ic-misattribution-1.c b/gcc/testsuite/gcc.dg/tree-prof/ic-misattribution-1.c index 126236eba8e..0c69045591b 100644 --- a/gcc/testsuite/gcc.dg/tree-prof/ic-misattribution-1.c +++ b/gcc/testsuite/gcc.dg/tree-prof/ic-misattribution-1.c @@ -1,4 +1,4 @@ -/* { dg-options "-O2 -fdump-ipa-profile-optimized" } */ +/* { dg-options "-O2 -fdump-ipa-profile-note" } */ /* { dg-additional-sources "ic-misattribution-1a.c" } */ extern void other_caller (void); diff --git a/gcc/value-prof.c b/gcc/value-prof.c index 9d9785b179d..00ede8d985f 100644 --- a/gcc/value-prof.c +++ b/gcc/value-prof.c @@ -1450,7 +1450,7 @@ gimple_ic_transform (gimple_stmt_iterator *gsi) if (dump_enabled_p ()) dump_printf_loc (MSG_MISSED_OPTIMIZATION, stmt, "Indirect call -> direct call from other " - "module %T=> %i (will resolve only with LTO)", + "module %T=> %i (will resolve only with LTO)\n", gimple_call_fn (stmt), (int)val); } return false; @@ -1471,10 +1471,9 @@ gimple_ic_transform (gimple_stmt_iterator *gsi) { dump_printf_loc (MSG_OPTIMIZED_LOCATIONS, stmt, "Indirect call -> direct call " - "%T => %T transformation on insn postponed " - "to ipa-profile: %G", gimple_call_fn (stmt), - direct_call->decl, stmt); - dump_printf_loc (MSG_OPTIMIZED_LOCATIONS, stmt, + "%T => %T transformation on insn postponed\n", + gimple_call_fn (stmt), direct_call->decl); + dump_printf_loc (MSG_NOTE, stmt, "hist->count %" PRId64 " hist->all %" PRId64"\n", count, all); } -- 2.30.2