diff options
author | Cary Coutant <ccoutant@google.com> | 2008-04-17 02:00:54 +0000 |
---|---|---|
committer | Cary Coutant <ccoutant@google.com> | 2008-04-17 02:00:54 +0000 |
commit | edfbb029539d1e67751ca7dd7c6ff3cbe702a6c2 (patch) | |
tree | 040f027806994825a8d677b455d77362de6ab65e /gold/symtab.cc | |
parent | 700b53b17a52448cb49f04a4e27d5f0130537924 (diff) | |
download | gdb-edfbb029539d1e67751ca7dd7c6ff3cbe702a6c2.zip gdb-edfbb029539d1e67751ca7dd7c6ff3cbe702a6c2.tar.gz gdb-edfbb029539d1e67751ca7dd7c6ff3cbe702a6c2.tar.bz2 |
* i386.cc (Target_i386::define_tls_base_symbol): New function.
(Target_i386::tls_base_symbol_defined_): New field.
(Target_i386::Scan::local): Define _TLS_MODULE_BASE_ symbol.
(Target_i386::Scan::global): Likewise.
* symtab.cc (sized_finalize_symbol): Add check for TLS symbol.
* x86_64.cc (Target_x86_64::define_tls_base_symbol): New function.
(Target_x86_64::tls_base_symbol_defined_): New field.
(Target_x86_64::Scan::local): Define _TLS_MODULE_BASE_ symbol.
(Target_x86_64::Scan::global): Likewise.
Diffstat (limited to 'gold/symtab.cc')
-rw-r--r-- | gold/symtab.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gold/symtab.cc b/gold/symtab.cc index ee826b3..9b23790 100644 --- a/gold/symtab.cc +++ b/gold/symtab.cc @@ -1839,7 +1839,9 @@ Symbol_table::sized_finalize_symbol(Symbol* unsized_sym) case Symbol::IN_OUTPUT_SEGMENT: { Output_segment* os = sym->output_segment(); - value = sym->value() + os->vaddr(); + value = sym->value(); + if (sym->type() != elfcpp::STT_TLS) + value += os->vaddr(); switch (sym->offset_base()) { case Symbol::SEGMENT_START: |