summaryrefslogtreecommitdiff
path: root/gold/object.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2012-09-25 00:59:25 +0000
committerAlan Modra <amodra@gmail.com>2012-09-25 00:59:25 +0000
commitec4dbad32d15acd95084aea6145486dac5a19948 (patch)
treed100fe6ede32917d61224bd18e241485f913cae2 /gold/object.h
parenta1e5fd6938feffd9c7f2d9732b59413d210602a6 (diff)
downloadbinutils-gdb-ec4dbad32d15acd95084aea6145486dac5a19948.tar.gz
* object.h (Sized_relobj_file::adjust_local_symbol,
do_adjust_local_symbol): New functions. * object.cc (Sized_relobj_file::do_count_local_symbols): Use the above. * powerpc.cc (Powerpc_relobj::do_adjust_local_symbol): New function. (Powerpc_relobj::scan_opd_relocs): Warn on unexpected opd relocs and irregular opd entry spacing. (Powerpc_relobj::do_read_relocs): Add opd size checks. (Global_symbol_visitor_opd): New functor. (Target_powerpc::do_finalize_sections): Omit global symbols defined on deleted opd entries.
Diffstat (limited to 'gold/object.h')
-rw-r--r--gold/object.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/gold/object.h b/gold/object.h
index a507204d2b7..522b63f44b6 100644
--- a/gold/object.h
+++ b/gold/object.h
@@ -2112,6 +2112,12 @@ class Sized_relobj_file : public Sized_relobj<size, big_endian>
void
set_local_plt_offset(unsigned int symndx, unsigned int plt_offset);
+ // Adjust this local symbol value. Return false if the symbol
+ // should be discarded from the output file.
+ bool
+ adjust_local_symbol(Symbol_value<size>* lv) const
+ { return this->do_adjust_local_symbol(lv); }
+
// Return the name of the symbol that spans the given offset in the
// specified section in this object. This is used only for error
// messages and is not particularly efficient.
@@ -2381,6 +2387,12 @@ class Sized_relobj_file : public Sized_relobj<size, big_endian>
const unsigned char* pshdrs, Output_file* of,
Views* pviews);
+ // Adjust this local symbol value. Return false if the symbol
+ // should be discarded from the output file.
+ virtual bool
+ do_adjust_local_symbol(Symbol_value<size>*) const
+ { return true; }
+
// Allow a child to set output local symbol count.
void
set_output_local_symbol_count(unsigned int value)