aboutsummaryrefslogtreecommitdiff
path: root/gcc/lto-streamer-out.c
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2020-05-22 16:37:06 +0200
committerJan Hubicka <jh@suse.cz>2020-05-22 16:37:06 +0200
commitbcb63eb2cbd3caf212b9cf42d8c218c09dc6ff8b (patch)
treea533824ecaf664934915b8534378801b2da04ba2 /gcc/lto-streamer-out.c
parent098ba49c7cd4d3f6202b6472aec8c33b68bbada7 (diff)
downloadgcc-bcb63eb2cbd3caf212b9cf42d8c218c09dc6ff8b.zip
gcc-bcb63eb2cbd3caf212b9cf42d8c218c09dc6ff8b.tar.gz
gcc-bcb63eb2cbd3caf212b9cf42d8c218c09dc6ff8b.tar.bz2
Avoid streaming stray references.
this patch avoids stremaing completely useless stray references to gobal decl stream. I am re-testing the patch (rebased to current tree) on x86_64-linux and intend to commit once testing finishes. gcc/ChangeLog: 2020-05-22 Jan Hubicka <hubicka@ucw.cz> * lto-streamer-out.c (lto_output_tree): Do not stream final ref if it is not needed. gcc/lto/ChangeLog: 2020-05-22 Jan Hubicka <hubicka@ucw.cz> * lto-common.c (lto_read_decls): Do not skip stray refs.
Diffstat (limited to 'gcc/lto-streamer-out.c')
-rw-r--r--gcc/lto-streamer-out.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/lto-streamer-out.c b/gcc/lto-streamer-out.c
index f5daadc..5ff7f33 100644
--- a/gcc/lto-streamer-out.c
+++ b/gcc/lto-streamer-out.c
@@ -1780,7 +1780,7 @@ lto_output_tree (struct output_block *ob, tree expr,
it. */
if (!existed_p)
lto_output_tree_1 (ob, expr, 0, ref_p, this_ref_p);
- else
+ else if (this_ref_p)
{
if (streamer_dump_file)
{