diff mbox

Don't call get_working_sets w/ LTO and -fauto-profile (PR, gcov-profile/70993)

Message ID 25957758-90b3-b980-29e0-f2acce105544@suse.cz
State New
Headers show

Commit Message

Martin Liška July 25, 2016, 11:05 a.m. UTC
Hi.

Currently, call to get_working_sets is only called from tree_profiling
(called from 'pass_ipa_tree_profile' and is guarded in gate with !flag_auto_profile).
I would like to apply the same logic in lto-cgraph.c.

Patch can bootstrap on ppc64le-redhat-linux and survives regression tests.

Ready to be installed?
Martin

Comments

Richard Biener July 25, 2016, 11:19 a.m. UTC | #1
On Mon, Jul 25, 2016 at 1:05 PM, Martin Liška <mliska@suse.cz> wrote:
> Hi.
>
> Currently, call to get_working_sets is only called from tree_profiling
> (called from 'pass_ipa_tree_profile' and is guarded in gate with !flag_auto_profile).
> I would like to apply the same logic in lto-cgraph.c.
>
> Patch can bootstrap on ppc64le-redhat-linux and survives regression tests.
>
> Ready to be installed?

Ok.

Richard.

> Martin
diff mbox

Patch

From dcf13fb3ac8a4c9e85842f147665b527ce71234b Mon Sep 17 00:00:00 2001
From: marxin <mliska@suse.cz>
Date: Fri, 22 Jul 2016 13:07:40 +0200
Subject: [PATCH] Don't call get_working_sets w/ LTO and -fauto-profile (PR
 gcov-profile/70993)

gcc/ChangeLog:

2016-07-22  Martin Liska  <mliska@suse.cz>

	* lto-cgraph.c (input_symtab): Don't call get_working_sets
	if flag_auto_profile is set to true.
---
 gcc/lto-cgraph.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gcc/lto-cgraph.c b/gcc/lto-cgraph.c
index 5cef2ba..2642041 100644
--- a/gcc/lto-cgraph.c
+++ b/gcc/lto-cgraph.c
@@ -1867,7 +1867,9 @@  input_symtab (void)
     }
 
   merge_profile_summaries (file_data_vec);
-  get_working_sets ();
+
+  if (!flag_auto_profile)
+    get_working_sets ();
 
 
   /* Clear out the aux field that was used to store enough state to
-- 
2.9.0