From bd73a62d774b7c9a77be60ccfc4ff0dd7641970f Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Mon, 10 Sep 2012 23:05:54 +0000 Subject: * output.h (Output_data_got::add_global_tls, add_local_tls, add_local_tls_pair): New functions. (Output_data_got::add_local_pair_with_rel): Remove second reloc param. Expand comment. (Output_data_got::Got_entry): Rename use_plt_offset_ to use_plt_or_tls_offset_, similarly for constructor param. (Output_data_got::Got_entry::write): Add got_index param. * output.cc (Output_data_got::add_global_tls, add_local_tls, add_local_tls_pair): New functions. (Output_data_got::Got_entry::write): Handle tls symbols with use_plt_or_tls_offset_ set specially. (Output_data_got::add_local_pair_with_rel): Only one reloc. (Output_data_got::do_write): Replace iterator with index, pass index to entry write function. * target.h (Target::tls_offset_for_local, tls_offset_for_global, do_tls_offset_for_local, do_tls_offset_for_global): New functions. * arm.cc (Target_arm::Scan::local): Update add_local_pair_with_rel call. * i386.cc (Target_i386::Scan::local): Likewise. * sparc.cc (Target_sparc::Scan::local): Likewise. * x86_64.cc (Target_x86_64::Scan::local): Likewise. * powerpc.cc (Target_powerpc::do_tls_offset_for_local, do_tls_offset_for_global): New functions. (Target_powerpc::Scan::local): Correct TLS relocations and got entry values. (Target_powerpc::Scan::global): Don't emit unnecessary dynamic relocations on TLS GOT entries. --- gold/x86_64.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gold/x86_64.cc') diff --git a/gold/x86_64.cc b/gold/x86_64.cc index a15b6ae..1712beb 100644 --- a/gold/x86_64.cc +++ b/gold/x86_64.cc @@ -2477,7 +2477,7 @@ Target_x86_64::Scan::local(Symbol_table* symtab, shndx, GOT_TYPE_TLS_PAIR, target->rela_dyn_section(layout), - elfcpp::R_X86_64_DTPMOD64, 0); + elfcpp::R_X86_64_DTPMOD64); } else if (optimized_type != tls::TLSOPT_TO_LE) unsupported_reloc_local(object, r_type); -- cgit v1.1