1 2012-10-24 H.J. Lu <hongjiu.lu@intel.com>
3 * compress.c (bfd_is_section_compressed): Don't decompress the
6 2012-10-23 Nathan Sidwell <nathan@codesourcery.com>
8 * bfd-in.h (bfd_elf_stack_segment_size): Declare.
10 * elfxx-target.h (elf_backend_stack_align): New.
12 * elf-bfd.h (struct elf_backend_data): Add stack_align field.
13 * elf.c (bfd_elf_map_sections_to_segments): Pay attention to
14 stack_align and stacksize for PT_GNU_STACK segment.
15 (assign_file_positions_for_non_load_sections): Set p_memsz for
17 (copy_elf_program_header): Copy PT_GNU_STACK size.
18 * elflink.c (bfd_elf_stack_segment_size): New function, taken from
20 (bfd_elf_size_dynamic_sections): Determine
21 PT_GNU_STACK requirements after calling backend. Pay attention to
23 * elf32-bfin.c (elf32_bfinfdpic_always_size_sections): Call
24 bfd_elf_stack_segment_size.
25 (elf32_bfinfdpic_modify_program_headers): Delete.
26 (elf32_bfingfdpic_copy_private_bfd_data): Don't copy PT_GNU_STACK
28 (elf_backend_stack_align): Override.
29 (elf_backend_modify_program_headers): Don't override.
30 * elf32-frv.c (frvfdpic_always_size_sections): Call
31 bfd_elf_stack_segment_size.
32 (elf32_frvfdpic_modify_program_headers): Delete.
33 (elf32_frvfdpic_copy_private_bfd_data): Don't copy PT_GNU_STACK
35 (elf_backend_stack_align): Override.
36 (elf_backend_modify_program_headers): Don't override.
37 * elf32-lm32.c (lm32_elf_always_size_sections): Leave
38 PT_GNU_STACK creation to underlying elf support. Check
39 __stacksize here for backwards compatibility, and set it if
41 (lm32_elf_modify_segment_map): Delete.
42 (lm32_elf_modify_program_headers): Delete.
43 (elf_backend_stack_align): Override.
44 (elf_backend_modify_segment_map): Don't override.
45 (elf_backend_modify_program_headers): Don't override.
46 * elf32-sh.c (sh_elf_always_size_sections): Call
47 bfd_elf_stack_segment_size.
48 (sh_elf_modify_program_headers): Delete.
49 (sh_elf_copy_private_data): Don't copy PT_GNU_STACK
51 (elf_backend_stack_align): Override.
52 (elf_backend_modify_program_headers): Don't override.
53 * elf32-tic6x.c (elf32_tic6x_always_size_sections): Call
54 bfd_elf_stack_segment_size.
55 (elf32_tic6x_modify_program_headers): Delete.
56 (elf32_tic6x_copy_private_data): Delete.
57 (elf_backend_stack_align): Override.
58 (bfd_elf32_bfd_copy_private_bfd_data): Don't override.
59 (elf_backend_modify_program_headers): Don't override.
61 2012-10-22 Alan Modra <amodra@gmail.com>
63 * cache.c (cache_bmmap): Don't use void* arithmetic.
65 2012-10-21 Alan Modra <amodra@gmail.com>
67 * compress.c (bfd_cache_section_contents): New function.
68 * bfd-in2.h: Regenerate.
70 2012-10-21 Hans-Peter Nilsson <hp@bitrange.com>
72 * linker.c (_bfd_generic_link_output_symbols): Handle a
73 no-longer-global symbol entered through a plugin.
75 2012-10-20 Alan Modra <amodra@gmail.com>
77 * compress.c: Reinstate 2012-10-19 change.
78 (bfd_get_full_section_contents): Don't free unless we alloc.
79 Use proper decompress size. Delete some vars, rename others.
81 2012-10-19 Tom Tromey <tromey@redhat.com>
83 * compress.c: Revert previous patch.
85 2012-10-19 Tom Tromey <tromey@redhat.com>
87 * compress.c (bfd_get_full_section_contents): Don't cache
88 decompressed contents.
90 2012-10-18 Kai Tietz <ktietz@redhat.com>
93 * coff-i386.c (bfd_target): Add section flag SEC_EXCLUDE.
94 Allow BFD_COMPRESS and BFD_DECOMPRESS flags.
95 * coff-x86_64.c: Likewise.
96 * coffcode.h (DOT_ZDEBUG): New define.
97 (sec_to_styp_flags): Check for .zdebug.
98 (styp_to_sec_flags): Likewise.
99 * coffgen.c (make_a_section): Handle .debug_* section
100 compression/decompression flags.
101 * cofflink.c (mark_relocs): Ignore relocations
102 for a section, which isn't marked as used.
103 (_bfd_coff_link_input_bfd): Add support of compressed
105 * compress.c (decompress_contents): Loop as long
106 as there is input available and there is room for
108 * bfd/pe-arm.c: Add .zdebug_ partial match entry.
109 * pe-i386.c: Likewise.
110 * pe-x86_64.c: Likewise.
111 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Don't clear all
112 data-directories as this might destroy content.
114 * coff-i386.c (_bfd_generic_find_nearest_line_discriminator):
115 define as coff_find_nearest_line_discriminator.
116 * libcoff-in.h (coff_find_nearest_line_discriminator): New
117 * libcoff.h: Regenerated.
118 * coff-x86_64.c: Likewise.
119 * coffgen.c (coff_find_nearest_line_discriminator): New function.
122 2012-10-16 Joel Brobecker <brobecker@adacore.com>
124 * coff64-rs6000.c (rs6000coff64_vec): Set _close_and_cleanup
125 field to _bfd_archive_close_and_cleanup.
126 (aix5coff64_vec): Likewise.
128 2012-10-16 Joel Brobecker <brobecker@adacore.com>
130 * coff-rs6000.c (rs6000coff_vec): Set _close_and_cleanup
131 field to _bfd_archive_close_and_cleanup.
132 (pmac_xcoff_vec): Likewise.
134 2012-10-16 Sofiane Naci <sofiane.naci@arm.com>
136 * elf64-aarch64.c (elf64_aarch64_tls_howto_table): Fix shift value for
137 R_AARCH64_TLSIE_LD_GOTTPREL_PREL19, R_AARCH64_TLSLE_MOVW_TPREL_G2,
138 R_AARCH64_TLSLE_MOVW_TPREL_G1, R_AARCH64_TLSLE_MOVW_TPREL_G1_NC,
139 R_AARCH64_TLSLE_ADD_TPREL_HI12.
140 (elf64_aarch64_tlsdesc_howto_table): Fix shift value for
141 R_AARCH64_TLSDESC_LD64_PREL19 and R_AARCH64_TLSDESC_OFF_G1.
142 (elf64_aarch64_final_link_relocate): Add signed_addend when resolving
143 AARCH64_TLSLE_*_TPREL_* relocations.
145 2012-10-16 Alan Modra <amodra@gmail.com>
147 * elf32-xtensa.c (free_section_cache): Renamed from
148 clear_section_cache. Don't zero cache.
149 (section_cache_section): Remove ineffectual zero of cache.
150 Call init_section_cache instead.
152 2012-10-15 Doug Evans <dje@google.com>
154 * elf.c (special_sections_d): Add comment.
156 2012-10-13 H.J. Lu <hongjiu.lu@intel.com>
158 * Makefile.am (LIBDL): Replace -ldl with @lt_cv_dlopen_libs@.
159 * configure.in (lt_cv_dlopen_libs): AC_SUBST.
160 * Makefile.in: Regenerated.
161 * configure: Likewise.
163 2012-10-08 Alan Modra <amodra@gmail.com>
166 * elf.c (_bfd_elf_make_section_from_shdr): Treat .gdb_index as
169 2012-09-20 Walter Lee <walt@tilera.com>
171 * elf32-tilepro.c (tilepro_elf_relocate_section): Adjust got
172 relocations with value of hgot.
173 * elfxx-tilegx.c (tilegx_elf_relocate_section): Ditto.
175 2012-09-19 Steve Ellcey <sellcey@mips.com>
177 * config.bfd: Add mips*-mti-elf* target.
179 2012-09-18 H.J. Lu <hongjiu.lu@intel.com>
182 * elf-bfd.h (_bfd_elf_merge_symbol): Add an argument to return
183 if the old symbol is weak.
185 * elf32-sh-symbian.c (sh_symbian_relocate_section): Update
186 _bfd_elf_merge_symbol call.
188 * elflink.c (_bfd_elf_merge_symbol): Add an argument to return
189 if the old symbol is weak.
190 (_bfd_elf_add_default_symbol): Update _bfd_elf_merge_symbol
192 (elf_link_add_object_symbols): Don't update symbol type from a
193 weak definition. Update symbol type from a common symbol when
194 overriding a weak symbol.
196 2012-09-17 H.J. Lu <hongjiu.lu@intel.com>
198 * elf32-i386.c (elf_i386_convert_mov_to_lea): Ignore discarded
200 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise.
202 2012-09-17 H.J. Lu <hongjiu.lu@intel.com>
204 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Replace return
206 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
208 2012-09-17 Walter Lee <walt@tilera.com>
210 * elf32-tilepro.c (tilepro_elf_relocate_section): Remove unused
212 * elfxx-tilegx.c (tilegx_elf_relocate_section): Ditto.
214 2012-09-17 Walter Lee <walt@tilera.com>
216 * elf32-tilepro.c (tilepro_elf_relocate_section): Fix computation
217 of got relocations for when .got.plt section is merged with .got.
218 * elfxx-tilegx.c (tilegx_elf_relocate_section): Ditto.
220 2012-09-14 David Edelsohn <dje.gcc@gmail.com>
222 * configure: Regenerate.
224 2012-09-13 Anthony Green <green@moxielogic.com>
226 * targets.c (bfd_elf32_bigmoxie_vec, bfd_elf32_littlemoxie_vec):
228 (bfd_elf32_moxie_vec): Remove.
229 * config.bfd, configure.in: Add bi-endian support for moxie.
230 * configure: Rebuilt.
231 * elf32-moxie.c (TARGET_LITTLE_NAME, TARGET_LITTLE_SYM): Define.
232 (TARGET_BIG_NAME, TARGET_BIG_SYM): Update for bi-endian support.
234 2012-09-12 Doug Kwan <dougkwan@google.com>
236 * elf64-ppc.c (ppc64_elf_relocate_section): Use pre-adjusted
237 relocation for stub lookup.
239 2012-09-12 Chris Schlumberger-Socha <chris.schlumberger-socha@arm.com>
241 * bfd-in2.h: Regenerated.
243 (elf64_aarch64_howto_table): Add R_AARCH64_GOT_LD_PREL19 reloc to HOWTO.
244 (elf64_aarch64_reloc_map): Add reloc entry.
245 (aarch64_resolve_relocation): Likewise.
246 (bfd_elf_aarch64_put_addend): Likewise.
247 (aarch64_reloc_got_type): Likewise.
248 (elf64_aarch64_final_link_relocate): Likewise.
249 (lf64_aarch64_check_relocs): Likewise.
250 (elf64_aarch64_check_relocs): New case for R_AARCH64_ADR_PREL_LO21
252 * libbfd.h: Regenerated.
253 * reloc.c (R_AARCH64_GOT_LD_PREL19): New reloc.
255 2012-09-10 Matthias Klose <doko@ubuntu.com>
257 * config.in: Disable sanity check for kfreebsd.
259 2012-09-10 H.J. Lu <hongjiu.lu@intel.com>
261 * configure: Regenerated.
263 2012-09-04 Sergey A. Guriev <sergey.a.guriev@intel.com>
265 * cpu-ia64-opc.c (ins_cnt6a): New function.
269 (elf64_ia64_operands): Add new operand types.
271 2012-09-04 H.J. Lu <hongjiu.lu@intel.com>
274 * elf.c (ignore_section_sym): Also ignore section symbols without
277 2012-09-03 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
279 * elf32-s390.c (elf_s390_relocate_section): Handle PLTOFF for
280 local and global ifunc symbols.
281 * elf64-s390.c (elf_s390_relocate_section): Likewise.
283 2012-09-02 H.J. Lu <hongjiu.lu@intel.com>
285 * elf-bfd.h (elf_link_hash_table): Add hdynamic for the
288 * elflink.c (_bfd_elf_link_create_dynamic_sections): Set
291 * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_symbol): Check
292 hdynamic instead of "_DYNAMIC".
293 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Likewise.
294 * elf32-cr16.c (elf32_arm_finish_dynamic_symbol): Likewise.
295 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
296 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
297 * elf32-i386.c (elf_i386_convert_mov_to_lea): Likewise.
298 * elf32-lm32.c (lm32_elf_finish_dynamic_symbol): Likewise.
299 * elf32-m32r.c (m32r_elf_finish_dynamic_symbol): Likewise.
300 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
301 * elf32-sh.c (sh_elf_finish_dynamic_symbol): Likewise.
302 * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
303 * elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
304 * elf32-vax.c (elf_vax_finish_dynamic_symbol): Likewise.
305 * elf32-xtensa.c (elf_xtensa_finish_dynamic_symbol): Likewise.
306 * elf64-aarch64.c elf64_aarch64_finish_dynamic_symbol(): Likewise.
307 * elf64-alpha.c (elf64_alpha_finish_dynamic_symbol): Likewise.
308 * elf64-ia64-vms.c (elf64_ia64_finish_dynamic_symbol): Likewise.
309 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
310 * elf64-sh64.c (sh64_elf64_finish_dynamic_symbol): Likewise.
311 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise.
312 * elfnn-ia64.c (elfNN_ia64_finish_dynamic_symbol): Likewise.
313 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
314 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
315 * elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
317 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Check
318 hdynamic, hgot, hplt instead of _DYNAMIC, _GLOBAL_OFFSET_TABLE_,
319 _PROCEDURE_LINKAGE_TABLE_.
320 * elf32-score.c (s3_bfd_score_elf_finish_dynamic_symbol): Likewise.
321 * elf32-score7.c (s7_bfd_score_elf_finish_dynamic_symbol): Likewise.
323 2012-08-31 H.J. Lu <hongjiu.lu@intel.com>
325 * elf32-i386.c (elf_i386_convert_mov_to_lea): Don't optimize
327 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise.
329 2012-08-31 H.J. Lu <hongjiu.lu@intel.com>
331 * elf32-i386.c (elf_i386_convert_mov_to_lea): New.
332 (elf_i386_size_dynamic_sections): Use it on input sections.
333 (elf_i386_relocate_section): Don't convert
334 "mov foo@GOT(%reg), %reg" to "lea foo@GOTOFF(%reg), %reg"
335 for local symbols here.
337 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): New.
338 (elf_x86_64_size_dynamic_sections): Use it on input sections.
339 (elf_x86_64_relocate_section): Don't convert
340 "mov foo@GOTPCREL(%rip), %reg" to "lea foo(%rip), %reg"
341 for local symbols here.
343 2012-08-30 H.J. Lu <hongjiu.lu@intel.com>
345 * elf32-i386.c (elf_i386_relocate_section): Convert
346 "mov foo@GOT(%reg), %reg" to "lea foo@GOTOFF(%reg), %reg"
349 * elf64-x86-64.c (elf_x86_64_relocate_section): Convert
350 "mov foo@GOTPCREL(%rip), %reg" to "lea foo(%rip), %reg"
353 2012-08-31 Alan Modra <amodra@gmail.com>
356 * elf64-ppc.c (ppc64_elf_relocate_section): Map symbols defined
357 by a linker script in .opd to corresponding input .opd section.
359 2012-08-28 Maciej W. Rozycki <macro@codesourcery.com>
361 * elf32-ppc.c (ppc_elf_relocate_section): Assert that dynindx is
363 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
365 2012-08-28 Maciej W. Rozycki <macro@codesourcery.com>
367 * elflink.c (_bfd_elf_merge_symbol): Also override the version
368 a dynamic symbol defaulted to if preempted with a hidden or
371 2012-08-28 Walter Lee <walt@tilera.com>
373 * elf32-tilepro.c (allocate_dynrelocs): Use PLT_ENTRY_SIZE as size
375 (tilepro_plt_entry_build): Account for new header size.
376 (tilepro_elf_finish_dynamic_sections): Ditto.
377 (tilepro_elf_plt_sym_val): Ditto.
378 * elfxx-tilegx.c (allocate_dynrelocs): Use PLT_ENTRY_SIZE as size
380 (tilegx_elf_finish_dynamic_sections): Account for new padding.
382 2012-08-27 Walter Lee <walt@tilera.com>
384 * reloc.c (Add BFD_RELOC_TILEGX_IMM16_X0_HW0_PLT_PCREL,
385 BFD_RELOC_TILEGX_IMM16_X1_HW0_PLT_PCREL,
386 BFD_RELOC_TILEGX_IMM16_X0_HW1_PLT_PCREL,
387 BFD_RELOC_TILEGX_IMM16_X1_HW1_PLT_PCREL,
388 BFD_RELOC_TILEGX_IMM16_X0_HW2_PLT_PCREL,
389 BFD_RELOC_TILEGX_IMM16_X1_HW2_PLT_PCREL,
390 BFD_RELOC_TILEGX_IMM16_X0_HW3_PLT_PCREL,
391 BFD_RELOC_TILEGX_IMM16_X1_HW3_PLT_PCREL,
392 BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_PLT_PCREL,
393 BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_PLT_PCREL,
394 BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_PLT_PCREL,
395 BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_PLT_PCREL,
396 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_PLT_PCREL,
397 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_PLT_PCREL): new relocations.
398 * elfxx-tilegx.c (tilegx_elf_howto_table): Handle new relocations.
399 (tilegx_reloc_map): Ditto.
400 (reloc_to_create_func): Ditto.
401 (tilegx_elf_check_relocs): Ditto.
402 (tilegx_elf_gc_sweep_hook): Ditto.
403 (tilegx_elf_relocate_section): Ditto.
404 * libbfd.h: Regenerate.
405 * bfd-in2.h: Regenerate.
407 2012-08-24 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
409 * elf32-arm.c (v8): New array.
410 (tag_cpu_arch_combine): Add support for ARMv8 attributes.
411 (elf32_arm_merge_eabi_attributes): Likewise.
412 (VFP_VERSION_COUNT): New define.
414 2012-08-20 Tom Tromey <tromey@redhat.com>
416 * vms-lib.c (_bfd_vms_lib_get_module): Use bfd_zmalloc for
418 * opncls.c (_bfd_delete_bfd): Free arelt_data.
419 * mach-o.c (bfd_mach_o_fat_member_init): Use bfd_zmalloc for
421 * ecoff.c (_bfd_ecoff_slurp_armap): Use free for mapdata.
422 * coff-rs6000.c (_bfd_xcoff_read_ar_hdr): Use bfd_zmalloc for
424 (xcoff_write_archive_contents_old): Likewise.
425 (xcoff_write_archive_contents_big): Likewise.
426 * archive64.c (bfd_elf64_archive_slurp_armap): Use free for
428 * archive.c (_bfd_generic_read_ar_hdr_mag): Use bfd_zmalloc and
430 (_bfd_get_elt_at_filepos): Likewise. Clear n_nfd->arelt_data on
432 (do_slurp_bsd_armap): Use bfd_zmalloc and free for areltdata.
433 (do_slurp_coff_armap): Likewise.
434 (_bfd_slurp_extended_name_table): Likewise.
435 (bfd_slurp_bsd_armap_f2): Likewise. Don't leak 'mapdata'.
437 2012-08-17 Nick Clifton <nickc@redhat.com>
439 * po/vi.po: Updated Vietnamese translation.
441 2012-08-17 Yuri Chornoivan <yurchor@ukr.net>
443 * elf-bfd.h, * elf32-ppc.c, * elf64-ia64-vms.c, * elfnn-ia64.c,
444 * elfxx-mips.c, * vms-alpha.c: Typo fixes.
446 2012-08-17 Alan Modra <amodra@gmail.com>
449 * archive.c (bfd_ar_hdr_from_filesystem): Revert last change.
450 Instead malloc areltdata.
452 2012-08-16 Tom Tromey <tromey@redhat.com>
455 * archive.c (bfd_ar_hdr_from_filesystem): Allocate areltdata on
456 'member' BFD. Don't try to free 'ared'.
458 2012-08-14 Nick Clifton <nickc@redhat.com>
460 * po/uk.po: Updated Ukranian translation.
462 2012-08-13 Maciej W. Rozycki <macro@codesourcery.com>
464 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Look up
465 the options section in the output rather than input BFD to
466 decide if to add a DT_MIPS_OPTIONS tag.
468 2012-08-13 Maciej W. Rozycki <macro@codesourcery.com>
470 * config.bfd: Wrap mips*el-*-linux* and mips*-*-linux* into
473 2012-08-13 Ian Bolton <ian.bolton@arm.com>
474 Laurent Desnogues <laurent.desnogues@arm.com>
475 Jim MacArthur <jim.macarthur@arm.com>
476 Marcus Shawcroft <marcus.shawcroft@arm.com>
477 Nigel Stephens <nigel.stephens@arm.com>
478 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
479 Richard Earnshaw <rearnsha@arm.com>
480 Sofiane Naci <sofiane.naci@arm.com>
481 Tejas Belagod <tejas.belagod@arm.com>
482 Yufeng Zhang <yufeng.zhang@arm.com>
484 * Makefile.am: Add AArch64 files.
485 * Makefile.in: Regenerate.
486 * archures.c (bfd_aarch64_arch): New declaration.
487 (bfd_archures_list): Use bfd_archures_list.
488 * bfd-in.h (bfd_elf64_aarch64_init_maps): New declaration.
489 (bfd_aarch64_process_before_allocation): New declaration.
490 (bfd_elf64_aarch64_process_before_allocation): New declaration.
491 (bfd_elf64_aarch64_set_options): New declaration.
492 (bfd_elf64_aarch64_add_glue_sections_to_bfd): New declaration.
493 (BFD_AARCH64_SPECIAL_SYM_TYPE_MAP): New definition.
494 (BFD_AARCH64_SPECIAL_SYM_TYPE_TAG): New definition.
495 (BFD_AARCH64_SPECIAL_SYM_TYPE_OTHER): New definition.
496 (BFD_AARCH64_SPECIAL_SYM_TYPE_ANY): New definition.
497 (bfd_is_aarch64_special_symbol_name): New declaration.
498 (bfd_aarch64_merge_machines): New declaration.
499 (bfd_aarch64_update_notes): New declaration.
500 (int bfd_aarch64_get_mach_from_notes): New declaration.
501 (elf64_aarch64_setup_section_lists): New declaration.
502 (elf64_aarch64_next_input_section): New declaration.
503 (elf64_aarch64_size_stubs): New declaration.
504 (elf64_aarch64_build_stubs): New declaration.
505 * config.bfd: Add AArch64.
506 * configure.in: Add AArch64.
507 * configure: Regenerate.
508 * cpu-aarch64.c: New file.
509 * elf-bfd.h: Add AArch64.
510 * bfd-in2.h: Regenerate.
511 * libbfd.h: Regenerate.
512 * elf64-aarch64.c: New file.
513 * reloc.c: Add AArch64 relocations.
514 * targets.c: Add AArch64.
515 * po/SRC-POTFILES.in: Regenerate.
517 2012-08-13 Maciej W. Rozycki <macro@codesourcery.com>
519 * elfxx-mips.c (mips_elf_calculate_relocation): Fix the handling
520 of protected symbols.
522 2012-08-10 Alan Modra <amodra@gmail.com>
525 * elf.c (IS_VALID_GROUP_SECTION_HEADER) Add minsize param.
526 (setup_group): Adjust uses.
527 (bfd_section_from_shdr): Allow SHT_GROUP sections with just a flag
530 2012-08-09 Nick Clifton <nickc@redhat.com>
532 * po/vi.po: Updated Vietnamese translation.
534 2012-08-09 Maciej W. Rozycki <macro@codesourcery.com>
536 * elfxx-mips.c (LA25_LUI_MICROMIPS_1, LA25_LUI_MICROMIPS_2):
537 Remove macros, folding them into...
538 (LA25_LUI_MICROMIPS): ... this new macro.
539 (LA25_J_MICROMIPS_1, LA25_J_MICROMIPS_2): Likewise into...
540 (LA25_J_MICROMIPS): ... this new macro.
541 (LA25_ADDIU_MICROMIPS_1, LA25_ADDIU_MICROMIPS_2): Likewise
543 (LA25_ADDIU_MICROMIPS): ... this new macro.
544 (bfd_put_micromips_32, bfd_get_micromips_32): New functions.
545 (mips_elf_create_la25_stub): Use them.
546 (check_br32_dslot, check_br32, check_relocated_bzc): Likewise.
547 (_bfd_mips_elf_relax_section): Likewise.
549 2012-08-09 Alan Modra <amodra@gmail.com>
550 Tom Tromey <tromey@redhat.com>
552 * archive.c (SECTION Archives): Update documentation.
553 (_bfd_delete_archive_data): Remove.
554 (_bfd_add_bfd_to_archive_cache): Set 'parent_cache' and 'key'.
555 (archive_close_worker, _bfd_archive_close_and_cleanup): New
557 * libbfd-in.h (struct areltdata <parent_cache, key>): New fields.
558 (_bfd_delete_archive_data): Don't declare.
559 (_bfd_archive_close_and_cleanup): Declare.
560 (_bfd_generic_close_and_cleanup): Redefine.
562 * opncls.c (_bfd_delete_bfd): Don't call _bfd_delete_archive_data.
563 (bfd_close): Don't close nested thin archives here.
565 2012-08-07 Tom Tromey <tromey@redhat.com>
567 * archive.c (_bfd_delete_archive_data): New function.
568 * libbfd-in.h (_bfd_delete_archive_data): Declare.
570 * opncls.c (_bfd_delete_bfd): Call _bfd_delete_archive_data.
572 2012-08-07 Nick Clifton <nickc@redhat.com>
574 * po/uk.po: Updated Ukranian translation.
576 2012-08-06 Maciej W. Rozycki <macro@codesourcery.com>
578 * elflink.c (bfd_elf_record_link_assignment): Remove --defsym
579 symbols special case.
581 2012-08-05 Maciej W. Rozycki <macro@linux-mips.org>
583 * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Don't allocate
584 PLT slots for local symbols.
586 2012-08-03 Maciej W. Rozycki <macro@codesourcery.com>
588 * elf64-mips.c (mips16_elf64_howto_table_rela): Correct src_mask
589 field initializers throughout.
590 * elfn32-mips.c (elf_mips16_howto_table_rela): Likewise.
592 2012-08-03 Maciej W. Rozycki <macro@codesourcery.com>
594 * elfxx-mips.c (mips_elf_perform_relocation): Update the
595 cross-mode jump message.
597 2012-08-03 Maciej W. Rozycki <macro@codesourcery.com>
599 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Update the
600 comment on DT_MIPS_RLD_MAP.
602 2012-08-03 Tom Tromey <tromey@redhat.com>
604 * opncls.c (_bfd_delete_bfd): Now static.
605 * libbfd-in.h (_bfd_delete_bfd): Don't declare.
608 2012-08-02 Sean Keys <skeys@ipdatasys.com>
610 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Modified
611 conditional statment to allow suppression of mismatched bank
614 2012-08-01 Alan Modra <amodra@gmail.com>
616 * dwarf2.c (struct dwarf2_debug): Add close_on_cleanup.
617 (_bfd_dwarf2_slurp_debug_info): Set close_on_cleanup if we open
619 (_bfd_dwarf2_cleanup_debug_info): Act on close_on_cleanup.
621 2012-07-30 Nick Clifton <nickc@redhat.com>
623 * po/bfd.pot: Updated template.
624 * po/es.po: Updated Spanish translation.
625 * po/fi.po: Updated Finnish translation.
626 * po/fr.po: Updated French translation.
627 * po/ru.po: Updated Russian translation.
628 * po/uk.po: Updated Ukranian translation.
630 2012-07-27 Mike Frysinger <vapier@gentoo.org>
632 * configure.in (AC_INIT): Call with the args bfd and 2.22.52.
633 (AM_INIT_AUTOMAKE): Remove args.
634 * configure: Regenerate.
636 2012-07-27 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
638 * cpu-s390.c (bfd_s390_64_arch, bfd_s390_arch): Pick the default
639 arch depending on the target size.
641 2012-07-27 Tristan Gingold <gingold@adacore.com>
643 * configure.in: Bump version to 2.23.51
644 * configure: Regenerate.
646 2012-07-26 Teresa Johnson <tejohnson@google.com>
648 * bfd/dwarf2.c (find_line): Initialize discriminator_ptr
651 2012-07-26 Meador Inge <meadori@codesourcery.com>
652 Nick Clifton <nickc@redhat.com>
655 * elf32-arm.c (elf32_arm_finish_dynamic_sections): Report an error
656 if a required section is missing from the linker script.
658 2012-07-24 Jan Waclawek <konfera@efton.sk>
660 * elf32-avr.c (elf32_avr_relax_delete_bytes): Call
661 _bfd_elf_link_read_relocs with keep_memory as TRUE.
663 2012-07-24 Teresa Johnson <tejohnson@google.com>
665 * bfd.c (bfd_find_nearest_line_discriminator): New macro.
666 * coff-rs6000.c: Init _bfd_find_nearest_line_discriminator.
667 * coff64-rs6000.c: Likewise.
668 * dwarf2.c (struct line_info): Add discriminator field.
669 (add_line_info): Fill in new discriminator field.
670 (decode_line_info): Record discriminator information instead
672 (lookup_address_in_line_info_table): Return discriminator field if
674 (comp_unit_find_nearest_line): Add discriminator argument.
675 (find_line): Likewise.
676 (_bfd_dwarf2_find_nearest_line): Likewise.
677 (_bfd_dwarf2_find_line): Likewise.
678 * elf-bfd.h (_bfd_elf_find_nearest_line_discriminator): New.
679 (_bfd_elf_find_line_discriminator): Likewise.
680 (_bfd_generic_find_nearest_line_discriminator): Likewise. Defined.
681 * elf.c (_bfd_elf_find_nearest_line): Change to a wrapper
682 that invokes _bfd_elf_find_nearest_line_discriminator with correct
684 (_bfd_elf_find_nearest_line_discriminator): New.
685 (_bfd_elf_find_line): Change to a wrapper
686 that invokes _bfd_elf_find_line_discriminator with correct
688 (_bfd_elf_find_line_discriminator): New.
689 * coffgen.c (coff_find_nearest_line_with_names): Handle
690 new discriminator argument.
691 * elf32-arm.c (elf32_arm_find_nearest_line): Likewise.
692 * elf64-alpha.c (elf64_alpha_find_nearest_line): Likewise.
693 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): Likewise.
694 * mach-o.c (bfd_mach_o_find_nearest_line): Likewise.
695 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Add discriminator
697 (_bfd_dwarf2_find_line): Likewise.
698 (_bfd_generic_find_nearest_line_discriminator): New.
699 * libbfd.c (_bfd_generic_find_nearest_line_discriminator): New.
700 * bfd-in2.h: Regenerated.
701 * libbfd.h: Likewise.
702 * targets.c (BFD_JUMP_TABLE_SYMBOLS): Initialize
703 _bfd_find_nearest_line_discriminator with
704 _bfd_generic_find_nearest_line_discriminator.
705 (bfd_target): Add _bfd_find_nearest_line_discriminator.
707 2012-07-24 Sean Keys <skeys@ipdatasys.com>
709 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Added code
710 that enables the linker to offset addresses, when linking against
711 symbols from the XGATE processor and vice versa.
713 2012-07-23 Nick Clifton <nickc@redhat.com>
715 * cisco-core.c (cisco_core_file_failing_command): Make static.
716 (cisco_core_file_failing_signal): Make static.
718 2012-07-18 H.J. Lu <hongjiu.lu@intel.com>
720 * bfd-in2.h: Regenerated.
722 2012-07-18 Nicolàs Alejandro Di Risio <sheeva@tiscali.it>
725 * section.c: Fix a typo in comments.
727 2012-07-13 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
729 * elf64-s390.c: Include elf-s390-common.c.
730 (R_390_IRELATIVE): New reloc.
731 (elf_s390_reloc_type_lookup): Support R_390_IRELATIVE.
732 (RELA_ENTRY_SIZE): New macro.
733 (elf_s390_link_hash_entry): New fields ifunc_resolver_address and
734 *ifunc_resolver_section.
735 (struct plt_entry): New struct.
736 (struct elf_s390_obj_tdata): New field local_plt.
737 (elf_s390_local_plt): New macro.
738 (struct elf_s390_link_hash_table): New field irelifunc.
740 (link_hash_newfunc): Initialize new fields.
741 (elf_s390_check_relocs): Handle IFUNC symbols.
742 (elf_s390_adjust_dynamic_symbol): Don't do anything for IFUNC
744 (allocate_dynrelocs): Call s390_elf_allocate_ifunc_dyn_relocs for
746 (elf_s390_size_dynamic_sections): Handle IFUNC symbols.
747 (elf_s390_relocate_section): Likewise.
748 (elf_s390_finish_dynamic_symbol): Likewise.
749 (elf_s390_finish_dynamic_sections): Handle local IFUNC symbols.
750 (elf_s390_finish_ifunc_symbol): New function.
751 (elf_s390_gc_sweep_hook): Handle local plt entries.
752 (elf_backend_add_symbol_hook): Define.
753 * elf32-s390.c: See elf64-s390.c changes.
754 * elf-s390-common.c: New file.
755 * bfd-in2.h (BFD_RELOC_390_IRELATIVE): New enum field.
756 * libbfd.h (BFD_RELOC_390_IRELATIVE): New entry for
757 BFD_RELOC_390_IRELATIVE.
758 * reloc.c (BFD_RELOC_390_IRELATIVE): Document new relocation.
760 2012-07-13 Nick Clifton <nickc@redhat.com>
762 * aix386-core.c: Remove use of PTR and PARAMS macros.
763 * archive.c: Likewise.
765 * cisco-core.c: Likewise.
766 * coff-alpha.c: Likewise.
767 * coff-apollo.c: Likewise.
768 * coff-aux.c: Likewise.
769 * coff-h8300.c: Likewise.
770 * coff-h8500.c: Likewise.
771 * coff-i386.c: Likewise.
772 * coff-i960.c: Likewise.
773 * coff-ia64.c: Likewise.
774 * coff-m68k.c: Likewise.
775 * coff-m88k.c: Likewise.
776 * coff-mcore.c: Likewise.
777 * coff-mips.c: Likewise.
778 * coff-or32.c: Likewise.
779 * coff-ppc.c: Likewise.
780 * coff-rs6000.c: Likewise.
781 * coff-sh.c: Likewise.
782 * coff-sparc.c: Likewise.
783 * coff-stgo32.c: Likewise.
784 * coff-tic30.c: Likewise.
785 * coff-tic4x.c: Likewise.
786 * coff-tic54x.c: Likewise.
787 * coff-tic80.c: Likewise.
788 * coff-w65.c: Likewise.
789 * cofflink.c: Likewise.
790 * cpu-arc.c: Likewise.
791 * cpu-cris.c: Likewise.
792 * cpu-h8500.c: Likewise.
793 * cpu-i960.c: Likewise.
794 * cpu-msp430.c: Likewise.
795 * cpu-ns32k.c: Likewise.
796 * cpu-powerpc.c: Likewise.
797 * cpu-rs6000.c: Likewise.
798 * cpu-tic4x.c: Likewise.
799 * cpu-w65.c: Likewise.
801 * ecofflink.c: Likewise.
802 * elf-m10200.c: Likewise.
803 * elf32-bfin.c: Likewise.
804 * elf32-cris.c: Likewise.
805 * elf32-crx.c: Likewise.
806 * elf32-fr30.c: Likewise.
807 * elf32-frv.c: Likewise.
808 * elf32-h8300.c: Likewise.
809 * elf32-i960.c: Likewise.
810 * elf32-m32c.c: Likewise.
811 * elf32-m68hc11.c: Likewise.
812 * elf32-m68hc12.c: Likewise.
813 * elf32-m68hc1x.c: Likewise.
814 * elf32-m68k.c: Likewise.
815 * elf32-mcore.c: Likewise.
816 * elf32-rl78.c: Likewise.
817 * elf32-rx.c: Likewise.
818 * elf32-s390.c: Likewise.
819 * elf32-vax.c: Likewise.
820 * elf64-alpha.c: Likewise.
821 * elf64-mmix.c: Likewise.
822 * elf64-s390.c: Likewise.
823 * elf64-sparc.c: Likewise.
824 * elfnn-ia64.c: Likewise.
825 * elfxx-mips.c: Likewise.
826 * elfxx-sparc.c: Likewise.
828 * hp300hpux.c: Likewise.
829 * hppabsd-core.c: Likewise.
830 * hpux-core.c: Likewise.
831 * i386dynix.c: Likewise.
832 * i386linux.c: Likewise.
833 * i386lynx.c: Likewise.
834 * i386mach3.c: Likewise.
835 * i386msdos.c: Likewise.
836 * i386os9k.c: Likewise.
837 * irix-core.c: Likewise.
838 * lynx-core.c: Likewise.
839 * m68klinux.c: Likewise.
840 * mach-o.h: Likewise.
841 * mipsbsd.c: Likewise.
842 * netbsd-core.c: Likewise.
843 * nlm32-i386.c: Likewise.
844 * osf-core.c: Likewise.
845 * pc532-mach.c: Likewise.
847 * ppcboot.c: Likewise.
848 * ptrace-core.c: Likewise.
849 * reloc16.c: Likewise.
850 * sco5-core.c: Likewise.
852 * sparclinux.c: Likewise.
853 * sparclynx.c: Likewise.
854 * ticoff.h: Likewise.
855 * trad-core.c: Likewise.
856 * vms-lib.c: Likewise.
859 2012-07-09 Alan Modra <amodra@gmail.com>
862 * elflink.c (elf_sort_symbol): Sort by size too.
863 (elf_link_add_object_symbols <weakdefs>): Simplify binary search.
864 Do not depend on ordering of symbol aliases. Match largest size.
866 2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
868 * elf.c (assign_section_numbers): Check if number of sections
870 * elfcode.h (elf_object_p): Likewise.
872 2012-07-03 Nick Clifton <nickc@redhat.com>
874 * archive.c (bsd_write_armap): Catch attempts to create an archive
875 with indicies bigger than 4Gb.
876 (coff_write_armap): Likewise.
878 2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
881 * elf.c (_bfd_elf_make_section_from_shdr): Don't compress empty
884 2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
887 * elflink.c (_bfd_elf_update_dynamic_flags): New.
888 (_bfd_elf_merge_symbol): Update both real and indirect symbol
890 (_bfd_elf_add_default_symbol): Make the real symbol dynamic if
891 the indirect symbol is defined in a shared library.
892 (elf_link_add_object_symbols): Likewise. If the indirect
893 symbol has been forced local, don't make the real symbol
895 (elf_link_check_versioned_symbol): Check indirect symbol.
896 (elf_link_output_extsym): Use real symbol definition when
897 reporting indirect symbol error. Check version info for
898 dynamic versioned symbol.
900 2012-07-03 Alan Modra <amodra@gmail.com>
903 * elf.c (assign_file_positions_for_load_sections): Remove assertions
904 that only PT_LOAD headers include file header and section headers.
905 (assign_file_positions_for_non_load_sections): Similarly don't
906 assert PT_GNU_RELRO header does not include file and section headers.
907 Compare first section vma rather than PT_LOAD p_vaddr against
908 relro_start when looking for PT_LOAD covering PT_GNU_RELRO. Replace
909 abort with assertion.
911 2012-07-02 Alan Modra <amodra@gmail.com>
913 * elf32-m32c.c (m32c_elf_check_relocs): Use bfd_make_section
914 "anyway" variant when creating .plt.
915 (m32c_elf_relax_plt_section): Remove redundant test and unused param.
916 (m32c_elf_relax_section): Test SEC_LINKER_CREATED before calling
917 m32c_elf_relax_plt_section.
918 * elfxx-mips.c (mips_elf_create_got_section): Use make anyway variant
919 when creating .got and .got.plt.
920 (_bfd_mips_elf_final_link): Likewise for .rtproc, and use
921 bfd_get_linker_section.
922 * sunos.c: Similarly throughout.
924 2012-07-01 Andreas Schwab <schwab@linux-m68k.org>
926 * elf.c (_bfd_elf_make_section_from_shdr): Fix typo in error
929 2012-06-29 H.J. Lu <hongjiu.lu@intel.com>
931 * elf64-x86-64.c (elf_x86_64_relocate_section): Return FALSE
932 on unresolvable relocation.
934 2012-06-29 H.J. Lu <hongjiu.lu@intel.com>
936 * archive.c (_bfd_compute_and_write_armap): Simplify global
939 2012-06-29 Nick Clifton <nickc@redhat.com>
942 * elf32-arm.c (elf32_arm_check_relocs): Do not increment refcount
943 for locally bound symbols.
945 2012-06-29 Alan Modra <amodra@gmail.com>
947 * section.c (bfd_get_linker_section): New function.
948 * elf32-arm.c: When retrieving SEC_LINKER_CREATED sections, use
949 the above throughout rather than bfd_get_section_by_name. Use
950 bfd_make_section_anyway rather than bfd_make_section when creating
952 * elf32-bfin.c: Likewise.
953 * elf32-cr16.c: Likewise.
954 * elf32-cris.c: Likewise.
955 * elf32-frv.c: Likewise.
956 * elf32-hppa.c: Likewise.
957 * elf32-i370.c: Likewise.
958 * elf32-i386.c: Likewise.
959 * elf32-lm32.c: Likewise.
960 * elf32-m32c.c: Likewise.
961 * elf32-m32r.c: Likewise.
962 * elf32-m68k.c: Likewise.
963 * elf32-microblaze.c: Likewise.
964 * elf32-ppc.c: Likewise.
965 * elf32-rl78.c: Likewise.
966 * elf32-s390.c: Likewise.
967 * elf32-score.c: Likewise.
968 * elf32-score7.c: Likewise.
969 * elf32-sh.c: Likewise.
970 * elf32-tic6x.c: Likewise.
971 * elf32-tilepro.c: Likewise.
972 * elf32-vax.c: Likewise.
973 * elf32-xstormy16.c: Likewise.
974 * elf32-xtensa.c: Likewise.
975 * elf64-alpha.c: Likewise.
976 * elf64-hppa.c: Likewise.
977 * elf64-ia64-vms.c: Likewise.
978 * elf64-ppc.c: Likewise.
979 * elf64-s390.c: Likewise.
980 * elf64-sh64.c: Likewise.
981 * elf64-sparc.c: Likewise.
982 * elf64-x86-64.c: Likewise.
983 * elfnn-ia64.c: Likewise.
984 * elfxx-mips.c: Likewise.
985 * elfxx-sparc.c: Likewise.
986 * elfxx-tilegx.c: Likewise.
987 * elflink.c: Likewise.
988 * elf-vxworks.c: Likewise.
989 * elf-m10300.c: Likewise. Also make use of htab plt, got and
991 * bfd-in2.h: Regenerate.
992 * elf32-lm32.c (lm32_elf_check_relocs): Use the correct bfd when
993 calling create_rofixup_section.
994 * elflink.c (bfd_elf_final_link): Simplify test for .dynstr.
996 2012-06-29 Alan Modra <amodra@gmail.com>
998 * elf32-sh.c (sh_elf_create_dynamic_sections): Don't create .rela
999 section for bss type sections, except for .rela.bss.
1000 * elf-m10300.c (_bfd_mn10300_elf_create_dynamic_sections): Likewise.
1001 * elf32-cr16.c (_bfd_cr16_elf_create_dynamic_sections): Likewise.
1002 * elf32-lm32.c (lm32_elf_create_dynamic_sections): Likewise.
1003 * elf32-m32r.c (m32r_elf_create_dynamic_sections): Likewise.
1004 * elf64-sh64.c (sh64_elf64_create_dynamic_sections): Likewise.
1006 2012-06-28 Roland McGrath <mcgrathr@google.com>
1008 * elf32-arm.c (elf32_arm_populate_plt_entry): Use int32_t for
1009 displacement calculation in nacl_p case.
1011 2012-06-28 Nick Clifton <nickc@redhat.com>
1013 * po/uk.po: New Ukranian translation.
1014 * configure.in (ALL_LINGUAS): Add uk.
1015 * configure: Regenerate.
1017 2012-06-26 Alan Modra <amodra@gmail.com>
1019 * elf64-ppc.c (ppc64_elf_next_toc_section): Don't error if input
1020 file has multiple .got/.toc sections and all don't fit in
1023 2012-06-22 Roland McGrath <mcgrathr@google.com>
1025 * elf.c (assign_file_positions_for_non_load_sections): Define
1026 __ehdr_start symbol if it's referenced and there's a PT_LOAD
1027 segment that covers both the file and program headers.
1029 2012-06-22 Andreas Schwab <schwab@linux-m68k.org>
1031 * elf32-m68k.c (elf_m68k_finish_dynamic_symbol): Don't make
1032 _GLOBAL_OFFSET_TABLE_ and _DYNAMIC absolute.
1034 2012-06-22 Alan Modra <amodra@gmail.com>
1036 * elf64-ppc.c (ppc64_elf_func_desc_adjust): Don't emit out-of-line
1037 save/restore functions when relocatable. Make "funcs" static.
1039 2012-06-18 Hans-Peter Nilsson <hp@axis.com>
1041 * elf32-cris.c (cris_elf_plt_sym_val): Rewrite to work in presence
1042 of merged .got and .got.plt entries.
1044 2012-06-18 John Szakmeister <john@szakmeister.net>
1046 * elf32-arm.c (elf32_arm_final_link_relocate): Correct return value.
1048 2012-06-17 Hans-Peter Nilsson <hp@axis.com>
1050 * elf32-cris.c (cris_elf_relocate_section): <R_CRIS_32_IE>
1051 <R_CRIS_32_GOT_TPREL, R_CRIS_16_GOT_TPREL>: Handle references to
1052 thread common symbols.
1054 2012-06-13 Nick Clifton <nickc@redhat.com>
1056 * elf32-arm.c (bfd_arm_get_mach_from_attributes): New function.
1057 (elf32_arm_object_p): If the machine number could not be deduced
1058 from the notes, call bfd_arm_get_mach_from_attributes to get the
1059 number from the attributes.
1061 2012-06-12 H.J. Lu <hongjiu.lu@intel.com>
1064 * elf.c (assign_file_positions_for_non_load_sections): Abort if
1065 PT_GNU_RELRO segment doesn't fit in PT_LOAD segment.
1067 2012-06-12 Alan Modra <amodra@gmail.com>
1070 * elf.c (_bfd_elf_map_sections_to_segments): Disregard bss type
1071 sections at end of PT_LOAD segment when searching for segment
1072 that contains end of relro extent.
1074 2012-06-11 H.J. Lu <hongjiu.lu@intel.com>
1076 * elf.c (assign_file_positions_for_non_load_sections): Reindent.
1078 2012-06-11 H.J. Lu <hongjiu.lu@intel.com>
1080 * elf.c (_bfd_elf_map_sections_to_segments): Reindent.
1082 2012-06-06 Alan Modra <amodra@gmail.com>
1084 * elflink.c (elf_link_input_bfd): Provide a file symbol for
1085 each input file with local syms, if the input lacks such.
1086 (bfd_elf_final_link): Add a file symbol to mark end of locals
1087 for which we can associate with input files.
1088 (struct elf_final_link_info): Add filesym_count field.
1089 (struct elf_outext_info): Add need_second_pass and second_pass.
1090 (elf_link_output_extsym): Detect symbols defined in the output
1091 file, emit them on second pass over locals.
1093 2012-06-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1095 * bfd-in.h (bfd_elf_bfd_from_remote_memory): Make LEN argument
1096 of target_read_memory as bfd_size_type.
1097 * bfd-in2.h: Regenerate.
1098 * elf-bfd.h (elf_backend_bfd_from_remote_memory): Make LEN
1099 argument of target_read_memory as bfd_size_type.
1100 (_bfd_elf32_bfd_from_remote_memory): Likewise.
1101 (_bfd_elf64_bfd_from_remote_memory): Likewise.
1102 * elf.c (bfd_elf_bfd_from_remote_memory): Likewise.
1103 * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): Likewise.
1105 2012-06-03 Alan Modra <amodra@gmail.com>
1108 * elf.c (elf_find_function): Cache last function sym info.
1109 (_bfd_elf_maybe_function_sym): Return function size, pass in
1110 section of interest.
1111 * elf-bfd.h (struct elf_backend_data <maybe_function_sym>): Likewise.
1112 (_bfd_elf_maybe_function_sym): Likewise.
1113 * elf64-ppc.c (ppc64_elf_maybe_function_sym): Likewise.
1114 (opd_entry_value): Add in_code_sec param. Revert caching code.
1115 Return -1 if in_code_sec and function found in wrong section.
1118 2012-06-01 Siddhesh Poyarekar <siddhesh@redhat.com>
1120 * bfd-in.h (bfd_elf_bfd_from_remote_memory): Make LEN argument
1121 of target_read_memory as size_t.
1122 * bfd-in2.h: Regenerate.
1123 * elf-bfd.h (elf_backend_bfd_from_remote_memory): Make LEN
1124 argument of target_read_memory as size_t.
1125 (_bfd_elf32_bfd_from_remote_memory): Likewise.
1126 (_bfd_elf64_bfd_from_remote_memory): Likewise.
1127 * elf.c (bfd_elf_bfd_from_remote_memory): Likewise.
1128 * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): Likewise.
1130 2012-06-01 Alan Modra <amodra@gmail.com>
1133 * elf64-ppc.c (opd_entry_value): Rewrite cache code.
1135 2012-05-29 Tom Tromey <tromey@redhat.com>
1137 * opncls.c (bfd_fopen): Always close fd on failure.
1138 (bfd_fdopenr): Likewise.
1140 2012-05-27 Alan Modra <amodra@gmail.com>
1143 * elflink.c (_bfd_elf_merge_symbol): When a symbol defined in
1144 a dynamic library finds a new instance with non-default
1145 visibility in a regular object, correctly handle symbols
1146 already on the undefs list and undo dynamic symbol state when
1147 the new symbol is hidden or internal.
1149 2012-05-25 H.J. Lu <hongjiu.lu@intel.com>
1151 * elf32-i386.c (elf_i386_create_dynamic_sections): Don't use
1152 dynamic_sec_flags to create PLT .eh_frame section.
1153 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1155 2012-05-25 Alan Modra <amodra@gmail.com>
1158 * elf-eh-frame.c (_bfd_elf_eh_frame_present): New function.
1159 (_bfd_elf_maybe_strip_eh_frame_hdr): Use it here.
1160 * elf-bfd.h (_bfd_elf_eh_frame_present): Declare.
1161 * elflink.c (bfd_elf_size_dynamic_sections): Let the backend
1162 size dynamic sections before stripping eh_frame_hdr.
1163 (bfd_elf_gc_sections): Handle multiple .eh_frame sections.
1164 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Drop glink_eh_frame
1165 if no other .eh_frame sections exist.
1166 * elf64-ppc.c (ppc64_elf_size_stubs): Likewise.
1167 * elf32-i386.c (elf_i386_create_dynamic_sections): Don't size
1168 or alloc plt_eh_frame here..
1169 (elf_i386_size_dynamic_sections): ..do it here instead. Don't
1170 specially keep sgotplt, iplt, tgotplt, sdynbss for symbols.
1171 (elf_i386_finish_dynamic_sections): Check plt_eh_frame->contents
1172 before writing plt offset.
1173 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Don't size
1174 or alloc plt_eh_frame here..
1175 (elf_x86_64_size_dynamic_sections): ..do it here instead.
1176 (elf_x86_64_finish_dynamic_sections): Check plt_eh_frame->contents
1177 before writing plt offset.
1179 2012-05-24 Alan Modra <amodra@gmail.com>
1182 * elf64-ppc.c (ppc64_elf_size_stubs): Round up glink_eh_frame
1183 size to output section alignment.
1184 (ppc64_elf_build_stubs): Likewise, and extend last FDE to cover.
1186 2012-05-23 Alan Modra <amodra@gmail.com>
1188 * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Handle
1189 BFDs with multiple .eh_frame sections.
1191 2012-05-23 Alan Modra <amodra@gmail.com>
1194 * elflink.c (bfd_elf_discard_info): Don't ignore dynamic BFDs.
1196 2012-05-22 H.J. Lu <hongjiu.lu@intel.com>
1199 * elf32-i386.c (elf_i386_create_dynamic_sections): Revert the
1201 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1203 2012-05-22 Alan Modra <amodra@gmail.com>
1205 * elflink.c (bfd_elf_discard_info): Look for next .eh_frame if
1206 first one is zero size or discarded.
1207 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Set most of
1208 glink_eh_frame contents here..
1209 (ppc_elf_finish_dynamic_sections): ..rather than here. Just set
1212 2012-05-22 H.J. Lu <hongjiu.lu@intel.com>
1215 * elf32-i386.c (elf_i386_create_dynamic_sections): Create PLT
1216 eh_frame section if there is an input .eh_frame section.
1217 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1219 2012-05-22 H.J. Lu <hongjiu.lu@intel.com>
1222 * elf32-i386.c (elf_i386_create_dynamic_sections): Always
1223 create PLT eh_frame section with SEC_LINKER_CREATED.
1224 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1226 2012-05-22 Alan Modra <amodra@gmail.com>
1228 * elflink.c (bfd_elf_discard_info): Handle multiple .eh_frame
1229 sections attached to a BFD.
1230 * section.c (bfd_get_section_by_name): Rewrite description.
1231 (bfd_get_next_section_by_name): New function.
1232 * bfd-in2.h: Regenerate.
1234 2012-05-21 Andreas Schwab <schwab@linux-m68k.org>
1236 * elf32-m68k.c (elf_m68k_grok_prstatus): New function.
1237 (elf_m68k_grok_psinfo): New function.
1238 (elf_backend_grok_prstatus): Define.
1239 (elf_backend_grok_psinfo): Define.
1241 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1243 * elf64-mips.c (elf_backend_got_header_size): Correct definition.
1244 * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Use the ELF
1245 backend's GOT header size instead of hardcoding it.
1247 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1249 * elf32-vax.c (elf_vax_relocate_section)
1250 <R_VAX_8, R_VAX_16, R_VAX_32>: Don't check if info->shared again.
1252 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1254 * elf32-vax.c (elf_vax_relocate_section)
1255 <R_VAX_8, R_VAX_16, R_VAX_32>: Use section flags rather than
1256 its name as the check for text sections.
1258 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1260 * elf64-mips.c (mips_elf64_be_swap_reloc_out): Also make sure
1261 the third reloc offset is the same as the first.
1263 2012-05-19 Alan Modra <amodra@gmail.com>
1265 * elf32-ppc.h (has_vle_insns, is_ppc_vle): Delete.
1266 (has_tls_reloc, has_tls_get_addr_call): Move back to..
1267 * elf32-ppc.c: ..here.
1268 (ppc_elf_section_flags, elf_backend_section_flags): Delete.
1269 (ppc_elf_modify_segment_map): Use ELF sh_flags to detect VLE sections.
1271 2012-05-18 H.J. Lu <hongjiu.lu@intel.com>
1273 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Don't make
1274 _DYNAMIC nor _GLOBAL_OFFSET_TABLE_ absolute.
1275 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
1277 2012-05-18 Roland McGrath <mcgrathr@google.com>
1279 * archive.c (_bfd_generic_read_ar_hdr_mag): Fix last change so as
1280 not to clobber the ar_fmag field stored in ARED->arch_header.
1282 2012-05-18 Pedro Alves <palves@redhat.com>
1284 * mach-o.h: Don't include sysdep.h.
1286 2012-05-18 Nick Clifton <nickc@redhat.com>
1289 * bfd-in.h: Check for PACKAGE or PACKAGE_VERSION before
1290 complaining about config.h not having been included.
1291 * bfd-in2.h: Regenerate.
1293 2012-05-18 Andreas Schwab <schwab@linux-m68k.org>
1295 * aclocal.m4: Regenerate.
1296 * Makefile.in: Regenerate.
1298 2012-05-17 Daniel Richard G. <skunk@iskunk.org>
1299 Nick Clifton <nickc@redhat.com>
1302 * configure.in: Add check that sysdep.h has been included before
1303 any system header files.
1304 * configure: Regenerate.
1305 * config.in: Regenerate.
1306 * aclocal.m4: Regenerate.
1307 * bfd-in.h: Generate an error if included before config.h.
1308 * sysdep.h: Likewise.
1309 * bfd-in2.h: Regenerate.
1310 * compress.c: Remove #include "config.h".
1311 * plugin.c: Likewise.
1312 * elf32-m68hc1x.c: Include sysdep.h before alloca-conf.h.
1313 * elf64-hppa.c: Likewise.
1315 * xsymc.c: Likewise.
1317 2012-05-17 Maciej W. Rozycki <macro@linux-mips.org>
1318 Alan Modra <amodra@gmail.com>
1320 * elf.c (ignore_section_sym): Correct comment. Don't return
1321 true for absolute section.
1322 (elf_map_symbols): Move stray comment. Adjust for above change.
1323 Don't discard global section symbols.
1325 2012-05-17 Alan Modra <amodra@gmail.com>
1327 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make _DYNAMIC,
1328 _GLOBAL_OFFSET_TABLE_ or _PROCEDURE_LINKAGE_TABLE_ absolute.
1329 * elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Don't make _DYNAMIC
1332 2012-05-17 Alan Modra <amodra@gmail.com>
1334 * elf32-ppc.c (has_tls_reloc, has_tls_get_addr_call, has_vle_insns,
1335 is_ppc_vle): Move to..
1336 * elf32-ppc.h: ..here, making is_ppc_vle a macro.
1338 2012-05-16 Sergio Durigan Junior <sergiodj@redhat.com>
1340 * bfd-in.h (bfd_get_section_name, bfd_get_section_vma,
1341 bfd_get_section_lma, bfd_get_section_alignment,
1342 bfd_get_section_flags, bfd_get_section_userdata): Rewrite macros
1343 in order to use the `bfd' argument.
1344 * bfd-in2.h: Regenerate.
1345 * elf-vxworks.c (elf_vxworks_finish_dynamic_entry): Pass proper `bfd'
1346 as the first argument for `bfd_get_section_alignment'.
1347 * elf32-arm.c (create_ifunc_sections): Likewise, for
1348 `bfd_set_section_alignment'.
1349 * elf32-m32r.c (m32r_elf_relocate_section): Likewise, for
1350 `bfd_get_section_name'.
1351 * elf32-microblaze.c (microblaze_elf_relocate_section): Likewise.
1352 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
1353 (ppc_elf_relocate_section): Likewise.
1354 * elf64-mmix.c (mmix_final_link_relocate): Likewise, for
1355 `bfd_get_section_vma'.
1356 * elf64-ppc.c (create_linkage_sections): Likewise, for
1357 `bfd_set_section_alignment'.
1359 2012-05-16 Georg-Johann Lay <avr@gjlay.de>
1362 * reloc.c: Rename BFD_RELOC_AVR_8_HHI to BFD_RELOC_AVR_8_HLO.
1363 * bfd-in2.h: Regenerate.
1364 * libbfd.h: Regenrate.
1365 * elf32-avr.c (elf_avr_howto_table): Rename R_AVR_8_HHI8 to
1367 (avr_reloc_map): Likewise.
1369 2012-05-16 Daniel Richard G. <skunk@iskunk.org>
1372 * bfd/aout-cris.c: Include sysdep.h before bfd.h.
1373 * bfd/aout-ns32k.c: Likewise.
1374 * bfd/aout-sparcle.c: Likewise.
1375 * bfd/aout0.c: Likewise.
1376 * bfd/bfd-in2.h: Likewise.
1377 * bfd/coff-stgo32.c: Likewise.
1378 * bfd/cpu-lm32.c: Likewise.
1379 * bfd/cpu-microblaze.c: Likewise.
1380 * bfd/cpu-score.c: Likewise.
1381 * bfd/cpu-tilegx.c: Likewise.
1382 * bfd/cpu-tilepro.c: Likewise.
1383 * bfd/elf32-lm32.c: Likewise.
1384 * bfd/elf32-microblaze.c: Likewise.
1385 * bfd/elf32-score7.c: Likewise.
1386 * bfd/elf32-tilepro.c: Likewise.
1387 * bfd/elfxx-tilegx.c: Likewise.
1388 * bfd/mach-o.h: Likewise.
1389 * bfd/nlm32-ppc.c: Likewise.
1390 * bfd/ns32knetbsd.c: Likewise.
1391 * bfd/pef.h: Likewise.
1392 * bfd/plugin.c: Likewise.
1393 * bfd/stab-syms.c: Likewise.
1394 * bfd/sunos.c: Likewise.
1395 * bfd/syms.c: Likewise.
1396 * bfd/xsym.h: Likewise.
1398 2012-05-16 Alan Modra <amodra@gmail.com>
1400 * elflink.c: Rename flaginfo to flinfo throughout, except..
1401 (bfd_elf_lookup_section_flags): ..here, rename finfo to flaginfo.
1402 Formatting, style. Simplify flag match.
1404 2012-05-16 Alan Modra <amodra@gmail.com>
1406 * dwarf2.c: Formatting.
1407 (arange_add): Pass in unit rather than bfd. Update callers.
1408 Ignore empty ranges. Don't ask for cleared memory.
1409 (parse_comp_unit): Only set unit->base_address if processing
1410 DW_TAG_compile_unit.
1411 (find_debug_info): Optimise section lookup.
1412 (place_sections): Use bfd_alloc for stash->adjusted_sections.
1413 (find_line): Match previously parsed comp unit addresses as we
1414 do for newly parsed comp units.
1416 2012-05-16 Alan Modra <amodra@gmail.com>
1418 * archive.c (_bfd_generic_read_ar_hdr_mag): Ensure sscanf
1419 stops at end of ar_size field.
1421 2012-05-16 Alan Modra <amodra@gmail.com>
1425 * elf.c (bfd_section_from_shdr): Fail when .dynsym sh_info is
1426 out of range. As a special case, fix sh_info for zero sh_size.
1427 Do the same for .symtab.
1429 2012-05-15 James Murray <jsm@jsm-net.demon.co.uk>
1430 Stephane Carrez <stcarrez@nerim.fr>
1432 * archures.c: Add bfd_arch_m9s12x and bfd_arch_m9s12xg.
1433 * config.bfd: Likewise.
1434 * cpu-m9s12x.c: New.
1435 * cpu-m9s12xg.c: New.
1436 * elf32-m68hc12.c: Add S12X and XGATE co-processor support.
1437 Add option to offset S12 addresses into XGATE memory space.
1438 Fix carry bug in IMM16 (IMM8 low/high) relocate.
1439 * Makefile.am (ALL_MACHINES): Add cpu-m9s12x and cpu-m9s12xg.
1440 (ALL_MACHINES_CFILES): Likewise.
1441 * reloc.c: Add S12X relocs.
1442 * Makefile.in: Regenerate.
1443 * bfd-in2.h: Regenerate.
1444 * libbfd.h: Regenerate.
1446 2012-05-14 James Lemke <jwlemke@codesourcery.com>
1447 Catherine Moore <clm@codesourcery.com>
1449 * bfd.c (bfd_lookup_section_flags): Add section parm.
1450 * ecoff.c (bfd_debug_section): Remove flag_info initializer.
1451 * elf-bfd.h (bfd_elf_section_data): Move in section_flag_info.
1452 (bfd_elf_lookup_section_flags): Add section parm.
1453 * elf32-ppc.c (is_ppc_vle): New function.
1454 (ppc_elf_modify_segment_map): New function.
1455 (elf_backend_modify_segment_map): Define.
1456 (has_vle_insns): New define.
1457 * elf32-ppc.h (ppc_elf_modify_segment_map): Declare.
1458 * elflink.c (bfd_elf_lookup_section_flags): Add return value & parm.
1459 Move in logic to omit / include a section.
1460 * libbfd-in.h (bfd_link_info): Add section parm.
1461 (bfd_generic_lookup_section_flags): Likewise.
1462 * reloc.c (bfd_generic_lookup_section_flags): Likewise.
1463 * section.c (bfd_section): Move out section_flag_info.
1464 (BFD_FAKE_SECTION): Remove flag_info initializer.
1465 * targets.c (_bfd_lookup_section_flags): Add section parm.
1467 2012-05-14 Catherine Moore <clm@codesourcery.com>
1469 * archures.c (bfd_mach_ppc_vle): New.
1470 * bfd-in2.h: Regenerated.
1471 * cpu-powerpc.c (bfd_powerpc_archs): New entry for vle.
1472 * elf32-ppc.c (split16_format_type): New enumeration.
1473 (ppc_elf_vle_split16): New function.
1474 (HOWTO): Add entries for R_PPC_VLE relocations.
1475 (ppc_elf_reloc_type_lookup): Handle PPC_VLE relocations.
1476 (ppc_elf_section_flags): New function.
1477 (ppc_elf_lookup_section_flags): New function.
1478 (ppc_elf_section_processing): New function.
1479 (ppc_elf_check_relocs): Handle PPC_VLE relocations.
1480 (ppc_elf_relocation_section): Likewise.
1481 (elf_backend_lookup_section_flags_hook): Define.
1482 (elf_backend_section_flags): Define.
1483 (elf_backend_section_processing): Define.
1484 * elf32-ppc.h (ppc_elf_section_processing): Declare.
1485 * libbfd.h: Regenerated.
1486 * reloc.c (BFD_RELOC_PPC_VLE_REL8, BFD_RELOC_PPC_VLE_REL15,
1487 BFD_RELOC_PPC_VLE_REL24, BFD_RELOC_PPC_VLE_LO16A,
1488 BFD_RELOC_PPC_VLE_LO16D, BFD_RELOC_PPC_VLE_HI16A,
1489 BFD_RELOC_PPC_VLE_HI16D, BFD_RELOC_PPC_VLE_HA16A,
1490 BFD_RELOC_PPC_VLE_HA16D, BFD_RELOC_PPC_VLE_SDA21,
1491 BFD_RELOC_PPC_VLE_SDA21_LO, BFD_RELOC_PPC_VLE_SDAREL_LO16A,
1492 BFD_RELOC_PPC_VLE_SDAREL_LO16D, BFD_RELOC_PPC_VLE_SDAREL_HI16A,
1493 BFD_RELOC_PPC_VLE_SDAREL_HI16D, BFD_RELOC_PPC_VLE_SDAREL_HA16A,
1494 BFD_RELOC_PPC_VLE_SDAREL_HA16D): New bfd relocations.
1496 2012-05-11 Georg-Johann Lay <avr@gjlay.de>
1499 * reloc.c: Add new ENUM for BFD_RELOC_AVR_8_LO,
1500 BFD_RELOC_AVR_8_HI, BFD_RELOC_AVR_8_HHI.
1501 * bfd-in2.h: Regenerate.
1502 * libbfd.h: Regenrate.
1503 * elf32-avr.c (elf_avr_howto_table): Add entries for
1504 R_AVR_8_LO8, R_AVR_8_HI8, R_AVR_8_HHI8.
1505 (avr_reloc_map): Add RELOC mappings for R_AVR_8_LO8, R_AVR_8_HI8,
1508 2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
1510 * elf64-x86-64.c (elf_x86_64_relocate_section): Use int in x32
1511 addend overflow check.
1513 2012-05-10 DJ Delorie <dj@redhat.com>
1515 * elf32-rx.c (rx_elf_object_p): Ignore empty segments.
1517 2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
1519 * elf64-x86-64.c (elf_x86_64_relocate_section): Display signed
1520 hex number in x32 addend overflow check.
1522 2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
1524 * elf64-x86-64.c (elf_x86_64_reloc_type_class): Handle
1525 R_X86_64_RELATIVE64.
1527 2012-05-09 H.J. Lu <hongjiu.lu@intel.com>
1529 * elf64-x86-64.c (elf_x86_64_relocate_section): Check addend
1530 overflow for R_X86_64_RELATIVE64.
1532 2012-05-08 Ben Cheng <bccheng@google.com>
1534 * elf.c: Preserve the original p_align and p_flags if they are
1537 2012-05-07 Alan Modra <amodra@gmail.com>
1539 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Update
1540 RELOC_AGAINST_DISCARDED_SECTION invocation.
1542 2012-05-07 Hans-Peter Nilsson <hp@axis.com>
1544 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Declare and use
1545 local variable i_ instead of assuming and using a variable i.
1547 2012-05-07 Maciej W. Rozycki <macro@linux-mips.org>
1549 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Handle compound
1551 * elfxx-mips.c (mips_reloc_against_discarded_section): New
1553 (_bfd_mips_elf_relocate_section): Call it, in place of
1554 RELOC_AGAINST_DISCARDED_SECTION.
1555 * elf-m10200.c (mn10200_elf_relocate_section): Update arguments
1556 to RELOC_AGAINST_DISCARDED_SECTION.
1557 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
1558 * elf32-arm.c (elf32_arm_relocate_section): Likewise.
1559 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
1560 * elf32-bfin.c (bfin_relocate_section): Likewise.
1561 (bfinfdpic_relocate_section): Likewise.
1562 * elf32-cr16.c (elf32_cr16_relocate_section): Likewise.
1563 * elf32-cr16c.c (elf32_cr16c_relocate_section): Likewise.
1564 * elf32-cris.c (cris_elf_relocate_section): Likewise.
1565 * elf32-crx.c (elf32_crx_relocate_section): Likewise.
1566 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
1567 * elf32-epiphany.c (epiphany_elf_relocate_section): Likewise.
1568 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
1569 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
1570 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
1571 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
1572 * elf32-i370.c (i370_elf_relocate_section): Likewise.
1573 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1574 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
1575 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
1576 * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
1577 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
1578 * elf32-m32c.c (m32c_elf_relocate_section): Likewise.
1579 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
1580 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
1581 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1582 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
1583 * elf32-mep.c (mep_elf_relocate_section): Likewise.
1584 * elf32-moxie.c (moxie_elf_relocate_section): Likewise.
1585 * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
1586 * elf32-mt.c (mt_elf_relocate_section): Likewise.
1587 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
1588 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1589 * elf32-rl78.c (rl78_elf_relocate_section): Likewise.
1590 * elf32-rx.c (rx_elf_relocate_section): Likewise.
1591 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1592 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
1593 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1594 * elf32-sh.c (sh_elf_relocate_section): Likewise.
1595 * elf32-spu.c (spu_elf_relocate_section): Likewise.
1596 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
1597 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
1598 * elf32-v850.c (v850_elf_relocate_section): Likewise.
1599 * elf32-vax.c (elf_vax_relocate_section): Likewise.
1600 * elf32-xc16x.c (elf32_xc16x_relocate_section): Likewise.
1601 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
1602 * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
1603 * elf64-alpha.c (elf64_alpha_relocate_section_r): Likewise.
1604 (elf64_alpha_relocate_section): Likewise.
1605 * elf64-hppa.c (elf64_hppa_relocate_section): Likewise.
1606 * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
1607 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
1608 * elf64-s390.c (elf_s390_relocate_section): Likewise.
1609 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
1610 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
1611 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
1612 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1613 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
1615 2012-05-05 Alan Modra <amodra@gmail.com>
1619 * linker.c (_bfd_nearby_section): Revert 2012-02-13 change.
1621 2012-05-05 Alan Modra <amodra@gmail.com>
1623 * aout-arm.c: Replace all uses of bfd_abs_section, bfd_com_section,
1624 bfd_und_section and bfd_ind_section with their _ptr variants, or
1625 use corresponding bfd_is_* macros.
1626 * aout-ns32k.c: Likewise.
1627 * aout-tic30.c: Likewise.
1628 * coff-arm.c: Likewise.
1629 * coff-tic54x.c: Likewise.
1630 * cpu-ns32k.c: Likewise.
1631 * elf-attrs.c: Likewise.
1632 * elfcode.h: Likewise.
1633 * peicode.h: Likewise.
1634 * reloc.c: Likewise.
1635 * riscix.c: Likewise.
1636 * versados.c: Likewise.
1637 * section.c: Likewise.
1638 (bfd_abs_section, bfd_ind_section, bfd_com_section,
1639 bfd_ind_section): Delete.
1640 (std_section): New array replacing above.
1641 (bfd_abs_section_ptr, bfd_ind_section_ptr, bfd_com_section_ptr,
1642 bfd_ind_section_ptr, STD_SECTION): Update.
1643 (BFD_FAKE_SECTION, GLOBAL_SYM_INIT): Remove unnecessary casts.
1644 * bfd-in2.h: Regenerate.
1646 2012-05-03 Sean Keys <skeys@ipdatasys.com>
1648 * cpu-xgate.c: New file. Added XGATE support.
1649 * archures.c (bfd_architecture): Add XGATE architecture.
1650 (bfd_archures_list): Add reference to XGATE architecture info.
1651 * elf-bfd.h (prep_headers): Handle bfd_arch_xgate.
1652 * reloc.c: Add various XGATE relocation enums.
1653 * targets.c (bfd_elf32_xgate_vec): Declare and add to target vector
1655 * Makefile.am: Add support for XGATE elf.
1656 * configure.in: Ditto.
1657 * config.bfd: Ditto.
1658 * Makefile.in: Regenerate.
1662 Added files for XGATE relocations.
1663 * elf32-xgate.c: Created minimal relocation file.
1664 * elf32-xgate.h: Created minimal header file for elf32-xgate.
1666 2012-05-03 Tristan Gingold <gingold@adacore.com>
1668 * dwarf2.c (decode_line_info): Ignore
1669 DW_LNE_HP_source_file_correlation.
1671 2012-05-01 Nick Clifton <nickc@redhat.com>
1674 * aoutx.h: Rename 'finfo' to 'flaginfo' to avoid conflicts with
1676 * coff-ppc.c: Likewise.
1677 * cofflink.c: Likewise.
1678 * elf32-arm.c: Likewise.
1679 * elf64-sparc.c: Likewise.
1680 * elflink.c: Likewise.
1681 * pdp11.c: Likewise.
1682 * rescoff.c: Likewise.
1684 2012-04-26 Mark Wielaard <mjw@redhat.com>
1686 * dwarf2.c (scan_unit_for_symbols): Account for DW_AT_high_pc
1687 possibly being relative to DW_AT_low_pc.
1688 (parse_comp_unit): Likewise.
1690 2012-04-26 Andreas Schwab <schwab@linux-m68k.org>
1692 * elf32-m68k.c (elf_m68k_check_relocs): Mark non-GOT references
1693 also when generating PIE.
1694 (elf_m68k_discard_copies): Mark undefined weak symbols referenced
1695 by relocations as dynamic.
1697 2012-04-26 Hans-Peter Nilsson <hp@axis.com>
1699 Provide a way for programs to recognize BFD_ASSERT calls.
1700 * bfd.c (bfd_assert_handler_type): New API type.
1701 (bfd_set_assert_handler, bfd_get_assert_handler): New API functions.
1702 (_bfd_assert_handler): New variable.
1703 (_bfd_default_assert_handler): New function.
1704 (bfd_assert): Call _bfd_assert_handler, not _bfd_error_handler.
1705 * libbfd-in.h (_bfd_assert_handler): Declare.
1706 * libbfd.h, bfd-in2.h: Regenerate.
1708 2012-04-24 Hans-Peter Nilsson <hp@axis.com>
1711 * elf32-arm.c (elf32_arm_gc_sweep_hook): Handle a forced-local
1712 symbol, where PLT refcount is set to -1.
1714 2012-04-24 Alan Modra <amodra@gmail.com>
1717 * elf-bfd.h (_bfd_elf_link_just_syms): Define as
1718 _bfd_generic_link_just_syms.
1719 * elflink.c (_bfd_elf_link_just_syms): Delete.
1720 * linker.c (_bfd_generic_link_just_syms): Set sec_info_type.
1722 * bfd-in.h (discarded_section): Renamed from elf_discarded_section.
1723 * section.c (SEC_INFO_TYPE_NONE, SEC_INFO_TYPE_STABS,
1724 SEC_INFO_TYPE_MERGE, SEC_INFO_TYPE_EH_FRAME,
1725 SEC_INFO_TYPE_JUST_SYMS): Renamed from corresponding ELF_INFO_TYPE.
1726 * elf-eh-frame.c, * elf-m10200.c, * elf-m10300.c,
1727 * elf.c, * elf32-arm.c, * elf32-avr.c, * elf32-bfin.c,
1728 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c,
1729 * elf32-crx.c, * elf32-d10v.c, * elf32-epiphany.c,
1730 * elf32-fr30.c, * elf32-frv.c, * elf32-h8300.c,
1731 * elf32-hppa.c, * elf32-i370.c, * elf32-i386.c,
1732 * elf32-i860.c, * elf32-ip2k.c, * elf32-iq2000.c,
1733 * elf32-lm32.c, * elf32-m32c.c, * elf32-m32r.c,
1734 * elf32-m68hc1x.c, * elf32-m68k.c, * elf32-mcore.c,
1735 * elf32-mep.c, * elf32-moxie.c, * elf32-msp430.c,
1736 * elf32-mt.c, * elf32-openrisc.c, * elf32-ppc.c,
1737 * elf32-rl78.c, * elf32-rx.c, * elf32-s390.c,
1738 * elf32-score.c, * elf32-score7.c, * elf32-sh.c,
1739 * elf32-spu.c, * elf32-tic6x.c, * elf32-tilepro.c,
1740 * elf32-v850.c, * elf32-vax.c, * elf32-xc16x.c,
1741 * elf32-xstormy16.c, * elf32-xtensa.c, * elf64-alpha.c,
1742 * elf64-hppa.c, * elf64-ia64-vms.c, * elf64-mmix.c,
1743 * elf64-ppc.c, * elf64-s390.c, * elf64-sh64.c,
1744 * elf64-x86-64.c, * elflink.c, * elfnn-ia64.c,
1745 * elfxx-mips.c, * elfxx-sparc.c, * elfxx-tilegx.c,
1746 * reloc.c: Update all references.
1747 * bfd-in2.h: Regenerate.
1749 2012-04-20 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
1751 * elf32-s390.c (ELF_DYNAMIC_INTERPRETER): Set to the GCC default.
1752 * elf64-s390.c (ELF_DYNAMIC_INTERPRETER): Set to the GCC default.
1754 2012-04-19 Thomas Schwinge <thomas@codesourcery.com>
1756 * elf32-sh.c (elf_sh_link_hash_entry): Specify an enum identifier for
1758 (allocate_dynrelocs, sh_elf_relocate_section, sh_elf_check_relocs): Use
1761 2012-04-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1763 * elf32-sh.c (allocate_dynrelocs): Don't allocate dynamic
1764 relocations when LE conversion happens on the IE tls symbol.
1766 2012-04-17 Roland McGrath <mcgrathr@google.com>
1768 * elf64-x86-64.c (elf_x86_64_nacl_plt0_entry): Fix nop padding
1769 so that 32-byte boundary is a proper instruction boundary.
1771 2012-04-17 Tristan Gingold <gingold@adacore.com>
1773 * vms-lib.c (_bfd_vms_lib_get_module): Append .obj extension to
1774 member of an object archive.<
1776 2012-04-17 Tristan Gingold <gingold@adacore.com>
1778 * vms-lib.c (MAX_EKEYLEN): Define.
1779 (MAX_KEYLEN): Fix value.
1780 (vms_write_index): Add comments and fix indentation.
1781 Adjust comparaison. Add assertions. Free kbn_blk.
1782 (_bfd_vms_lib_write_archive_contents): Use MAX_EKEYLEN.
1783 Compense MAX_KEYLEN adjustment.
1785 2012-04-16 Maciej W. Rozycki <macro@linux-mips.org>
1787 * elfxx-mips.c (mips16_stub_symndx): Handle n64 compound relocs.
1788 (_bfd_mips_elf_check_relocs): Update accordingly.
1790 2012-04-13 Alan Modra <amodra@gmail.com>
1793 * elflink.c (bfd_elf_final_link): Set reloc_count to 0 for
1796 2012-04-12 David S. Miller <davem@davemloft.net>
1798 * reloc.c (BFD_RELOC_SPARC_H34, BFD_RELOC_SPARC_SIZE32,
1799 BFD_RELOC_SPARC_SIZE64, BFD_RELOC_SPARC_WDISP10): New relocs.
1800 * libbfd.h: Regenerate.
1801 * bfd-in2.h: Likewise.
1802 * elfxx-sparc.c (sparc_elf_wdisp10_reloc): New function.
1803 (_bfd_sparc_elf_howto_table): Add entries for R_SPARC_H34,
1804 R_SPARC_SIZE32, R_SPARC_64, and R_SPARC_WDISP10.
1805 (_bfd_sparc_elf_reloc_type_lookup): Handle new relocs.
1806 (_bfd_sparc_elf_check_relocs): Likewise.
1807 (_bfd_sparc_elf_gc_sweep_hook): Likewise.
1808 (_bfd_sparc_elf_relocate_section): Likewise.
1810 2012-04-12 Roland McGrath <mcgrathr@google.com>
1812 * elf32-arm.c (elf32_arm_nacl_plt0_entry, elf32_arm_nacl_plt_entry):
1814 (struct elf32_arm_link_hash_table): New member `nacl_p'.
1815 (elf32_arm_link_hash_table_create): Initialize it.
1816 (elf32_arm_nacl_link_hash_table_create): New function.
1817 (arm_movw_immediate, arm_movt_immediate): New functions.
1818 (elf32_arm_populate_plt_entry): Test HTAB->nacl_p.
1819 (elf32_arm_finish_dynamic_sections): Likewise.
1820 (elf32_arm_output_plt_map_1): Likewise.
1821 (bfd_elf32_littlearm_nacl_vec, bfd_elf32_bigarm_nacl_vec):
1822 New backend vector stanza.
1823 (elf32_arm_nacl_modify_segment_map): New function.
1824 * config.bfd: Handle arm-*-nacl*, armeb-*-nacl*.
1825 * targets.c: Support bfd_elf32_{big,little}_nacl_vec.
1826 * configure.in: Likewise.
1827 (bfd_elf32_bigarm_nacl_vec): Add elf-nacl.lo here.
1828 (bfd_elf32_littlearm_nacl_vec): Likewise.
1829 (bfd_elf32_bigarm_vec, bfd_elf32_littlearm_vec): Likewise.
1830 (bfd_elf32_bigarm_symbian_vec): Likewise.
1831 (bfd_elf32_littlearm_symbian_vec): Likewise.
1832 (bfd_elf32_bigarm_vxworks_vec): Likewise.
1833 (bfd_elf32_littlearm_vxworks_vec): Likewise.
1834 * configure: Regenerated.
1836 2012-04-12 Tristan Gingold <gingold@adacore.com>
1838 * elflink.c (elf_link_output_extsym): Add a guard.
1839 (bfd_elf_final_link): Remove assertion.
1840 (bfd_elf_final_link): Add a guard.
1841 * elfnn-ia64.c (INCLUDE_IA64_VMS): Removed.
1842 (elfNN_vms_section_from_shdr, elfNN_vms_object_p)
1843 (elfNN_vms_post_process_headers, elfNN_vms_section_processing)
1844 (elfNN_vms_final_write_processing, elfNN_vms_close_and_cleanup):
1846 (elfNN-ia64-vms target): Move to ...
1847 * elf64-ia64-vms.c: New file.
1848 * configure.in (bfd_elf64_ia64_vms_vec): Add elf64-ia64-vms.lo
1849 * Makefile.am (BFD64_BACKENDS): Add elf64-ia64-vms.lo.
1850 (BFD64_BACKENDS_CFILES): Ad elf64-ia64-vms.c.
1851 * configure: Regenerate.
1852 * Makefile.in: Regenerate.
1854 2012-04-11 Nick Clifton <nickc@redhat.com>
1857 * elf64-ppc.c (opd_entry_value): When dealing with sections
1858 without relocs, keep the last section loaded in order to avoid
1859 unnecessary reloads.
1861 2012-04-09 Roland McGrath <mcgrathr@google.com>
1863 * elf.c (_bfd_elf_map_sections_to_segments): Set INFO->user_phdrs.
1864 * elf-nacl.c (nacl_modify_segment_map): Do nothing if INFO->user_phdrs.
1865 (nacl_modify_program_headers): Likewise.
1867 2012-04-03 Roland McGrath <mcgrathr@google.com>
1869 * elf-nacl.c: New file.
1870 * elf-nacl.h: New file.
1871 * elf32-i386.c (elf_backend_modify_segment_map): Define for
1872 bfd_elf32_i386_nacl_vec.
1873 (elf_backend_modify_program_headers): Likewise.
1874 * elf64-x86-64.c (elf_backend_modify_segment_map): Define for
1875 bfd_elf64_x86_64_nacl_vec and bfd_elf32_x86_64_nacl_vec.
1876 (elf_backend_modify_program_headers): Likewise.
1877 * Makefile.am (BFD32_BACKENDS, BFD64_BACKENDS): Add elf-nacl.lo here.
1878 (BFD32_BACKENDS_CFILES, BFD64_BACKENDS_CFILES): Add elf-nacl.c here.
1879 * Makefile.in: Regenerated.
1880 * configure.in (bfd_elf64_x86_64_nacl_vec): Add elf-nacl.o to tb here.
1881 (bfd_elf32_x86_64_nacl_vec): Likewise.
1882 (bfd_elf64_x86_64_vec, bfd_elf32_x86_64_vec): Likewise.
1883 (bfd_elf64_x86_64_freebsd_vec, bfd_elf64_x86_64_sol2_vec): Likewise.
1884 (bfd_elf64_l1om_vec, bfd_elf64_l1om_freebsd_vec): Likewise.
1885 (bfd_elf64_k1om_vec, bfd_elf64_k1om_freebsd_vec): Likewise.
1886 (bfd_elf32_i386_nacl_vec): Likewise.
1887 (bfd_elf32_i386_sol2_vec, bfd_elf32_i386_freebsd_vec): Likewise.
1888 (bfd_elf32_i386_vxworks_vec, bfd_elf32_i386_vec): Likewise.
1889 * configure: Regenerated.
1891 2012-03-31 Andreas Schwab <schwab@linux-m68k.org>
1893 * elf32-m68k.c (elf_m68k_relocate_section): Allow
1894 R_68K_TLS_LE{8,16,32} for PIE.
1896 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
1898 * elf64-s390.c: Fix several comments regarding PLT entry
1900 * elf32-s390.c: Likewise.
1902 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
1904 * elf64-s390.c: Use the section pointer shortcuts in
1905 elf_link_hash_table and remove them from the target specific
1907 * elf32-s390.c: Likewise.
1909 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
1911 * elf64-s390.c (elf_s390x_plt_entry, elf_s390x_first_plt_entry):
1913 (PLT_PIC_ENTRY_WORD*, PLT_PIC12_ENTRY_WORD*): Remove.
1914 (elf_s390_finish_dynamic_symbol): Use memcpy instead of bfd_put_32.
1915 (elf_s390_finish_dynamic_sections): Likewise.
1916 * elf32-s390.c (elf_s390_plt_entry, elf_s390_plt_pic_entry)
1917 (elf_s390_plt_pic12_entry, elf_s390_plt_pic16_entry)
1918 (elf_s390_plt_first_entry, elf_s390_plt_pic_first_entry): New definitions.
1919 (PLT_PIC16_ENTRY_WORD*, PLT_ENTRY_WORD*)
1920 (PLT_PIC_FIRST_ENTRY_WORD*, PLT_FIRST_ENTRY_WORD*): Remove.
1922 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
1924 * elf32-s390.c (struct elf_s390_dyn_relocs): Remove.
1925 Rename all occurrences in the file to elf_dyn_relocs.
1926 * elf64-s390.c: Likewise.
1928 2012-03-30 Alan Modra <amodra@gmail.com>
1930 * elflink.c (_bfd_elf_gc_mark_reloc): Don't delve into dynamic
1933 2012-03-29 Alan Modra <amodra@gmail.com>
1935 * bfd-in.h (bfd_get_arch_size, bfd_get_sign_extend_vma): Delete.
1936 * bfd-in2.h: Regenerate.
1938 2012-03-23 Alan Modra <amodra@gmail.com>
1940 * elf.c (assign_file_positions_for_non_load_sections): Don't warn
1941 on empty alloc sections.
1943 2012-03-23 Alan Modra <amodra@gmail.com>
1945 * linker.c (_bfd_nearby_section): New function, split out from..
1947 * bfd-in.h (_bfd_nearby_section): Declare.
1948 * bfd-in2.h: Regenerate.
1949 * elflink.c (elf_link_input_bfd): Don't use text_index_section or
1950 data_index_section with ld -q or ld -r output relocs against
1951 stripped output sections. Instead use _bfd_nearby_section.
1953 2012-03-23 Alan Modra <amodra@gmail.com>
1956 * elf64-ppc.c (opd_entry_value): Read full symbol table when
1957 sym hashes unavailable.
1959 2012-03-21 Eliot Dresselhaus <eliot@sonic.net>
1961 * elf32-tic6x.c (elf32_tic6x_merge_private_bfd_data): Return TRUE
1962 for non-C6X objects.
1964 2012-03-20 Kai Tietz <ktietz@redhat.com>
1967 * configure.in (AC_CHECK_HEADERS): Test for windows.h and dlfcn.h.
1968 * plugin.c: Guard include of dlfcn.h if HAVE_DLFCN_H is defined.
1969 Add windows.h header include if HAVE_WINDOWS_H is defined.
1970 (dlerror): New static function if windows variant is used instead
1972 (dlclose): Likewise.
1975 * configure: Regenerated.
1976 * config.in: Regenerated.
1978 2012-03-20 H.J. Lu <hongjiu.lu@intel.com>
1981 * elf32-i386.c (elf_i386_relocate_section): Don't issue an error
1982 for R_386_GOTOFF relocation against protected function if
1983 SYMBOLIC_BIND is true.
1985 * elf64-x86-64.c (elf_x86_64_relocate_section): Don't issue an
1986 error for R_X86_64_GOTOFF64 relocation against protected function
1987 when building executable or SYMBOLIC_BIND is true.
1989 2012-03-16 Roland McGrath <mcgrathr@google.com>
1991 * config.bfd: Handle x86_64-*-nacl*.
1992 * elf64-x86-64.c (bfd_elf64_x86_64_nacl_vec): New backend vector stanza.
1993 (bfd_elf32_x86_64_nacl_vec): Likewise.
1994 * targets.c: Support them.
1995 * configure.in: Likewise.
1996 * configure: Regenerated.
1998 2012-03-16 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
2000 * elf32-arm.c (elf32_arm_attributes_accept_div): New function.
2001 (elf32_arm_attributes_forbid_div): Likewise.
2002 (elf32_arm_merge_eabi_attributes): Correct handling of
2005 2012-03-15 Roland McGrath <mcgrathr@google.com>
2007 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Use
2008 elf_x86_64_backend_data parameters for plt_eh_frame.
2010 * elf64-x86-64.c (struct elf_x86_64_backend_data): New type.
2011 (get_elf_x86_64_backend_data, GET_PLT_ENTRY_SIZE): New macros.
2012 (elf_x86_64_arch_bed): New variable.
2013 (elf_backend_arch_data): New macro.
2014 (elf_x86_64_adjust_dynamic_symbol): Use GET_PLT_ENTRY_SIZE.
2015 (elf_x86_64_allocate_dynrelocs): Likewise.
2016 (elf_x86_64_relocate_section): Likewise.
2017 (elf_x86_64_plt_sym_val): Likewise.
2018 (elf_x86_64_finish_dynamic_symbol): Use elf_x86_64_backend_data
2019 parameters for PLT details.
2020 (elf_x86_64_finish_dynamic_sections): Likewise.
2022 2012-03-14 Roland McGrath <mcgrathr@google.com>
2024 * elf32-i386.c (elf_i386_nacl_pic_plt0_entry): Initialize up
2025 to the full size, padding out with nop instructions.
2027 2012-03-12 Alan Modra <amodra@gmail.com>
2029 * elf-m10300.c (_bfd_mn10300_elf_adjust_dynamic_symbol): Don't warn
2030 on zero size dynbss symbol.
2031 * elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Likewise.
2032 * elf32-cr16.c (_bfd_cr16_elf_adjust_dynamic_symbol): Likewise.
2033 * elf32-cris.c (elf_cris_adjust_dynamic_symbol): Likewise.
2034 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
2035 * elf32-i370.c (i370_elf_adjust_dynamic_symbol): Likewise.
2036 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Likewise.
2037 * elf32-lm32.c (lm32_elf_adjust_dynamic_symbol): Likewise.
2038 * elf32-m32r.c (m32r_elf_adjust_dynamic_symbol): Likewise.
2039 * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
2040 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
2041 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
2042 * elf32-sh.c (sh_elf_adjust_dynamic_symbol): Likewise.
2043 * elf32-tic6x.c (elf32_tic6x_adjust_dynamic_symbol): Likewise.
2044 * elf32-tilepro.c (tilepro_elf_adjust_dynamic_symbol): Likewise.
2045 * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Likewise.
2046 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
2047 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
2048 * elf64-sh64.c (sh64_elf64_adjust_dynamic_symbol): Likewise.
2049 * elf64-x86-64.c (elf_x86_64_adjust_dynamic_symbol): Likewise.
2050 * elfxx-sparc.c (_bfd_sparc_elf_adjust_dynamic_symbol): Likewise.
2051 * elfxx-tilegx.c (tilegx_elf_adjust_dynamic_symbol): Likewise.
2053 2012-03-10 Edmar Wienskoski <edmar@freescale.com>
2055 * archures.c: Add bfd_mach_ppc_e5500 and bfd_mach_ppc_e6500.
2056 * bfd-in2.h: Regenerate.
2057 * cpu-powerpc.c (bfd_powerpc_archs): Add entries for
2058 bfd_mach_ppc_e5500 and bfd_mach_ppc_e6500.
2060 2012-03-09 H.J. Lu <hongjiu.lu@intel.com>
2063 * elf32-i386.c (elf_i386_relocate_section): Restore
2066 * elf64-x86-64.c (elf_x86_64_relocate_section): Restore
2069 2012-03-08 Tristan Gingold <gingold@adacore.com>
2071 * vms-lib.c (_bfd_vms_lib_write_archive_contents): Set maximum
2072 keylen according to archive kind. Set nextvbn and nextrfa lhd
2073 fields. Add comments.
2075 2012-03-07 Nick Clifton <nickc@redhat.com>
2077 * elf-m10300.c (elf32_mn10300_link_hash_entry): Add tls_type
2079 (elf32_mn10300_link_hash_table): Add tls_ldm_got entry;
2080 (elf_mn10300_tdata): Define.
2081 (elf_mn10300_local_got_tls_type): Define.
2082 (elf_mn10300_howto_table): Add entries for R_MN10300_TLS_GD,
2083 R_MN10300_TLS_LD, R_MN10300_TLS_LDO, R_MN10300_TLS_GOTIE,
2084 R_MN10300_TLS_IE, R_MN10300_TLS_LE, R_MN10300_TLS_DPTMOD,
2085 R_MN10300_TLS_DTPOFF, R_MN10300_TLS_TPOFF relocs.
2086 (mn10300_reloc_map): Likewise.
2087 (elf_mn10300_tls_transition): New function.
2088 (dtpoff, tpoff, mn10300_do_tls_transition): New functions.
2089 (mn10300_elf_check_relocs): Add TLS support.
2090 (mn10300_elf_final_link_relocate): Likewise.
2091 (mn10300_elf_relocate_section): Likewise.
2092 (mn10300_elf_relax_section): Likewise.
2093 (elf32_mn10300_link_hash_newfunc): Initialise new field.
2094 (_bfd_mn10300_copy_indirect_symbol): New function.
2095 (elf32_mn10300_link_hash_table_create): Initialise new fields.
2096 (_bfd_mn10300_elf_size_dynamic_sections): Add TLS support.
2097 (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise.
2098 (_bfd_mn10300_elf_reloc_type_class): Allocate an
2099 elf_mn10300_obj_tdata structure.
2100 (elf_backend_copy_indirect_symbol): Define.
2101 * reloc.c (BFD_MN10300_TLS_GD, BFD_MN10300_TLS_LD,
2102 BFD_MN10300_TLS_LDO, BFD_MN10300_TLS_GOTIE, BFD_MN10300_TLS_IE,
2103 BFD_MN10300_TLS_LE, BFD_MN10300_TLS_DPTMOD,
2104 BFD_MN10300_TLS_DTPOFF, BFD_MN10300_TLS_TPOFF): New relocations.
2105 (BFD_RELOC_MN10300_32_PCREL, BFD_RELOC_MN10300_16_PCREL): Move to
2106 alongside other MN10300 relocations.
2107 * bfd-in2.h: Regenerate.
2108 * libbfd.h: Regenerate.
2110 2012-03-06 Jakub Jelinek <jakub@redhat.com>
2112 * elf64-x86-64.c (elf_x86_64_relocate_section): For R_X86_64_RELATIVE
2113 set relocate to TRUE.
2115 2012-03-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2118 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Also ignore
2119 overflows for R_SPARC_UA32 in .stab sections.
2121 2012-03-01 Alan Modra <amodra@gmail.com>
2123 * elfxx-tilegx.c (tilegx_elf_relocate_section): Silence bogus warning.
2125 2012-02-27 Alan Modra <amodra@gmail.com>
2127 * elf32-sh.c (sh_elf_osec_to_segment): Check for elf flavour bfd
2128 before calling elf specific function.
2129 (sh_elf_osec_readonly_p): Test for error return from above.
2131 2012-02-27 Alan Modra <amodra@gmail.com>
2133 * elf32-spu.c (build_stub): Fix malloc under-allocation.
2135 2012-02-25 Walter Lee <walt@tilera.com>
2136 * reloc.c: Add BFD_RELOC_TILEPRO_TLS_GD_CALL,
2137 BFD_RELOC_TILEPRO_IMM8_X0_TLS_GD_ADD,
2138 BFD_RELOC_TILEPRO_IMM8_X1_TLS_GD_ADD,
2139 BFD_RELOC_TILEPRO_IMM8_Y0_TLS_GD_ADD,
2140 BFD_RELOC_TILEPRO_IMM8_Y1_TLS_GD_ADD,
2141 BFD_RELOC_TILEPRO_TLS_IE_LOAD, BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE,
2142 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE,
2143 BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_LO,
2144 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_LO,
2145 BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_HI,
2146 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_HI,
2147 BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_HA,
2148 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_HA,
2149 BFD_RELOC_TILEGX_IMM16_X0_HW0_TLS_LE,
2150 BFD_RELOC_TILEGX_IMM16_X1_HW0_TLS_LE,
2151 BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_TLS_LE,
2152 BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_TLS_LE,
2153 BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_TLS_LE,
2154 BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_TLS_LE,
2155 BFD_RELOC_TILEGX_TLS_GD_CALL, BFD_RELOC_TILEGX_IMM8_X0_TLS_GD_ADD,
2156 BFD_RELOC_TILEGX_IMM8_X1_TLS_GD_ADD,
2157 BFD_RELOC_TILEGX_IMM8_Y0_TLS_GD_ADD,
2158 BFD_RELOC_TILEGX_IMM8_Y1_TLS_GD_ADD, BFD_RELOC_TILEGX_TLS_IE_LOAD,
2159 BFD_RELOC_TILEGX_IMM8_X0_TLS_ADD,
2160 BFD_RELOC_TILEGX_IMM8_X1_TLS_ADD,
2161 BFD_RELOC_TILEGX_IMM8_Y0_TLS_ADD, BFD_RELOC_TILEGX_IMM8_Y1_TLS_ADD.
2162 Delete BFD_RELOC_TILEGX_IMM16_X0_HW1_GOT,
2163 BFD_RELOC_TILEGX_IMM16_X1_HW1_GOT,
2164 BFD_RELOC_TILEGX_IMM16_X0_HW2_GOT,
2165 BFD_RELOC_TILEGX_IMM16_X1_HW2_GOT,
2166 BFD_RELOC_TILEGX_IMM16_X0_HW3_GOT,
2167 BFD_RELOC_TILEGX_IMM16_X1_HW3_GOT,
2168 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_GOT,
2169 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_GOT,
2170 BFD_RELOC_TILEGX_IMM16_X0_HW1_TLS_GD,
2171 BFD_RELOC_TILEGX_IMM16_X1_HW1_TLS_GD,
2172 BFD_RELOC_TILEGX_IMM16_X0_HW2_TLS_GD,
2173 BFD_RELOC_TILEGX_IMM16_X1_HW2_TLS_GD,
2174 BFD_RELOC_TILEGX_IMM16_X0_HW3_TLS_GD,
2175 BFD_RELOC_TILEGX_IMM16_X1_HW3_TLS_GD,
2176 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_TLS_GD,
2177 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_TLS_GD,
2178 BFD_RELOC_TILEGX_IMM16_X0_HW1_TLS_IE,
2179 BFD_RELOC_TILEGX_IMM16_X1_HW1_TLS_IE,
2180 BFD_RELOC_TILEGX_IMM16_X0_HW2_TLS_IE,
2181 BFD_RELOC_TILEGX_IMM16_X1_HW2_TLS_IE,
2182 BFD_RELOC_TILEGX_IMM16_X0_HW3_TLS_IE,
2183 BFD_RELOC_TILEGX_IMM16_X1_HW3_TLS_IE,
2184 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_TLS_IE,
2185 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_TLS_IE.
2186 * elf32-tilepro.c (tilepro_elf_howto_table): Update tilepro
2188 (tilepro_reloc_map): Ditto.
2189 (tilepro_info_to_howto_rela): Ditto.
2190 (reloc_to_create_func): Ditto.
2191 (tilepro_tls_translate_to_le): New.
2192 (tilepro_tls_translate_to_ie): New.
2193 (tilepro_elf_tls_transition): New.
2194 (tilepro_elf_check_relocs): Handle new tls relocations.
2195 (tilepro_elf_gc_sweep_hook): Ditto.
2196 (allocate_dynrelocs): Ditto.
2197 (tilepro_elf_relocate_section): Ditto.
2198 (tilepro_replace_insn): New.
2199 (insn_mask_X1): New.
2200 (insn_mask_X0_no_dest_no_srca): New
2201 (insn_mask_X1_no_dest_no_srca): New
2202 (insn_mask_Y0_no_dest_no_srca): New
2203 (insn_mask_Y1_no_dest_no_srca): New
2206 (insn_tls_le_move_X1): New
2207 (insn_tls_le_move_zero_X0X1): New
2208 (insn_tls_ie_lw_X1): New
2209 (insn_tls_ie_add_X0X1): New
2210 (insn_tls_ie_add_Y0Y1): New
2211 (insn_tls_gd_add_X0X1): New
2212 (insn_tls_gd_add_Y0Y1): New
2213 * elfxx-tilegx.c (tilegx_elf_howto_table): Update tilegx
2215 (tilegx_reloc_map): Ditto.
2216 (tilegx_info_to_howto_rela): Ditto.
2217 (reloc_to_create_func): Ditto.
2218 (tilegx_elf_link_hash_table): New field disable_le_transition.
2219 (tilegx_tls_translate_to_le): New.
2220 (tilegx_tls_translate_to_ie): New.
2221 (tilegx_elf_tls_transition): New.
2222 (tilegx_elf_check_relocs): Handle new tls relocations.
2223 (tilegx_elf_gc_sweep_hook): Ditto.
2224 (allocate_dynrelocs): Ditto.
2225 (tilegx_elf_relocate_section): Ditto.
2226 (tilegx_copy_bits): New.
2227 (tilegx_replace_insn): New.
2228 (insn_mask_X1): New.
2229 (insn_mask_X0_no_dest_no_srca): New.
2230 (insn_mask_X1_no_dest_no_srca): New.
2231 (insn_mask_Y0_no_dest_no_srca): New.
2232 (insn_mask_Y1_no_dest_no_srca): New.
2233 (insn_mask_X0_no_operand): New.
2234 (insn_mask_X1_no_operand): New.
2235 (insn_mask_Y0_no_operand): New.
2236 (insn_mask_Y1_no_operand): New.
2237 (insn_tls_ie_ld_X1): New.
2238 (insn_tls_ie_ld4s_X1): New.
2239 (insn_tls_ie_add_X0X1): New.
2240 (insn_tls_ie_add_Y0Y1): New.
2241 (insn_tls_ie_addx_X0X1): New.
2242 (insn_tls_ie_addx_Y0Y1): New.
2243 (insn_tls_gd_add_X0X1): New.
2244 (insn_tls_gd_add_Y0Y1): New.
2245 (insn_move_X0X1): New.
2246 (insn_move_Y0Y1): New.
2247 (insn_add_X0X1): New.
2248 (insn_add_Y0Y1): New.
2249 (insn_addx_X0X1): New.
2250 (insn_addx_Y0Y1): New.
2251 * libbfd.h: Regenerate.
2252 * bfd-in2.h: Regenerate.
2254 2012-02-25 Walter Lee <walt@tilera.com>
2256 * config.bfd (tilegx-*-*): rename little endian vector; add big
2258 (tilegxbe-*-*): New case.
2259 * configure.in (bfd_elf32_tilegx_vec): Rename...
2260 (bfd_elf32_tilegx_le_vec): ... to this.
2261 (bfd_elf32_tilegx_be_vec): New vector.
2262 (bfd_elf64_tilegx_vec): Rename...
2263 (bfd_elf64_tilegx_le_vec): ... to this.
2264 (bfd_elf64_tilegx_be_vec): New vector.
2265 * configure: Regenerate.
2266 * elf32-tilegx.c (TARGET_LITTLE_SYM): Rename.
2267 (TARGET_LITTLE_NAME): Ditto.
2268 (TARGET_BIG_SYM): Define.
2269 (TARGET_BIG_NAME): Define.
2270 * elf64-tilegx.c (TARGET_LITTLE_SYM): Rename.
2271 (TARGET_LITTLE_NAME): Ditto.
2272 (TARGET_BIG_SYM): Define.
2273 (TARGET_BIG_NAME): Define.
2274 * targets.c (bfd_elf32_tilegx_vec): Rename...
2275 (bfd_elf32_tilegx_le_vec): ... to this.
2276 (bfd_elf32_tilegx_be_vec): Declare.
2277 (bfd_elf64_tilegx_vec): Rename...
2278 (bfd_elf64_tilegx_le_vec): ... to this.
2279 (bfd_elf64_tilegx_be_vec): Declare.
2280 (_bfd_target_vector): Add / rename above vectors.
2281 * arctures.c (bfd_architecture): Define bfd_mach_tilegx32.
2282 * bfd-in2.h: Regenerate.
2283 * cpu-tilegx.c (bfd_tilegx32_arch): define.
2284 (bfd_tilegx_arch): link to bfd_tilegx32_arch.
2286 2012-02-24 Nick Clifton <nickc@redhat.com>
2289 * reloc.c (bfd_generic_get_relocated_section_contents): Issue an
2290 error message instead of aborting, when an outofrange reloc is
2293 2012-02-23 Iain Sandoe <idsandoe@googlemail.com>
2295 * mach-o.c (bfd_mach_o_swap_in_non_scattered_reloc): New.
2296 (bfd_mach_o_canonicalize_one_reloc): Swap non-scattered reloc
2297 bit-fields when target and host differ in endian-ness. When
2298 PAIRs are non-scattered find the 'symbol' from the preceding
2299 reloc. Add FIXME re. reloc symbols on section boundaries.
2300 (bfd_mach_o_swap_out_non_scattered_reloc): New.
2301 (bfd_mach_o_write_relocs): Use bfd_mach_o_encode_non_scattered_reloc.
2303 2012-02-17 Iain Sandoe <idsandoe@googlemail.com>
2305 * mach-o-i386.c (i386_howto_table): Add support for 16 bit
2307 (bfd_mach_o_i386_swap_reloc_in): Handle 16bit sect-diffs.
2308 (bfd_mach_o_i386_swap_reloc_out): Likewise.
2310 2012-02-17 Tristan Gingold <gingold@adacore.com>
2312 * reloc.c (BFD_RELOC_MACH_O_LOCAL_SECTDIFF):
2313 * libbfd.h: Regenerated.
2314 * bfd-in2.h: Likewise.
2315 * mach-o-i386.c (i386_howto_table): Include local sectdiff.
2316 (bfd_mach_o_i386_swap_reloc_in): Update for local sectdiff.
2317 (bfd_mach_o_i386_swap_reloc_out): Likewise.
2319 2012-02-17 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
2321 * elf32-s390.c (elf_s390_relocate_section): Support basr in the
2322 GD->LE and LD->LE optimizations.
2324 2012-02-16 Alan Modra <amodra@gmail.com>
2327 * elf32-rx.c (elf32_rx_relax_section): Correct width check.
2329 2012-02-13 Richard Henderson <rth@redhat.com>
2332 * linker.c (fix_syms): Force symbols outside any section into
2333 bfd_abs_section_ptr.
2335 2012-02-13 Alan Modra <amodra@gmail.com>
2337 * elf32-m68hc1x.c (elf32_m68hc11_merge_symbol_attribute): New function.
2338 * elf32-m68hc1x.h (elf32_m68hc11_merge_symbol_attribute): Declare.
2339 * elf32-m68hc11.c (elf_backend_merge_symbol_attribute): Define.
2340 * elf32-m68hc12.c (elf_backend_merge_symbol_attribute): Define.
2342 2012-02-11 Jan Kratochvil <jan.kratochvil@redhat.com>
2343 Nick Clifton <nickc@redhat.com>
2345 * oasys.c (oasys_write_header): Fix compilation warning on zero-sized
2348 2012-02-10 Iain Sandoe <idsandoe@googlemail.com>
2350 * mach-o.c (bfd_mach_o_build_seg_command): Count zerofill section
2351 vma additions in their logical, rather than physical order.
2353 2012-02-10 Iain Sandoe <idsandoe@googlemail.com>
2355 * mach-o.c (mach_o_section_name_xlat): Correct eh-frame section
2357 * mach-o-x86-64.c (text_section_names_xlat): New.
2358 (mach_o_x86_64_segsec_names_xlat): New.
2359 (bfd_mach_o_tgt_seg_table): Define to mach_o_x86_64_segsec_names_xlat.
2360 * mach-o-i386.c (text_section_names_xlat): Correct section parameters.
2362 2012-02-10 Tristan Gingold <gingold@adacore.com>
2364 * elfnn-ia64.c (elfNN_vms_object_p): Change comparison operator
2365 to avoid infinite loop. Add comments.
2367 2012-02-09 H.J. Lu <hongjiu.lu@intel.com>
2370 * cpu-i386.c (bfd_arch_i386_fill): Updated to support multi byte
2372 (bfd_arch_i386_short_nop_fill): New.
2373 (bfd_arch_i386_long_nop_fill): Likewise.
2374 Use bfd_arch_i386_short_nop_fill in 32bit bfd_arch_info
2375 initializers. Use bfd_arch_i386_long_nop_fill on 64bit
2376 bfd_arch_info initializers.
2378 * cpu-k1om.c (bfd_arch_i386_fill): Renamed to ...
2379 (bfd_arch_i386_short_nop_fill): This.
2380 Update bfd_arch_info initializers.
2381 * cpu-l1om.c: Likewise.
2383 2012-02-08 Alan Modra <amodra@gmail.com>
2385 * elflink.c (_bfd_elf_gc_mark_rsec): Mark weakdef syms too.
2386 (_bfd_elf_fix_symbol_flags): When a weakdef is def_regular, clear
2387 the correct h->u.weakdef.
2389 2012-02-07 Alan Modra <amodra@gmail.com>
2391 * elf.c (elf_find_function): Don't use internal_elf_sym.
2392 (_bfd_elf_maybe_function_sym): Likewise. Replace elf_symbol_type
2393 parameter with asymbol.
2394 * elf64-ppc.c (ppc64_elf_maybe_function_sym): Likewise.
2395 * elf-bfd.h (_bfd_elf_maybe_function_sym): Update prototype.
2396 (struct elf_backend_data <maybe_function_sym>): Likewise.
2398 2012-02-02 Vidya Praveen (vidya.praveen@atmel.com)
2401 * elf32-avr.c (elf32_avr_relax_section): Correct the
2402 condition that qualifies the candidates for relaxation.
2404 2012-02-02 Tristan Gingold <gingold@adacore.com>
2406 * bfdio.c (real_fopen): Remove unused vms_modes variable.
2408 2012-02-02 Tristan Gingold <gingold@adacore.com>
2410 * mach-o.c (bfd_mach_o_read_header): Silent uninitialized
2413 2012-02-02 Tristan Gingold <gingold@adacore.com>
2415 * archive.c (bfd_slurp_armap): Fix thinko in cast.
2417 2012-01-31 H.J. Lu <hongjiu.lu@intel.com>
2420 * archures.c (bfd_arch_info): Add fill.
2421 (bfd_default_arch_struct): Add bfd_arch_default_fill.
2422 (bfd_arch_default_fill): New.
2424 * configure.in: Set bfd version to 2.22.52.
2425 * configure: Regenerated.
2427 * cpu-alpha.c: Add bfd_arch_default_fill to bfd_arch_info
2429 * cpu-arc.c: Likewise.
2430 * cpu-arm.c: Likewise.
2431 * cpu-avr.c: Likewise.
2432 * cpu-bfin.c: Likewise.
2433 * cpu-cr16.c: Likewise.
2434 * cpu-cr16c.c: Likewise.
2435 * cpu-cris.c: Likewise.
2436 * cpu-crx.c: Likewise.
2437 * cpu-d10v.c: Likewise.
2438 * cpu-d30v.c: Likewise.
2439 * cpu-dlx.c: Likewise.
2440 * cpu-epiphany.c: Likewise.
2441 * cpu-fr30.c: Likewise.
2442 * cpu-frv.c: Likewise.
2443 * cpu-h8300.c: Likewise.
2444 * cpu-h8500.c: Likewise.
2445 * cpu-hppa.c: Likewise.
2446 * cpu-i370.c: Likewise.
2447 * cpu-i860.c: Likewise.
2448 * cpu-i960.c: Likewise.
2449 * cpu-ia64.c: Likewise.
2450 * cpu-ip2k.c: Likewise.
2451 * cpu-iq2000.c: Likewise.
2452 * cpu-lm32.c: Likewise.
2453 * cpu-m10200.c: Likewise.
2454 * cpu-m10300.c: Likewise.
2455 * cpu-m32c.c: Likewise.
2456 * cpu-m32r.c: Likewise.
2457 * cpu-m68hc11.c: Likewise.
2458 * cpu-m68hc12.c: Likewise.
2459 * cpu-m68k.c: Likewise.
2460 * cpu-m88k.c: Likewise.
2461 * cpu-mcore.c: Likewise.
2462 * cpu-mep.c: Likewise.
2463 * cpu-microblaze.c: Likewise.
2464 * cpu-mips.c: Likewise.
2465 * cpu-mmix.c: Likewise.
2466 * cpu-moxie.c: Likewise.
2467 * cpu-msp430.c: Likewise.
2468 * cpu-mt.c: Likewise.
2469 * cpu-ns32k.c: Likewise.
2470 * cpu-openrisc.c: Likewise.
2471 * cpu-or32.c: Likewise.
2472 * cpu-pdp11.c: Likewise.
2473 * cpu-pj.c: Likewise.
2474 * cpu-plugin.c: Likewise.
2475 * cpu-powerpc.c: Likewise.
2476 * cpu-rl78.c: Likewise.
2477 * cpu-rs6000.c: Likewise.
2478 * cpu-rx.c: Likewise.
2479 * cpu-s390.c: Likewise.
2480 * cpu-score.c: Likewise.
2481 * cpu-sh.c: Likewise.
2482 * cpu-sparc.c: Likewise.
2483 * cpu-spu.c: Likewise.
2484 * cpu-tic30.c: Likewise.
2485 * cpu-tic4x.c: Likewise.
2486 * cpu-tic54x.c: Likewise.
2487 * cpu-tic6x.c: Likewise.
2488 * cpu-tic80.c: Likewise.
2489 * cpu-tilegx.c: Likewise.
2490 * cpu-tilepro.c: Likewise.
2491 * cpu-v850.c: Likewise.
2492 * cpu-vax.c: Likewise.
2493 * cpu-w65.c: Likewise.
2494 * cpu-we32k.c: Likewise.
2495 * cpu-xc16x.c: Likewise.
2496 * cpu-xstormy16.c: Likewise.
2497 * cpu-xtensa.c: Likewise.
2498 * cpu-z80.c: Likewise.
2499 * cpu-z8k.c: Likewise.
2501 * cpu-i386.c: Include "libiberty.h".
2502 (bfd_arch_i386_fill): New.
2503 Add bfd_arch_i386_fill to bfd_arch_info initializer.
2505 * cpu-k1om.c: Add bfd_arch_i386_fill to bfd_arch_info initializer.
2506 * cpu-l1om.c: Likewise.
2508 * linker.c (default_data_link_order): Call abfd->arch_info->fill
2511 * bfd-in2.h: Regenerated.
2513 2012-01-27 Michael Eager <eager@eagercon.com>
2515 * elf32-microblaze.c (create_got_section):
2516 Reuse existing .rela.got section.
2518 2012-01-23 Alan Modra <amodra@gmail.com>
2520 * elf-bfd.h: Formatting.
2521 (struct elf_backend_data): Add "maybe_function_sym".
2522 (_bfd_elf_maybe_function_sym): Declare.
2523 * elfxx-target.h (elf_backend_maybe_function_sym): Define.
2524 (elfNN_bed): Init new field.
2525 * elf.c (elf_find_function): Use maybe_function_sym.
2526 (_bfd_elf_maybe_function_sym): New function.
2527 * elf64-ppc.c (elf_backend_maybe_function_sym): Define.
2528 (ppc64_elf_maybe_function_sym): New function.
2530 2012-01-20 Francois Gouget <fgouget@codeweavers.com>
2533 * archive.c (_bfd_ar_sizepad): New function. Correctly install and
2534 pad the size field in an archive header.
2535 (_bfd_generic_read_ar_hdr_mag): Use the correct type and scan
2536 function for the archive size field.
2537 (bfd_generic_openr_next_archived_file): Likewise.
2538 (do_slurp_coff_armap): Likewise.
2539 (_bfd_write_archive_contents): Likewise.
2540 (_bfd_bsd44_write_ar_hdr): Use the new function.
2541 (bfd_ar_hdr_from_filesystem): Likewise.
2542 (_bfd_write_archive_contents): Likewise.
2543 (bsd_write_armap): Likewise.
2544 (coff_write_armap): Likewise.
2545 * archive64.c (bfd_elf64_archive_write_armap): Likewise.
2546 * bfdio.c (bfd_bread): Use correct type for archive element
2548 * ar.c (open_inarch): Likewise.
2549 (extract_file): Likewise.
2550 * libbfd-in.h (struct areltdata): Use correct types for
2551 parsed_size and extra_size fields.
2552 Prototype _bfd_ar_sizepad function.
2553 * libbfd.h: Regenerate.
2555 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
2557 * elf.c (elfcore_write_prpsinfo): Provide unconditionally.
2558 Return NULL if core file generation is unsupported.
2559 (elfcore_write_prstatus): Likewise.
2560 * elf32-arm.c (elf32_arm_nabi_write_core_note): New function.
2561 (elf_backend_write_core_note): Define.
2563 2012-01-19 Tristan Gingold <gingold@adacore.com>
2565 * pef.c: Add a comment.
2568 2012-01-17 Alan Modra <amodra@gmail.com>
2570 * elf32-ppc.c (ppc_elf_write_core_note <NT_PRPSINFO>): Don't leave
2571 trailing garbage in the note.
2572 * elf64-ppc.c (ppc64_elf_write_core_note <NT_PRPSINFO>): Likewise.
2574 2012-01-16 Daniel Green <venix1@gmail.com>
2577 * coff-i386.c (coff_i386_rtype_to_howto <R_SECREL32>): Test
2578 h->root.type not h->type.
2579 * coff-x86_64.c (coff_amd64_rtype_to_howto <R_AMD64_SECREL>): Likewise.
2581 2012-01-13 Iain Sandoe <idsandoe@googlemail.com>
2583 * mach-o.c (bfd_mach_o_build_dysymtab_command): Handle absolute
2586 2012-01-13 Iain Sandoe <idsandoe@googlemail.com>
2588 * mach-o.c (bfd_mach_o_write_relocs): Move computation of relocs file
2589 position from here... to (bfd_mach_o_build_seg_command): Here.
2591 2012-01-12 Iain Sandoe <idsandoe@googlemail.com>
2593 * mach-o.c (bfd_mach_o_count_indirect_symbols): New.
2594 (bfd_mach_o_build_dysymtab_command): Populate indirect symbol table.
2595 * mach-o.h (bfd_mach_o_asymbol): Move declaration to start of the
2596 file. (bfd_mach_o_section): Add indirect_syms field.
2598 2012-01-11 Iain Sandoe <idsandoe@googlemail.com>
2600 * mach-o.c (bfd_mach_o_build_seg_command): Separate computation of
2601 vmsize from filesize. Don't compute offsets or file sizes for
2604 2012-01-11 Iain Sandoe <idsandoe@googlemail.com>
2606 * mach-o.c (bfd_mach_o_build_commands): Make the building of each
2607 command type independent.
2609 2012-01-11 Alan Modra <amodra@gmail.com>
2611 * elf64-ppc.c: Define more insns used in plt call stubs.
2612 (ppc64_elf_brtaken_reloc): Assume isa version 2 or above.
2613 (ppc64_elf_relocate_section): Likewise.
2614 (enum ppc_stub_type): Add ppc_stub_plt_call_r2save.
2615 (struct ppc_link_hash_table): Increase size of stub_count array.
2616 Add plt_stub_align and plt_thread_safe.
2617 (ALWAYS_USE_FAKE_DEP, ALWAYS_EMIT_R2SAVE): Define.
2618 (plt_stub_size, plt_stub_pad): New functions.
2619 (build_plt_stub): Emit barriers for power7 thread safety. Don't
2620 emit needless save of r2.
2621 (build_tls_get_addr_stub): Adjust params.
2622 (ppc_build_one_stub): Handle ppc_stub_plt_call_r2save and aligning
2623 plt stubs. Adjust build_*plt_stub calls.
2624 (ppc_size_one_stub): Similarly.
2625 (ppc64_elf_size_stubs): Accept plt_thread_safe and plt_stub_align
2626 params. Choose default for plt_thread_safe based on existence of
2627 calls to thread creation functions. Modify plt_call to
2628 plt_call_r2save when no tocsave reloc found. Align tail of stub
2630 (ppc64_elf_build_stubs): Align tail of stub sections. Adjust
2631 output of stub statistics.
2632 (ppc64_elf_relocate_section): Handle ppc_stub_plt_call_r2save.
2633 * elf64-ppc.h (ppc64_elf_size_stubs): Update prototype.
2635 2012-01-10 H.J. Lu <hongjiu.lu@intel.com>
2638 * elf64-x86-64.c (elf_x86_64_relocate_section): Remove ABI_64_P
2639 check on R_X86_64_PCXX.
2641 2012-01-10 Tristan Gingold <gingold@adacore.com>
2643 * mach-o.c (bfd_mach_o_build_commands): Avoid uninitialized false
2646 2012-01-10 Tristan Gingold <gingold@adacore.com>
2648 * bfdio.c (bfd_tell): Handle nested archives.
2650 * cache.c (bfd_cache_lookup_worker): Ditto.
2651 * archive.c (_bfd_get_elt_at_filepos): Remove code dealing with
2653 (bfd_generic_openr_next_archived_file): Likewise.
2655 2012-01-09 Iain Sandoe <idsandoe@googlemail.com>
2657 * mach-o.c (bfd_mach_o_bfd_copy_private_symbol_data): Implement.
2658 (bfd_mach_o_write_symtab): Remove handling for indirect syms.
2659 (bfd_mach_o_primary_symbol_sort_key): Likewise.
2660 (bfd_mach_o_cf_symbols): Likewise.
2661 (bfd_mach_o_sort_symbol_table): Remove.
2662 (bfd_mach_o_mangle_symbols): Adjust arguments, remove handling
2663 for indirect and dysymtab counts. Do the symbol sorting here.
2664 (bfd_mach_o_build_dysymtab_command): Count the symbol types here.
2665 Make the indirect symbols a TODO.
2666 (bfd_mach_o_build_commands): Adjust call to bfd_mach_o_mangle_symbols.
2667 (bfd_mach_o_make_empty_symbol): Specifically flag unset symbols with
2669 (bfd_mach_o_read_symtab_symbol): Record the symbol index.
2670 (bfd_mach_o_read_symtab_symbol): Adjust recording of global status.
2671 * mach-o.h (mach_o_data_struct): Remove indirect and dysymtab entries.
2672 (IS_MACHO_INDIRECT): Remove.
2673 (SYM_MACHO_FIELDS_UNSET, SYM_MACHO_FIELDS_NOT_VALIDATED): New.
2675 2012-01-06 Nick Clifton <nickc@redhat.com>
2678 * reloc.c (bfd_generic_lookup_section_flags): Rename 'finfo' to
2679 'flaginfo' to avoid conflicts with AIX system headers.
2681 2012-01-06 Tristan Gingold <gingold@adacore.com>
2683 * bfdio.c (bfd_bread): Use arelt_size macro.
2685 2012-01-06 Tristan Gingold <gingold@adacore.com>
2687 * config.bfd (i[3-7]86-*-darwin*): Define targ64_selvecs.
2689 2012-01-05 Nick Clifton <nickc@redhat.com>
2692 * elf32-avr.c (elf32_avr_relax_delete_bytes): Read in relocs if
2695 2012-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
2697 Fix zero registers core files when built by gcc-4.7.
2698 * elf64-x86-64.c (elf_x86_64_write_core_note): Remove variables p and
2699 size. Call elfcore_write_note for the local variables. Remove the
2700 final elfcore_write_note call. Add NOTREACHED comments.
2702 2012-01-04 Tristan Gingold <gingold@adacore.com>
2704 * mach-o.c (bfd_mach_o_fat_stat_arch_elt): New function.
2705 (bfd_mach_o_generic_stat_arch_elt): Adjust.
2707 2012-01-04 Tristan Gingold <gingold@adacore.com>
2709 * mach-o.c (bfd_mach_o_fat_member_init): New function.
2710 (bfd_mach_o_openr_next_archived_file): Reindent.
2711 Adjust to call bfd_mach_o_fat_member_init.
2712 (bfd_mach_o_fat_extract): Adjust to call bfd_mach_o_fat_member_init.
2714 2012-01-04 Tristan Gingold <gingold@adacore.com>
2716 * mach-o-x86-64.c (bfd_mach_o_x86_64_swap_reloc_out): Handle
2717 BFD_RELOC_32, BFD_RELOC_MACH_O_X86_64_PCREL32_1,
2718 BFD_RELOC_MACH_O_X86_64_PCREL32_2,
2719 BFD_RELOC_MACH_O_X86_64_PCREL32_4,
2720 BFD_RELOC_MACH_O_X86_64_BRANCH32,
2721 BFD_RELOC_MACH_O_X86_64_SUBTRACTOR32,
2722 BFD_RELOC_MACH_O_X86_64_GOT.
2724 2012-01-04 Tristan Gingold <gingold@adacore.com>
2726 * mach-o.h (bfd_mach_o_fvmlib_command): New structure.
2727 (bfd_mach_o_load_command): Add fvmlib field.
2729 * mach-o.c (bfd_mach_o_read_fvmlib): New function.
2730 (bfd_mach_o_read_command): Handle fvmlib.
2732 2012-01-04 Tristan Gingold <gingold@adacore.com>
2734 * mach-o.c (bfd_mach_o_convert_architecture): Reindent.
2735 Decode msubtype for ARM.
2737 2012-01-04 Tristan Gingold <gingold@adacore.com>
2739 * mach-o.c (bfd_mach_o_get_synthetic_symtab): Add comments.
2741 2012-01-04 Tristan Gingold <gingold@adacore.com>
2743 * mach-o.h: Reindent header.
2744 (bfd_mach_o_encryption_info_command): New structure.
2745 (bfd_mach_o_load_command): Add encryption_info field.
2747 * mach-o.c (bfd_mach_o_read_encryption_info): New function.
2748 (bfd_mach_o_read_command): Handle BFD_MACH_O_LC_ENCRYPTION_INFO.
2749 (bfd_mach_o_read_command): Adjust error message.
2751 2012-01-04 Shinichiro Hamaji <shinichiro.hamaji@gmail.com>
2753 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Factor out the part
2754 which reads DWARF2 and stores in stash from find_line.
2755 (find_line) Call _bfd_dwarf2_slurp_debug_info.
2756 * libbfd-in.h (_bfd_dwarf2_slurp_debug_info): Add declaration.
2757 * libbfd.h (_bfd_dwarf2_slurp_debug_info): Regenerate.
2758 * mach-o.c (dsym_subdir): The name of subdir where debug
2759 information may be stored.
2760 (bfd_mach_o_lookup_uuid_command): New. Lookup a load command whose
2762 (bfd_mach_o_dsym_for_uuid_p): New. Check if the specified BFD is
2763 corresponding to the executable.
2764 (bfd_mach_o_find_dsym): New. Find a debug information BFD in the
2765 specified binary file.
2766 (bfd_mach_o_follow_dsym): New. Find a debug information BFD for
2768 (bfd_mach_o_find_nearest_line): Check dSYM files for Mach-O
2769 executables, dylibs, and bundles.
2770 (bfd_mach_o_close_and_cleanup): Clean up BFDs for the dSYM file.
2771 * mach-o.h (dsym_bfd): The BFD of the dSYM file.
2773 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
2775 * mach-o.c (bfd_mach_o_mangle_symbols): Put in the section index
2777 (bfd_mach_o_primary_symbol_sort_key): Adjust for stabs.
2778 (bfd_mach_o_cf_symbols): Likewise.
2780 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
2782 * mach-o.c (bfd_mach_o_mangle_symbols): Correct typo.
2784 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
2786 * mach-o.c (bfd_mach_o_write_symtab): Fill in the string table index
2787 as the value of an indirect symbol. Keep the string table index in
2788 non-indirect syms for reference.
2789 (bfd_mach_o_write_dysymtab): New.
2790 (bfd_mach_o_primary_symbol_sort_key): New.
2791 (bfd_mach_o_cf_symbols): New.
2792 (bfd_mach_o_sort_symbol_table): New.
2793 (bfd_mach_o_mangle_symbols): Return early if no symbols. Sort symbols.
2794 If we are emitting a dysymtab, process indirect symbols and count the
2795 number of each other kind.
2796 (bfd_mach_o_mangle_sections): New.
2797 (bfd_mach_o_write_contents): Split out some pre-requisite code into
2798 the command builder. Write dysymtab if the command is present.
2799 (bfd_mach_o_count_sections_for_seg): New.
2800 (bfd_mach_o_build_seg_command): New.
2801 (bfd_mach_o_build_dysymtab_command): New.
2802 (bfd_mach_o_build_commands): Reorganize to support the fact that some
2803 commands are optional and should not be emitted if there are no
2804 sections or symbols.
2805 (bfd_mach_o_set_section_contents): Amend comment.
2806 * mach-o.h: Amend and add to comments.
2807 (mach_o_data_struct): Add fields for dysymtab symbols counts and a
2808 pointer to the indirects, when present.
2809 (bfd_mach_o_should_emit_dysymtab): New macro.
2810 (IS_MACHO_INDIRECT): Likewise.
2812 For older changes see ChangeLog-2011
2818 version-control: never