binutils/
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
5baf5e34
SE
12013-09-17 Doug Gilmore <Doug.Gilmore@imgtec.com>
2
3 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): Handle
4 EF_MIPS_FP64.
5
29bff3ea
DA
62013-08-31 John David Anglin <dave.anglin@bell.net>
7
8 * elf64-hppa.c (elf_hppa_final_link_relocate): Add missing '%' to
9 format string.
10
5c98a14e
JJ
112013-08-29 Jakub Jelinek <jakub@redhat.com>
12
13 * elf64-x86-64.c (elf_x86_64_check_tls_transition): Allow
14 64-bit -mcmodel=large -fpic TLS GD and LD sequences.
15 (elf_x86_64_relocate_section): Handle -mcmodel=large -fpic
16 TLS GD and LD sequences in GD->LE, GD->IE and LD->LE transitions.
17
e5034e59
AM
182013-08-27 Alan Modra <amodra@gmail.com>
19
20 * elf-bfd.h (struct elf_backend_data): Remove as_needed_cleanup.
21 Add notice_as_needed.
22 * elf64-ppc.c (elf_backend_as_needed_cleanup): Don't define.
23 (elf_backend_notice_as_needed): Define.
24 (ppc64_elf_as_needed_cleanup): Rename and adjust..
25 (ppc64_elf_notice_as_needed): ..to this.
26 * elflink.c (_bfd_elf_notice_as_needed): New function, extracted..
27 (elf_link_add_object_symbols): ..from here.
28 * elfxx-target.h (elf_backend_as_needed_cleanup): Don't define.
29 (elf_backend_notice_as_needed): Define..
30 (elfNN_bed): ..and use here.
31
1098fd41
RM
322013-08-26 Roland McGrath <mcgrathr@google.com>
33
34 * archures.c (bfd_mach_i386_nacl, bfd_mach_i386_i386_nacl): New macros.
35 (bfd_mach_x86_64_nacl, bfd_mach_x64_32_nacl): New macros.
36 * cpu-i386.c (bfd_arch_i386_onebyte_nop_fill): New function.
37 (bfd_i386_nacl_arch): New variable.
38 (bfd_x86_64_nacl_arch, bfd_x64_32_nacl_arch): New variables.
39 (bfd_x64_32_arch_intel_syntax): Link them into the list.
40 * bfd-in2.h: Regenerate.
41
887badb3
RM
422013-08-26 Roland McGrath <mcgrathr@google.com>
43
44 * elf-nacl.c (nacl_modify_segment_map): Fix logic reordering the
45 elf_segment_map list. If an executable segment is page-aligned
46 but does not end with a full page, then append a fake section into
47 the segment map entry that pads out the page.
48 (nacl_final_write_processing): New function. Write the code fill
49 laid out in nacl_modify_segment_map.
50 * elf-nacl.h: Declare it.
51 * elf32-arm.c (elf32_arm_nacl_final_write_processing): New function.
52 (elf_backend_final_write_processing): Define it for NaCl backend.
53 * elf32-i386.c (elf_backend_final_write_processing): Likewise.
54 * elf64-x86-64.c (elf_backend_final_write_processing): Likewise.
55
56 * elf-nacl.c (segment_eligible_for_headers): Rename MAXPAGESIZE
57 parameter to MINPAGESIZE.
58 (nacl_modify_segment_map): Use minpagesize instead of maxpagesize.
59
60 * elf32-arm.c (ELF_MINPAGESIZE, ELF_COMMONPAGESIZE): #undef for NaCl.
61
387f8054
MR
622013-08-24 Maciej W. Rozycki <macro@linux-mips.org>
63
64 * elf32-tilepro.c (tilepro_elf_finish_dynamic_sections): Don't
65 set GOT's entry size if there is no ELF section data.
66 * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
67 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_sections):
68 Likewise.
69
f8222080
L
702013-08-23 H.J. Lu <hongjiu.lu@intel.com>
71
72 * elf64-x86-64.c (get_elf_x86_64_arch_data): New.
73 (get_elf_x86_64_backend_data): Use it.
74 (elf_x86_64_size_dynamic_sections): Likewise.
75
9aff4b7a
NC
762013-08-23 Yuri Chornoivan <yurchor@ukr.net>
77
78 PR binutils/15834
79 * bfdio.c: Fix typos.
80 * elf32-spu.c: Likewise.
81 * elfnn-aarch64.c: Likewise.
82
2eea2440
TG
832013-08-21 Tristan Gingold <gingold@adacore.com>
84
85 * coff-rs6000.c (_bfd_xcoff_sizeof_headers): Also count
86 .ovrflo sections.
87 * coffcode.h (coff_compute_section_file_positions): Force
88 match between file offset and vma offset.
89
934bce08
AM
902013-08-21 Alan Modra <amodra@gmail.com>
91
92 * elflink.c (_bfd_elf_merge_symbol): Set *poldbfd, *poldweak,
93 and *poldalignment before exiting when !relocs_compatible.
94
00b7642b
AM
952013-08-21 Alan Modra <amodra@gmail.com>
96
97 * elflink.c (_bfd_elf_define_linkage_sym): Don't set STV_INTERNAL
98 symbols to STV_HIDDEN.
99
62c34db3
NC
1002013-08-14 John Tytgat <john@bass-software.com>
101
102 PR ld/15787
103 * elf32-arm.c (elf32_arm_final_link_relocate): Use origin of output
104 segment containing the relocating symbol instead of assuming 0 for
105 sb group relocations.
106
4046d87a
NC
1072013-08-09 Nick Clifton <nickc@redhat.com>
108
109 * elf32-rl78.c (rl78_elf_merge_private_bfd_data): Complain if G10
110 flag bits do not match.
111 (rl78_elf_print_private_bfd_data): Describe G10 flag.
112
13896403
RS
1132013-08-05 John Tytgat <john@bass-software.com>
114
115 * po/BLD-POTFILES.in: Regenerate.
116 * po/SRC-POTFILES.in: Likewise.
117
31a91d61
NC
1182013-07-31 John Tytgat <john@bass-software.com>
119
120 PR ld/15787
121 * elf32-arm.c (elf32_arm_final_link_relocate): Base SB on the
122 output section VMA.
123
a505d7ac
MR
1242013-07-28 Maciej W. Rozycki <macro@linux-mips.org>
125
126 * elf64-hppa.c (elf64_hppa_finish_dynamic_sections)
127 <DT_HP_LOAD_MAP>: Return unsuccessfully if there's no `.data'
128 section.
129
0608afa7
AP
1302013-07-27 Andrew Pinski <apinski@cavium.com>
131
132 * elfnn-aarch64.c (elfNN_aarch64_check_relocs):
133 Use the correct alignment for
134 _bfd_elf_make_dynamic_reloc_section for ILP32.
135
54757ed1
AP
1362013-07-27 Andrew Pinski <apinski@cavium.com>
137
138 * elfnn-aarch64.c (elfNN_aarch64_howto_from_bfd_reloc): Handle
139 BFD_RELOC_AARCH64_NONE explicitly.
140
f6518c48
MR
1412013-07-27 Maciej W. Rozycki <macro@linux-mips.org>
142
143 * elf32-vax.c (elf_vax_finish_dynamic_sections): Don't set GOT's
144 entry size if there is no ELF section data.
145
125b5bac
MR
1462013-07-27 Maciej W. Rozycki <macro@linux-mips.org>
147
148 * elf32-vax.c (elf_vax_check_relocs) <R_VAX_GOT32, R_VAX_PLT32>:
149 Don't check symbol visibility here. Remove a check already
150 asserted for.
151 (elf_vax_instantiate_got_entries): Use SYMBOL_REFERENCES_LOCAL
152 instead of individual checks.
153 (elf_vax_relocate_section) <R_VAX_GOT32, R_VAX_PLT32>: Only
154 check the offset to decide if produce a GOT or PLT entry.
155 Remove redundant assertions. Remove code to produce GOT entries
156 for local symbols. Remove a duplicate comment and add a comment
157 on GOT relocations.
158 (elf_vax_finish_dynamic_symbol): Remove code to produce RELATIVE
159 dynamic relocs.
160
49d01bf6
MR
1612013-07-27 Maciej W. Rozycki <macro@linux-mips.org>
162
163 * elf32-vax.c (elf_vax_always_size_sections): Correct a comment
164 typo.
165
fac3d241
MR
1662013-07-27 Maciej W. Rozycki <macro@linux-mips.org>
167
168 * elf32-vax.c (elf_vax_discard_got_entries): New function.
169 (elf_vax_always_size_sections): Likewise.
170 (elf_vax_size_dynamic_sections): Remove code moved to
171 elf_vax_always_size_sections. Make comment on
172 elf_vax_instantiate_got_entries match reality.
173 (elf_vax_instantiate_got_entries): Assert that rather than check
174 if dynobj is null. Don't check for dynamic_sections_created.
175 Make function description match reality.
176 (elf_backend_always_size_sections): New macro.
177
729eabd5
AM
1782013-07-25 Alan Modra <amodra@gmail.com>
179
180 * elf64-ppc.c (struct ppc64_elf_obj_tdata): Replace opd_relocs
181 with a union.
182 (opd_entry_value): Cache .opd section contents.
183 (ppc64_elf_relocate_section): Adjust.
184
db6a5d5f
AM
1852013-07-25 Alan Modra <amodra@gmail.com>
186
187 PR ld/15762
188 PR ld/12761
189 * elflink.c (elf_link_add_object_symbols): Correct test in
190 last patch. Remove unnecessary code.
191
7fa9fcb6
TG
1922013-07-24 Tristan Gingold <gingold@adacore.com>
193
194 * coff-rs6000.c (xcoff_howto_table): Fix masks and pc_relative for
195 R_RBR. Add numbers in comments.
196 (_bfd_xcoff_reloc_type_lookup): Handle BFD_RELOC_PPC_B16.
197 * coff64-rs6000.c: Likewise.
198
436e1eba
AM
1992013-07-20 Alan Modra <amodra@gmail.com>
200
201 PR ld/15762
202 PR ld/12761
203 * elflink.c (elf_link_add_object_symbols): Don't clobber
204 .gnu.warning.symbol sections when shared.
205
ee181c72
NC
2062013-07-19 Nick Clifton <nickc@redhat.com>
207
208 * elf32-rx.c (rx_elf_relocate_section): Fix typo: move
209 saw_subtract from R_RX_OPdiv to R_RX_OPneg.
210
df301bfc
NC
2112013-07-18 Travis Snoozy <quandary@remstate.com>
212
213 PR ld/15721
214 * elf32-msp430.c (R_MSP430_10_PCREL): Use 10-bit source and
215 destination masks.
216 * R_MSP430_2X_PCREL: Likewise.
217 * R_MSP430X_10_PCREL: Likewise.
218 * R_MSP430X_2X_PCREL: Likewise.
219
39f21624
NC
2202013-07-18 Terry Guo <terry.guo@arm.com>
221
00b7642b 222 * elf32-arm.c (arm_type_of_stub): Don't use ST_BRANCH_TO_ARM for
39f21624 223 thumb only targets.
00b7642b 224 (elf32_arm_final_link_relocate): Likewise.
39f21624 225
671a6cbe
NC
2262013-07-18 Bill Neubauer <wcn@google.com>
227
228 * mach-o.c (mach_o_section_name_xlat dw): Add entry for
229 .debug_gdb_scripts
230
7a89b94e
NC
2312013-07-18 Roland McGrath <mcgrathr@google.com>
232
233 * elf32-arm.c (elf32_arm_stub_long_branch_arm_nacl): New variable.
234 (elf32_arm_stub_long_branch_arm_nacl_pic): New variable.
235 (arm_build_one_stub): Increase MAXRELOCS to 3.
236 (arm_type_of_stub): Use them if GLOBALS->nacl_p.
237 (struct elf32_arm_link_hash_table): Give add_stub_section member's
238 pointee type a third argument.
239 (elf32_arm_create_or_find_stub_sec): Update caller.
240 (elf32_arm_size_stubs): Update argument type.
241 * bfd-in.h (elf32_arm_size_stubs): Update decl.
242 * bfd-in2.h: Regenerate.
243 * libbfd.h: Regenerate.
244
d929bc19
MR
2452013-07-15 Maciej W. Rozycki <macro@codesourcery.com>
246
247 * elfxx-mips.c (mips_elf_merge_obj_attributes): Replace hardcoded
248 magic numbers with enum values.
249
7e11d300
RM
2502013-07-12 Roland McGrath <mcgrathr@google.com>
251
252 * reloc.c: Add BFD_RELOC_390_PC12DBL, BFD_RELOC_390_PLT12DBL,
253 BFD_RELOC_390_PC24DBL, BFD_RELOC_390_PLT24DBL (should have
254 been added here with 2013-07-05 elf32-s390.c change).
255 * bfd-in2.h: Regenerate (no-op).
256 * libbfd.h: Regenerate (no-op).
257
ba92f887
MR
2582013-07-12 Maciej W. Rozycki <macro@codesourcery.com>
259
260 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Handle
261 EF_MIPS_NAN2008.
262 (_bfd_mips_elf_print_private_bfd_data): Likewise.
263
53452371
TG
2642013-07-09 Tristan Gingold <gingold@adacore.com>
265
266 * vms-alpha.c (struct vms_private_data_struct): Remove
267 flag_hash_long_names and flag_show_after_trunc.
268 (hash_string): Remove.
269 (_bfd_vms_length_hash_symbol): Remove.
270 (alpha_vms_write_exec): Remove call to _bfd_vms_length_hash_symbol.
271 (_bfd_vms_write_egsd): Likewise. Rewrite condition.
272 (_bfd_vms_write_ehdr): Remove code that set removed flags.
273 (_bfd_vms_write_etir): Remove call to _bfd_vms_length_hash_symbol.
274 (vms_bfd_is_local_label_name): Remove trace call.
275
787548c8
TG
2762013-07-09 Tristan Gingold <gingold@adacore.com>
277
278 * hosts/alphavms.h: Include config.h and ansidecl.h, remove useless
279 macros.
280 * configure.com: Adjust to match changes in configure.
281 * makefile.vms (OBJS): Update list.
282
2d63fb6c
TG
2832013-07-05 Tristan Gingold <gingold@adacore.com>
284
285 * coffcode.h (coff_write_object_contents): Use ".ovrflo" name for
286 overflow sections.
287
fb798c50
AK
2882013-07-05 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
289
290 * elf32-s390.c: Add new relocation definitions R_390_PC12DBL,
291 R_390_PLT12DBL, R_390_PC24DBL, and R_390_PLT24DBL.
292 (elf_s390_reloc_type_lookup, elf_s390_check_relocs)
293 (elf_s390_gc_sweep_hook, elf_s390_relocate_section): Support new
294 relocations.
295 * elf64-s390.c: See elf32-s390.c
296 * bfd-in2.h: Add new relocs to enum bfd_reloc_code_real.
297 * libbfd.h: Add new reloc strings.
298
7bcccb57
MS
2992013-07-03 Marcus Shawcroft <marcus.shawcroft@arm.com>
300
301 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Reorder case
302 values.
303 (elfNN_aarch64_relocate_section): Likewise.
304 (elfNN_aarch64_gc_sweep_hook): Likewise.
305 (elfNN_aarch64_check_relocs): Likewise.
306
5295321c
AM
3072013-07-03 Alan Modra <amodra@gmail.com>
308
309 * elf64-ppc.c (ppc64_elf_func_desc_adjust): Don't hide .TOC.
310 when relocatable. Don't change root.type or type here.
311 (ppc64_elf_set_toc): Set type of .TOC. to STT_OBJECT.
312
ba8ca3e7
AM
3132013-07-03 Alan Modra <amodra@gmail.com>
314
315 * elf64-ppc.c (struct ppc_stub_hash_entry): Delete "addend".
316 (ppc64_elf_size_stubs): Don't set "addend".
317 (ppc64_elf_relocate_section): Don't allow calls via
318 toc-adjusting stubs without a following nop even in an
319 executable, except for self-calls and both libc_start_main
320 and .libc_start_main.
321
c66bb0ee
AM
3222013-07-03 Alan Modra <amodra@gmail.com>
323
324 * elf64-ppc.c (ppc64_elf_func_desc_adjust): Hide ".TOC.".
325
d5be367d
TG
3262013-07-02 Tristan Gingold <gingold@adacore.com>
327
328 * coff-rs6000.c (xcoff_find_nearest_line_discriminator): Add missing
329 line.
330
9a1ada6c
TG
3312013-07-02 Tristan Gingold <gingold@adacore.com>
332
b1a49096
TG
333 * vms-alpha.c (_bfd_generic_find_nearest_line_discriminator): Define.
334 (_bfd_vms_find_nearest_line_discriminator): New function.
335
3362013-07-02 Tristan Gingold <gingold@adacore.com>
c66bb0ee 337
9a1ada6c
TG
338 * coff-rs6000.c (xcoff_create_csect_from_smclas): Handle more smclas.
339
a685c4e6
TG
3402013-07-02 Tristan Gingold <gingold@adacore.com>
341
342 * coff-rs6000.c (xcoff_find_nearest_line_discriminator): New function.
343 (rs6000coff_vec): Reference it.
344
cc0efaa8
MS
3452013-07-02 Marcus Shawcroft <marcus.shawcroft@arm.com>
346
347 * elfnn-aarch64.c (aarch64_elf_create_got_section): New.
348 (elfNN_aarch64_check_relocs): Use aarch64_elf_create_got_section.
349 (elfNN_aarch64_create_dynamic_sections): Do not define
350 _GLOBAL_OFFSET_TABLE_; call aarch64_elf_create_got_section.
351
9d115506
MS
3522013-07-02 Marcus Shawcroft <marcus.shawcroft@arm.com>
353
354 * ld-aarch64/emit-relocs-309-low.d: Adjust .text address.
355 * ld-aarch64/emit-relocs-309-up.d: Adjust .got address.
356 * ld-aarch64/emit-relocs-312.d: Adjust offsets into .got.
357 * ld-aarch64/tls-relax-all.d: Likewise.
358 * ld-aarch64/gc-got-relocs.d: Adjust expected .got content.
359 * ld-aarch64/gc-tls-relocs.d: Likewise.
360 * ld-aarch64/tls-relax-gd-ie.d: Likewise.
361 * ld-aarch64/tls-relax-gdesc-ie-2.d: Likewise.
362 * ld-aarch64/tls-relax-gdesc-ie.d: Likewise.
363
f40da81b
AM
3642013-07-02 Alan Modra <amodra@gmail.com>
365
366 * elf64-ppc.c (ppc64_elf_relocate_section): Set "relocation" for
367 .TOC. after relocatable check.
368
1c865ab2
AM
3692013-07-01 Alan Modra <amodra@gmail.com>
370
371 * elf64-ppc.h (ppc64_elf_toc): Delete.
372 (ppc64_elf_set_toc): Declare.
373 * elf64-ppc.c (ppc64_elf_toc_reloc): Replace call to ppc64_elf_toc
374 with call the ppc64_elf_set_toc.
375 (ppc64_elf_toc_ha_reloc, ppc64_elf_toc64_reloc): Likewise.
376 (ppc64_elf_start_multitoc_partition): Likewise.
377 (struct ppc_link_hash_table): Delete dot_toc_dot. Replace all uses
378 with elf.hgot.
379 (ppc64_elf_process_dot_syms): Don't make a fake function descriptor
380 for ".TOC.".
381 (ppc64_elf_check_relocs): Mark sections with a reference to .TOC.
382 as needing a toc pointer.
383 (ppc64_elf_size_stubs): Don't set dot_toc_dot here.
384 (ppc64_elf_set_toc): Rename from ppc64_elf_toc. Add info param.
385 Set elf.hgot value.
386
a69ed7f7
L
3872013-06-28 H.J. Lu <hongjiu.lu@intel.com>
388
389 PR ld/15685
390 * elf64-x86-64.c (elf_x86_64_relocate_section): Handle
391 R_X86_64_DTPOFF64.
392
c3b6407f
NC
3932013-06-28 Nick Clifton <nickc@redhat.com>
394
395 PR ld/15302
396 * elf32-arm.c (allocate_dynrelocs_for_symbol): Revert previous patch.
397
8db339a6
MS
3982013-06-27 Marcus Shawcroft <marcus.shawcroft@arm.com>
399
400 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Reserve one slot
401 in sgot.
402 (elfNN_aarch64_finish_dynamic_sections): Place the &_DYNAMIC reference
403 in sgot[0] rather than sgotplt[0].
404
2d426575
YZ
4052013-06-26 Yufeng Zhang <yufeng.zhang@arm.com>
406
407 * Makefile.am (elf32-aarch64.c): Add a #line cpp directive at the
408 beginning of the generated file.
409 (elf64-aarch64.c): Likewise.
410 * Makefile.in: Re-generated.
411
caed7120
YZ
4122013-06-26 Yufeng Zhang <yufeng.zhang@arm.com>
413
414 * Makefile.am (BFD64_BACKENDS): Add elfxx-aarch64.c.
415 (BFD64_BACKENDS_CFILES): Add elfxx-aarch64.lo.
416 * Makefile.in: Re-generated.
417 * configure.in (bfd_elf64_bigaarch64_vec): Add elfxx-aarch64.lo.
418 (bfd_elf64_littleaarch64_vec): Likewise.
419 (bfd_elf32_bigaarch64_vec): Likewise.
420 (bfd_elf32_littleaarch64_vec): Likewise.
421 * configure: Re-generated.
422 * elfxx-aarch64.c: New file; split from elf64-aarch64.c.
423 * elfxx-aarch64.h: New file.
424 * elfnn-aarch64.c: Include "elfxx-aarch64.h"; move the following
425 stuff to elfxx-aarch64.c.
426 (bfd_elf_aarch64_put_addend): Removed.
427 (PG_OFFSET, PG): Likewise.
428 (elfNN_aarch64_small_plt0_entry): Support ELF32.
429 (elfNN_aarch64_tlsdesc_small_plt_entry): Likewise.
430 (elf64_aarch64_grok_prstatus): Removed.
431 (elf_backend_grok_prstatus): Removed.
432 (insn32): Likewise.
433 (aarch64_unsigned_overflow): Likewise.
434 (aarch64_signed_overflow): Likewise.
435 (aarch64_resolve_relocation): Likewise.
436 (MASK): Likewise.
437 (decode_branch_ofs_26): Likewise.
438 (decode_cond_branch_ofs_19): Likewise.
439 (decode_ld_lit_ofs_19): Likewise.
440 (decode_tst_branch_ofs_14): Likewise.
441 (decode_movw_imm): Likewise.
442 (decode_adr_imm): Likewise.
443 (decode_add_imm): Likewise.
444 (reencode_branch_ofs_26): Likewise.
445 (reencode_cond_branch_ofs_19): Likewise.
446 (reencode_ld_lit_ofs_19): Likewise.
447 (reencode_tst_branch_ofs_14): Likewise.
448 (reencode_movw_imm): Likewise.
449 (reencode_adr_imm): Likewise.
450 (reencode_ldst_pos_imm): Likewise.
451 (reencode_add_imm): Likewise.
452 (reencode_movzn_to_movz): Likewise.
453 (reencode_movzn_to_movn): Likewise.
454 (aarch64_relocate): Update to call the new function names in
455 elfxx-aarch64.c.
456 (aarch64_calculate_got_entry_vma): Likewise.
457 (elfNN_aarch64_final_link_relocate): Likewise.
458 (elf64_aarch64_update_plt_entry): Likewise; change the type of the
459 parameter 'r_type' to bfd_reloc_code_real_type; rename to ...
460 (elf_aarch64_update_plt_entry): ... this.
461 (elfNN_aarch64_create_small_pltn_entry): Update.
462 (elfNN_aarch64_init_small_plt0_entry): Remove plt_got_base; add
463 bfd_vma plt_got_2nd_ent; update to call elf_aarch64_update_plt_entry.
464 (elfNN_aarch64_finish_dynamic_sections): Add plt_entry; update to
465 call elf_aarch64_update_plt_entry.
466
a6bb11b2
YZ
4672013-06-26 Yufeng Zhang <yufeng.zhang@arm.com>
468
469 * bfd-in2.h: Re-generated.
470 * elfnn-aarch64.c (HOWTO64, HOWTO32): New define.
471 (IS_AARCH64_TLS_RELOC): Change to be based on the
472 bfd reloc enumerators.
473 (IS_AARCH64_TLSDESC_RELOC): Likewise.
474 (PG, PG_OFFSET): Cast literal to bfd_vma.
475 (elf64_aarch64_howto_table): Removed.
476 (elf64_aarch64_howto_dynrelocs): Removed.
477 (elf64_aarch64_tls_howto_table): Removed.
478 (elf64_aarch64_tlsdesc_howto_table): Removed.
479 (elfNN_aarch64_howto_table): New table to host all howto entires..
480 (R_AARCH64_*): Replaced by AARCH64_R (*) and AARCH64_R_STR (*).
481 (elfNN_aarch64_bfd_reloc_from_howto): New function.
482 (elfNN_aarch64_bfd_reloc_from_type): Ditto.
483 (struct elf_aarch64_reloc_map): New.
484 (elf_aarch64_reloc_map): New table.
485 (elfNN_aarch64_howto_from_bfd_reloc): New function.
486 (elfNN_aarch64_howto_from_type): Update to look up the new table
487 elfNN_aarch64_howto_table.
488 (struct elf64_aarch64_reloc_map): Remove.
489 (elf64_aarch64_reloc_map): Remove.
490 (elfNN_aarch64_reloc_type_lookup): Change to call
491 elfNN_aarch64_howto_from_bfd_reloc.
492 (elfNN_aarch64_reloc_name_lookup): Change to look up the new table
493 elfNN_aarch64_howto_table.
494 (aarch64_resolve_relocation): Refactor to switch on the bfd
495 reloc enumerators.
496 (bfd_elf_aarch64_put_addend): Likewise.
497 (elfNN_aarch64_final_link_relocate): Likewise.
498 (aarch64_tls_transition_without_check): Likewise.
499 (aarch64_reloc_got_type): Likewise.
500 (aarch64_can_relax_tls): Likewise.
501 (aarch64_tls_transition): Likewise.
502 (elfNN_aarch64_tls_relax): Likewise.
503 (elfNN_aarch64_final_link_relocate): Likewise.
504 (elfNN_aarch64_relocate_section): Likewise.
505 (elfNN_aarch64_gc_sweep_hook): Likewise.
506 (elfNN_aarch64_check_relocs): Likewise.
507 (aarch64_tls_transition): Change to return a bfd reloc enumerator.
508 * libbfd.h: Re-generated.
509 * reloc.c: Re-order the AArch64 bfd reloc enumerators.
510 (BFD_RELOC_AARCH64_RELOC_START)
511 (BFD_RELOC_AARCH64_RELOC_END)
512 (BFD_RELOC_AARCH64_LD_GOT_LO12_NC)
513 (BFD_RELOC_AARCH64_LD32_GOT_LO12_NC)
514 (BFD_RELOC_AARCH64_TLSDESC_LD_LO12_NC)
515 (BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC)
516 (BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_LO12_NC)
517 (BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC)
518 (BFD_RELOC_AARCH64_IRELATIVE): New relocs.
519
cec5225b
YZ
5202013-06-26 Yufeng Zhang <yufeng.zhang@arm.com>
521
522 * Makefile.am (BFD64_BACKENDS): Add elf32-aarch64.lo.
523 (BUILD_CFILES): Add elf32-aarch64.c.
524 (elf32-aarch64.c): New rule for generating from elfnn-aarch64.c.
525 * Makefile.in: Re-generated.
526 * archures.c (bfd_mach_aarch64_ilp32): New define.
527 * bfd-in.h (bfd_elf32_aarch64_init_maps): New declaration.
528 (bfd_elf32_aarch64_set_options): Ditto.
529 (elf32_aarch64_setup_section_lists): Ditto.
530 (elf32_aarch64_next_input_section): Ditto.
531 (elf32_aarch64_size_stubs): Ditto.
532 (elf32_aarch64_build_stubs): Ditto.
533 * bfd-in2.h: Re-generated.
534 * config.bfd (aarch64-*-elf): Add bfd_elf32_littleaarch64_vec
535 and bfd_elf32_bigaarch64_vec.
536 (aarch64-*-linux*): Likewise.
537 (aarch64_be-*-elf): Likewise.
538 (aarch64_be-*-linux*): Likewise.
539 * configure.in (bfd_elf32_bigaarch64_vec)
540 (bfd_elf32_littleaarch64_vec): New.
541 * configure: Re-generated.
542 * cpu-aarch64.c (compatible): Don't allow mixing ilp32 objects with
543 lp64 ones.
544 (bfd_aarch64_arch_ilp32): New.
545 (bfd_aarch64_arch): Link to bfd_aarch64_arch_ilp32.
546 * elfnn-aarch64.c (ARCH_SIZE): New define.
547 (AARCH64_R, AARCH64_R_STR, LOG_FILE_ALIGN): New defines.
548 (GOT_ENTRY_SIZE): Re-define as (ARCH_SIZE / 8).
549 (elf64_aarch64_*): Rename to elfNN_aarch64_*.
550 (ELF64_R_*): Rename to ELFNN_R_*.
551 Plus other paramaterization.
552 * targets.c (bfd_elf32_bigaarch64_vec, bfd_elf32_littleaarch64_vec):
553 New declarations.
554 (_bfd_target_vector): Add bfd_elf32_bigaarch64_vec and
555 bfd_elf32_littleaarch64_vec.
556
81197114
YZ
5572013-06-26 Yufeng Zhang <yufeng.zhang@arm.com>
558
559 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-aarch64.c.
560 (BUILD_CFILES): Add elf64-aarch64.c.
561 (elf64-aarch64.c): New rule for generating from elfnn-aarch64.c.
562 * Makefile.in: Re-generated.
563 * elf64-aarch64.c: Rename to ...
564 * elfnn-aarch64.c: ... this.
565
833794fc
MR
5662013-06-25 Maciej W. Rozycki <macro@codesourcery.com>
567 Paul Brook <paul@codesourcery.com>
568
569 * elfxx-mips.h (_bfd_mips_elf_insn32): New prototype.
570 * elfxx-mips.c (mips_elf_link_hash_table): Add insn32 member.
571 (STUB_MOVE32_MICROMIPS, STUB_JALR32_MICROMIPS): New macros.
572 (MICROMIPS_INSN32_FUNCTION_STUB_NORMAL_SIZE): Likewise.
573 (MICROMIPS_INSN32_FUNCTION_STUB_BIG_SIZE): Likewise.
574 (micromips_insn32_o32_exec_plt0_entry): New variable.
575 (micromips_insn32_o32_exec_plt_entry): Likewise.
576 (_bfd_mips_elf_adjust_dynamic_symbol): Handle insn32 mode.
577 (mips_elf_estimate_stub_size): Likewise.
578 (_bfd_mips_elf_size_dynamic_sections): Likewise.
579 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
580 (mips_finish_exec_plt): Likewise.
581 (_bfd_mips_elf_relax_section): Likewise.
582 (_bfd_mips_elf_insn32): New function.
583 (_bfd_mips_elf_get_synthetic_symtab): Handle insn32 PLT.
584
1bbce132
MR
5852013-06-24 Maciej W. Rozycki <macro@codesourcery.com>
586
587 * elfxx-mips.h (_bfd_mips_elf_get_synthetic_symtab): New
588 prototype.
589 * elf32-mips.c (elf_backend_plt_sym_val): Remove macro.
590 (bfd_elf32_get_synthetic_symtab): New macro.
591 * elfxx-mips.c (plt_entry): New structure.
592 (mips_elf_link_hash_entry): Add use_plt_entry member.
593 (mips_elf_link_hash_table): Rename plt_entry_size member to
594 plt_mips_entry_size. Add plt_comp_entry_size, plt_mips_offset,
595 plt_comp_offset, plt_got_index entries and plt_header_is_comp
596 members.
597 (STUB_LW_MICROMIPS, STUB_MOVE_MICROMIPS): New macros.
598 (STUB_LUI_MICROMIPS, STUB_JALR_MICROMIPS): Likewise.
599 (STUB_ORI_MICROMIPS, STUB_LI16U_MICROMIPS): Likewise.
600 (STUB_LI16S_MICROMIPS): Likewise.
601 (MICROMIPS_FUNCTION_STUB_NORMAL_SIZE): Likewise.
602 (MICROMIPS_FUNCTION_STUB_BIG_SIZE): Likewise.
603 (micromips_o32_exec_plt0_entry): New variable.
604 (mips16_o32_exec_plt_entry): Likewise.
605 (micromips_o32_exec_plt_entry): Likewise.
606 (mips_elf_link_hash_newfunc): Initialize use_plt_entry.
607 (mips_elf_output_extsym): Update to use gotplt_union's plist
608 member rather than offset.
609 (mips_elf_gotplt_index): Likewise. Remove the VxWorks
610 restriction. Use MIPS_ELF_GOT_SIZE to calculate GOT address.
611 (mips_elf_count_got_symbols): Update to use gotplt_union's plist
612 member rather than offset.
613 (mips_elf_calculate_relocation): Handle MIPS16/microMIPS PLT
614 entries.
615 (_bfd_mips_elf_create_dynamic_sections): Don't set PLT sizes
616 here.
617 (mips_elf_make_plt_record): New function.
618 (_bfd_mips_elf_check_relocs): Update comment. Record occurences
619 of JAL relocations that might need a PLT entry.
620 (_bfd_mips_elf_adjust_dynamic_symbol): Update to use
621 gotplt_union's plist member rather than offset. Set individual
622 PLT entry sizes here. Handle MIPS16/microMIPS PLT entries.
623 Don't set the symbol's value in the symbol table for PLT
624 references here. Don't set the PLT or PLT GOT section sizes
625 here.
626 (mips_elf_estimate_stub_size): Handle microMIPS stubs.
627 (mips_elf_allocate_lazy_stub): Likewise.
628 (mips_elf_lay_out_lazy_stubs): Likewise. Define a _MIPS_STUBS_
629 magic symbol.
630 (mips_elf_set_plt_sym_value): New function.
631 (_bfd_mips_elf_size_dynamic_sections): Set PLT header size and
632 PLT and PLT GOT section sizes here. Set the symbol values in
633 the symbol table for PLT references here. Handle microMIPS
634 annotation of the _PROCEDURE_LINKAGE_TABLE_ magic symbol.
635 (_bfd_mips_elf_finish_dynamic_symbol): Update to use
636 gotplt_union's plist member rather than offset. Handle
637 MIPS16/microMIPS PLT entries. Handle microMIPS stubs.
638 (_bfd_mips_vxworks_finish_dynamic_symbol): Update to use
639 gotplt_union's plist member rather than offset. Use
640 MIPS_ELF_GOT_SIZE to calculate GOT address.
641 (mips_finish_exec_plt): Handle microMIPS PLT. Return status.
642 (_bfd_mips_elf_finish_dynamic_sections): Handle result from
643 mips_finish_exec_plt.
644 (_bfd_mips_elf_link_hash_table_create): Update to use
645 gotplt_union's plist member rather than offset.
646 (_bfd_mips_elf_get_synthetic_symtab): New function.
647
cd6d434c
NC
6482013-06-24 Wawa <caojinyu@msn.com>
649
650 PR 15657
651 * hash.c (_bfd_stringtab_add): Copy the string if COPY is true.
652
42429eac
RS
6532013-06-23 Richard Sandiford <rdsandiford@googlemail.com>
654
655 * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Move MIPS ELF
656 files to...
657 (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): ...here.
658 * Makefile.in: Regenerate.
659 * config.bfd: Enclose all MIPS ELF targets in #ifdef BFD64.
660 Set want64 to true for them at the end.
661 * targets.c (_bfd_target_vector): Protect MIPS ELF targets with
662 #ifdef BFD64.
663
12d83431
SL
6642013-06-22 Sandra Loosemore <sandra@codesourcery.com>
665
666 * elf32-nios2.c (nios2_elf32_finish_dynamic_sections): Don't
667 set sh_entsize for PLT section.
668
b9eead84
YZ
6692013-06-20 Yufeng Zhang <yufeng.zhang@arm.com>
670
671 * bfd-in.h (bfd_elf64_aarch64_set_options): Add 'extern'.
672 * bfd-in2.h: Re-generated.
673 * elf64-aarch64.c (RELOC_SECTION): Removed.
674 (SWAP_RELOC_IN, SWAP_RELOC_OUT): Ditto.
675 (AARCH64_ELF_OS_ABI_VERSION): Ditto.
676 (elf64_aarch64_link_hash_traverse): Ditto.
677 (elf64_aarch64_size_stubs): Change 'Aarch64' to 'AArch64' in the
678 comment.
679
8847944f
WN
6802013-06-19 Will Newton <will.newton@linaro.org>
681
682 * configure: Regenerated.
683 * configure.in: Remove aarch64 dependency on elf-ifunc.c.
684 * elf64-aarch64.c: Remove objalloc.h include.
685 (elf64_aarch64_howto_dynrelocs): Remove R_AARCH64_IRELATIVE howto.
686 (struct elf64_aarch64_link_hash_table): Remove ifunc related
687 members. (elf_aarch64_local_htab_hash): Remove function.
688 (elf_aarch64_local_htab_eq): Remove function.
689 (elf_aarch64_get_local_sym_hash): Remove function.
690 (elf64_aarch64_link_hash_table_create): Remove local hash
691 table initialization.
692 (elf64_aarch64_final_link_relocate): Remove sym argument and
693 handling of ifunc symbols.
694 (elf64_aarch64_relocate_section): Don't pass sym argument to
695 elf64_aarch64_final_link_relocate.
696 (elf64_aarch64_gc_sweep_hook): Remove handling of ifunc symbols.
697 (elf64_aarch64_adjust_dynamic_symbol): Likewise.
698 (elf64_aarch64_check_relocs): Likewise.
699 (elf64_aarch64_post_process_headers): Remove call to
700 _bfd_elf_set_osabi.
701 (elf64_aarch64_is_function_type): New function.
702 (elf64_aarch64_allocate_dynrelocs): Remove handling of ifunc
703 symbols. (elf_aarch64_allocate_local_dynrelocs): Remove function.
704 (elf64_aarch64_size_dynamic_sections): Remove call to
705 elf_aarch64_allocate_local_dynrelocs.
706 (elf64_aarch64_create_small_pltn_entry): Remove info argument.
707 Remove creation of R_AARCH64_IRELATIVE dynamic relocs.
708 (elf64_aarch64_finish_dynamic_symbol): Remove handling of ifunc
709 symbols. (elf_aarch64_finish_local_dynamic_symbol): Remove
710 function. (elf64_aarch64_finish_dynamic_sections): Remove call to
711 elf_aarch64_finish_local_dynamic_symbol.
712 (elf64_aarch64_add_symbol_hook): Remove function.
713
2532064a
YZ
7142013-06-14 Yufeng Zhang <yufeng.zhang@arm.com>
715
716 * elf64-aarch64.c (elf64_aarch64_final_link_relocate): Call
717 aarch64_resolve_relocation and bfd_elf_aarch64_put_addend to
718 handle the relocations of R_AARCH64_JUMP26, R_AARCH64_CALL26,
719 R_AARCH64_LD64_GOT_LO12_NC, R_AARCH64_ADR_GOT_PAGE and
720 R_AARCH64_GOT_LD_PREL19.
721
2f47f5fc
NC
7222013-06-13 Terry Guo <terry.guo@arm.com>
723
724 PR ld/15302
725 * elf32-arm.c (allocate_dynrelocs_for_symbol): Transform
726 ST_BRANCH_TO_ARM into ST_BRANCH_TO_THUMB if the target only
727 supports thumb instructions.
728
34064ff3
DD
7292013-06-11 DJ Delorie <dj@redhat.com>
730
731 * elf32-rl78.c (rl78_elf_relocate_section): Fix OPsub math.
732
3368874f
WN
7332013-06-11 Will Newton <will.newton@linaro.org>
734
735 * elf64-aarch64.c (elf_aarch64_get_local_sym_hash): Use
736 ELF64_R_SYM instead of ELF32_R_SYM.
737
47fc0f1f
NC
7382013-06-11 Nick Clifton <nickc@redhat.com>
739
740 * elf32-rl78.c (rl78_elf_finish_dynamic_sections): Onlly run
741 checks if the dynamic sections have been created and relaxation
742 has not been performed.
743
692e2b8b
WN
7442013-06-07 Will Newton <will.newton@linaro.org>
745
746 * configure: Regenerate.
747 * configure.in: Build elf-ifunc.o for AArch64.
748 * elf64-aarch64.c: Include objalloc.h.
749 (elf64_aarch64_howto_dynrelocs): Add R_AARCH64_IRELATIVE howto.
750 (struct elf64_aarch64_link_hash_table): Add members for handling
751 R_AARCH64_IRELATIVE relocations.
752 (elf_aarch64_local_htab_hash): New function.
753 (elf_aarch64_local_htab_eq): New function.
754 (elf_aarch64_get_local_sym_hash): New function.
755 (elf64_aarch64_link_hash_table_create): Initialize local STT_GNU_IFUNC
756 symbol hash.
757 (elf64_aarch64_hash_table_free): Free local STT_GNU_IFUNC symbol hash.
758 (elf64_aarch64_final_link_relocate): Add sym argument. Add support
759 for handling STT_GNU_IFUNC symbols.
760 (elf64_aarch64_gc_sweep_hook): Add support for garbage collecting
761 references to STT_GNU_IFUNC symbols.
762 (elf64_aarch64_adjust_dynamic_symbol): Add support for handling
763 STT_GNU_IFUNC symbols.
764 (elf64_aarch64_check_relocs): Add support for handling STT_GNU_IFUNC
765 symbols. Ensure we don't increase plt.refcount from -1 to 0.
766 (elf64_aarch64_post_process_headers): Call _bfd_elf_set_osabi.
767 (elf64_aarch64_is_function_type): Remove function.
768 (elf64_aarch64_allocate_dynrelocs): Call
769 _bfd_elf_allocate_ifunc_dyn_relocs for STT_GNU_IFUNC symbols.
770 (elf_aarch64_allocate_local_dynrelocs): New function.
771 (elf64_aarch64_size_dynamic_sections): Call
772 elf_aarch64_allocate_local_dynrelocs. Initialize next_irelative_index.
773 (elf64_aarch64_create_small_pltn_entry): Add info argument.
774 Add support for creating .iplt entries for STT_GNU_IFUNC symbols.
775 (elf64_aarch64_finish_dynamic_symbol): Add support for handling
776 STT_GNU_IFUNC symbols and .iplt.
777 (elf_aarch64_finish_local_dynamic_symbol): New function.
778 (elf64_aarch64_finish_dynamic_sections): Call
779 elf_aarch64_finish_local_dynamic_symbol.
780 (elf64_aarch64_add_symbol_hook): New function.
781
fa549f3b
AM
7822013-06-03 Alan Modra <amodra@gmail.com>
783
784 * syms.c (_bfd_stab_section_find_nearest_line): Add last_str
785 var. Use it with last_stab.
786
067ec077
CM
7872013-05-30 Paul Brook <paul@codesourcery.com>
788
789 * bfd-in2.h: Regenerate.
790 * elf32-mips.c (elf_mips_eh_howto): New.
791 (bfd_elf32_bfd_reloc_type_lookup ): Support BFD_RELOC_MIPS_EH.
792 (bfd_elf32_bfd_reloc_name_lookup): Likewise.
793 (mips_elf32_rtype_to_howto): Support R_MIPS_EH.
794 * elf64-mips.c (elf_mips_eh_howto): New.
795 (bfd_elf64_bfd_reloc_type_lookup): Support BFD_RELOC_MIPS_EH.
796 (bfd_elf64_bfd_reloc_name_lookup): Likewise.
797 (mips_elf64_rtype_to_howto): Support R_MIPS_EH.
798 * libbfd.h: Regenerate.
799 * reloc.c (BFD_RELOC_MIPS_EH): New.
800
95e34fb4
NC
8012013-05-29 Nick Clifton <nickc@redhat.com>
802
803 * dwarf2.c (struct dwarf2_debug): Add fields for handling
804 alternate debug info source.
805 (dwarf_debug_sections): Add entries for alternate .debug_str and
806 .debug_info sections.
807 (dwarf_debug_section_enum): Likewise.
808 (read_alt_indirect_string): New function. Handles a
809 DW_FORM_GNU_strp_alt attribute.
810 (read_alt_indirect_ref): New function. Handles a
811 DW_FORM_GNU_ref_alt attribute.
812 (read_attribute_value): Process DW_FORM_GNU_ref_alt and
813 DW_FORM_GNU_strp_alt.
814 (find_abstract_instance_name): Handle DW_FORM_GNU_ref_alt
815 attributes.
816 (_bfd_dwarf2_cleanup_debug_info): Free alternate debug info
817 sources.
818 * opncls.c (GNU_DEBUGALTLINK): Define.
819 (bfd_get_alt_debug_link_info): New function.
820 (separate_alt_debug_file_exists): New function.
821 (find_separate_debug_file): Add parameters for fetch and check
822 functions.
823 (bfd_follow_gnu_debugaltlink): New function.
824 * bfd-in2.h: Regenerate.
825
418009c2
YZ
8262013-05-28 Yufeng Zhang <yufeng.zhang@arm.com>
827
828 * reloc.c (BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE): Rename to ...
829 (BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21): ... this.
830 (BFD_RELOC_AARCH64_TLSDESC_LD64_PREL19): Rename to ...
831 (BFD_RELOC_AARCH64_TLSDESC_LD_PREL19): ... this.
832 * bfd-in2.h: Regenerate.
833 * libbfd.h: Regenerate.
834 * elf64-aarch64.c (IS_AARCH64_TLSDESC_RELOC): Update to use
835 the correct names.
836 (elf64_aarch64_tlsdesc_howto_table): Likewise.
837 (elf64_aarch64_reloc_map): Likewise.
838 (aarch64_resolve_relocation): Likewise.
839 (bfd_elf_aarch64_put_addend): Likewise.
840 (aarch64_tls_transition_without_check): Likewise.
841 (aarch64_reloc_got_type): Likewise.
842 (elf64_aarch64_final_link_relocate): Likewise.
843 (elf64_aarch64_tls_relax): Likewise.
844 (elf64_aarch64_relocate_section): Likewise.
845 (elf64_aarch64_gc_sweep_hook): Likewise.
846 (elf64_aarch64_check_relocs): Likewise.
847
9d782e8d
MW
8482013-05-26 Mark Wielaard <mjw@redhat.com>
849
850 * cache.c (BFD_CACHE_MAX_OPEN): Remove define.
851 (max_open_files): New static int initialized to zero.
852 (bfd_cache_max_open): New static function to set and return
853 max_open_files.
854 (bfd_cache_init): Use bfd_cache_max_open.
855 (bfd_open_file): Likewise.
856 * configure.in (AC_CHECK_HEADERS): Add sys/resource.h.
857 (AC_CHECK_FUNCS): Add getrlimit.
858 * configure: Regenerated.
859 * config.in: Likewise.
860 * sysdep.h: Check and include sys/resource.h for getrlimit.
861
03ae2d5e
AM
8622013-05-23 Alan Modra <amodra@gmail.com>
863
864 * format.c (bfd_check_format_matches): Don't match a target in
865 targ_selvecs if some other target is a better match. If
866 targets implement match priority, fall back to the first of
867 the best matches.
868
ad3d9127
AM
8692013-05-22 Eric Herman <eric@freesa.org>
870
871 PR binutils/15462
872 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Warning fix.
873
5b3905f1
AM
8742013-05-22 Ralf Dreesen <gamma@dreesen.net>
875
876 PR binutils/15474
877 * srec.c (srec_set_section_contents): Properly convert size
878 and offset to address when octets_per_byte is not unity.
879
8be65dd3
MR
8802013-05-20 Maciej W. Rozycki <macro@linux-mips.org>
881
882 * elf32-vax.c (elf_vax_instantiate_got_entries): Only set the
883 refcount member of the gotplt_union when resetting the reference
884 count. Adjust comment.
885
593f8f29
WN
8862013-05-20 Will Newton <will.newton@linaro.org>
887
888 * elf64-aarch64.c (elf64_aarch64_link_hash_entry): Remove
889 relocs_copied member.
890 (elf64_aarch64_link_hash_newfunc): Remove initialization of
891 relocs_copied member.
892 (elf64_aarch64_copy_indirect_symbol): Remove code to copy
893 relocs_copied member.
894
a0f0eb1e
MR
8952013-05-19 Maciej W. Rozycki <macro@linux-mips.org>
896
897 * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Convert K&R
898 function definition.
899
af65e588
CC
9002013-05-16 Cary Coutant <ccoutant@google.com>
901
902 * ecoff.c (ecoff_link_check_archive_element): Add initializers for
903 external_ext_size and esize.
904
9f6e76f4
TG
9052013-05-16 Tristan Gingold <gingold@adacore.com>
906
907 * coff-rs6000.c (_bfd_xcoff_reloc_type_lookup): Handle BFD_RELOC_16.
908 * coff64-rs6000.c (xcoff64_reloc_type_lookup): Likewise.
909
c495064d
AS
9102013-05-15 Andreas Schwab <schwab@suse.de>
911
912 * elf64-aarch64.c (elf_backend_default_execstack): Define to 0.
913
110a61d3
JB
9142013-05-10 Joel Brobecker <brobecker@adacore.com>
915
916 * coffcode.h (styp_to_sec_flags) [RS6000COFF_C]: Add handling
917 of STYP_EXCEPT, STYP_LOADER and STYP_TYPCHK sections.
918
ceae87f3
JB
9192013-05-09 Joel Brobecker <brobecker@adacore.com>
920
921 * bfd.c (_bfd_default_error_handler): Replace use of putc
922 by fputc. Add comment explaining why.
923
012b2306
AM
9242013-05-09 Alan Modra <amodra@gmail.com>
925
926 * elflink.c (elf_link_add_object_symbols): Don't omit reading
927 of symbols when hashes already exist.
928
7b70956d
WN
9292013-05-07 Will Newton <will.newton@linaro.org>
930
931 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Add a
932 plt_header_size argument for ports where it differs from
933 plt_entry_size.
934 * elf-bfd.h: Likewise.
935 * elf32-i386.c: Pass plt_header_size to
936 _bfd_elf_allocate_ifunc_dyn_relocs.
937 * elf64-x86-64.c: Likewise.
938
1ee9e8b3
WN
9392013-05-07 Will Newton <will.newton@linaro.org>
940
012b2306 941 * elf-ifunc.c (_bfd_elf_create_ifunc_dyn_reloc): Remove unused
1ee9e8b3
WN
942 function.
943 * elf-bfd.h: Likewise.
944
b47468a6
CM
9452013-05-06 Paul Brook <paul@codesourcery.com>
946
012b2306
AM
947 * elf64-mips.c (elf_mips_gnu_pcrel32): New.
948 (bfd_elf64_bfd_reloc_type_lookup, bfd_elf64_bfd_reloc_name_lookup,
949 mips_elf64_rtype_to_howto): Handle R_MIPS_PC32.
950 * elfn32-mips.c (elf_mips_gnu_pcrel32): New.
951 (bfd_elfn32_bfd_reloc_type_lookup, bfd_elfn32_bfd_reloc_name_lookup,
952 mips_elfn32_rtype_to_howto): Handle R_MIPS_PC32.
b47468a6 953
128205bb
AM
9542013-05-06 Alan Modra <amodra@gmail.com>
955
956 * elf64-ppc.c (opd_entry_value): Handle case where symbol
957 hashes are not available.
958
f45794cb
AM
9592013-05-06 Alan Modra <amodra@gmail.com>
960
961 * elflink.c (elf_link_add_object_symbols): Don't save symbol
962 hashes around loading as-needed library. Zero them on allocation,
963 and restore to initial all-zero state if library not needed.
964 Arrange to reuse hashes if we load library again later.
965
d150b1a2
RS
9662013-05-04 Richard Sandiford <rdsandiford@googlemail.com>
967
968 * elf32-mips.c (elf_mips_copy_howto, elf_mips_jump_slot_howto):
969 Use _bfd_mips_elf_generic_reloc instead of bfd_elf_generic_reloc.
970 * elfn32-mips.c: Likewise.
971 * elf64-mips.c: Likewise.
972
13761a11
NC
9732013-05-02 Nick Clifton <nickc@redhat.com>
974
975 * archures.c: Add some more MSP430 machine numbers.
976 * config.bfd (msp430): Define targ_selvecs.
977 * configure.in: Add bfd_elf32_msp430_ti_vec.
978 * cpu-msp430.c: Add some more MSP430 machine numbers.
979 * elf32-msp430.c Add support for MSP430X relocations.
980 Add support for TI compiler generated relocations.
981 Add support for sym_diff relocations.
982 Add support for relaxing out of range short branches into long
983 branches.
984 Add support for MSP430 attribute section.
985 * reloc.c: Add MSP430X relocations.
986 * targets.c: Add bfd_elf32_msp430_ti_vec.
987 * bfd-in2.h: Regenerate.
988 * configure: Regenerate.
989 * libbfd.h: Regenerate.
990
df26367c
MR
9912013-05-01 Maciej W. Rozycki <macro@codesourcery.com>
992
993 * config.bfd: Replace alpha*-*-linuxecoff* pattern with
994 alpha*-*-linux*ecoff*.
995
ed54588d
NC
9962013-04-30 Olaf Flebbe <o.flebbe@science-computing.de>
997
998 PR binutils/15417
999 * elflink.c (elf_link_add_object_symbols): Initialise 'idx' to
1000 zero.
1001
b8297068
AM
10022013-04-30 Alan Modra <amodra@gmail.com>
1003
1004 * elflink.c (bfd_elf_record_link_assignment): Dont make
1005 STV_INTERNAL symbols STV_HIDDEN.
1006
b40bf0a2
NC
10072013-04-29 Nick Clifton <nickc@redhat.com>
1008
1009 * elflink.c (_bfd_elf_gc_mark_extra_sections): Remove mark from
1010 fragmented .debug_line sections associated with unmarked code
1011 sections.
1012
aba8c3de
WN
10132013-04-29 Will Newton <will.newton@linaro.org>
1014
1015 * elf32-arm.c (elf32_arm_populate_plt_entry): Call
1016 elf32_arm_add_dynreloc when emitting R_ARM_IRELATIVE relocs.
1017
7fcfd62d
NC
10182013-04-29 Will Newton <will.newton@linaro.org>
1019
1020 * elf64-aarch64.c (elf64_aarch64_check_relocs): Move relocation
1021 error check up and add error message.
1022
ed5acf27
WN
10232013-04-26 Will Newton <will.newton@linaro.org>
1024
1025 * elf64-aarch64.c (elf64_aarch64_check_relocs): Remove dead code.
1026
49926cd0
AM
10272013-04-25 Alan Modra <amodra@gmail.com>
1028
1029 * config.bfd: Add powerpc64le-linux.
1030
05567e3d
L
10312013-04-24 H.J. Lu <hongjiu.lu@intel.com>
1032
1033 * config.bfd (targ_selvecs): Add bfd_elf32_x86_64_vec for
1034 x86_64-*-elf*.
1035
99059e56
RM
10362013-04-24 Roland McGrath <mcgrathr@google.com>
1037
1038 * elf32-arm.c (elf32_arm_allocate_plt_entry): If HTAB->nacl_p,
1039 allocate space for PLT header even if IS_IPLT_ENTRY.
1040 (arm_nacl_put_plt0): New function, broken out of ...
1041 (elf32_arm_finish_dynamic_sections): ... here. Call it.
1042 If HTAB->nacl_p, set up the PLT header in .iplt too.
1043 (elf32_arm_output_arch_local_syms): If HTAB->nacl_p, write
1044 a mapping symbol for the start of .iplt too.
1045
544008aa
NC
10462013-04-19 Luca Pizzamiglio <luca.pizzamiglio@gmail.com>
1047
7b5d8d96
NC
1048 * ecoff.c (_bfd_ecoff_sizeof_headers): Cast the return value of
1049 BFD_ALIGN to int.
1050 * elf32-tic6x.c (elf32_tic6x_size_dynamic_sections): Remove unused
1051 variables.
1052 * elf32-v850.c (v850_elf_relax_section): Redefine the type of 'i'
1053 to bfd_vma.
1054 * vms-alpha.c (evax_bfd_print_etir): Initialize sec_len.
544008aa 1055
86f7d49b
AM
10562013-04-22 Alan Modra <amodra@gmail.com>
1057
1058 PR ld/15382
1059 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Don't multiply
1060 sh_size or reloc_count adjustment by count.
1061
bfeb4a28
AM
10622013-04-22 Alan Modra <amodra@gmail.com>
1063
1064 * elf64-ppc.c (ppc64_elf_check_relocs): Don't call
1065 create_linkage_sections here..
1066 (ppc64_elf_init_stub_bfd): ..do so here. Return status.
1067 (create_linkage_sections): Move earlier in file.
1068 (ppc64_elf_setup_section_lists): Remove now useless htab->brlt test.
1069 * elf64-ppc.h (ppc64_elf_init_stub_bfd): Update proto.
1070
2d0a6933
NC
10712013-04-19 Nick Clifton <nickc@redhat.com>
1072
1073 PR binutils/15356
1074 * compress.c (decompress_contents): Always call inflateEnd, even
1075 when another inflation operation fails.
1076
a9ea330b
L
10772013-04-17 H.J. Lu <hongjiu.lu@intel.com>
1078
1079 * elf-ifunc.c: Update copyright year.
1080
a253d456
NC
10812013-04-17 Luca Pizzamiglio <luca.pizzamiglio@gmail.com>
1082
1083 * coffcode.h: Added a cast to void when a bfd_set_section_*()
1084 macro's return value is ignored.
1085 * elf32-hppa.c: Likewise.
1086 * elf32-tic6x.c: Likewise.
1087 * mach-o.c: Likewise.
1088 * mmo.c: Likewise.
1089 * opncls.c: Likewise.
1090 * peicode.h: Likewise.
1091 * elf32-m32r.c: Check return value of bfd_set_section_*().
1092 * elfnn-ia64.c: Likewise.
1093 * elfxx-mips.c: Likewise.
1094 * vms-alpha.c: Likewise.
1095
1622ff3b
L
10962013-04-15 H.J. Lu <hongjiu.lu@intel.com>
1097
1098 PR ld/15371
1099 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Check
1100 regular reference without non-GOT reference when building
1101 shared library.
1102
a22cd6f6
AM
11032013-04-15 Alan Modra <amodra@gmail.com>
1104
1105 * archive.c (_bfd_archive_close_and_cleanup): Clear parent
1106 cache slot for archives.
1107
ed905580
HPN
11082013-04-14 Hans-Peter Nilsson <hp@bitrange.com>
1109
1110 * mmo.c (mmo_write_chunk): Break out abfd->tdata.mmo_data to new
1111 local variable mmop.
1112
8d6a12ee
NC
11132013-04-09 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
1114
1115 PR ld/12494
1116 * bfd/elf32-avr.c: Consider all sections to determine if linker
1117 relaxation can safely delete a ret after a call/jmp
1118
79bb5c23
NC
11192013-04-09 Mingjie Xing <mingjie.xing@gmail.com>
1120
1121 * bfd.c (typedef bfd, Error reporting, Miscellaneous): Add
1122 INODEs.
1123
36192a8d
TT
11242013-04-08 Tom Tromey <tromey@redhat.com>
1125
1126 * som.c (bfd_section_from_som_symbol): No longer static.
1127 * som.h (bfd_section_from_som_symbol): Declare.
1128
198f1157
AM
11292013-04-06 Alan Modra <amodra@gmail.com>
1130
1131 * elf32-ppc.c (ppc_elf_check_relocs): Use SYMBOLIC_BIND.
1132 * elf64-ppc.c (ppc64_elf_check_relocs, dec_dynrel_count): Likewise.
1133
c69ba956
NC
11342013-04-05 Nick Clifton <nickc@redhat.com>
1135
1136 * elflink.c (elf_link_add_object_symbols): Revert accidental commit.
1137
ff5ac77b
AM
11382013-04-04 Alan Modra <amodra@gmail.com>
1139
1140 * bfd.c (bfd_error_type, bfd_errmsgs): Add bfd_error_missing_dso.
1141 * bfd-in2.h: Regenerate.
1142 * elflink.c (elf_link_add_object_symbols): Use new error.
1143
41702d50
NC
11442013-04-03 Nick Clifton <nickc@redhat.com>
1145
1146 * elf32-v850.c (v850_elf_is_target_special_symbol): New function.
1147 (bfd_elf32_bfd_is_target_special_symbol): Define.
1148
cb8af559
NC
11492013-04-03 Venkataramanan Kumar <venkataramanan.kumar@linaro.org>
1150
a22cd6f6
AM
1151 * elf64-aarch64.c (elf64_aarch64_gc_sweep_hook): Use
1152 elf64_aarch64_locals to get local GOT reference counts.
cb8af559 1153
1122dc88
DD
11542013-04-02 DJ Delorie <dj@redhat.com>
1155
1156 * elf32-rl78.c (GET_RELOC): Assert that there are relocs to get.
1157 (rl78_elf_relax_section): Only fetch the next reloc if there is
1158 one expected.
1159
81fbe831
AM
11602013-03-30 Alan Modra <amodra@gmail.com>
1161
1162 PR ld/15323
1163 * elf-m10300.c (mn10300_elf_check_relocs): Set non_ir_ref for
1164 global symbols referenced by relocs.
1165 * elf32-arm.c (elf32_arm_check_relocs): Likewise.
1166 * elf32-bfin.c (bfin_check_relocs): Likewise.
1167 * elf32-cr16.c (cr16_elf_check_relocs): Likewise.
1168 * elf32-cris.c (cris_elf_check_relocs): Likewise.
1169 * elf32-d10v.c (elf32_d10v_check_relocs): Likewise.
1170 * elf32-dlx.c (elf32_dlx_check_relocs): Likewise.
1171 * elf32-fr30.c (fr30_elf_check_relocs): Likewise.
1172 * elf32-frv.c (elf32_frv_check_relocs): Likewise.
1173 * elf32-hppa.c (elf32_hppa_check_relocs): Likewise.
1174 * elf32-i370.c (i370_elf_check_relocs): Likewise.
1175 * elf32-iq2000.c (iq2000_elf_check_relocs): Likewise.
1176 * elf32-lm32.c (lm32_elf_check_relocs): Likewise.
1177 * elf32-m32c.c (m32c_elf_check_relocs): Likewise.
1178 * elf32-m32r.c (m32r_elf_check_relocs): Likewise.
1179 * elf32-m68hc1x.c (elf32_m68hc11_check_relocs): Likewise.
1180 * elf32-m68k.c (elf_m68k_check_relocs): Likewise.
1181 * elf32-mcore.c (mcore_elf_check_relocs): Likewise.
1182 * elf32-metag.c (elf_metag_check_relocs): Likewise.
1183 * elf32-microblaze.c (microblaze_elf_check_relocs): Likewise.
1184 * elf32-moxie.c (moxie_elf_check_relocs): Likewise.
1185 * elf32-msp430.c (elf32_msp430_check_relocs): Likewise.
1186 * elf32-mt.c (mt_elf_check_relocs): Likewise.
1187 * elf32-nios2.c (nios2_elf32_check_relocs): Likewise.
1188 * elf32-openrisc.c (openrisc_elf_check_relocs): Likewise.
1189 * elf32-ppc.c (ppc_elf_check_relocs): Likewise.
1190 * elf32-rl78.c (rl78_elf_check_relocs): Likewise.
1191 * elf32-s390.c (elf_s390_check_relocs): Likewise.
1192 * elf32-score.c (s3_bfd_score_elf_check_relocs): Likewise.
1193 * elf32-score7.c (s7_bfd_score_elf_check_relocs): Likewise.
1194 * elf32-sh.c (sh_elf_check_relocs): Likewise.
1195 * elf32-tic6x.c (elf32_tic6x_check_relocs): Likewise.
1196 * elf32-tilepro.c (tilepro_elf_check_relocs): Likewise.
1197 * elf32-v850.c (v850_elf_check_relocs): Likewise.
1198 * elf32-vax.c (elf_vax_check_relocs): Likewise.
1199 * elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise.
1200 * elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
1201 * elf64-aarch64.c (elf64_aarch64_check_relocs): Likewise.
1202 * elf64-alpha.c (elf64_alpha_check_relocs): Likewise.
1203 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
1204 * elf64-ia64-vms.c (elf64_ia64_check_relocs): Likewise.
1205 * elf64-mmix.c (mmix_elf_check_relocs): Likewise.
1206 * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
1207 * elf64-s390.c (elf_s390_check_relocs): Likewise.
1208 * elf64-sh64.c (sh_elf64_check_relocs): Likewise.
1209 * elfnn-ia64.c (elfNN_ia64_check_relocs): Likewise.
1210 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
1211 * elfxx-tilegx.c (tilegx_elf_check_relocs): Likewise.
1212 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise. Don't
1213 test indirect/warning links for NULL.
1214
61315175
L
12152013-03-29 H.J. Lu <hongjiu.lu@intel.com>
1216
1217 PR ld/15323
1218 * elf32-i386.c (elf_i386_check_relocs): Set non_ir_ref if a
81fbe831 1219 symbol is referenced by a non-shared object.
61315175
L
1220 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
1221
a6f713fc
KK
12222013-03-28 Joe Seymour <jseymour@codesourcery.com>
1223
1224 * elf32-sh.c (sh_elf_relocate_section): Suppress warnings for
1225 R_SH_REL32 relocations against undefined weak symbols.
1226
19e08130
AM
12272013-03-28 Alan Modra <amodra@gmail.com>
1228
1229 * elf64-ppc.c (struct ppc_dyn_relocs): New.
1230 (ppc64_elf_check_relocs): Separate dynrel counts for local syms
1231 into ifunc and non-ifunc.
1232 (dec_dynrel_count): Pass in sym rather than sym_sec. Handle
1233 separate ifunc/non-ifunc dynrel counts.
1234 (allocate_got): Always use reliplt for ifunc.
1235 (allocate_dynrelocs): Likewise.
1236 (ppc64_elf_size_dynamic_sections): Likewise.
1237 (ppc64_elf_layout_multitoc): Likewise.
1238 (ppc64_elf_relocate_section): Likewise.
1239
f95f8542
AM
12402013-03-28 Alan Modra <amodra@gmail.com>
1241
1242 * elf32-ppc.c (struct ppc_dyn_relocs): New.
1243 (ppc_elf_check_relocs): Separate dynrel counts for local syms
1244 into ifunc and non-ifunc.
1245 (allocate_dynrelocs): Always put ifunc relocs into reliplt.
1246 (ppc_elf_size_dynamic_sections): Likewise.
1247 (ppc_elf_relocate_section): Likewise.
1248
7e612e98
AM
12492013-03-28 Alan Modra <amodra@gmail.com>
1250
1251 * elf-bfd.h (enum elf_reloc_type_class): Add reloc_class_ifunc.
1252 (struct elf_backend_data <elf_backed_reloc_type_class>): Add
1253 bfd_link_info* and asection* params.
1254 (_bfd_elf_reloc_type_class): Likewise.
1255 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1256 * elflink.c (elf_link_sort_cmp2): Sort first on reloc class.
1257 (elf_link_sort_relocs): Update elf_backed_reloc_type_class call.
1258 * elf32-ppc.c (ppc_elf_reloc_type_class): Return reloc_class_ifunc
1259 for any reliplt reloc. Don't return reloc_class_plt for
1260 R_PPC_REL24 and R_PPC_ADDR24.
1261 * elf64-ppc.c (allocate_got): Formatting.
1262 (ppc64_elf_reloc_type_class): Return reloc_class_ifunc for any
1263 reliplt reloc.
1264 * elf-m10300.c, * elf32-arm.c, * elf32-bfin.c, * elf32-cr16.c,
1265 * elf32-cris.c, * elf32-hppa.c, * elf32-i386.c, * elf32-lm32.c,
1266 * elf32-m32r.c, * elf32-m68k.c, * elf32-metag.c, * elf32-nios2.c,
1267 * elf32-s390.c, * elf32-sh.c, * elf32-sparc.c, * elf32-tilepro.c,
1268 * elf32-vax.c, * elf32-xtensa.c, * elf64-aarch64.c, * elf64-alpha.c,
1269 * elf64-hppa.c, * elf64-ia64-vms.c, * elf64-s390.c, * elf64-sparc.c,
1270 * elf64-x86-64.c, * elfnn-ia64.c, * elfxx-tilegx.c, * elfxx-tilegx.h:
1271 Add extra params to the various reloc_type_class functions.
1272
0bed072f
AM
12732013-03-27 Alan Modra <amodra@gmail.com>
1274
1275 * elf32-ppc.c (ppc_elf_check_relocs): Set PLT_IFUNC in local got
1276 masks for all local ifunc syms.
1277 (allocate_dynrelocs): Don't use htab->relgot for ifunc.
1278 (ppc_elf_size_dynamic_sections): Likewise.
1279 (ppc_elf_relocate_section): Likewise.
1280
6f820c85
WN
12812013-03-27 Will Newton <will.newton@linaro.org>
1282
1283 * elf32-arm.c (elf32_arm_final_link_relocate): Avoid emitting a
1284 dynamic reloc for symbols with dynindx == -1.
1285 (allocate_dynrelocs_for_symbol): Avoid allocating space for a
1286 dynamic reloc for symbols with dynindx == -1.
1287
31943882
WN
12882013-03-27 Will Newton <will.newton@linaro.org>
1289
1290 * elf32-arm.c (elf32_arm_final_link_relocate): Avoid emitting a
1291 dynamic reloc for non-default visibility undefined weaks.
1292 (allocate_dynrelocs_for_symbol): Avoid allocating space for a
1293 dynamic reloc for non-default visibility undefined weaks.
1294
ffd65175
AM
12952013-03-26 Alan Modra <amodra@gmail.com>
1296
1297 * elflink.c (_bfd_elf_add_default_symbol): Preserve section
1298 over _bfd_elf_merge_symbol calls.
1299
3a81e825
AM
13002013-03-26 Alan Modra <amodra@gmail.com>
1301
1302 * elflink.c (elf_link_add_object_symbols): Add assertion for
1303 common override alignment check code. Formatting.
1304
4f3fedcf
AM
13052013-03-25 Alan Modra <amodra@gmail.com>
1306
1307 * elflink.c (_bfd_elf_merge_symbol): Set old_alignment for
1308 usual common symbols as well as for dynamic. Add poldbfd param.
1309 Save old bfd. Adjust callers.
1310 (_bfd_elf_add_default_symbol): Add poldbfd param. Pass "section"
1311 and "value" by value, not pointer. Adjust caller.
1312 (elf_link_add_object_symbols): Combine undef_bfd and old_bfd vars.
1313 Delete code to set same. Use old_bfd and old_alignment from
1314 _bfd_elf_merge_symbol instead. Add default symbol before
1315 alignment and size checks. Wrap overlong lines.
1316
e3c9d234
AM
13172013-03-25 Alan Modra <amodra@gmail.com>
1318
1319 * elflink.c (_bfd_elf_add_default_symbol): Delete "override" param.
1320 (elf_link_add_object_symbols): Don't call _bfd_elf_add_default_symbol
1321 when override is true.
1322
6c9b78e6
AM
13232013-03-25 Alan Modra <amodra@gmail.com>
1324
1325 * elflink.c (_bfd_elf_merge_symbol): Use local var holding value
1326 of *sym_hash.
1327
191c0c42
AM
13282013-03-25 Alan Modra <amodra@gmail.com>
1329
1330 * elflink.c (_bfd_elf_merge_symbol): Don't discard TLS symbols here.
1331 Wrap long lines.
1332 (elf_link_add_object_symbols): Discard TLS symbols for --just-syms
1333 early in symbol loop.
1334
5d13b3b3
AM
13352013-03-25 Alan Modra <amodra@gmail.com>
1336
1337 * elf-bfd.h (struct elf_backend_data <merge_symbol>): Update proto.
1338 (_bfd_elf_init_reloc_shdr): Delete.
1339 * elf.c (_bfd_elf_init_reloc_shdr): Make static.
1340 * elf64-x86-64.c (elf_x86_64_merge_symbol): Trim parameters to
1341 just what is needed.
1342 * elflink.c (_bfd_elf_merge_symbol): Update bed->merge_symbol call.
1343
8a56bd02
AM
13442013-03-23 Alan Modra <amodra@gmail.com>
1345
1346 * elf-bfd.h (_bfd_elf_merge_symbol): Delete declaration.
1347 * elflink.c (_bfd_elf_merge_symbol): Make static.
1348 * elf32-sh-symbian.c (sh_symbian_relocate_section): Don't call
1349 _bfd_elf_merge_symbol, call _bfd_generic_link_add_one_symbol.
1350
96f29d96
AM
13512013-03-23 Alan Modra <amodra@gmail.com>
1352
1353 PR ld/15270
1354 * elflink.c (elf_link_add_object_symbols): Don't set def_regular
1355 or ref_regular for BFD_PLUGIN owned syms, or have them affect
1356 def_dynamic/ref_dynamic.
1357 (_bfd_elf_fix_symbol_flags): Don't set def_regular for BFD_PLUGIN
1358 owned syms.
1359
209be8d2
DM
13602013-03-22 David S. Miller <davem@davemloft.net>
1361
1362 * elfxx-sparc.c (_bfd_sparc_elf_merge_private_bfd_data): Set type of
1363 hwcaps attribute.
1364
5c0df484
NC
13652013-03-22 Achille Fouilleul <achille.fouilleul+binutils@gadz.org>
1366
1367 PR ld/14902
1368 * elf32-h8300.c (elf32_h8_relax_delete_bytes): Fix off by one
1369 errors adjusting relocs and symbols.
1370
81f5558e
NC
13712013-03-21 Michael Schewe <michael.schewe@gmx.net>
1372
1373 * elf32-h8300 (h8_relax_section): Add new relaxation of mov
1374 @(disp:32,ERx) to mov @(disp:16,ERx).
1375 (R_H8_DISP32A16): New reloc.
1376 Comments added and corrected.
1377 * reloc.c (BFD_RELOC_H8_DISP32A16): New reloc.
1378 * bfd-in2.h: Regenerate.
1379 * libbfd.h: Regenerate.
1380
ce63b7b3
KT
13812013-03-21 Kai Tietz <ktietz@redhat.com>
1382
1383 * coffgen.c (coff_real_object_p): Make global.
1384 * peicode.h (coff_real_object_p): Add prototype.
1385 (FILHDR): Defined for COFF_IMAGE_WITH_PE as
1386 external_PEI_IMAGE_hdr structure.
1387 (coff_swap_filehdr_in): Handle variable header-size.
1388 * peXXigen.c (_bfd_XXi_swap_aouthdr_in): Just handle amount
1389 of directory-entiries as specified in pe-header.
1390
088ca6c1
NC
13912013-03-21 Nick Clifton <nickc@redhat.com>
1392
1393 PR sim/15286
1394 * elf32-arm.c (bfd_arm_get_mach_from_attributes): Identify XScale,
1395 iWMMXt and iWMMXt2 processors from attributes.
1396
8877b5e5
AM
13972013-03-20 Alan Modra <amodra@gmail.com>
1398
1399 * elflink.c (_bfd_elf_make_dynamic_reloc_section): Override
1400 sh_type according to is_rela.
1401
ffa9430d
AM
14022013-03-18 Alan Modra <amodra@gmail.com>
1403
1404 PR ld/12549
1405 * elflink.c (elf_link_add_object_symbols): Exclude weak refs when
1406 considering whether an --as-needed library is needed.
1407
cc0ea93c
TT
14082013-03-14 Tom Tromey <tromey@redhat.com>
1409
1410 * opncls.c (bfd_get_debug_link_info): Rename from
1411 get_debug_link_info. Export. Update comment.
1412 (find_separate_debug_file): Update.
1413 * bfd-in2.h: Rebuild.
1414
59c108f7
NC
14152013-03-08 Venkataramanan Kumar <venkataramanan.kumar@linaro.org>
1416
a22cd6f6 1417 * elf64-aarch64.c (elf_backend_can_gc_sections): Enable gc-section
59c108f7 1418 support.
a22cd6f6 1419 (elf64_aarch64_gc_sweep_hook): Handle GOT, TLS and PLT related
59c108f7
NC
1420 relocs.
1421
abb3f6cc
NC
14222013-03-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
1423
1424 * elf-bfd.h (elfcore_write_s390_tdb): Add prototype.
1425 * elf.c (elfcore_write_s390_tdb): New function.
1426 (elfcore_write_register_note): Call it.
1427 (elfcore_grok_s390_tdb): New function.
1428 (elfcore_grok_note): Call it.
1429
af924177
MR
14302013-03-08 Maciej W. Rozycki <macro@codesourcery.com>
1431
1432 * elfxx-mips.c (mips_elf_allocate_lazy_stub): Correct data type.
1433
48385e38
CV
14342013-03-05 Corinna Vinschen <vinschen@redhat.com>
1435
1436 * config.bfd: Add x86_64-*-cygwin to list of supported targets.
1437
f75e0e33
AM
14382013-03-04 Alan Modra <amodra@gmail.com>
1439
1440 * elf32-ppc.c (ppc_elf_relocate_section <R_PPC_PLTREL24>): Adjust
1441 non-zero addends when relocatable, rather than addends >= 32768.
1442 Always zero "addend" before applying relocation.
1443
17e3916e
NC
14442013-03-04 Nick Clifton <nickc@redhat.com>
1445
1446 * archive64.c (bfd_elf64_archive_write_armap): Fix calculation of
1447 file pointer offsets for thin archives.
1448
3064e1ff
JB
14492013-02-28 Nathan Sidwell <nathan@codesourcery.com>
1450
1451 * elf32-arm.c (elf32_arm_size_dynamic_sections): Don't call
1452 elf32_arm_allocate_dynrelocs for source reloc for non-dynamic link.
1453
4107ae22
DD
14542013-02-27 DJ Delorie <dj@redhat.com>
1455
1456 * reloc.c (BFD_RELOC_RL78_CODE): Add.
1457 * libbfd.h: Regenerate.
1458 * bfd-in2.h: Regenerate.
1459 * elf32-rl78.c (rl78_elf_relocate_section): Handle weak code
1460 references in compuated relocs.
1461
730fbaf8
AG
14622013-02-26 Anthony Green <green@moxielogic.com>
1463
1464 * config.bfd: Extend moxie-rtems target triplet name support.
1465
35399224
L
14662013-02-21 H.J. Lu <hongjiu.lu@intel.com>
1467
1468 PR ld/15167
1469 * elf64-ia64-vms.c (elf64_vms_link_add_object_symbols): Set
1470 unique_global only for definition.
1471 * elflink.c (_bfd_elf_merge_symbol): Don't set unique_global
1472 here.
1473 (elf_link_add_object_symbols): Set unique_global only
1474 for definition.
1475
c0355132
AM
14762013-02-21 Alan Modra <amodra@gmail.com>
1477
1478 * elf-bfd.h (struct elf_build_id): Extracted from..
1479 (struct elf_build_id_info): ..here. Delete.
1480 (struct output_elf_obj_tdata): New, extracted from..
1481 (struct elf_obj_tdata): ..here. Reorganize for better packing.
1482 Add "o" field.
1483 (elf_program_header_size): Reference tdata->o.
1484 (elf_seg_map, elf_next_file_pos, elf_eh_frame_hdr, elf_linker,
1485 elf_stack_flags, elf_shstrtab, elf_strtab_sec, elf_shstrtab_sec,
1486 elf_section_syms, elf_num_section_syms, elf_flags_init): Likewise.
1487 * elf.c (bfd_elf_allocate_object): Allocate output_elf_obj_tdata
1488 when opening bfd in any mode that might write.
1489 (_bfd_elf_write_object_contents): Use build_id field in
1490 output_elf_obj_tdata.
1491 (_bfd_elf_close_and_cleanup): Tweak elf_shstrtab test.
1492 (elfobj_grok_gnu_build_id): Adjust for elf_tdata changes.
1493
228e534f
AM
14942013-02-21 Alan Modra <amodra@gmail.com>
1495
1496 * elf-bfd.h (struct core_elf_obj_tdata): New.
1497 (struct elf_obj_tdata): Delete core_signal, core_pid, core_lwpid,
1498 core_program, and core_command. Add "core".
1499 * elf.c (bfd_elf_mkcorefile): Allocate "core" struct.
1500 Update all refs to tdata core fields.
1501 * elf32-am33lin.c, * elf32-arm.c, * elf32-cris.c, * elf32-frv.c,
1502 * elf32-hppa.c, * elf32-i386.c, * elf32-m68k.c, * elf32-mips.c,
1503 * elf32-nios2.c, * elf32-ppc.c, * elf32-s390.c, * elf32-score.c,
1504 * elf32-score7.c, * elf32-sh.c, * elf32-sparc.c, * elf32-tilegx.c,
1505 * elf32-tilepro.c, * elf32-xtensa.c, * elf64-aarch64.c,
1506 * elf64-hppa.c, * elf64-mips.c, * elf64-ppc.c, * elf64-tilegx.c,
1507 * elf64-x86-64.c, * elfcore.h, * elfn32-mips.c: Update all refs
1508 to tdata core fields.
1509
12bd6957
AM
15102013-02-21 Alan Modra <amodra@gmail.com>
1511
1512 * elf-bfd.h (struct elf_obj_tdata): Rename segment_map to seg_map.
1513 Delete num_locals and num_globals.
1514 (elf_num_locals, elf_num_globals): Don't define.
1515 (elf_seg_map, elf_next_file_pos, elf_eh_frame_hdr, elf_linker,
1516 elf_stack_flags, elf_strtab_sec, elf_shstrtab_sec): Define.
1517 * bfd.c, * elf-eh-frame.c, * elf-nacl.c, * elf-vxworks.c, * elf.c,
1518 * elf32-arm.c, * elf32-lm32.c, * elf32-ppc.c, * elf32-rx.c,
1519 * elf32-spu.c, * elf64-hppa.c, * elfcode.h, * elflink.c,
1520 * elfnn-ia64.c, * elfxx-mips.c: Use newly defined elf_obj_tdata
1521 accessor macros.
1522 * elf.c (elf_map_symbols): Add pnum_locals param. Return
1523 number of locals syms via new param.
1524 (swap_out_syms): Adjust to suit elf_map_symbols change.
1525
cbf8d970
MR
15262013-02-19 Maciej W. Rozycki <macro@codesourcery.com>
1527
1528 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Also clear
1529 STO_MICROMIPS annotation.
1530
30e8ee25
AM
15312013-02-19 Alan Modra <amodra@gmail.com>
1532
1533 * configure.in: Bump version to 2.23.52.
1534 * elf-bfd.h (struct elf_build_id_info): New.
1535 (struct elf_obj_tdata): Delete after_write_object_contents,
1536 after_write_object_contents_info and build_id_size. Make build_id
1537 a pointer to struct elf_build_id_info.
1538 * elf.c (_bfd_elf_write_object_contents): Style. Update
1539 after_write_ibject_contents invocation.
1540 (elfobj_grok_gnu_build_id): Update for new build_id struct. Don't
1541 allow zero size notes.
1542 * configure: Regenerate.
1543
5b175e56
MR
15442013-02-18 Maciej W. Rozycki <macro@codesourcery.com>
1545
1546 * elf64-mips.c (micromips_elf64_howto_table_rel): Add
1547 R_MICROMIPS_SCN_DISP and R_MICROMIPS_JALR.
1548 (micromips_elf64_howto_table_rela): Likewise.
1549 (micromips_reloc_map): Add BFD_RELOC_MICROMIPS_JALR.
1550 * elfn32-mips.c (elf_micromips_howto_table_rel): Add
1551 R_MICROMIPS_SCN_DISP and R_MICROMIPS_JALR.
1552 (elf_micromips_howto_table_rela): Likewise.
1553 (micromips_reloc_map): Add BFD_RELOC_MICROMIPS_JALR.
1554
e8faf7d1
MR
15552013-02-18 Paul Brook <paul@codesourcery.com>
1556
1557 * elfxx-mips.c (MICROMIPS_P): New macro.
1558 (_bfd_mips_elf_symbol_processing): Use it.
1559
c164a95d
MR
15602013-02-18 Maciej W. Rozycki <macro@codesourcery.com>
1561
1562 * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Clarify
1563 comment on _PROCEDURE_LINKAGE_TABLE_ creation.
1564
d45f8bda
AM
15652013-02-18 Alan Modra <amodra@gmail.com>
1566
1567 PR ld/12549
1568 * elf-bfd.h (_bfd_elf_strtab_clear_refs): Delete.
1569 (_bfd_elf_strtab_clear_all_refs): Declare.
1570 (_bfd_elf_strtab_resize): Declare.
1571 * elf-strtab.c (_bfd_elf_strtab_clear_refs): Delete.
1572 (_bfd_elf_strtab_clear_all_refs): New function.
1573 (_bfd_elf_strtab_resize): Likewise.
1574 * elflink.c (elf_link_add_object_symbols): Use _bfd_elf_strtab_resize.
1575
698600e4
AM
15762013-02-18 Alan Modra <amodra@gmail.com>
1577
1578 * elf-bfd.h (struct elf_obj_tdata): Move find_line_info, local_stubs,
1579 local_call_stubs, elf_data_symbol, elf_text_symbol, elf_data_section,
1580 and elf_text_section to..
1581 * elfxx-mips.c (struct mips_elf_obj_tdata): ..here. Update all refs.
1582 * elf64-alpha.c (struct mips_elf_find_line): Rename to..
1583 (struct alpha_elf_find_line): ..this.
1584 (struct alpha_elf_obj_tdata): Add find_line_info, update refs.
1585
3d5bef4c
L
15862013-02-16 H.J. Lu <hongjiu.lu@intel.com>
1587
1588 PR ld/15146
1589 * elflink.c (elf_link_add_object_symbols): Don't add DT_NEEDED
1590 for references from the dummy bfd.
1591
313ed4a9
L
15922013-02-16 H.J. Lu <hongjiu.lu@intel.com>
1593
1594 PR ld/15149
1595 * elflink.c (elf_link_add_object_symbols): Also track weak
1596 references.
1597
989fbeff
L
15982013-02-15 H.J. Lu <hongjiu.lu@intel.com>
1599
1600 PR binutils/15151
1601 * archive.c (_bfd_find_nested_archive): Don't allow a nested
1602 archive pointing to itself.
1603 (_bfd_get_elt_at_filepos): Revert the last 2 changes.
1604
a043396b
NC
16052013-02-15 Nick Clifton <nickc@redhat.com>
1606
1607 PR binutils/15140
1608 * archive.c (_bfd_get_elt_at_filepos): Prevent an infinite loop
1609 accessing a corrupt nested archive.
1610
13db6b44
RS
16112013-02-13 Richard Sandiford <rdsandiford@googlemail.com>
1612
1613 * elfxx-mips.c (mips_got_page_ref): New structure.
1614 (mips_got_page_entry): Use a section rather than a (bfd, symndx)
1615 pair to represent the anchor point.
1616 (mips_got_info): Add a got_page_refs field.
1617 (mips_elf_link_hash_table): Add a sym_cache field.
1618 (mips_got_page_ref_hash, mips_got_page_ref_eq): New functions.
1619 (mips_got_page_entry_hash, mips_got_page_entry_eq): Update for
1620 new anchor representation.
1621 (mips_elf_create_got_info): Create got_page_refs rather than
1622 got_page_entries.
1623 (mips_elf_record_got_page_ref): New function.
1624 (mips_elf_pages_for_range): Move further down file.
1625 (mips_elf_record_got_page_entry): Likewise. Take a got as argument.
1626 Use a section rather than a (bfd, symndx) pair to represent the
1627 anchor point.
1628 (mips_elf_resolve_got_page_ref): New function.
1629 (mips_elf_resolve_final_got_entries): Use it to populate
1630 got_page_entries.
1631 (_bfd_mips_elf_check_relocs): Call mips_elf_record_got_page_ref
1632 rather than mips_elf_record_got_page_entry. Only nullify h
1633 afterwards.
1634 (mips_elf_lay_out_got): Call mips_elf_resolve_final_got_entries
1635 earlier.
1636
57093f5e
RS
16372013-02-12 Richard Sandiford <rdsandiford@googlemail.com>
1638
1639 * elfxx-mips.c (mips_elf_lay_out_got): Count VxWorks GOT relocs
1640 in g->relocs.
1641
9c3f90c4
AM
16422013-02-12 Alan Modra <amodra@gmail.com>
1643
1644 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Provide
1645 suitable definition when using generic linker hash table.
1646
476366af
RS
16472013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1648
1649 * elfxx-mips.c (mips_elf_count_got_entries): Delete.
1650 (mips_elf_check_recreate_got, mips_elf_recreate_got): Take a
1651 mips_elf_traverse_got_arg. Count GOT entries.
1652 (mips_elf_resolve_final_got_entries): Take the bfd_link_info
1653 as argument. Update after above changes.
1654 (mips_elf_merge_got, mips_elf_lay_out_got): Don't call
1655 mips_elf_count_got_entries. Update the calls to
1656 mips_elf_resolve_final_got_entries.
1657
9ab066b4
RS
16582013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1659
1660 * elfxx-mips.c (mips_got_tls_type): New enum.
1661 (mips_got_entry): Add tls_initialized.
1662 (mips_elf_got_entry_hash, mips_elf_got_entry_eq, mips_tls_got_relocs)
1663 (mips_elf_count_got_entry, mips_elf_initialize_tls_index): Remove
1664 GOT_TLS_TYPE masks.
1665 (mips_elf_reloc_tls_type, mips_tls_got_entries)
1666 (mips_elf_record_global_got_symbol, mips_elf_initialize_tls_index)
1667 (_bfd_mips_elf_finish_dynamic_symbol): Use GOT_TLS_NONE rather
1668 than GOT_NORMAL.
1669 (mips_elf_initialize_tls_slots): Replace got_offset and tls_type_p
1670 arguments with a GOT entry. Remove GOT_TLS_TYPE masks. Use
1671 tls_initialized rather than GOT_TLS_DONE.
1672 (mips_tls_got_index): Delete.
1673 (mips_elf_local_got_index, mips_elf_global_got_index): Use
1674 mips_elf_initialize_tls_slots rather than mips_tls_got_index.
1675 (mips_elf_record_got_entry): Initialize tls_initialized.
1676
6c42ddb9
RS
16772013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1678
1679 * elfxx-mips.c (mips_got_entry): Remove tls_ldm_offset.
1680 (mips_elf_link_hash_entry): Remove tls_ie_type, tls_gd_type,
1681 tls_ie_got_offset and tls_gd_got_offset.
1682 (mips_elf_link_hash_newfunc): Remove initialization.
1683 (mips_elf_create_got_info): Likewise.
1684 (mips_elf_count_local_got_entries, mips_elf_count_global_tls_entries)
1685 (mips_tls_single_got_index): Delete.
1686 (mips_elf_local_got_index): Always use the GOT entry to track
1687 GOT indices.
1688 (mips_elf_global_got_index): Likewise.
1689 (mips_elf_create_local_got_entry): Assert that TLS entries have
1690 already been allocated.
1691 (mips_elf_record_global_got_symbol): Don't initialize
1692 tls_ie_type or tls_gd_type.
1693 (mips_elf_count_got_symbols): Only count reloc-only GOT entries here.
1694 (mips_elf_initialize_tls_index): Allocate a GOT index for every TLS
1695 entry.
1696 (mips_elf_lay_out_got): Use mips_elf_count_got_entries to count
1697 the GOT entries.
1698 (_bfd_mips_elf_finish_dynamic_symbol): Assert that TLS GOT offsets
1699 have been allocated.
1700 (_bfd_mips_elf_copy_indirect_symbol): Remove handling of
1701 tls_ie_type and tls_gd_type.
1702
ebc53538
RS
17032013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1704
1705 * elfxx-mips.c (mips_elf_create_local_got_entry): Tidy. Avoid
1706 aliasing violation. Check for htab allocation failures.
1707
13fbec83
RS
17082013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1709
1710 * elfxx-mips.c (mips_elf_primary_global_got_index): New function,
1711 split out from...
1712 (mips_elf_global_got_index): ...here. Reorder arguments so that
1713 the output bfd and info come first.
1714 (mips_elf_calculate_relocation): Update the call to
1715 mips_elf_global_got_index accordingly.
1716 (_bfd_mips_elf_finish_dynamic_symbol): Use
1717 mips_elf_primary_global_got_index rather than
1718 mips_elf_global_got_index.
1719 (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
1720
3dff0dd1
RS
17212013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1722
1723 * elfxx-mips.c (mips_got_entry): Update comments.
1724 (mips_elf_multi_got_entry_eq): Rename to...
1725 (mips_elf_got_entry_eq): ...this, deleting the old definition.
1726 (mips_elf_create_got_info): Remove master_got_p argument.
1727 Always use mips_elf_got_entry_eq.
1728 (mips_elf_bfd_got, mips_elf_multi_got, mips_elf_create_got_section):
1729 Update calls accordingly.
1730
d7206569
RS
17312013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1732
1733 * elfxx-mips.c (mips_got_info): Remove bfd2got.
1734 (mips_elf_bfd2got_hash): Delete.
1735 (mips_elf_got_per_bfd_arg): Remove bfd2got.
1736 (mips_elf_replace_bfd_got, mips_elf_count_got_entries): New functions.
1737 (mips_elf_global_got_index, mips_elf_create_local_got_entry): Use
1738 g->next to test for the multigot case. Use mips_elf_bfd_got rather
1739 than mips_elf_got_for_ibfd.
1740 (mips_elf_bfd2got_entry_hash, mips_elf_bfd2got_entry_eq)
1741 (mips_elf_got_for_ibfd, mips_elf_get_got_for_bfd): Delete.
1742 (mips_elf_make_got_per_bfd): Replace with...
1743 (mips_elf_add_got_entry): ...this new function.
1744 (mips_elf_make_got_pages_per_bfd): Replace with...
1745 (mips_elf_add_got_page_entry): ...this new function.
1746 (mips_elf_merge_got_with): Replace bfd2got argument with separate
1747 bfd and GOT arguments. Use mips_elf_add_got_entry and
1748 mips_elf_add_got_page_entry instead of mips_elf_make_got_per_bfd
1749 and mips_elf_make_got_pages_per_bfd. Use mips_elf_replace_bfd_got
1750 to set the BFD's GOT and free the old table.
1751 (mips_elf_merge_got): Replace bfd2got argument with separate
1752 bfd and GOT arguments. Apply mips_elf_resolve_final_got_entries.
1753 Use mips_elf_count_got_entries to count the number of entries in
1754 each GOT. Update the calls to mips_elf_merge_got_with.
1755 (mips_elf_adjust_gp): Use g->next to test for the multigot case.
1756 Use mips_elf_bfd_got rather than mips_elf_got_for_ibfd.
1757 (mips_elf_multi_got): Don't create the bfd2got hash table.
1758 Replace hash table traversal with a walk over the input bfds,
1759 updating the call to mips_elf_merge_got. Use mips_elf_replace_bfd_got
1760 to set the output bfd's GOT.
1761 (mips_elf_lay_out_got): Rename "sub" to "ibfd". Record that all
1762 bfds use the master GOT in the single-GOT case.
1763 (_bfd_mips_elf_finish_dynamic_sections): Use mips_elf_bfd_got
1764 rather than mips_elf_got_for_ibfd.
1765
ee227692
RS
17662013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1767
1768 * elfxx-mips.c (mips_elf_obj_tdata): Add a got field.
1769 (mips_elf_bfd_got, mips_elf_record_got_entry): New functions.
1770 (mips_elf_record_global_got_symbol): Update the hash entry before
1771 adding the mips_got_entry. Use mips_elf_record_got_entry to do
1772 the latter.
1773 (mips_elf_record_local_got_symbol): Use mips_elf_record_got_entry.
1774 (mips_elf_record_got_page_entry): Record the entry in both the
1775 master and bfd GOTs.
1776
72e7511a
RS
17772013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1778
1779 * elfxx-mips.c (mips_elf_recreate_got): Don't change the entry;
1780 create another one if necessary.
1781 (mips_elf_set_gotidx): New function.
1782 (mips_elf_set_global_gotidx): Use it.
1783 (mips_elf_initialize_tls_index): Likewise. Take a
1784 mips_elf_traverse_got_arg as argument.
1785 (mips_elf_lay_out_got): Update use of mips_elf_initialize_tls_index.
1786 (mips_elf_multi_got): Likewise. Cope with error returns from
1787 mips_elf_set_global_gotidx.
1788
ab361d49
RS
17892013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1790
1791 * elfxx-mips.c (mips_got_info): Add relocs field.
1792 (mips_elf_set_global_got_offset_arg, mips_elf_count_tls_arg): Replace
1793 with...
1794 (mips_elf_traverse_got_arg): ...this new structure.
1795 (mips_elf_count_local_tls_relocs): Delete.
1796 (mips_elf_count_global_tls_relocs): Likewise.
1797 (mips_elf_count_got_entry): New function.
1798 (mips_elf_count_local_got_entries): Likewise.
1799 (mips_elf_count_global_tls_entries): Take a mips_elf_traverse_got_arg
1800 rather than a mips_elf_count_tls_arg. Count both relocs and entries.
1801 (mips_elf_record_local_got_symbol): Don't count got entries here.
1802 (mips_elf_make_got_per_bfd): Use mips_elf_count_got_entry.
1803 (mips_elf_set_global_got_offset): Split into...
1804 (mips_elf_set_global_got_area, mips_elf_set_global_gotidx): ...these
1805 new functions. Take a mips_elf_traverse_got_arg rather than a
1806 mips_elf_set_global_got_offset_arg. Don't count TLS relocs here.
1807 Use g->relocs to record the number of relocs needed for global GOT
1808 entries.
1809 (mips_elf_multi_got): Use mips_elf_traverse_got_arg rather than
1810 mips_elf_set_global_got_offset_arg. Use the relocs field to count
1811 relocations. Update for above function split.
1812 (mips_elf_lay_out_got): Use mips_elf_count_local_got_entries
1813 to count both the number of GOT entries and the number of TLS
1814 relocs required by local entries. Likewise
1815 mips_elf_count_global_tls_entries and global entries.
1816 Remove uses of mips_elf_count_local_tls_relocs and
1817 mips_elf_count_global_tls_relocs.
1818
e641e783
RS
18192013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1820
1821 * elfxx-mips.c (mips_got_entry): Update comment above tls_type entry
1822 to say that each structure represents only one type of TLS reference.
1823 (GOT_TLS_TYPE): New define.
1824 (mips_elf_link_hash_entry): Temporarily split tls_type and
1825 tls_got_offset into two variables each.
1826 (mips_elf_link_hash_newfunc): Update accordingly.
1827 (mips_elf_got_entry_eq, mips_elf_got_entry_hash)
1828 (mips_elf_multi_got_entry_eq): Require the tls_type to be the same.
1829 (mips_elf_reloc_tls_type, mips_tls_got_entries): New functions.
1830 (mips_tls_got_relocs): Use a switch statement.
1831 (mips_elf_count_global_tls_entries): Handle the new hash entry fields.
1832 (mips_elf_initialize_tls_slots): Use a switch statement. Avoid
1833 local "offset" variable.
1834 (mips_tls_got_index): Remove r_type argument and assert. Remove
1835 code that handled entries with two TLS types; always use the
1836 original got_index instead.
1837 (mips_tls_single_got_index): New function.
1838 (mips_elf_local_got_index): Use entry->tls_type to check for
1839 TLS entries. Use mips_tls_single_got_index. Update call to
1840 mips_tls_got_index.
1841 (mips_elf_global_got_index): Use mips_elf_reloc_tls_type.
1842 Use p->tls_type to check for TLS entries. Update call to
1843 mips_tls_got_index. Use mips_tls_single_got_index.
1844 (mips_elf_create_local_got_entry): Use mips_elf_reloc_tls_type.
1845 Use entry.tls_type to check for TLS entries.
1846 (mips_elf_record_global_got_symbol): Replace tls_flag argument
1847 with r_type argument. Use mips_elf_reloc_tls_type.
1848 Set up the new hash entry fields.
1849 (mips_elf_record_local_got_symbol): Replace tls_flag argument
1850 with r_type argument. Use mips_elf_reloc_tls_type and
1851 mips_tls_got_entries. Remove code that handled entries
1852 with multiple TLS types.
1853 (mips_elf_make_got_per_bfd): Use mips_tls_got_entries.
1854 (mips_elf_initialize_tls_index): Handle new hash entry fields.
1855 Use equality rather than masks when checking for specific TLS types.
1856 Use mips_tls_got_entries. Remove code that handled entries
1857 with multiple TLS types.
1858 (mips_elf_calculate_relocation): Use TLS_RELOC_P instead of
1859 testing the hash table entry.
1860 (_bfd_mips_elf_check_relocs): Update calls to
1861 mips_elf_record_global_got_symbol and mips_elf_record_local_got_symbol.
1862 (_bfd_mips_elf_finish_dynamic_symbol): Don't check h->type.
1863 (_bfd_mips_elf_copy_indirect_symbol): Handle new hash entry fields.
1864
d9bf376d
RS
18652013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1866
1867 * elfxx-mips.c (mips_elf_multi_got_entry_hash): Rename to...
1868 (mips_elf_got_entry_hash): ...this, deleting the old version.
1869 (mips_elf_create_got_info): Use mips_elf_got_entry_hash for
1870 both types of GOT.
1871
5334aa52
RS
18722013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1873
1874 * elfxx-mips.c (mips_elf_create_got_info): New function.
1875 (mips_elf_get_got_for_bfd, mips_elf_multi_got): Use it.
1876 (mips_elf_create_got_section): Likewise.
1877
946c668d
RS
18782013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1879
1880 * elfxx-mips.c (mips_elf_record_local_got_symbol): Always set
1881 gotidx to -1.
1882
59b08994
RS
18832013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1884
1885 * elfxx-mips.c (mips_elf_multi_got): Simplify size calculation.
1886
d222d210
RS
18872013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1888
1889 * elfxx-mips.c (mips_got_info): Move global_gotsym to...
1890 (mips_elf_link_hash_table): ...here. Update rest of file accordingly.
1891
1fd20d70
RS
18922013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1893
1894 * elfxx-mips.c (mips_elf_count_global_tls_entries)
1895 (mips_elf_count_global_tls_relocs): Don't count indirect or
1896 warning symbols.
1897 (mips_elf_multi_got, mips_elf_lay_out_got): Assert that the right
1898 number of TLS entries were allocated.
1899
7d94b319
RS
19002013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1901
1902 * elfxx-mips.c (mips_elf_sort_hash_table_f): Remove asserts.
1903
17214937
RS
19042013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1905
1906 * elfxx-mips.c (mips_elf_merge_got_with): Only use arg->global_count
1907 if there are TLS relocations.
1908
9efeb38d
RS
19092013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
1910
1911 * elfxx-mips.c (mips_elf_recreate_got): Remove free.
1912 (mips_elf_resolve_final_got_entries): Remove bogus comment.
1913
9c3f90c4
AM
19142013-02-11 Alan Modra <amodra@gmail.com>
1915
1916 * elfcode.h (elf_checksum_contents): Free contents.
1917 * elf-bfd.h (_bfd_elf_link_hash_table_free): Declare.
1918 * elflink.c (_bfd_elf_link_hash_table_free): New function.
1919 (elf_final_link_free): New function, extracted from..
1920 (bfd_elf_final_link): ..here. Always call
1921 _bfd_elf_write_section_eh_frame_hdr.
1922 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Default to
1923 _bfd_elf_link_hash_table_free.
1924 * libbfd-in.h (_bfd_merge_sections_free): Declare.
1925 * libbfd.h: Regenerate.
1926 * merge.c (_bfd_merge_sections_free): New function.
1927 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame_hdr): Free
1928 hdr_info->array.
1929 * elf-m10300.c (elf32_mn10300_link_hash_table_free): Call
1930 _bfd_elf_link_hash_table_free.
1931 * elf32-arm.c (elf32_arm_link_hash_table_free): Likewise.
1932 * elf32-avr.c (elf32_avr_link_hash_table_free): Likewise.
1933 * elf32-hppa.c (elf32_hppa_link_hash_table_free): Likewise.
1934 * elf32-i386.c (elf_i386_link_hash_table_free): Likewise.
1935 * elf32-m68hc1x.c (m68hc11_elf_hash_table_free): Likewise.
1936 * elf32-m68k.c (elf_m68k_link_hash_table_free): Likewise.
1937 * elf32-metag.c (elf_metag_link_hash_table_free): Likewise.
1938 * elf32-xgate.c (xgate_elf_bfd_link_hash_table_free): Likewise.
1939 * elf64-aarch64.c (elf64_aarch64_link_hash_table_free): Likewise.
1940 * elf64-ia64-vms.c (elf64_ia64_hash_table_free): Likewise.
1941 * elf64-ppc.c (ppc64_elf_link_hash_table_free): Likewise.
1942 * elf64-x86-64.c (elf_x86_64_link_hash_table_free): Likewise.
1943 * elfnn-ia64.c (elfNN_ia64_hash_table_free): Likewise.
1944 * elf32-cr16.c (elf32_cr16_link_hash_table_free): Delete.
1945 (bfd_elf32_bfd_link_hash_table_free): Don't define.
1946 * elf32-tic6x.c (elf32_tic6x_link_hash_table_free): Delete.
1947 (bfd_elf32_bfd_link_hash_table_free): Dont' define.
1948
7bf52ea2
AM
19492013-02-10 Alan Modra <amodra@gmail.com>
1950
1951 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_zmalloc.
1952 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
1953 * m68klinux.c (linux_link_hash_table_create): Likewise.
1954 * sparclinux.c (linux_link_hash_table_create): Likewise.
1955 * sunos.c (sunos_link_hash_table_create): Likewise.
1956 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
1957 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
1958 * elf32-arm.c (elf32_arm_link_hash_table_create): Likewise.
1959 * elf32-avr.c (elf32_avr_link_hash_table_create): Likewise.
1960 * elf32-cr16.c (elf32_cr16_link_hash_table_create): Likewise.
1961 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
1962 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
1963 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
1964 * elf32-lm32.c (lm32_elf_link_hash_table_create): Likewise.
1965 * elf32-m32r.c (m32r_elf_link_hash_table_create): Likewise.
1966 * elf32-m68hc1x.c (m68hc11_elf_hash_table_create): Likewise.
1967 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
1968 * elf32-metag.c (elf_metag_link_hash_table_create): Likewise.
1969 * elf32-nios2.c (nios2_elf32_link_hash_table_create): Likewise.
1970 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
1971 * elf32-score.c (elf32_score_link_hash_table_create): Likewise.
1972 * elf32-spu.c (spu_elf_link_hash_table_create): Likewise.
1973 * elf32-tic6x.c (elf32_tic6x_link_hash_table_create): Likewise.
1974 * elf32-vax.c (elf_vax_link_hash_table_create): Likewise.
1975 * elf32-xgate.c (xgate_elf_bfd_link_hash_table_create): Likewise.
1976 * elf32-xtensa.c (elf_xtensa_link_hash_table_create): Likewise.
1977 * elf64-aarch64.c (elf64_aarch64_link_hash_table_create): Likewise.
1978 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
1979 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
1980 * elf64-x86-64.c (elf_x86_64_link_hash_table_create): Likewise.
1981 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
1982 * elflink.c (_bfd_elf_link_hash_table_create): Likewise.
1983 (_bfd_elf_link_hash_table_init): Assume zero fill table on entry.
1984
22cdc249
AM
19852013-02-10 Alan Modra <amodra@gmail.com>
1986
1987 * i386linux.c (linux_link_hash_table_create): Allocate table
1988 with bfd_zmalloc, not bfd_alloc.
1989 * pdp11.c (link_hash_table_create): Allocate table with
1990 bfd_malloc, not bfd_alloc.
1991 * elf32-bfin.c (bfinfdpic_elf_link_hash_table_create): Allocate table
1992 with bfd_zmalloc, not bfd_zalloc.
1993 (bfin_link_hash_table_create): Likewise.
1994 * elf32-frv.c (frvfdpic_elf_link_hash_table_create): Likewise.
1995 * elf64-hppa.c (elf64_hppa_hash_table_create): Likewise.
1996
0e5de31a
AM
19972013-02-10 Alan Modra <amodra@gmail.com>
1998
1999 PR ld/15113
2000 * elf32-sh.c (sh_elf_link_hash_table_create): Use bfd_zmalloc.
2001
ad1fc92a
NC
20022013-02-08 Markos Chandras <markos.chandras@imgtec.com>
2003
2004 * elf32-metag.c: Use bfd_get_linker_section to get SEC_LINKER_CREATED
2005 sections.
34c67f14
NC
2006 (elf_metag_adjust_dynamic_symbol): Don't error on zero size dynbss
2007 symbol.
ad1fc92a 2008
170a8295
YZ
20092013-02-08 Yufeng Zhang <yufeng.zhang@arm.com>
2010
2011 * elf64-aarch64.c (elf64_aarch64_grok_prstatus): Change 'size' from
2012 288 to 272.
2013
619a703e
AM
20142013-02-08 Alan Modra <amodra@gmail.com>
2015
2016 PR binutils/15106
2017 * elf-bfd.h (struct elf_obj_tdata): Add elf_find_function_cache.
2018 * elf.c (elf_find_function): Revert last change. Use new
2019 tdata field rather than static vars for cache.
2020
02acbe22
L
20212013-02-07 H.J. Lu <hongjiu.lu@intel.com>
2022
2023 PR ld/15107
2024 * elflink.c (elf_link_output_extsym): Set STB_GNU_UNIQUE only if
2025 symbol is defined in regular object.
2026
1965d5f2
AM
20272013-02-07 Roberto Agostino Vitillo <ra.vitillo@gmail.com>
2028
2029 PR binutils/15106
2030 * elf.c (elf_find_function): Don't cache if symbols change.
2031
dafbc74d
AM
20322013-02-07 Alan Modra <amodra@gmail.com>
2033
2034 PR binutils/14873
2035 * elf-attrs.c (_bfd_elf_copy_obj_attributes): Don't attempt to
2036 copy attributes from or to non-ELF.
2037
20e52bd2
L
20382013-02-06 H.J. Lu <hongjiu.lu@intel.com>
2039
2040 * elf32-i386.c (elf_i386_allocate_dynrelocs): Don't clear pc_count
2041 for non-zero TLS symbol.
2042 (elf_i386_relocate_section): Don't resolve size relocation against
2043 non-zero TLS symbol.
2044 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Don't clear
2045 pc_count for non-zero TLS symbol.
2046 (elf_x86_64_relocate_section): Don't resolve size relocation
2047 against non-zero TLS symbol.
2048
36591ba1 20492013-02-06 Sandra Loosemore <sandra@codesourcery.com>
20e52bd2 2050 Andrew Jenner <andrew@codesourcery.com>
36591ba1
SL
2051
2052 Based on patches from Altera Corporation.
2053
2054 * Makefile.am (ALL_MACHINES): Add cpu-nios2.lo.
2055 (ALL_MACHINES_CFILES): Add cpu-nios2.c.
2056 (BFD_BACKENDS): Add elf32-nios2.lo.
2057 (BFD32_BACKENDS_CFILES): Add elf32-nios2.c.
2058 * Makefile.in: Regenerated.
2059 * configure.in: Add entries for bfd_elf32_bignios2_vec and
2060 bfd_elf32_littlenios2_vec.
2061 * configure: Regenerated.
2062 * config.bfd: Add cases for nios2.
2063 * archures.c (enum bfd_architecture): Add bfd_arch_nios2.
2064 (bfd_mach_nios2): Define.
2065 (bfd_nios2_arch): Declare.
2066 (bfd_archures_list): Add bfd_nios2_arch.
2067 * targets.c (bfd_elf32_bignios2_vec): Declare.
2068 (bfd_elf32_littlenios2_vec): Declare.
2069 (_bfd_target_vector): Add entries for bfd_elf32_bignios2_vec and
2070 bfd_elf32_littlenios2_vec.
2071 * elf-bfd.h (enum elf_target_id): Add NIOS2_ELF_DATA.
2072 * reloc.c (enum bfd_reloc_code_real): Add Nios II relocations.
2073 * bfd-in2.h: Regenerated.
2074 * libbfd.h: Regenerated.
2075 * cpu-nios2.c: New file.
2076 * elf32-nios2.c: New file.
2077
ca6b5f82
AM
20782013-02-06 Alan Modra <amodra@gmail.com>
2079
2080 * elf32-arm.c (elf32_arm_final_link_relocate): Only test for
2081 stubs in stub_bfd.
2082
37ba9f93
AM
20832013-02-06 Alan Modra <amodra@gmail.com>
2084
2085 * Makefile.am (SOURCE_HFILES): Add `elf-linux-psinfo.h'.
2086 * Makefile.in: Regenerate.
2087
70a38d42
SDJ
20882013-02-04 Sergio Durigan Junior <sergiodj@redhat.com>
2089 Pedro Alves <palves@redhat.com>
2090
2091 * Makefile.in (SOURCE_HFILES): Add `elf-linux-psinfo.h'.
2092 * elf-bfd.h (elf_internal_linux_prpsinfo): New structure
2093 declaration.
2094 (elfcore_write_linux_prpsinfo32, elfcore_write_linux_prpsinfo64)
2095 (elfcore_write_ppc32_linux_prpsinfo32): New declarations.
2096 * elf-linux-psinfo.h: New file.
2097 * elf.c: Include elf-linux-psinfo.h.
2098 (elfcore_write_linux_prpsinfo32, elfcore_write_linux_prpsinfo64):
2099 New functions.
2100 * elf32-ppc.c: Include `elf-linux-psinfo.h'.
2101 (elf_external_ppc_linux_prpsinfo32): New structure declaration.
2102 (PPC_LINUX_PRPSINFO32_SWAP_FIELDS): New macro.
2103 (elfcore_write_ppc_linux_prpsinfo32): New function.
2104
5ee43bc4
TG
21052013-02-04 Tristan Gingold <gingold@adacore.com>
2106
2107 * mach-o.c (bfd_mach_o_scan_start_address): Do not fail if no
2108 start address.
2109
0cadb185
AM
21102013-02-04 Alan Modra <amodra@gmail.com>
2111
2112 * Makefile.am (BFD64_BACKENDS): Remove elf-nacl.lo.
2113 (BFD64_BACKENDS_CFILES): Remove elf-nacl.c.
2114 * Makefile.in: Regenerate.
2115 * po/SRC-POTFILES.in: Regenerate.
2116
5d42dfb5
AM
21172013-02-04 Alan Modra <amodra@gmail.com>
2118
2119 * coff-tic54x.c (SWAP_OUT_RELOC_EXTRA): Delete.
2120 * coff-tic80.c (SWAP_OUT_RELOC_EXTRA): Delete.
2121
c57da1a7
AM
21222013-02-01 Alan Modra <amodra@gmail.com>
2123
2124 * elf64-ppc.c (dec_dynrel_count): Don't error when elf_gc_sweep_symbol
2125 clears def_regular.
2126
c0fd7846
TG
21272013-01-31 Tristan Gingold <gingold@adacore.com>
2128
2129 * mach-o.c (bfd_mach_o_scan): Call bfd_mach_o_flatten_sections
2130 earlier. Fix status checking of bfd_mach_o_scan_start_address.
2131 (bfd_mach_o_scan_start_address): Handle LC_MAIN.
2132
b45b6908
AM
21332013-01-31 Alan Modra <amodra@gmail.com>
2134 David S. Miller <davem@davemloft.net>
2135
2136 PR ld/15056
2137 * elfxx-sparc.c (_bfd_sparc_elf_gc_mark_hook): Handle implicit
2138 references to __tls_get_addr.
2139 * elf32-tilpro.c (tilepro_elf_gc_mark_hook): Likewise. Correct
2140 vtinherit and vtentry reloc handling too.
2141 * elfxx-tilegx.c (tilegx_elf_gc_mark_hook): As for tilepro.
2142
bcaa2f82
AM
21432013-01-31 Alan Modra <amodra@gmail.com>
2144
2145 * elf64-ppc.c (ppc_stub_name): Trim off trailing "+0".
2146
22aa0c7e
AM
21472013-01-31 Alan Modra <amodra@gmail.com>
2148
2149 * elf64-ppc.c (build_plt_stub): Correct plt stub branch to glink.
2150
bc30df16
AM
21512013-01-28 Alan Modra <amodra@gmail.com>
2152
2153 * elf64-ppc.c: Use %T to print symbols names and remove redundant
2154 "relocation" in error messages throughout file.
2155 (ppc64_elf_relocate_section): Remove sibling call error message,
2156 replace with "call lacks nop". Specially report errors for
2157 branches to function entry points via OPD lookup and branches
2158 to stubs. Remove NULL symbol handling now done by %T.
2159
89d7b8aa
AM
21602013-01-28 Alan Modra <amodra@gmail.com>
2161
2162 * archive.c (bfd_generic_archive_p): Return target and keep
2163 ardata on partial matches.
2164 * format.c (bfd_check_format_matches): Adjust for above
2165 change. Remove bfd_error_file_ambiguously_recognized dead
2166 code.
2167
c9ba0c87
AM
21682013-01-26 Alan Modra <amodra@gmail.com>
2169
2170 * bfd.c (struct bfd_preserve, bfd_preserve_save, bfd_preserve_restore,
2171 bfd_preserve_finish): Move to..
2172 * format.c: ..here, splitting out..
2173 (bfd_reinit): ..this. New function.
2174 (bfd_check_format_matches): Use bfd_preserve_save/restore to
2175 keep bfd state for a match.
2176 * elfcode.h (elf_object_p): Don't use bfd_preserve_save/restore.
2177 * elfcore.h (elf_core_file_p): Likewise.
2178 * mach-o.c (bfd_mach_o_header_p): Likewise.
2179 * pef.c (bfd_pef_object_p, bfd_pef_xlib_object_p): Likewise.
2180 * xsym.c (bfd_sym_object_p): Likewise.
2181 * mmo.c (mmo_scan): Clear abfd->symcount.
2182 * opncls.c (_bfd_new_bfd): Use a smaller section hash table.
2183 * section.c (bfd_section_list_clear): Clear section_htab.count.
2184 * bfd-in2.h: Regenerate.
2185
d79dcc73
NC
21862013-01-25 Michael Schewe <michael.schewe@gmx.net>
2187
2188 * elf32-h8300.c (elf32_h8_relax_section): When checking for a
2189 second reloc, make sure that the reloc potentially exists first.
2190
78c8d46c
NC
21912013-01-24 Nick Clifton <nickc@redhat.com>
2192
2193 * archures.c: Add bfd_mach_v850e3v5.
2194 * bfd-in2.h: Regenerate.
2195 * cpu-v850.c: Add entries for v850e2v5 and v850e3v5.
2196 * cpu-v850_rh850.c: Likewise.
2197 * elf32-v850.c: Add support for v850e3v5 architecture.
2198
1a18f0ae
NC
21992013-01-23 Markos Chandras <markos.chandras@imgtec.com>
2200
2201 * elf32-metag.c: Error on HIADDR16/LOADDR16 in shared link.
2202
f65a9e53
AM
22032013-01-23 Leif Ekblad <leif@rdos.net>
2204
2205 * config.bfd (x86_64-*-rdos*): Remove targ_selvecs.
2206
3bea1fcb
L
22072013-01-18 H.J. Lu <hongjiu.lu@intel.com>
2208
2209 * elf32-i386.c (elf_i386_allocate_dynrelocs): Clear pc_count for
2210 non-zero TLS symbol.
2211 (elf_i386_relocate_section): Resolve size relocation against
2212 non-zero TLS symbol.
2213 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Clear pc_count
2214 for non-zero TLS symbol.
2215 (elf_x86_64_relocate_section): Resolve size relocation against
2216 non-zero TLS symbol.
2217
b1b00fcc
MF
22182013-01-18 Mike Frysinger <vapier@gentoo.org>
2219
2220 * elflink.c (bfd_elf_size_dynamic_sections): Only add DT_RPATH
2221 when new_dtags is false. Only add DT_RUNPATH when new_dtags is
2222 true.
2223
06a6a421
L
22242013-01-17 H.J. Lu <hongjiu.lu@intel.com>
2225
2226 * elf32-i386.c (elf_i386_check_relocs): Count size relocation as
2227 PC-relative relocation.
2228 * elf64-x86-64.c (elf_x86_64_check_relocs): Count size relocation
2229 as PC-relative relocation.
2230
6a3e1bae
L
22312013-01-16 H.J. Lu <hongjiu.lu@intel.com>
2232
2233 * elf32-i386.c (elf_i386_check_relocs): Update R_386_SIZE32
2234 check.
2235 (elf_i386_relocate_section): Don't check TLS for R_386_SIZE32.
2236
2237 * elf64-x86-64.c (elf_x86_64_check_relocs): Update R_X86_64_SIZE32
2238 and R_X86_64_SIZE64 check.
2239 (elf_x86_64_relocate_section): Don't check TLS for R_X86_64_SIZE32
2240 nor R_X86_64_SIZE64.
2241
1788fc08
L
22422013-01-16 H.J. Lu <hongjiu.lu@intel.com>
2243
2244 * bfd-in2.h: Regenerated.
2245 * libbfd.h: Likewise.
2246
2247 * elf32-i386.c (elf_howto_table): Fill R_386_SIZE32 entry.
2248 (elf_i386_reloc_type_lookup): Support BFD_RELOC_SIZE32.
2249 (elf_i386_check_relocs): Handle R_386_SIZE32.
2250 (elf_i386_gc_sweep_hook): Likewise.
2251 (elf_i386_relocate_section): Likewise.
2252
2253 * elf64-x86-64.c (x86_64_elf_howto_table): Fill R_X86_64_SIZE32
2254 and R_X86_64_SIZE64 entries.
2255 (x86_64_reloc_map): Add BFD_RELOC_SIZE32 and BFD_RELOC_SIZE64,
2256 (elf_x86_64_rtype_to_howto): Handle R_X86_64_SIZE32 for x32.
2257 (elf_x86_64_reloc_name_lookup): Likewise.
2258 (elf_x86_64_check_relocs): Handle R_X86_64_SIZE32 and
2259 R_X86_64_SIZE64.
2260 (elf_x86_64_gc_sweep_hook): Likewise.
2261 (elf_x86_64_relocate_section): Likewise.
2262
2263 * reloc.c (bfd_reloc_code_type): Add BFD_RELOC_SIZE32 and
2264 BFD_RELOC_SIZE64.
2265
1e536451
L
22662013-01-15 H.J. Lu <hongjiu.lu@intel.com>
2267
2268 * elf64-x86-64.c (R_X86_64_standard): Replace R_X86_64_IRELATIVE
2269 with R_X86_64_RELATIVE64.
2270
77bf820f
NC
22712013-01-15 Nick Clifton <nickc@redhat.com>
2272
2273 * elf32-msp430.c: Fix spelling typo.
2274
e2458743
AM
22752013-01-15 Alan Modra <amodra@gmail.com>
2276
2277 * elf64-ppc.c (ppc64_elf_size_stubs): Default shared libs to
2278 plt-thread-safe.
2279
405bf443
AM
22802013-01-14 Alan Modra <amodra@gmail.com>
2281
2282 PR binutils/14813
2283 * bfdio.c (struct bfd_iovec <bclose>): Revert 2012-11-06.
2284 (memory_bclose): Likewise. Return 0 on success.
2285 * cache.c (cache_bclose): Likewise.
2286 * opncls.c (opncls_bclose, bfd_close): Likewise.
2287 * vms-lib.c (vms_lib_bclose): Likewise.
2288 * libbfd.h: Regenerate.
2289
ee659f1f
AM
22902013-01-13 Alan Modra <amodra@gmail.com>
2291
2292 * elf-bfd.h (struct elf_link_hash_entry): Delete dynamic_weak.
2293 Add ref_dynamic_nonweak.
2294 * elflink.c (_bfd_elf_mark_dynamic_def_weak): Delete.
2295 (_bfd_elf_merge_symbol): Don't call above function. Move
2296 setting of ref_dynamic_nonweak and dynamic_def earlier. Don't
2297 clear dynamic_def.
2298 (elf_link_add_object_symbols): Delete redundant "override" test.
2299 Don't set dynamic_def here.
2300 (elf_link_output_extsym): Update.
2301
68c4a57e
L
23022013-01-12 H.J. Lu <hongjiu.lu@intel.com>
2303
2304 * elf32-i386.c (elf_i386_check_relocs): Set bfd errror for
2305 normal and TLS symbol access.
2306 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
2307
02be4619
AM
23082013-01-12 Alan Modra <amodra@gmail.com>
2309
2310 * elf-bfd.h (_bfd_elf_strtab_refcount): Declare.
2311 * elf-strtab.c (_bfd_elf_strtab_refcount): New function.
2312 * elflink.c (elf_add_dt_needed_tag): Use _bfd_elf_strtab_refcount.
2313
a4542f1b
AM
23142013-01-12 Alan Modra <amodra@gmail.com>
2315
2316 PR ld/12549
2317 * elf-bfd.h (_bfd_elf_strtab_clear_refs): Declare.
2318 (_bfd_elf_strtab_clear_all_refs): Define.
2319 * elf-strtab.c (_bfd_elf_strtab_clear_refs): New function.
2320 (_bfd_elf_strtab_clear_all_refs): Delete.
2321 * elflink.c (elf_link_add_object_symbols): Clear out added
2322 strtab refs. Correct handling of warning common symbols.
2323
68ffbac6
L
23242013-01-10 H.J. Lu <hongjiu.lu@intel.com>
2325
2326 * aout0.c: Remove trailing white spaces.
2327 * archive.c: Likewise.
2328 * archures.c: Likewise.
2329 * bfd-in.h: Likewise.
2330 * bfd-in2.h: Likewise.
2331 * coff-alpha.c: Likewise.
2332 * coff-i860.c: Likewise.
2333 * coff-mips.c: Likewise.
2334 * coff-ppc.c: Likewise.
2335 * coff-tic80.c: Likewise.
2336 * coff-x86_64.c: Likewise.
2337 * coff-z80.c: Likewise.
2338 * coffcode.h: Likewise.
2339 * coffgen.c: Likewise.
2340 * cofflink.c: Likewise.
2341 * compress.c: Likewise.
2342 * corefile.c: Likewise.
2343 * cpu-arm.c: Likewise.
2344 * cpu-avr.c: Likewise.
2345 * cpu-bfin.c: Likewise.
2346 * cpu-cr16.c: Likewise.
2347 * cpu-cr16c.c: Likewise.
2348 * cpu-crx.c: Likewise.
2349 * cpu-h8300.c: Likewise.
2350 * cpu-i386.c: Likewise.
2351 * cpu-lm32.c: Likewise.
2352 * cpu-m68k.c: Likewise.
2353 * cpu-moxie.c: Likewise.
2354 * cpu-msp430.c: Likewise.
2355 * cpu-sh.c: Likewise.
2356 * cpu-xc16x.c: Likewise.
2357 * dwarf2.c: Likewise.
2358 * ecofflink.c: Likewise.
2359 * ecoffswap.h: Likewise.
2360 * elf-ifunc.c: Likewise.
2361 * elf-m10300.c: Likewise.
2362 * elf-vxworks.c: Likewise.
2363 * elf32-avr.c: Likewise.
2364 * elf32-avr.h: Likewise.
2365 * elf32-cr16.c: Likewise.
2366 * elf32-cr16c.c: Likewise.
2367 * elf32-cris.c: Likewise.
2368 * elf32-crx.c: Likewise.
2369 * elf32-frv.c: Likewise.
2370 * elf32-hppa.c: Likewise.
2371 * elf32-i860.c: Likewise.
2372 * elf32-ip2k.c: Likewise.
2373 * elf32-iq2000.c: Likewise.
2374 * elf32-m32c.c: Likewise.
2375 * elf32-m68hc1x.c: Likewise.
2376 * elf32-msp430.c: Likewise.
2377 * elf32-mt.c: Likewise.
2378 * elf32-ppc.c: Likewise.
2379 * elf32-rl78.c: Likewise.
2380 * elf32-s390.c: Likewise.
2381 * elf32-score.h: Likewise.
2382 * elf32-sh-symbian.c: Likewise.
2383 * elf32-sh.c: Likewise.
2384 * elf32-spu.c: Likewise.
2385 * elf32-tic6x.c: Likewise.
2386 * elf32-v850.c: Likewise.
2387 * elf32-xc16x.c: Likewise.
2388 * elf32-xtensa.c: Likewise.
2389 * elf64-alpha.c: Likewise.
2390 * elf64-hppa.c: Likewise.
2391 * elf64-ppc.c: Likewise.
2392 * elf64-s390.c: Likewise.
2393 * elfcore.h: Likewise.
2394 * elflink.c: Likewise.
2395 * elfxx-mips.c: Likewise.
2396 * elfxx-sparc.c: Likewise.
2397 * elfxx-tilegx.c: Likewise.
2398 * ieee.c: Likewise.
2399 * libcoff.h: Likewise.
2400 * libpei.h: Likewise.
2401 * libxcoff.h: Likewise.
2402 * linker.c: Likewise.
2403 * mach-o-i386.c: Likewise.
2404 * mach-o-target.c: Likewise.
2405 * mach-o.c: Likewise.
2406 * mach-o.h: Likewise.
2407 * mmo.c: Likewise.
2408 * opncls.c: Likewise.
2409 * pdp11.c: Likewise.
2410 * pe-x86_64.c: Likewise.
2411 * peXXigen.c: Likewise.
2412 * pef-traceback.h: Likewise.
2413 * pei-x86_64.c: Likewise.
2414 * peicode.h: Likewise.
2415 * plugin.c: Likewise.
2416 * reloc.c: Likewise.
2417 * riscix.c: Likewise.
2418 * section.c: Likewise.
2419 * som.c: Likewise.
2420 * syms.c: Likewise.
2421 * tekhex.c: Likewise.
2422 * ticoff.h: Likewise.
2423 * vaxbsd.c: Likewise.
2424 * xcofflink.c: Likewise.
2425 * xtensa-isa.c: Likewise.
2426
a3c62988
NC
24272013-01-10 Will Newton <will.newton@imgtec.com>
2428
2429 * Makefile.am: Add Meta.
2430 * Makefile.in: Regenerate.
2431 * archures.c (bfd_mach_metag): New.
2432 * bfd-in2.h: Regenerate.
2433 * config.bfd: Add Meta.
2434 * configure: Regenerate.
2435 * configure.in: Add Meta.
2436 * cpu-metag.c: New file.
2437 * elf-bfd.h: Add Meta.
2438 * elf32-metag.c: New file.
2439 * elf32-metag.h: New file.
2440 * libbfd.h: Regenerate.
2441 * reloc.c: Add Meta relocations.
2442 * targets.c: Add Meta.
2443
652451f8
YZ
24442013-01-08 Yufeng Zhang <yufeng.zhang@arm.com>
2445
2446 * elf-bfd.h (elfcore_write_aarch_tls): Add prototype.
2447 (elfcore_write_aarch_hw_break): Likewise.
2448 (elfcore_write_aarch_hw_watch): Likewise.
2449 * elf.c (elfcore_grok_aarch_tls): New function.
2450 (elfcore_grok_aarch_hw_break): Likewise.
2451 (elfcore_grok_aarch_hw_watch): Likewise.
2452 (elfcore_grok_note): Call the new functions to handle the
2453 corresponding notes.
2454 (elfcore_write_aarch_tls): New function.
2455 (elfcore_write_aarch_hw_break): Likewise.
2456 (elfcore_write_aarch_hw_watch): Likewise.
2457 (elfcore_write_register_note): Call the new functions to handle the
2458 corresponding pseudo sections.
2459
45a466b5
TT
24602013-01-07 Tom Tromey <tromey@redhat.com>
2461
2462 * section.c (_bfd_std_section): Rename from std_section.
f75e0e33
AM
2463 (bfd_com_section_ptr, bfd_und_section_ptr, bfd_abs_section_ptr)
2464 (STD_SECTION): Update.
45a466b5
TT
2465 * bfd-in2.h: Rebuild.
2466
e407c74b
NC
24672013-01-04 Juergen Urban <JuergenUrban@gmx.de>
2468
2469 * archures.c (bfd_mach_mips5900): Define.
2470 * bfd-in2.h: Regenerate.
2471 * config.bfd: Add mips64-ps2-elf and mips-ps2-elf targets.
2472 * cpu-mips.c: Add support for MIPS r5900.
2473 * elfxx-mips.c: Add support for MIPS r5900 (extension of r4000).
2474
9b239e0e
NC
24752013-01-03 Nickolai Zeldovich <nickolai@csail.mit.edu>
2476 Nick Clifton <nickc@redhat.com>
2477
2478 * elflink.c (get_value): Prevent the use of an undefined shift
2479 operation. Add sanity checks.
2480
bab4becb 24812013-01-02 Kaushik Phatak <kaushik.phatak@kpitcummins.com>
884f2a8d 2482
bab4becb 2483 * config.bfd (cr16*-*-uclinux*): New target support.
884f2a8d 2484
9911c0fc 2485
bab4becb 2486For older changes see ChangeLog-2012
56882138 2487\f
bab4becb 2488Copyright (C) 2013 Free Software Foundation, Inc.
752937aa
NC
2489
2490Copying and distribution of this file, with or without modification,
2491are permitted in any medium without royalty provided the copyright
2492notice and this notice are preserved.
2493
56882138
AM
2494Local Variables:
2495mode: change-log
2496left-margin: 8
2497fill-column: 74
2498version-control: never
2499End:
This page took 0.777634 seconds and 4 git commands to generate.