Commit Graph

9252 Commits

Author SHA1 Message Date
Alan Modra e3ae1ce459 daily update 2011-09-14 00:00:06 +00:00
Alan Modra 29d3e15313 daily update 2011-09-13 00:00:05 +00:00
H.J. Lu 7b5b197e80 Use .got.plt for IFUNC symbols if there are no GOT relocations.
bfd/

2011-09-12  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/13178
	* elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Use .got.plt
	if there are no GOT relocations.

ld/testsuite/

2011-09-12  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/13178
	* ld-ifunc/ifunc-13-i386.d: Updated.
	* ld-ifunc/ifunc-13-x86-64.d: Likewise.
	* ld-ifunc/ifunc-3a-x86.d: Likewise.
	* ld-x86-64/pr13082-5a.d: Likewise.

	* ld-ifunc/ifunc-15-i386.d: New.
	* ld-ifunc/ifunc-15-i386.s: Likewise.
	* ld-ifunc/ifunc-15-x86-64.d: Likewise.
	* ld-ifunc/ifunc-15-x86-64.s: Likewise.
2011-09-12 18:17:36 +00:00
Alan Modra 3079918dc3 daily update 2011-09-12 00:00:05 +00:00
Alan Modra 14a65e3755 daily update 2011-09-11 00:00:06 +00:00
Alan Modra 17b03c24fb daily update 2011-09-10 00:00:05 +00:00
Kai Tietz e777132256 2011-09-09 Kai Tietz <ktietz@redhat.com>
* peicode.h (pe_ILF_build_a_bfd): Don't remove leading underscore
        for targets without symbol_leading_char.
2011-09-09 16:28:12 +00:00
Alan Modra a301ba0b9a daily update 2011-09-09 00:00:05 +00:00
Nick Clifton 103ae312ba * bfdwin.c (bfd_get_file_window): Fix memory leak. 2011-09-08 16:06:11 +00:00
Alan Modra cc42bdc275 daily update 2011-09-08 00:00:06 +00:00
Alan Modra 28942f6293 PR ld/13131
* bfd/elf64-ppc.c (adjust_toc_syms): Ensure ppc64_elf_howto_table
	is initialized.
2011-09-07 13:56:09 +00:00
Alan Modra 27e78320b0 daily update 2011-09-07 00:00:06 +00:00
Alan Modra b140b0101b PR ld/13131
* elf64-ppc.c (adjust_toc_syms): Delete redundant code.
	(ppc64_elf_edit_toc): Fix style nit.  Report some details
	on linker failure due to reference in debug or non-alloc
	sections to optimized away toc entry, and don't abort.
2011-09-06 07:41:24 +00:00
Alan Modra 18df1c457e daily update 2011-09-06 00:00:04 +00:00
Alan Modra 4a5818a296 daily update 2011-09-05 00:00:06 +00:00
Alan Modra 7db1c6bfe2 daily update 2011-09-04 00:00:06 +00:00
Alan Modra 1aca6c577b daily update 2011-09-03 00:00:07 +00:00
Alan Modra 876dbddf2f daily update 2011-09-02 00:00:05 +00:00
Christophe Lyon 7d500b8357 2011-09-01 Christophe Lyon <christophe.lyon@st.com>
bfd/
	* elf32-arm.c (elf32_arm_output_arch_local_syms): Skip excluded
	sections.

        ld/testsuite/
	* ld-arm/arm-elf.exp: Add new rodata-merge-map test.
	* ld-arm/rodata-merge-map.ld: New file.
	* ld-arm/rodata-merge-map.sym: Likewise.
	* ld-arm/rodata-merge-map1.s Likewise.
	* ld-arm/rodata-merge-map2.s: Likewise.
	* ld-arm/rodata-merge-map3.s: Likewise.
2011-09-01 14:10:40 +00:00
Alan Modra 0ddc55ad78 daily update 2011-09-01 00:00:04 +00:00
Alan Modra 8501c0d426 daily update 2011-08-31 00:00:05 +00:00
Alan Modra 5a5dcae463 daily update 2011-08-30 00:00:06 +00:00
Alan Modra 78662a6e67 daily update 2011-08-28 00:00:06 +00:00
Alan Modra 53c8030fec daily update 2011-08-27 00:00:05 +00:00
Nick Clifton 7cf8042268 Updated Spanish translations. 2011-08-26 15:15:52 +00:00
Alan Modra a0dc6b134c daily update 2011-08-26 00:00:05 +00:00
Alan Modra 978e21aec5 daily update 2011-08-25 00:00:05 +00:00
Alan Modra 17770d1728 daily update 2011-08-24 00:00:05 +00:00
Alan Modra 34e20cec1e daily update 2011-08-23 00:00:05 +00:00
Alan Modra 61ab05f36d daily update 2011-08-22 00:00:05 +00:00
Alan Modra ca861ac30a daily update 2011-08-21 00:00:05 +00:00
Alan Modra eee4be5edd daily update 2011-08-20 00:00:05 +00:00
Alan Modra af75cb9c9b * elf64-ppc.c (ppc64_elf_edit_toc): Ignore can_optimize bit if
we haven't seen expected -mcmodel=medium/large code relocs.
2011-08-19 08:12:08 +00:00
Alan Modra fe9e19f9b8 daily update 2011-08-19 00:00:06 +00:00
Tristan Gingold 9d4b600942 2011-08-18 Tristan Gingold <gingold@adacore.com>
* mach-o.c (bfd_mach_o_read_segment): Initialize list.
2011-08-18 09:28:42 +00:00
Alan Modra 8304cc9064 daily update 2011-08-18 00:00:05 +00:00
Tristan Gingold 72b5104c84 2011-08-17 Tristan Gingold <gingold@adacore.com>
* mach-o.c (bfd_mach_o_write_section_32): Fix typo.
2011-08-17 10:17:39 +00:00
Alan Modra c77ec72614 PR ld/12762
bfd/
	* bfd-in.h (struct bfd_section_already_linked): Forward declare.
	(_bfd_handle_already_linked): Declare.
	* coff-alpha.c (_bfd_ecoff_section_already_linked): Define as
	_bfd_coff_section_already_linked.
	* coff-mips.c (_bfd_ecoff_section_already_linked): Likewise.
	* coffcode.h (coff_section_already_linked): Likewise.
	* cofflink.c (coff_link_add_symbols): Revert 2011-07-09 changes.
	* elf-bfd.h: Likewise.
	* libbfd-in.h: Likewise.
	* targets.c: Likewise.
	* linker.c (bfd_section_already_linked): Likewise.
	(bfd_section_already_linked_table_lookup): Likewise.
	(bfd_section_already_linked_table_insert): Likewise.
	(_bfd_generic_section_already_linked): Likewise.  Call
	_bfd_handle_already_linked.
	(_bfd_handle_already_linked): New function, split out from..
	* elflink.c (_bfd_elf_section_already_linked): ..here.  Revert
	2011-07-09 changes.  Avoid unnecessary strcmp when matching
	already_linked_list entries.  Match plugin linkonce section.
	(section_signature): Delete.
	* coffgen.c (_bfd_coff_section_already_linked): New function.
	* libcoff-in.h (_bfd_coff_section_already_linked): Declare.
	* libbfd.h: Regenerate.
	* libcoff.h: Regenerate.
	* bfd-in2.h: Regenerate.
ld/
	* ldlang.c (section_already_linked): Revert 2011-07-09 changes.
	* plugin.c: Likewise.
	(asymbol_from_plugin_symbol): Create linkonce section for syms
	with comdat_key.
2011-08-17 00:39:41 +00:00
Alan Modra 48db9718bb daily update 2011-08-17 00:00:05 +00:00
Alan Modra d51a548c8c daily update 2011-08-16 00:00:05 +00:00
Alan Modra 10614790ea daily update 2011-08-15 00:00:05 +00:00
Alan Modra b3874e1a22 * elf32-ppc.c (ppc_elf_select_plt_layout): Force bss-plt when
shared and call to _mcount will go via plt.
2011-08-14 09:17:17 +00:00
Alan Modra 8de848d897 * elf64-ppc.c: Prefix all einfo error strings with "%P: ".
* elf32-ppc.c: Likewise.
	(ppc_elf_select_plt_layout): Use einfo rather than info to report
	forced bss-plt.
2011-08-14 08:11:56 +00:00
Alan Modra a369ae95b6 daily update 2011-08-14 00:00:05 +00:00
Alan Modra 49ac4fb0e0 daily update 2011-08-13 00:00:06 +00:00
H.J. Lu 64d25c4414 Add R_X86_64_RELATIVE64 and handle R_X86_64_64 for x32.
bfd/

2011-08-12  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/13082
	* elf64-x86-64.c (x86_64_elf_howto_table): Add R_X86_64_RELATIVE64.
	(elf_x86_64_relocate_section): Treat R_X86_64_64 like R_X86_64_32
	and zero-extend it to 64bit if addend is zero for x32.  Generate
	R_X86_64_RELATIVE64 for x32.

include/elf/

2011-08-12  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/13082
	* x86-64.h (R_X86_64_RELATIVE64): New.

ld/testsuite/

2011-08-12  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/13082
	* ld-x86-64/pr13082-1.s: New.
	* ld-x86-64/pr13082-1a.d: Likewise.
	* ld-x86-64/pr13082-1b.d: Likewise.
	* ld-x86-64/pr13082-2.s: Likewise.
	* ld-x86-64/pr13082-2a.d: Likewise.
	* ld-x86-64/pr13082-2b.d: Likewise.
	* ld-x86-64/pr13082-3.s: Likewise.
	* ld-x86-64/pr13082-3a.d: Likewise.
	* ld-x86-64/pr13082-3b.d: Likewise.
	* ld-x86-64/pr13082-4.s: Likewise.
	* ld-x86-64/pr13082-4a.d: Likewise.
	* ld-x86-64/pr13082-4b.d: Likewise.
	* ld-x86-64/pr13082-5.s: Likewise.
	* ld-x86-64/pr13082-5a.d: Likewise.
	* ld-x86-64/pr13082-5b.d: Likewise.
	* ld-x86-64/pr13082-6.s: Likewise.
	* ld-x86-64/pr13082-6a.d: Likewise.
	* ld-x86-64/pr13082-6b.d: Likewise.

	* ld-x86-64/x86-64.exp: Run pr13082-[1-6][ab].
2011-08-12 19:42:39 +00:00
Alan Modra afd2ddc121 daily update 2011-08-10 00:00:04 +00:00
Matthew Gretton-Dann 2de70689ff * bfd/bfd-in.h (bfd_elf32_arm_set_target_relocs): Update prototype.
* bfd/bfd-in2.h (bfd_elf32_arm_set_target_relocs): Likewise.
	* bfd/elf32-arm.c (elf32_arm_link_hash_table): New field.
	(elf232_arm_link_hash_table_create): Initialise new field.
	(check_use_blx): Change test depending on fix_arm1176.
	(bfd_elf32_arm_set_target_relocs): Set fix_arm1176 from
	command line options.
	* ld/emultempl/armelf.em (fix_arm1176): New variable.
	(arm_elf_create_output_section_statements): Pass
	fix_arm1176 option to bfd backend.
	(OPTION_FIX_ARM1176): New define.
	(OPTION_NO_FIX_ARM1176): Likewise.
	(PARSE_AND_LIST_LONGOPTS): Add new command line options.
	(PARSE_AND_LIST_OPTIONS): Likewise.
	(PARSE_AND_LIST_ARGS_CASES): Likewise.
	* ld/ld.texinfo: Document new command line options.
	* ld/testsuite/ld-arm/arm-elf.exp (armelftests): Update for new command-line
	options.
	(armeabitests): Update for new command-line options, and add
	new test cases.
	* ld/testsuite/ld-arm/fix-arm1176.s: Add test case.
	* ld/testsuite/ld-arm/fix-arm1176-off.d: Likewise.
	* ld/testsuite/ld-arm/fix-arm1176-on.d: Likewise.
2011-08-09 13:10:44 +00:00
Tristan Gingold 5a5cbf7230 2011-08-08 Tristan Gingold <gingold@adacore.com>
* mach-o.c (struct mach_o_segment_name_xlat): Add comments.
	(segsec_names_xlat): Reorder elements.
	(bfd_mach_o_read_section_32): Fix typo.
	(bfd_mach_o_read_section_64): Fix typo.
2011-08-08 14:53:30 +00:00
Tristan Gingold f1bde64c90 2011-08-08 Tristan Gingold <gingold@adacore.com>
* mach-o.h (BFD_MACH_O_SEGNAME_SIZE): New macro.
	(BFD_MACH_O_SECTNAME_SIZE): Ditto.
	(bfd_mach_o_section): Use them.  Add next field.
	(bfd_mach_o_segment_command): Replace sections array by
	sect_head and sect_tail.
	(bfd_mach_o_get_mach_o_section): New macro.
	(bfd_mach_o_lookup_section): Remove.
	(bfd_mach_o_new_section_hook): New function.
	* mach-o.c (bfd_mach_o_normalize_section_name): Use strncmp
	instead of strcmp.
	(bfd_mach_o_convert_section_name_to_bfd): Replaces section
	parameter with segname and sectname parameters.  Adjust.
	(bfd_mach_o_append_section_to_segment): New function.  Use a
	linked list for Mach-O sections.
	(bfd_mach_o_write_segment_32): Adjust.
	(bfd_mach_o_write_segment_64): Ditto.
	(bfd_mach_o_build_commands): Fix comment.  Adjust.
	(bfd_mach_o_flatten_sections): Adjust.
	(bfd_mach_o_print_section_map): Adjust.
	(bfd_mach_o_set_section_flags_from_bfd): Ditto.
	(bfd_mach_o_new_section_hook): New function.
	(bfd_mach_o_init_section_from_mach_o): Ditto.
	(bfd_mach_o_read_section_32): Remove section parameter.
	Return a section instead.
	(bfd_mach_o_read_section_64): Ditto.
	(bfd_mach_o_read_section): Ditto.
	(bfd_mach_o_make_bfd_section): Adjust.
	(bfd_mach_o_read_segment): Adjust for new profile of
	bfd_mach_o_read_section.
	(bfd_mach_o_lookup_section): Remove.
	* mach-o-target.c (bfd_mach_o_new_section_hook): Remove.
2011-08-08 10:56:31 +00:00