+2014-12-04 Alan Modra <amodra@gmail.com>
+
+ * Powerpc.cc (Target_powerpc::Branch_info::make_stub): Ignore
+ addend of PLTREL24 reloc when not generating a plt stub. Make
+ max_branch_offset an "Address".
+ (Target_powerpc::Relocate::relocate): Make max_branch_offset
+ an "Address".
+
+2014-12-04 Alan Modra <amodra@gmail.com>
+
+ PR 17670
+ * symtab.cc (Symbol::set_undefined): Remove assertion.
+ * powerpc.cc (Target_powerpc::symval_for_branch): Don't assert
+ on symbols defined in discarded sections, instead return false.
+ Rearrange params, update all callers.
+ (Target_powerpc::Branch_info::make_stub): Don't make stubs for
+ branches to syms in discarded sections.
+ (Global_symbol_visitor_opd::operator()): Set discarded opd syms
+ undefined and flag as discarded.
+ (Target_powerpc::Relocate::relocate): Localize variable.
+
+2014-12-03 Alan Modra <amodra@gmail.com>
+
+ PR 17566
+ * powerpc.cc (Target_powerpc::Scan::local): Use add_local_section
+ when adding dynamic relocations against section symbols.
+
+2014-11-26 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Stub_control::set_output_and_owner): New function.
+ (Target_powerpc::group_sections): Use it.
+
+2014-11-25 Cary Coutant <ccoutant@google.com>
+
+ PR gold/17639
+ * object.cc (Sized_relobj_file): Initialize is_deferred_layout_.
+ (Sized_relobj_file::do_layout): Handle deferred sections properly
+ during GC pass 1. Don't add reloc sections to deferred list twice.
+ * object.h (Sized_relobj_file::is_deferred_layout): New function.
+ (Sized_relobj_file::is_deferred_layout_): New data member.
+
+2014-11-21 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::Relocate::relocate): Correct test
+ for undefined weaks.
+
+2014-11-20 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Stub_control::Stub_control): Init stub14_group_size_
+ from --stub-group-size parameter divided by 1024.
+ (Powerpc_relocate_functions::rela, rela_ua): Add fieldsize
+ template parameter. Update all uses.
+ (Target_powerpc::Relocate::relocate): Rename has_plt_value to
+ has_stub_value. Set for long branches. Don't report overflow for
+ branch to undefined weak symbols. Print info message on
+ overflowing branch to stub.
+
+2014-11-20 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::do_relax): Add __go_go to thread_starters.
+
+2014-10-28 Alan Modra <amodra@gmail.com>
+
+ Apply trunk patches
+ 2014-10-22 Alan Modra <amodra@gmail.com>
+ * powerpc.cc (do_relax): Add gcc-4.9 libgomp functions to
+ thread_starter.
+
+2014-09-30 Cary Coutant <ccoutant@google.com>
+
+ PR gold/17432
+ * resolve.cc (Symbol_table::resolve): Fix local shadowing error.
+
+2014-09-30 Kito Cheng <kito@0xlab.org>
+
+ PR gold/13597
+ * layout.cc (Layout::create_dynamic_symtab): Build gnu-style
+ hash table before sysv-style hash table.
+
+2014-09-29 Sriraman Tallam <tmsriram@google.com>
+
+ * options.h (--pic-executable): Add negative to alias to -no-pie.
+
+2014-09-26 Cary Coutant <ccoutant@google.com>
+
+ PR gold/16773
+ * object.cc (Sized_relobj_file): Compute value of section symbols
+ for TLS sections the same as TLS symbols.
+
+2014-09-25 Cary Coutant <ccoutant@google.com>
+
+ PR gold/17432
+ * resolve.cc (Symbol_table::resolve): Override common placeholder
+ symbols, but adjust sizes.
+ * symtab.cc (Symbol_table::add_from_object): Don't add placeholder
+ symbols to common lists.
+
+2014-09-24 Alan Modra <amodra@gmail.com>
+
+ * po/POTFILES.in: Regenerate.
+
+2014-09-23 Taiju Tsuiki <tzik@google.com>
+ Cary Coutant <ccoutant@google.com>
+
+ PR gold/14860
+ * gold.cc (queue_final_tasks): Add Write_sections_task as a blocker
+ on input_sections_blocker.
+ * layout.cc (Write_sections_task::locks): Unblock
+ input_sections_blocker_.
+ * layout.h (Write_sections_task::Write_sections_task): Add
+ input_sections_blocker.
+ * testsuite/Makefile.am (exception_x86_64_bnd_test): Add gcctestdir/ld
+ to DEPENDENCIES.
+ * testsuite/Makefile.in: Regenerate.
+
+2014-09-18 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
+
+ * testsuite/Makefile.am (plugin_test_10): New test.
+ * testsuite/Makefile.in: Regenerate
+ * testsuite/plugin_common_test_2.c (c1): Align to 8.
+ * testsuite/plugin_test_10.sh: New file.
+
+2014-09-17 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
+
+ * plugin.cc (Sized_pluginobj::do_add_symbols): Ignore isym->size.
+ * resolve.cc (Symbol_table::resolve): Don't override common symbols
+ during the replacement phase.
+
+2014-09-17 Han Shen <shenhan@google.com>
+ Jing Yu <jingyu@google.com>
+
+ * aarch64-reloc.def: Add TLSGD_ADR_PAGE21, TLSGD_ADD_LO12_NC,
+ TLSDESC_ADR_PAGE21, TLSDESC_LD64_LO12, TLSDESC_ADD_LO12, TLSDESC_CALL.
+ * aarch64.cc (Target_aarch64): Add data members
+ got_irelative_, got_tlsdesc_, rela_irelative_, got_mod_index_offset_,
+ tlsdesc_reloc_info_, tls_base_symbol_defined_. Initialize them in
+ constructor.
+ (Target_aarch64::do_reloc_symbol_index): New method.
+ (Target_aarch64::do_reloc_addend): New method.
+ (Target_aarch64::add_tlsdesc_info): New method.
+ (Target_aarch64::do_dynsym_value): New method.
+ (Target_aarch64::do_make_data_plt): Add new parameters: got,
+ got_irelative. Pass them to Output_data_plt_aarch64_standard.
+ (Target_aarch64::make_data_plt): Add new parameters: got,
+ got_irelative. Pass them to do_make_data_plt.
+ (Target_aarch64::Relocate): Add skip_call_tls_get_addr_ variable.
+ (Target_aarch64::Relocate:tls_gd_to_le): New method.
+ (Target_aarch64::Relocate:tls_ie_to_le): New method.
+ (Target_aarch64::Relocate:tls_desc_gd_to_le): New method.
+ (Target_aarch64::Relocate:tls_desc_gd_to_ie): New method.
+ (Target_aarch64::got_tlsdesc_section): New method.
+ (Target_aarch64::make_local_ifunc_plt_entry): New method.
+ (Target_aarch64::define_tls_base_symbol): New method.
+ (Target_aarch64::reserve_tlsdesc_entries): New method.
+ (Target_aarch64::got_mod_index_entry): New method.
+ (Target_aarch64::rela_tlsdesc_section): New method.
+ (Target_aarch64::rela_irelative_section): New method.
+ (Target_aarch64::Tlsdesc_info): New struct.
+ (Target_aarch64::got_section): Create .got.plt space for IRELATIVE
+ relocations and tlsdesc relocations.
+ (Target_aarch64::optimize_tls_reloc): Implement method.
+ (Output_data_plt_aarch64): Add member variables: tlsdesc_rel_, got_,
+ got_irelative_, irelative_count_, tlsdesc_got_offset_. Initialize them
+ in constructor.
+ (Output_data_plt_aarch64::reserve_tlsdesc_entry): New method.
+ (Output_data_plt_aarch64::has_tlsdesc_entry): New method.
+ (Output_data_plt_aarch64::get_tlsdesc_got_offset): New method.
+ (Output_data_plt_aarch64::get_tlsdesc_plt_offset): New method.
+ (Output_data_plt_aarch64::rela_tlsdesc): New method.
+ (Output_data_plt_aarch64::rela_irelative): New method.
+ (Output_data_plt_aarch64::entry_count): Count IRELATIVE relocations.
+ (Output_data_plt_aarch64::first_plt_entry_offset): Add const attribute.
+ (Output_data_plt_aarch64::get_plt_tlsdesc_entry_size): New method.
+ (Output_data_plt_aarch64::fill_tlsdesc_entry): New method.
+ (Output_data_plt_aarch64::do_get_plt_tlsdesc_entry_size): New method.
+ (Output_data_plt_aarch64::do_fill_tlsdesc_entry): New method.
+ (Output_data_plt_aarch64_standard): New member variables:
+ plt_tlsdesc_entry_size, tlsdesc_plt_entry.
+ (Output_data_plt_aarch64_standard::Output_data_plt_aarch64_standard):
+ New parameter: got, got_irelative.
+ (Output_data_plt_aarch64_standard::do_get_plt_entry_size): New method.
+ (Output_data_plt_aarch64_standard::do_fill_tlsdesc_entry): New method.
+ (Output_data_plt_aarch64::do_write): Replace got_address with
+ gotplt_address. Add irelative_count_ to count. Write tlsdesc entry.
+ (AArch64_relocate_functions::update_movnz): New method.
+ (AArch64_relocate_functions): Correct format.
+ (AArch64_relocate_functions::movnz): New method.
+ (Target_aarch64::Scan::local): Correct format. Move r_sym, got to
+ before the switch. Add new cases to switch.
+ Check ie_to_le relaxation on tlsie relocations. Add code handling
+ tlsgd tlsdesc cases.
+ (Target_aarch64::Scan::global): Move arp to front. Do copy_reloc when
+ needed. Add new cases to switch. Insert dynamic RELATIVE relocation
+ when needed. Add code handling tlsgd, tlsie, tlsdesc cases.
+ Call reloc_name_in_error_message to print unsupported reloc.
+ (Target_aarch64::make_plt_section): Pass got_ and got_irelative_ to
+ make_data_plt.
+ (Target_aarch64::do_finalize_sections): Emit relocs to save COPY
+ relocs. Fill in some more dynamic tags.
+ (Target_aarch64::Relocate::relocate): Handle tlsgd, tlsdesc relocs.
+ Skip call tls_get_addr when tlsgd is relaxed.
+ (Target_aarch64::Relocate::relocate_tls): Correct format. Add code
+ handling tlsgd, tlsdesc relocs, and tls gd->le, ie->le, tlsdesc->le,
+ tlsdesc->ie relaxation.
+
+2014-09-03 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * mips.cc (Target_mips_nacl): New class.
+ (Target_selector_mips_nacl): New class.
+ (target_selector_mips32): Rename from target_selector_mips32be and use
+ Target_selector_mips_nacl instead of Target_selector_mips.
+ (target_selector_mips32el): Rename from target_selector_mips32 and use
+ Target_selector_mips_nacl instead of Target_selector_mips.
+ (target_selector_mips64): Rename from target_selector_mips64be and use
+ Target_selector_mips_nacl instead of Target_selector_mips.
+ (target_selector_mips64el): Rename from target_selector_mips64 and use
+ Target_selector_mips_nacl instead of Target_selector_mips.
+ (Target_mips::mips_info): Add const attribute.
+
+2014-09-02 Cary Coutant <ccoutant@google.com>
+
+ * dwp.cc (Sized_relobj_dwo::do_section_name): Add const attribute.
+ * dynobj.h (Sized_dynobj::do_section_name): Likewise.
+ * incremental.cc (Sized_relobj_incr::do_section_name): Likewise.
+ (Sized_incr_dynobj::do_section_name): Likewise.
+ * incremental.h (Sized_relobj_incr::do_section_name): Likewise.
+ (Sized_incr_dynobj::do_section_name): Likewise.
+ * object.h (Object::section_name): Likewise.
+ (Object::do_section_name): Likewise.
+ (Sized_relobj_file::do_section_name): Likewise.
+ * plugin.cc (Sized_pluginobj::do_section_name): Likewise.
+ * plugin.h (Sized_pluginobj::do_section_name): Likewise.
+
+2014-09-02 Cary Coutant <ccoutant@google.com>
+
+ PR gold/17005
+ * ehframe.cc (Fde::write): Add output_offset parameter.
+ (Cie::write): Likewise.
+ (Eh_frame::set_final_data_size): Account for offset within output
+ section.
+ (Eh_frame::do_sized_write): Likewise.
+ * ehframe.h (Fde::write): Add output_offset parameter.
+ (Cie::write): Likewise.
+ * output.cc (Output_section::Input_section_sort_entry): Remove
+ section_has_name_; add output_section_name parameter. Use
+ output section name for non-input sections.
+ (Output_section::Input_section_sort_entry::section_has_name): Remove.
+ (Output_section::Input_section_sort_entry::section_has_name_): Remove.
+ (Output_section::Input_section_sort_compare): Remove logic for
+ sections without names.
+ (Output_section::Input_section_sort_init_fini_compare): Likewise.
+ (Output_section::Input_section_sort_section_prefix_special_ordering_compare):
+ Likewise.
+ (Output_section::Input_section_sort_section_name_compare): Likewise.
+
+2014-08-29 Han Shen <shenhan@google.com>
+ Jing Yu <jingyu@google.com>
+
+ * aarch64-reloc-property.cc
+ (AArch64_reloc_property_table::reloc_name_in_error_message): Fix bug in
+ reference reloc property in the table.
+ * aarch64-reloc.def: Add TLSLE reloc types and fix some errors in
+ 3 other entries.
+ * aarch64.cc: (Output_data_got_aarch64::add_static_reloc):
+ 2 new overloaded methods.
+ (Output_data_got_aarch64::do_write): Add code to write out
+ static relocs.
+ (class Output_data_got_aarch64::Static_reloc): New class to wrap
+ static relocs.
+ (Output_data_got_aarch64::static_relocs): New vector to
+ hold static relocs.
+ (Target_aarch64::TCB_SIZE): New const static memeber.
+ (Target_aarch64::tcb_size): New method.
+ (Target_aarch64::Relocate::relocate): Add code handling new reloc types.
+ (Target_aarch64::Relocate::relocate_tls): New method.
+ (Target_aarch64::Scan::local): Add code handling new reloc types.
+ (Target_aarch64::Scan::global): Add code handling new reloc types.
+
+2014-08-13 Sriraman Tallam <tmsriram@google.com>
+
+ * options.h (-no-pie): Add option.
+
+2014-08-08 Jing Yu <jingyu@google.com>
+ Han Shen <shenhan@google.com>
+
+ * Makefile.am (HFILES): Add aarch64-reloc-property.h.
+ (DEFFILES): add aarch64-reloc.def.
+ (TARGETSOURCES): Add aarch64-reloc-property.cc.
+ (ALL_TARGETOBJS): Add aarch64-reloc-property.$(OBJEXT).
+ * Makefile.in: Regenerate.
+ * aarch64-reloc-property.cc: New file.
+ * aarch64-reloc-property.h: New file.
+ * aarch64-reloc.def: New file.
+ * aarch64.cc: Include aarch64-reloc-property.h. Replace spaces
+ with tab to make the format consistent.
+ (Output_data_got_aarch64::symbol_table_): New method.
+ (Target_aarch64::do_plt_address_for_global): New method.
+ (Target_aarch64::do_plt_address_for_local): New method.
+ (Target_aarch64::do_select_as_default_target): New method.
+ (Target_aarch64::do_make_data_plt): New method.
+ (Target_aarch64::make_data_plt): New method.
+ (Output_data_plt_aarch64::has_irelative_section): New method.
+ (Output_data_plt_aarch64::address_for_global): New method.
+ (Output_data_plt_aarch64::address_for_local): New method.
+ (Output_data_plt_aarch64::irelative_rel_): New parameter.
+ (Output_data_plt_aarch64::add_entry): Implement contents.
+ (Output_data_plt_aarch64::set_final_data_size): Fix typo.
+ (Output_data_plt_aarch64::do_write): Remove useless got_base. Set
+ the got_pov entry to plt0.
+ (Output_data_plt_aarch64_standard::do_fill_first_plt_entry):
+ Implement contents.
+ (Output_data_plt_aarch64_standard::do_fill_plt_entry): Implement.
+ (AArch64_howto): New struct.
+ (aarch64_howto[]): New static const array.
+ (AArch64_relocate_functions): New class.
+ (Target_aarch64::Scan::get_reference_flags): Remove method.
+ (Target_aarch64::Scan::local): Implement to support a few relocations.
+ (Target_aarch64::Scan::global): Implement to support a few relocations.
+ (Target_aarch64::make_plt_section): Implement contents.
+ (Target_aarch64::make_plt_entry): Implement contents.
+ (Target_aarch64::do_finalize_sections): Implement contents.
+ (Target_aarch64::Relocate::relocate): Implement a few relocations.
+ (Target_aarch64::relocate_section): Implement contents.
+
+2014-08-06 Alan Modra <amodra@gmail.com>
+
+ * testsuite/defsym_test.sh: Allow ppc64le localentry annotation.
+
+2014-08-06 Alan Modra <amodra@gmail.com>
+
+ PR 13227
+ * symtab.cc (Symbol_table::add_from_relobj): Warn on __gnu_lto_slim.
+
+2014-07-21 Sriraman Tallam <tmsriram@google.com>
+
+ * object.cc (Relobj::is_section_name_included): Add
+ ".rodata.nptl_version" to not garbage collect this section.
+
+2014-07-08 Cary Coutant <ccoutant@google.com>
+
+ * expression.cc (struct Expression::Expression_eval_info): Add
+ new fields type_pointer, vis_pointer, and nonvis_pointer.
+ (Expression::eval_maybe_dot): Add type_pointer, vis_pointer, and
+ nonvis_pointer parameters. Adjust all calls.
+ (Symbol_expression::value): Update type, visibility, and nonvis bits
+ in caller.
+ * script.cc (Symbol_assignment::sized_finalize): Update type,
+ visibility, and remaining st_other bits for new symbol.
+ * script.h: (Expression::eval_maybe_dot): Add type_pointer,
+ vis_pointer, and nonvis_pointer parameters.
+ * symtab.h (Symbol::set_type): New method.
+
+ * testsuite/Makefile.am (defsym_test): New test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/defsym_test.c: New file.
+ * testsuite/defsym_test.sh: New file.
+
+2014-07-08 Cary Coutant <ccoutant@google.com>
+
+ PR gold/15639
+ * dynobj.h (Sized_dynobj::base_read_symbols): New method.
+ * dynobj.cc (Sized_dynobj::do_read_symbols): Move body to...
+ (Sized_dynobj::base_read_symbols): ...new method.
+ * object.h (Sized_relobj_file::base_read_symbols): New method.
+ * object.cc (Sized_relobj_file::do_read_symbols): Move body to...
+ (Sized_relobj_file::base_read_symbols): ...new method.
+ * arm.cc (Arm_relobj::do_read_symbols): Call base_read_symbols.
+ * mips.cc: (Mips_relobj::do_read_symbols): Likewise.
+ * powerpc.cc (Powerpc_dynobj::do_read_symbols): Likewise.
+
+2014-07-04 Alan Modra <amodra@gmail.com>
+
+ * po/POTFILES.in: Regenerate.
+
+2014-07-02 Jing Yu <jingyu@google.com>
+
+ * aarch64.cc: New file
+ * Makefile.am (TARGETSOURCES): Add aarch64.cc
+ (ALL_TARGETOBJS): Add aarch64.$(OBJEXT)
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add entries for aarch64*.
+ * configure.ac: Likewise.
+ * configure: Likewise.
+
+2014-06-27 Alan Modra <amodra@gmail.com>
+
+ * symtab.cc (Symbol::should_add_dynsym_entry): Don't make inline.
+
+2014-06-24 Cary Coutant <ccoutant@google.com>
+
+ * dwp.cc (Dwo_file::read): Allow files with no .debug_types
+ sections.
+ (Dwo_file::sized_read_unit_index): Likewise.
+
+2014-06-23 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * mips.cc: New file.
+ * Makefile.am (TARGETSOURCES): Add mips.cc
+ (ALL_TARGETOBJS): Add mips.$(OBJEXT)
+ * configure.tgt: Add entries for mips*.
+ * configure.ac: Likewise.
+ * Makefile.in: Regenerate.
+ * configure: Likewise.
+
+2014-06-09 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_pubnames_table::read_header): Check that
+ unit_length is within section bounds.
+
+2014-06-09 Cary Coutant <ccoutant@google.com>
+
+ PR gold/16980
+ * layout.cc (Layout::print_to_mapfile): Print unattached sections in
+ map.
+
+2014-06-07 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (relocate): Treat field of cmpli insn as a bitfield.
+
+2014-06-06 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.h (Dwarf_pubnames_table): Remove output_section_offset_.
+ * dwarf_reader.cc (Dwarf_pubnames_table::read_section): Likewise.
+ (Dwarf_pubnames_table::read_header): Likewise.
+ * layout.cc (gdb_fast_lookup_sections): Add .debug_gnu_pubnames and
+ .debug_gnu_pubtypes.
+
+2014-06-05 Joel Brobecker <brobecker@adacore.com>
+
+ * Makefile.am (CONFIG_STATUS_DEPENDENCIES): New.
+ * Makefile.in, configure: Regenerate.
+
+2014-06-03 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (addis_12_2): Define.
+ (Stub_table::do_write): Support fusion on ELFv2 stubs.
+
+2014-06-03 Alan Modra <amodra@gmail.com>
+
+ * testsuite/plugin_test.c (parse_readelf_line): Skip non-visibility
+ st_other output.
+
+2014-06-02 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::local_reloc_may_be_function_pointer):
+ Only ignore relocs on ELFv1.
+ (Target_powerpc::global_reloc_may_be_function_pointer): Likewise.
+
+2014-05-30 Cary Coutant <ccoutant@google.com>
+
+ * testsuite/Makefile.am (ehdr_start_test_4): Fix typo in -B option.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/ehdr_start_test_4.sh: Look for "U" instead of "w".
+
+2014-05-27 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR gold/16945
+ * x86_64.cc (Target_x86_64::Relocate::relocate): Use signed int
+ for got_offset. Properly get GOT address for R_X86_64_PLTOFF64.
+
+2014-05-15 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (do_plt_fde_location): Handle zero length .glink.
+ Compare FDE contents with DW_CFA_nop rather than 0.
+
+2014-05-13 Sriraman Tallam <tmsriram@google.com>
+
+ * symtab.h (may_need_copy_reloc): Remove check for position independent
+ code.
+ * x86_64.cc (Target_x86_64<size>::Scan::global): Add check for no
+ position independence before pc absolute may_need_copy_reloc call.
+ Add check for executable output befor pc relative may_need_copy_reloc
+ call.
+ * i386.cc: Ditto.
+ * arm.cc: Ditto.
+ * sparc.cc: Ditto.
+ * tilegx.cc: Ditto.
+ * powerpc.cc: Add check for no position independence before
+ may_need_copy_reloc calls.
+ * testsuite/pie_copyrelocs_test.cc: New file.
+ * testsuite/pie_copyrelocs_shared_test.cc: New file.
+ * Makefile.am (pie_copyrelocs_test): New test.
+ * Makefile.in: Regenerate.
+
+2014-05-08 Martin Liška <mliska@suse.cz>
+
+ * output.cc (Sized_relobj_file::do_layout): Fix typo in info message.
+
+2014-05-06 Cary Coutant <ccoutant@google.com>
+
+ PR gold/16900
+ * i386.cc (Output_data_got_plt_i386): New class.
+ (Output_data_plt_i386::Output_data_plt_i386): Change type of got_plt
+ parameter. Change all callers.
+ (Output_data_plt_i386::layout_): Remove.
+ (Output_data_plt_i386::got_plt_): Change type.
+ (Target_i386::got_plt_): Change type. Change all references.
+ (Target_i386::got_section): Create instance of new class.
+ (Output_data_got_plt_i386::do_write): New function.
+ * x86_64.cc (Output_data_got_plt_x86_64): New class.
+ (Output_data_plt_x86_64::Output_data_plt_x86_64): Change type of got_plt
+ parameter. Change all callers.
+ (Output_data_plt_x86_64::layout_): Remove.
+ (Output_data_plt_x86_64::got_plt_): Change type.
+ (Target_x86_64::got_plt_): Change type. Change all references.
+ (Target_x86_64::got_section): Create instance of new class.
+ (Output_data_got_plt_x86_64::do_write): New function.
+ (Output_data_plt_x86_64::do_write): Don't write reserved words in GOT.
+ (Target_x86_64<size>::init_got_plt_for_update): Create instance of new
+ class.
+
+2014-05-05 Cary Coutant <ccoutant@google.com>
+
+ * gdb-index.cc (Gdb_index_info_reader): Don't complain about language
+ if we have pubnames/pubtypes.
+
+2014-05-02 Cary Coutant <ccoutant@google.com>
+
+ * defstd.cc (in_segment): Define __ehdr_start here...
+ * layout.cc (Layout::finalize): ...Instead of here. Set the
+ output segment when known.
+ * resolve.cc (Symbol::override_base_with_special): Remember
+ the original binding.
+ * symtab.cc (Symbol::set_output_segment): New function.
+ (Symbol::set_undefined): New function.
+ * symtab.h (Symbol::is_weak_undefined): Check original undef
+ binding.
+ (Symbol::is_strong_undefined): New function.
+ (Symbol::set_output_segment): New function.
+ (Symbol::set_undefined): New function.
+ * target-reloc.h (is_strong_undefined): Remove.
+ (issue_undefined_symbol_error): Call Symbol::is_weak_undefined.
+ Check for hidden undefs.
+ (relocate_section): Call Symbol::is_strong_undefined.
+
+ * testsuite/Makefile.am (ehdr_start_test_1)
+ (ehdr_start_test_2, ehdr_start_test_3)
+ (ehdr_start_test_4, ehdr_start_test_5): New test cases.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/ehdr_start_def.cc: New source file.
+ * testsuite/ehdr_start_test.cc: New source file.
+ * testsuite/ehdr_start_test.t: New linker script.
+ * testsuite/ehdr_start_test_4.sh: New shell script.
+
+2014-04-23 Cary Coutant <ccoutant@google.com>
+
+ PR gold/16870
+ * x86_64.cc (Target_x86_64::Relocate::relocate): Add missing break.
+
+2014-04-15 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * layout.cc (Layout::include_section): Allow a target to decide
+ whether to include a section.
+ * target.h (Target::should_include_section): New function.
+ (Target::do_should_include_section): New function.
+
+2014-04-15 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * copy-relocs.cc (Copy_relocs::Copy_reloc_entry::emit): Remove and
+ inline into ...
+ (Copy_relocs::emit): ... here.
+ * copy-relocs.h (Copy_reloc_entry): Change from class to struct.
+ (Copy_reloc_entry::make_copy_reloc): Change from private to protected.
+ (Copy_reloc_entry::entries_): Change from private to protected.
+
+2014-04-02 Sriraman Tallam <tmsriram@google.com>
+
+ * icf.cc (get_section_contents): Replace copies of reloc
+ vectors with const references.
+
+2014-04-02 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac (HAVE_PUBNAMES): Use C instead of C++.
+ (HAVE_NO_USE_LINKER_PLUGIN): Check for -fno-use-linker-plugin.
+ * configure: Regenerate.
+ * testsuite/Makefile.am (OPT_NO_PLUGINS): New macro for
+ -fno-use-linker-plugin.
+ (LINK1, CXXLINK1): Add it to the link command.
+ * testsuite/Makefile.in: Regenerate.
+
+2014-03-12 Alan Modra <amodra@gmail.com>
+
+ * Makefile.in: Regenerate.
+
+2014-03-10 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * symtab.h (Symbol::set_nonvis): New function.
+
+2014-03-10 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * symtab.cc (Sized_symbol<32>::init_output_data):
+ Instantiate the template.
+ (Sized_symbol<64>::init_output_data): Likewise.
+
+2014-03-10 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * symtab.cc (Symbol_table::sized_write_globals): Allow a target to
+ adjust dynamic symbol value.
+ * target.h (Target::adjust_dyn_symbol): New function.
+ (Target::do_adjust_dyn_symbol): New function.
+
+2014-03-10 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * output.cc (Output_data_dynamic::Dynamic_entry::write):
+ Get the value of DYNAMIC_CUSTOM dynamic entry.
+ * output.h (Output_data_dynamic::add_custom): New function.
+ (Dynamic_entry::Dynamic_entry): New constructor for DYNAMIC_CUSTOM
+ dynamic entry.
+ (enum Dynamic_entry::Classification): Add DYNAMIC_CUSTOM.
+ * target.h (Target::dynamic_tag_custom_value): New function.
+ (Target::do_dynamic_tag_custom_value): New function.
+
+2014-03-10 Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * symtab.cc (Symbol_table::set_dynsym_indexes): Allow a target to set
+ dynsym indexes.
+ * target.h (Target::has_custom_set_dynsym_indexes): New function.
+ (Target::do_has_custom_set_dynsym_indexes): New function.
+ (Target::set_dynsym_indexes): New function.
+ (Target::do_set_dynsym_indexes): New function.
+
+2014-03-07 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relocate_functions::Overflow_check): Add
+ CHECK_UNSIGNED, CHECK_LOW_INSN, CHECK_HIGH_INSN.
+ (Powerpc_relocate_functions::has_overflow_unsigned): New function.
+ (Powerpc_relocate_functions::has_overflow_bitfield,
+ overflowed): Use the above.
+ (Target_powerpc::Relocate::relocate): Correct overflow checking
+ for a number of relocations. Modify overflow test for 16-bit
+ fields in instructions to signed/unsigned according to whether
+ the field takes a signed or unsigned value.
+
+2014-03-05 Alan Modra <amodra@gmail.com>
+
+ Update copyright years.
+
+2014-03-05 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::Scan::local, global): Support
+ R_PPC64_ADDR64_LOCAL.
+ (Target_powerpc::Relocate::relocate): Likewise.
+
+2014-03-03 Alan Modra <amodra@gmail.com>
+
+ * dwp.cc (print_version): Update copyright year to current.
+
+2014-02-10 Alan Modra <amodra@gmail.com>
+
+ * po/gold.pot: Regenerate.
+
+2014-02-06 Cary Coutant <ccoutant@google.com>
+
+ Fix problem where -u is ignored when a weak undef is seen.
+
+ * archive.cc (Library_base::should_include_member): Reorder
+ code to check for -u option if a weak undef has already been seen.
+ * testsuite/Makefile.am (weak_undef_test_2): New test case.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/weak_undef_file3.cc: New file.
+ * testsuite/weak_undef_file4.cc: New file.
+ * testsuite/weak_undef_test_2.cc: New file.
+
+2014-02-05 Cary Coutant <ccoutant@google.com>
+
+ Fix issues with gold undefined symbol diagnostics.
+
+ PR binutils/15435
+ * errors.cc (Errors::undefined_symbol): Move undef vtable symbol
+ check to here.
+ * target-reloc.h (is_strong_undefined): New function.
+ (relocate_section): Move undef vtable symbol check from here.
+ Check for is_strong_undefined.
+
+2014-02-05 Cary Coutant <ccoutant@google.com>
+
+ Fix problems with the --dynamic-list option.
+
+ PR gold/13577
+ * options.cc (General_options::parse_dynamic_list):
+ Set have_dynamic_list_.
+ (General_options::General_options): Initialize have_dynamic_list_.
+ (General_options::finalize): Turn off -Bsymbolic and
+ -Bsymbolic-functions if --dynamic-list provided.
+ * options.h (General_options::have_dynamic_list): New function.
+ (General_options::have_dynamic_list_): New data member.
+ * symtab.h (Symbol::is_preemptible): Handle --dynamic-list
+ correctly.
+
+ PR gold/16530
+ * symtab.cc (Symbol_table::add_from_relobj): If symbol is named
+ in --dynamic-list, mark it.
+
+ * testsuite/Makefile.am (gc_dynamic_list_test.sh): New test case.
+ (dynamic_list_2): New test case.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/dynamic_list_2.cc: New file.
+ * testsuite/dynamic_list_2.t: New file.
+ * testsuite/dynamic_list_lib1.cc: New file.
+ * testsuite/dynamic_list_lib2.cc: New file.
+ * testsuite/gc_dynamic_list_test.c: New file.
+ * testsuite/gc_dynamic_list_test.sh: New file.
+ * testsuite/gc_dynamic_list_test.t: New file.
+
+2014-01-28 Cary Coutant <ccoutant@google.com>
+
+ Add .gdb_index version 7 support.
+
+ * gold/dwarf_reader.cc: include <utility> (for make_pair).
+ (Dwarf_abbrev_table::do_read_abbrevs): Check for compressed
+ debug sections.
+ (Dwarf_ranges_table::read_ranges_table): Likewise.
+ (Dwarf_pubnames_table::read_section): Check for GNU-style
+ sections, and for compressed debug sections.
+ (Dwarf_pubnames_table::read_header): Compute end address of table.
+ (Dwarf_pubnames_table::next_name): Return flag_byte. Check
+ for end of list by offset, not by offset == 0.
+ (Dwarf_info_reader::do_read_string_table): Check for compressed
+ debug sections.
+ * gold/dwarf_reader.h (Dwarf_pubnames_table::Dwarf_pubnames_table):
+ Initialize new data members.
+ (Dwarf_pubnames_table::next_name): return flag_byte.
+ (Dwarf_pubnames_table::end_of_table_): New data member.
+ (Dwarf_pubnames_table::is_gnu_style_): New data member.
+ * gold/gdb-index.cc (gdb_index_version): Update to version 7.
+ (Gdb_index_info_reader::read_pubtable): Read flag_byte.
+ (Gdb_index_info_reader::read_pubnames_and_pubtypes): Don't
+ read skeleton type unit DIEs.
+ (Gdb_index::add_symbol): Add flag_byte; adjust all callers.
+ (Gdb_index::do_write): Write flag_byte.
+ * gold/gdb-index.h (Gdb_index::add_symbol): Add flags parameter.
+ (Gdb_index::Cu_vector): Store flags along with cu indexes.
+ * gold/testsuite/gdb_index_test_3.sh: Allow versions 4-7.
+ * gold/testsuite/gdb_index_test_comm.sh: Likewise.
+
+2014-01-08 H.J. Lu <hongjiu.lu@intel.com>
+
+ * version.cc (print_version): Update copyright year to 2014.
+
+2013-12-19 Dimitry Andric <dimitry@andric.com>
+
+ * stringpool.cc (Stringpool_template::reserve): Add
+ HAVE_UNORDERED_MAP case.
+ * stringpool.cc (Stringpool_template::print_stats): Likewise.
+
+2013-12-18 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac: Check for <unordered_set> and <unordered_map>.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+ * system.h: Use <unordered_set> and <unordered_map> if available.
+
+2013-12-10 Roland McGrath <mcgrathr@google.com>
+
+ * Makefile.am (install-exec-local): Prefix $(INSTALL_PROGRAM) uses
+ with $(INSTALL_PROGRAM_ENV).
+ * Makefile.in: Regenerate.
+
+2013-11-22 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac: Add check for which library is needed for
+ dlopen.
+ * configure: Regenerate.
+
+2013-11-22 Cary Coutant <ccoutant@google.com>
+
+ * testsuite/Makefile.am (exception_x86_64_bnd_test): Use in-tree
+ assembler.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-11-17 H.J. Lu <hongjiu.lu@intel.com>
+
+ * x86_64.cc (Target_x86_64<size>::Scan::get_reference_flags):
+ Handle R_X86_64_PC32_BND and R_X86_64_PLT32_BND just like
+ R_X86_64_PC32 and R_X86_64_PLT32, respectively.
+ (Target_x86_64<size>::Scan::local): Likewise.
+ (Target_x86_64<size>::Scan::global): Likewise.
+ (Target_x86_64<size>::Relocate::relocate): Likewise.
+ (Target_x86_64<size>::Relocatable_size_for_reloc::get_size_for_reloc):
+ Likewise.
+ (Target_x86_64<size>::Scan::check_non_pic(): Handle
+ R_X86_64_PC32_BND.
+
+ * testsuite/Makefile.am (check_PROGRAMS): Add
+ exception_x86_64_bnd_test.
+ (exception_x86_64_bnd_test_SOURCES): New macro.
+ (exception_x86_64_bnd_test_DEPENDENCIES): Likewise.
+ (exception_x86_64_bnd_test_LDFLAGS): Likewise.
+ (exception_x86_64_bnd_test_LDADD): Likewise.
+ (exception_x86_64_bnd_1.o): New rule.
+ (exception_x86_64_bnd_2.o): Likewise.
+ * testsuite/Makefile.in: Regenerated.
+
+2013-11-15 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::glink_section): Provide non-const
+ accessor.
+ (Target_powerpc::Branch_info::make_stub): Make global entry stubs.
+ Only call ppc64_local_entry_offset for 64-bit. Restrict
+ symval_for_branch lookup to ELFv1.
+ (Stub_table::add_plt_call_entry): Use unsigned int off.
+ (Output_data_glink::Address, invalid_address): New.
+ (Output_data_glink::add_eh_frame): Move out of line. Add
+ support for ELFv2.
+ (Output_data_glink::add_global_entry, find_global_entry,
+ global_entry_address): New functions.
+ (Output_data_glink::global_entry_stubs_, end_branch_table_,
+ ge_size): New variables.
+ (Output_data_glink::set_final_data_size): Add global entry
+ stub sizing.
+ (Output_data_glink::do_write): Write global entry stubs.
+ (Target_powerpc::Scan::reloc_needs_plt_for_ifunc): Add target
+ parameter. Return true for ELFv2. Adjust callers.
+ (Target_powerpc::Scan::local, global): Restrict opd lookup to
+ ELFv1. Similarly for ifunc and dynamic relocation processing
+ specific to ELFv1. Recognize that symbols are defined on
+ their plt entries for ELFv2.
+ (Target_powerpc::symval_for_branch): Assert if called for
+ ELFv2 or ppc32.
+ (Target_powerpc::Relocate::relocate): Use global entry plt
+ stub for symbol value if such exists on ELFv2.
+ (Target_powerpc::Relocate::relocate): Don't call
+ symval_for_branch when ELFv2. Do adjust for local entry
+ offset when ELFv2.
+ (Target_powerpc::do_dynsym_value): Set symbols to global entry
+ plt stub for ELFv2.
+ (Target_powerpc::do_plt_address_for_global): Similarly.
+
+2013-11-14 Cary Coutant <ccoutant@google.com>
+
+ Revert patch -- this did not fix the problem, and there is
+ no race there.
+
+ 2013-11-14 Cary Coutant <ccoutant@google.com>
+
+ PR gold/14860
+ * ehframe.cc (Eh_frame_hdr::Eh_frame_hdr): Initialize lock_.
+ (Ehframe_hdr::set_final_data_size): Allocate a Lock.
+ * ehframe.h (Eh_frame_hdr::record_fde): Hold the lock while
+ updating fde_offsets_.
+ (Eh_frame_hdr::lock_): New data member.
+
+2013-11-14 Cary Coutant <ccoutant@google.com>
+
+ * dwp.cc (Dwo_file_entry): New type.
+ (File_list): Use Dwo_file_entry.
+ (Dwo_file::verify): New function.
+ (Dwo_file::verify_dwo_list): New function.
+ (Dwo_file::sized_verify_dwo_list): New function.
+ (Dwo_name_info_reader::visit_compilation_unit): Add dwo_id to file
+ list.
+ (Dwp_options): New enum type.
+ (dwp_options): Add --verify-only.
+ (usage): Likewise.
+ (main): Likewise.
+ * dwp.h (gold_info): Add declaration.
+
+2013-11-14 Cary Coutant <ccoutant@google.com>
+
+ PR gold/14860
+ * ehframe.cc (Eh_frame_hdr::Eh_frame_hdr): Initialize lock_.
+ (Ehframe_hdr::set_final_data_size): Allocate a Lock.
+ * ehframe.h (Eh_frame_hdr::record_fde): Hold the lock while
+ updating fde_offsets_.
+ (Eh_frame_hdr::lock_): New data member.
+
+2013-11-06 Cary Coutant <ccoutant@google.com>
+
+ PR gold/15758
+ * object.cc (Sized_relobj_file::do_layout): Handle .eh_frame sections
+ before reloc sections.
+
+2013-11-04 Alan Modra <amodra@gmail.com>
+
+ * symtab.h (Symbol::Reference_flags): Add FUNC_DESC_ABI.
+ (Symbol::needs_dynamic_reloc): Test new flag.
+ * powerpc.cc (needs_dynamic_reloc, use_plt_offset): Delete.
+ (Target_powerpc::Scan::get_reference_flags): Add target param.
+ Return FUNC_DESC_ABI for 64-bit ELFv1.
+ (Target_powerpc::Branch_info::make_stub): Adjust get_reference_flags
+ call.
+ (Target_powerpc::Scan::global): Use Symbol::needs_dynamic_reloc.
+ (Target_powerpc::Relocate::relocate): Use Symbol::use_plt_offset.
+
+2013-10-31 Cary Coutant <ccoutant@google.com>
+
+ Restore support for dwp v2 DWARF package file format.
+
+ * dwarf_reader.cc (Dwarf_info_reader::visit_type_unit): Add
+ tu_length parameter. Adjust all callers.
+ * dwarf_reader.h (Dwarf_info_reader::visit_type_unit): Likewise.
+ * dwp.cc: Include dwarf.h.
+ (Section_bounds): New struct type.
+ (Unit_set): New struct type.
+ (Dwo_file::Dwo_file): Initialize new data member.
+ (Dwo_file::read_compunit_index, Dwo_file::read_typeunit_index):
+ Combine and rename to...
+ (Dwo_file::read_unit_index): ...this.
+ (Dwo_file::sized_read_compunit_index)
+ (Dwo_file::sized_read_typeunit_index): Combine and rename to...
+ (Dwo_file::sized_read_unit_index): ...this.
+ (Dwo_file::copy_section): Remove section_name, is_str_offsets
+ parameters; add section_id parameter.
+ (Dwo_file::add_cu_set, Dwo_file::add_tu_set): Combine and rename to...
+ (Dwo_file::add_unit_set): ...this.
+ (Dwo_file::shndx_map_): Remove.
+ (Dwo_file::sect_offsets_): New data member.
+ (Dwp_output_file::Dwp_output_file): Initialize new data members.
+ (Dwp_output_file::add_section): Rename to...
+ (Dwp_output_file::add_contribution): ...this.
+ (Dwp_output_file::add_cu_set): Combine parameters into a struct.
+ (Dwp_output_file::add_tu_set): Likewise.
+ (Dwp_output_file::Contribution): New type.
+ (Dwp_output_file::Section::contributions): New data member.
+ (Dwp_output_file::Cu_or_tu_set): Remove.
+ (Dwp_output_file::Section::Section): New ctor.
+ (Dwp_output_file::Dwp_index::Shndx_pool): Remove.
+ (Dwp_output_file::Dwp_index::Section_table): New type.
+ (Dwp_output_file::Dwp_index::Dwp_index): Initialize new data members.
+ (Dwp_output_file::Dwp_index::enter_set): Change type of "set"
+ parameter.
+ (Dwp_output_file::Dwp_index::shndx_pool): Remove.
+ (Dwp_output_file::Dwp_index::shndx_pool_end): Remove.
+ (Dwp_output_file::Dwp_index::section_table): New member function.
+ (Dwp_output_file::Dwp_index::section_table_end): New member function.
+ (Dwp_output_file::Dwp_index::shndx_pool_size): Remove.
+ (Dwp_output_file::Dwp_index::section_table_rows): New member function.
+ (Dwp_output_file::Dwp_index::section_table_cols): New member function.
+ (Dwp_output_file::Dwp_index::shndx_pool_): Remove.
+ (Dwp_output_file::Dwp_index::section_table_): New data member.
+ (Dwp_output_file::Dwp_index::section_mask_): New data member.
+ (Dwp_output_file::add_output_section): New member function.
+ (Dwp_output_file::write_new_section): New member function.
+ (Dwp_output_file::write_contributions): New member function.
+ (Dwp_output_file::section_id_map_): New data member.
+ (class Dwo_id_info_reader): Remove.
+ (class Unit_reader): New class.
+ (get_dwarf_section_name): New function.
+ (Dwo_file::read_executable): Adjust initializations of class data.
+ (Dwo_file::read): Add support for v2 package file format.
+ (Dwo_file::read_unit_index): Likewise.
+ (Dwo_file::sized_read_unit_index): Likewise.
+ (Dwo_file::copy_section): Likewise.
+ (Dwo_file::add_unit_set): Likewise.
+ (Dwp_output_file::add_output_section): Likewise.
+ (Dwp_output_file::add_contribution): Likewise.
+ (Dwp_output_file::Dwp_index::find_or_add): Use row index to check
+ for empty slot.
+ (Dwp_output_file::Dwp_index::enter_set): Add support for v2 package
+ file format.
+ (Dwp_output_file::Dwp_index::grow): Use row index to check for empty
+ slot.
+ (Dwp_output_file::initialize): Remove unused function.
+ (Dwp_output_file::finalize): Add support for v2 package file format.
+ (Dwp_output_file::write_index): Likewise.
+ * gdb-index.cc (Gdb_index_info_reader::visit_type_unit): Adjust
+ function prototype.
+
+2013-10-31 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac: Fix check for -fmerge-constants.
+ * configure.ac: Regenerate.
+
+2013-10-30 Roland McGrath <mcgrathr@google.com>
+
+ * x86_64.cc (Output_data_plt_x86_64_nacl::first_plt_entry):
+ Correct 9-byte nop sequence to match what the assembler generates.
+
+2013-10-30 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::abiversion, set_abiversion,
+ ppc64_local_entry_offset, ppc64_local_entry_offset,
+ do_read_symbols): New functions.
+ (Powerpc_relobj::e_flags_, st_other_): New vars.
+ (Powerpc_relobj::Powerpc_relobj): Call set_abiversion.
+ (Powerpc_dynobj::abiversion, set_abiversion): New functions.
+ (Powerpc_relobj::e_flags_): New var.
+ (Target_powerpc::first_plt_entry_offset, plt_entry_size): Inline
+ and adjust for ELFv2.
+ (Target_powerpc::abiversion, set_abiversion, stk_toc): New functions.
+ (Powerpc_relobj::do_find_special_sections): Check no .opd in ELFv2.
+ (Powerpc_dynobj::do_find_special_sections): Likewise.
+ (Target_powerpc::do_define_standard_symbols): Define ".TOC.".
+ (Target_powerpc::Branch_info::make_stub): Adjust stub destination
+ to ELFv2 local entry.
+ (Target_powerpc::do_relax): No thread safe barriers needed for
+ ELFv2.
+ (Output_data_plt_powerpc::initial_plt_entry_size_,
+ plt_entry_size): Delete. Replace all uses with
+ first_plt_entry_offset() and plt_entry_size().
+ (Output_data_plt_powerpc::Output_data_plt_powerpc): Remove
+ reserved_size parm. Update callers.
+ (Output_data_plt_powerpc::entry_count): Update.
+ (Output_data_plt_powerpc::first_plt_entry_offset): Make private
+ and use Target_powerpc::first_plt_entry_offset().
+ (Output_data_plt_powerpc::get_plt_entry_size): Similarly and
+ rename to plt_entry_size.
+ (Output_data_plt_powerpc::add_ifunc_entry,
+ add_local_ifunc_entry): Adjust reloc for ELFv2.
+ (glink_eh_frame_fde_64): Rename to glink_eh_frame_fde_64v1.
+ (glink_eh_frame_fde_64v2): New.
+ (Stub_table::plt_call_size): Support ELFv2 sizing.
+ (Output_data_glink::add_eh_frame): Use the new FDE.
+ (Output_data_glink::set_final_data_size): Adjust for ELFv2 glink.
+ (Stub_table::do_write): Write ELFv2 stubs and glink.
+ (Target_powerpc::Relocate::relocate): Replaces nop after call
+ with ld 2,24(1) and adjust local offset destination for ELFv2.
+
+2013-10-30 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::Scan::check_non_pic): Handle new relocs.
+ (Target_powerpc::Scan::global, local): Likewise.
+ (Target_powerpc::Relocate::relocate): Likewise. Check for overflow
+ on all ppc64 @h and @ha relocs.
+
+2013-10-14 Alan Modra <amodra@gmail.com>
+
+ * output.h (Output_data_got::add_constant): Tidy.
+ (Output_data_got::add_constant_pair): New function.
+ * powerpc.cc (Output_data_got_powerpc): Override all Output_data_got
+ methods used so as to first call reserve_ent().
+
+2013-10-11 Roland McGrath <mcgrathr@google.com>
+
+ * powerpc.cc (Output_data_got_powerpc): Remove unused methods
+ add_got_entry and add_got_entry_pair.
+
+ * configure.ac (TLS_GNU2_DIALECT): Use -Werror in test.
+ (HAVE_PUBNAMES): Likewise.
+ * configure: Regenerate.
+
+ * testsuite/Makefile.am: Replace '-T foo' with '-Wl,-T,foo' throughout.
+ * testsuite/Makefile.in: Regenerate.
+
+ * target.h (Target::adjust_elf_header, Target::do_adjust_elf_header):
+ Remove const from declaration.
+ * target.cc (Sized_target::do_adjust_elf_header): Update definition.
+ * sparc.cc (Target_sparc::do_adjust_elf_header): Likewise.
+ * output.h (Output_file_header): Remove const from member target_
+ and corresponding constructor argument.
+ * output.cc (Output_file_header::Output_file_header): Update prototype.
+ (Output_file_header::do_sized_write): Use this->target_ in place
+ of parameters()->target().
+
+ * testsuite/undef_symbol.cc (Foo::get_a): New method.
+
+ * configure.ac (MERGE_CONSTANTS_FLAG): New check.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * testsuite/merge_string_literals_1.c: Renamed to have .cc suffix.
+ * testsuite/merge_string_literals_2.c: Likewise.
+ * testsuite/Makefile.am
+ (merge_string_literals_1.o, merge_string_literals_2.o): Update deps.
+ (AM_CFLAGS, AM_CXXFLAGS): Use $(MERGE_CONSTANTS_FLAG) in place of
+ literal -fmerge-constants.
+ * testsuite/Makefile.in: Regenerate.
+
+ * i386.cc (Target_i386): Remove unused member dynbss_.
+ * arm.cc (Target_arm): Likewise.
+ * powerpc.cc (Target_powerpc): Likewise.
+ * sparc.cc (Target_sparc): Likewise.
+ * tilegx.cc (Target_tilegx): Likewise.
+ * x86_64.cc (Target_x86_64): Likewise.
+ * dwarf_reader.h (Dwarf_info_reader): Remove unused members
+ type_signature_, type_offset_.
+ * plugin.h (Plugin_hook): Remove unused member layout_.
+ * readsyms.h (Add_symbols): Remove unused members dirpath_, dirindex_,
+ mapfile_.
+ (Read_member): Remove unused members input_objects_, symtab_,
+ mapfile_, layout_.
+ (Check_library): Remove unused member symtab_.
+ * archive.h (Lib_group): Remove unused member lib_.
+ * archive.cc (Lib_group::Lib_group): Update initializer.
+ * incremental.h (Incremental_binary): Remove unused member target_.
+ (Incremental_script_entry): Removed unused member script_.
+ * layout.h (Write_symbols_task): Remove unused member input_objects_.
+ * icf.h (Icf): Remove unused member num_tracked_relocs.
+
+ * gold-threads.h (Once): Conditionalize member was_run_lock_ on
+ [ENABLE_THREADS && __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4], matching
+ its only use.
+ * gold-threads.cc (Once::Once): Likewise conditionalize initializer.
+
+ * archive.h: Use struct rather than class for forward declaration
+ of Read_symbols_data.
+
+2013-10-07 Cary Coutant <ccoutant@google.com>
+
+ PR gold/16010
+ * testsuite/Makefile.am (icf_test): Fix dependencies.
+ (icf_safe_test): Likewise.
+ (icf_safe_so_test): Likewise.
+ (large_symbol_alignment): Add empty _LDADD rule.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-09-03 Pavel Chupin <pavel.v.chupin@intel.com>
+
+ PR gold/15927
+ * x86_64.cc (Target_x86_64<size>::Scan::global): Use relative
+ relocation for R_X86_64_32 on x32.
+
+2013-08-27 Roland McGrath <mcgrathr@google.com>
+
+ * output.cc (Output_segment::set_section_addresses): Take new
+ Target* argument. If target->isolate_execinstr() and the segment
+ is executable and starts at a target->abi_pagesize() boundary,
+ pad its end out to a target->abi_pagesize() boundary with code fill.
+ * output.h (Output_segment::set_section_addresses): Update decl.
+ * layout.h (Layout::check_output_data_for_reset_values): Take new
+ argument RELAX_OUTPUTS.
+ (Layout): New member relax_output_list_.
+ (Layout::add_relax_output): New method.
+ * layout.cc (Layout::Layout): Update constructor.
+ (Layout::reset_relax_output): New method.
+ (Layout::clean_up_after_relaxation): Call it.
+ (Layout::prepare_for_relaxation): Update caller.
+ (Layout::set_segment_offsets): Update callers of set_section_addresses.
+ Call reset_relax_output before re-processing segments for
+ isolate_execinstr case.
+ (Layout::write_data): Handle relax_output_list_.
+ (Layout::Relaxation_debug_check::check_output_data_for_reset_values):
+ Take new argument RELAX_OUTPUTS. Assert it's an empty collection.
+
+2013-08-23 Yuri Chornoivan <yurchor@ukr.net>
+
+ PR binutils/15834
+ * object.h: Fix typos.
+
+2013-08-16 Roland McGrath <mcgrathr@google.com>
+
+ * i386.cc (Target_i386_nacl::do_code_fill): New virtual function.
+ * x86_64.cc (Target_x86_64_nacl::do_code_fill): New virtual function.
+
+2013-08-07 Cary Coutant <ccoutant@google.com>
+
+ Revert support for v2 DWP files:
+
+ 2013-03-01 Cary Coutant <ccoutant@google.com>
+
+ Add dwp support for v2 DWARF package file format.
+ * dwarf_reader.cc (Dwarf_info_reader::visit_type_unit): Add
+ tu_length parameter. Adjust all callers.
+ * dwarf_reader.h (Dwarf_info_reader::visit_type_unit): Likewise.
+ * dwp.cc: Include dwarf.h.
+ (Section_bounds): New struct type.
+ (Unit_set): New struct type.
+ (Dwo_file::Dwo_file): Initialize new data member.
+ (Dwo_file::read_compunit_index, Dwo_file::read_typeunit_index):
+ Combine and rename to...
+ (Dwo_file::read_unit_index): ...this.
+ (Dwo_file::sized_read_compunit_index)
+ (Dwo_file::sized_read_typeunit_index): Combine and rename to...
+ (Dwo_file::sized_read_unit_index): ...this.
+ (Dwo_file::copy_section): Remove section_name, is_str_offsets
+ parameters; add section_id parameter.
+ (Dwo_file::add_cu_set, Dwo_file::add_tu_set): Combine and rename to...
+ (Dwo_file::add_unit_set): ...this.
+ (Dwo_file::shndx_map_): Remove.
+ (Dwo_file::sect_offsets_): New data member.
+ (Dwp_output_file::Dwp_output_file): Initialize new data members.
+ (Dwp_output_file::add_section): Rename to...
+ (Dwp_output_file::add_contribution): ...this.
+ (Dwp_output_file::add_cu_set): Combine parameters into a struct.
+ (Dwp_output_file::add_tu_set): Likewise.
+ (Dwp_output_file::Contribution): New type.
+ (Dwp_output_file::Section::contributions): New data member.
+ (Dwp_output_file::Cu_or_tu_set): Remove.
+ (Dwp_output_file::Section::Section): New ctor.
+ (Dwp_output_file::Dwp_index::Shndx_pool): Remove.
+ (Dwp_output_file::Dwp_index::Section_table): New type.
+ (Dwp_output_file::Dwp_index::Dwp_index): Initialize new data members.
+ (Dwp_output_file::Dwp_index::enter_set): Change type of "set"
+ parameter.
+ (Dwp_output_file::Dwp_index::shndx_pool): Remove.
+ (Dwp_output_file::Dwp_index::shndx_pool_end): Remove.
+ (Dwp_output_file::Dwp_index::section_table): New member function.
+ (Dwp_output_file::Dwp_index::section_table_end): New member function.
+ (Dwp_output_file::Dwp_index::shndx_pool_size): Remove.
+ (Dwp_output_file::Dwp_index::section_table_rows): New member function.
+ (Dwp_output_file::Dwp_index::section_table_cols): New member function.
+ (Dwp_output_file::Dwp_index::shndx_pool_): Remove.
+ (Dwp_output_file::Dwp_index::section_table_): New data member.
+ (Dwp_output_file::Dwp_index::section_mask_): New data member.
+ (Dwp_output_file::add_output_section): New member function.
+ (Dwp_output_file::write_new_section): New member function.
+ (Dwp_output_file::write_contributions): New member function.
+ (Dwp_output_file::section_id_map_): New data member.
+ (class Dwo_id_info_reader): Remove.
+ (class Unit_reader): New class.
+ (get_dwarf_section_name): New function.
+ (Dwo_file::read_executable): Adjust initializations of class data.
+ (Dwo_file::read): Add support for v2 package file format.
+ (Dwo_file::read_unit_index): Likewise.
+ (Dwo_file::sized_read_unit_index): Likewise.
+ (Dwo_file::copy_section): Likewise.
+ (Dwo_file::add_unit_set): Likewise.
+ (Dwp_output_file::add_output_section): Likewise.
+ (Dwp_output_file::add_contribution): Likewise.
+ (Dwp_output_file::Dwp_index::find_or_add): Use row index to check
+ for empty slot.
+ (Dwp_output_file::Dwp_index::enter_set): Add support for v2 package
+ file format.
+ (Dwp_output_file::Dwp_index::grow): Use row index to check for empty
+ slot.
+ (Dwp_output_file::initialize): Remove unused function.
+ (Dwp_output_file::finalize): Add support for v2 package file format.
+ (Dwp_output_file::write_index): Likewise.
+ * gdb-index.cc (Gdb_index_info_reader::visit_type_unit): Adjust
+ function prototype.
+
+2013-07-31 Cary Coutant <ccoutant@google.com>
+
+ * object.cc (Sized_relobj::do_output_section_address): New function.
+ (Sized_relobj): Instantiate explicitly.
+ * object.h (Object::output_section_address): New function.
+ (Object::do_output_section_address): New function.
+ (Sized_relobj::do_output_section_address): New function.
+ * powerpc.cc (Target_powerpc::symval_for_branch): Use it.
+
+2013-07-30 Cary Coutant <ccoutant@google.com>
+ Sasa Stankovic <Sasa.Stankovic@imgtec.com>
+
+ * parameters.cc (Parameters::entry): Return target-specific entry
+ symbol name.
+ * target.h (Target::entry_symbol_name): New function.
+ (Target_info::entry_symbol_name): New data member.
+
+ * arm.cc (Target_arm::arm_info): Add entry_symbol_name.
+ * i386.cc (Target_i386::i386_info): Likewise.
+ (Target_i386_nacl::i386_nacl_info): Likewise.
+ * sparc.cc (Target_sparc::sparc_info): Likewise.
+ * tilegx.cc (Target_tilegx::tilegx_info): Likewise.
+ * x86_64.cc: (Target_x86_64::x86_64_info) Likewise.
+ (Target_x86_64_nacl::x86_64_nacl_info) Likewise.
+ * testsuite/testfile.cc (Target_test::test_target_info): Likewise.
+
+2013-07-22 Sterling Augustine <saugustine@google.com>
+
+ * dwarf_reader.cc (Dwarf_pubnames_table::read_section):
+ Convert parameter shndx to local variable. Add parameters symtab
+ and symtab_size. Scan over section names. Find relocation
+ section corresponding to current section. Create and initialize
+ reloc_mapper_ and reloc_type_.
+ (Dwarf_pubnames_table::read_header): Add assertion. Change
+ unit_length to off_t. Initialize member unit_length_. Fill in field
+ cu_offset_.
+ * dwarf_reader.h (Dwarf_pubnames_table::Dwarf_pubnames_table):
+ Initialize new fields unit_length_ and cu_offset_.
+ (Dwarf_pubnames_table::read_section): Update prototype.
+ (Dwarf_pubnames_table::cu_offset): New member function.
+ (Dwarf_pubnames_table::subsection_size): Likewise.
+ (Dwarf_pubnames_table::cu_offset_, Dwarf_pubnames_table::unit_length):
+ New fields.
+ (Dwarf_info_reader::symtab, Dwarf_info_reader::symtab_size): Make
+ member functions public.
+ * gdb_index.cc (Gdb_index_info_reader::read_pubnames_and_pubtypes):
+ Update comment. Rework logic. Move repeated parts to...
+ (Gdb_index_info_reader::read_pubtable): ...here. New function.
+ (Gdb_index::Gdb_index): Initialize new fields, pubnames_table_,
+ pubtypes_table_, and stmt_list_offset.
+ (Gdb_index::map_pubtable_to_dies, Gdb_index::find_pubname_offset,
+ Gdb_index::find_pubtype_offset,
+ Gdb_index::map_pubnames_and_types_to_dies): Define new functions.
+ (Gdb_index::pubnames_read): Update prototype and rework logic.
+ * gdb_index.h (Gdb_index_info_reader, Dwarf_pubnames_table):
+ Forward declare.
+ (Gdb_index::map_pubtable_to_dies, Gdb_index::find_pubname_offset,
+ Gdb_index::find_pubtype_offset, Gdb_index::pubnames_table)
+ Gdb_index::pubtypes_table, Gdb_index::map_pubnames_and_types_to_dies,
+ Gdb_index::map_pubtable_to_dies):
+ Declare functions.
+ (Gdb_index::pubnames_read): Update declaration.
+ (Gdb_index::Pubname_offset_map): New type.
+ (Gdb_index::cu_pubname_map_, Gdb_index::cu_pubtype_map_,
+ Gdb_index::pubnames_table_, Gdb_index::pubtypes_table_,
+ Gdb_index::stmt_list_offset): Declare.
+ (Gdb_index::pubnames_shndx_, Gdb_index::pubnames_offet_,
+ Gdb_index::pubtypes_object_, Gdb_index::pubtypes_shndx_)
+ Gdb_index::pubtypes_offset_): Remove.
+
+2013-07-19 Roland McGrath <mcgrathr@google.com>
+
+ * options.h (General_options): Add -Trodata-segment option.
+ * parameters.cc (Parameters::check_rodata_segment): New function.
+ (Parameters::set_target_once): Call it.
+ * parameters.h (Parameters): Declare it (private member function).
+ * layout.cc (load_seg_unusable_for_headers): New function, broken
+ out of Layout::relaxation_loop_body. If TARGET->isolate_execinstr()
+ then validate rodata segment rather than text segment.
+ (relaxation_loop_body): Call that.
+ (is_text_segment): New function. Don't admit a non-executable
+ segment if TARGET->isolate_execinstr().
+ (set_segment_offsets): Call it. Honor -Trodata-segment option.
+
+2013-07-15 Shawn Landden <shawnlandden@gmail.com>
+
+ PR gold/15070
+ * fileread.h (File_read::get_view): Clarify comment about ALIGNED.
+ * nacl.h (Sniff_file::View::View): Request aligned view.
+
+2013-07-11 Cary Coutant <ccoutant@google.com>
+
+ * powerpc.cc (Target_powerpc::write_branch_lookup_table): Use
+ correct BRLT entry size.
+
+2013-07-03 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::Relocate::relocate): Update self-call
+ comment.
+
+2013-07-01 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_ranges_table::read_ranges_table): Save
+ reloc_type_.
+ (Dwarf_ranges_table::read_range_list): Call lookup_reloc.
+ (Dwarf_ranges_table::lookup_reloc): New function.
+ * dwarf_reader.h (Dwarf_ranges_table::Dwarf_ranges_table): Initialize
+ reloc_type_.
+ (Dwarf_ranges_table::lookup_reloc): New function.
+ (Dwarf_ranges_table::reloc_type_): New data member.
+
+2013-06-27 Jing Yu <jingyu@google.com>
+
+ PR gold/15662
+ * powerpc.cc (Output_data_brlt_powerpc::reset_brlt_sizes): New
+ function.
+ (Output_data_brlt_powerpc::finalize_brlt_sizes): New function.
+ (Target_powerpc::do_relax): Call the above.
+
+2013-06-27 Cary Coutant <ccoutant@google.com>
+
+ * powerpc.cc (Target_powerpc::symval_for_branch): Don't assert
+ on garbage collected .opd section.
+
+2013-06-27 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::do_gc_add_reference): Test dst_shndx
+ is non-zero.
+ (Target_powerpc::do_gc_mark_symbols): Likewise for sym->shndx().
+ (Target_powerpc::do_function_location): Likewise for loc->shndx.
+
+2013-06-14 Cary Coutant <ccoutant@google.com>
+
+ * resolve.cc (Symbol::override_base): Don't override st_type
+ from plugin placeholder symbols.
+ (Symbol_table::resolve): Likewise.
+ (Symbol_table::should_override): Don't complain about TLS mismatch
+ if the TO symbol is a plugin placeholder.
+ * testsuite/Makefile.am (plugin_test_tls): New test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/plugin_test_tls.sh: New test script.
+ * testsuite/two_file_test_2_tls.cc: New test source.
+ * testsuite/two_file_test_tls.cc: New test source.
+
+2013-06-05 Alexander Ivchenko <alexander.ivchenko@intel.com>
+
+ * layout.cc (Layout::set_segment_offsets): Taking care of the case when
+ the maximum segment alignment is larger than the page size.
+ * testsuite/Makefile.am (large_symbol_alignment): Test that Gold
+ correctly aligns the symbols with large alignemnt.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/large_symbol_alignment.cc: New file.
+
+2013-05-30 Alexander Ivchenko <alexander.ivchenko@intel.com>
+ Sriraman Tallam <tmsriram@google.com>
+
+ * options.h (sort_section): New option.
+ * output.h (Input_section_sort_section_prefix_special_ordering_compare):
+ Rename from Input_section_sort_section_name_special_ordering_compare.
+ (Input_section_sort_section_name_compare): New struct.
+ * output.cc (Output_section::Input_section_sort_section_name_compare::
+ operator()): New function.
+ (Output_section::sort_attached_input_sections): Use new sort function
+ for .text if --sort-section=name is specified.
+ * layout.cc (Layout::make_output_section):
+ Add sorting by name when --sort-section=name is specified.
+ * testsuite/Makefile.am (text_section_grouping): Test option
+ --sort-section=name.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/section_sorting_name.cc: New file.
+ * testsuite/section_sorting_name.sh: New file.
+
+2013-05-21 Cary Coutant <ccoutant@google.com>
+
+ * symtab.h (Symbol::is_cxx_vtable): New function.
+ * target-reloc.h (relocate_section): Check for vtable symbol.
+ * testsuite/Makefile.am (missing_key_func.sh): New test case.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/missing_key_func.cc: New test source.
+ * testsuite/missing_key_func.sh: New test script.
+
+2013-05-21 Cary Coutant <ccoutant@google.com>
+
+ * object.cc (Sized_relobj_file::get_symbol_location_info): Set
+ type of enclosing symbol.
+ (Relocate_info::location): Check symbol type when describing symbol.
+ * object.h (Symbol_location_info): Remove unused line_number;
+ add enclosing_symbol_type.
+ * testsuite/debug_msg.sh: Adjust expected output.
+
+2013-05-13 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac: Export DEFAULT_TARGET.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * testsuite/Makefile.am: Add .EXPORT_ALL_VARIABLES.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/debug_msg.sh: Delete duplicate tests.
+ Don't check undef_int error message match for powerpc where the
+ source file and line number aren't available.
+
+2013-05-10 Roland McGrath <mcgrathr@google.com>
+
+ * options.h (General_options): Add --rosegment-gap option.
+ * options.cc (finalize): --rosegment-gap implies --rosegment.
+ * layout.cc (set_segment_offsets): Let user option override
+ target->rosegment_gap().
+
+2013-05-10 Roland McGrath <mcgrathr@google.com>
+
+ * options.h (General_options): Remove leading space from help
+ messages for -nostdlib and --rosegment.
+
+2013-05-03 Maciej W. Rozycki <macro@codesourcery.com>
+
+ PR ld/15365
+ * layout.cc (Layout::finalize): Make __ehdr_start STV_HIDDEN.
+
+2013-05-03 Alan Modra <amodra@gmail.com>
+
+ * merge.cc (Output_merge_string::do_add_input_section): Correct
+ scan for number of strings. Rename vars to avoid shadowing.
+ Include missing terminator in input_size_.
+
+2013-05-01 H.J. Lu <hongjiu.lu@intel.com>
+
+ * merge.cc (Output_merge_string<Char_type>::do_add_input_section):
+ Restore empty string handling.
+
+2013-05-01 Cary Coutant <ccoutant@google.com>
+
+ * stringpool.cc (Stringpool_template::new_key_offset): Fix
+ uninitialized warning.
+
+2013-04-29 Alexander Ivchenko <alexander.ivchenko@intel.com>
+
+ * output.cc (Output_section::add_merge_input_section): Allow
+ to merge sections if the alignment is more than character size.
+ * merge.h (Output_merge_string::Output_merge_string): Remove
+ assert.
+ * merge.cc (Output_merge_string<Char_type>::do_add_input_section): Count
+ only not-null strings. Check the alignment of strings.
+ * stringpool.h
+ (Stringpool_template<Stringpool_char>::Stringpool_template): Add
+ alignment as the argument.
+ (Stringpool_template<Stringpool_char>::addralign_): New class member.
+ * stringpool.cc (Stringpool_template<Stringpool_char>::new_key_offset):
+ Align non-zero length strings according to the addralign_.
+ (Stringpool_template<Stringpool_char>::set_string_offsets):
+ Updating offsets according to the given alignment.
+ * testsuite/Makefile.am (text_section_grouping): Test if string
+ literals are getting merged.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/merge_string_literals_1.c: New file.
+ * testsuite/merge_string_literals_2.c: Ditto.
+ * testsuite/merge_string_literals.sh: Ditto.
+
+2013-04-26 Ian Lance Taylor <iant@google.com>
+
+ * target-reloc.h (relocate_section): If the reloc offset is out of
+ range, pass VIEW as NULL to relocate.relocate.
+ * arm.cc (Target_arm:Relocate::relocate): Check for a NULL view.
+ * i386.cc (Target_i386::Relocate::relocate): Likewise.
+ * powerpc.cc (Target_powerpc::Relocate::relocate): Likewise.
+ * sparc.cc (Target_sparc::Relocate::relocate): Likewise.
+ * tilegx.cc (Target_tilegx::Relocate::relocate): Likewise.
+ * x86_64.cc (Target_x86_64::Relocate::relocate): Likewise.
+
+2013-04-26 Geoff Pike <gpike@chromium.org>
+
+ * gold.cc (queue_final_tasks): invoke layout->queue_build_id_tasks().
+ * layout.cc (Hash_task): New class.
+ (Layout::queue_build_id_tasks): New function.
+ (Layout::write_build_id): Handle single-thread portion of build ID
+ computation. (In some cases, all of it is single-threaded.) Replace
+ {sha1,md5}_process_bytes with {sha1,md5}_buffer to get the same
+ functionality in fewer lines of code.
+ * layout.h (Layout::queue_build_id_tasks): New function declaration.
+ * options.h (General_options): make "--build-id" default to tree
+ rather than sha1. Add two new options related to --build-id=tree:
+ --build-id-chunk-size-for-treehash and
+ --build-id-min-file-size-for-treehash.
+ * Makefile.am: add testing of --build-id=tree and related new options
+ (these tests will be invoked by "make check").
+ * Makefile.in: Regenerate.
+
+2013-04-25 Alan Modra <amodra@gmail.com>
+
+ * configure.tgt: Add powerpcle and powerpc64le.
+
+2013-04-22 Alan Modra <amodra@gmail.com>
+
+ PR gold/15355
+ * layout.cc (Layout::segment_precedes): Allow more than one
+ segment with the same type and flags.
+
+2013-04-15 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (Layout::set_relocatable_section_offsets): Don't
+ allocate space in file for BSS sections.
+
+2013-04-15 Cary Coutant <ccoutant@google.com>
+
+ * script-sections.cc (Orphan_output_section): Reset address
+ to zero after each orphaned section for relocatable links.
+
+2013-04-15 Cary Coutant <ccoutant@google.com>
+
+ * symtab.cc (Symbol_table::sized_write_globals): Subtract
+ section starting address for relocatable link.
+ * testsuite/Makefile.am (script_test_11): New test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/script_test_11.c: New source file.
+ * testsuite/script_test_11.t: New linker script.
+
+2013-04-13 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Stub_control::can_add_to_stub_group): Don't set
+ owner when sections are not adjacent and exceed group size.
+ (Target_powerpc::group_sections): Handle corner case.
+ (Target_powerpc::Branch_info::make_stub): Handle case where
+ stub table doesn't exist due to branches in non-exec sections.
+ (Target_powerpc::Relocate::relocate): Likewise.
+
+2013-04-11 Alan Modra <amodra@gmail.com>
+
+ PR gold/15354
+ * powerpc.cc (Target_powerpc::make_brlt_section): Name section
+ .branch_lt to match bfd ld. Adjust comments throughout file.
+
+2013-04-04 Ian Lance Taylor <iant@google.com>
+
+ GCC PR c++/56840
+ * object.cc (do_layout_deferred_sections): Handle .eh_frame
+ sections before checking whether they are included in the link.
+
+2013-03-29 Sriraman Tallam <tmsriram@google.com>
+
+ * archive.cc (Archive::get_elf_object_for_member): Create the elf
+ object before calling the plugin claim_file handler. Pass the elf
+ object of the archive to the plugin. Delete the elf object if the
+ plugin claims the file.
+
+2013-03-21 Alan Modra <amodra@gmail.com>
+
+ * layout.cc (Layout::set_segment_offsets): Accept writable .text
+ segment when omagic.
+
+2013-03-21 Alan Modra <amodra@gmail.com>
+
+ * dwp.cc (Dwp_output_file::add_contribution): Avoid signed/unsigned
+ comparison warning.
+ * layout.cc (Layout::create_dynamic_symtab): Avoid "may be used
+ uninitialized" warning.
+
+2013-03-20 Alan Modra <amodra@gmail.com>
+
+ * symtab.h (Symbol::clear_version): New function.
+ * symtab.cc (Symbol_table::set_dynsym_indexes): Don't set object
+ is_needed by weak references. Clear version for symbols defined
+ in as-needed objects that are not needed.
+
+2013-03-15 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::Scan::reloc_needs_plt_for_ifunc): Make
+ static and public. Add report_err param. Return false for data refs.
+ (Target_powerpc::rela_dyn_section): New overloaded function.
+ (Target_powerpc::plt_, iplt_): Elucidate.
+ (Output_data_plt_powerpc::entry_count): Handle current_data_size()==0.
+ (Output_data_plt_powerpc::do_write): Don't write .iplt.
+ (Output_data_plt_powerpc::plt_entry_count): Don't add .iplt entries.
+ (Target_powerpc::Scan::local, global): Adjust reloc_needs_plt_for_ifunc
+ calls. Put ifunc dynamic relocs in irela_dyn_section. Only
+ push_branch and make_plt_entry for ifunc syms when
+ reloc_needs_plt_for_ifunc.
+ (Target_powerpc::Relocate::relocate): Don't use plt entry value
+ for ifunc unless reloc_needs_plt_for_ifunc.
+
+2013-03-15 Alan Modra <amodra@gmail.com>
+
+ * gc.h (gc_process_relocs): Don't look through function descriptors.
+ * icf.cc (get_section_contents): Do so here instead.
+
+2013-03-13 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (is_branch_reloc): Forward declare.
+ (Target_powerpc::do_can_check_for_function_pointers): New predicate.
+ (Target_powerpc::Scan::local_reloc_may_be_function_pointer): Return
+ false for 64-bit, true for 32-bit non-branch relocs.
+ (Target_powerpc::Scan::global_reloc_may_be_function_pointer): Likewise.
+ * testsuite/Makefile.am (icf_test): Use linker map file instead of
+ nm output.
+ (icf_safe_test): Generate linker map file as well as nm output.
+ (icf_safe_so_test): Likewise.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/icf_test.sh: Parse linker map file to determine
+ section folding.
+ * testsuite/icf_safe_test.sh: Likewise. Expect folding for PowerPC.
+ * testsuite/icf_safe_so_test.sh: Likewise.
+ (X86_32_or_ARM_specific_safe_fold): Merge into..
+ (arch_specific_safe_fold): ..this.
+ (X86_64_specific_safe_fold): Delete unused function.
+
+2013-03-12 Alan Modra <amodra@gmail.com>
+
+ * gc.h (gc_process_relocs): Look through function descriptors
+ to determine shndx, symvalue and addend used by ICF. Tidy
+ variable duplication.
+
+2013-03-11 Alan Modra <amodra@gmail.com>
+
+ * gold.cc (queue_middle_tasks): Move detect_odr_violations..
+ * layout.cc (Layout_task_runner::run): ..to here.
+ * symtab.h (struct Symbol_location): Extract from..
+ (class Symbol_table): ..here.
+ * symtab.cc (Symbol_table::linenos_from_loc): Invoke function_location.
+ * target.h (class Target): Add function_location and
+ do_function_location functions.
+ (class Sized_target): Add do_function_location.
+ * object.h (class Sized_relobj_file): Move find_shdr..
+ (class Object): ..to here.
+ * object.cc: Likewise. Update to suit. Instantiate.
+ (Sized_relobj_file::find_eh_frame): Update find_shdr call.
+ * powerpc.cc (class Powerpc_dynobj): New.
+ (Target_powerpc::do_function_location): New function.
+ (Powerpc_relobj::do_find_special_sections): Update find_shdr call.
+ (Powerpc_dynobj::do_read_symbols): New function.
+ (Target_powerpc::do_make_elf_object): Make a Powerpc_dynobj.
+
+2013-03-08 Ian Lance Taylor <iant@google.com>
+
+ * options.cc (General_options::string_to_object_format): Accept
+ "default".
+
+2013-03-08 Alan Modra <amodra@gmail.com>
+
+ * ehframe.h (Post_fdes) Make it a vector of Post_fde rather than
+ pointer to Post_fde.
+ (struct Post_fde): Move definition to here..
+ * ehframe.cc (struct Post_fde): ..from here.
+ (Cie::write): Don't alloc Post_fde.
+ (Eh_frame::do_sized_write): Update. Don't free Post_fde.
+
+2013-03-07 Alan Modra <amodra@gmail.com>
+
+ * testsuite/discard_locals_relocatable_test.c: Add a powerpc
+ relocation referencing .LC0.
+ * testsuite/discard_locals_test.sh: Remove FIXMEs.
+
+2013-03-07 Alan Modra <amodra@gmail.com>
+
+ * testsuite/ifunc-sel.h (ifunc_sel, ifunc_one): Mark
+ always_inline. Add assembly for powerpc to avoid GOT.
+
+2013-03-07 Alan Modra <amodra@gmail.com>
+
+ * testsuite/script_test_10.sh: Don't test .bss section
+ header number.
+
+2013-03-06 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (class Powerpc_relobj): Move some member functions.
+ (Target_powerpc::symval_for_branch): Add symtab param. Update
+ all callers. Handle folded sections.
+ (Target_powerpc::do_gc_add_reference): Don't cast dynamic object
+ to Powerpc_relobj.
+ (Global_symbol_visitor_opd::operator()): Likewise.
+
+2013-03-04 Alan Modra <amodra@gmail.com>
+
+ * testsuite/Makefile.am (final_layout_script.lds): Add .sbss.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-03-01 Cary Coutant <ccoutant@google.com>
+
+ Add dwp support for v2 DWARF package file format.
+ * dwarf_reader.cc (Dwarf_info_reader::visit_type_unit): Add
+ tu_length parameter. Adjust all callers.
+ * dwarf_reader.h (Dwarf_info_reader::visit_type_unit): Likewise.
+ * dwp.cc: Include dwarf.h.
+ (Section_bounds): New struct type.
+ (Unit_set): New struct type.
+ (Dwo_file::Dwo_file): Initialize new data member.
+ (Dwo_file::read_compunit_index, Dwo_file::read_typeunit_index):
+ Combine and rename to...
+ (Dwo_file::read_unit_index): ...this.
+ (Dwo_file::sized_read_compunit_index)
+ (Dwo_file::sized_read_typeunit_index): Combine and rename to...
+ (Dwo_file::sized_read_unit_index): ...this.
+ (Dwo_file::copy_section): Remove section_name, is_str_offsets
+ parameters; add section_id parameter.
+ (Dwo_file::add_cu_set, Dwo_file::add_tu_set): Combine and rename to...
+ (Dwo_file::add_unit_set): ...this.
+ (Dwo_file::shndx_map_): Remove.
+ (Dwo_file::sect_offsets_): New data member.
+ (Dwp_output_file::Dwp_output_file): Initialize new data members.
+ (Dwp_output_file::add_section): Rename to...
+ (Dwp_output_file::add_contribution): ...this.
+ (Dwp_output_file::add_cu_set): Combine parameters into a struct.
+ (Dwp_output_file::add_tu_set): Likewise.
+ (Dwp_output_file::Contribution): New type.
+ (Dwp_output_file::Section::contributions): New data member.
+ (Dwp_output_file::Cu_or_tu_set): Remove.
+ (Dwp_output_file::Section::Section): New ctor.
+ (Dwp_output_file::Dwp_index::Shndx_pool): Remove.
+ (Dwp_output_file::Dwp_index::Section_table): New type.
+ (Dwp_output_file::Dwp_index::Dwp_index): Initialize new data members.
+ (Dwp_output_file::Dwp_index::enter_set): Change type of "set"
+ parameter.
+ (Dwp_output_file::Dwp_index::shndx_pool): Remove.
+ (Dwp_output_file::Dwp_index::shndx_pool_end): Remove.
+ (Dwp_output_file::Dwp_index::section_table): New member function.
+ (Dwp_output_file::Dwp_index::section_table_end): New member function.
+ (Dwp_output_file::Dwp_index::shndx_pool_size): Remove.
+ (Dwp_output_file::Dwp_index::section_table_rows): New member function.
+ (Dwp_output_file::Dwp_index::section_table_cols): New member function.
+ (Dwp_output_file::Dwp_index::shndx_pool_): Remove.
+ (Dwp_output_file::Dwp_index::section_table_): New data member.
+ (Dwp_output_file::Dwp_index::section_mask_): New data member.
+ (Dwp_output_file::add_output_section): New member function.
+ (Dwp_output_file::write_new_section): New member function.
+ (Dwp_output_file::write_contributions): New member function.
+ (Dwp_output_file::section_id_map_): New data member.
+ (class Dwo_id_info_reader): Remove.
+ (class Unit_reader): New class.
+ (get_dwarf_section_name): New function.
+ (Dwo_file::read_executable): Adjust initializations of class data.
+ (Dwo_file::read): Add support for v2 package file format.
+ (Dwo_file::read_unit_index): Likewise.
+ (Dwo_file::sized_read_unit_index): Likewise.
+ (Dwo_file::copy_section): Likewise.
+ (Dwo_file::add_unit_set): Likewise.
+ (Dwp_output_file::add_output_section): Likewise.
+ (Dwp_output_file::add_contribution): Likewise.
+ (Dwp_output_file::Dwp_index::find_or_add): Use row index to check
+ for empty slot.
+ (Dwp_output_file::Dwp_index::enter_set): Add support for v2 package
+ file format.
+ (Dwp_output_file::Dwp_index::grow): Use row index to check for empty
+ slot.
+ (Dwp_output_file::initialize): Remove unused function.
+ (Dwp_output_file::finalize): Add support for v2 package file format.
+ (Dwp_output_file::write_index): Likewise.
+ * gdb-index.cc (Gdb_index_info_reader::visit_type_unit): Adjust
+ function prototype.
+
+2013-03-01 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_info_reader::check_buffer): Move
+ function into class definition in header file.
+ (Dwarf_info_reader::warn_corrupt_debug_section): New function.
+ * dwarf_reader.h (Dwarf_info_reader::warn_corrupt_debug_section):
+ New function.
+ (Dwarf_info_reader::check_buffer): Move here from .cc file.
+
+2013-02-28 Alan Modra <amodra@gmail.com>
+
+ * target.h (Target::plt_fde_location, do_plt_fde_location): Declare.
+ * target.cc (Target::do_plt_fde_location): New function.
+ * ehframe.h (class FDE): Add post_map field to u_.from_linker,
+ accessor function, and constructor param.
+ (struct Post_fde, Post_fdes): Declare.
+ (Cie::write): Add post_fdes param.
+ * ehframe.cc (Fde::write): Use plt_fde_location.
+ (struct Post_fde): Define.
+ (Cie::write): Stash FDEs added post merge mapping.
+ (Eh_frame::add_ehframe_for_plt): Assert no new CIEs after mapping.
+ Adjust Fde constructor call. Bump final_data_size_ for post map FDEs.
+ (Eh_frame::do_sized_write): Arrange to write post map FDES after
+ other FDEs.
+ * powerpc.cc (Target_powerpc::do_plt_fde_location): New function.
+ (Target_powerpc::has_glink): New function.
+ (Target_powerpc::do_relax): Add eh_frame info for stubs.
+ (struct Eh_cie, eh_frame_cie, glink_eh_frame_fde_64,
+ glink_eh_frame_fde_32, default_fde): New data.
+ (Stub_table::eh_frame_added_): New var.
+ (Stub_table::find_long_branch_entry, stub_address, stub_offset):
+ Make const.
+ (Stub_table::add_eh_frame): New function.
+ (Output_data_glink::add_eh_frame): New function.
+ (Target_powerpc::make_glink_section): Call add_eh_frame.
+
+2013-02-15 Ian Lance Taylor <iant@google.com>
+
+ * options.h (DEFINE_uint64_alias): Define.
+ (class General_options): Add -Ttext-segment as an alias for
+ -Ttext.
+
+2013-02-15 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Stub_table::plt_off): New function, extracted from..
+ (Stub_table::do_write): ..here, two places.
+ (Stub_table::plt_call_size): Use it here too.
+
+2013-02-11 Ian Lance Taylor <iant@google.com>
+
+ * descriptors.cc (Descriptors::close_all): New function.
+ * descriptors.h (class Descriptors): Declare close_all.
+ (close_all_descriptors): New inline function.
+ * plugin.cc: Include "descriptors.h".
+ (Plugin_manager::cleanup): Call close_all_descriptors.
+
+2013-02-06 Alan Modra <amodra@gmail.com>
+
+ * README: Update coding style link.
+
+2013-01-28 Cary Coutant <ccoutant@google.com>
+
+ * dwp.cc (File_list): New typedef.
+ (Dwo_name_info_reader): New class.
+ (Dwo_id_info_reader::Dwo_id_info_reader): Remove unused parameters.
+ (Dwo_id_info_reader::visit_top_die): Remove unused member function.
+ (Dwo_file::~Dwo_file): Delete input_file_ after obj_.
+ (Dwo_file::read_executable): New function.
+ (Dwo_file::read): Move common setup code to ...
+ (Dwo_file::make_object): ... here.
+ (dwp_options): Add --exec/-e.
+ (usage): Likewise.
+ (main): Likewise.
+
+2013-01-24 Sriraman Tallam <tmsriram@google.com>
+
+ * layout.cc (Layout::layout): Check for option text_reorder.
+ (Layout::make_output_section): Ditto.
+ * options.h (text_reorder): New option.
+ * output.cc (Input_section_sort_compare): Remove special ordering
+ of section names.
+ (Output_section::
+ Input_section_sort_section_name_special_ordering_compare::
+ operator()): New function.
+ (Output_section::sort_attached_input_sections): Use new sort function
+ for .text.
+ * output.h (Input_section_sort_section_name_special_ordering_compare):
+ New struct.
+ * testsuite/Makefile.am (text_section_grouping): Test option
+ --no-text-reorder
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/text_section_grouping.sh: Check order of functions without
+ default text reordering.
+
+2013-01-18 Mike Frysinger <vapier@gentoo.org>
+
+ * options.h (General_options): Change default to true for new_dtags.
+
+2013-01-18 Mike Frysinger <vapier@gentoo.org>
+
+ * layout.cc (Layout::finish_dynamic_section): Only add DT_RPATH
+ when enable_new_dtags is false. Only add DT_RUNPATH when
+ enable_new_dtags is true.
+
+2013-01-17 Serge Pavlov <serge.v.pavlov@gmail.com>
+
+ * powerpc.cc (Stub_table::find_plt_call_entry): Make types
+ used in declaration and definition consistent.
+ (Target_powerpc::symval_for_branch): Ditto.
+
+2013-01-16 Sriraman Tallam <tmsriram@google.com>
+
+ * testsuite/plugin_final_layout.cc: Fix comment.
+
+2013-01-16 Sriraman Tallam <tmsriram@google.com>
+
+ * layout.cc (Layout::layout): Do not do default sorting for
+ text sections when section ordering is specified.
+ (make_output_section): Ditto.
+ * testsuite/plugin_final_layout.cc: Name the function sections
+ to catch reordering issues.
+
+2013-01-15 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::do_relax): Default shared libs to
+ plt-thread-safe.
+
+2013-01-15 Alan Modra <amodra@gmail.com>
+
+ * testsuite/Makefile.am (final_layout_script.lds): Handle .got section.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-01-14 Alan Modra <amodra@gmail.com>
+
+ * testsuite/Makefile.am (MOSTLYCLEANFILES): Add various output files.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-01-11 Pavel Chupin <pavel.v.chupin@intel.com>
+
+ PR bfd/14430
+ Fix mingw gold build with plugins enabled
+ * Makefile.am: Replace -ldl with @DLOPEN_LIBS@.
+ * configure.ac: Export DLOPEN_LIBS and add headers check.
+ * plugin.cc: Handle non-dlfcn case.
+ * Makefile.in: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-01-09 Sriraman Tallam <tmsriram@google.com>
+
+ * output.h (sort_attached_input_sections): Change to be public.
+ * script-sections.cc
+ (Output_section_definition::set_section_addresses): Sort
+ attached input sections according to section order before linker
+ script assigns section addresses.
+ (Orphan_output_section::set_section_addresses): Sort
+ attached input sections according to section order before linker
+ script assigns section addresses.
+ * Makefile.am (final_layout.sh): Use a simple linker script to
+ check if section ordering still works.
+ * Makefile.in: Regenerate.
+
+2013-01-09 Ben Cheng <bccheng@google.com>
+
+ * arm.cc (Target_arm::attributes_accept_div): New function.
+ (Target_arm::attributes_forbid_div): New function.
+ (Target_arm::merge_object_attributes): Merge the Tag_DIV_use
+ attribute using the same new functions as what bfd/elf32_arm.c
+ does.
+
+2013-01-07 Cary Coutant <ccoutant@google.com>
+
+ PR gold/14993
+ * output.cc (Output_section::add_input_section): For incremental
+ updates, don't track input sections that are allocated from patch
+ space.
+
+2013-01-07 H.J. Lu <hongjiu.lu@intel.com>
+ Ian Lance Taylor <iant@google.com>
+
+ PR gold/14897
+ * configure.ac (--enable-ld): Removed.
+ (install_as_default): Set to yes only for --enable-gold=default
+ or --disable-ld.
+ * configure: Regenerated.
+
+2013-01-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * options.h (General_options): Add -fuse-ld= for GCC linker
+ option compatibility.
+
+2013-01-04 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac: Fix typo restoring CXXFLAGS.
+ * configure: Regenerate.
+
+2013-01-04 Cary Coutant <ccoutant@google.com>
+
+ * testsuite/Makefile.am (CXXLINK_S): New macro.
+ (debug_msg_so.err, debug_msg_ndebug.err): Use CXXLINK_S.
+ * testsuite/Makefile.in: Regenerate.
+
+2013-01-02 H.J. Lu <hongjiu.lu@intel.com>
+
+ * version.cc (print_version): Update copyright year to 2013.
+
+2012-12-20 Ian Lance Taylor <iant@google.com>
+
+ * layout.cc (Layout::special_ordering_of_input_section): New
+ function.
+ (Layout::layout): If input section requires special ordering, must
+ sort input sections.
+ (Layout::make_output_section): May sort .text input sections.
+ (Layout::is_section_name_prefix_grouped): Remove.
+ * layout.h (class Layout): Declare
+ special_ordering_of_input_section. Don't declare
+ is_section_name_prefix_grouped.
+ * output.cc (Output_section::add_input_section): Revert last
+ change.
+ (Output_section::Input_section_sort::match_file_name): Don't crash
+ if called on output section data.
+ (Output_section::Input_section_sort_compare): Sort based on
+ special ordering.
+ (Output_section::Input_section_sort_section_order_index_compare):
+ Revert last patch.
+ (Output_section::sort_attached_input_sections): Likewise.
+
+2012-12-18 Sriraman Tallam <tmsriram@google.com>
+
+ * layout.cc (Layout::is_section_name_prefix_grouped): New function.
+ * layout.h (Layout::is_section_name_prefix_grouped): New function.
+ * output.cc (Output_section::add_input_section): Check if section
+ name contains special prefix. Keep input sections to sort such
+ sections.
+ (Output_section::Input_section_sort_section_order_index_compare
+ ::operator()): Group sections according to prefixes.
+ (Output_section::sort_attached_input_sections): Add condition to
+ Input_section_entry constructor call.
+ * testsuite/Makefile.am (text_section_grouping): New test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/text_section_grouping.cc: New file.
+ * testsuite/text_section_grouping.sh: New file.
+
+2012-12-17 Nick Clifton <nickc@redhat.com>
+
+ * Makefile.am: Add copyright notice.
+ * NEWS: Likewise.
+ * README: Likewise.
+ * configure.ac: Likewise.
+ * ftruncate.c: Likewise.
+ * Makefile.in: Regenerate.
+
+2012-12-14 Cary Coutant <ccoutant@google.com>
+
+ * testsuite/Makefile.am (exception_separate_shared_12_test): Add
+ --no-as-needed flag.
+ (exception_separate_shared_12_test): Likewise.
+ (incremental_copy_test): Likewise.
+ * testsuite/Makefile.in: Regenerate.
+
+2012-12-14 Cary Coutant <ccoutant@google.com>
+
+ * dwp.cc (Dwp_output_file::add_cu_set): Check for duplicate CUs.
+ (Dwp_output_file::Dwp_index::enter_set): Add assert.
+
+2012-12-12 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (class Track_tls): New.
+ (class Relocate, class Scan): Inherit Track_tls.
+ (Target_powerpc::Scan::local, global): Track tls optimization
+ and avoid creating plt entry for __tls_get_addr if all uses
+ are optimized away.
+ (Target_powerpc::Relocate::relocate): Update to use Track_tls.
+
+2012-12-12 Alan Modra <amodra@gmail.com>
+
+ * options.h (General_options): Add --toc-sort/--no-toc-sort.
+ Replace no_toc_optimize with toc_optimize.
+ * output.h (Output_section::input_sections): Provide non-const variant.
+ * powerpc.cc (Powerpc_relobj::has_small_toc_reloc_,
+ set_has_small_toc_reloc, has_small_toc_reloc): New variable and
+ accessors.
+ (Target_powerpc::Scan::local, global): Call set_has_small_toc_reloc.
+ (class Sort_toc_sections): New.
+ (Target_powerpc::do_finalize_sections): Sort toc sections.
+ (Target_powerpc::Relocate::relocate): Update toc_optimize test.
+
+2012-12-10 Roland McGrath <mcgrathr@google.com>
+
+ * testsuite/binary_unittest.cc (read_all): New function.
+ (Sized_binary_test): Use it instead of ::read.
+ * fileread.cc (do_read): Don't assume pread always reads the whole
+ amount in a single call.
+
+2012-12-10 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_selector_powerpc::Target_selector_powerpc):
+ Set EM_PPC64 or EM_PPC here.
+ (Target_selector_powerpc::do_recognize): Delete.
+
+2012-12-10 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::Powerpc_relobj): Init has14_ and
+ stub_table_.
+ (Target_powerpc::Branch_info::make_stub): Don't omit addend.
+
+2012-12-07 Roland McGrath <mcgrathr@google.com>
+
+ * testsuite/binary_unittest.cc (Sized_binary_test):
+ Use open_descriptor rather than ::open.
+
+2012-12-07 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Stub_table::do_write): Delete redundant Address
+ typedef and invalid_address constant.
+ (Output_data_glink, Stub_table, Target_powerpc): Explicitly
+ instantiate constants.
+
+2012-12-06 Roland McGrath <mcgrathr@google.com>
+
+ * configure.ac (HAVE_ZLIB): Use AM_ZLIB instead of AC_SEARCH_LIBS.
+ Use $ac_cv_header_zlib_h = yes as the condition in AM_CONDITIONAL.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * testsuite/Makefile.in: Regenerate.
+
+2012-12-07 Alan Modra <amodra@gmail.com>
+
+ * options.h (General_options): Add no_toc_optimize.
+ * powerpc.cc (ok_lo_toc_insn): New function.
+ (Target_powerpc::Relocate::relocate): Optimize toc access sequences.
+
+2012-12-06 Alan Modra <amodra@gmail.com>
+
+ * options.h (General_options): Add plt_align, plt_static_chain,
+ plt_thread_safe. Update stub_group_size help text.
+ * powerpc.cc (Target_powerpc::plt_thread_safe): New access function
+ for new plt_thread_safe_ var.
+ (use_plt_offset): Correct comments.
+ (Target_powerpc::do_relax): Look for thread creation symbols to
+ determine default plt_thread_safe value. Clear plt call stubs
+ as well as branch stubs each iteration.
+ (add_2_2_11, add_12_12_11, bnectr_p4, cmpldi_2_0, xor_11_11_11): New
+ insn constants.
+ (l, hi, ha, write_insn): Move earlier.
+ (Stub_table): Delete prev_size, add last_plt_size and last_branch_size.
+ (Stub_table::clear_stubs): Rename from clear_long_branch_stubs, clear
+ plt stubs too.
+ (Stub_table::update_size): Adjust.
+ (Stub_table::prev_size, set_prev_size): Delete.
+ (Stub_table::stub_align): Let --plt-align affect result.
+ (Stub_table::plt_call_size): Calculate sizes for various stubs.
+ (Stub_table::branch_stub_size): Use last_plt_size in address calc.
+ (Stub_table::add_plt_call_stub): Pass iterator to plt_call_size.
+ (Stub_table::do_write): Support more stub variants.
+
+2012-12-04 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::do_scan_relocs): Delete.
+ (Target_powerpc::do_define_standard_symbols): New function.
+
+2012-12-03 Alan Modra <amodra@gmail.com>
+
+ * output.h: Formatting, whitespace.
+
+2012-12-03 Alan Modra <amodra@gmail.com>
+
+ * layout.h (Layout::get_executable_sections): Declare.
+ * layout.cc (Layout::get_executable_sections): New function.
+ * arm.cc (Target_arm::group_sections): Use it.
+ (Arm_output_section::group_sections): Delete now redundant test.
+ * output.cc (Output_reloc::Output_reloc): Add is_relative.
+ param to handle relative relocs.
+ * output.h (Output_reloc::Output_reloc <absolute reloc>): Likewise.
+ (Output_data_reloc::add_absolute): Adjust.
+ (Output_data_reloc::add_relative): New function.
+ (Output_data::reset_data_size): New function.
+ (Output_relaxed_input_section::set_relobj, set_shndx): New functions.
+ (Output_section::set_addralign): New function.
+ (Output_section::checkpoint_set_addralign): New function.
+ (Output_section::clear_section_offsets_need_adjustment): New function.
+ (Output_section::input_sections): Make public.
+ * powerpc.cc (class Output_data_brlt_powerpc): New.
+ (class Stub_table, class Stub_control): New.
+ (Powerpc_relobj::has14_, set_has_14bit_branch, has_14bit_branch,
+ stub_table_, set_stub_table, stub_table): New vectors and accessor
+ functions.
+ (Target_powerpc::do_may_relax, do_relax, push_branch,
+ new_stub_table, stub_tables, brlt_section, group_sections,
+ add_branch_lookup_table, find_branch_lookup_table,
+ write_branch_lookup_table, make_brlt_section): New functions.
+ (Target_powerpc::struct Sort_sections, class Branch_info): New.
+ (Target_powerpc::brlt_section_, stub_tables_, branch_lookup_table_,
+ branch_info_): New vars.
+ (Target_powerpc::make_plt_entry, make_local_ifunc_plt_entry): Don't
+ make call stubs here.
+ (Output_data_glink): Remove all call stub handling from this class.
+ (Target_powerpc::Scan::local, global): Save interesting branch
+ relocs and relocs for ifunc. Adjust calls to plt entry functions.
+ (Target_powerpc::do_finalize_sections): Only make reg save/restore
+ functions on final link.
+ (Target_powerpc::Relocate::relocate): Adjust lookup of call stubs.
+ Handle long branch destinations too.
+ (Target_powerpc::do_dynsym_value, do_plt_address_for_global,
+ do_plt_address_for_local): Adjust lookup of plt call stubs.
+
+2012-11-30 Alan Modra <amodra@gmail.com>
+
+ * powerpc.c (Target_powerpc::Scan::global): Don't emit relative
+ relocs against protected symbols when building 32-bit shared libs.
+
+2012-11-30 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::make_plt_section): Add symtab
+ param. Call got_section() to make .got. Update all callers
+ and their callers and so on.
+
+2012-11-30 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::do_scan_relocs): Make STB_LOCAL
+ _GLOBAL_OFFSET_TABLE_ rather than STB_WEAK.
+ (Output_data_got_powerpc::make_header): Update _GLOBAL_OFFSET_TABLE_
+ value if it already exists.
+
+2012-11-19 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR gold/14858
+ * x86_64.cc (Relocate::tls_ld_to_le): Support x32.
+
+2012-11-14 Roland McGrath <mcgrathr@google.com>
+
+ * arm.cc (Output_data_plt_arm_nacl::first_plt_entry): Use bic rather
+ than bfc instruction for data sandboxing.
+
+2012-11-08 Alan Modra <amodra@gmail.com>
+
+ * po/POTFILES.in: Regenerate.
+
+2012-11-05 Alan Modra <amodra@gmail.com>
+
+ * configure.ac: Apply 2012-09-10 change to config.in here.
+ * configure: Regenerate.
+
+2012-11-05 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj): Delete "Offset" typedef.
+ (struct Opd_ent): Use "Address" rather than "Offset".
+ (Output_data_got_powerpc::got_base_offset): Return Valtype.
+ (Target_powerpc::got_section): Make public.
+ (Target_powerpc::scan_relocs): Move code setting symbols..
+ (Powerpc_relobj::do_scan_relocs): ..to here, new function.
+ Create _SDA_BASE_ only when referenced.
+
+2012-11-02 Roland McGrath <mcgrathr@google.com>
+
+ * i386.cc (Target_i386::relocate_relocs): Remove extraneous typename
+ from last change.
+
+2012-11-01 Roland McGrath <mcgrathr@google.com>
+
+ * target.h (Sized_target::relocate_relocs): Use Elf_Off
+ for offset_in_output_section parameter.
+ (Sized_target::relocate_special_relocatable): Likewise.
+ * arm.cc (Target_arm::relocate_relocs): Likewise.
+ (Target_arm::relocate_special_relocatable): Likewise.
+ * i386.cc (Target_i386::relocate_relocs): Likewise.
+ * powerpc.cc (Target_powerpc::relocate_relocs): Likewise.
+ * sparc.cc (Target_sparc::relocate_relocs): Likewise.
+ * target-reloc.h (relocate_relocs): Likewise.
+ * testsuite/testfile.cc (Target_test): Likewise.
+ * tilegx.cc (Target_tilegx::relocate_relocs): Likewise.
+ * x86_64.cc (Target_x86_64::relocate_relocs): Likewise.
+
+ * system.h: Move inclusion of <clocale> to after <libintl.h> in
+ [ENABLE_NLS] section, and separately at top of [!ENABLE_NLS] section.
+
+ * descriptors.cc (set_close_on_exec): Add ATTRIBUTE_UNUSED to the
+ parameter, which is unused in the [!F_SETFD] case.
+
+ * dwarf_reader.cc (Sized_elf_reloc_mapper::symbol_section): Cast
+ SYMNDX to off_t before comparing it to this->data_size().
+ * output.cc (Output_symtab_xindex::endian_do_write): Likewise.
+ * incremental.cc (Output_section_incremental_inputs::do_write):
+ Cast GLOBAL_SYM_COUNT to off_t before comparing it to SYMTAB_SIZE.
+
+ * nacl.cc: Include "libiberty.h" for vasprintf declaration.
+
+2012-10-30 Steve McIntyre <steve.mcintyre@linaro.org>
+
+ * gold.cc (Target_arm::do_adjust_elf_header): Add the
+ hard-float/soft-float ABI flag as appropriate for ET_DYN/ET_EXEC
+ in EABI_VER5.
+
+2012-10-29 Cary Coutant <ccoutant@google.com>
+
+ * dwp.cc (usage): Add file and exit status parameters;
+ add --help and --version options.
+ (print_version): New function.
+ (main): Add --help and --version options.
+
+2012-10-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/Makefile.am (MOSTLYCLEANFILES): Add
+ final_layout_sequence.txt.
+ * testsuite/Makefile.in: Regenerated.
+
+2012-10-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/Makefile.am (COMPILE1): New variable. Renamed from
+ COMPILE generated by automake.
+ (LINK1): Likewise.
+ (CXXCOMPILE1): Likewise.
+ (CXXLINK1): Likewise.
+ (COMPILE): Strip out -Wp,-D_FORTIFY_SOURCE= from COMPILE1.
+ (LINK): Likewise.
+ (CXXCOMPILE): Likewise.
+ (CXXLINK): Likewise.
+ * testsuite/Makefile.in: Regenerated.
+
+2012-10-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * dwp.cc (Dwo_file::record_target_info): Issue a fatal error
+ on bad fwrite return.
+
+2012-10-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * dwp.cc (Dwo_file::remap_str_offset): Use section_offset_type
+ on val.
+
+2012-10-23 Cary Coutant <ccoutant@google.com>
+
+ * testsuite/Makefile.am (TEST_OBJCOPY): New macro.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/dwp_test.h: New source file.
+ * testsuite/dwp_test_1.cc: New source file.
+ * testsuite/dwp_test_1.s: New source file.
+ * testsuite/dwp_test_1.sh: New source file.
+ * testsuite/dwp_test_1b.cc: New source file.
+ * testsuite/dwp_test_1b.s: New source file.
+ * testsuite/dwp_test_2.cc: New source file.
+ * testsuite/dwp_test_2.s: New source file.
+ * testsuite/dwp_test_2.sh: New source file.
+ * testsuite/dwp_test_main.cc: New source file.
+ * testsuite/dwp_test_main.s: New source file.
+
+2012-10-23 Cary Coutant <ccoutant@google.com>
+
+ * dwp.h: New header file.
+ * dwp.cc: New source file.
+ * gold.h: Move shared declarations to system.h.
+ * system.h: New header file.
+ * Makefile.am: Add dwp.
+ * Makefile.in: Regenerate.
+
+2012-10-23 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_ranges_table::read_range_list): Call
+ Dwarf_info_reader::read_from_pointer.
+ (Dwarf_pubnames_table::read_header): Likewise.
+ (Dwarf_pubnames_table::next_name): Likewise.
+ (Dwarf_die::read_attributes): Likewise.
+ (Dwarf_die::skip_attributes): Likewise.
+ (Dwarf_info_reader::read_from_pointer): New function template.
+ * dwarf_reader.h (Dwarf_ranges_table): Add dwinfo_.
+ (Dwarf_pubnames_table): Likewise.
+ (Dwarf_info_reader::read_from_pointer): New function template.
+ * gdb-index.cc (Gdb_index_info_reader): Adjust call to
+ Dwarf_pubnames_table ctor.
+
+2012-10-23 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_info_reader::do_parse): Use stored
+ abbrev_shndx.
+ * dwarf_reader.h (Dwarf_info_reader::Dwarf_info_reader): Initialize
+ abbrev_shndx_.
+ (Dwarf_info_reader::set_abbrev_shndx): New method.
+ (Dwarf_info_reader::abbrev_shndx_): New data member.
+
+2012-10-23 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (make_elf_reloc_mapper): Check size and endianness
+ from object, not parameters.
+ (Dwarf_info_reader::parse): Likewise.
+ * object.h (Relobj::elfsize, Relobj::is_big_endian): New methods.
+ (Relobj::do_elfsize, Relobj::do_is_big_endian): New methods.
+ (Sized_relobj::do_elfsize, Sized_relobj::do_is_big_endian): New
+ methods.
+
+2012-10-23 Cary Coutant <ccoutant@google.com>
+
+ * fileread.cc (Input_file::Input_file): New constructor.
+ * fileread.h (class Input_file): Add new constructor.
+
+2012-10-18 Alan Modra <amodra@gmail.com>
+
+ PR gold/14727
+ * object.cc (Relobj::is_section_name_included): Also match
+ .sdata personality section.
+
+2012-10-18 Alan Modra <amodra@gmail.com>
+
+ * target-reloc.h (class Default_comdat_behavior): New, package up..
+ (get_comdat_behaviour): ..this.
+ (relocate_section): Add Relocate_comdat_behavior template arg,
+ adjust code to suit.
+ * arm.cc (Target_arm::relocate_section): Adjust to suit.
+ (Target_arm::scan_reloc_section): Likewise.
+ * i386.cc (Target_i386::relocate_section): Likewise.
+ * sparc.cc (Target_sparc::relocate_section): Likewise.
+ * tilegx.cc (Target_tilegx::relocate_section): Likewise.
+ * x86_64.cc (Target_x86_64::relocate_section): Likewise.
+ * powerpc.cc (class Relocate_comdat_behavior): New.
+ (Target_powerpc::relocate_section): Don't zap opd relocs. Supply
+ gold::relocate_section with new template arg.
+
+2012-10-18 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::Scan::local, global): Always emit
+ dynamic relocs for GOT_TPREL got entries, without symbol if
+ resolving locally.
+ (Target_powerpc::do_gc_add_reference): Don't add for dynamic objects.
+ (Target_powerpc::scan_relocs): Define _GLOBAL_OFFSET_TABLE_ early.
+ (Target_powerpc::Relocate:relocate): REL32 reloc may be unaligned.
+
+2012-10-17 Alan Modra <amodra@gmail.com>
+
+ PR gold/14726
+ * gold.cc (queue_middle_tasks): Call gc_mark_symbol on _init and _fini.
+
+2012-10-16 Sriraman Tallam <tmsriram@google.com>
+
+ * layout.cc (Layout::include_section): Keep sections marked
+ SHF_EXCLUDE when doing relocatable links.
+
+2012-10-16 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::define_save_restore_funcs): New func.
+ (Target_powerpc::do_finalize_sections): Call it.
+ (Output_data_save_res): New class and supporting functions.
+ (Target_powerpc::symval_for_branch): Only look up .opd entry for
+ normal symbols defined in object files.
+
+2012-10-12 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::add_gc_mark, process_gc_mark): New.
+ (struct Opd_ent): Make "discard" a bit field. Add "gc_mark".
+ (Target_powerpc::do_gc_mark_symbol): Delay marking function code
+ section if scan_opd_relocs not yet called.
+ (Target_powerpc::gc_process_relocs): Call process_gc_mark.
+
+2012-10-12 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Output_data_plt_powerpc::add_entry, add_ifunc_entry,
+ add_local_ifunc_entry): Revert last change.
+ (Target_powerpc::make_plt_entry, make_local_ifunc_plt_entry): Likewise.
+
+2012-10-05 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::do_plt_address_for_local,
+ do_plt_address_for_global): New functions.
+ (Output_data_got_powerpc::do_write): Don't segfault when linking
+ statically.
+ (Output_data_plt_powerpc::add_entry, add_ifunc_entry,
+ add_local_ifunc_entry): Return true on adding entry..
+ (Target_powerpc::make_plt_entry): ..use to avoid unnecessary
+ glink->add_entry call. Remove unused symtab param. Adjust calls.
+ (Target_powerpc::make_local_ifunc_plt_entry): Likewise.
+ (Target_powerpc::make_iplt_section): Remove symtab param. Don't
+ set up symbols here.
+ (Target_powerpc::do_finalize_sections): Instead set up __rela_iplt
+ syms here. Do so even when no .iplt. Don't segfault when linking
+ statically.
+ (Output_data_glink::add_entry, find_entry): Rearrange params. Add
+ new variants without reloc param.
+ (Glink_sym_ent::Glink_sym_ent): Likewise.
+ (Target_powerpc::Scan::reloc_needs_plt_for_ifunc): Accept any
+ reloc when refs will resolve to plt call stub.
+ (Target_powerpc::Scan::local): Correct ifunc handling. Allow
+ R_PPC_PLTREL24 to resolve locally.
+ (Target_powerpc::Scan::global): Correct ifunc handling.
+ (Target_powerpc::Relocate::relocate): Correct local sym glink
+ lookup. Don't destroy "value" when we have a plt call stub,
+ and when checking plt call validity.
+ (Target_powerpc::do_dynsym_value): Simplify.
+
+2012-10-05 Alan Modra <amodra@gmail.com>
+
+ * i386.cc (Output_data_plt_i386::address_for_global,
+ address_for_local): Add plt offset to returned value. Adjust uses.
+ * sparc.cc (Output_data_plt_sparc::address_for_global,
+ address_for_local): Likewise.
+ * tilegx.cc (Output_data_plt_tilegx::address_for_global,
+ address_for_local): Likewise.
+ * x86_64.cc (Output_data_plt_x86_64::address_for_global,
+ address_for_local): Likewise.
+ * target.h (Target::plt_address_for_global, plt_address_for_local):
+ Update comment.
+ * output.cc (Output_reloc::symbol_value): Don't add plt offset here.
+ (Output_data_got::Got_entry::write): Nor here.
+ * output.h: Comment fix.
+
+2012-10-02 Jiong Wang <jiwang@tilera.com>
+
+ * tilegx.cc (Target_tilegx::do_finalize_sections): Adjust
+ global_offset_table_ value for larget got.
+ (Target_tilegx::Relocate::relocate): Handle adjusted got value.
+
+2012-09-29 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Target_powerpc::iplt_): New output section.
+ (Target_powerpc::iplt_section, make_iplt_section,
+ reloc_needs_plt_for_ifunc, make_local_ifunc_plt_entry): New functions.
+ (Target_powerpc::make_plt_entry): Handle ifunc syms.
+ Target_powerpc::plt_entry_count): Count iplt entries too.
+ (Output_data_plt_powerpc::Output_data_plt_powerpc): Don't create
+ reloc section in constructor. New params.
+ (Target_powerpc::make_plt_section): Create reloc section here instead.
+ (Output_data_plt_powerpc::add_ifunc_entry, add_local_ifunc_entry): New
+ functions.
+ (Output_data_plt_powerpc::initial_plt_entry_size_, name_): New vars.
+ (Output_data_glink::add_entry, find_entry): New functions to
+ deal with local syms.
+ (Glink_sym_ent): Add support for local syms.
+ (Output_data_glink::do_write): Handle ifunc plt entries.
+ (Target_powerpc::Scan::get_reference_flags): Handle more relocs.
+ (Target_powerpc::Scan::local, global): Handle ifunc syms.
+ (Target_powerpc::Relocate::relocate): Likewise.
+ (Target_powerpc::do_dynsym_value): Use glink stub, not plt entry.
+
+2012-09-25 Alan Modra <amodra@gmail.com>
+
+ * 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.
+
+2012-09-15 Jiong Wang <jiwang@tilera.com>
+
+ * tilegx.cc: New file.
+ * Makefile.am (TARGETSOURCES): Add tilegx.cc
+ (ALL_TARGETOBJS): Add tilegx.$(OBJEXT)
+ * configure.tgt: Add entries for tilegx*.
+ * configure.ac: Likewise.
+ * Makefile.in: Rebuild.
+ * configure: Likewise.
+ * testsuite/icf_safe_test.sh (arch_specific_safe_fold): Handle
+ tilegx.
+
+2012-09-13 Alan Modra <amodra@gmail.com>
+
+ * target-reloc.h (scan_relocs): Call scan.local for relocs
+ against symbols in discarded sections. Pass is_discarded
+ param.
+ * arm.cc, * i386.cc, * sparc.cc, * x86_64.cc (Target_*::Scan::local):
+ Add is_discarded param.
+ * powerpc (Target_powerpc::Scan::local): Likewise. Use
+ is_discarded to flag opd entry as discarded. Don't emit dyn
+ relocs on such entries.
+ (Target_powerpc::Scan::global): Similarly detect and handle
+ such opd entries.
+ (Powerpc_relobj): Replace opd_ent_shndx_ and opd_ent_off_ with
+ opd_ent_. Update all uses.
+ (Powerpc_relobj::get_opd_discard, set_opd_discard): New functions.
+ (Target_powerpc::relocate_section): Zero out discarded opd
+ entry relocs.
+
+2012-09-12 Ian Lance Taylor <iant@google.com>
+
+ PR gold/14570
+ * output.cc: Rename Output_data_got template parameter from size
+ to got_size for all functions. Compile all variants of
+ Output_data_got.
+ (Output_data_got::Got_entry::write): Correct use of size for
+ symbol value. Use local_is_tls rather than casting to
+ Sized_relobj_file.
+ * object.h (class Object): Add local_is_tls and do_local_is_tls.
+ (class Sized_relobj_file): Add do_local_is_tls.
+ * incremental.h (class Sized_relobj_incr): Add do_local_is_tls.
+
+2012-09-11 Alan Modra <amodra@gmail.com>
+
+ PR gold/14566
+ * layout.cc (Layout::set_segment_offsets): When using
+ common-page-size alignment, ensure we are on a new max-page-size
+ page.
+ * output.cc (Output_segment::set_section_addresses): Use
+ abi_pagesize, not common_pagesize for relro boundary.
+ (Output_segment::set_offset): Likewise.
+
+2012-09-11 Alan Modra <amodra@gmail.com>
+
+ * 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.
+
+2012-09-10 Matthias Klose <doko@ubuntu.com>
+
+ * config.in: Disable sanity check for kfreebsd.
+
+2012-09-10 Sterling Augustine <saugustine@google.com>
+
+ * gdb-index.cc (Gdb_index::pubnames_read): New parameter.
+ (Gdb_index::pubtypes_read): New parameter.
+ (Gdb_index_info_reader::read_pubnames_and_pubtypes): Add parameters
+ to calls.
+ * gdb-index.h (Gdb_index): New fields pubnames_object_ and
+ pubtypes_object_.
+
+2012-09-09 Alan Modra <amodra@gmail.com>
+
+ * target.h (Target::gc_mark_symbol, do_gc_mark_symbol): New functions.
+ (Sized_target::gc_add_reference, do_gc_add_reference): New functions.
+ * gc.h (gc_process_relocs): Call target gc_add_reference.
+ * gold.cc (queue_middle_tasks): Use gc_mark_symbol on start sym.
+ * symtab.cc (Symbol_table::gc_mark_undef_symbols): Use gc_mark_symbol.
+ (Symbol_table::gc_mark_symbol): Call target gc_mark_symbol. Remove
+ unnecessary cast.
+ * powerpc.cc (Powerpc_relobj::get_opd_ent): Rearrange parameters
+ to cater for when we don't need code offset. Update use.
+ (Powerpc_relobj::access_from_map_, opd_valid_): New vars.
+ (Powerpc_relobj::access_from_map, add_reference, opd_valid,
+ set_opd_valid): New functions.
+ (Target_powerpc::do_gc_add_reference): New function.
+ (Target_powerpc::gc_process_relocs): Call gc()->add_reference on
+ stashed refs.
+ (Target_powerpc::do_gc_mark_symbol): New function.
+
+2012-09-06 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_die::read_attributes): Add
+ DW_FORM_GNU_addr_index and DW_FORM_GNU_str_index.
+ (Dwarf_die::skip_attributes): Likewise.
+ * object.cc (Read_symbols_data::~Read_symbols_data): Update comment.
+ * testsuite/gdb_index_test.cc (inline_func_1): New function.
+ (main): Call it.
+ * testsuite/gdb_index_test_comm.sh: Check index for inline function.
+
+2012-09-05 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/script_test_3.t: Add .got.plt output section
+ statement.
+ * testsuite/script_test_4.t: Likewise.
+
+2012-09-05 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relocate_functions): Upcase enum values,
+ update all uses and lose "enum" when using type.
+
+2012-09-05 Alan Modra <amodra@gmail.com>
+
+ * configure.ac (FN_PTRS_IN_SO_WITHOUT_PIC): False for powerpc.
+ * configure: Regenerate.
+ * testsuite/Makefile.am (final_layout.stdout): Pass --synthetic to nm.
+ (plugin_final_layout.stdout): Likewise.
+ (memory_test): Set page sizes to 0x1000.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/discard_locals_test.sh: Add FIXME comment.
+ * testsuite/justsyms_exec.c: Disable function test for powerpc64.
+ * testsuite/pr14265.t: Add .got output section statement.
+ * testsuite/script_test_2.t: Likewise.
+ * testsuite/script_test_3.t: Likewise.
+ * testsuite/script_test_4.t: Likewise.
+ * testsuite/script_test_5.t: Likewise.
+ * testsuite/script_test_6.t: Likewise.
+ * testsuite/script_test_7.t: Likewise.
+ * testsuite/script_test_9.t: Likewise.
+
+2012-09-05 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::get_opd_ent): Make const.
+ (Powerpc_relocate_functions::Status): New typedef.
+ (Target_powerpc::Scan::get_reference_flags): Handle more relocs.
+ (Target_powerpc::Scan::local): Handle REL64.
+ (Target_powerpc::Scan::global): Likewise, and dynamic relocs
+ for REL32 and REL64.
+ (Target_powerpc::symval_for_branch): New function, extracted from..
+ (Target_powerpc::Relocate::relocate): ..here. Correct plt call
+ checks. Report overflow errors.
+
+2012-09-05 Alan Modra <amodra@gmail.com>
+
+ * object.h (Sized_relobj_file::emit_relocs): Delete.
+ (Sized_relobj_file::emit_relocs_reltype): Delete.
+ * reloc.cc (Sized_relobj_file::do_relocate_sections): Call target
+ relocate_relocs for --emit-relocs.
+ (Sized_relobj_file::emit_relocs, emit_relocs_reltype): Delete.
+ * output.h: Update comment.
+ (Output_segment::first_section): New function.
+ (Output_segment::first_section_load_address): Use first_section.
+ * output.cc (Output_segment::first_section): New function extracted..
+ (Output_segment::first_section_load_address): ..from here. Delete.
+ * target-reloc.h (relocate_for_relocatable): Rename to relocate_relocs.
+ * target.h (Sized_target::relocate_for_relocatable): Likewise.
+ * arm.cc (Target_arm::relocate_for_relocatable): Likewise, and
+ adjust call to target.h function.
+ * i386.cc (Target_i386): Likewise.
+ * sparc.cc (Target_sparc): Likewise.
+ * x86_64.cc (Target_x86_64): Likewise.
+ * powerpc.cc (Target_powerpc): Likewise.
+ (Target_powerpc::Scan::local, global): Handle R_POWERPC_TLS. Ensure
+ first tls section has section symbol for optimised local dynamic
+ output relocs.
+ (Target_powerpc::Relocate::relocate): Correct local dynamic value.
+ (Target_powerpc::relocate_relocs): Adjust relocs emitted for
+ optimised tls code.
+ * testsuite/testfile.cc (Target_test::relocate_for_relocatable):
+ Rename to relocate_relocs. Update error message.
+
+2012-09-04 Andreas Schwab <schwab@linux-m68k.org>
+
+ * powerpc.cc (do_make_elf_object): Allow ET_EXEC files with
+ --just-symbols.
+
+2012-08-31 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj): Add and use Address typedef.
+ (Powerpc_relobj::toc_base_offset): New stub function.
+ (Target_powerpc): Add tp_offset, dtp_offset. Rename
+ got_mod_index_offset to tlsld_got_offset. Update all refs.
+ (Target_powerpc::Relocate::enum skip_tls): New.
+ (Target_powerpc::call_tls_get_addr_): New var.
+ (Target_powerpc::is_branch_reloc): Move to file scope.
+ (Target_powerpc::relocate_tls, optimize_tls_reloc): Delete.
+ (Target_powerpc::optimize_tls_gd, optimize_tls_ld, optimize_tls_ie):
+ New functions.
+ (Target_powerpc::enum Got_type): Delete old values, add new ones.
+ (powerpc_info): Correct common_pagesize for ppc64.
+ (at_tls_transform, needs_dynamic_reloc, use_plt_offset): New functions.
+ (Powerpc_relocate_functions): Add overflow check enums and functions.
+ Add non-shift version of rela, rela_ua. Delete all rel public
+ functions. Delete addr16_lo. Add addr64, addr64_u, addr32,
+ addr32_u, addr24, addr16_u, addr16_hi2, addr16_ha2, addr16_hi3,
+ addr16_ha3, addr14 functions.
+ (Output_data_got_powerpc::add_constant_pair): New function.
+ (Output_data_got_powerpc::got_base_offset): Likewise.
+ (Output_data_got_powerpc::do_write): Correct 64-bit got header.
+ (instruction constants): Sort, add some more.
+ (Output_data_glink::do_write): Add and use Address typedef. Use
+ object->toc_base_offset() stub for 64-bit.
+ (Target_powerpc::tlsld_got_offset): Use add_constant_pair.
+ (Target_powerpc::Scan::get_reference_flags): Handle more relocs.
+ (Target_powerpc::Scan::local, global): Emit relative dynamic reloc
+ for R_PPC64_TOC. Handle more relocs. Generate got entries for TLS.
+ Always treat .opd relocs as against locally defined symbol.
+ Correct condition for RELATIVE relocs.
+ (Target_powerpc::do_finalize_sections): Test for NULL sections.
+ (Target_powerpc::Relocate::relocate): Use plt call stub as value
+ for 32-bit syms with a plt entry. Correct ppc64 toc base
+ calculations. Handle TLS relocs, and more. Add overflow
+ checking and adjust for Powerpc_relocate_functions changes.
+ (Target_powerpc::relocate_for_relocatable): Handle zero r_sym.
+ Reinstate --emit-relocs code with FIXME.
+
+2012-08-30 Alan Modra <amodra@gmail.com>
+
+ * layout.cc (Layout::set_segment_offsets): Set p_align to
+ abi_pagesize, not common_pagesize.
+ (Layout::relaxation_loop_body): Similarly use abi_pagesize
+ to determine whether file header can go in segment.
+
+2012-08-30 Alan Modra <amodra@gmail.com>
+
+ * output.h (Output_reloc::Output_reloc <output section>): Add
+ is_relative param. Adjust calls.
+ (Output_reloc::add_output_section_relative): New functions.
+ * output.cc (Output_reloc::Output_reloc <output section>): Handle
+ is_relative.
+ (Output_reloc::symbol_value): Handle SECTION_CODE.
+
+2012-08-24 Sriraman Tallam <tmsriram@google.com>
+
+ * gold.cc (queue_middle_tasks): Call layout again when unique
+ segments for sections is desired.
+ * layout.cc (Layout::Layout): Initialize new members.
+ (Layout::get_output_section_flags): New function.
+ (Layout::choose_output_section): Call get_output_section_flags.
+ (Layout::layout): Make output section for mapping to a unique segment.
+ (Layout::insert_section_segment_map): New function.
+ (Layout::attach_allocated_section_to_segment): Make unique segment for
+ output sections marked so.
+ (Layout::segment_precedes): Check for unique segments when sorting.
+ * layout.h (Layout::Unique_segment_info): New struct.
+ (Layout::Section_segment_map): New typedef.
+ (Layout::insert_section_segment_map): New function.
+ (Layout::get_output_section_flags): New function.
+ (Layout::is_unique_segment_for_sections_specified): New function.
+ (Layout::set_unique_segment_for_sections_specified): New function.
+ (Layout::unique_segment_for_sections_specified_): New member.
+ (Layout::section_segment_map_): New member.
+ * object.cc (Sized_relobj_file<size, big_endian>::do_layout):
+ Rename is_gc_pass_one to is_pass_one.
+ Rename is_gc_pass_two to is_pass_two.
+ Rename is_gc_or_icf to is_two_pass.
+ Check for which pass based on whether symbols data is present.
+ Make it two pass when unique segments for sections is desired.
+ * output.cc (Output_section::Output_section): Initialize new
+ members.
+ * output.h (Output_section::is_unique_segment): New function.
+ (Output_section::set_is_unique_segment): New function.
+ (Output_section::is_unique_segment_): New member.
+ (Output_section::extra_segment_flags): New function.
+ (Output_section::set_extra_segment_flags): New function.
+ (Output_section::extra_segment_flags_): New member.
+ (Output_section::segment_alignment): New function.
+ (Output_section::set_segment_alignment): New function.
+ (Output_section::segment_alignment_): New member.
+ (Output_segment::Output_segment): Initialize is_unique_segment_.
+ (Output_segment::is_unique_segment): New function.
+ (Output_segment::set_is_unique_segment): New function.
+ (Output_segment::is_unique_segment_): New member.
+ * plugin.cc (allow_unique_segment_for_sections): New function.
+ (unique_segment_for_sections): New function.
+ (Plugin::load): Add new functions to transfer vector.
+ * Makefile.am (plugin_final_layout.readelf.stdout): Add readelf output.
+ * Makefile.in: Regenerate.
+ * testsuite/plugin_final_layout.sh: Check if unique segment
+ functionality works.
+ * testsuite/plugin_section_order.c (onload): Check if new interfaces
+ are available.
+ (allow_unique_segment_for_sections): New global.
+ (unique_segment_for_sections): New global.
+ (claim_file_hook): Call allow_unique_segment_for_sections.
+ (all_symbols_read_hook): Call unique_segment_for_sections.
+
+2012-08-22 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (Layout::include_section): Don't assert on GROUP
+ sections with --emit-relocs.
+
+2012-08-21 Cary Coutant <ccoutant@google.com>
+
+ * symtab.cc (Symbol_table::gc_mark_undef_symbols): Don't assert
+ if --export-dynamic-symbol names an undef symbol.
+
+2012-08-18 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc: Formatting and white space.
+ (Powerpc_relobj): Rename got2_section_ to special_.
+ Add opd_ent_shndx_ and opd_ent_off_ vectors.
+ (Powerpc_relobj::opd_shndx, init_opd, get_opd_ent, set_opd_ent,
+ scan_opd_relocs, do_read_relocs, opd_ent_ndx): New functions.
+ (Target_powerpc): Add Address typedef and invalid_address. Use
+ throughout.
+ (Target_powerpc::is_branch_reloc): New function.
+ (Powerpc_relocate_functions): Add Address typedef, use throughout.
+ (Powerpc_relocate_functions:rela, rela_ua): Correct type used
+ for dst_mask, value and addend.
+ (Powerpc_relobj::do_find_special_sections): Find .opd for 64-bit.
+ (ld_2_1, cror_15_15_15, cror_31_31_31): New insn constants.
+ (Output_data_glink::do_write): Correct toc base. Don't try to use
+ uint16_t for 24-bit offset. Use get_output_section_offset and
+ check return.
+ (Target_powerpc::Scan::local): Handle more relocs.
+ (Target_powerpc::do_finalize_sections): Set up DT_PPC64_GLINK.
+ (Target_powerpc::Relocate::relocate): Correct toc base calculation.
+ Plug in toc restoring insn after plt calls. Translate branches
+ to function descriptor symbols to corresponding entry point.
+ (Target_powerpc::relocate_for_relocatable): Check return from
+ get_output_section_offset.
+ * symtab.h: Comment typo.
+
+2012-08-14 Ian Lance Taylor <iant@google.com>
+
+ * x86_64.cc (Target_x86_64::Scan::global): Fix erroneous call to
+ unsupported_relocal_local to call unsupported_reloc_global.
+
+2012-08-14 Nick Clifton <nickc@redhat.com>
+
+ PR ld/14265
+ * script-sections.cc (Sections_element::output_section_name): Add
+ keep return parameter.
+ (Output_section_element::match_name): Add keep return parameter.
+ Return the value of the keep_ member.
+ * script-sections.h (class Output_section): Update
+ output_section_name prototype.
+ * layout.cc (Layout::keep_input_section): New public member
+ function.
+ (Layout::choose_output_section): Pass keep parameter to
+ output_section_name.
+ * layout.h (class Layout): Add keep_input_section.
+ * object.cc (Sized_relobj_file::do_layout): Check for kept input
+ sections.
+ * testsuite/Makefile.am: Add a test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/pr14265.c: Source file for the test.
+ * testsuite/pr14265.t: Linker script for the test.
+ * testsuite/pr14265.sh: Shell script for the test.
+
+2012-08-14 Alan Modra <amodra@gmail.com>
+
+ * target.h (Target::output_section_name): New function.
+ (Target::do_output_section_name): New function.
+ * layout.cc (Layout::choose_output_section): Call the above.
+ * powerpc.cc (Target_powerpc::do_output_section_name): New function.
+
+2012-08-14 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc: Update for renamed R_PPC_REL16 relocs.
+ (Output_data_got_powerpc::do_write): Don't rely on base class lookup
+ for replace_constant call.
+ (Output_data_plt_powerpc::do_print_to_mapfile): New function.
+ (Output_data_glink::do_print_to_mapfile): New function.
+ (Target_powerpc::Scan::local): Ignore R_PPC64_TOCSAVE.
+ (Target_powerpc::Relocate::relocate): Likewise.
+
+2012-08-14 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc (Powerpc_relobj::set_got2_shndx): Delete.
+ (Powerpc_relobj::do_find_special_sections): Don't use set_got2_shndx.
+ (Output_data_glink::add_entry,find_entry): Remove shndx param.
+ (class Glink_sym_ent): Rename from struct Glink_sym_ent. Remove
+ all references to shndx_. Handle special case for R_PPC_PLTREL24
+ here.
+ (class Glink_sym_ent_hash): Rename from struct Glink_sym_ent_hash.
+ (Output_data_glink::do_write): Retrieve got2_shdnx from object.
+ (Target_powerpc::make_plt_entry): Don't special case R_PPC_PLTREL24
+ here.
+ (Target_powerpc::Scan::global): Nor on make_plt_entry call.
+ (Target_powerpc::Relocate::relocate): Nor on glink->find_entry call.
+
+2012-08-12 Alan Modra <amodra@gmail.com>
+
+ * powerpc.cc: Whitespace fixes. Wrap overly long lines.
+ (glink insn constants): Use uint32_t.
+ (Output_data_glink::add_entry): Use insert, not [] operator.
+
+2012-08-11 Alan Modra <amodra@gmail.com>
+
+ * object.h (Sized_relobj_file::find_shdr): New function.
+ (Sized_relobj_file::find_special_sections): New function.
+ * object.cc (Sized_relobj_file::find_shdr): New function.
+ (Sized_relobj_file::find_eh_frame): Use find_shdr.
+ (Sized_relobj_file::find_special_sections): New function, split out..
+ (Sized_relobj_file::do_read_symbols): ..from here.
+ * output.h (Output_data_got::replace_constant): New function.
+ (Output_data_got::num_entries): New function.
+ (Output_data_got::last_got_offset,set_got_size): Use num_entries.
+ (Output_data_got::got_offset): Protected rather than private.
+ (Output_data_got::replace_got_entry): New function.
+ * output.cc (Output_data_got::replace_got_entry): New function.
+ * powerpc.cc (class Powerpc_relobj): New.
+ (class Powerpc_relocate_functions): Delete all psymval variants or
+ convert to value,addend type. Delete pcrela, pcrela_unaligned.
+ Implement _ha functions using corresponding _hi function.
+ (Powerpc_relobj::find_special_sections): New function.
+ (Target_powerpc::do_make_elf_object): New function.
+ (class Output_data_got_powerpc): New.
+ (class Output_data_glink): New.
+ (class Powerpc_scan_relocatable_reloc): New.
+ Many more changes througout file.
+
+2012-08-09 Nick Clifton <nickc@redhat.com>
+
+ * po/vi.po: Updated Vietnamese translation.
+
+2012-08-07 Ian Lance Taylor <iant@google.com>
+
+ * layout.cc (Layout::add_target_dynamic_tags): If
+ dynrel_includes_plt but no dyn_rel, emit dynamic reloc tags for
+ plt_rel.
+
+2012-07-30 Nick Clifton <nickc@redhat.com>
+
+ * po/gold.pot: Updated template.
+ * po/es.po: Updated Spanish translation.
+
+2012-07-18 Cary Coutant <ccoutant@google.com>
+
+ PR gold/14344
+ * configure.ac: Add check for -gpubnames support.
+ * configure: Regenerate.
+ * testsuite/Makefile.am (gdb_index_test_1): Add check for -gpubnames
+ support; force -gno-pubnames.
+ (gdb_index_test_2, gdb_index_test_3): Add check for -gpubnames
+ support.
+ (gdb_index_test_4): New test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/gdb_index_test_1.sh: Refactor code into common file.
+ * testsuite/gdb_index_test_2.sh: Likewise.
+ * testsuite/gdb_index_test_3.sh: Don't look for space after colon.
+ * testsuite/gdb_index_test_4.sh: New script.
+ * testsuite/gdb_index_test_comm.sh: New script with common code;
+ don't look for space after colon.
+
+2012-07-16 Sriraman Tallam <tmsriram@google.com>
+
+ * gold.cc (queue_middle_tasks): Update function order only after
+ deferred objects due to plugins are processed.
+
+2012-07-11 Ian Lance Taylor <iant@google.com>
+
+ * arm.cc (Arm_relocate_functions::abs16): Remove unused typedef.
+ (Arm_exidx_cantunwind::do_fixed_endian_write): Likewise.
+ (Target_arm::scan_reloc_for_stub): Likewise.
+ * common.cc (Symbol_table::do_allocate_commons_list): Likewise.
+ * dwarf_reader.cc (Dwarf_die::skip_attributes): Likewise.
+ * ehframe.cc (Eh_frame::do_add_ehframe_input_section): Likewise.
+ * incremental.cc (Sized_incr_dynobj::do_add_symbols): Likewise.
+ * powerpc.cc (Target_powerpc::relocate_tls): Likewise.
+
+2012-07-10 Dodji Seketeli <dodji@redhat.com>
+ Ian Lance Taylor <iant@google.com>
+
+ PR gold/14309
+ * configure.ac: Test whether std::tr1::hash<off_t> works.
+ * gold.h: Add a specialization for std::tr1::hash<off_t> if
+ needed.
+ * output.h (class Output_fill): Add virtual destructor.
+ * configure, config.in: Rebuild.
+
+2012-06-22 Roland McGrath <mcgrathr@google.com>
+
+ * layout.cc (finalize): Define __ehdr_start symbol if applicable.
+
+2012-06-12 Rafael Ávila de Espíndola <respindola@mozilla.com>
+
+ * plugin.cc (Plugin::load): Handle position independent executables.
+
+2012-06-06 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (gdb_sections): Remove ".debug_" prefixes,
+ add .debug_macro.
+ (lines_only_debug_sections): Likewise.
+ (gdb_fast_lookup_sections): New static array.
+ (is_gdb_debug_section): Rename formal parameter.
+ (is_lines_only_debug_section): Likewise.
+ (is_gdb_fast_lookup_section): New function.
+ (Layout::include_section): Check for ".zdebug_" prefix; pass
+ section name suffix to is_gdb_debug_section, et al.; check for
+ fast-lookup sections when building .gdb_index.
+ * options.h (--strip-debug-gdb): Update GDB version number.
+
+2012-06-06 Cary Coutant <ccoutant@google.com>
+
+ * configure.ac: Add check for fallocate.
+ * configure: Regenerate.
+ * config.in: Regenerate.
+
+ * options.h (class General_options): Add --mmap-output-file and
+ --posix-fallocate options.
+ * output.cc: (posix_fallocate): Remove; replace with...
+ (gold_fallocate): New function.
+ (Output_file::map_no_anonymous): Call gold_fallocate.
+ (Output_file::map): Check --mmap-output-file option.
+
+2012-06-05 Jing Yu <jingyu@google.com>
+
+ * gold.h (textdomain): Add do {} to empty while(0).
+ (bindtextdomain): Likewise.
+
+2012-06-04 Cary Coutant <ccoutant@google.com>
+
+ * dynobj.cc (Sized_dynobj::do_get_global_symbol_counts): Call
+ has_dynsym_index.
+
+2012-05-25 Sriraman Tallam <tmsriram@google.com>
+
+ * symtab.cc (Symbol_table::define_special_symbol):
+ Initialize *poldsym to prevent uninitialized variable errors.
+
+2012-05-23 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (Layout::section_name_mapping): Add rules to handle
+ exact match on .data.rel.ro.local or .data.rel.ro.
+ (Layout::output_section_name): Check for exact matches.
+
+2012-05-23 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (Layout::section_name_mapping): Match .data.rel.ro.*
+ more carefully.
+
+2012-05-22 Cary Coutant <ccoutant@google.com>
+
+ * symtab.cc (Symbol::should_add_dynsym_entry): Check for relocatable
+ object before exporting symbol.
+
+2012-05-21 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/tls_test.cc: Include "config.h" first.
+ * testsuite/tls_test_c.c: Likewise.
+
+2012-05-17 Daniel Richard G. <skunk@iskunk.org>
+ Nick Clifton <nickc@redhat.com>
+
+ PR 14072
+ * configure.in: Add check that sysdep.h has been included before
+ any system header files.
+ * configure: Regenerate.
+ * config.in: Regenerate.
+
+2012-05-14 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (Layout::make_output_section): Mark .tdata section
+ as RELRO.
+ * testsuite/relro_test.cc: Add a TLS variable.
+
+2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR gold/14091
+ * x86_64.cc (Target_x86_64::Scan::local): For x32, generate
+ R_X86_64_RELATIVE64 instead of R_X86_64_RELATIVE in case of
+ R_X86_64_64.
+
+2012-05-08 Cary Coutant <ccoutant@google.com>
+
+ * layout.cc (gdb_sections): Update GDB version, add .debug_addr.
+ (lines_only_debug_sections): Likewise.
+
+2012-05-02 Roland McGrath <mcgrathr@google.com>
+
+ * nacl.cc: New file.
+ * nacl.h: New file.
+ * Makefile.am (CCFILES, HFILES): Add them.
+ * Makefile.in: Regenerate.
+ * i386.cc (Output_data_plt_i386_nacl): New class.
+ (Output_data_plt_i386_nacl_exec): New class.
+ (Output_data_plt_i386_nacl_dyn): New class.
+ (Target_i386_nacl): New class.
+ (Target_selector_i386_nacl): New class.
+ (target_selector_i386): Use it instead of Target_selector_i386.
+ * x86_64.cc (Output_data_plt_x86_64_nacl): New class.
+ (Target_x86_64_nacl): New class.
+ (Target_selector_x86_64_nacl): New class.
+ (target_selector_x86_64, target_selector_x32): Use it instead of
+ Target_selector_x86_64.
+ * arm.cc (Output_data_plt_arm_nacl): New class.
+ (Target_arm_nacl): New class.
+ (Target_selector_arm_nacl): New class.
+ (target_selector_arm, target_selector_armbe): Use it instead of
+ Target_selector_arm.
+
+ * target-select.cc (select_target): Take new Input_file* and off_t
+ arguments, pass them on to recognize method of selector.
+ * object.cc (make_elf_sized_object): Update caller.
+ * parameters.cc (parameters_force_valid_target): Likewise.
+ * incremental.cc (make_sized_incremental_binary): Likewise.
+ * target-select.h: Update decl.
+ (Target_selector::recognize): Take new Input_file* argument,
+ pass it on to do_recognize.
+ (Target_selector::do_recognize): Take new Input_file* argument.
+ * freebsd.h (Target_selector_freebsd::do_recognize): Likewise.
+ * powerpc.cc (Target_selector_powerpc::do_recognize): Likewise.
+ * sparc.cc (Target_selector_sparc::do_recognize): Likewise.
+ * testsuite/testfile.cc (Target_selector::do_recognize): Likewise.
+
+ * target.h (Target::Target_info): New members isolate_execinstr
+ and rosegment_gap.
+ (Target::isolate_execinstr, Target::rosegment_gap): New methods.
+ * arm.cc (Target_arm::arm_info): Update initializer.
+ * i386.cc (Target_i386::i386_info): Likewise.
+ * powerpc.cc (Target_powerpc::powerpc_info): Likewise.
+ * sparc.cc (Target_sparc::sparc_info): Likewise.
+ * x86_64.cc (Target_x86_64::x86_64_info): Likewise.
+ * testsuite/testfile.cc (Target_test::test_target_info): Likewise.
+ * layout.cc (Layout::attach_allocated_section_to_segment):
+ Take new const Target* argument. If target->isolate_execinstr(), act
+ like --rosegment.
+ (Layout::find_first_load_seg): Take new const Target* argument;
+ if target->isolate_execinstr(), reject PF_X segments.
+ (Layout::relaxation_loop_body): Update caller.
+ (Layout::set_segment_offsets): If target->isolate_execinstr(),
+ reset file offset to zero when we hit LOAD_SEG, and then do a second
+ loop over the segments before LOAD_SEG to reassign offsets after
+ addresses have been determined. Handle target->rosegment_gap().
+ (Layout::attach_section_to_segment): Take new const Target* argument;
+ pass it to attach_allocated_section_to_segment.
+ (Layout::make_output_section): Update caller.
+ (Layout::attach_sections_to_segments): Take new const Target* argument;
+ pass it to attach_section_to_segment.
+ * gold.cc (queue_middle_tasks): Update caller.
+ * layout.h (Layout): Update method decls with new arguments.
+
+ * arm.cc (Target_arm::Target_arm): Take optional argument for the
+ Target_info pointer to use.
+ (Target_arm::do_make_data_plt): New virtual method.
+ (Target_arm::make_data_plt): New method that calls it.
+ (Target_arm::make_plt_entry): Use it.
+ (Output_data_plt_arm::Output_data_plt_arm): Take additional argument
+ for the section alignment.
+ (Output_data_plt_arm::do_first_plt_entry_offset): New abstract virtual
+ method.
+ (Output_data_plt_arm::first_plt_entry_offset): Call it.
+ (Output_data_plt_arm::do_get_plt_entry_size): New abstract virtual
+ method.
+ (Output_data_plt_arm::get_plt_entry_size): Call it.
+ (Output_data_plt_arm::do_fill_plt_entry): New abstract virtual method.
+ (Output_data_plt_arm::fill_plt_entry): New method that calls it.
+ (Output_data_plt_arm::do_fill_first_plt_entry): New abstract virtual
+ method.
+ (Output_data_plt_arm::fill_first_plt_entry): New method that calls it.
+ (Output_data_plt_arm::set_final_data_size): Use get_plt_entry_size
+ method instead of sizeof(plt_entry).
+ (Output_data_plt_arm::add_entry): Likewise.
+ Use first_plt_entry_offset method instead of sizeof(first_plt_entry).
+ (Target_arm::first_plt_entry_offset): Call method on this->plt_ rather
+ than static method.
+ (Target_arm::plt_entry_size): Likewise.
+ (Output_data_plt_arm::first_plt_entry, Output_data_plt_arm::plt_entry):
+ Move to ...
+ (Output_data_plt_arm_standard): ... here, new class.
+ (Output_data_plt_arm::do_write): Move guts of PLT filling to...
+ (Output_data_plt_arm_standard::do_fill_first_plt_entry): ... here ...
+ (Output_data_plt_arm_standard::do_fill_plt_entry): ... and here.
+
+ * x86_64.cc (Output_data_plt_x86_64::Output_data_plt_x86_64):
+ Take additional argument for the PLT entry size.
+ (Output_data_plt_x86_64::get_tlsdesc_plt_offset):
+ Use get_plt_entry_size method rather than plt_entry_size variable.
+ (Output_data_plt_x86_64::reserve_slot): Likewise.
+ (Output_data_plt_x86_64::do_adjust_output_section): Likewise.
+ (Output_data_plt_x86_64::add_entry): Likewise.
+ (Output_data_plt_x86_64::add_local_ifunc_entry): Likewise.
+ (Output_data_plt_x86_64::address_for_global): Likewise.
+ (Output_data_plt_x86_64::address_for_local): Likewise.
+ (Output_data_plt_x86_64::set_final_data_size): Likewise.
+ (Output_data_plt_x86_64::first_plt_entry_offset): Likewise.
+ Make method non-static.
+ (Output_data_plt_x86_64::do_get_plt_entry_size): New abstract virtual
+ method.
+ (Output_data_plt_x86_64::get_plt_entry_size): Just call that.
+ (Output_data_plt_x86_64::do_add_eh_frame): New abstract virtual method.
+ (Output_data_plt_x86_64::add_eh_frame): New method to call it.
+ (Output_data_plt_x86_64::do_fill_first_plt_entry): New abstract
+ virtual method.
+ (Output_data_plt_x86_64::fill_first_plt_entry): New method to call it.
+ (Output_data_plt_x86_64::do_fill_plt_entry): New abstract
+ virtual method.
+ (Output_data_plt_x86_64::fill_plt_entry): New method to call it.
+ (Output_data_plt_x86_64::do_fill_tlsdesc_entry): New abstract
+ virtual method.
+ (Output_data_plt_x86_64::fill_tlsdesc_entry): New method to call it.
+ (Output_data_plt_x86_64::plt_entry_size)
+ (Output_data_plt_x86_64::first_plt_entry)
+ (Output_data_plt_x86_64::plt_entry)
+ (Output_data_plt_x86_64::tlsdesc_plt_entry)
+ (Output_data_plt_x86_64::plt_eh_frame_fde_size)
+ (Output_data_plt_x86_64::plt_eh_frame_fde): Move to ...
+ (Output_data_plt_x86_64_standard): ... here, new class.
+ (Target_x86_64::Target_x86_64): Take optional argument for the
+ Target_info pointer to use.
+ (Target_x86_64::do_make_data_plt): New virtual method.
+ (Target_x86_64::make_data_plt): New method to call it.
+ (Target_x86_64::init_got_plt_for_update): Use that.
+ Call this->plt_->add_eh_frame method here.
+ (Output_data_plt_x86_64::init): Don't do add_eh_frame_for_plt here.
+ (Target_x86_64::first_plt_entry_offset): Call method on this->plt_
+ rather than static method.
+ (Target_x86_64::plt_entry_size): Likewise.
+ (Output_data_plt_x86_64::do_write): Use get_plt_entry_size method
+ rather than plt_entry_size variable. Move guts of PLT filling to...
+ (Output_data_plt_x86_64_standard::do_fill_first_plt_entry): ... here ...
+ (Output_data_plt_x86_64_standard::do_fill_plt_entry): ... and here ...
+ (Output_data_plt_x86_64_standard::do_fill_tlsdesc_entry): ... and here.
+
+ * i386.cc (Output_data_plt_i386::Output_data_plt_i386): Take
+ additional argument for the section alignment.
+ Don't do add_eh_frame_for_plt here.
+ (Output_data_plt_i386::first_plt_entry_offset): Make the method
+ non-static. Use get_plt_entry_size method rather than plt_entry_size
+ variable.
+ (Output_data_plt_i386::do_get_plt_entry_size): New abstract virtual
+ method.
+ (Output_data_plt_i386::get_plt_entry_size): Call it.
+ (Output_data_plt_i386::do_add_eh_frame): New abstract virtual method.
+ (Output_data_plt_i386::add_eh_frame): New method to call it.
+ (Output_data_plt_i386::do_fill_first_plt_entry): New abstract virtual
+ method.
+ (Output_data_plt_i386::fill_first_plt_entry): New method to call it.
+ (Output_data_plt_i386::do_fill_plt_entry): New abstract virtual
+ method.
+ (Output_data_plt_i386::fill_plt_entry): New method to call it.
+ (Output_data_plt_i386::set_final_data_size): Use get_plt_entry_size
+ method instead of plt_entry_size.
+ (Output_data_plt_i386::plt_entry_size)
+ (Output_data_plt_i386::plt_eh_frame_fde_size)
+ (Output_data_plt_i386::plt_eh_frame_fde): Move to ...
+ (Output_data_plt_i386_standard): ... here, new class.
+ (Output_data_plt_i386_exec): New class.
+ (Output_data_plt_i386::exec_first_plt_entry): Move to ...
+ (Output_data_plt_i386_exec::first_plt_entry): ... here.
+ (Output_data_plt_i386::exec_plt_entry): Move to ...
+ (Output_data_plt_i386_exec::plt_entry): ... here.
+ (Output_data_plt_i386_dyn): New class.
+ (Output_data_plt_i386::first_plt_entry): Move to ...
+ (Output_data_plt_i386_dyn::first_plt_entry): ... here.
+ (Output_data_plt_i386::dyn_plt_entry): Move to ...
+ (Output_data_plt_i386_dyn::plt_entry): ... here.
+ (Target_i386::Target_i386): Take optional argument for the Target_info
+ pointer to use.
+ (Target_i386::do_make_data_plt): New virtual method.
+ (Target_i386::make_data_plt): New method to call it.
+ (Target_i386::make_plt_section): Use that.
+ Call this->plt_->add_eh_frame method here.
+ (Output_data_plt_i386::add_entry): Use get_plt_entry_size method
+ rather than plt_entry_size variable.
+ (Output_data_plt_i386::add_local_ifunc_entry): Likewise.
+ (Output_data_plt_i386::address_for_local): Likewise.
+ (Output_data_plt_i386::do_write): Likewise.
+ Move guts of PLT filling to...
+ (Output_data_plt_i386_exec::do_fill_first_plt_entry): ... here ...
+ (Output_data_plt_i386_exec::do_fill_plt_entry): ... and here ...
+ (Output_data_plt_i386_dyn::do_fill_first_plt_entry): ... and here ...
+ (Output_data_plt_i386_dyn::do_fill_plt_entry): ... and here.
+
+2012-05-01 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Dwarf_die::read_attributes)
+ (Dwarf_die::skip_attributes, Dwarf_die::int_attribute)
+ (Dwarf_die::uint_attribute): Remove DW_FORM_null.
+ * reduced_debug_output.cc
+ (Output_reduced_debug_info_section::get_die_end): Remove
+ DW_FORM_GNU_ref_index. Add default case.
+
+2012-04-26 Mark Wielaard <mjw@redhat.com>
+
+ * dwarf_reader.cc (Dwarf_die::address_attribute): New function.
+ * dwarf_reader.h (Dwarf_die::address_attribute): Likewise.
+ * gdb-index.cc (Gdb_index_info_reader::record_cu_ranges): Handle
+ DW_AT_high_pc as offset from DW_AT_low_pc.
+
+ * testsuite/Makefile.am (gdb_index_test_3.sh): New test case.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/gdb_index_test_3.c: New test source file.
+ * testsuite/gdb_index_test_3.sh: New test source file.
+
+2012-04-25 Ian Lance Taylor <iant@google.com>
+
+ * arm.cc (Target_arm::do_is_defined_by_abi): Make sym a const
+ pointer.
+ (Stub_addend_reader::operator()): Declare Arm_relocate_functions
+ as a class, not a struct.
+ (Target_arm::scan_span_for_cortex_a8_erratum): Likewise.
+ (Target_arm::apply_cortex_a8_workaround): Likewise.
+ * gc.h: Declare Reloc_types as a struct, not a class.
+ * object.h: Declare Symbols_data as a struct.
+ * reloc.h: Declare Read_relocs_data as a struct.
+ * target.h: Declare Relocate_info as a struct.
+
+2012-04-24 David S. Miller <davem@davemloft.net>
+
+ * sparc.cc (Target_sparc::Relocate::relax_call): New function.
+ (Target_sparc::Relocate::relocate): Call it for R_SPARC_WDISP30
+ and R_SPARC_WPLT30.
+
+2012-04-24 Cary Coutant <ccoutant@google.com>
+
+ * incremental-dump.cc (find_input_containing_global): Replace
+ magic number with symbolic constant.
+ (dump_incremental_inputs): Update version number.
+ * incremental.cc (Output_section_incremental_inputs): Update version
+ number; import symbolic constants from Incremental_inputs_reader.
+ (Incremental_inputs::create_data_sections): Align relocations
+ section correctly for 64-bit targets.
+ (Output_section_incremental_inputs::set_final_data_size): Use symbolic
+ constants; add padding.
+ (Output_section_incremental_inputs::write_header): Add assert for
+ header_size.
+ (Output_section_incremental_inputs::write_input_files): Add assert
+ for input_entry_size.
+ (Output_section_incremental_inputs::write_info_blocks): Add padding;
+ add assert for object_info_size, input_section_entry_size,
+ global_sym_entry_size.
+ * incremental.h (Incremental_inputs_reader): Add symbolic constants
+ for data structure sizes; use them.
+ (Incremental_input_entry_reader): Import symbolic constants from
+ Incremental_inputs_reader; use them.
+
+2012-04-23 David S. Miller <davem@davemloft.net>
+
+ * sparc.cc (class Target_sparc): Add elf_machine_, elf_flags_,
+ and elf_flags_set_.
+ (Target_sparc::Target_sparc): Initialize new fields.
+ (Target_sparc::do_make_elf_object): New function.
+ (Target_sparc::do_adjust_elf_header): New function.
+
+2012-04-23 Cary Coutant <ccoutant@google.com>
+
+ * gdb-index.cc (Gdb_index::do_write): Use Swap_aligned32 for writing
+ CU range table of gdb index.
+
+2012-04-20 David S. Miller <davem@davemloft.net>
+
+ * target.cc (Sized_target::do_adjust_elf_header): Use big_endian
+ instead of false.
+
+2012-04-16 David S. Miller <davem@davemloft.net>
+
+ * sparc.cc (Target_sparc::got_address): New function.
+ (Sparc_relocate_functions::gdop_hix22): New function.
+ (Sparc_relocate_functions::gdop_lox10): New function.
+ (Target_sparc::Scan::local): Do not emit a GOT entry for GOTDATA
+ relocs.
+ (Target_sparc::Scan::local): Likewise if the global symbol is not
+ preemptible and is not IFUNC.
+ (Target_sparc::Relocate::relocate): Perform GOTDATA code
+ transformations for local and non-preemptible non-IFUNC global
+ symbols.
+
+ * gdb-index.cc (Gdb_index::do_write): Use Swap_unaligned when
+ writing out 64-bit part of ranges.
+
+ * Makefile.am: Build IFUNC tests with -fPIC and -fPIE instead of
+ -fpic and -fpie respectively.
+ * Makefile.in: Regenerate.
+
+ * sparc.cc (class Target_sparc): Add rela_ifunc_.
+ (Target_sparc::Target_sparc): Initialize new field.
+ (Target_sparc::do_plt_section_for_global): New function.
+ (Target_sparc::do_plt_section_for_local): New function.
+ (Target_sparc::reloc_needs_plt_for_ifunc): New function.
+ (Target_sparc::make_plt_section): New function, broken out of
+ make_plt_entry. Use ORDER_NON_RELRO_FIRST for ".plt".
+ (Target_sparc::make_plt_entry): Call make_plt_section.
+ (Target_sparc::make_local_ifunc_plt_entry): New function.
+ (Target_sparc::rela_ifunc_section): New function.
+ (Target_sparc::plt_section): Remove const.
+ (Output_data_plt_sparc): Update declarations. Define Global_ifunc
+ and Local_ifunc types. Add global_ifuncs_, local_ifuncs_, ifunc_rel_,
+ and ifunc_count_ fields.
+ (Output_data_plt_sparc::Output_data_plt_sparc): Initialize new fields.
+ (Output_data_plt_sparc::add_entry): Handle IFUNC symbols.
+ (Output_data_plt_sparc::add_local_ifunc_entry): New function.
+ (Output_data_plt_sparc::rela_ifunc): New function.
+ (Output_data_plt_sparc::emit_pending_ifunc_relocs): New function.
+ (Output_data_plt_sparc::has_ifunc_section): New function.
+ (Output_data_plt_sparc::entry_count): Include ifunc_count_.
+ (Output_data_plt_sparc::address_for_global): New function.
+ (Output_data_plt_sparc::address_for_local): New function.
+ (Output_data_plt_sparc::plt_index_to_offset): New function.
+ (Output_data_plt_sparc::set_final_data_size): Use plt_index_to_offset
+ and entry_count.
+ (Output_data_plt_sparc::do_write): Use first_plt_entry_offset and
+ entry_count.
+ (Target_sparc::Scan::get_reference_flags): Add R_SPARC_IRELATIVE and
+ R_SPARC_JMP_IREL to switch.
+ (Target_sparc::Scan::check_non_pic): Likewise.
+ (Target_sparc::Scan::local): Handle IFUNC symbols.
+ (Target_sparc::Scan::local): Likewise.
+ (Target_sparc::Relocate::relocate): Likewise, use plt_address_for_global
+ and plt_address_for_local.
+ (Target_sparc::do_finalize_sections): Call emit_pending_ifunc_relocs.
+ Define __rel_iplt_start and __rel_iplt_end if doing a static link.
+
+ * output.h (Output_reloc): Allow use_plt_offset for global relocs too.
+ (class Output_data_reloc): Adjust calls to Output_reloc_type.
+ (Output_data_reloc::add_global_relative): (RELA only) Add use_plt_offset.
+ * output.cc (Output_reloc::Output_reloc): Add use_plt_offset flag for
+ global relocs too.
+ (Output_reloc::symbol_value): Respect use_plt_offset_ for global symbols.
+ * powerpc.cc (Target_powerpc::Scan::global): Adjust add_global_relative
+ calls.
+ * sparc.cc (Target_sparc::Scan::global): Likewise.
+ * x86_64.cc (Target_x86_64::Scan::global): Likewise.
+
+2012-04-16 Cary Coutant <ccoutant@google.com>
+
+ * archive.cc (Library_base::should_include_member): Check for
+ --export-dynamic-symbol.
+ * options.h (class General_options): Add --export-dynamic-symbol.
+ * symtab.cc (Symbol::should_add_dynsym_entry): Check for
+ --export-dynamic-symbol.
+ (Symbol_table::gc_mark_undef_symbols): Likewise.
+ (Symbol_table::do_add_undefined_symbols_from_command_line): Likewise.
+
+2012-04-12 David S. Miller <davem@davemloft.net>
+
+ * sparc.cc (Reloc::wdisp10): New relocation method.
+ (Reloc::h34): Likewise.
+ (Target_sparc::Scan::check_non_pic): Handle R_SPARC_H34.
+ (Target_sparc::Scan::get_reference_flags): Handle R_SPARC_H34 and
+ R_SPARC_WDISP10.
+ (Target_sparc::Scan::local): Likewise.
+ (Target_sparc::Scan::global): Likewise.
+ (Target_sparc::Relocate::relocate): Likewise.
+
+2012-04-09 Cary Coutant <ccoutant@google.com>
+
+ * gdb-index.cc (Gdb_index_info_reader::record_cu_ranges): Allow
+ low_pc == 0.
+
+2012-04-06 Ian Lance Taylor <iant@google.com>
+
+ * timer.cc: #include <unistd.h>.
+
+2012-04-06 Roland McGrath <mcgrathr@google.com>
+
+ * configure.in (AC_CHECK_HEADERS): Add locale.h.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2012-04-05 Nick Clifton <nickc@redhat.com>
+
+ * configure.ac (AC_CHECK_FUNCS): Add setlocale.
+ (AM_LC_MESSAGES): Add.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2012-03-21 Cary Coutant <ccoutant@google.com>
+
+ * Makefile.am: Add gdb-index.cc, gdb-index.h.
+ * Makefile.in: Regenerate.
+ * dwarf_reader.cc (Sized_elf_reloc_mapper::do_initialize): New function.
+ (Sized_elf_reloc_mapper::symbol_section): New function.
+ (Sized_elf_reloc_mapper::do_get_reloc_target): New function.
+ (make_elf_reloc_mapper): New function.
+ (Dwarf_abbrev_table::clear_abbrev_codes): New function.
+ (Dwarf_abbrev_table::do_read_abbrevs): New function.
+ (Dwarf_abbrev_table::do_get_abbrev): New function.
+ (Dwarf_ranges_table::read_ranges_table): New function.
+ (Dwarf_ranges_table::read_range_list): New function.
+ (Dwarf_pubnames_table::read_section): New function.
+ (Dwarf_pubnames_table::read_header): New function.
+ (Dwarf_pubnames_table::next_name): New function.
+ (Dwarf_die::Dwarf_die): New function.
+ (Dwarf_die::read_attributes): New function.
+ (Dwarf_die::skip_attributes): New function.
+ (Dwarf_die::set_name): New function.
+ (Dwarf_die::set_linkage_name): New function.
+ (Dwarf_die::attribute): New function.
+ (Dwarf_die::string_attribute): New function.
+ (Dwarf_die::int_attribute): New function.
+ (Dwarf_die::uint_attribute): New function.
+ (Dwarf_die::ref_attribute): New function.
+ (Dwarf_die::child_offset): New function.
+ (Dwarf_die::sibling_offset): New function.
+ (Dwarf_info_reader::check_buffer): New function.
+ (Dwarf_info_reader::parse): New function.
+ (Dwarf_info_reader::do_parse): New function.
+ (Dwarf_info_reader::do_read_string_table): New function.
+ (Dwarf_info_reader::lookup_reloc): New function.
+ (Dwarf_info_reader::get_string): New function.
+ (Dwarf_info_reader::visit_compilation_unit): New function.
+ (Dwarf_info_reader::visit_type_unit): New function.
+ (Sized_dwarf_line_info::Sized_dwarf_line_info): Use
+ Sized_elf_reloc_mapper.
+ (Sized_dwarf_line_info::symbol_section): Remove function.
+ (Sized_dwarf_line_info::read_relocs): Use Sized_elf_reloc_mapper.
+ (Sized_dwarf_line_info::read_line_mappings): Remove object
+ parameter, adjust callers.
+ (Sized_dwarf_line_info::format_file_lineno): Fix type of cast.
+ * dwarf_reader.h: Include <sys/types.h>.
+ (class Track_relocs): Remove forward declaration.
+ (class Elf_reloc_mapper): New class.
+ (class Sized_elf_reloc_mapper): New class.
+ (class Dwarf_abbrev_table): New class.
+ (class Dwarf_range_list): New class.
+ (class Dwarf_ranges_table): New class.
+ (class Dwarf_pubnames_table): New class.
+ (class Dwarf_die): New class.
+ (class Dwarf_info_reader): New class.
+ (Sized_dwarf_line_info::read_line_mappings): Remove object parameter.
+ (Sized_dwarf_line_info::symbol_section): Remove member function.
+ * dynobj.h (Sized_dynobj::do_section_contents): Refactor code from
+ base class.
+ * gdb-index.cc: New source file.
+ * gdb-index.h: New source file.
+ * incremental.cc (Sized_relobj_incr::do_layout): Track .debug_info
+ and .debug_types sections, call Layout::add_to_gdb_index.
+ (Sized_relobj_incr::do_section_name): Implement.
+ (Sized_relobj_incr::do_section_contents): Adjust parameter list and
+ return type; Implement.
+ (Sized_incr_dynobj::do_section_contents): Adjust parameter list and
+ return type.
+ * incremental.h (Sized_relobj_incr::do_section_contents): Adjust
+ parameter list and return type.
+ (Sized_incr_dynobj::do_section_contents): Likewise.
+ * layout.cc: Include gdb-index.h.
+ (Layout::Layout): Initialize gdb_index_data_.
+ (Layout::init_fixed_output_section): Check for .gdb_index section.
+ (Layout::add_to_gdb_index): New function. Instantiate.
+ * layout.h: Add forward declaration for class Gdb_index.
+ (Layout::add_to_gdb_index): New member function.
+ (Layout::gdb_index_data_): New data member.
+ * main.cc: Include gdb-index.h.
+ (main): Print statistics for gdb index.
+ * object.cc (Object::section_contents): Move code into
+ do_section_contents.
+ (need_decompressed_section): Check for sections needed when building
+ gdb index.
+ (build_compressed_section_map): Likewise.
+ (Sized_relobj_file::do_read_symbols): Need local symbols when building
+ gdb index.
+ (Sized_relobj_file::do_layout): Track .debug_info and .debug_types
+ sections; call Layout::add_to_gdb_index.
+ (Sized_relobj_file::do_decompressed_section_contents): Call
+ do_section_contents directly.
+ * object.h (Object::do_section_contents): Adjust parameter list and
+ return type.
+ (Object::do_decompressed_section_contents): Call do_section_contents
+ directly.
+ (Sized_relobj_file::do_section_contents): Adjust parameter list and
+ return type.
+ * options.h (class General_options): Add --gdb-index option.
+ * plugin.cc (Sized_pluginobj::do_section_contents): Adjust parameter
+ list and return type.
+ * plugin.h (Sized_pluginobj::do_section_contents): Likewise.
+ * reloc.h (Track_relocs::checkpoint): New function.
+ (Track_relocs::reset): New function.
+
+ * testsuite/Makefile.am (gdb_index_test_1.sh, gdb_index_test_2.sh):
+ New test cases.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/gdb_index_test.cc: New test source file.
+ * testsuite/gdb_index_test_1.sh: New test source file.
+ * testsuite/gdb_index_test_2.sh: New test source file.
+
+2012-03-19 Doug Kwan <dougkwan@google.com>
+
+ * arm.cc (Target_arm::do_define_standard_symbols): New method.
+ (Target_arm::do_finalize_sections): Remove code which defines
+ __exidx_start and __exidx_end. Make symbol table parameter
+ anonymous as it is not used.
+ * gold.cc (queue_middle_tasks): Call target hook to define any
+ target-specific symbols.
+ * target.h (Target::define_standard_symbols): New method.
+ (Target::do_define_standard_symbols): Same.
+ * testsuite/Makefile.am (arm_exidx_test): Dump relocations also.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/arm_exidx.s: Generate data relocations for __exidx_start
+ and __exidx_end.
+ * testsuite/arm_exidx_test.sh: Check that no unused dynamic
+ relocations are generated for __exidx_start and __exidx_end.
+
+2012-03-16 Doug Kwan <dougkwan@google.com>
+
+ * testsuite/Makefile.am: Disable test initpri3b.
+ * testsuite/Makefile.in: Regenerate.
+
+2012-03-15 Doug Kwan <dougkwan@google.com>
+
+ * arm.cc (Target_arm::got_section): Make .got section read-only
+ if -z now is given.
+
+2012-03-15 Ian Lance Taylor <iant@google.com>
+
+ PR gold/13850
+ * layout.cc (Layout::make_output_section): Correctly mark
+ SHT_INIT_ARRAY, et. al., as relro.
+
+2012-03-14 Doug Kwan <dougkwan@google.com>
+
+ * gold/arm.cc (Target_arm::Scan::global): Generate R_ARM_GLOB_DAT
+ dynamic relocations for protected symbols in shared objects.
+
+2012-03-13 Ian Lance Taylor <iant@google.com>
+
+ * resolve.cc (Symbol_table::resolve): When merging common symbols,
+ keep the larger alignment.
+
+2012-03-12 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Sized_dwarf_line_info::process_one_opcode): Fix
+ handling of DW_LNE_define_file.
+
+2012-03-12 Cary Coutant <ccoutant@google.com>
+
+ * reduced_debug_output.cc
+ (Output_reduced_debug_info_section::get_die_end): Add new FORM
+ codes to switch.
+
+2012-02-29 Cary Coutant <ccoutant@google.com>
+
+ * object.cc (need_decompressed_section): Add #ifdef ENABLE_THREADS.
+
+2012-02-29 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Sized_dwarf_line_info::Sized_dwarf_line_info):
+ Call Object::decompressed_section_contents.
+ * dwarf_reader.h (Sized_dwarf_line_info::~Sized_dwarf_line_info):
+ New dtor.
+ (Sized_dwarf_line_info::buffer_start_): New data member.
+ * merge.cc (Output_merge_data::do_add_input_section): Call
+ Object::decompressed_section_contents.
+ (Output_merge_string::do_add_input_section): Likewise.
+ * object.cc (need_decompressed_section): New function.
+ (build_compressed_section_map): Decompress sections needed later.
+ (Sized_relobj_file::do_decompressed_section_contents): New function.
+ (Sized_relobj_file::do_discard_decompressed_sections): New function.
+ * object.h (Object::decompressed_section_contents): New function.
+ (Object::discard_decompressed_sections): New function.
+ (Object::do_decompressed_section_contents): New function.
+ (Object::do_discard_decompressed_sections): New function.
+ (Compressed_section_info): New type.
+ (Compressed_section_map): Include decompressed section contents.
+ (Sized_relobj_file::do_decompressed_section_contents): New function.
+ (Sized_relobj_file::do_discard_decompressed_sections): New function.
+
+2012-02-16 Cary Coutant <ccoutant@google.com>
+
+ * testsuite/Makefile.am (initpri2): Add --ctors-in-init-array option.
+ * testsuite/Makefile.in: Regenerate.
+
+2012-02-14 Cary Coutant <ccoutant@google.com>
+
+ * options.cc (General_options::finalize): Disallow -pie and -static.
+
+2012-02-03 Doug Kwan <dougkwan@google.com>
+
+ * arm.cc (Arm_relocate_functions::abs8,
+ Arm_relocate_functions::abs16): Use
+ Bits::has_signed_unsigned_overflow32.
+ (Arm_relocate_functions::thm_abs8): Correct range of
+ overflow check.
+ * reloc.h (Bits class): Change minimum number of bits from 0 to 1
+ in assertions.
+
+2012-02-02 Doug Kwan <dougkwan@google.com>
+
+ * arm.cc (Reloc_stub::stub_type_for_reloc): Use PIC stubs in all
+ position independent outputs, not just shared objects.
+
+2012-01-30 H.J. Lu <hongjiu.lu@intel.com>
+
+ * configure.ac: Check if -fpic -mtls-dialect=gnu2 works.
+ * configure: Regenerated.
+
+2012-01-27 Ian Lance Taylor <iant@google.com>
+
+ * reloc.h (Bits): New class with static functions, copied from
+ namespace utils in arm.cc.
+ * arm.cc (namespace utils): Remove. Rewrite all uses to use Bits
+ instead.
+
+2012-01-27 H.J. Lu <hongjiu.lu@intel.com>
+
+ * incremental.cc (write_info_blocks): Correct relocation offset.
+
+2012-01-27 H.J. Lu <hongjiu.lu@intel.com>
+
+ * x86_64.cc (Relocate::tls_gd_to_ie): Support x32.
+ (Relocate::tls_gd_to_le): Likewise.
+
+2012-01-27 H.J. Lu <hongjiu.lu@intel.com>
+
+ * x86_64.cc (Scan::global): Support x32 IFUNC function pointer.
+
+2012-01-27 H.J. Lu <hongjiu.lu@intel.com>
+
+ * configure.ac: Check if -mcmodel=medium works.
+ * configure: Regenerated.
+
+2012-01-24 Cary Coutant <ccoutant@google.com>
+
+ * int_encoding.cc (read_unsigned_LEB_128): Replaced with inline
+ definition and ...
+ (read_unsigned_LEB_128_x): ... this new function.
+ (read_signed_LEB_128): Replaced with inline definition and ...
+ (read_signed_LEB_128_x): ... this new function.
+ * int_encoding.h (read_unsigned_LEB_128_x): New function.
+ (read_unsigned_LEB_128): Add inline definition.
+ (read_signed_LEB_128_x): New function.
+ (read_signed_LEB_128): Add inline definition.
+ * testsuite/Makefile.am (leb128_unittest): New unit test.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/leb128_unittest.cc: New unit test.
+
+2012-01-23 Ian Lance Taylor <iant@google.com>
+
+ PR gold/13617
+ * i386.cc (Target_i386::do_code_fill): When using a jmp
+ instruction, pad with nop instructions.
+ * x86_64.cc (Target_x86_64::do_code_fill): Likewise.
+
+2012-01-22 H.J. Lu <hongjiu.lu@intel.com>
+
+ * x86_64.cc (gc_process_relocs): Add typename on types used in
+ template.
+ (scan_relocs): Likewise.
+ (relocate_section): Likewise.
+ (apply_relocation): Likewise.
+
+2012-01-10 H.J. Lu <hongjiu.lu@intel.com>
+
+ * x86_64.cc (Scan::check_non_pic): Allow R_X86_64_32 for x32.
+ (Scan::local): Use R_X86_64_RELATIVE relocation for R_X86_64_32
+ under x32.
+
+2012-01-09 H.J. Lu <hongjiu.lu@intel.com>
+
+ * x86_64.cc: Initial support for x32.
+
+2012-01-03 Cary Coutant <ccoutant@google.com>
+
+ * gold/incremental.cc (Sized_incremental_binary::do_process_got_plt):
+ Use abstract base class for GOT.
+ * gold/output.h (class Output_data_got_base): New abstract base class.
+ (class Output_data_got): Derive from new base class, adjust ctors.
+ (Output_data_got::reserve_slot): Make virtual; rename to
+ do_reserve_slot; Adjust callers.
+ * gold/target.h (Sized_target::init_got_plt_for_update): Return
+ pointer to abstract base class.
+ * gold/x86_64.cc (Target_x86_64::init_got_plt_for_update): Likewise.
+
+2011-12-18 Ian Lance Taylor <iant@google.com>
+
+ * object.h (Relobj::local_symbol_value): New function.
+ (Relobj::local_plt_offset): New function.
+ (Relobj::local_has_got_offset): New function.
+ (Relobj::local_got_offset): New function.
+ (Relobj::set_local_got_offset): New function.
+ (Relobj::do_local_symbol_value): New pure virtual function.
+ (Relobj::do_local_plt_offset): Likewise.
+ (Relobj::do_local_has_got_offset): Likewise.
+ (Relobj::do_local_got_offset): Likewise.
+ (Relobj::do_set_local_got_offset): Likewise.
+ (Sized_relobj::do_local_has_got_offset): Rename from
+ local_has_got_offset.
+ (Sized_relobj::do_local_got_offset): Rename from local_got_offset.
+ (Sized_relobj::do_set_local_got_offset): Rename from
+ set_local_got_offset.
+ (Sized_relobj_file::do_local_plt_offset): Rename from
+ local_plt_offset.
+ (Sized_relobj_file::do_local_symbol_value): New function.
+ * object.cc (Sized_relobj_file::do_local_plt_offset): Rename from
+ local_plt_offset.
+ * output.cc (Output_data_got::Got_entry::write): Change object to
+ Relobj. Use local_symbol_value.
+ (Output_data_got::add_global_with_rel): Change rel_dyn to
+ Output_data_reloc_generic*. Use add_global_generic.
+ (Output_data_got::add_global_with_rela): Remove. Change all
+ callers to use add_global_with_rel.
+ (Output_data_got::add_global_pair_with_rel): Change rel_dyn to
+ Output_data_reloc_generic*. Use add_global_generic.
+ (Output_data_got::add_global_pair_with_rela): Remove. Change all
+ callers to use add_global_pair_with_rel.
+ (Output_data_got::add_local): Change object to Relobj*.
+ (Output_data_got::add_local_plt): Likewise.
+ (Output_data_got::add_local_with_rel): Change object to Relobj*,
+ change rel_dyn to Output_data_reloc_generic*. Use
+ add_local_generic.
+ (Output_data_got::add_local_with_rela): Remove. Change all
+ callers to use all_local_with_rel.
+ (Output_data_got::add_local_pair_with_rel): Change object to
+ Relobj*, change rel_dyn to Output_data_reloc_generic*. Use
+ add_output_section_generic.
+ (Output_data_got::add_local_pair_with_rela): Remove. Change all
+ callers to use add_local_pair_with_rel.
+ (Output_data_got::reserve_local): Change object to Relobj*.
+ * output.h: (class Output_data_reloc_generic): Add pure virtual
+ declarations for add_global_generic, add_local_generic,
+ add_output_section_generic.
+ (class Output_data_reloc) [SHT_REL, SHT_RELA]: Implement new
+ functions for Output_data_reloc_generic. Update declarations for
+ changes listed in output.cc.
+ (class Output_data_got): Change template parameter to got_size.
+ Don't define Rel_dyn or Rela_dyn. Update declarations per above.
+ * incremental.h (Sized_relobj_incr::do_local_symbol_value): New
+ function.
+ (Sized_relobj_incr::do_local_plt_offset): New function.
+ * copy-relocs.cc (Copy_relocs::Copy_reloc_entry::emit): Call
+ add_global_generic.
+
+2011-12-17 Cary Coutant <ccoutant@google.com>
+
+ * dwarf_reader.cc (Sized_dwarf_line_info::read_lines): Add casts.
+ * resolve.cc (Symbol_table::resolve): Likewise.
+ * i386.cc (Target_i386::do_code_fill): Use char constants for nop
+ arrays.
+ * x86_64.cc (Target_x86_64::do_code_fill): Likewise.
+
+2011-12-16 Ian Lance Taylor <iant@google.com>
+
+ * output.h (Output_data_reloc_generic::add): Only call
+ add_dynamic_reloc if this is a dynamic reloc section.
+
+2011-12-15 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR gold/13505
+ * target-reloc.h (apply_relocation): Replace <64, false> with
+ <size, big_endian>.
+
+2011-11-25 Nick Clifton <nickc@redhat.com>
+
+ * po/it.po: New Italian translation.
+
+2011-11-17 Sterling Augustine <saugustine@google.com>
+
+ * script.cc (script_include_directive): Implement.
+ (read_script_file): New local variables name and search_path. Update
+ comment. Call IS_ABSOLUTE_PATH and Dirsearch::find_file_in_dir_list.
+ * dirsearch.h (Dirsearch::find_file_in_dir_list): Declare new method.
+ * dirsearch.cc (Dirsearch::find_file_in_dir_list): Implement it.
+
+2011-11-11 Sterling Augustine <saugustine@google.com>
+
+ * yyscript.y (section_cmd): Add support for INCLUDE directive.
+ (file_or_sections_cmd): Likewise.
+
2011-11-11 Doug Kwan <dougkwan@google.com>
* arm.cc (Target_arm::do_make_elf_object): Allow executable also
(Relocate_functions::rel32_unaligned): Ditto.
(Relocate_functions::pcrel32_unaligned): Ditto.
-2011-11-15 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
+2011-11-09 Doug Kwan <dougkwan@google.com>
+
+ PR gold/13362
+ * arm.cc (Arm_scan_relocatable_relocs::Default_scan_relocatable_relocs):
+ Use unaligned 4-byte relocs for static 32-bit data as required by EABI.
+ * reloc.h (Relocatable_relocs::Reloc_strategy): New enum
+ RELOC_ADJUST_FOR_SECTION_4_UNALIGNED.
+ (Relocate_functions::rel_unaligned): New.
+ (Relocate_functions::rel32_unaligned): New.
+ * target-reloc.h (relocate_for_relocatable): Add code to handle
+ RELOC_ADJUST_FOR_SECTION_4_UNALIGNED.
+ * testsuite/Makefile.am (arm_unaligned_reloc_r.stdout,
+ arm_unaligned_reloc_r): New targets.
+ * testsuite/Makefile.in: Regenerate.
+ * arm_unaligned_reloc.sh: Check unaligned relocs in relocatable
+ linking.
+
+2011-11-02 Ian Lance Taylor <iant@google.com>
+
+ * configure.ac: Add --with-lib-path option. Define LIB_PATH and
+ NATIVE_LINKER.
+ * Makefile.am (AM_CPPFLAGS): Define TOOLLIBDIR.
+ * options.cc (General_options::finalize): Use library search path
+ from configure script if specified. If not native and no sysroot,
+ only search TOOLLIBDIR.
+ * options.h (Search_directory::Search_directory): Change name to
+ const std::string&.
+ (General_options::add_to_library_path_with_sysroot): Change arg to
+ const std::string&.
+ * configure, Makefile.in, config.in: Rebuild.
+
+2011-11-02 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
- Apply mainline patches.
- 2011-11-02 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
* arm.cc (Target_arm::may_use_v5t_interworking): Check whether
we are working around the ARM1176 Erratum.
* options.h (General_options::fix_arm1176): Add option.
* testsuite/Makefile.in: Regenerate.
* testsuite/arm_fix_1176.s: New file.
* testsuite/arm_fix_1176.sh: Likewise.
- 2011-11-02 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
+
+2011-11-02 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
+
* arm.cc (Target_arm::Target_arm): Remove initialisation of
may_use_blx_.
(Target_arm::may_use_blx): Remove method.
* testsuite/arm_farcall_thumb_thumb.s: Likewise.
* testsuite/arm_farcall_thumb_thumb.sh: Likewise.
-2011-10-25 Alan Modra <amodra@gmail.com>
+2011-10-31 Cary Coutant <ccoutant@google.com>
- Apply mainline patches.
- 2011-09-26 Cary Coutant <ccoutant@google.com>
- gcc PR lto/47247
- * plugin.cc (get_symbols_v2): New function.
- (Plugin::load): Add LDPT_GET_SYMBOLS_V2.
- (is_referenced_from_outside): New function.
- (Pluginobj::get_symbol_resolution_info): Add version parameter, return
- LDPR_PREVAILING_DEF_IRONLY_EXP when using new version.
- (get_symbols): Pass version parameter.
- (get_symbols_v2): New function.
- * plugin.h (Pluginobj::get_symbol_resolution_info): Add version
- parameter.
- * testsuite/plugin_test.c (get_symbols_v2): New static variable.
- (onload): Add LDPT_GET_SYMBOLS_V2.
- (all_symbols_read_hook): Use get_symbols_v2; check for
- LDPR_PREVAILING_DEF_IRONLY_EXP.
- * testsuite/plugin_test_3.sh: Update expected results.
+ PR gold/13023
+ * expression.cc (Expression::eval_with_dot): Add
+ is_section_dot_assignment parameter.
+ (Expression::eval_maybe_dot): Likewise. Adjust value when rhs is
+ absolute and assigning to dot within a section.
+ * script-sections.cc
+ (Output_section_element_assignment::set_section_addresses): Pass
+ dot_section to set_if_absolute.
+ (Output_section_element_dot_assignment::finalize_symbols): Pass TRUE
+ as is_section_dot_assignment flag to eval_with_dot.
+ (Output_section_element_dot_assignment::set_section_addresses):
+ Likewise.
+ * script.cc (Symbol_assignment::set_if_absolute): Add dot_section
+ parameter. Also set value if relative to dot_section; set the
+ symbol's output_section.
+ * script.h (Expression::eval_with_dot): Add is_section_dot_assignment
+ parameter. Adjust all callers.
+ (Expression::eval_maybe_dot): Likewise.
+ (Symbol_assignment::set_if_absolute): Add dot_section parameter.
+ Adjust all callers.
+ * testsuite/script_test_2.t: Test assignment of an absolute value
+ to dot within an output section element.
+
+2011-10-31 Cary Coutant <ccoutant@google.com>
+
+ * options.h (class General_options): Add --[no-]gnu-unique options.
+ * symtab.cc (Symbol_table::sized_write_globals): Convert
+ STB_GNU_UNIQUE to STB_GLOBAL if --no-gnu-unique.
+
+2011-10-31 Cary Coutant <ccoutant@google.com>
+
+ PR gold/13359
+ * i386.cc (Target_i386::Relocate::relocate_tls): Remove
+ unnecessary assertion.
+ * x86_64.cc (Target_x86_64::Relocate::relocate_tls): Likewise.
+
+2011-10-31 Sriraman Tallam <tmsriram@google.com>
+
+ * symtab.h (Symbol_table::gc_mark_symbol_for_shlib): Rename to
+ gc_mark_symbol.
+ * symtab.cc (Symbol_table::gc_mark_symbol_for_shlib): Rename to
+ gc_mark_symbol.
+ Change to just keep the section associated with symbol.
+ (Symbol_table::add_from_relobj): Mark symbols as not garbage when
+ they are externally visible and --export-dynamic is turned on.
+ (Symbol_table::gc_mark_dyn_syms): Call gc_mark_symbol.
+
+2011-10-19 Ian Lance Taylor <iant@google.com>
+
+ PR gold/13163
+ * script-sections.cc
+ (Output_section_element_dot_assignment::needs_output_section): New
+ function.
+
+2011-10-19 Ian Lance Taylor <iant@google.com>
+
+ PR gold/13204
+ * layout.cc (Layout::segment_precedes): Don't assert failure if a
+ --section-start option was seen.
+ * options.h (General_options::any_section_start): New function.
2011-10-18 David S. Miller <davem@davemloft.net>
__tls_get_addr call delay slot instruction forward 4 bytes when
performing relaxation.
+2011-10-18 Cary Coutant <ccoutant@google.com>
+
+ * output.cc (posix_fallocate): Return 0 on success, errno on failure.
+ (Output_file::map_no_anonymous): Check for non-zero
+ return code from posix_fallocate.
+
+2011-10-17 Cary Coutant <ccoutant@google.com>
+
+ PR gold/13245
+ * plugin.cc (is_visible_from_outside): Check for symbols
+ referenced from dynamic objects.
+ * resolve.cc (Symbol_table::resolve): Don't count references
+ from dynamic objects as references from real ELF files.
+ * testsuite/plugin_test_2.sh: Adjust expected result.
+
+2011-10-17 Cary Coutant <ccoutant@google.com>
+
+ * gold.cc: Include timer.h.
+ (queue_middle_tasks): Stamp time.
+ (queue_final_tasks): Likewise.
+ * main.cc (main): Store timer in parameters. Print timers
+ for each pass.
+ * parameters.cc (Parameters::Parameters): Initialize timer_.
+ (Parameters::set_timer): New function.
+ (set_parameters_timer): New function.
+ * parameters.h (Parameters::set_timer): New function.
+ (Parameters::timer): New function.
+ (Parameters::timer_): New data member.
+ (set_parameters_timer): New function.
+ * timer.cc (Timer::stamp): New function.
+ (Timer::get_pass_time): New function.
+ * timer.h (Timer::stamp): New function.
+ (Timer::get_pass_time): New function.
+ (Timer::pass_times_): New data member.
+
+2011-10-17 Cary Coutant <ccoutant@google.com>
+
+ * readsyms.cc (Read_symbols::run): Don't queue an unblocker
+ task for members of lib groups.
+
+2011-10-17 Cary Coutant <ccoutant@google.com>
+
+ PR gold/13288
+ * fileread.cc (File_read::find_view): Add assert.
+ (File_read::make_view): Move bounds check (replace with assert)...
+ (File_read::find_or_make_view): ... to here.
+
+2011-10-12 Cary Coutant <ccoutant@google.com>
+
+ * output.cc (Output_file::open_base_file): Handle case where
+ ::read returns less than requested size.
+
+2011-10-10 Cary Coutant <ccoutant@google.com>
+
+ * incremental.cc (Sized_relobj_incr::Sized_relobj_incr):
+ Initialize defined_count_.
+ (Sized_relobj_incr::do_add_symbols): Count defined symbols.
+ (Sized_relobj_incr::do_get_global_symbol_counts): Rewrite.
+ (Sized_incr_dynobj::Sized_incr_dynobj): Initialize defined_count_.
+ (Sized_incr_dynobj::do_add_symbols): Count defined symbols.
+ (Sized_incr_dynobj::do_get_global_symbol_counts): Rewrite.
+ * incremental.h (Sized_relobj_incr::defined_count_): New data
+ member.
+ (Sized_incr_dynobj::defined_count_): New data member.
+ * plugin.cc (Sized_pluginobj::do_get_global_symbol_counts):
+ Return zeroes instead of internal error.
+
+2011-10-10 Cary Coutant <ccoutant@google.com>
+
+ PR gold/13249
+ * output.cc (Output_reloc::Output_reloc): Add use_plt_offset flag.
+ (Output_reloc::symbol_value): Return PLT offset if flag is set.
+ * output.h (class Output_reloc): Add use_plt_offset flag.
+ (Output_reloc::type_): Adjust size of bit field.
+ (Output_reloc::use_plt_offset_): New bit field.
+ (class Output_data_reloc): Adjust all calls to Output_reloc_type.
+ (Output_data_reloc::add_local_relative): (RELA only) Add use_plt_offset
+ flag. Adjust all callers.
+ * x86_64.cc (Target_x86_64::Scan::local): Check for IFUNC when
+ creating RELATIVE relocations.
+
+2011-10-10 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: Updated Spanish translation.
+ * po/fi.po: Updated Finnish translation.
+
+2011-10-03 Diego Novillo <dnovillo@google.com>
+
+ * options.cc (parse_uint): Fix dereference of RETVAL.
+
+2011-09-29 Sriraman Tallam <tmsriram@google.com>
+
+ * layout.h (section_order_map_): New member.
+ (get_section_order_map): New member function.
+ * output.cc (Output_section::add_input_section): Check for patterns
+ only when --section-ordering-file is specified.
+ * gold.cc (queue_middle_tasks): Delay updating order of sections till
+ output_sections have been formed.
+ * layout.cc (Layout_Layout): Initialize section_order_map_.
+ * plugin.cc (update_section_order): Store order in order_map. Do not
+ update the order.
+ * testsuite/Makefile.am: Add test case for plugin_final_layout.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/plugin_section_order.c: New file.
+ * testsuite/plugin_final_layout.cc: New file.
+ * testsuite/plugin_final_layout.sh: New file.
+
+2011-09-29 Cary Coutant <ccoutant@google.com>
+
+ * incremental.cc (Sized_incremental_binary::do_process_got_plt):
+ Check for NULL.
+ * symtab.cc (Symbol_table::add_from_relobj): Ignore version
+ symbols during incremental update.
+ (Symbol_table::add_from_dynobj): Likewise.
+
2011-09-27 Viktor Kutuzov <vkutuzov@accesssoftek.com>
Ian Lance Taylor <iant@google.com>
* symtab.cc (Symbol_table::define_special_symbol): Always
canonicalize version string.
+2011-09-26 Cary Coutant <ccoutant@google.com>
+
+ * gold.cc (queue_initial_tasks): Move option checks ...
+ * options.cc (General_options::finalize): ... to here. Disable
+ some options; make others fatal.
+
+2011-09-26 Cary Coutant <ccoutant@google.com>
+
+ gcc PR lto/47247
+ * plugin.cc (get_symbols_v2): New function.
+ (Plugin::load): Add LDPT_GET_SYMBOLS_V2.
+ (is_referenced_from_outside): New function.
+ (Pluginobj::get_symbol_resolution_info): Add version parameter, return
+ LDPR_PREVAILING_DEF_IRONLY_EXP when using new version.
+ (get_symbols): Pass version parameter.
+ (get_symbols_v2): New function.
+ * plugin.h (Pluginobj::get_symbol_resolution_info): Add version
+ parameter.
+ * testsuite/plugin_test.c (get_symbols_v2): New static variable.
+ (onload): Add LDPT_GET_SYMBOLS_V2.
+ (all_symbols_read_hook): Use get_symbols_v2; check for
+ LDPR_PREVAILING_DEF_IRONLY_EXP.
+ * testsuite/plugin_test_3.sh: Update expected results.
+
+2011-09-23 Simon Baldwin <simonb@google.com>
+
+ * configure.ac: Add new --with-gold-ldadd and --with-gold-ldflags
+ configuration options.
+ * configure: Regenerate.
+ * Makefile.am: Handle GOLD_LDADD and GOLD_LDFLAGS.
+ * Makefile.in: Regenerate.
+ * testsuite/Makefile.in: Regenerate.
+
2011-09-19 Sriraman Tallam <tmsriram@google.com>
* plugin.h (should_defer_layout): Modify to check for any_claimed_.
(get_section_name): New function.
(get_section_contents): New function.
(update_section_order): New function.
- (allow_section_ordering): New function.
+ (allow_section_ordering): New function.
(Plugin::load): Add the new interfaces to the transfer vector.
(Plugin_manager::load_plugins): New parameter.
(Plugin_manager::all_symbols_read): New parameter.
* output.cc: Likewise.
2011-05-31 Doug Kwan <dougkwan@google.com>
- Asier Llano
+ Asier Llano
PR gold/12826
* arm.cc (Target_arm::tag_cpu_arch_combine): Fix handling of
(Incremental_input_entry_reader::get_global_symbol_count): Rewrite.
(Incremental_input_entry_reader::get_output_symbol_index): Adjust
size of shared library info entry.
- * layout.cc (Layout::finish_dynamic_section): Don't test for
+ * layout.cc (Layout::finish_dynamic_section): Don't test for
incremental link when adding DT_NEEDED entries.
* object.h (Object::Object): Initialize new data member.
(Object::dynobj): New function.
* arm.cc (Arm_output_section::Arm_output_section): Set SHF_LINK_ORDER
flag of a SHT_ARM_EXIDX section.
- * testsuite/Makefile.am (arm_exidx_test): New test rules.
+ * testsuite/Makefile.am (arm_exidx_test): New test rules.
* testsuite/Makefile.in: Regenerate.
* testsuite/arm_exidx_test.s: New file.
* testsuite/arm_exidx_test.sh: Same.
2011-02-02 Sriraman Tallam <tmsriram@google.com>
* icf.h (is_section_foldable_candidate): Change type of parameter
- to std::string.
+ to std::string.
* icf.cc (Icf::find_identical_sections): Change type of local variable
- section_name to be std::string.
+ section_name to be std::string.
(is_function_ctor_or_dtor): Change type of parameter to std::string.
2011-01-25 Ian Lance Taylor <iant@google.com>
(Arm_exidx_merge_section::section_contents_): New data member.
(Arm_input_section::Arm_input_section): Initialize original_contents_.
(Arm_input_section::~Arm_input_section): De-allocate memory.
- (Arm_input_section::original_contents_): New data member.
+ (Arm_input_section::original_contents_): New data member.
(Arm_exidx_fixup::process_exidx_section): Pass EXIDX section contents
in parameters instead of calling Object::section_contents without
locking.
and updating local symbols.
(Arm_input_section<big_endian>::init): Copy contents of original
input section.
- (Arm_input_section<big_endian>::do_write): Use saved contents of
+ (Arm_input_section<big_endian>::do_write): Use saved contents of
original input section instead of calling Object::section_contents
without locking.
(Arm_exidx_cantunwind::do_fixed_endian_write): Find out text section
(Arm_exidx_merged_section::Arm_exidx_merged_section): Add sanity check
for size. Allocate a buffer for merged EXIDX entries.
(Arm_exidx_merged_section::build_contents): New method.
- (Arm_exidx_merged_section::do_write): Move merge section contents
+ (Arm_exidx_merged_section::do_write): Move merge section contents
building code to Arm_exidx_merged_section::build_contetns. Write
out contetns in buffer instead of building it on the fly.
(Arm_relobj::make_exidx_input_section): Also pass text section size
2010-10-29 Viktor Kutuzov <vkutuzov@accesssoftek.com>
* testsuite/Makefile.am: Move gcctestdir/ld rule to
- NATIVE_OR_CROSS_LINKER.
+ NATIVE_OR_CROSS_LINKER.
* testsuite/Makefile.in: Regenerate.
2010-10-20 Doug Kwan <dougkwan@google.com>
2010-10-14 Cary Coutant <ccoutant@google.com>
* debug.h (DEBUG_INCREMENTAL): New flag.
- (debug_string_to_enum): Add DEBUG_INCREMENTAL).
- * gold.cc (queue_initial_tasks): Check parameters for incremental link
- mode.
- * incremental.cc (report_command_line): Ignore all forms of
- --incremental.
- * layout.cc (Layout::Layout): Check parameters for incremental link
- mode.
- * options.cc (General_options::parse_incremental): New function.
- (General_options::parse_no_incremental): New function.
- (General_options::parse_incremental_full): New function.
- (General_options::parse_incremental_update): New function.
- (General_options::incremental_mode_): New data member.
- (General_options::finalize): Check incremental_mode_.
- * options.h (General_options): Update help text for --incremental.
- Add --no-incremental, --incremental-full, --incremental-update.
- (General_options::Incremental_mode): New enum type.
- (General_options::incremental_mode): New function.
- (General_options::incremental_mode_): New data member.
- * parameters.cc (Parameters::incremental_mode_): New data member.
- (Parameters::set_options): Set incremental_mode_.
- (Parameters::set_incremental_full): New function.
- (Parameters::incremental): New function.
- (Parameters::incremental_update): New function.
- (set_parameters_incremental_full): New function.
- * parameters.h (Parameters::set_incremental_full): New function.
- (Parameters::incremental): New function.
- (Parameters::incremental_update): New function.
- (Parameters::incremental_mode_): New data member.
- (set_parameters_incremental_full): New function.
- * plugin.cc (Plugin_manager::add_input_file): Check parameters for
- incremental link mode.
- * reloc.cc (Sized_relobj::do_read_relocs): Likewise.
- (Sized_relobj::do_relocate_sections): Likewise.
- * testsuite/Makefile.am (incremental_test): Use --incremental-full
- option.
- * testsuite/Makefile.in: Regenerate.
- * testsuite/incremental_test.sh: Filter all forms of --incremental.
+ (debug_string_to_enum): Add DEBUG_INCREMENTAL).
+ * gold.cc (queue_initial_tasks): Check parameters for incremental link
+ mode.
+ * incremental.cc (report_command_line): Ignore all forms of
+ --incremental.
+ * layout.cc (Layout::Layout): Check parameters for incremental link
+ mode.
+ * options.cc (General_options::parse_incremental): New function.
+ (General_options::parse_no_incremental): New function.
+ (General_options::parse_incremental_full): New function.
+ (General_options::parse_incremental_update): New function.
+ (General_options::incremental_mode_): New data member.
+ (General_options::finalize): Check incremental_mode_.
+ * options.h (General_options): Update help text for --incremental.
+ Add --no-incremental, --incremental-full, --incremental-update.
+ (General_options::Incremental_mode): New enum type.
+ (General_options::incremental_mode): New function.
+ (General_options::incremental_mode_): New data member.
+ * parameters.cc (Parameters::incremental_mode_): New data member.
+ (Parameters::set_options): Set incremental_mode_.
+ (Parameters::set_incremental_full): New function.
+ (Parameters::incremental): New function.
+ (Parameters::incremental_update): New function.
+ (set_parameters_incremental_full): New function.
+ * parameters.h (Parameters::set_incremental_full): New function.
+ (Parameters::incremental): New function.
+ (Parameters::incremental_update): New function.
+ (Parameters::incremental_mode_): New data member.
+ (set_parameters_incremental_full): New function.
+ * plugin.cc (Plugin_manager::add_input_file): Check parameters for
+ incremental link mode.
+ * reloc.cc (Sized_relobj::do_read_relocs): Likewise.
+ (Sized_relobj::do_relocate_sections): Likewise.
+ * testsuite/Makefile.am (incremental_test): Use --incremental-full
+ option.
+ * testsuite/Makefile.in: Regenerate.
+ * testsuite/incremental_test.sh: Filter all forms of --incremental.
2010-10-12 Viktor Kutuzov <vkutuzov@accesssoftek.com>
section without SHF_EXECINSTR.
(Arm_output_section::fix_exidx_coverage): Skip input sections with
errors.
- (Arm_relobj::make_exidx_input_section): Add new parameter for text
+ (Arm_relobj::make_exidx_input_section): Add new parameter for text
section header. Make error messages more verbose. Check for
a non-executable section linked to an EXIDX section.
(Arm_relobj::do_read_symbols): Remove error checking, which has been
in a relocatable link.
(Target_arm::do_relax): Look for the EXIDX output section instead of
assuming that it is called .ARM.exidx.
- (Target_arm::fix_exidx_coverage): Add a new parameter for input
+ (Target_arm::fix_exidx_coverage): Add a new parameter for input
section list. Do not check for SHF_EXECINSTR section flags but
skip any input section with errors.
* output.cc (Output_section::Output_section): Initialize
2010-05-26 Rafael Espindola <espindola@google.com>
- PR 11604
+ PR 11604
* gold/object.cc(Sized_relobj::do_layout_deferred_sections): Avoid
adding sections the garbage collector removed.
* gold/testsuite/Makefile.am: Add test.
to use Output_section_lookup_maps class.
(Output_section::add_relaxed_input_section): Adjst code for lookup
maps code refactoring.
- (Output_section::add_merge_input_section): Add a new parameter
+ (Output_section::add_merge_input_section): Add a new parameter
KEEPS_INPUT_SECTION. Adjust code to use Output_section_lookup_maps
class. If adding input section to a newly created merge output
section fails, remove the new merge section.
(Output_section::convert_input_sections_in_list_to_relaxed_input_sections):
Adjust code for use of the Output_section_lookup_maps class.
- (Output_section::find_merge_section): Ditto.
+ (Output_section::find_merge_section): Ditto.
(Output_section::build_lookup_maps): New method defintion.
- (Output_section::find_relaxed_input_section): Adjust code to use
+ (Output_section::find_relaxed_input_section): Adjust code to use
Output_section_lookup_maps class.
(Output_section::get_input_sections): Export merge sections. Adjust
code to use Output_section_lookup_maps class.
defintion. Declare method only.
(Output_section::Input_section::shndx): Ditto.
(Output_section::Input_section::output_merge_base): New method defintion.
- (Output_section::Input_section::u2_.pomb): New union field.
+ (Output_section::Input_section::u2_.pomb): New union field.
(Output_section::Merge_section_by_properties_map,
Output_section::Output_section_data_by_input_section_map,
Output_section::Ouptut_relaxed_input_section_by_input_section_map):
Remove types.
- (Output_section::add_merge_input_section): Add new parameter
+ (Output_section::add_merge_input_section): Add new parameter
KEEPS_INPUT_SECTIONS.
(Output_section::build_lookup_maps): New method declaration.
(Output_section::merge_section_map_,
section elements. Handle discard sections.
(Sort_output_sections::operator()): Handle NOLOAD sections.
* script-sections.h (Script_sections::Section_type): New enum type.
- (Script_sections::output_section_name): Add a new parameter for
+ (Script_sections::output_section_name): Add a new parameter for
returning script section type.
* script.cc (script_keyword_parsecodes): Add keywords COPY, DSECT,
INFO and NOLOAD.
thumb2_blx_in_range, thumb2_blx_in_range.o,
thumb2_blx_out_of_range.stdout, thumb2_blx_out_of_range,
thumb2_blx_out_of_range.o): New rules.
- (MOSTLYCLEANFILES): Add thumb_blx_in_range, thumb_blx_out_of_range,
+ (MOSTLYCLEANFILES): Add thumb_blx_in_range, thumb_blx_out_of_range,
thumb2_blx_in_range and thumb2_blx_out_of_range.
* testsuite/Makefile.in: Regenerate.
* arm_branch_in_range.sh: Add tests for THUMB BLX.
Stub_table::reloc_stubs_size_ and Stub_table::reloc_stubs_addralign_.
(Stub_table::reloc_stubs_size_, Stub_table::reloc_stubs_addralign_):
New data members.
- (Stub_table::update_data_size_and_addralign): Use
+ (Stub_table::update_data_size_and_addralign): Use
Stub_table::reloc_stubs_size_ and Stub_table::reloc_stubs_addralign_
instead of going over all reloc stubs.
- (Stub_table::finalize_stubs): Do not assign reloc stub offsets.
+ (Stub_table::finalize_stubs): Do not assign reloc stub offsets.
* stringpool.cc (Stringpool_template::Stringpool_template): Initialize
Stringpool_template::offset_ to size of Stringpool_char.
- (Stringpool_template::new_key_offset): Remove code to initialize
+ (Stringpool_template::new_key_offset): Remove code to initialize
Stringpool_template::offset_.
* stringpool.h (Stringpool_template::set_no_zero_null): Set
Stringpool_template::offset_ to zero.
when not optimizing.
* stringpool.h (Chunked_vector::Chunked_vector): Initialize data
member size_.
- (Chunked_vector::clear): Clear size_.
- (Chunked_vector::reserve): Call reserve method of all Element_vectors.
- (Chunked_vector::size): Return size_.
- (Chunked_vector::push_back): Use size_ to find insert position.
+ (Chunked_vector::clear): Clear size_.
+ (Chunked_vector::reserve): Call reserve method of all Element_vectors.
+ (Chunked_vector::size): Return size_.
+ (Chunked_vector::push_back): Use size_ to find insert position.
(Chunked_vector::size_): New data member.
(Stringpool_template::set_no_zero_null): Assert string set is empty.
(Stringpool_template::new_key_offset): New method declaration.
flags and attributes merging if an input file is a binary file.
* fileread.cc (Input_file::open): Record format of original file.
* fileread.h (Input_file::Format): New enum type.
- (Input_file::Input_file): Initialize data member format_.
+ (Input_file::Input_file): Initialize data member format_.
(Input_file::format): New method definition.
(Input_file::format_):: New data member.
(Arm_output_section::fix_exidx_coverage): Add a parameter for layout.
If user uses a script with a SECTIONS clause, issue only a warning
for a misplaced EXIDX input section. Otherwise, issue an error.
- (Arm_relobj::do_gc_process_relocs): Exit early if we are not doing
+ (Arm_relobj::do_gc_process_relocs): Exit early if we are not doing
garbage collection.
(Target_arm::got_mode_index_entry): Handle static linking.
(Target_arm::Scan::local): Ditto.
* arm.cc (Arm_relocate_functions::arm_branch_common): Fix bug in
handling of the maximum backward branch offset.
- (Arm_relocate_functions::thumb_branch_common): Ditto.
+ (Arm_relocate_functions::thumb_branch_common): Ditto.
* testsuite/Makefile.am (check_SCRIPTS): Add arm_branch_in_range.sh.
(check_DATA): Add arm_bl_in_range.stdout, arm_bl_out_of_range.stdout
thumb_bl_in_range.stdout, thumb_bl_out_of_range.stdout,
(Target_arm::optimize_tls_reloc, Target_arm::define_tls_base_symbol,
Target_arm::got_mod_index_entry, Target_arm::rel_tls_desc_section):
New methods.
- (Target_arm::Got_type): Add GOT_TYPE_TLS_NOFFSET, GOT_TYPE_OFFSET,
+ (Target_arm::Got_type): Add GOT_TYPE_TLS_NOFFSET, GOT_TYPE_OFFSET,
GOT_TYPE_TLS_PAIR and GOT_TYPE_TLS_DESC.
(Target_arm::got_mod_index_offset_,
Target_arm::tls_base_symbol_defined_): New data members.
* Makefile.am (HFILES): Add arm-reloc-property.h.
(DEFFILES): New.
- (TARGETSOURCES): Add arm-reloc-property.cc
- (ALL_TARGETOBJS): Add arm-reloc-property.$(OBJEXT)
+ (TARGETSOURCES): Add arm-reloc-property.cc
+ (ALL_TARGETOBJS): Add arm-reloc-property.$(OBJEXT)
(libgold_a_SOURCES): $(DEFFILES)
* Makefile.in: Regenerate.
* arm-reloc-property.cc: New file.
* arm.cc (set): Include.
(class Arm_exidx_fixup): Change type of last_input_section_ to const
pointer type.
- (Arm_output_section::Text_section_list): New type.
+ (Arm_output_section::Text_section_list): New type.
(Arm_output_section::append_text_sections_to_list): New method.
(Arm_output_section::fix_exidx_coverage): Ditto.
(Arm_relobj::Arm_relobj): Initialize exidx_section_map_.
- (Arm_relobj::convert_input_section_to_relaxed_section): Use
+ (Arm_relobj::convert_input_section_to_relaxed_section): Use
Relobj::set_section_offset() instead of
Sized_relobj::invalidate_section_offset().
- (Arm_relobj::section_needs_reloc_stub_scanning): Add an extra
+ (Arm_relobj::section_needs_reloc_stub_scanning): Add an extra
parameter for section headers. Ignore relocation sections for
unallocated sections and EXIDX sections.
(Target_arm::fix_exidx_coverage): New method.
(Arm_output_section::append_text_sections_to_list): New method.
(Arm_output_section::fix_exidx_coverage): Ditto.
(Arm_relobj::scan_sections_for_stubs): Adjust call to
- Arm_relobj::section_needs_reloc_stub_scanning.
+ Arm_relobj::section_needs_reloc_stub_scanning.
(Target_arm::do_relax): Fix EXIDX output section coverage in the
first pass.
(Target_arm::fix_exidx_coverage): New method.
(Output_section::add_merge_input_section): Ditto.
(Output_section::build_relaxation_map): Change to use Section_id
instead of Input_section_specifier as key type.
- (Output_section::convert_input_sections_in_list_to_relaxed_sections):
+ (Output_section::convert_input_sections_in_list_to_relaxed_sections):
Ditto.
(Output_section::convert_input_sections_to_relaxed_sections): Change
to use Const_section_id instead of Input_section_specifier as key type.
- (Output_section::find_merge_section): Ditto.
+ (Output_section::find_merge_section): Ditto.
(Output_section::find_relaxed_input_section): Ditto.
* output.h (Input_section_specifier): Remove class.
(Output_section::Output_section_data_by_input_section_map): Change
2010-01-08 Doug Kwan <dougkwan@google.com>
* arm.cc (Stub_table::Stub_table): Initalize cortex_a8_stubs_,
- prev_data_size_ and prev_addralign_. Remove initializer for
- deleted data member has_been_changed_.
- (Stub_table::empty): Look at both reloc_stubs_ and cortex_a8_stubs_
- to determine if the table is empty.
- (Stub_table::has_been_changed, Stub_table_set_has_been_changed):
- Remove.
- (Stub_table::add_reloc_stub): Define method in class definition
- instead of just declaring it there.
- (Stub_table::add_cortex_a8_stub): New method definition.
- (Stub_table::update_data_size_and_addralign): Ditto.
- (Stub_table::finalize_stubs): Ditto.
- (Stub_table::apply_cortex_a8_workaround_to_address_range): Ditto.
- (Stub_table::do_addralign_): Return address alignment in the
- (Stub_table::do_reset_address_and_file_offset): Define method in
- class definition instead of declaring it there. Set current data
- size to be the data size of the previous pass.
- (Stub_table::set_final_data_size): Use current data size as the
- final data size.
- (Stub_table::relocate_stub): Change parameter type of stub from
- Reloc_stub pointer to Stub pointer.
- (Stub_table::addralign_, Stub_table::has_been_changed_): Remove.
- (Stub_table::Cortex_a8_stub_list): New typedef.
- (Stub_table::cortex_a8_stubs_, Stub_table::prev_data_size_,
- Stub_table::prev_addralign_): New data member.
- (Arm_relobj::Arm_relobj): Initialize data member
- section_has_cortex_a8_workaround_.
- (Arm_relobj::section_has_cortex_a8_workaround,
- Arm_relobj::mark_section_for_cortex_a8_workaround): New method
- definitions.
- (Arm_relobj::section_has_cortex_a8_workaround_): New data member
- declarations.
- (Target_arm::relocate_stub): Change parameter type of stub from
- Reloc_stub pointer to Stub pointer.
- (Insn_template::size, Insn_template::alignment): Handle
- THUMB16_SPECIAL_TYPE.
- (Stub_table::remove_all_cortex_a8_stubs, Stub_table::finalize_stubs,
- Stub_table::update_data_size_and_addralign,
- Stub_table::apply_cortex_a8_workaround_to_address_range): New method
- definitions.
- (Stub_table::relocate_stubs): Handle Cortex-A8 stubs.
- (Stub_table::do_write): Ditto.
- (Target_arm::do_relax): Adjust code for changes in Stub_table.
+ prev_data_size_ and prev_addralign_. Remove initializer for
+ deleted data member has_been_changed_.
+ (Stub_table::empty): Look at both reloc_stubs_ and cortex_a8_stubs_
+ to determine if the table is empty.
+ (Stub_table::has_been_changed, Stub_table_set_has_been_changed):
+ Remove.
+ (Stub_table::add_reloc_stub): Define method in class definition
+ instead of just declaring it there.
+ (Stub_table::add_cortex_a8_stub): New method definition.
+ (Stub_table::update_data_size_and_addralign): Ditto.
+ (Stub_table::finalize_stubs): Ditto.
+ (Stub_table::apply_cortex_a8_workaround_to_address_range): Ditto.
+ (Stub_table::do_addralign_): Return address alignment in the
+ (Stub_table::do_reset_address_and_file_offset): Define method in
+ class definition instead of declaring it there. Set current data
+ size to be the data size of the previous pass.
+ (Stub_table::set_final_data_size): Use current data size as the
+ final data size.
+ (Stub_table::relocate_stub): Change parameter type of stub from
+ Reloc_stub pointer to Stub pointer.
+ (Stub_table::addralign_, Stub_table::has_been_changed_): Remove.
+ (Stub_table::Cortex_a8_stub_list): New typedef.
+ (Stub_table::cortex_a8_stubs_, Stub_table::prev_data_size_,
+ Stub_table::prev_addralign_): New data member.
+ (Arm_relobj::Arm_relobj): Initialize data member
+ section_has_cortex_a8_workaround_.
+ (Arm_relobj::section_has_cortex_a8_workaround,
+ Arm_relobj::mark_section_for_cortex_a8_workaround): New method
+ definitions.
+ (Arm_relobj::section_has_cortex_a8_workaround_): New data member
+ declarations.
+ (Target_arm::relocate_stub): Change parameter type of stub from
+ Reloc_stub pointer to Stub pointer.
+ (Insn_template::size, Insn_template::alignment): Handle
+ THUMB16_SPECIAL_TYPE.
+ (Stub_table::remove_all_cortex_a8_stubs, Stub_table::finalize_stubs,
+ Stub_table::update_data_size_and_addralign,
+ Stub_table::apply_cortex_a8_workaround_to_address_range): New method
+ definitions.
+ (Stub_table::relocate_stubs): Handle Cortex-A8 stubs.
+ (Stub_table::do_write): Ditto.
+ (Target_arm::do_relax): Adjust code for changes in Stub_table.
2010-01-08 Ian Lance Taylor <iant@google.com>
(Arm_dynobj::attributes_section_data_): New data member declaration.
(Target_arm::Target_arm): Initialize attributes_section_data_. Change
initialization value of may_use_blx_ to false.
- (Target_arm::using_thumb2, Target_arm::using_thumb_only,
+ (Target_arm::using_thumb2, Target_arm::using_thumb_only,
Target_arm::may_use_arm_nop, Target_arm::may_use_thumb2_nop): Use
object attributes to compute results instead of hard-coding.
(Target_arm::do_attribute_arg_type, Target_arm::do_attributes_order,
2009-12-01 Rafael Avila de Espindola <espindola@google.com>
- * incremental-dump.cc (main): Fix typos.
+ * incremental-dump.cc (main): Fix typos.
2009-11-27 Rafael Avila de Espindola <espindola@google.com>
base class initializer.
(Output_section::add_relaxed_input_section): New method declaration.
(Output_section::Input_section): Change visibility to protected.
- (Output_section::Input_section::relobj,
+ (Output_section::Input_section::relobj,
Output_section::Input_section::shndx): Handle relaxed input sections.
Output_section::input_sections) Change visibility to protected. Also
define overload to return a non-const pointer.
Output_section_data.
(Output_data_dynamic::set_final_data_size): Add DT_NULL tag only once.
(Output_symtab_xindex::do_write): Add array bound check.
- (Output_section::Input_section::print_to_mapfile): Handle
+ (Output_section::Input_section::print_to_mapfile): Handle
RELAXED_INPUT_SECTION_CODE.
(Output_section::Output_section): Initialize data member checkpoint_.
(Output_section::~Output_section): Delete checkpoint object pointed
an elfcpp:Ehdr as parameter.
* target.cc: Include dynobj.h.
(Target::do_make_elf_object_implementation): New.
- (Target::do_make_elf_object): New.
+ (Target::do_make_elf_object): New.
* target.h (Target::make_elf_object): New template declaration.
(Target::do_make_elf_object): New method declarations.
(Target::do_make_elf_object_implementation): New template declaration.
* Makefile.am (libgold_a_LIBADD): New.
(ld_new_DEPENDENCIES, ld_new_LDADD): Remove LIBOBJS
- * Makefile.in: Regenerate.
+ * Makefile.in: Regenerate.
* config.in (HAVE_DECL_MEMMEM, HAVE_DECL_STRNDUP): New.
* configure: Regenerate.
* configure.ac (AC_CHECK_DECLS): Add strndup and memmem.
(Incremental_inputs::sized_create_incremental_inputs_data): New method.
* incremental.h: New file.
* layout.cc (Layout::Layout): Handle new incremental_inputs_.
- (Layout::finalize): Create incremental inputs section in
+ (Layout::finalize): Create incremental inputs section in
incremental builds.
- (Layout::create_incremental_info_sections): New method.
+ (Layout::create_incremental_info_sections): New method.
* layout.h (Layout::incremental_inputs): New method.
- (Layout::create_incremental_info_sections): New method.
- (Layout::incremental_inputs_): New field.
+ (Layout::create_incremental_info_sections): New method.
+ (Layout::incremental_inputs_): New field.
* main.cc (main): Notify Incremental_input of the command line.
2009-04-01 Ian Lance Taylor <iant@google.com>
dispositions.
* options.cc (General_options::parse_incremental_changed): New
function.
- (General_options::parse_incremental_unchanged): New function.
- (General_options::parse_incremental_unknown): New function.
- (General_options::General_options): Initialize new fields
+ (General_options::parse_incremental_unchanged): New function.
+ (General_options::parse_incremental_unknown): New function.
+ (General_options::General_options): Initialize new fields
incremental_disposition_ and implicit_incremental_.
- (General_options::finalize): Check for uasge of --incremental-*
+ (General_options::finalize): Check for uasge of --incremental-*
without --incremental.
2009-02-06 Chris Demetriou <cgd@google.com>
2009-01-31 Mikolaj Zalewski <mikolajz@google.com>
* script.cc (Lazy_demangler): New class.
- (Version_script_info::get_symbol_version_helper): Demangle a
+ (Version_script_info::get_symbol_version_helper): Demangle a
symbol only once.
2009-01-29 Cary Coutant <ccoutant@google.com>
2008-03-21 Ian Lance Taylor <iant@google.com>
* Added source code to GNU binutils.
+\f
+Copyright (C) 2008-2014 Free Software Foundation, Inc.
+
+Copying and distribution of this file, with or without modification,
+are permitted in any medium without royalty provided the copyright
+notice and this notice are preserved.
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End: