This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
[binutils-gdb/binutils-2_28-branch] 2018-01-12 Eric Christopher <echristo at gmail dot com>
- From: Eric Christopher <echristo at sourceware dot org>
- To: bfd-cvs at sourceware dot org
- Date: 12 Jan 2018 19:15:35 -0000
- Subject: [binutils-gdb/binutils-2_28-branch] 2018-01-12 Eric Christopher <echristo at gmail dot com>
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=1e4d2a179d04d08bf113706939dd502c46301261
commit 1e4d2a179d04d08bf113706939dd502c46301261
Author: Eric Christopher <echristo@gmail.com>
Date: Fri Jan 12 11:12:55 2018 -0800
2018-01-12 Eric Christopher <echristo@gmail.com>
Apply from master:
2018-01-12 Sterling Augustine <saugustine@google.com>
* cref.cc (Cref_inputs::Cref_table_compare::operator): Add
conditionals and calls to is_forwarder.
Diff:
---
gold/ChangeLog | 8 ++++++++
gold/cref.cc | 6 +++++-
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/gold/ChangeLog b/gold/ChangeLog
index 208dc1f..e2eebd1 100644
--- a/gold/ChangeLog
+++ b/gold/ChangeLog
@@ -1,3 +1,11 @@
+2018-01-12 Eric Christopher <echristo@gmail.com>
+
+ Apply from master:
+ 2018-01-12 Sterling Augustine <saugustine@google.com>
+
+ * cref.cc (Cref_inputs::Cref_table_compare::operator): Add
+ conditionals and calls to is_forwarder.
+
2017-11-21 Ian Lance Taylor <iant@google.com>
Apply from master:
diff --git a/gold/cref.cc b/gold/cref.cc
index d3337b9..ff9e217 100644
--- a/gold/cref.cc
+++ b/gold/cref.cc
@@ -236,9 +236,13 @@ Cref_inputs::Cref_table_compare::operator()(const Symbol* s1,
}
// We should never have two different symbols with the same name and
- // version.
+ // version, where one doesn't forward to the other.
if (s1 == s2)
return false;
+ if (s1->is_forwarder() && !s2->is_forwarder())
+ return true;
+ if (!s1->is_forwarder() && s2->is_forwarder())
+ return false;
gold_unreachable();
}