public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/marxin/heads/fix-modref-dump-dependency)] IPA: fix reproducibility in IPA MOD REF
@ 2021-11-18 16:50 Martin Liska
0 siblings, 0 replies; only message in thread
From: Martin Liska @ 2021-11-18 16:50 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:0f5efe41f2f7917b4091d19b55ffb80675d769e7
commit 0f5efe41f2f7917b4091d19b55ffb80675d769e7
Author: Martin Liska <mliska@suse.cz>
Date: Thu Nov 18 17:50:19 2021 +0100
IPA: fix reproducibility in IPA MOD REF
gcc/ChangeLog:
* ipa-modref.c (analyze_function): Do not execute the code
only if dump_file != NULL.
Diff:
---
gcc/ipa-modref.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/gcc/ipa-modref.c b/gcc/ipa-modref.c
index a3c7c6d6a1f..6cacf9c8ab1 100644
--- a/gcc/ipa-modref.c
+++ b/gcc/ipa-modref.c
@@ -2868,15 +2868,15 @@ analyze_function (function *f, bool ipa)
optimization_summaries = modref_summaries::create_ggc (symtab);
else /* Remove existing summary if we are re-running the pass. */
{
- if (dump_file
- && (summary
- = optimization_summaries->get (fnode))
- != NULL
+ summary = optimization_summaries->get (fnode);
+ if (summary != NULL
&& summary->loads)
{
- fprintf (dump_file, "Past summary:\n");
- optimization_summaries->get
- (fnode)->dump (dump_file);
+ if (dump_file)
+ {
+ fprintf (dump_file, "Past summary:\n");
+ optimization_summaries->get (fnode)->dump (dump_file);
+ }
past_flags.reserve_exact (summary->arg_flags.length ());
past_flags.splice (summary->arg_flags);
past_retslot_flags = summary->retslot_flags;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-11-18 16:50 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-18 16:50 [gcc(refs/users/marxin/heads/fix-modref-dump-dependency)] IPA: fix reproducibility in IPA MOD REF Martin Liska
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).