aboutsummaryrefslogtreecommitdiff
path: root/gold/object.cc
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2021-08-28 14:23:33 +0930
committerAlan Modra <amodra@gmail.com>2021-09-18 08:20:11 +0930
commit973b2b402ebf660e2bbbac60e85469164d76ecfc (patch)
tree5c483374372e3cde206bc403bf3095e379567e6c /gold/object.cc
parent912697efc15768894c13a9370a2fcaa950f24558 (diff)
downloadgdb-973b2b402ebf660e2bbbac60e85469164d76ecfc.zip
gdb-973b2b402ebf660e2bbbac60e85469164d76ecfc.tar.gz
gdb-973b2b402ebf660e2bbbac60e85469164d76ecfc.tar.bz2
[GOLD] Remove addend from Local_got_entry_key
This patch removes the addend from Local_got_entry_key, which is unnecessary now that Got_offset_list has an addend. Note that it might be advantageous to keep the addend in Local_got_entry_key when linking objects containing a large number of section_sym+addend@got relocations. I opted to save some memory by removing the field but left the class there in case we might need to restore {sym,addend} lookup. That's also why this change is split out from the Got_offset_list change. PR 28192 * object.h (Local_got_entry_key): Delete addend_ field. Adjust constructor and methods to suit. * object.cc (Sized_relobj::do_for_all_local_got_entries): Update key.
Diffstat (limited to 'gold/object.cc')
-rw-r--r--gold/object.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/gold/object.cc b/gold/object.cc
index 45cf30d..b7a2a6c 100644
--- a/gold/object.cc
+++ b/gold/object.cc
@@ -427,7 +427,7 @@ Sized_relobj<size, big_endian>::do_for_all_local_got_entries(
unsigned int nsyms = this->local_symbol_count();
for (unsigned int i = 0; i < nsyms; i++)
{
- Local_got_entry_key key(i, 0);
+ Local_got_entry_key key(i);
Local_got_offsets::const_iterator p = this->local_got_offsets_.find(key);
if (p != this->local_got_offsets_.end())
{