aboutsummaryrefslogtreecommitdiff
path: root/gcc/lto/lto.c
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2015-08-31 11:48:11 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2015-08-31 11:48:11 +0000
commit45aee888b558bbf042ab53c88005148e44d0e1b1 (patch)
treecfb9a962ef757505f7618678eb1167a6ab46af2c /gcc/lto/lto.c
parent6c1bc27c5f1052e363e69fcabee45ef44d4bdde5 (diff)
downloadgcc-45aee888b558bbf042ab53c88005148e44d0e1b1.zip
gcc-45aee888b558bbf042ab53c88005148e44d0e1b1.tar.gz
gcc-45aee888b558bbf042ab53c88005148e44d0e1b1.tar.bz2
lto-symtab.c (lto_symtab_prevailing_decl): Remove redundant test, do not replace a non-builtin with a builtin.
2015-08-31 Richard Biener <rguenther@suse.de> lto/ * lto-symtab.c (lto_symtab_prevailing_decl): Remove redundant test, do not replace a non-builtin with a builtin. * lto.c (compare_tree_sccs_1): Do not merge things we stream as builtins vs. non-builtins. From-SVN: r227339
Diffstat (limited to 'gcc/lto/lto.c')
-rw-r--r--gcc/lto/lto.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/lto/lto.c b/gcc/lto/lto.c
index 7ec4c08..b4287a3 100644
--- a/gcc/lto/lto.c
+++ b/gcc/lto/lto.c
@@ -1054,8 +1054,10 @@ compare_tree_sccs_1 (tree t1, tree t2, tree **map)
return false;
- /* We don't want to compare locations, so there is nothing do compare
- for TS_DECL_MINIMAL. */
+ /* We want to compare locations up to the point where it makes
+ a difference for streaming - thus whether the decl is builtin or not. */
+ if (CODE_CONTAINS_STRUCT (code, TS_DECL_MINIMAL))
+ compare_values (streamer_handle_as_builtin_p);
if (CODE_CONTAINS_STRUCT (code, TS_DECL_COMMON))
{