1 2018-09-14 Alan Modra <amodra@gmail.com>
4 * reloc.c (bfd_generic_get_relocated_section_contents): Zero reloc
5 fields in debug sections when reloc is against an undefined symbol
6 and called from bfd_simple_get_relocated_section_contents or
8 * dwarf2.c (find_abstract_instance): Return true for zero offset
9 DW_FORM_ref_addr without returning values.
11 2018-09-06 Alan Modra <amodra@gmail.com>
14 * elf32-avr.c (elf_avr_special_sections): New.
15 (elf_backend_special_sections): Define.
17 2018-09-04 Jose E. Marchesi <jose.marchesi@oracle.com>
19 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Do not issue an
20 error when an invalid relocation is passed; this is already done
21 by `_bfd_sparc_elf_info_to_howto_ptr'.
23 2018-09-04 Jose E. Marchesi <jose.marchesi@oracle.com>
25 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Issue an
26 error when an invalid symbol index is retrieved in ELF64_R_SYM of
27 a relocation seen in an input file.
29 2018-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
30 Alan Modra <amodra@gmail.com>
33 elf.c (copy_elf_program_header): When first segment contains
34 only the headers and SHT_NOBITS sections, use segment p_filesz
35 to calculate header and padding size. Use filepos of the first
38 018-08-31 H.J. Lu <hongjiu.lu@intel.com>
41 * archures.c (bfd_arch_get_compatible): Allow an IR object with
44 2018-08-31 Alan Modra <amodra@gmail.com>
46 * elf64-ppc.c (num_relocs_for_offset): New function.
47 (emit_relocs_for_offset): New function.
48 (use_global_in_relocs): New function, split out from..
49 (ppc_build_one_stub): ..here. Output relocations for notoc stubs.
50 (ppc_size_one_stub): Calculate reloc count for notoc stubs.
51 (ppc64_elf_size_stubs): Don't count undefined syms in stub_globals.
53 2018-08-31 Alan Modra <amodra@gmail.com>
55 * reloc.c (BFD_RELOC_PPC64_REL16_HIGH, BFD_RELOC_PPC64_REL16_HIGHA),
56 (BFD_RELOC_PPC64_REL16_HIGHER, BFD_RELOC_PPC64_REL16_HIGHERA),
57 (BFD_RELOC_PPC64_REL16_HIGHEST, BFD_RELOC_PPC64_REL16_HIGHESTA):
59 * elf64-ppc.c (ppc64_elf_howto_raw): Add new REL16 howtos.
60 (ppc64_elf_reloc_type_lookup): Translate new REL16 relocs.
61 (ppc64_elf_check_relocs, ppc64_elf_relocate_section): Handle them.
62 * bfd-in2.h: Regenerate.
63 * libbfd.h: Regenerate.
65 2018-08-31 Alan Modra <amodra@gmail.com>
67 * elf64-ppc.c: Correct _notoc stub comments.
68 (ppc_build_one_stub): Simplify output of branch for notoc
69 long branch stub. Don't include label offset of 8 bytes in
70 "off" calculation for notoc plt stub. Don't emit insns to get pc.
71 (build_offset): Emit insns to get pc here instead.
72 (size_offset): Add 4 extra insns.
73 (plt_stub_size): Adjust for "off" and size_offset changes.
74 (ppc_size_one_stub): Rearrange code into a switch, duplicating
75 some to better match ppc_build_one_stub.
77 2018-08-29 Chenghua Xu <paul.hua.gm@gmail.com>
79 * archures.c (bfd_architecture): New machine
81 * bfd-in2.h (bfd_architecture): Likewise.
82 * cpu-mips.c (enum I_xxx): Likewise.
83 (arch_info_struct): Likewise.
84 * elfxx-mips.c (_bfd_elf_mips_mach): Handle
86 (mips_set_isa_flags): Likewise.
87 (mips_mach_extensions): Map bfd_mach_mips_gs264e to
88 bfd_mach_mips_gs464e extension.
90 2018-08-29 Chenghua Xu <paul.hua.gm@gmail.com>
92 * archures.c (bfd_architecture): New machine
94 * bfd-in2.h (bfd_architecture): Likewise.
95 * cpu-mips.c (enum I_xxx): Likewise.
96 (arch_info_struct): Likewise.
97 * elfxx-mips.c (_bfd_elf_mips_mach): Handle
99 (mips_set_isa_flags): Likewise.
100 (mips_mach_extensions): Map bfd_mach_mips_gs464e to
101 bfd_mach_mips_gs464 extension.
103 2018-08-29 Chenghua Xu <paul.hua.gm@gmail.com>
105 * archures.c (bfd_architecture): Rename
106 bfd_mach_mips_loongson_3a to bfd_mach_mips_gs464.
107 * bfd-in2.h (bfd_architecture): Likewise.
108 * cpu-mips.c (enum I_xxx): Likewise.
109 (arch_info_struct): Likewise.
110 * elfxx-mips.c (_bfd_elf_mips_mach): Likewise.
111 (mips_set_isa_flags): Likewise.
112 (mips_mach_extensions): Likewise.
113 (bfd_mips_isa_ext_mach): Likewise.
114 (bfd_mips_isa_ext): Likewise.
115 (print_mips_isa_ext): Delete AFL_EXT_LOONGSON_3A.
117 2018-08-29 Chenghua Xu <paul.hua.gm@gmail.com>
119 * elfxx-mips.c (print_mips_ases): Add Loongson EXT2 extension.
121 2018-08-29 Chenghua Xu <paul.hua.gm@gmail.com>
123 * elfxx-mips.c (infer_mips_abiflags): Use ases instead of
124 isa_ext for infer ABI flags.
125 (print_mips_ases): Add Loongson EXT extension.
127 2018-08-29 Chenghua Xu <paul.hua.gm@gmail.com>
129 * elfxx-mips.c (print_mips_ases): Add CAM extension.
131 2018-08-27 H.J. Lu <hongjiu.lu@intel.com>
133 * elfxx-x86.c (_bfd_x86_elf_parse_gnu_properties): Don't mask
134 out the GNU_PROPERTY_X86_UINT32_VALID bit.
136 2018-08-25 H.J. Lu <hongjiu.lu@intel.com>
139 * elf.c (_bfd_elf_get_symbol_version_string): Return
140 _("<corrupt>") for corrupt symbol version info.
142 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
144 * elfxx-x86.c (_bfd_x86_elf_parse_gnu_properties): Handle
145 X86_COMPAT_ISA_1_USED, X86_COMPAT_ISA_1_NEEDED,
146 X86_UINT32_AND_LO, X86_UINT32_AND_HI, X86_UINT32_OR_LO,
147 X86_UINT32_OR_HI, X86_UINT32_OR_AND_LO and X86_UINT32_OR_AND_HI
148 instead of X86_ISA_1_USED, X86_ISA_1_NEEDED and X86_FEATURE_1_AND.
149 (_bfd_x86_elf_merge_gnu_properties): Likewise.
150 (_bfd_x86_elf_link_setup_gnu_properties): Add X86_FEATURE_2_NEEDED
151 instead of X86_ISA_1_NEEDED.
152 (_bfd_x86_elf_link_fixup_gnu_properties): Handle
153 X86_COMPAT_ISA_1_USED, X86_COMPAT_ISA_1_NEEDED, X86_UINT32_AND_LO,
154 X86_UINT32_AND_HI, X86_UINT32_OR_LO, X86_UINT32_OR_HI,
155 X86_UINT32_OR_AND_LO and X86_UINT32_OR_AND_HI instead of
156 X86_ISA_1_USED, X86_ISA_1_NEEDED and X86_FEATURE_1_AND.
158 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
160 * elfxx-x86.c (_bfd_x86_elf_parse_gnu_properties): Mask out the
161 GNU_PROPERTY_X86_UINT32_VALID bit.
162 (_bfd_x86_elf_link_fixup_gnu_properties): Set the
163 GNU_PROPERTY_X86_UINT32_VALID bit for non-relocatable output.
165 2018-08-23 Zenith423 <zenith432@users.sourceforge.net>
168 * plugin.c (struct plugin_list_entry): New structure.
169 (plugin_list): New variable.
170 (try_load_plugin): Place opened plugins on a list. Ensure that
171 the refcount in the dynamic loader is kept at 1.
173 2018-08-23 Alan Modra <amodra@gmail.com>
175 * elf64-ppc.c (ppc64_elf_relocate_section): Revise "call lacks
178 2018-08-23 Nick Clifton <nickc@redhat.com>
180 * elf64-hppa.c (elf_hppa_final_link_relocate): Replace unworkable
181 code with an assertion.
183 2018-08-23 Nick Clifton <nickc@redhat.com>
186 * coffgen.c (coff_pointerize_aux): Add table_end parameter. Use
187 it to prevent walking off the end of the table.
188 (coff_get_normalized_symtab): Pass internal_end pointer to
191 2018-08-23 Alan Modra <amodra@gmail.com>
193 * elf64-ppc.c (ppc64_elf_relocate_section): Don't miss clearing
194 unresolved_reloc on ppc_stub_plt_call_notoc.
196 2018-08-22 H.J. Lu <hongjiu.lu@intel.com>
199 * development.sh (experimental): New.
201 2018-08-22 Helge Deller <deller@gmx.de>
202 Nick Clifton <nickc@redhat.com>
204 * elf-hppa.h (elf_hppa_fake_sections): Use SHT_PARISC_UNWIND as
205 the section type of the .PARISC.unwind section on 64-bit binaries
206 and SHT_PROGBITS for 32-bit binaries. Add a comment about it.
207 Add comment about the sh_entsize value.
209 2018-08-22 Rafeal Auler <rafaelauler@gmail.com>
212 * elfnn-aarch64.c (elfNN_aarch64_size_stubs): Always update the
213 stub's target, since it may have been changed after the layout.
215 2018-08-21 John Darington <john@darrington.wattle.id.au>
217 * elf32-s12z.c (opru18_reloc): New function.
218 (elf_s12z_howto_table): Adjust Howto according to new knowledge.
220 2018-08-21 mephi42 <mephi42@gmail.com>
223 * mach-o.c (bfd_mach_o_mangle_symbols): Update n_type even if
224 data is already considered filled.
226 2018-08-21 Alan Modra <amodra@gmail.com>
228 * elf64-ppc.c (HOW): Define.
230 (ppc64_elf_howto_raw): Use HOW to initialize entries.
231 * elf32-ppc.c (HOW): Define.
232 (ppc_elf_howto_raw): Use HOW to initialize entries, updating
233 R_PPC_VLE_REL15 and R_PPC_VLE_REL24 to use bitpos=0.
235 2018-08-21 Alan Modra <amodra@gmail.com>
237 * reloc.c (reloc_howto_type): Typedef.
238 (bfd_symbol): Delete forward declaration.
239 (struct reloc_howto_struct): Add "negate" field. Make "size",
240 "bitsize", "rightshift", "bitpos", "complain_on_overflow",
241 "pc_relative", "partial_inplace", and "pcrel_offset" bitfields.
242 Rearrange for better packing. Revise comments.
243 (HOWTO): Map to rearranged reloc_howto_struct.
244 (bfd_get_reloc_size): Delete now unused cases.
245 (read_reloc, write_reloc): Likewise.
246 (apply_reloc, _bfd_relocate_contents): Test howto->negate
247 rather than howto->size < 0 for negated relocation values.
248 * coff-rs6000.c (xcoff_complain_overflow_bitfield_func): Avoid
249 signed/unsigned warning.
250 (xcoff_ppc_relocate_section): Delete "condition is always false"
252 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Likewise.
253 * cpu-ns32k.c (do_ns32k_reloc): Adjust to suit reloc_howto_struct
255 * vms-alpha.c (_bfd_vms_write_etir, alpha_vms_slurp_relocs): Use
256 size 16 for ALPHA_R_LINKAGE.
257 (alpha_howto_table <ALPHA_R_LINKAGE>): Set encoded size and
259 * bfd-in.h (reloc_howto_type): Delete.
260 * bfd-in2.h: Regenerate.
262 2018-08-21 Alan Modra <amodra@gmail.com>
264 * reloc.c (HOWTO): Revise comment.
265 (NEWHOWTO, HOWTO_PREPARE): Delete.
266 * coff-arm.c (coff_arm_reloc_type_lookup): Replace const struc
267 reloc_howto_struct with reloc_howto_type.
268 * ns32knetbsd.c (MY_bfd_reloc_type_lookup): Likewise.
269 * vms-alpha.c (alpha_vms_bfd_reloc_type_lookup): Likewise.
270 * elf-hppa.h (HOW): Define.
271 (elf_hppa_howto_table): Use it to simplify this table, correcting
272 name of R_PARISC_LTOFF16WF, R_PARISC_LTOFF_FPTR64, and
273 R_PARISC_LTOFF_FPTR16DF.
274 * elf32-mep.c (MEPREL): Use HOWTO.
275 * bfd-in2.h: Regenerate.
277 2018-08-20 Alan Modra <amodra@gmail.com>
279 * mmo.c (valid_mmo_symbol_character_set): Initialize and make
281 (mmo_init): Don't init valid_mmo_symbol_character_set.
283 2018-08-20 Alan Modra <amodra@gmail.com>
285 * rs6000-core.c (CORE_COMMONSZ): Balance parentheses in expression.
287 2018-08-17 H.J. Lu <hongjiu.lu@intel.com>
290 * elf-bfd.h (elf_backend_data): Add fixup_gnu_properties.
291 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Call
292 backend fixup_gnu_properties if it isn't NULL. Discard
293 .note.gnu.property section if all properties have been removed.
294 * elfxx-target.h (elf_backend_fixup_gnu_properties): New.
295 (elfNN_bed): Initialize fixup_gnu_properties.
296 * elfxx-x86.c (_bfd_x86_elf_link_fixup_gnu_properties): New
298 * elfxx-x86.h (_bfd_x86_elf_link_fixup_gnu_properties): New
300 (elf_backend_fixup_gnu_properties): New.
302 2018-08-16 Alan Modra <amodra@gmail.com>
304 * elf64-ppc.c: Correct ppc_stub_long_branch_notoc example.
307 2018-08-12 H.J. Lu <hongjiu.lu@intel.com>
310 * Makefile.am (BFD32_LIBS): Add elf-properties.lo.
311 (BFD32_LIBS_CFILES): Add elf-properties.c.
312 (BFD32_BACKENDS): Remove elf-properties.lo.
313 (BFD32_BACKENDS_CFILES): Remove elf-properties.c.
314 * configure.ac (elf): Remove elf-properties.lo.
315 * Makefile.in: Regenerated.
316 * configure: Likewise.
318 2018-08-11 H.J. Lu <hongjiu.lu@intel.com>
321 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Don't
322 add X86_ISA_1_NEEDED property only if existing properties won't
325 2018-08-11 Alan Modra <amodra@gmail.com>
327 * reloc.c (bfd_get_reloc_size): Sort switch.
328 (read_reloc, write_reloc, apply_reloc): New functions.
329 (bfd_perform_relocation, bfd_install_relocation): Use apply_reloc.
330 (_bfd_relocate_contents): Use read_reloc and write_reloc.
331 (_bfd_clear_contents): Likewise.
333 2018-08-11 John Darrington <john@darrington.wattle.id.au>
335 * reloc.c (_bfd_relocate_contents): Handle 3 byte relocs.
336 (_bfd_clear_contents): Likewise.
337 (bfd_perform_relocation): Likewise.
338 (bfd_install_relocation): Likewise.
340 2018-08-10 H.J. Lu <hongjiu.lu@intel.com>
343 * elflink.c (bfd_elf_record_link_assignment): Always clear
344 h->verinfo.verdef when overriding a dynamic definition.
346 2018-08-10 H.J. Lu <hongjiu.lu@intel.com>
349 * elf-properties.c (elf_get_gnu_property_section_size): Always
350 use align_size as pr_datasz for GNU_PROPERTY_STACK_SIZE.
351 (elf_write_gnu_properties): Likewise.
353 2018-08-08 H.J. Lu <hongjiu.lu@intel.com>
356 * bfd.c (bfd_convert_section_size): Check BFD_DECOMPRESS after
357 calling _bfd_elf_convert_gnu_property_size to convert
358 .note.gnu.property section size.
359 (bfd_convert_section_contents): Check BFD_DECOMPRESS after
360 calling _bfd_elf_convert_gnu_properties to convert
361 .note.gnu.property section.
362 * elf-bfd.h (_bfd_elf_convert_gnu_property_size): New prototype.
363 (_bfd_elf_convert_gnu_properties): Likewise.
364 * elf-properties.c (elf_get_gnu_property_section_size): New
366 (elf_write_gnu_properties): Likewise.
367 (_bfd_elf_convert_gnu_property_size): Likewise.
368 (_bfd_elf_convert_gnu_properties): Likewise.
369 (_bfd_elf_link_setup_gnu_properties): Use
370 elf_get_gnu_property_section_size and elf_write_gnu_properties.
372 2018-08-08 H.J. Lu <hongjiu.lu@intel.com>
375 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Remove
376 GNU_PROPERTY_X86_ISA_1_USED if an input file doesn't have it.
377 (_bfd_x86_elf_link_setup_gnu_properties): Adding the
378 GNU_PROPERTY_X86_ISA_1_NEEDED, instead of
379 GNU_PROPERTY_X86_ISA_1_USED, property.
381 2018-08-07 Alan Modra <amodra@gmail.com>
383 * elf64-ppc.c (struct map_stub): Delete tls_get_addr_opt_bctrl.
384 Add lr_restore, eh_size and eh_base.
385 (eh_advance, eh_advance_size): New functions.
386 (build_tls_get_addr_stub): Emit EH info for stub.
387 (ppc_build_one_stub): Likewise for _notoc stubs.
388 (ppc_size_one_stub): Size EH info for stub.
389 (group_sections): Init new map_stub fields.
390 (stub_eh_frame_size): Delete.
391 (ppc64_elf_size_stubs): Size EH info for stubs. Set up dummy EH
393 (ppc64_elf_build_stubs): Reinit new map_stub fields. Set FDE
394 offset to stub section here..
395 (ppc64_elf_finish_dynamic_sections): ..rather than here.
397 2018-08-07 Alan Modra <amodra@gmail.com>
399 * elf64-ppc.c (ppc64_elf_relocate_section): Don't skip first
400 instruction of __tls_get_addr_opt stub.
401 (plt_stub_size): Omit ALWAYS_EMIT_R2SAVE condition when
402 dealing with __tls_get_addr_opt stub.
403 (build_tls_get_addr_stub, ppc_size_one_stub): Likewise.
405 2018-08-06 Claudiu Zissulescu <claziss@synopsys.com>
407 * elf32-arc.c (arc_elf_merge_private_bfd_data): Complain about
408 efalgs only when in/out exists.
409 (elf32_arc_section_from_shdr): Don't complain about 0x0c
410 section type. It is mwdt compiler specific.
412 2018-08-06 Claudiu Zissulescu <claziss@synopsys.com>
414 * elf32-arc.c (arc_elf_merge_attributes): Fix merge attributes.
416 2018-08-06 Claudiu Zissulescu <claziss@synopsys.com>
418 * elf32-arc.c (arc_elf_merge_attributes): Handle
421 2018-08-05 Alan Modra <amodra@gmail.com>
423 * elf64-ppc.c (ADDI_R12_R11, ADDI_R12_R12, LIS_R12),
424 (ADDIS_R12_R11, ORIS_R12_R12_0, ORI_R12_R12_0),
425 (SLDI_R12_R12_32, LDX_R12_R11_R12, ADD_R12_R11_R12): Define.
426 (ppc64_elf_howto_raw): Add R_PPC64_REL24_NOTOC entry.
427 (ppc64_elf_reloc_type_lookup): Support R_PPC64_REL24_NOTOC.
428 (ppc_stub_type): Add ppc_stub_long_branch_notoc,
429 ppc_stub_long_branch_both, ppc_stub_plt_branch_notoc,
430 ppc_stub_plt_branch_both, ppc_stub_plt_call_notoc, and
431 ppc_stub_plt_call_both.
432 (is_branch_reloc): Add R_PPC64_REL24_NOTOC.
433 (build_offset, size_offset): New functions.
434 (plt_stub_size): Support plt_call_notoc and plt_call_both.
435 (ppc_build_one_stub, ppc_size_one_stub): Support new stubs.
436 (toc_adjusting_stub_needed): Handle R_PPC64_REL24_NOTOC.
437 (ppc64_elf_size_stubs): Likewise, and new stubs.
438 (ppc64_elf_build_stubs, ppc64_elf_relocate_section): Likewise.
439 * reloc.c: Add BFD_RELOC_PPC64_REL24_NOTOC.
440 * bfd-in2.h: Regenerate.
441 * libbfd.h: Regenerate.
443 2018-08-05 Alan Modra <amodra@gmail.com>
445 * elf64-ppc.c (ppc_build_one_stub): Lose "_r2off" in stub symbols.
447 2018-08-02 Jim Wilson <jimw@sifive.com>
449 * elfnn-riscv.c (riscv_elf_create_dynamic_sections): For .tdata.dyn,
450 add SEC_LINKER_CREATED flag.
452 2018-08-01 Nick Clifton <nickc@redhat.com>
454 * coff-rs6000.c (_bfd_xcoff_put_ldsymbol_name): Suppress warnings
455 about potentially truncated strncpy operations.
456 (_bfd_xcoff_put_symbol_name): Likewise.
458 * elf32-avr.c (avr_stub_name): Check for a NULL return from
461 2018-08-01 Zenith <zenith432@users.sourceforge.net>
464 * plugin.c (bfd_plugin_open_input): Close file descriptor if the
466 (try_claim): Always close the file descriptor at the end of the
468 (try_load_plugin): If a plugin has already been registered, then
469 skip the dlopen and onload steps and go straight to claiming the
470 file. If these is an error, close the plugin.
472 2018-08-01 Alan Modra <amodra@gmail.com>
474 * elf64-ppc.c (plt_stub_pad): Delay plt_stub_size call until needed.
475 (ppc_build_one_stub): Don't set stub_offset, instead assert that
476 it is sane. Don't adjust stub_offset for alignment. Adjust size
477 calculation. Use "targ" temp when calculating offsets.
478 (ppc_size_one_stub): Set stub_offset here. Use "targ" temp when
479 calculating offsets. Adjust for alignment before setting
480 tls_get_addr_opt_bctrl.
482 2018-08-01 Alan Modra <amodra@gmail.com>
484 * po/SRC-POTFILES.in: Regenerate.
486 2018-07-30 Nick Clifton <nickc@redhat.com>
489 * elf32-sh.c (sh_elf_relocate_section): When processing
490 translation relocs, fail if the relocation offset is too small.
491 Replace BFD_ASSERTs with more helpful error messages.
493 2018-07-30 Andrew Jenner <andrew@codesourcery.com>
495 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES): Add C-SKY.
496 (BFD32_BACKENDS, BFD_BACKENDS_CFILES): Likewise.
497 * Makefile.in: Regenerated.
498 * archures.c (enum bfd_architecture): Add bfd_arch_csky and
499 related bfd_mach defines.
500 (bfd_csky_arch): Declare.
501 (bfd_archures_list): Add C-SKY.
502 * bfd-in.h (elf32_csky_build_stubs): Declare.
503 (elf32_csky_size_stubs): Declare.
504 (elf32_csky_next_input_section: Declare.
505 (elf32_csky_setup_section_lists): Declare.
506 * bfd-in2.h: Regenerated.
507 * config.bfd: Add C-SKY.
508 * configure.ac: Likewise.
509 * configure: Regenerated.
510 * cpu-csky.c: New file.
511 * elf-bfd.h (enum elf_target_id): Add C-SKY.
512 * elf32-csky.c: New file.
513 * libbfd.h: Regenerated.
514 * reloc.c: Add C-SKY relocations.
515 * targets.c (csky_elf32_be_vec, csky_elf32_le_vec): Declare.
516 (_bfd_target_vector): Add C-SKY target vector entries.
518 2018-07-27 John Darrington <john@darrington.wattle.id.au>
520 * elf32-s12z.c (ELF_TARGET_ID): Don't define.
522 2018-07-27 John Darrington <john@darrington.wattle.id.au>
524 * libbfd.c (bfd_getb24, bfd_getl24): New functions.
525 (bfd_get_24, bfd_put_24): New macros.
526 * bfd-in2.h: Regenerate.
528 2018-07-27 John Darrington <john@darrington.wattle.id.au>
530 * elf32-s12z.c (s12z_elf_set_mach_from_flags): Remove comment.
532 2018-07-26 Alan Modra <amodra@gmail.com>
534 * elf64-ppc.c (ppc64_elf_size_stubs): Use a ppc_stub_long_branch_r2off
535 for calls to symbols with STO_PPC64_LOCAL_MASK bits set to 1.
537 2018-07-25 Alan Modra <amodra@gmail.com>
539 * elf32-ppc.c (ppc_elf_relax_section): Ignore common or undef locals.
540 Avoid trashing toff with added when used as a symbol index.
541 Ignore R_PPC_PLTREL24 addends in unused example code. Avoid
542 creating unnecessary fixups when relocatable.
544 2018-07-25 Alan Modra <amodra@gmail.com>
546 * elf32-arm.c (elf32_arm_nabi_write_core_note): Disable
547 -Wstringop-truncation warning for gcc-8.0 too.
548 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
549 * elf64-ppc.c (ppc64_elf_write_core_note): Likewise.
550 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
551 * elf32-s390.c (elf_s390_write_core_note): Comment fix.
552 * elf64-s390.c (elf_s390_write_core_note): Likewise.
554 2018-07-24 Alan Modra <amodra@gmail.com>
557 * dwarf2.c (dwarf_debug_section_enum): Fix comment typo.
558 * elf.c (bfd_section_from_shdr, elf_sort_sections): Likewise.
560 2018-07-23 Max Filippov <jcmvbkbc@gmail.com>
562 * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Move
563 relocation sections consistency check to always check both
564 .rela.dyn and .rela.plt when they exist. Rearrange variable
565 definition and assignment places.
567 2018-07-23 Max Filippov <jcmvbkbc@gmail.com>
569 * elf32-xtensa.c (shrink_dynamic_reloc_sections): Shrink dynamic
570 relocations section for dynamic undefined weak symbols when
571 linking a shared object.
573 2018-07-23 Tom Tromey <tom@tromey.com>
575 * elf.c (bfd_get_elf_phdrs): Don't call memcpy with size 0.
577 2018-07-21 Eric Botcazou <ebotcazou@adacore.com>
579 * elf32-arm.c (elf32_arm_final_link_relocate) <R_ARM_GOT32>: Small
580 cleanup for the case of a global symbol that binds locally. Also
581 install a value in the GOT slot in the case of a local symbol in
584 2018-07-20 H.J. Lu <hongjiu.lu@intel.com>
587 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): If the
588 separate code program header is needed, make sure that the first
589 read-only PT_LOAD segment has no code by adding a
590 GNU_PROPERTY_X86_ISA_1_USED note.
592 2018-07-20 Chenghua Xu <paul.hua.gm@gmail.com>
593 Maciej W. Rozycki <macro@mips.com>
595 * elfxx-mips.c (print_mips_ases): Add MMI extension.
597 2018-07-20 Maciej W. Rozycki <macro@mips.com>
599 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Do not
600 create DT_REL, DT_RELSZ or DT_RELENT dynamic entries if the
601 dynamic relocation section will be discarded from output.
602 (_bfd_mips_elf_finish_dynamic_sections) <DT_RELSZ>: Assert that
603 the dynamic relocation section will be retained in output.
605 2018-07-18 Maciej W. Rozycki <macro@mips.com>
607 * xcofflink.c (xcoff_write_global_symbol): Fix symbol type
608 checks for defined weak symbols.
610 2018-07-17 Maciej W. Rozycki <macro@mips.com>
612 * elf32-nds32.c (nds32_elf_relax_loadstore): Use
613 `bfd_is_abs_symbol' rather than `bfd_is_abs_section' in checking
614 whether the symbol is absolute.
615 (nds32_elf_relax_lo12): Likewise.
616 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
617 (elfNN_aarch64_check_relocs): Likewise.
618 * xcofflink.c (xcoff_need_ldrel_p): Likewise.
619 (bfd_xcoff_import_symbol): Likewise.
620 (xcoff_write_global_symbol): Likewise.
622 2018-07-17 Maciej W. Rozycki <macro@mips.com>
624 * linker.c (bfd_is_abs_symbol): New macro.
625 * bfd-in2.h: Regenerate.
627 2018-07-16 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
629 * elf-bfd.h (elfcore_write_ppc_tar): Add prototype.
630 (elfcore_write_ppc_ppr): Likewise.
631 (elfcore_write_ppc_dscr): Likewise.
632 (elfcore_write_ppc_ebb): Likewise.
633 (elfcore_write_ppc_pmu): Likewise.
634 (elfcore_write_ppc_tm_cgpr): Likewise.
635 (elfcore_write_ppc_tm_cfpr): Likewise.
636 (elfcore_write_ppc_tm_cvmx): Likewise.
637 (elfcore_write_ppc_tm_cvsx): Likewise.
638 (elfcore_write_ppc_tm_spr): Likewise.
639 (elfcore_write_ppc_tm_ctar): Likewise.
640 (elfcore_write_ppc_tm_cppr): Likewise.
641 (elfcore_write_ppc_tm_cdscr): Likewise.
642 * elf.c (elfcore_write_ppc_tar): New function.
643 (elfcore_write_ppc_ppr): Likewise.
644 (elfcore_write_ppc_dscr): Likewise.
645 (elfcore_write_ppc_ebb): Likewise.
646 (elfcore_write_ppc_pmu): Likewise.
647 (elfcore_write_ppc_tm_cgpr): Likewise.
648 (elfcore_write_ppc_tm_cfpr): Likewise.
649 (elfcore_write_ppc_tm_cvmx): Likewise.
650 (elfcore_write_ppc_tm_cvsx): Likewise.
651 (elfcore_write_ppc_tm_spr): Likewise.
652 (elfcore_write_ppc_tm_ctar): Likewise.
653 (elfcore_write_ppc_tm_cppr): Likewise.
654 (elfcore_write_ppc_tm_cdscr): Likewise.
655 (elfcore_write_register_note): Call them.
656 (elfcore_grok_ppc_tar): New function.
657 (elfcore_grok_ppc_ppr): Likewise.
658 (elfcore_grok_ppc_dscr): Likewise.
659 (elfcore_grok_ppc_ebb): Likewise.
660 (elfcore_grok_ppc_pmu): Likewise.
661 (elfcore_grok_ppc_tm_cgpr): Likewise.
662 (elfcore_grok_ppc_tm_cfpr): Likewise.
663 (elfcore_grok_ppc_tm_cvmx): Likewise.
664 (elfcore_grok_ppc_tm_cvsx): Likewise.
665 (elfcore_grok_ppc_tm_spr): Likewise.
666 (elfcore_grok_ppc_tm_ctar): Likewise.
667 (elfcore_grok_ppc_tm_cppr): Likewise.
668 (elfcore_grok_ppc_tm_cdscr): Likewise.
669 (elfcore_grok_note): Call them.
671 2018-07-11 Maciej W. Rozycki <macro@mips.com>
673 * elfxx-mips.c (mips_tls_got_relocs): Use `bfd_link_dll' rather
674 than `!bfd_link_pic' in determining the dynamic symbol index.
675 Avoid the index of -1.
676 (mips_elf_initialize_tls_slots): Likewise. Flatten code by
677 moving `dyn' to the beginning of the function block.
679 2018-07-11 Maciej W. Rozycki <macro@mips.com>
680 Rich Felker <bugdal@aerifal.cx>
683 * elfxx-mips.c (mips_tls_got_relocs): Use `bfd_link_dll' rather
684 than `bfd_link_pic' to determine whether dynamic relocations are
686 (mips_elf_initialize_tls_slots): Likewise.
688 2018-07-10 Maciej W. Rozycki <macro@mips.com>
690 * elflink.c (bfd_elf_final_link): Rename `remove' local variable
693 2018-07-10 Alan Modra <amodra@gmail.com>
695 * elf32-xgate.h: Delete.
696 * elf32-xgate.c: Delete unnecessary forward declarations, add two
698 (xgate_elf_bfd_link_hash_table_create)
699 (xgate_elf_bfd_link_hash_table_free)
700 (xgate_elf_set_mach_from_flags, struct xgate_scan_param)
701 (stub_hash_newfunc, elf32_xgate_add_symbol_hook)
702 (elf32_xgate_setup_section_lists, elf32_xgate_size_stubs)
703 (elf32_xgate_build_stubs, elf32_xgate_check_relocs)
704 (elf32_xgate_relocate_section, _bfd_xgate_elf_set_private_flags)
705 (elf32_xgate_post_process_headers): Delete.
706 (elf32_xgate_backend_symbol_processing): New function.
707 (xgate_elf_ignore_reloc, xgate_elf_special_reloc)
708 (_bfd_xgate_elf_print_private_bfd_data): Make static.
709 (ELF_TARGET_ID, elf_info_to_howto, elf_backend_check_relocs)
710 (elf_backend_relocate_section, elf_backend_object_p)
711 (elf_backend_final_write_processing, elf_backend_can_gc_sections)
712 (elf_backend_post_process_headers, elf_backend_add_symbol_hook)
713 (bfd_elf32_bfd_link_hash_table_create)
714 (bfd_elf32_bfd_set_private_flags)
715 (xgate_stub_hash_lookup): Don't define.
716 (elf_backend_symbol_processing): Define.
717 * elf-bfd.h (elf_target_id): Delete XGATE_ELF_DATA.
719 2018-07-09 Maciej W. Rozycki <macro@mips.com>
721 * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Don't set
722 `->needs_lazy_stub' if the stubs output section is the absolute
725 2018-07-09 H.J. Lu <hongjiu.lu@intel.com>
728 * configure.ac: Use changequote for "i[3-7]86-*-linux-*".
729 * configure: Regenerated.
731 2018-07-09 Alan Modra <amodra@gmail.com>
733 * elf32-m68hc1x.c (elf32_m68hc11_post_process_headers): Call
734 _bfd_elf_post_process_headers.
736 2018-07-06 Max Filippov <jcmvbkbc@gmail.com>
738 * elf32-xtensa.c (elf_xtensa_allocate_dynrelocs): Don't allocate
739 space for dynamic relocation for undefined weak symbol.
740 (elf_xtensa_relocate_section): Don't emit R_XTENSA_RELATIVE
741 relocation for undefined weak symbols.
742 (shrink_dynamic_reloc_sections): Don't shrink dynamic relocation
743 section for relocations against undefined weak symbols.
745 2018-07-06 Alan Hayward <alan.hayward@arm.com>
747 * elf.c (elfcore_grok_aarch_sve): New function.
748 (elfcore_grok_note): Check for Aarch64 SVE.
749 (elfcore_write_aarch_sve): New function.
750 (elfcore_write_register_note): Check for Aarch64 SVE.
751 * elf-bfd.h(elfcore_grok_aarch_sve): New declaration.
753 2018-07-06 Alan Modra <amodra@gmail.com>
755 * elf32-arm.c (elf32_arm_nabi_write_core_note): Don't use
756 DIAGNOTIC_PUSH and DIAGNOSTIC_POP unconditionally.
757 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
758 * elf32-s390.c (elf_s390_write_core_note): Likewise.
759 * elf64-ppc.c (ppc64_elf_write_core_note): Likewise.
760 * elf64-s390.c (elf_s390_write_core_note): Likewise.
761 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
763 2018-07-05 Jim Wilson <jimw@sifive.com>
765 * config.bfd (riscv32*-*-*): Renamed from riscv32-*-*.
766 (riscv64*-*-*): Likewise.
767 (riscv-*-*): Add as an alias for riscv32*-*-*.
769 2018-07-05 H.J. Lu <hongjiu.lu@intel.com>
772 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Remove x86
773 ISA properties with empty bits.
775 2018-07-05 Nick Clifton <nickc@redhat.com>
777 * po/ru.po: Updated Russian translation.
779 2018-07-05 Alan Modra <amodra@gmail.com>
781 * elf-bfd.h (_bfd_elf_ppc_merge_fp_attributes): Update prototype.
782 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Return error
783 on mismatch. Remove "warning: " from messages. Track last bfd
785 (ppc_elf_merge_obj_attributes): Likewise. Handle status from
786 _bfd_elf_ppc_merge_fp_attributes.
787 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Handle status
788 from _bfd_elf_ppc_merge_fp_attributes.
790 2018-07-04 H.J. Lu <hongjiu.lu@intel.com>
792 * Makefile.am (bfdinclude_HEADERS): Add $(INCDIR)/diagnostics.h.
793 * Makefile.in: Regenerated.
795 2018-07-03 Alan Modra <amodra@gmail.com>
797 * elflink.c (bfd_elf_final_link): Remove zero size .gnu.attributes
800 2018-07-03 Alan Modra <amodra@gmail.com>
802 * elf-bfd.h (ATTR_TYPE_FLAG_ERROR, ATTR_TYPE_HAS_ERROR): Define.
803 * elf-attrs.c (is_default_attr): Handle ATTR_TYPE_HAS_ERROR.
804 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Use
805 ATTR_TYPE_FLAG_INT_VAL. Set ATTR_TYPE_HAS_ERROR on finding
806 incompatible attribute.
807 (ppc_elf_merge_obj_attributes): Likewise. Return
808 _bfd_elf_merge_object_attributes result.
809 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Return
810 _bfd_elf_merge_object_attributes result.
812 2018-07-03 Alan Modra <amodra@gmail.com>
815 * elflink.c (_bfd_elf_fix_symbol_flags): Hide dynamic symbols
816 in discarded sections.
818 2018-07-02 Maciej W. Rozycki <macro@mips.com>
820 * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Set
821 `mark' for symbols created from `mips_elf_dynsym_rtproc_names'
824 2018-07-02 Maciej W. Rozycki <macro@mips.com>
826 * elf64-mips.c (micromips_elf64_howto_table_rel): Add
827 R_MICROMIPS_HI0_LO16, R_MICROMIPS_TLS_GD, R_MICROMIPS_TLS_LDM,
828 R_MICROMIPS_TLS_DTPREL_HI16, R_MICROMIPS_TLS_DTPREL_LO16,
829 R_MICROMIPS_TLS_GOTTPREL, R_MICROMIPS_TLS_TPREL_HI16,
830 R_MICROMIPS_TLS_TPREL_LO16, R_MICROMIPS_GPREL7_S2 and
831 R_MICROMIPS_PC23_S2 relocation entries.
832 (micromips_elf64_howto_table_rela): Likewise.
833 (micromips_reloc_map): Likewise.
834 * elfn32-mips.c (elf_micromips_howto_table_rel): Likewise.
835 (elf_micromips_howto_table_rela): Likewise.
836 (micromips_reloc_map): Likewise.
838 2018-07-02 H.J. Lu <hongjiu.lu@intel.com>
841 * elf64-x86-64.c (elf_x86_64_relocate_section): Clear the
842 R_X86_64_converted_reloc_bit bit.
844 2018-07-02 Jeff Muizelaar <jrmuizel@gmail.com>
845 Tom Tromey <tom@tromey.com>
849 * mach-o.c (bfd_mach_o_fat_close_and_cleanup): New function.
850 (bfd_mach_o_close_and_cleanup): Redefine.
851 * archive.c (_bfd_unlink_from_archive_parent): New function,
853 (_bfd_archive_close_and_cleanup): ..here.
854 (bfd_generic_archive_p): Do not clear archive's format.
855 * libbfd-in.h (_bfd_unlink_from_archive_parent): Declare.
856 * libbfd.h: Regenerate.
858 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
860 * archures.c (bfd_mach_arm_5TEJ, bfd_mach_arm_6, bfd_mach_arm_6KZ,
861 bfd_mach_arm_6T2, bfd_mach_arm_6K, bfd_mach_arm_7, bfd_mach_arm_6M,
862 bfd_mach_arm_6SM, bfd_mach_arm_7EM, bfd_mach_arm_8, bfd_mach_arm_8R,
863 bfd_mach_arm_8M_BASE, bfd_mach_arm_8M_MAIN): Define.
864 * bfd-in2.h: Regenerate.
865 * cpu-arm.c (arch_info_struct): Add entries for above new
867 * elf32-arm.c (bfd_arm_get_mach_from_attributes): Add Tag_CPU_arch to
868 bfd_mach_arm mapping logic for pre Armv4 and Armv5TEJ and later
869 architectures. Force assert failure for any new Tag_CPU_arch value.
871 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
873 * doc/bfdint.texi: Use command-line consistently when used in a
875 * doc/bfdsumm.texi: Likewise.
877 2018-06-29 Maciej W. Rozycki <macro@mips.com>
879 * elfxx-mips.c (allocate_dynrelocs): Remove extraneous symbol
880 visibility check made for undefined weak symbols.
882 2018-06-26 Nick Clifton <nickc@redhat.com>
884 * po/uk.po: Updated Ukranian translation.
886 2018-06-25 Nick Clifton <nickc@redhat.com>
888 * elfnn-aarch64.c (_bfd_aarch64_erratum_835769_stub_name): Check
889 for malloc returning NULL.
890 (_bfd_aarch64_erratum_843419_fixup): Check for
891 _bfd_aarch64_erratum_835769_stub_name returning NULL.
893 2018-06-24 Nick Clifton <nickc@redhat.com>
895 * po/bfd.pot: Regenerate.
897 2018-06-24 Nick Clifton <nickc@redhat.com>
899 * version.m4: Update version string to 2.31.51.
900 * configure: Regenerate.
902 2018-06-24 Nick Clifton <nickc@redhat.com>
906 2018-06-21 Maciej W. Rozycki <macro@mips.com>
908 * elfxx-mips.c (_bfd_mips_elf_compact_eh_encoding)
909 (_bfd_mips_elf_cant_unwind_opcode): Correct formatting.
911 2018-06-21 Maciej W. Rozycki <macro@mips.com>
913 * elfxx-mips.c (_bfd_mips_post_process_headers): Keep
914 EI_ABIVERSION setting together.
916 2018-06-21 Maciej W. Rozycki <macro@mips.com>
918 * elfxx-mips.c (MIPS_LIBC_ABI_DEFAULT, MIPS_LIBC_ABI_MIPS_PLT)
919 (MIPS_LIBC_ABI_UNIQUE, MIPS_LIBC_ABI_MIPS_O32_FP64)
920 (MIPS_LIBC_ABI_MAX): New enumeration constants.
921 (_bfd_mips_post_process_headers): Use them in place of magic
924 2018-06-21 Jim Wilson <jimw@sifive.com>
926 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Update comment.
927 Use SYMBOL_REFERENCES_LOCAL. Add asserts for h->got.offset.
929 2018-06-21 Alan Modra <amodra@gmail.com>
931 * doc/Makefile.am (AUTOMAKE_OPTIONS): Add "foreign".
932 * doc/Makefile.in: Regenerate.
934 2018-06-20 Renlin Li <renlin.li@arm.com>
936 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Use PG_OFFSET
937 to resolve BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC,
938 BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC,
939 BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC,
940 BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC,
941 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
942 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
943 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
944 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
946 2018-06-20 Nick Clifton <nickc@redhat.com>
949 * opncls.c (get_build_id): Check for a negative or excessive data
950 size in the build-id note.
952 2018-06-20 Nick Clifton <nickc@redhat.com>
955 * mach-o.c (cputype): New function.
956 (cpusubtype): New function.
957 (bfd_mach_o_bfd_print_private_data): New function. Dispalys the
958 values in the MACH-O file header.
959 (bfd_mach_o_bfd_copy_private_header_data): Copy the cputype and
960 cpusubtype fields from the input bfd's mach-o header to the output
962 * mach-o-target.c (bfd_mach_o_bfd_print_private_bfd_data):
963 Redefine to bfd_mach_o_bfd_print_private_data.
964 * mach-o.h (bfd_mach_o_bfd_print_private_bfd_data): Prototype.
966 2018-06-19 Maciej W. Rozycki <macro@mips.com>
969 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Verify the
970 `.got.plt' entry referred is in range.
971 (mips_finish_exec_plt): Correct the range check for `.got.plt'
972 start. Replace the assertion used for that with a proper error
975 2018-06-19 Maciej W. Rozycki <macro@mips.com>
977 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Fix
980 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
982 * Makefile.am (AUTOMAKE_OPTIONS): Remove 1.11.
983 (INCLUDES): Rename to ...
984 (AM_CPPFLAGS): ... this.
985 * configure.ac: Remove AC_PREREQ.
986 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove 1.9, cygnus, add
987 info-in-builddir no-texinfo.tex.
988 (info_TEXINFOS): Rename bfd.texinfo to bfd.texi.
989 * doc/bfd.texinfo: Rename to ...
990 * doc/bfd.texi: ... this.
991 * Makefile.in: Re-generate.
992 * aclocal.m4: Re-generate.
993 * config.in: Re-generate.
994 * configure: Re-generate.
995 * doc/Makefile.in: Re-generate.
997 2018-06-18 Mephi <mephi42@gmail.com>
1000 * mach-o-x86-64.c (x86_64_howto_table): Add entry for
1001 BFD_RELOC_MACH_O_X86_64_RELOC_TLV.
1002 (bfd_mach_o_x86_64_canonicalize_one_reloc): Handle the new reloc.
1003 (bfd_mach_o_x86_64_swap_reloc_out): Likewise.
1004 * reloc.c (BFD_RELOC_MACH_O_X86_64_TV): New entry.
1005 * bfd-in2.h: Regenerate.
1006 * libbfd.h: Regenerate.
1008 2018-06-14 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
1010 * elfxx-mips.c (print_mips_ases): Add GINV extension.
1012 2018-06-14 H.J. Lu <hongjiu.lu@intel.com>
1015 * elf.c (_bfd_elf_get_symbol_version_string): Check if the first
1016 symbol version is base version.
1018 2018-06-14 Alan Modra <amodra@gmail.com>
1020 * elf-bfd.h (struct elf_link_hash_table): Add "dynamic_relocs".
1021 * elflink.c (_bfd_elf_init_2_index_sections): Comment fix.
1022 (_bfd_elf_add_dynamic_entry): Set "dynamic_relocs".
1023 (_bfd_elf_link_renumber_dynsyms): Exclude all section symbols when
1024 "dynamic_relocs" is not set.
1025 * elfxx-mips.c (count_section_dynsyms): Likewise.
1027 2018-06-14 Alan Modra <amodra@gmail.com>
1030 * bfdio.c (bfd_seek): Optimize away seeks to current position.
1032 2018-06-13 Scott Egerton <scott.egerton@imgtec.com>
1033 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
1035 * elfxx-mips.c (print_mips_ases): Add CRC.
1037 2018-06-08 H.J. Lu <hongjiu.lu@intel.com>
1040 * elfxx-x86.c (elf_x86_hide_linker_defined): New function.
1041 (_bfd_x86_elf_link_check_relocs): Use it to hide hidden
1042 __bss_start, _end and _edata in shared libraries.
1044 2018-06-07 Alan Modra <amodra@gmail.com>
1046 * elf32-tic6x.c (elf32_tic6x_check_relocs): Reference
1047 __c6xabi_DSBT_BASE explicitly for R_C6000_SBR_* relocs.
1049 2018-06-05 Alan Modra <amodra@gmail.com>
1051 * bfd.c (struct bfd): Update comment on "where" usage.
1052 * bfdio.c (bfd_bwrite, bfd_stat): Use and update "iovec",
1053 "iostream", and "where" from containing archive file. Return
1054 error on NULL iovec.
1055 (bfd_bread): Similarly, and return error attempted out of
1056 bounds archive element access.
1057 (bfd_tell, bfd_flush): Use and update "iovec", "iostream", and
1058 "where" from containing archive file.
1059 (bfd_seek): Likewise. Return error on NULL iovec. Don't
1060 attempt to optimize away seeks. Don't paper over errors by
1062 (bfd_get_mtime): Call bfd_stat rather than iovec->bstat.
1063 (bfd_get_size): Likewise.
1064 (bfd_mmap): Operate on and use iovec of containing archive
1065 file. Return error on NULL iovec.
1066 * cache.c (bfd_cache_lookup_worker): Abort if working on
1067 archive element bfd.
1068 (cache_bread_1): Delete bfd parameter, add FILE* parameter.
1069 Don't ignore zero byte reads.
1070 (cache_bread): Look up FILE* in cache here. Error on NULL
1072 (cache_bwrite): Rename "where" to "from".
1073 (cache_bmmap): Don't handle archive elements.
1074 * coffcode.h (coff_slurp_line_table): Exit early on zero
1076 * bfd-in2.h: Regenerate.
1078 2018-06-05 Alan Modra <amodra@gmail.com>
1081 * plugin.c (bfd_plugin_open_input): Allow for possibility of
1082 nested archives. Open file again for plugin.
1083 (try_claim): Don't save and restore file position. Close file
1085 * sysdep.h (O_BINARY): Define.
1087 2018-06-04 Max Filippov <jcmvbkbc@gmail.com>
1089 * elf32-xtensa.c (xtensa_read_table_entries): Make global.
1090 (compute_fill_extra_space): Drop declaration. Rename function to
1091 xtensa_compute_fill_extra_space.
1092 (compute_ebb_actions, remove_dead_literal): Update references to
1093 compute_fill_extra_space.
1095 2018-06-04 Volodymyr Arbatov <arbatov@cadence.com>
1097 * elf32-xtensa.c (elf32xtensa_separate_props): New global
1099 (xtensa_add_names): New function.
1100 (xtensa_property_section_name): Add new parameter
1101 separate_sections, use it to choose property section name.
1102 (xtensa_get_separate_property_section): New function.
1103 (xtensa_get_property_section): Invoke
1104 xtensa_get_separate_property_section to get individual property
1105 section if it exists, common property section otherwise.
1106 (xtensa_make_property_section): Pass elf32xtensa_separate_props
1107 to xtensa_property_section_name.
1109 2018-06-04 H.J. Lu <hongjiu.lu@intel.com>
1112 * bfd-in.h: Include "diagnostics.h".
1113 * bfd-in2.h: Regenerated.
1114 * elf32-arm.c (elf32_arm_nabi_write_core_note): Use
1115 DIAGNOSTIC_PUSH, DIAGNOSTIC_IGNORE_STRINGOP_TRUNCATION and
1116 DIAGNOSTIC_POP to silence GCC 8.1 warnings with
1117 -Wstringop-truncation.
1118 * elf32-ppc.c (ppc_elf_write_core_note): Likewse.
1119 * elf32-s390.c (elf_s390_write_core_note): Likewse.
1120 * elf64-ppc.c (ppc64_elf_write_core_note): Likewse.
1121 * elf64-s390.c (elf_s390_write_core_note): Likewse.
1122 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewse.
1124 2018-06-03 Jim Wilson <jimw@sifive.com>
1127 * elfnn-riscv.c (riscv_elf_relocate_section) <R_RISCV_CALL>: Check
1128 for and handle an undefined weak with no PLT.
1131 * elfnn-riscv.c (riscv_relax_delete_bytes): Add versioned_hidden check
1132 to code that ignores duplicate symbols.
1134 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
1136 * version.m4: Bump version to 2.30.52
1137 * configure: Regenerated.
1139 2018-06-01 Alan Modra <amodra@gmail.com>
1141 * bfd.c (_bfd_error_handler): Arrange for this function to be
1142 declared in bfd-in2.h.
1143 * libbfd-in.h (_bfd_error_handler): Don't declare.
1144 * libbfd.h: Regenerate.
1145 * bfd-in2.h: Regenerate.
1147 2018-05-30 Amaan Cheval <amaan.cheval@gmail.com>
1149 * config.bfd (x86_64-*-*): Add pei-x86-64 target to x86_64-*-rtems*
1150 This is needed to generate UEFI application image files from ELFs.
1152 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
1154 * elf32-i386.c (elf_i386_lazy_plt): Add plt_tlsdesc_entry,
1155 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
1156 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
1157 plt_tlsdesc_got2_insn_end for TLSDESC entry.
1158 (elf_i386_lazy_ibt_plt): Likewise.
1159 (elf_i386_nacl_plt): Likewise.
1160 * elf64-x86-64.c (tlsdesc_plt_entry): Moved and renamed to ...
1161 (elf_x86_64_tlsdesc_plt_entry): This.
1162 (elf_x86_64_lazy_plt): Add plt_tlsdesc_entry,
1163 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
1164 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
1165 plt_tlsdesc_got2_insn_end for TLSDESC entry.
1166 (elf_x86_64_lazy_bnd_plt): Likewise.
1167 (elf_x86_64_lazy_ibt_plt): Likewise.
1168 (elf_x32_lazy_ibt_plt): Likewise.
1169 (elf_x86_64_nacl_plt): Likewise.
1170 (elf_x86_64_finish_dynamic_sections): Use plt_tlsdesc_entry,
1171 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
1172 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
1173 plt_tlsdesc_got2_insn_end to update TLSDESC entry.
1174 * elfxx-x86.h (elf_x86_lazy_plt_layout): Update comments.
1175 Add plt_tlsdesc_entry, plt_tlsdesc_entry_size,
1176 plt_tlsdesc_got1_offset, plt_tlsdesc_got2_offset,
1177 plt_tlsdesc_got1_insn_end and plt_tlsdesc_got2_insn_end.
1178 (elf_x86_non_lazy_plt_layout): Update comments.
1179 (elf_x86_plt_layout): Likewise.
1181 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
1184 * elf-s390-common.c (elf_s390_add_symbol_hook): Removed.
1185 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
1186 (elf_backend_add_symbol_hook): Likewise.
1187 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
1188 (elf_backend_add_symbol_hook): Likewise.
1189 * elf32-s390.c (elf_backend_add_symbol_hook): Likewise.
1190 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
1191 (elf_backend_add_symbol_hook): Likewise.
1192 * elf64-s390.c (elf_backend_add_symbol_hook): Likewise.
1193 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
1194 * elfxx-aarch64.h (_bfd_aarch64_elf_add_symbol_hook): Likewise.
1195 (elf_backend_add_symbol_hook): Likewise.
1196 * elf32-arm.c (elf32_arm_add_symbol_hook): Remove STT_GNU_IFUNC
1198 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
1199 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
1200 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
1201 * elflink.c (elf_link_add_object_symbols): Set
1202 elf_gnu_symbol_ifunc for STT_GNU_IFUNC symbols.
1204 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
1207 * elf-bfd.h (_bfd_elf_link_hide_sym_by_version): New.
1208 * elflink.c (_bfd_elf_link_hide_versioned_symbol): New function.
1209 Extracted from _bfd_elf_link_assign_sym_version.
1210 (_bfd_elf_link_hide_sym_by_version): New function.
1211 (_bfd_elf_link_assign_sym_version): Use
1212 _bfd_elf_link_hide_versioned_symbol.
1213 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Call
1214 _bfd_elf_link_hide_sym_by_version instead of
1215 bfd_hide_sym_by_version. Don't check unversioned symbol.
1217 2018-05-25 Alan Modra <amodra@gmail.com>
1219 * Makefile.in: Regenerate.
1220 * po/SRC-POTFILES.in: Regenerate.
1222 2018-05-25 Alan Modra <amodra@gmail.com>
1224 * configure.ac (bfd_cv_hidden): Run test with -Werror in CFLAGS.
1225 * configure: Regenerate.
1227 2018-05-23 H.J. Lu <hongjiu.lu@intel.com>
1229 * elf64-ppc.c (ppc64_elf_write_core_note): Add ATTRIBUTE_NONSTRING
1232 2018-05-22 Alan Modra <amodra@gmail.com>
1235 * elf32-hppa.c (hppa_get_stub_entry): Return NULL when link_sec
1237 (elf32_hppa_size_stubs): Only create stubs for load, alloc, code
1239 (final_link_relocate): Revert last change.
1241 2018-05-22 Alan Modra <amodra@gmail.com>
1244 * elf32-hppa.c (final_link_relocate): Don't look for plt call
1245 stubs in non-alloc sections.
1247 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
1250 * aout-target.h (MY_bfd_link_hide_symbol): New.
1251 * aout-tic30.c (MY_bfd_link_hide_symbol): Likewise.
1252 * binary.c (binary_bfd_link_hide_symbol): Likewise.
1253 * coff-alpha.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
1254 * coff-mips.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
1255 * coff-rs6000.c (_bfd_xcoff_bfd_link_hide_symbol): Likewise.
1256 * coffcode.h (coff_bfd_link_hide_symbol): Likewise.
1257 * elf-bfd.h (_bfd_elf_link_hide_symbol): Likewise.
1258 * elfxx-target.h (bfd_elfNN_bfd_link_hide_symbol): Likewise.
1259 * i386msdos.c (msdos_bfd_link_hide_symbol): Likewise.
1260 * ihex.c (ihex_bfd_link_hide_symbol): Likewise.
1261 * libbfd-in.h (_bfd_nolink_bfd_link_hide_symbol): Likewise.
1262 * linker.c (_bfd_generic_link_hide_symbol): Likewise.
1263 (bfd_link_hide_symbol): Likewise.
1264 * mach-o-target.c (bfd_mach_o_bfd_link_hide_symbol): Likewise.
1265 * mmo.c (mmo_bfd_link_hide_symbol): Likewise.
1266 * pef.c (bfd_pef_bfd_link_hide_symbol): Likewise.
1267 * plugin.c (bfd_plugin_bfd_link_hide_symbol): Likewise.
1268 * ppcboot.c (ppcboot_bfd_link_hide_symbol): Likewise.
1269 * som.c (som_bfd_link_hide_symbol): Likewise.
1270 * srec.c (srec_bfd_link_hide_symbol): Likewise.
1271 * tekhex.c (tekhex_bfd_link_hide_symbol): Likewise.
1272 * vms-alpha.c (vms_bfd_link_hide_symbol): Likewise.
1273 (alpha_vms_bfd_link_hide_symbol): Likewise.
1274 * xsym.c (bfd_sym_bfd_link_hide_symbol): Likewise.
1275 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
1276 _bfd_generic_link_hide_symbol.
1277 (rs6000_xcoff64_aix_vec): Likewise.
1278 * elflink.c (bfd_elf_record_link_assignment): Don't make forced
1279 local symbol dynamic.
1280 (_bfd_elf_link_hide_symbol): New function.
1281 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
1282 check root.ldscript_def.
1283 * targets.c (bfd_target): Add _bfd_link_hide_symbol.
1284 (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_link_hide_symbol.
1285 * bfd-in2.h: Regenerated.
1286 * libbfd.h: Likewise.
1288 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
1291 * elf.c (setup_group): Mark section in a section group with
1294 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
1297 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
1298 set eh->local_ref to 1 if a symbol is versioned and there is a
1301 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
1303 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Handle
1306 2018-05-18 Jim Wilson <jimw@sifive.com>
1308 * elfnn-riscv.c (allocate_dynrelocs): Discard dynamic relocations if
1309 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
1310 (riscv_elf_relocate_section): Don't generate dynamic relocation if
1311 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
1312 (riscv_elf_finish_dynamic_symbol): Likewise.
1314 2018-05-18 John Darrington <john@darrington.wattle.id.au>
1316 * Makefile.am: Add s12z files.
1317 * Makefile.in: Regenerate.
1318 * archures.c: Add bfd_s12z_arch.
1319 * bfd-in.h: Add exports of bfd_putb24 and bfd_putl24.
1320 * bfd-in2.h: Regenerate.
1321 * config.bfd: Add s12z target.
1322 * configure.ac: Add s12z target.
1323 * configure: Regenerate.
1324 * cpu-s12z.c: New file.
1325 * elf32-s12z.c: New file.
1326 * libbfd.c (bfd_putb24): New function.
1327 (bfd_putl24): New function.
1328 * libbfd.h: Regenerate.
1329 * reloc.c: Add s12z relocations.
1330 (bfd_get_reloc_size): Handle size 5 relocs.
1331 * targets.c: Add s12z_elf32_vec.
1333 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
1336 * elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
1338 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
1339 set eh->local_ref to 1 for linker defined symbols.
1341 2018-05-18 Alan Modra <amodra@gmail.com>
1344 * elf.c (setup_group): Formatting. Check that SHT_GROUP entries
1345 don't point at other SHT_GROUP sections. Set shdr corresponding
1346 to invalid entry, to NULL rather than section 0. Identify
1347 SHT_GROUP section index when reporting an error. Cope with NULL
1350 2018-05-18 Alan Modra <amodra@gmail.com>
1352 * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
1353 * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
1355 * libbfd.h: Regenerate.
1356 * configure: Regenerate.
1357 * config.in: Regenerate.
1359 2018-05-18 Alan Modra <amodra@gmail.com>
1361 * libbfd-in.h: Add include guard.
1362 * libcoff-in.h: Likewise.
1363 * doc/Makefile.am (libbfd.h, libcoff.h): Append another #endif.
1364 * doc/Makefile.in: Regenerate.
1365 * libbfd.h: Regenerate.
1366 * libcoff.h: Regenerate.
1368 2018-05-16 Maciej W. Rozycki <macro@mips.com>
1370 * elf32-nds32.c (nds32_convert_32_to_16): Preset `insn_type'.
1372 2018-05-16 Alan Modra <amodra@gmail.com>
1375 * format.c (struct bfd_preserve): Add section_id.
1376 (bfd_preserve_save, bfd_preserve_restore): Save and restore
1378 (bfd_reinit): Set _bfd_section_id.
1379 (bfd_check_format_matches): Put all matches of any priority into
1380 matching_vector. Save initial section id and start each attempted
1381 match at that section id.
1382 * libbfd-in.h (_bfd_section_id): Declare.
1383 * section.c (_bfd_section_id): Rename from section_id and make
1384 global. Adjust uses.
1385 (bfd_get_next_section_id): Delete.
1386 * elf64-ppc.c (ppc64_elf_setup_section_lists): Replace use of
1387 bfd_get_section_id with _bfd_section_id.
1388 * libbfd.h: Regenerate.
1389 * bfd-in2.h: Regenerate.
1391 2018-05-15 Christophe Guillon <christophe.guillon@st.com>
1393 * coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
1394 of the aux structure are initialised.
1396 2018-05-15 Francois H. Theron <francois.theron@netronome.com>
1398 * targets.c: Wrap nfp_elf64_vec in BFD64 ifdef.
1400 2018-05-15 Nick Clifton <nickc@redhat.com>
1402 * po/pt.po: New Portuguese translation.
1403 * configure.ac (ALL_LINGUAS): Add pt.
1404 * configure: Regenerate.
1406 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
1409 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Don't issue
1410 an error on IFUNC pointer defined in PDE.
1411 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Call
1412 _bfd_x86_elf_link_fixup_ifunc_symbol.
1413 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
1414 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): New
1416 * elfxx-x86.h (_bfd_x86_elf_link_fixup_ifunc_symbol): New.
1418 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
1421 * elfxx-x86.c (elf_x86_linker_defined): New function.
1422 (_bfd_x86_elf_link_check_relocs): Use it to mark __bss_start,
1423 _end and _edata locally defined within executables.
1425 2018-05-12 Alan Modra <amodra@gmail.com>
1428 * elf.c (rewrite_elf_program_header): Use segment_mark only for
1429 PT_LOAD headers. Delete first_matching_lma and first_suggested_lma.
1430 Instead make matching_lma and suggested_lma pointers to the
1431 sections. Align section vma and lma calculated from segment.
1432 Don't clear includes_phdrs or includes_filehdr based on p_paddr
1433 test. Try to handle alignment padding before first section by
1434 adjusting new segment lma down. Adjust PT_PHDR map p_paddr.
1436 2018-05-09 Dimitar Dimitrov <dimitar@dinux.eu>
1438 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Make LDI32 relocation
1439 conformant to TI ABI.
1440 (pru_elf32_relax_section): Likewise.
1441 (pru_elf_relax_delete_bytes): Fix offsets for new LDI32 code.
1442 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Ignore addend.
1443 (pru_elf32_pmem_relocate): Trap - should not get here.
1444 (pru_elf32_relocate_section): Add support for REL relocations.
1445 (elf_info_to_howto_rel): Enable REL.
1446 (elf_backend_may_use_rel_p): Likewise.
1447 (elf_backend_may_use_rela_p): Likewise.
1448 (elf_backend_default_use_rela_p): Likewise.
1450 2018-05-09 Alan Modra <amodra@gmail.com>
1453 * peXXigen.c (pe_print_edata): Correct minimum size.
1455 2018-05-09 Alan Modra <amodra@gmail.com>
1458 * peXXigen.c (pe_print_idata): Bound check hint_addr.
1460 2018-05-08 Nick Clifton <nickc@redhat.com>
1463 * elf.c (bfd_elf_get_str_section): Check for an excessively large
1465 * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
1466 attribute section is larger than the size of the file.
1468 2018-05-07 Alan Modra <amodra@gmail.com>
1470 * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than
1471 strncmp when checking for ".bf" special symbol.
1472 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags
1473 section name a char array, remove sentinal known_sections entry,
1474 and adjust loop over known_sections to suit. Use memcmp rather
1477 2018-05-04 Alan Modra <amodra@gmail.com>
1479 * elf-linux-core.h (struct elf_external_linux_prpsinfo32_ugid32),
1480 (struct elf_external_linux_prpsinfo32_ugid16),
1481 (struct elf_external_linux_prpsinfo64_ugid32),
1482 (struct elf_external_linux_prpsinfo64_ugid16): Add ATTRIBUTE_NONSTRING
1483 to pr_fname and pr_psargs fields. Remove GCC diagnostic pragmas.
1485 * elf.c (elfcore_write_prpsinfo): ..here. Indent nested preprocessor
1487 * elf32-arm.c (elf32_arm_nabi_write_core_note): Add ATTRIBUTE_NONSTRING
1489 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
1490 * elf32-s390.c (elf_s390_write_core_note): Likewise.
1491 * elf64-s390.c (elf_s390_write_core_note): Likewise.
1492 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
1493 * elf64-x86-64.c (elf_x86_64_write_core_note): Add GCC diagnostic
1495 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Use strnlen to avoid
1496 false positive gcc-8 warning.
1497 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
1499 2018-05-04 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
1501 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Fix the order
1502 of arguments when warning about different long double types.
1504 2018-05-03 Simon Atanasyan <simon@atanasyan.com>
1506 * elf32-mips.c: (elf32_mips_fixup_symbol): New function.
1507 (elf_backend_fixup_symbol): New macro.
1508 * elfxx-mips.c: (mips_elf_output_extsym): Discard _gp_disp
1510 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
1512 2018-04-30 Francois H. Theron <francois.theron@netronome.com>
1514 * Makefile.am: Added NFP files to build.
1515 * archures.c: Added bfd_arch_nfp
1516 * config.bfd: Added NFP support.
1517 * configure.ac: Added NFP support.
1518 * cpu-nfp.c: New, for NFP support.
1519 * elf-bfd.h: Added elf_section_info()
1520 * elf64-nfp.c: New, for NFP support.
1521 * po/SRC-POTFILES.in: Added NFP source files.
1522 * targets.c: Added nfp_elf64_vec
1523 * bfd-in2.h: Regenerate.
1524 * Makefile.in: Regenerate.
1525 * configure: Regenerate.
1527 2018-04-27 Alan Modra <amodra@gmail.com>
1529 * bfd-in2.h: Regenerate.
1530 * libbfd.h: Regenerate.
1532 2018-04-27 Alan Modra <amodra@gmail.com>
1536 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't drop plt
1538 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Comment fixes.
1540 2018-04-26 Pedro Alves <palves@redhat.com>
1542 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't consider
1543 ifunc and non-ifunc symbols duplicates.
1545 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1546 Mickaël Guêné <mickael.guene@st.com>
1548 * elf32-arm.c (elf32_arm_fdpic_thumb_plt_entry): New.
1549 (elf32_arm_plt_needs_thumb_stub_p): Handle thumb-only case.
1550 (elf32_arm_populate_plt_entry): Likewise.
1551 (elf32_arm_output_plt_map_1): Likewise.
1552 (elf32_arm_output_arch_local_syms): Likewise.
1554 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1555 Mickaël Guêné <mickael.guene@st.com>
1557 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Handle
1558 _GLOBAL_OFFSET_TABLE_ in FDPIC mode.
1560 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1561 Mickaël Guêné <mickael.guene@st.com>
1563 * elf32-arm.c (bfd_elf32_arm_set_target_params): Handle FDPIC case
1566 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1567 Mickaël Guêné <mickael.guene@st.com>
1569 * elf32-arm.c (DEFAULT_STACK_SIZE): New.
1570 (elf32_arm_always_size_sections): Create stack segment.
1572 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1573 Mickaël Guêné <mickael.guene@st.com>
1575 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
1576 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
1578 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
1579 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
1580 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
1581 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
1582 (struct elf32_arm_link_hash_table): Update comment.
1583 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
1584 (IS_ARM_TLS_RELOC): Likewise.
1585 (elf32_arm_check_relocs): Likewise.
1586 (allocate_dynrelocs_for_symbol): Likewise.
1587 (elf32_arm_size_dynamic_sections): Update comment.
1588 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
1589 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
1591 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1592 Mickaël Guêné <mickael.guene@st.com>
1594 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
1595 (elf32_arm_create_dynamic_sections): Handle FDPIC.
1596 (elf32_arm_allocate_plt_entry): Likewise.
1597 (elf32_arm_populate_plt_entry): Likewise.
1598 (elf32_arm_output_plt_map_1): Likewise.
1600 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1601 Mickaël Guêné <mickael.guene@st.com>
1603 * elf32-arm.c (struct fdpic_local): New.
1604 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
1605 (elf32_arm_local_fdpic_cnts): New.
1606 (struct fdpic_global): New.
1607 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
1608 (elf32_arm_link_hash_table): Add srofixup field.
1609 (arm_elf_add_rofixup): New.
1610 (arm_elf_fill_funcdesc): New.
1611 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
1612 (elf32_arm_allocate_local_sym_info): Likewise.
1613 (create_got_section): Create .rofixup section.
1614 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
1615 (bfd_elf32_arm_set_target_params): Handle FDPIC.
1616 (elf32_arm_final_link_relocate): Likewise.
1617 (elf32_arm_check_relocs): Likewise.
1618 (allocate_dynrelocs_for_symbol): Likewise.
1619 (elf32_arm_size_dynamic_sections): Likewise.
1620 (elf32_arm_finish_dynamic_sections): Likewise.
1621 (elf32_arm_output_arch_local_syms): Likewise.
1622 (elf32_arm_fdpic_omit_section_dynsym): New.
1624 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1625 Mickaël Guêné <mickael.guene@st.com>
1627 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
1628 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
1629 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
1630 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
1631 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
1632 (elf32_arm_howto_from_type): Take new members of
1633 elf32_arm_howto_table_2 into account.
1634 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
1635 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
1636 BFD_RELOC_ARM_FUNCDESC_VALUE.
1637 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
1638 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
1639 BFD_RELOC_ARM_FUNCDESC_VALUE.
1641 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1642 Mickaël Guêné <mickael.guene@st.com>
1644 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
1645 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
1646 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
1647 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
1649 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1650 Mickaël Guêné <mickael.guene@st.com>
1652 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
1653 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
1654 arm*-*-uclinuxfdpiceabi.
1655 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
1656 arm_elf32_fdpic_le_vec.
1657 * configure: Regenerate.
1658 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
1659 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
1660 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
1661 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
1662 (elf32_arm_fdpic_link_hash_table_create): New.
1663 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
1664 arm_elf32_fdpic_le_vec.
1666 2018-04-25 Alan Modra <amodra@gmail.com>
1668 * elf-linux-core.h: Disable gcc-8 string truncation warning.
1669 * elf.c (elfcore_write_prpsinfo): Likewise.
1671 2018-04-25 Alan Modra <amodra@gmail.com>
1673 * Makefile.am: Remove arm-aout and arm-coff support.
1674 * config.bfd: Likewise.
1675 * configure.ac: Likewise.
1676 * targets.c: Likewise.
1677 * aout-arm.c: Delete.
1678 * armnetbsd.c: Delete.
1680 * Makefile.in: Regenerate.
1681 * configure: Regenerate.
1682 * po/SRC-POTFILES.in: Regenerate.
1684 2018-04-24 Nick Clifton <nickc@redhat.com>
1687 * elf.c (ignore_section_sym): Check for the output_section pointer
1688 being NULL before dereferencing it.
1691 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
1692 a negative PE_DEBUG_DATA size before iterating over the debug data.
1694 2018-04-23 Alan Modra <amodra@gmail.com>
1696 * elf-linux-core.h: Revert last change.
1699 2018-04-23 Nick Clifton <nickc@redhat.com>
1702 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
1703 the end of the string table, and zero it.
1705 2018-04-23 Alan Modra <amodra@gmail.com>
1707 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
1708 gcc-8 string truncation warning.
1709 (swap_linux_prpsinfo32_ugid16_out): Likewise.
1710 (swap_linux_prpsinfo64_ugid32_out): Likewise.
1711 (swap_linux_prpsinfo64_ugid16_out): Likewise.
1712 * elf.c (elfcore_write_prpsinfo): Likewise.
1714 2018-04-23 Nick Clifton <nickc@redhat.com>
1717 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
1718 the end of the string table, and zero it.
1720 2018-04-20 Alan Modra <amodra@gmail.com>
1723 * elf32-hppa.c (got_relocs_needed): Add extra param to special
1724 case both dtprel and tprel relocs.
1725 (allocate_dynrelocs): Adjust conditions for got relocs.
1726 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
1727 Emit dynamic relocs on TLS GOT entries for shared libraries,
1728 not when pic. Omit dynamic reloc on dtprel entry when local,
1729 and on tprel entry when local and executable.
1731 2018-04-19 Alan Modra <amodra@gmail.com>
1734 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
1735 (hppa_type_of_stub): Don't return a long branch stub for
1736 symbols other than those defined statically.
1738 2018-04-19 Alan Modra <amodra@gmail.com>
1740 * Makefile.am: Revert 2018-04-18 coff-mips changes.
1741 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
1742 to selvecs for mips targets change 2018-04-18.
1743 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
1744 and mips_ecoff_bele_vec.
1745 * targets.c: Likewise.
1746 * coff-mips.c: Resurrect.
1747 * Makefile.in: Regenerate.
1748 * configure: Regenerate.
1749 * po/SRC-POTFILES.in: Regenerate.
1751 2018-04-18 Alan Modra <amodra@gmail.com>
1753 * Makefile.am: Remove mips aout and coff support.
1754 * config.bfd: Likewise.
1755 * configure.ac: Likewise.
1756 * targets.c: Likewise.
1757 * coff-mips.c: Delete
1760 * pei-mips.c: Delete
1761 * Makefile.in: Regenerate.
1762 * configure: Regenerate.
1763 * po/SRC-POTFILES.in: Regenerate.
1765 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
1767 * elf32-i386.c (elf32_bed): Define before including
1769 * elf64-x86-64.c (elf64_bed): Define before including
1771 (elf32_bed): Define before including "elf32-target.h".
1773 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
1776 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
1777 normal input file with compatible relocation.
1779 2018-04-18 Alan Modra <amodra@gmail.com>
1781 * Makefile.am: Remove support for assorted i386 aout and coff targets.
1782 * config.bfd: Likewise.
1783 * configure.ac: Likewise.
1784 * doc/bfdint.texi: Likewise.
1785 * targets.c: Likewise.
1786 * freebsd.h: Delete.
1787 * i386dynix.c: Delete.
1788 * i386freebsd.c: Delete.
1789 * i386linux.c: Delete.
1790 * i386mach3.c: Delete.
1791 * i386netbsd.c: Delete.
1792 * i386os9k.c: Delete.
1793 * Makefile.in: Regenerate.
1794 * configure: Regenerate.
1795 * po/SRC-POTFILES.in: Regenerate.
1797 2018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
1799 Microblaze Target: PIC data text relative
1801 * bfd/reloc.c (2 new BFD relocations):
1802 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
1803 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
1804 * bfd/bfd-in2.h: Regenerate
1805 * bfd/libbfd.h: Regenerate
1806 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
1807 new relocs and handle them in both relocate and relax functions.
1808 (microblaze_elf_reloc_type_lookup): add mapping between for new
1810 (microblaze_elf_relocate_section): Handle new relocs in case of
1812 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
1814 2018-04-17 Nick Clifton <nickc@redhat.com>
1817 * aoutx.h (find_nearest_line): Check that the symbol name exists
1818 and is long enough, before attempting to see if it is for a .o
1820 * hash.c (bfd_hash_hash): Add an assertion that the string is not
1822 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
1824 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
1828 * dwarf2.c (concat_filename): Check for a NULL table pointer.
1830 2018-04-16 Nick Clifton <nickc@redhat.com>
1833 * coffgen.c (coff_pointerize_aux): Check for an out of range
1836 2018-04-16 Alan Modra <amodra@gmail.com>
1838 * Makefile.am: Remove arm-epoc-pe support.
1839 * coff-arm.c: Likewise.
1840 * config.bfd: Likewise.
1841 * configure.ac: Likewise.
1842 * targets.c: Likewise.
1843 * epoc-pe-arm.c: Delete.
1844 * epoc-pei-arm.c: Delete.
1845 * Makefile.in: Regenerate.
1846 * configure: Regenerate.
1847 * po/SRC-POTFILES.in: Regenerate.
1849 2018-04-16 Alan Modra <amodra@gmail.com>
1851 * Makefile.am: Remove sparc-aout and sparc-coff support.
1852 * config.bfd: Likewise.
1853 * configure.ac: Likewise.
1854 * targets.c: Likewise.
1855 * aout-sparcle.c: Delete.
1857 * cf-sparclynx.c: Delete.
1858 * coff-sparc.c: Delete.
1860 * sparclinux.c: Delete.
1861 * sparclynx.c: Delete.
1862 * sparcnetbsd.c: Delete.
1864 * Makefile.in: Regenerate.
1865 * configure: Regenerate.
1866 * po/SRC-POTFILES.in: Regenerate.
1868 2018-04-16 Alan Modra <amodra@gmail.com>
1870 * Makefile.am: Remove m68k-aout and m68k-coff support.
1871 * aoutf1.h: Likewise.
1872 * aoutx.h: Likewise.
1873 * archive.c: Likewise.
1874 * bfd-in.h: Likewise.
1876 * coffcode.h: Likewise.
1877 * coffswap.h: Likewise.
1878 * config.bfd: Likewise.
1879 * configure.ac: Likewise.
1880 * configure.host: Likewise.
1881 * doc/bfd.texinfo: Likewise.
1882 * doc/bfdint.texi: Likewise.
1883 * freebsd.h: Likewise.
1884 * gen-aout.c: Likewise.
1885 * hpux-core.c: Likewise.
1886 * libaout.h: Likewise.
1887 * libbfd-in.h: Likewise.
1888 * pdp11.c: Likewise.
1889 * peicode.h: Likewise.
1890 * riscix.c: Likewise.
1891 * targets.c: Likewise.
1893 * coff-apollo.c: Delete.
1894 * coff-aux.c: Delete.
1895 * coff-m68k.c: Delete.
1896 * coff-svm68k.c: Delete.
1897 * coff-u68k.c: Delete.
1898 * hosts/delta68.h: Delete.
1899 * hosts/hp300bsd.h: Delete.
1900 * hosts/m68kaux.h: Delete.
1901 * hosts/news.h: Delete.
1902 * hp300bsd.c: Delete.
1903 * hp300hpux.c: Delete.
1904 * liboasys.h: Delete.
1905 * m68k4knetbsd.c: Delete.
1906 * m68klinux.c: Delete.
1907 * m68knetbsd.c: Delete.
1909 * versados.c: Delete.
1910 * Makefile.in: Regenerate.
1911 * bfd-in2.h: Regenerate.
1912 * configure: Regenerate.
1913 * libbfd.h: Regenerate.
1914 * po/SRC-POTFILES.in: Regenerate.
1916 2018-04-16 Alan Modra <amodra@gmail.com>
1918 * Makefile.am: Remove sh5 and sh64 support.
1919 * archures.c: Likewise.
1920 * config.bfd: Likewise.
1921 * configure.ac: Likewise.
1922 * cpu-sh.c: Likewise.
1923 * elf32-sh-relocs.h: Likewise.
1924 * elf32-sh.c: Likewise.
1925 * targets.c: Likewise.
1926 * elf32-sh64-com.c: Delete.
1927 * elf32-sh64.c: Delete.
1928 * elf32-sh64.h: Delete.
1929 * elf64-sh64.c: Delete.
1930 * Makefile.in: Regenerate.
1931 * bfd-in2.h: Regenerate.
1932 * configure: Regenerate.
1933 * po/SRC-POTFILES.in: Regenerate.
1935 2018-04-16 Alan Modra <amodra@gmail.com>
1937 * Makefile.am: Remove sh-symbianelf support.
1938 * config.bfd: Likewise.
1939 * configure.ac: Likewise.
1940 * targets.c: Likewise.
1941 * elf32-sh-symbian.c: Delete.
1942 * Makefile.in: Regenerate.
1943 * configure: Regenerate.
1944 * po/SRC-POTFILES.in: Regenerate.
1946 2018-04-16 Alan Modra <amodra@gmail.com>
1948 * Makefile.am: Remove vax-bsd and vax-ultrix support.
1949 * config.bfd: Likewise.
1950 * configure.ac: Likewise.
1951 * targets.c: Likewise.
1953 * Makefile.in: Regenerate.
1954 * configure: Regenerate.
1955 * po/SRC-POTFILES.in: Regenerate.
1957 2018-04-16 Alan Modra <amodra@gmail.com>
1959 * Makefile.am: Remove w65 support.
1960 * archures.c: Likewise.
1961 * coffcode.h: Likewise.
1962 * config.bfd: Likewise.
1963 * configure.ac: Likewise.
1964 * targets.c: Likewise.
1965 * coff-w65.c: Delete.
1966 * cpu-w65.c: Delete.
1967 * Makefile.in: Regenerate.
1968 * bfd-in2.h: Regenerate.
1969 * configure: Regenerate.
1970 * po/SRC-POTFILES.in: Regenerate.
1972 2018-04-16 Alan Modra <amodra@gmail.com>
1974 * Makefile.am: Remove we32k support.
1975 * archures.c: Likewise.
1976 * coffcode.h: Likewise.
1977 * config.bfd: Likewise.
1978 * configure.ac: Likewise.
1979 * targets.c: Likewise.
1980 * coff-we32k.c: Delete.
1981 * cpu-we32k.c: Delete.
1982 * Makefile.in: Regenerate.
1983 * bfd-in2.h: Regenerate.
1984 * configure: Regenerate.
1985 * po/SRC-POTFILES.in: Regenerate.
1987 2018-04-16 Alan Modra <amodra@gmail.com>
1989 * Makefile.am: Remove m88k support.
1990 * aoutx.h: Likewise.
1991 * archures.c: Likewise.
1992 * coffcode.h: Likewise.
1993 * coffswap.h: Likewise.
1994 * config.bfd: Likewise.
1995 * configure.ac: Likewise.
1996 * cpu-ns32k.c: Likewise.
1997 * elf32-nds32.c: Likewise.
1998 * mach-o.c: Likewise.
1999 * netbsd-core.c: Likewise.
2000 * reloc.c: Likewise.
2001 * targets.c: Likewise.
2002 * coff-m88k.c: Delete.
2003 * cpu-m88k.c: Delete.
2004 * elf32-m88k.c: Delete.
2005 * hosts/m88kmach3.h: Delete.
2006 * m88kmach3.c: Delete.
2007 * m88kopenbsd.c: Delete.
2008 * Makefile.in: Regenerate.
2009 * bfd-in2.h: Regenerate.
2010 * configure: Regenerate.
2011 * po/SRC-POTFILES.in: Regenerate.
2013 2018-04-16 Alan Modra <amodra@gmail.com>
2015 * Makefile.am: Remove i370 support.
2016 * archures.c: Likewise.
2017 * config.bfd: Likewise.
2018 * configure.ac: Likewise.
2019 * targets.c: Likewise.
2020 * cpu-i370.c: Delete.
2021 * elf32-i370.c: Delete.
2022 * Makefile.in: Regenerate.
2023 * bfd-in2.h: Regenerate.
2024 * configure: Regenerate.
2025 * po/SRC-POTFILES.in: Regenerate.
2027 2018-04-16 Alan Modra <amodra@gmail.com>
2029 * Makefile.am: Remove h8500 support.
2030 * archures.c: Likewise.
2031 * coffcode.h: Likewise.
2032 * config.bfd: Likewise.
2033 * configure.ac: Likewise.
2034 * targets.c: Likewise.
2035 * coff-h8500.c: Delete.
2036 * cpu-h8500.c: Delete.
2037 * Makefile.in: Regenerate.
2038 * bfd-in2.h: Regenerate.
2039 * configure: Regenerate.
2040 * po/SRC-POTFILES.in: Regenerate.
2042 2018-04-16 Alan Modra <amodra@gmail.com>
2044 * Makefile.am: Remove h8300-coff support.
2045 * coffcode.h: Likewise.
2046 * config.bfd: Likewise.
2047 * configure.ac: Likewise.
2048 * reloc16.c: Likewise.
2049 * targets.c: Likewise.
2050 * coff-h8300.c: Delete.
2051 * Makefile.in: Regenerate.
2052 * configure: Regenerate.
2053 * po/SRC-POTFILES.in: Regenerate.
2055 2018-04-16 Alan Modra <amodra@gmail.com>
2057 * Makefile.am: Remove IEEE 695 support.
2058 * archures.c: Likewise.
2060 * config.bfd: Likewise.
2061 * configure.ac: Likewise.
2062 * doc/bfd.texinfo: Likewise.
2063 * doc/bfdint.texi: Likewise.
2064 * doc/bfdsumm.texi: Likewise.
2065 * section.c: Likewise.
2066 * targets.c: Likewise.
2068 * libieee.h: Delete.
2069 * Makefile.in: Regenerate.
2070 * bfd-in2.h: Regenerate.
2071 * configure: Regenerate.
2072 * po/SRC-POTFILES.in: Regenerate.
2074 2018-04-16 Alan Modra <amodra@gmail.com>
2076 * config.bfd: Remove tandem support.
2078 2018-04-16 Alan Modra <amodra@gmail.com>
2080 * Makefile.am: Remove newsos3 support.
2081 * aoutx.h: Likewise.
2082 * config.bfd: Likewise.
2083 * configure.ac: Likewise.
2084 * targets.c: Likewise.
2085 * newsos3.c: Delete.
2086 * Makefile.in: Regenerate.
2087 * configure: Regenerate.
2088 * po/SRC-POTFILES.in: Regenerate.
2090 2018-04-16 Alan Modra <amodra@gmail.com>
2092 * Makefile.am: Remove netware support.
2093 * bfd-in.h: Likewise.
2095 * config.bfd: Likewise.
2096 * configure.ac: Likewise.
2097 * doc/bfdint.texi: Likewise.
2098 * ecoff.c: Likewise.
2099 * targets.c: Likewise.
2101 * nlm-target.h: Delete.
2103 * nlm32-alpha.c: Delete.
2104 * nlm32-i386.c: Delete.
2105 * nlm32-ppc.c: Delete.
2106 * nlm32-sparc.c: Delete.
2109 * nlmcode.h: Delete.
2110 * nlmswap.h: Delete.
2111 * Makefile.in: Regenerate.
2112 * bfd-in2.h: Regenerate.
2113 * configure: Regenerate.
2114 * po/SRC-POTFILES.in: Regenerate.
2116 2018-04-16 Alan Modra <amodra@gmail.com>
2118 * archures.c: Remove tahoe support.
2119 * config.bfd: Likewise.
2120 * configure.ac: Likewise.
2121 * hosts/tahoe.h: Delete.
2122 * bfd-in2.h: Regenerate.
2123 * configure: Regenerate.
2125 2018-04-14 Alan Modra <amodra@gmail.com>
2127 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
2128 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
2130 (elfNN_bed): Init relropagesize.
2131 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
2132 select relropagesize.
2133 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
2134 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
2135 (ELF_MINPAGESIZE): Don't define.
2136 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
2137 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
2138 * bfd-in2.h: Regenerate.
2140 2018-04-14 Alan Modra <amodra@gmail.com>
2142 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
2143 on __QNXTARGET__ define.
2145 2018-04-14 Alan Modra <amodra@gmail.com>
2147 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
2150 2018-04-11 Alan Modra <amodra@gmail.com>
2152 * aout-adobe.c: Delete.
2154 * coff-i860.c: Delete.
2155 * coff-i960.c: Delete.
2156 * cpu-i860.c: Delete.
2157 * cpu-i960.c: Delete.
2158 * elf32-i860.c: Delete.
2159 * elf32-i960.c: Delete.
2160 * hosts/i860mach3.h: Delete.
2161 * Makefile.am: Remove i860, i960, bout, and adobe support.
2162 * archures.c: Remove i860 and i960 support.
2163 * coffcode.h: Likewise.
2164 * reloc.c: Likewise.
2165 * aoutx.h: Comment updates.
2166 * archive.c: Remove BOUT and i960 support.
2167 * bfd.c: Remove BOUT support.
2168 * coffswap.h: Remove i960 support.
2169 * config.bfd: Remove i860, i960 and adobe targets.
2170 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
2171 * targets.c: Likewise.
2172 * ieee.c: Remove i960 support.
2173 * mach-o.c: Remove i860 support.
2174 * Makefile.in: Regenerate.
2175 * bfd-in2.h: Regenerate.
2176 * configure: Regenerate.
2177 * libbfd.h: Regenerate.
2178 * po/SRC-POTFILES.in: Regenerate.
2180 2018-04-09 Maciej W. Rozycki <macro@mips.com>
2182 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
2183 in the BFD symbol referred by the relocation.
2184 (mips_elf64_write_rela): Likewise.
2186 2018-04-09 Maciej W. Rozycki <macro@mips.com>
2188 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
2189 error for out-of-range `r_sym' values.
2191 2018-04-09 Alan Modra <amodra@gmail.com>
2193 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
2194 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
2195 (ppc64_elf_check_relocs): Set has_pltcall.
2196 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
2197 (ppc64_elf_inline_plt): New function.
2198 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
2199 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
2200 * elf32-ppc.c (has_pltcall): Define.
2201 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
2202 (ppc_elf_check_relocs): Set has_pltcall.
2203 (ppc_elf_inline_plt): New function.
2204 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
2205 (ppc_elf_size_dynamic_sections): Likewise.
2206 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
2208 2018-04-09 Alan Modra <amodra@gmail.com>
2210 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
2211 (is_plt_seq_reloc): New function.
2212 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
2213 (ppc_elf_tls_optimize): Handle inline plt call sequence.
2214 (ppc_elf_relax_section): Handle PLTCALL reloc.
2215 (ppc_elf_relocate_section): Nop out inline plt call sequence when
2217 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
2218 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
2219 (has_tls_get_addr_call): Correct comment.
2220 (is_branch_reloc): Add PLTCALL.
2221 (is_plt_seq_reloc): New function.
2222 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
2223 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
2224 entry for R_PPC64_PLTCALL.
2225 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
2226 (ppc_type_of_stub): Handle PLTCALL reloc.
2227 (toc_adjusting_stub_needed): Likewise.
2228 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
2229 reloc insn. Nop out inline plt call sequence when resolving
2230 locally. Handle __tls_get_addr inline plt call optimization.
2232 2018-04-09 Alan Modra <amodra@gmail.com>
2234 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
2235 (struct ppc_stub_hash_entry): Add symtype field.
2237 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
2238 (create_linkage_sections): Create pltlocal and relpltlocal.
2239 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
2241 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
2242 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
2243 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
2244 Keep PLT entries for inline calls against locals.
2245 (ppc_build_one_stub): Use pltlocal as appropriate.
2246 (ppc_size_one_stub): Likewise.
2247 (ppc64_elf_size_stubs): Set symtype.
2248 (build_global_entry_stubs_and_plt): Init pltlocal and write
2249 relpltlocal for globals.
2250 (write_plt_relocs_for_local_syms): Likewise for local syms.
2251 (ppc64_elf_relocate_section): Support PLT for local syms.
2252 * elf32-ppc.c (PLT_KEEP): Define.
2253 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
2254 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
2255 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
2256 Set PLT_KEEP. Adjust update_local_sym_info call.
2257 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
2258 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
2259 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
2260 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
2261 (write_global_sym_plt): Init pltlocal and write relpltlocal.
2262 (ppc_finish_symbols): Likewise for locals.
2264 2018-04-09 Alan Modra <amodra@gmail.com>
2266 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
2267 for local symbols to..
2268 (write_plt_relocs_for_local_syms): ..here. New function.
2269 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
2271 (build_global_entry_stubs_and_plt): ..here. Rename from
2272 build_global_entry_stubs.
2273 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
2274 Call write_plt_relocs_for_local_syms.
2275 * elf32-ppc.c (get_sym_h): New function.
2276 (ppc_elf_relax_section): Use get_sym_h.
2277 (ppc_elf_relocate_section): Move output of PLT relocs and glink
2278 stubs for local symbols to..
2279 (ppc_finish_symbols): ..here. New function.
2280 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
2282 (write_global_sym_plt): ..here. New function.
2283 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
2284 (ppc_finish_symbols): Declare.
2286 2018-04-09 Alan Modra <amodra@gmail.com>
2288 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
2289 (ppc_elf_relocate_section): Likewise.
2290 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
2291 (ppc64_elf_relocate_section): Likewise. Correct PLT16
2292 resolution to plt entry relative to toc pointer.
2294 2018-04-09 Alan Modra <amodra@gmail.com>
2296 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
2297 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
2298 file when other TLS flags are tested in a mask.
2299 (TLS_MARK, NON_GOT): Define.
2300 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
2301 (update_local_sym_info): Don't create got entry when NON_GOT.
2302 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
2304 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
2305 (ppc64_elf_relocate_section): Likewise.
2306 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
2307 __tls_get_addr calls lacking a marker reloc.
2308 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
2309 TLS_TPRELGD): Renumber. Update comment.
2310 (TLS_MARK, NON_GOT): Define.
2311 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
2312 (update_local_sym_info): Don't create got entry when NON_GOT.
2313 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
2315 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
2316 __tls_get_addr calls lacking a marker reloc.
2318 2018-04-06 H.J. Lu <hongjiu.lu@intel.com>
2320 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
2321 R_X86_64_converted_reloc_bit.
2323 2018-04-05 H.J. Lu <hongjiu.lu@intel.com>
2326 * configure: Regenerated.
2328 2018-04-05 Alan Modra <amodra@gmail.com>
2330 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
2331 (elf_hppa_info_to_howto_rel): Likewise.
2333 2018-04-04 Maciej W. Rozycki <macro@mips.com>
2335 * elf-hppa.h (elf_hppa_info_to_howto): Also return
2336 unsuccessfully for unimplemented relocations.
2337 (elf_hppa_info_to_howto_rel): Likewise.
2339 2018-04-04 Maciej W. Rozycki <macro@mips.com>
2341 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
2342 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
2343 howto lookup failure.
2344 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
2346 (elf32_i860_info_to_howto_rela): Likewise.
2347 (elf32_i860_relocate_splitn): Likewise.
2348 (elf32_i860_relocate_pc16): Likewise.
2349 (elf32_i860_relocate_pc26): Likewise.
2350 (elf32_i860_relocate_section): Likewise.
2352 2018-04-04 Maciej W. Rozycki <macro@mips.com>
2354 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
2355 check for `visium_elf_howto_table' table access.
2357 2018-04-04 Maciej W. Rozycki <macro@mips.com>
2359 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
2360 check for `iq2000_elf_howto_table' table access.
2362 2018-04-04 Maciej W. Rozycki <macro@mips.com>
2364 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
2365 for `elf32_frv_howto_table' table access.
2367 2018-04-04 Maciej W. Rozycki <macro@mips.com>
2369 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
2370 unsuccessfully for placeholder howtos.
2371 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
2372 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
2374 2018-03-29 Maciej W. Rozycki <macro@mips.com>
2376 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
2377 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
2379 2018-03-28 Maciej W. Rozycki <macro@mips.com>
2381 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
2382 ATTRIBUTE_UNUSED from `abfd'.
2384 2018-03-28 Maciej W. Rozycki <macro@mips.com>
2386 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
2387 `_bfd_error_handler' call formatting.
2389 2018-03-28 Maciej W. Rozycki <macro@mips.com>
2391 * elf32-mips.c (mips_info_to_howto_rel): Call
2392 `mips_elf32_rtype_to_howto' directly rather than via
2393 `->elf_backend_mips_rtype_to_howto'.
2395 2018-03-28 Renlin Li <renlin.li@arm.com>
2398 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
2399 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
2400 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
2401 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
2402 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
2403 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
2404 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
2405 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
2406 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
2407 (elfNN_aarch64_final_link_relocate): Support new relocations.
2408 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
2410 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
2412 2018-03-28 Renlin Li <renlin.li@arm.com>
2415 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
2416 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
2417 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
2418 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
2419 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
2420 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
2421 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
2422 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
2423 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
2424 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
2425 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
2426 TLSLE_LDST16_TPREL_LO12,
2427 TLSLE_LDST16_TPREL_LO12_NC,
2428 TLSLE_LDST32_TPREL_LO12,
2429 TLSLE_LDST32_TPREL_LO12_NC,
2430 TLSLE_LDST64_TPREL_LO12,
2431 TLSLE_LDST64_TPREL_LO12_NC,
2432 TLSLE_LDST8_TPREL_LO12,
2433 TLSLE_LDST8_TPREL_LO12_NC.
2434 * bfd-in2.h: Regenerated.
2435 * libbfd.h: Regenerated.
2437 2018-03-28 Eric Botcazou <ebotcazou@adacore.com>
2440 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
2441 has_old_style_got_reloc.
2442 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
2443 relocations. Fix a couple of long lines.
2444 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
2445 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
2448 2018-03-25 H.J. Lu <hongjiu.lu@intel.com>
2451 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
2452 ENDBR64 to the TLSDESC PLT entry.
2454 2018-03-21 Alan Modra <amodra@gmail.com>
2456 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
2457 symbols. Use size_t counts. Delete redundant opd test.
2459 2018-03-21 Alan Modra <amodra@gmail.com>
2461 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
2463 2018-03-21 Alan Modra <amodra@gmail.com>
2465 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
2467 (update_local_sym_info): Likewise for local_got_tls_masks.
2468 (ppc_elf_tls_optimize): Likewise for lgot_masks.
2470 2018-03-21 Alan Modra <amodra@gmail.com>
2472 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
2473 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
2474 do in size_dynamic_sections.
2476 2018-03-21 Alan Modra <amodra@gmail.com>
2478 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
2479 without first checking array bounds.
2480 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
2482 2018-03-20 H.J. Lu <hongjiu.lu@intel.com>
2485 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
2486 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
2488 2018-03-19 Nick Clifton <nickc@redhat.com>
2490 * po/es.po: Updated Spanish translation.
2492 2018-03-15 Max Filippov <jcmvbkbc@gmail.com>
2494 * elf32-xtensa.c (xlate_map_entry): Change types of address
2495 fields from 'unsigned' to 'bfd_vma'.
2496 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
2497 the key argument to bsearch. Allow offsets past the end of a
2498 section, use the last map entry for translation of such offsets.
2500 2018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2502 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
2503 Not support the target feature.
2504 (nds32_elf_ex9_itb_base): Likewise.
2505 (nds32_elf_ex9_import_table): Likewise.
2506 (nds32_elf_ex9_finish): Likewise.
2507 (nds32_elf_ex9_reloc_jmp): Likewise.
2508 (nds32_elf_get_insn_with_reg): Likewise.
2509 (nds32_get_local_syms): Likewise.
2510 (nds32_elf_ex9_replace_instruction): Likewise.
2511 (nds32_elf_ifc_calc): Likewise.
2512 (nds32_elf_ifc_finish): Likewise.
2513 (nds32_elf_ifc_replace): Likewise.
2514 (nds32_elf_ifc_reloc): Likewise.
2516 2018-03-14 Alan Modra <amodra@gmail.com>
2518 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
2519 sfpr size added before defining alias symbols.
2520 (ppc64_elf_build_stubs): Add stub section padding before
2521 copying sfpr contents and defining save/restore alias symbols.
2523 2018-03-14 H.J. Lu <hongjiu.lu@intel.com>
2526 * elflink.c (elf_gc_mark_debug_section): Also check the local
2527 debug definition section.
2529 2018-03-13 Nick Clifton <nickc@redhat.com>
2532 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
2533 function. Add an end address parameter. Check access of the data
2534 pointer to make sure that they do not extend beyond the end
2535 address. Return FALSE if any check fails. Add the end address
2536 pointer to the ui structure.
2537 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
2538 codes to make sure that they do not extend beyond the end address
2539 pointer. Print an error message and return immediately if any
2542 2018-03-09 Nick Clifton <nickc@redhat.com>
2544 * elf64-s390.c (elf_s390_relocate_section): Move check for
2545 relocations against non-allocated sections to before the code that
2546 handles ifunc relocations.
2547 * elf32-s390.c (elf_s390_relocate_section): Likewise.
2548 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
2549 relocs against IFUNC symbols in non-allocated sections as relocs
2550 against FUNC symbols.
2551 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
2553 2018-03-08 H.J. Lu <hongjiu.lu@intel.com>
2556 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
2557 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
2558 relocation against FUNC symbol.
2559 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
2561 2018-03-07 Renlin Li <renlin.li@arm.com>
2564 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
2565 symbol, and don't emit relocation in specific case.
2567 2018-03-07 Alan Modra <amodra@gmail.com>
2569 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
2570 (mips_elf64_slurp_one_reloc_table): Pass on error.
2572 2018-03-03 James Cowgill <james.cowgill@mips.com>
2573 Maciej W. Rozycki <macro@mips.com>
2576 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
2577 after calling `undefined_symbol' hook if this is an error
2578 condition. Assume the value of 0 for the symbol requested
2581 2018-03-02 Jim Wilson <jimw@sifive.com>
2584 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
2585 and nop instead of 4.
2586 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
2589 2018-03-01 Jim Wilson <jimw@sifive.com>
2592 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
2593 else if instead of if.
2595 2018-03-01 Alan Modra <amodra@gmail.com>
2597 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
2599 2018-02-28 Alan Modra <amodra@gmail.com>
2602 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
2604 2018-02-28 Nick Clifton <nickc@redhat.com>
2608 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
2609 pointer. Drop unused abfd parameter. Check the size of the block
2610 before initialising the data field. Return the end pointer if the
2612 (read_attribute_value): Adjust invocations of read_n_bytes.
2615 * dwarf1.c (parse_die): Check the length of form blocks before
2616 advancing the data pointer.
2618 2018-02-28 Alan Modra <amodra@gmail.com>
2621 * aoutx.h (translate_symbol_table): Print an error message and set
2622 bfd_error on finding an invalid name string offset.
2624 2018-02-27 H.J. Lu <hongjiu.lu@intel.com>
2626 * config.in: Regenerated.
2627 * configure: Likewise.
2628 * configure.ac: Add --enable-separate-code.
2629 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
2630 to 1 for Linux/x86 targets,
2631 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
2632 DEFAULT_LD_Z_SEPARATE_CODE is 1.
2634 2018-02-27 Nick Clifton <nickc@redhat.com>
2636 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
2638 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
2639 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
2640 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
2641 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
2642 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
2643 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
2644 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
2645 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
2646 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
2649 * elf-bfd.h (struct elf_backend_data): Change the return type of
2650 the elf_info_to_howto and elf_info_to_howto_rel function pointers
2652 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
2653 value from the info_to_howto function and fail if that function
2655 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
2656 from the info_to_howto function.
2657 (elf32_h8_relax_section): Likewise.
2658 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
2659 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
2660 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
2661 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
2662 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
2663 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
2664 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
2665 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
2666 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
2667 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
2668 (riscv_elf_relocate_section): Likewise.
2669 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
2670 bfd_boolean. Issue an error message, set an error value and
2671 return FALSE if the reloc is not recognized.
2672 (elf_hppa_info_to_howto_rel): Likewise.
2673 * elf-m10200.c (mn10200_info_to_howto): Likewise.
2674 * elf-m10300.c (mn10300_info_to_howto): Likewise.
2675 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
2676 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
2677 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
2678 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
2679 * elf32-bfin.c (bfin_info_to_howto): Likewise.
2680 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
2681 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
2682 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
2683 (cris_info_to_howto_rela): Likewise.
2684 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
2685 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
2686 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
2688 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
2689 (elf32_dlx_info_to_howto_rel): Likewise.
2690 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
2691 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
2692 * elf32-frv.c (frv_info_to_howto_rela)
2693 (frvfdpic_info_to_howto_rel): Likewise.
2694 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
2695 * elf32-gen.c (elf_generic_info_to_howto)
2696 (elf_generic_info_to_howto_rel): Likewise.
2697 * elf32-h8300.c (elf32_h8_info_to_howto)
2698 (elf32_h8_info_to_howto_rel): Likewise.
2699 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
2700 * elf32-i386.c (elf_i386_reloc_type_lookup)
2701 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
2702 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
2704 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
2705 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
2706 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
2707 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
2708 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
2709 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
2711 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
2712 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
2713 * elf32-m68k.c (rtype_to_howto): Likewise.
2714 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
2715 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
2716 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
2717 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
2718 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
2720 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
2721 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
2722 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
2723 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
2725 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
2726 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
2727 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
2728 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
2729 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
2730 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
2731 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
2732 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
2733 * elf32-score.c (s3_bfd_score_info_to_howto)
2734 (_bfd_score_info_to_howto): Likewise.
2735 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
2736 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
2737 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
2738 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
2739 (elf32_tic6x_info_to_howto_rel): Likewise.
2740 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
2741 * elf32-v850.c (v850_elf_info_to_howto_rel)
2742 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
2743 * elf32-vax.c (rtype_to_howto): Likewise.
2744 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
2745 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
2746 (elf32_wasm32_info_to_howto_rela): Likewise.
2747 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
2748 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
2749 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
2750 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
2751 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
2752 * elf64-gen.c (elf_generic_info_to_howto)
2753 (elf_generic_info_to_howto_rel): Likewise.
2754 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
2755 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
2756 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
2757 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
2758 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
2759 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
2761 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
2762 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
2764 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
2765 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
2766 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
2767 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
2768 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
2769 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
2770 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
2771 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
2772 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
2773 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
2776 2018-02-26 Jim Wilson <jimw@sifive.com>
2777 Stephan Schreiber <info@fs-driver.org>
2780 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
2781 call, set changed_contents and changed_relocs. Likewise after
2782 successful ia64_elf_relax_br call.
2784 2018-02-26 Alan Modra <amodra@gmail.com>
2786 * elf.c (assign_file_positions_except_relocs): Don't segfault
2787 when actual number of phdrs is less than allocated. Delete
2788 outdated comment. Formatting.
2790 2018-02-26 Alan Modra <amodra@gmail.com>
2792 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
2793 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
2794 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
2795 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
2796 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
2797 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
2798 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
2799 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
2800 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
2801 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
2802 error/warning messages.
2804 2018-02-26 Alan Modra <amodra@gmail.com>
2806 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
2807 * syms.c: Standardize error/warning messages.
2809 2018-02-26 Alan Modra <amodra@gmail.com>
2811 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
2812 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
2813 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
2814 * peXXigen.c, * peicode.h: Standardize error/warning messages.
2816 2018-02-26 Alan Modra <amodra@gmail.com>
2818 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
2820 2018-02-26 Alan Modra <amodra@gmail.com>
2822 * elfxx-mips.c: Standardize error/warning messages.
2824 2018-02-26 Alan Modra <amodra@gmail.com>
2826 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
2827 * elflink.c: Standardize error/warning messages. Replace use of
2828 linker callback einfo with _bfd_error_handler when possible.
2830 2018-02-26 Alan Modra <amodra@gmail.com>
2832 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
2833 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
2834 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
2835 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
2836 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
2837 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
2838 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
2839 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
2840 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
2841 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
2842 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
2843 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
2844 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
2845 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
2846 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
2847 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
2848 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
2849 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
2850 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
2851 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
2852 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
2853 unrecognized/unsupported reloc message.
2855 2018-02-26 Alan Modra <amodra@gmail.com>
2857 * elf32-ppc.c: Standardize error/warning messages. Use
2858 _bfd_error_handler rather than einfo when einfo features not used.
2859 * elf64-ppc.c: Likewise.
2861 2018-02-23 Alan Modra <amodra@gmail.com>
2864 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
2865 segment if no matching LOAD segment.
2867 2018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2869 * elf32-nds32.h: Define mask for ict_model.
2871 2018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
2873 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
2875 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2878 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
2880 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2881 .reginfo section has wrong size.
2883 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2885 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
2886 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
2887 `.MIPS.abiflags' sections.
2888 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
2891 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2893 * section.c (SEC_FIXED_SIZE): New macro.
2894 * bfd-in2.h: Regenerate.
2896 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2898 * section.c (SEC_HAS_GOT_REF): Remove macro.
2899 * bfd-in2.h: Regenerate.
2901 2018-02-19 Alan Modra <amodra@gmail.com>
2903 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
2905 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
2906 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
2907 (_bfd_riscv_relax_pc): Likewise and fix typos.
2908 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
2909 * libbfd.h: Regenerate.
2911 2018-02-19 Alan Modra <amodra@gmail.com>
2913 * dwarf2.c (read_section): Don't use 'll' format modifier.
2914 (find_abstract_instance): Likewise.
2915 * elfcore.h (elf_core_file_p): Likewise.
2917 2018-02-19 Alan Modra <amodra@gmail.com>
2919 * bfd-in.h: Include inttypes.h or if not available define
2920 PRId64, PRIu64 and PRIx64.
2921 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
2922 modifier to print bfd_vma.
2923 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
2924 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
2925 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
2926 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
2927 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
2928 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
2929 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
2930 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
2931 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
2932 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
2933 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
2934 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
2935 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
2936 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
2937 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
2938 and cast input to uint64_t, and similarly for Ld and Lu.
2939 * bfd-in2.h: Regenerate.
2941 2018-02-19 Alan Modra <amodra@gmail.com>
2943 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
2944 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
2945 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
2946 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
2947 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
2948 * reloc.c: Replace use of %R and %T in format strings passed to
2949 einfo and friends by %pR and %pT.
2951 2018-02-19 Alan Modra <amodra@gmail.com>
2953 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
2955 * aout-adobe.c: Update all messages using %A and %B.
2956 * aout-cris.c: Likewise.
2957 * aoutx.h: Likewise.
2958 * archive.c: Likewise.
2959 * binary.c: Likewise.
2960 * cache.c: Likewise.
2961 * coff-alpha.c: Likewise.
2962 * coff-arm.c: Likewise.
2963 * coff-i860.c: Likewise.
2964 * coff-mcore.c: Likewise.
2965 * coff-ppc.c: Likewise.
2966 * coff-rs6000.c: Likewise.
2967 * coff-sh.c: Likewise.
2968 * coff-tic4x.c: Likewise.
2969 * coff-tic54x.c: Likewise.
2970 * coff-tic80.c: Likewise.
2971 * coff64-rs6000.c: Likewise.
2972 * coffcode.h: Likewise.
2973 * coffgen.c: Likewise.
2974 * cofflink.c: Likewise.
2975 * coffswap.h: Likewise.
2976 * compress.c: Likewise.
2977 * cpu-arm.c: Likewise.
2978 * ecoff.c: Likewise.
2979 * elf-attrs.c: Likewise.
2980 * elf-eh-frame.c: Likewise.
2981 * elf-ifunc.c: Likewise.
2982 * elf-m10300.c: Likewise.
2983 * elf-properties.c: Likewise.
2984 * elf-s390-common.c: Likewise.
2986 * elf32-arc.c: Likewise.
2987 * elf32-arm.c: Likewise.
2988 * elf32-avr.c: Likewise.
2989 * elf32-bfin.c: Likewise.
2990 * elf32-cr16.c: Likewise.
2991 * elf32-cr16c.c: Likewise.
2992 * elf32-cris.c: Likewise.
2993 * elf32-crx.c: Likewise.
2994 * elf32-d10v.c: Likewise.
2995 * elf32-d30v.c: Likewise.
2996 * elf32-epiphany.c: Likewise.
2997 * elf32-fr30.c: Likewise.
2998 * elf32-frv.c: Likewise.
2999 * elf32-gen.c: Likewise.
3000 * elf32-hppa.c: Likewise.
3001 * elf32-i370.c: Likewise.
3002 * elf32-i386.c: Likewise.
3003 * elf32-i960.c: Likewise.
3004 * elf32-ip2k.c: Likewise.
3005 * elf32-iq2000.c: Likewise.
3006 * elf32-lm32.c: Likewise.
3007 * elf32-m32c.c: Likewise.
3008 * elf32-m32r.c: Likewise.
3009 * elf32-m68hc11.c: Likewise.
3010 * elf32-m68hc12.c: Likewise.
3011 * elf32-m68hc1x.c: Likewise.
3012 * elf32-m68k.c: Likewise.
3013 * elf32-mcore.c: Likewise.
3014 * elf32-mep.c: Likewise.
3015 * elf32-metag.c: Likewise.
3016 * elf32-microblaze.c: Likewise.
3017 * elf32-moxie.c: Likewise.
3018 * elf32-msp430.c: Likewise.
3019 * elf32-mt.c: Likewise.
3020 * elf32-nds32.c: Likewise.
3021 * elf32-nios2.c: Likewise.
3022 * elf32-or1k.c: Likewise.
3023 * elf32-pj.c: Likewise.
3024 * elf32-ppc.c: Likewise.
3025 * elf32-rl78.c: Likewise.
3026 * elf32-rx.c: Likewise.
3027 * elf32-s390.c: Likewise.
3028 * elf32-score.c: Likewise.
3029 * elf32-score7.c: Likewise.
3030 * elf32-sh-symbian.c: Likewise.
3031 * elf32-sh.c: Likewise.
3032 * elf32-sh64.c: Likewise.
3033 * elf32-sparc.c: Likewise.
3034 * elf32-spu.c: Likewise.
3035 * elf32-tic6x.c: Likewise.
3036 * elf32-tilepro.c: Likewise.
3037 * elf32-v850.c: Likewise.
3038 * elf32-vax.c: Likewise.
3039 * elf32-visium.c: Likewise.
3040 * elf32-wasm32.c: Likewise.
3041 * elf32-xgate.c: Likewise.
3042 * elf32-xtensa.c: Likewise.
3043 * elf64-alpha.c: Likewise.
3044 * elf64-gen.c: Likewise.
3045 * elf64-hppa.c: Likewise.
3046 * elf64-ia64-vms.c: Likewise.
3047 * elf64-mmix.c: Likewise.
3048 * elf64-ppc.c: Likewise.
3049 * elf64-s390.c: Likewise.
3050 * elf64-sh64.c: Likewise.
3051 * elf64-sparc.c: Likewise.
3052 * elf64-x86-64.c: Likewise.
3053 * elfcode.h: Likewise.
3054 * elfcore.h: Likewise.
3055 * elflink.c: Likewise.
3056 * elfnn-aarch64.c: Likewise.
3057 * elfnn-ia64.c: Likewise.
3058 * elfnn-riscv.c: Likewise.
3059 * elfxx-mips.c: Likewise.
3060 * elfxx-sparc.c: Likewise.
3061 * elfxx-tilegx.c: Likewise.
3062 * elfxx-x86.c: Likewise.
3063 * hpux-core.c: Likewise.
3066 * libbfd.c: Likewise.
3067 * linker.c: Likewise.
3068 * mach-o.c: Likewise.
3069 * merge.c: Likewise.
3071 * oasys.c: Likewise.
3072 * pdp11.c: Likewise.
3073 * pe-mips.c: Likewise.
3074 * peXXigen.c: Likewise.
3075 * peicode.h: Likewise.
3076 * reloc.c: Likewise.
3077 * rs6000-core.c: Likewise.
3079 * stabs.c: Likewise.
3080 * vms-alpha.c: Likewise.
3081 * xcofflink.c: Likewise.
3083 2018-02-19 Alan Modra <amodra@gmail.com>
3086 * elf.c (IS_TBSS): Define.
3087 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
3088 (assign_file_positions_for_non_load_sections): Revert last change.
3089 Properly calculate load segment limits to compare against relro limits.
3091 2018-02-17 Alan Modra <amodra@gmail.com>
3094 * elf.c (assign_file_positions_for_non_load_sections): Ignore
3095 degenerate zero size PT_LOAD segments when finding one overlapping
3096 the PT_GNU_RELRO segment.
3098 2018-02-16 Alan Modra <amodra@gmail.com>
3100 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
3101 (_bfd_bool_bfd_true): Rename from bfd_true.
3102 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
3103 (_bfd_int_bfd_0): Rename from bfd_0.
3104 (_bfd_uint_bfd_0): Rename from bfd_0u.
3105 (_bfd_long_bfd_0): Rename from bfd_0l.
3106 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
3107 (_bfd_void_bfd): Rename from bfd_void.
3108 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
3109 (_bfd_bool_bfd_link_false_error),
3110 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
3111 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
3112 (_bfd_bool_bfd_asection_bfd_asection_true),
3113 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
3114 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
3115 * archive.c (_bfd_noarchive_get_elt_at_index),
3116 (_bfd_noarchive_openr_next_archived_file),
3117 (_bfd_noarchive_construct_extended_name_table),
3118 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
3119 (_bfd_noarchive_write_armap): New functions.
3120 * archures.c (_bfd_nowrite_set_arch_mach): New function.
3121 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
3122 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
3123 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
3124 (alpha_ecoff_swap_coff_lineno_out),
3125 (alpha_ecoff_swap_coff_reloc_out): New functions.
3126 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
3127 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
3128 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
3129 (mips_ecoff_swap_coff_lineno_out),
3130 (mips_ecoff_swap_coff_reloc_out): New functions.
3131 * coffcode.h (coff_set_alignment_hook): Replace define with
3133 (symname_in_debug_hook): Likewise.
3134 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
3135 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
3136 * elf.c (assign_file_positions_except_relocs): Test
3137 elf_backend_allow_non_load_phdr for NULL.
3138 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
3139 _bfd_elf_link_omit_section_dynsym. Update uses.
3140 (_bfd_elf_omit_section_dynsym_all): New function.
3141 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
3142 (_bfd_elf_omit_section_dynsym_default): Declare.
3143 (_bfd_elf_omit_section_dynsym_all): Declare.
3144 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
3145 (_bfd_nolink_bfd_get_relocated_section_contents),
3146 (_bfd_nolink_bfd_lookup_section_flags),
3147 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
3148 (_bfd_nolink_bfd_link_hash_table_create),
3149 (_bfd_nolink_bfd_link_just_syms),
3150 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
3151 (_bfd_nolink_bfd_link_split_section),
3152 (_bfd_nolink_section_already_linked),
3153 (_bfd_nolink_bfd_define_common_symbol),
3154 (_bfd_nolink_bfd_define_start_stop): New functions.
3155 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
3156 (_bfd_norelocs_bfd_reloc_name_lookup),
3157 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
3158 * section.c (_bfd_nowrite_set_section_contents): New function.
3159 * syms.c (_bfd_nosymbols_canonicalize_symtab),
3160 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
3161 (_bfd_nosymbols_get_symbol_version_string),
3162 (_bfd_nosymbols_bfd_is_local_label_name),
3163 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
3164 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
3165 (_bfd_nosymbols_bfd_make_debug_symbol),
3166 ( _bfd_nosymbols_read_minisymbols),
3167 ( _bfd_nosymbols_minisymbol_to_symbol),
3168 (_bfd_nodynamic_get_synthetic_symtab): New functions.
3169 * libbfd-in.h: Declare new functions. Update existing defines,
3171 * aix386-core.c: Update to use new hooks. Formatting.
3172 * aout-adobe.c: Likewise.
3173 * aout-arm.c: Likewise.
3174 * aout-target.h: Likewise.
3175 * aout-tic30.c: Likewise.
3176 * aoutf1.h: Likewise.
3177 * binary.c: Likewise.
3179 * cisco-core.c: Likewise.
3180 * coff-alpha.c: Likewise.
3181 * coff-i386.c: Likewise.
3182 * coff-i860.c: Likewise.
3183 * coff-i960.c: Likewise.
3184 * coff-ia64.c: Likewise.
3185 * coff-mips.c: Likewise.
3186 * coff-ppc.c: Likewise.
3187 * coff-rs6000.c: Likewise.
3188 * coff-sh.c: Likewise.
3189 * coff-tic30.c: Likewise.
3190 * coff-tic54x.c: Likewise.
3191 * coff-x86_64.c: Likewise.
3192 * coff64-rs6000.c: Likewise.
3193 * coffcode.h: Likewise.
3194 * elf-m10300.c: Likewise.
3195 * elf32-cr16.c: Likewise.
3196 * elf32-lm32.c: Likewise.
3197 * elf32-m32r.c: Likewise.
3198 * elf32-metag.c: Likewise.
3199 * elf32-score.c: Likewise.
3200 * elf32-score7.c: Likewise.
3201 * elf32-tilepro.c: Likewise.
3202 * elf32-xstormy16.c: Likewise.
3203 * elf32-xtensa.c: Likewise.
3204 * elf64-alpha.c: Likewise.
3205 * elf64-hppa.c: Likewise.
3206 * elf64-ia64-vms.c: Likewise.
3207 * elf64-mmix.c: Likewise.
3208 * elf64-sh64.c: Likewise.
3209 * elfnn-ia64.c: Likewise.
3210 * elfxx-sparc.c: Likewise.
3211 * elfxx-target.h: Likewise.
3212 * elfxx-tilegx.c: Likewise.
3213 * elfxx-x86.h: Likewise.
3214 * hp300hpux.c: Likewise.
3215 * hppabsd-core.c: Likewise.
3216 * hpux-core.c: Likewise.
3217 * i386msdos.c: Likewise.
3218 * i386os9k.c: Likewise.
3221 * irix-core.c: Likewise.
3222 * libaout.h: Likewise.
3223 * libecoff.h: Likewise.
3224 * mach-o-target.c: Likewise.
3225 * mach-o.c: Likewise.
3226 * mipsbsd.c: Likewise.
3228 * netbsd-core.c: Likewise.
3229 * nlm-target.h: Likewise.
3230 * oasys.c: Likewise.
3231 * osf-core.c: Likewise.
3232 * pdp11.c: Likewise.
3233 * pe-mips.c: Likewise.
3234 * pe-x86_64.c: Likewise.
3236 * plugin.c: Likewise.
3237 * ppcboot.c: Likewise.
3238 * ptrace-core.c: Likewise.
3239 * sco5-core.c: Likewise.
3241 * sparclynx.c: Likewise.
3243 * tekhex.c: Likewise.
3244 * trad-core.c: Likewise.
3245 * verilog.c: Likewise.
3246 * versados.c: Likewise.
3247 * vms-alpha.c: Likewise.
3248 * vms-lib.c: Likewise.
3249 * wasm-module.c: Likewise.
3251 * libbfd.h: Regenerate.
3253 2018-02-15 Jim Wilson <jimw@sifive.com>
3255 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
3256 symbols whose section address is zero.
3258 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
3259 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
3260 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
3261 Add %X%P to error messages.
3263 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
3266 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
3267 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
3268 and assert that the result of the call is not NULL.
3270 2018-02-14 Nick Clifton <nickc@redhat.com>
3273 Revert previous delta. Add extra casts to avoid compile time
3275 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
3276 cast to avoid warning from gcc v8 compiler.
3277 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
3278 (_bfd_generic_bfd_set_private_flags): Likewise.
3279 (_bfd_generic_bfd_copy_private_section_data): Likewise.
3280 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
3281 (_bfd_generic_bfd_copy_private_header_data): Likewise.
3282 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
3283 (_bfd_noarchive_construct_extended_name_table): Likewise.
3284 (_bfd_noarchive_truncate_arname): Likewise.
3285 (_bfd_noarchive_write_ar_hdr): Likewise.
3286 (_bfd_noarchive_get_elt_at_index): Likewise.
3287 (_bfd_nosymbols_canonicalize_symtab): Likewise.
3288 (_bfd_nosymbols_print_symbol): Likewise.
3289 (_bfd_nosymbols_get_symbol_info): Likewise.
3290 (_bfd_nosymbols_get_symbol_version_string): Likewise.
3291 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
3292 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
3293 (_bfd_nosymbols_get_lineno): Likewise.
3294 (_bfd_nosymbols_find_nearest_line): Likewise.
3295 (_bfd_nosymbols_find_line): Likewise.
3296 (_bfd_nosymbols_find_inliner_info): Likewise.
3297 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
3298 (_bfd_nosymbols_read_minisymbols): Likewise.
3299 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
3300 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
3301 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
3302 (_bfd_nowrite_set_arch_mach): Likewise.
3303 (_bfd_nowrite_set_section_contents): Likewise.
3304 (_bfd_nolink_sizeof_headers): Likewise.
3305 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
3306 (_bfd_nolink_bfd_relax_section): Likewise.
3307 (_bfd_nolink_bfd_gc_sections): Likewise.
3308 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
3309 (_bfd_nolink_bfd_merge_sections): Likewise.
3310 (_bfd_nolink_bfd_is_group_section): Likewise.
3311 (_bfd_nolink_bfd_discard_group): Likewise.
3312 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
3313 (_bfd_nolink_bfd_link_add_symbols): Likewise.
3314 (_bfd_nolink_bfd_link_just_syms): Likewise.
3315 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
3316 (_bfd_nolink_bfd_final_link): Likewise.
3317 (_bfd_nolink_bfd_link_split_section): Likewise.
3318 (_bfd_nolink_section_already_linked): Likewise.
3319 (_bfd_nolink_bfd_define_common_symbol): Likewise.
3320 (_bfd_nolink_bfd_define_start_stop): Likewise.
3321 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
3322 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
3323 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
3324 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
3325 * libbfd.c (bfd_false_any): Delete.
3326 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
3327 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
3328 * libbfd.h (extern): Regenerate
3329 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
3330 cast to avoid warning from gcc v8 compiler.
3331 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
3332 * binary.c (binary_get_symbol_info): Likewise.
3333 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
3334 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3335 * coffcode.h (coff_set_alignment_hook): Likewise.
3336 (symname_in_debug_hook): Likewise.
3337 (bfd_coff_backend_data bigobj_swap_table): Likewise.
3338 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
3339 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
3340 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
3341 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
3342 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
3343 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
3344 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
3345 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
3346 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
3347 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
3348 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
3349 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
3350 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
3351 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
3352 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
3353 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
3354 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
3355 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
3356 (bfd_elfNN_bfd_set_private_flags): Likewise.
3357 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
3358 (elf_backend_init_index_section): Likewise.
3359 (elf_backend_allow_non_load_phdr): Likewise.
3360 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
3361 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
3362 * ieee.c (ieee_construct_extended_name_table): Likewise.
3363 (ieee_write_armap): Likewise.
3364 (ieee_write_ar_hdr): Likewise.
3365 (ieee_bfd_is_target_special_symbol): Likewise.
3366 * ihex.c (ihex_canonicalize_symtab): Likewise.
3367 (ihex_bfd_is_target_special_symbol): Likewise.
3368 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
3369 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
3370 (_bfd_ecoff_set_alignment_hook): Likewise.
3371 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
3372 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
3373 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
3374 * oasys.c (oasys_construct_extended_name_table): Likewise.
3375 (oasys_write_armap): Likewise.
3376 (oasys_write_ar_hdr): Likewise.
3377 (oasys_bfd_is_target_special_symbol): Likewise.
3378 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
3379 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
3380 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
3381 * som.c (som_bfd_is_target_special_symbol): Likewise.
3382 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
3383 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
3384 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
3385 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
3386 (versados_bfd_reloc_name_lookup): Likewise.
3387 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
3388 (vms_bfd_define_start_stop): Likewise.
3389 (alpha_vms_bfd_is_target_special_symbol): Likewise.
3390 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
3391 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
3393 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
3396 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
3397 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
3398 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
3399 R_X86_64_PC32 reloc against dynamic function in data section.
3400 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
3401 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
3402 against dynamic function in data section.
3403 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
3404 function address only if pcrel_plt is true.
3405 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
3406 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
3407 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
3408 PC-relative relocation against a function definition in data
3409 secton in PIE. Remove the obsolete comments.
3410 (elf_x86_link_hash_table): Add pcrel_plt.
3412 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
3414 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
3415 instead of bfd_link_pic, for building shared library.
3417 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
3420 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
3421 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
3422 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
3423 against protected function in shared object.
3425 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
3428 * po/ru.po: Fix typo in Russian translation.
3430 2018-02-13 Maciej W. Rozycki <macro@mips.com>
3432 * wasm-module.c (wasm_scan_name_function_section): Rename
3433 `index' local variable to `idx'.
3435 2018-02-13 Nick Clifton <nickc@redhat.com>
3438 Fix compile time warnings generated by gcc version 8.
3439 * libbfd-in.h: Remove extraneous text from prototypes.
3440 Add prototypes for bfd_false_any, bfd_true_any,
3441 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
3442 bfd_n1_any, bfd_void_any.
3443 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
3445 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
3446 (_bfd_generic_bfd_set_private_flags): Likewise.
3447 (_bfd_generic_bfd_copy_private_section_data): Likewise.
3448 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
3449 (_bfd_generic_bfd_copy_private_header_data): Likewise.
3450 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
3451 (_bfd_noarchive_construct_extended_name_table): Likewise.
3452 (_bfd_noarchive_truncate_arname): Likewise.
3453 (_bfd_noarchive_write_ar_hdr): Likewise.
3454 (_bfd_noarchive_get_elt_at_index): Likewise.
3455 (_bfd_nosymbols_canonicalize_symtab): Likewise.
3456 (_bfd_nosymbols_print_symbol): Likewise.
3457 (_bfd_nosymbols_get_symbol_info): Likewise.
3458 (_bfd_nosymbols_get_symbol_version_string): Likewise.
3459 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
3460 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
3461 (_bfd_nosymbols_get_lineno): Likewise.
3462 (_bfd_nosymbols_find_nearest_line): Likewise.
3463 (_bfd_nosymbols_find_line): Likewise.
3464 (_bfd_nosymbols_find_inliner_info): Likewise.
3465 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
3466 (_bfd_nosymbols_read_minisymbols): Likewise.
3467 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
3468 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
3469 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
3470 (_bfd_nowrite_set_arch_mach): Likewise.
3471 (_bfd_nowrite_set_section_contents): Likewise.
3472 (_bfd_nolink_sizeof_headers): Likewise.
3473 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
3474 (_bfd_nolink_bfd_relax_section): Likewise.
3475 (_bfd_nolink_bfd_gc_sections): Likewise.
3476 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
3477 (_bfd_nolink_bfd_merge_sections): Likewise.
3478 (_bfd_nolink_bfd_is_group_section): Likewise.
3479 (_bfd_nolink_bfd_discard_group): Likewise.
3480 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
3481 (_bfd_nolink_bfd_link_add_symbols): Likewise.
3482 (_bfd_nolink_bfd_link_just_syms): Likewise.
3483 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
3484 (_bfd_nolink_bfd_final_link): Likewise.
3485 (_bfd_nolink_bfd_link_split_section): Likewise.
3486 (_bfd_nolink_section_already_linked): Likewise.
3487 (_bfd_nolink_bfd_define_common_symbol): Likewise.
3488 (_bfd_nolink_bfd_define_start_stop): Likewise.
3489 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
3490 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
3491 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
3492 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
3493 * libbfd.c (bfd_false_any): New function. Like bfd_false but
3494 accepts one or more arguments.
3495 (bfd_true_any): Likewise.
3496 (bfd_nullvoidptr_any): Likewise.
3497 (bfd_0_any): Likewise.
3498 (bfd_0u_any): Likewise.
3499 (bfd_0l_any): Likewise.
3500 (_bfd_n1_any): Likewise.
3501 (bfd_void_any): Likewise.
3502 * libbfd.h (extern): Regenerate
3503 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
3504 based dummy function.
3505 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
3506 * binary.c (binary_get_symbol_info): Likewise.
3507 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
3508 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3509 * coffcode.h (coff_set_alignment_hook): Likewise.
3510 (symname_in_debug_hook): Likewise.
3511 (bfd_coff_backend_data bigobj_swap_table): Likewise.
3512 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
3513 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
3514 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
3515 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
3516 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
3517 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
3518 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
3519 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
3520 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
3521 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
3522 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
3523 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
3524 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
3525 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
3526 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
3527 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
3528 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
3529 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
3530 (bfd_elfNN_bfd_set_private_flags): Likewise.
3531 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
3532 (elf_backend_init_index_section): Likewise.
3533 (elf_backend_allow_non_load_phdr): Likewise.
3534 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
3535 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
3536 * ieee.c (ieee_construct_extended_name_table): Likewise.
3537 (ieee_write_armap): Likewise.
3538 (ieee_write_ar_hdr): Likewise.
3539 (ieee_bfd_is_target_special_symbol): Likewise.
3540 * ihex.c (ihex_canonicalize_symtab): Likewise.
3541 (ihex_bfd_is_target_special_symbol): Likewise.
3542 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
3543 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
3544 (_bfd_ecoff_set_alignment_hook): Likewise.
3545 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
3546 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
3547 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
3548 * oasys.c (oasys_construct_extended_name_table): Likewise.
3549 (oasys_write_armap): Likewise.
3550 (oasys_write_ar_hdr): Likewise.
3551 (oasys_bfd_is_target_special_symbol): Likewise.
3552 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
3553 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
3554 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
3555 * som.c (som_bfd_is_target_special_symbol): Likewise.
3556 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
3557 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
3558 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
3559 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
3560 (versados_bfd_reloc_name_lookup): Likewise.
3561 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
3562 (vms_bfd_define_start_stop): Likewise.
3563 (alpha_vms_bfd_is_target_special_symbol): Likewise.
3564 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
3565 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
3566 * elf32-arc.c (get_replace_function): Assign replacement function
3568 * elf32-i370.c (i370_noop): Update prototype.
3570 2018-02-13 Alan Modra <amodra@gmail.com>
3573 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
3574 relocation sections. If size reduces to just the flag word,
3575 remove that too and mark with SEC_EXCLUDE.
3576 * elflink.c (bfd_elf_final_link): Strip empty group sections.
3578 2018-02-13 Alan Modra <amodra@gmail.com>
3581 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
3584 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
3586 * i386msdos.c (msdos_mkobject); New function.
3587 (msdos_object_p): New function.
3588 (i386_msdos_vec): Use msdos_object_p as the check_format
3590 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
3591 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
3593 * peXXigen.c: Likewise.
3594 * coff-ia64.c: Likewise.
3596 2018-02-12 Nick Clifton <nickc@redhat.com>
3598 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
3600 * elf32-arc.c (elf_arc_relocate_section): Likewise.
3602 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
3604 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
3605 (sparc_elf_append_rela): Assert that there is enough room in section.
3606 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
3607 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
3608 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
3609 For a symbol subject to a GOT relocation, reserve a slot in the
3610 relocation section if the symbol isn't dynamic and we are in PIC mode.
3611 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
3612 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
3613 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
3614 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
3615 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
3616 resolved_to_zero. Do not generate a dynamic GOT relocation for an
3617 undefined weak symbol with non-default visibility. Remove superfluous
3618 'else' and fix formatting.
3620 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
3622 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
3624 (i386_elf32_sol2_vec): Don't declare.
3625 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
3626 Don't set need_global_offset_table.
3627 (elf_i386_solaris_arch_bed): New.
3628 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
3630 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
3631 target_os != is_nacl instead of target_os == is_normal.
3632 (x86_64_elf64_sol2_vec): Don't declare.
3633 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
3634 is_nacl instead of target_os == is_normal. Don't set
3635 need_global_offset_table.
3636 (elf_x86_64_solaris_arch_bed): New.
3637 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
3639 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
3640 _GLOBAL_OFFSET_TABLE_ for Solaris.
3641 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
3642 need_global_offset_table.
3643 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
3644 (elf_x86_link_hash_table): Remove need_global_offset_table.
3645 (elf_x86_init_table): Likewise.
3647 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
3649 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
3651 (i386_elf32_sol2_vec): Declared.
3652 (elf_i386_link_setup_gnu_properties): Set
3653 need_global_offset_table with info->output_bfd->xvec.
3654 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
3656 (x86_64_elf64_sol2_vec): Declared.
3657 (elf_x86_64_link_setup_gnu_properties): Set
3658 need_global_offset_table with info->output_bfd->xvec.
3660 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
3662 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
3664 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
3666 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
3668 (elf_x86_64_link_setup_gnu_properties): Set
3669 need_global_offset_table for Solaris.
3670 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
3671 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
3672 (_bfd_x86_elf_link_setup_gnu_properties): Copy
3673 need_global_offset_table.
3674 * elfxx-x86.h (elf_x86_link_hash_table): Add
3675 need_global_offset_table.
3676 (elf_x86_init_table): Likewise.
3678 2018-02-08 Jim Wilson <jimw@sifive.com>
3680 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
3683 2018-02-08 Nick Clifton <nickc@redhat.com>
3686 * elf.c (elf_parse_notes): Reject notes with excessuively large
3689 2018-02-07 Alan Modra <amodra@gmail.com>
3691 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
3692 * elf32-ppc.c: Remove speculation barrier support.
3693 * elf32-ppc.h: Likewise.
3694 * elf64-ppc.c: Likewise.
3695 * elf64-ppc.h: Likewise.
3697 2018-02-06 Jim Wilson <jimw@sifive.com>
3699 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
3700 callback to report an error.
3702 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
3705 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
3706 into call to !bfd_link_executable and tidy up.
3707 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
3708 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
3709 !bfd_link_executable.
3710 <R_SPARC_TLS_IE_HI22>: Likewise.
3711 <GOT relocations>: Remove useless code, tidy and merge related blocks.
3712 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
3713 !bfd_link_executable.
3714 <R_SPARC_WPLT30>: Tidy up.
3715 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
3716 !bfd_link_executable.
3717 (allocate_dynrelocs): Likewise.
3718 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
3719 <R_SPARC_TLS_GD_HI22>: Merge into...
3720 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
3721 sparc_elf_tls_transition and remove redundant code.
3722 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
3723 !bfd_link_executable.
3724 <R_SPARC_TLS_LDO_HIX22>: Likewise.
3725 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
3726 <R_SPARC_TLS_LDM_CALL>: Likewise.
3727 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
3728 <R_SPARC_TLS_GD_ADD>: Likewise.
3729 <R_SPARC_TLS_LDM_ADD>: Likewise.
3730 <R_SPARC_TLS_LDO_ADD>: Likewise.
3731 <R_SPARC_TLS_IE_LD>: Likewise.
3733 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
3736 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
3737 functions failed to find the function name, try the generic elf
3738 find function instead.
3740 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
3742 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
3743 'memcpy' instead of 'strncpy' when writing the magic number.
3745 2018-02-06 Nick Clifton <nickc@redhat.com>
3748 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
3749 section before attempting to read it in.
3750 (bfd_get_alt_debug_link_info): Likewise.
3752 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
3754 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
3755 line information in addition to name, if they can be found.
3757 2018-02-05 Renlin Li <renlin.li@arm.com>
3760 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
3761 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
3762 check for writeable section as well.
3764 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
3767 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
3768 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
3769 undefined weak symbol to 0.
3770 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
3771 if _GLOBAL_OFFSET_TABLE_ is referenced.
3772 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
3773 got_referenced instead of ref_regular_nonweak. Remove the
3774 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
3775 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
3777 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3779 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
3780 initialize `hi_reloc'.
3782 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3784 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
3785 SHT_MIPS_REGINFO sections don't assert the correct size and
3786 report an error instead.
3788 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3790 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
3791 status from `->elf_backend_section_processing'.
3793 2018-02-02 Jim Wilson <jimw@sifive.com>
3796 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
3797 If link_info->wrap_hash, check for a duplicate symbol and ignore.
3798 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
3799 Pass new argument to riscv_relax_delete_bytes.
3800 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
3801 ATTRIBUTE_UNUSED from link_info parameter.
3803 2018-02-02 Alan Modra <amodra@gmail.com>
3805 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
3806 emitted for toc sequence optimization. Set and use "howto" later.
3808 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
3810 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
3811 arithmetic on NULL pointer.
3812 * elflink.c (_bfd_elf_archive_symbol_lookup,
3813 elf_link_add_archive_symbols): Likewise.
3815 2018-01-31 Michael Matz <matz@suse.de>
3817 * elflink.c (bfd_elf_define_start_stop): Fix check of
3820 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
3823 * elflink.c (bfd_elf_define_start_stop): Check if __start and
3824 __stop symbols are referenced by shared objects.
3826 2018-01-30 Alan Modra <amodra@gmail.com>
3829 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
3830 segment when demand paged with lma on the same page. Test this
3831 before load/non-load, executable/non-executable,
3832 writable/non-writable tests and simplify. Delete bogus relro
3833 condition in writable/non-writable test. Delete outdated
3834 comment. Formatting.
3836 2018-01-30 Alan Modra <amodra@gmail.com>
3838 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
3841 2018-01-29 Alan Modra <amodra@gmail.com>
3844 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
3845 range before converting to a symbol table pointer.
3847 2018-01-27 Nick Clifton <nickc@redhat.com>
3849 * po/ru.po: Updated Russian translation.
3851 2018-01-26 Alan Modra <amodra@gmail.com>
3853 * elflink.c (bfd_elf_define_start_stop): Override symbols when
3854 they are defined dynamically.
3856 2018-01-26 Alan Modra <amodra@gmail.com>
3858 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
3859 .branch_lt changes size.
3861 2018-01-25 Alan Modra <amodra@gmail.com>
3864 * elfcode.h (elf_object_p): Avoid integer overflow.
3866 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
3869 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
3870 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
3873 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
3876 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
3877 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
3878 bfd_link_executable for TLS check.
3879 (_bfd_sparc_elf_check_relocs): Likewise.
3880 (allocate_dynrelocs): Likewise.
3881 (_bfd_sparc_elf_relocate_section): Likewise.
3883 2018-01-24 Renlin Li <renlin.li@arm.com>
3885 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
3886 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3887 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3888 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3889 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3890 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
3891 (_bfd_aarch64_elf_resolve_relocation): Likewise.
3893 2018-01-24 Renlin Li <renlin.li@arm.com>
3895 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
3896 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
3897 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
3898 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
3899 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
3900 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3901 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3902 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3903 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3904 * bfd-in2.h: Regenerate.
3905 * libbfd.h: Regenerate.
3907 2018-01-23 Maciej W. Rozycki <macro@mips.com>
3909 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
3910 `mips_elf32_section_processing' comment reference.
3912 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
3915 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
3916 versioned __tls_get_addr symbol.
3918 2018-01-19 Nick Clifton <nickc@redhat.com>
3920 * po/fr.po: Updated French translation.
3922 2018-01-18 Alan Modra <amodra@gmail.com>
3924 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
3925 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
3926 (ppc64_elf_build_stubs): Likewise.
3928 2018-01-17 Nick Clifton <nickc@redhat.com>
3930 * po/ru.po: Updated Russian translation.
3931 * po/uk/po: Updated Ukranian translation.
3933 2018-01-17 Alan Modra <amodra@gmail.com>
3935 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
3937 2018-01-17 Alan Modra <amodra@gmail.com>
3939 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
3940 (CRSETEQ, BEQCTRM): Define.
3941 (is_nonpic_glink_stub): Don't check bctr.
3942 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3943 (ppc_elf_relax_section): Size speculation barrier.
3944 (output_bctr): New function.
3945 (write_glink_stub): Use output_bctr.
3946 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
3947 (ppc_elf_finish_dynamic_symbol): Likewise.
3948 (ppc_elf_finish_dynamic_sections): Use output_bctr.
3949 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
3950 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
3951 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
3952 (size_global_entry_stubs): Handle speculation barrier sizing.
3953 (plt_stub_size): Likewise.
3954 (output_bctr): New function.
3955 (build_plt_stub, build_tls_get_addr_stub): Output speculation
3957 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
3958 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
3959 (build_global_entry_stubs): Output speculation barrier.
3960 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
3961 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
3963 2018-01-17 Alan Modra <amodra@gmail.com>
3965 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
3966 __tls_get_addr_opt, and alignment sizing.
3967 (TLS_GET_ADDR_GLINK_SIZE): Delete.
3968 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
3969 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
3971 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3972 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
3973 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
3975 (write_glink_stub): Handle __tls_get_addr_opt stub.
3976 Pad out to size given by GLINK_ENTRY_SIZE.
3977 (ppc_elf_relocate_section): Adjust write_glink_stub call.
3978 (ppc_elf_finish_dynamic_symbol): Likewise.
3979 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
3980 insn array since so many need rewriting.
3981 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
3982 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
3983 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
3984 nops. Adjust all uses.
3985 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
3986 in glink_vma calculation.
3987 (struct ppc_link_hash_table): Add global_entry section pointer.
3988 (create_linkage_sections): Create separate section for global
3990 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
3991 (size_global_entry_stubs): Handle sizing for aligned stubs.
3992 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
3993 and don't stash end of glink branch table in rawsize.
3994 (ppc_build_one_stub): Rewrite stub size calculations.
3995 (build_global_entry_stubs): Use new section.
3996 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
3997 Build lazy link stubs out to end of section. Build global entry
3998 stubs in new section.
4000 2018-01-15 Nick Clifton <nickc@redhat.com>
4002 * po/uk.po: Updated Ukranian translation.
4004 2018-01-13 Nick Clifton <nickc@redhat.com>
4006 * po/bfd.pot: Regenerated.
4008 2018-01-13 Nick Clifton <nickc@redhat.com>
4010 * version.m4: Bump version to 2.30.51
4011 * configure: Regenerate.
4013 2018-01-13 Nick Clifton <nickc@redhat.com>
4015 2.30 branch created.
4017 2018-01-12 Jens Widell <jl@opera.com>
4019 * elf.c (setup_group): Optimize search for group by remembering
4020 last found group and restarting search at that index.
4021 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
4023 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
4025 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
4026 bfd_link_common_skip_none in switch.
4028 2018-01-12 Alan Modra <amodra@gmail.com>
4031 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
4032 references on forced local symbols.
4034 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
4036 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
4037 .reginfo section has wrong size.
4039 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
4042 * elf.c (_bfd_elf_map_sections_to_segments): When generating
4043 separate code and read-only data LOAD segments, create a new
4044 LOAD segment if the previous section contains text and the
4045 current section doesn't or vice versa. Don't put a writable
4046 section in a read-only segment if there is a RELRO segment.
4048 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
4051 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
4052 references on forced local symbols.
4054 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
4057 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
4058 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
4060 2018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
4063 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
4065 2018-01-03 John Baldwin <jhb@FreeBSD.org>
4067 * elf.c (elfcore_grok_freebsd_note): Handle
4068 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
4069 NT_FREEBSD_PROCSTAT_VMMAP.
4071 2018-01-03 Alan Modra <amodra@gmail.com>
4073 Update year range in copyright notice of all files.
4075 For older changes see ChangeLog-2017
4077 Copyright (C) 2018 Free Software Foundation, Inc.
4079 Copying and distribution of this file, with or without modification,
4080 are permitted in any medium without royalty provided the copyright
4081 notice and this notice are preserved.
4087 version-control: never