1 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
2 Mickaël Guêné <mickael.guene@st.com>
4 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
5 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
7 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
8 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
9 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
10 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
11 (struct elf32_arm_link_hash_table): Update comment.
12 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
13 (IS_ARM_TLS_RELOC): Likewise.
14 (elf32_arm_check_relocs): Likewise.
15 (allocate_dynrelocs_for_symbol): Likewise.
16 (elf32_arm_size_dynamic_sections): Update comment.
17 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
18 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
20 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
21 Mickaël Guêné <mickael.guene@st.com>
23 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
24 (elf32_arm_create_dynamic_sections): Handle FDPIC.
25 (elf32_arm_allocate_plt_entry): Likewise.
26 (elf32_arm_populate_plt_entry): Likewise.
27 (elf32_arm_output_plt_map_1): Likewise.
29 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
30 Mickaël Guêné <mickael.guene@st.com>
32 * elf32-arm.c (struct fdpic_local): New.
33 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
34 (elf32_arm_local_fdpic_cnts): New.
35 (struct fdpic_global): New.
36 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
37 (elf32_arm_link_hash_table): Add srofixup field.
38 (arm_elf_add_rofixup): New.
39 (arm_elf_fill_funcdesc): New.
40 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
41 (elf32_arm_allocate_local_sym_info): Likewise.
42 (create_got_section): Create .rofixup section.
43 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
44 (bfd_elf32_arm_set_target_params): Handle FDPIC.
45 (elf32_arm_final_link_relocate): Likewise.
46 (elf32_arm_check_relocs): Likewise.
47 (allocate_dynrelocs_for_symbol): Likewise.
48 (elf32_arm_size_dynamic_sections): Likewise.
49 (elf32_arm_finish_dynamic_sections): Likewise.
50 (elf32_arm_output_arch_local_syms): Likewise.
51 (elf32_arm_fdpic_omit_section_dynsym): New.
53 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
54 Mickaël Guêné <mickael.guene@st.com>
56 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
57 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
58 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
59 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
60 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
61 (elf32_arm_howto_from_type): Take new members of
62 elf32_arm_howto_table_2 into account.
63 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
64 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
65 BFD_RELOC_ARM_FUNCDESC_VALUE.
66 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
67 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
68 BFD_RELOC_ARM_FUNCDESC_VALUE.
70 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
71 Mickaël Guêné <mickael.guene@st.com>
73 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
74 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
75 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
76 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
78 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
79 Mickaël Guêné <mickael.guene@st.com>
81 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
82 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
83 arm*-*-uclinuxfdpiceabi.
84 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
85 arm_elf32_fdpic_le_vec.
86 * configure: Regenerate.
87 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
88 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
89 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
90 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
91 (elf32_arm_fdpic_link_hash_table_create): New.
92 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
93 arm_elf32_fdpic_le_vec.
95 2018-04-25 Alan Modra <amodra@gmail.com>
97 * elf-linux-core.h: Disable gcc-8 string truncation warning.
98 * elf.c (elfcore_write_prpsinfo): Likewise.
100 2018-04-25 Alan Modra <amodra@gmail.com>
102 * Makefile.am: Remove arm-aout and arm-coff support.
103 * config.bfd: Likewise.
104 * configure.ac: Likewise.
105 * targets.c: Likewise.
106 * aout-arm.c: Delete.
107 * armnetbsd.c: Delete.
109 * Makefile.in: Regenerate.
110 * configure: Regenerate.
111 * po/SRC-POTFILES.in: Regenerate.
113 2018-04-24 Nick Clifton <nickc@redhat.com>
116 * elf.c (ignore_section_sym): Check for the output_section pointer
117 being NULL before dereferencing it.
120 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
121 a negative PE_DEBUG_DATA size before iterating over the debug data.
123 2018-04-23 Alan Modra <amodra@gmail.com>
125 * elf-linux-core.h: Revert last change.
128 2018-04-23 Nick Clifton <nickc@redhat.com>
131 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
132 the end of the string table, and zero it.
134 2018-04-23 Alan Modra <amodra@gmail.com>
136 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
137 gcc-8 string truncation warning.
138 (swap_linux_prpsinfo32_ugid16_out): Likewise.
139 (swap_linux_prpsinfo64_ugid32_out): Likewise.
140 (swap_linux_prpsinfo64_ugid16_out): Likewise.
141 * elf.c (elfcore_write_prpsinfo): Likewise.
143 2018-04-23 Nick Clifton <nickc@redhat.com>
146 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
147 the end of the string table, and zero it.
149 2018-04-20 Alan Modra <amodra@gmail.com>
152 * elf32-hppa.c (got_relocs_needed): Add extra param to special
153 case both dtprel and tprel relocs.
154 (allocate_dynrelocs): Adjust conditions for got relocs.
155 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
156 Emit dynamic relocs on TLS GOT entries for shared libraries,
157 not when pic. Omit dynamic reloc on dtprel entry when local,
158 and on tprel entry when local and executable.
160 2018-04-19 Alan Modra <amodra@gmail.com>
163 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
164 (hppa_type_of_stub): Don't return a long branch stub for
165 symbols other than those defined statically.
167 2018-04-19 Alan Modra <amodra@gmail.com>
169 * Makefile.am: Revert 2018-04-18 coff-mips changes.
170 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
171 to selvecs for mips targets change 2018-04-18.
172 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
173 and mips_ecoff_bele_vec.
174 * targets.c: Likewise.
175 * coff-mips.c: Resurrect.
176 * Makefile.in: Regenerate.
177 * configure: Regenerate.
178 * po/SRC-POTFILES.in: Regenerate.
180 2018-04-18 Alan Modra <amodra@gmail.com>
182 * Makefile.am: Remove mips aout and coff support.
183 * config.bfd: Likewise.
184 * configure.ac: Likewise.
185 * targets.c: Likewise.
186 * coff-mips.c: Delete
190 * Makefile.in: Regenerate.
191 * configure: Regenerate.
192 * po/SRC-POTFILES.in: Regenerate.
194 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
196 * elf32-i386.c (elf32_bed): Define before including
198 * elf64-x86-64.c (elf64_bed): Define before including
200 (elf32_bed): Define before including "elf32-target.h".
202 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
205 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
206 normal input file with compatible relocation.
208 2018-04-18 Alan Modra <amodra@gmail.com>
210 * Makefile.am: Remove support for assorted i386 aout and coff targets.
211 * config.bfd: Likewise.
212 * configure.ac: Likewise.
213 * doc/bfdint.texi: Likewise.
214 * targets.c: Likewise.
216 * i386dynix.c: Delete.
217 * i386freebsd.c: Delete.
218 * i386linux.c: Delete.
219 * i386mach3.c: Delete.
220 * i386netbsd.c: Delete.
221 * i386os9k.c: Delete.
222 * Makefile.in: Regenerate.
223 * configure: Regenerate.
224 * po/SRC-POTFILES.in: Regenerate.
226 2018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
228 Microblaze Target: PIC data text relative
230 * bfd/reloc.c (2 new BFD relocations):
231 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
232 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
233 * bfd/bfd-in2.h: Regenerate
234 * bfd/libbfd.h: Regenerate
235 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
236 new relocs and handle them in both relocate and relax functions.
237 (microblaze_elf_reloc_type_lookup): add mapping between for new
239 (microblaze_elf_relocate_section): Handle new relocs in case of
241 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
243 2018-04-17 Nick Clifton <nickc@redhat.com>
246 * aoutx.h (find_nearest_line): Check that the symbol name exists
247 and is long enough, before attempting to see if it is for a .o
249 * hash.c (bfd_hash_hash): Add an assertion that the string is not
251 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
253 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
257 * dwarf2.c (concat_filename): Check for a NULL table pointer.
259 2018-04-16 Nick Clifton <nickc@redhat.com>
262 * coffgen.c (coff_pointerize_aux): Check for an out of range
265 2018-04-16 Alan Modra <amodra@gmail.com>
267 * Makefile.am: Remove arm-epoc-pe support.
268 * coff-arm.c: Likewise.
269 * config.bfd: Likewise.
270 * configure.ac: Likewise.
271 * targets.c: Likewise.
272 * epoc-pe-arm.c: Delete.
273 * epoc-pei-arm.c: Delete.
274 * Makefile.in: Regenerate.
275 * configure: Regenerate.
276 * po/SRC-POTFILES.in: Regenerate.
278 2018-04-16 Alan Modra <amodra@gmail.com>
280 * Makefile.am: Remove sparc-aout and sparc-coff support.
281 * config.bfd: Likewise.
282 * configure.ac: Likewise.
283 * targets.c: Likewise.
284 * aout-sparcle.c: Delete.
286 * cf-sparclynx.c: Delete.
287 * coff-sparc.c: Delete.
289 * sparclinux.c: Delete.
290 * sparclynx.c: Delete.
291 * sparcnetbsd.c: Delete.
293 * Makefile.in: Regenerate.
294 * configure: Regenerate.
295 * po/SRC-POTFILES.in: Regenerate.
297 2018-04-16 Alan Modra <amodra@gmail.com>
299 * Makefile.am: Remove m68k-aout and m68k-coff support.
300 * aoutf1.h: Likewise.
302 * archive.c: Likewise.
303 * bfd-in.h: Likewise.
305 * coffcode.h: Likewise.
306 * coffswap.h: Likewise.
307 * config.bfd: Likewise.
308 * configure.ac: Likewise.
309 * configure.host: Likewise.
310 * doc/bfd.texinfo: Likewise.
311 * doc/bfdint.texi: Likewise.
312 * freebsd.h: Likewise.
313 * gen-aout.c: Likewise.
314 * hpux-core.c: Likewise.
315 * libaout.h: Likewise.
316 * libbfd-in.h: Likewise.
318 * peicode.h: Likewise.
319 * riscix.c: Likewise.
320 * targets.c: Likewise.
322 * coff-apollo.c: Delete.
323 * coff-aux.c: Delete.
324 * coff-m68k.c: Delete.
325 * coff-svm68k.c: Delete.
326 * coff-u68k.c: Delete.
327 * hosts/delta68.h: Delete.
328 * hosts/hp300bsd.h: Delete.
329 * hosts/m68kaux.h: Delete.
330 * hosts/news.h: Delete.
331 * hp300bsd.c: Delete.
332 * hp300hpux.c: Delete.
333 * liboasys.h: Delete.
334 * m68k4knetbsd.c: Delete.
335 * m68klinux.c: Delete.
336 * m68knetbsd.c: Delete.
338 * versados.c: Delete.
339 * Makefile.in: Regenerate.
340 * bfd-in2.h: Regenerate.
341 * configure: Regenerate.
342 * libbfd.h: Regenerate.
343 * po/SRC-POTFILES.in: Regenerate.
345 2018-04-16 Alan Modra <amodra@gmail.com>
347 * Makefile.am: Remove sh5 and sh64 support.
348 * archures.c: Likewise.
349 * config.bfd: Likewise.
350 * configure.ac: Likewise.
351 * cpu-sh.c: Likewise.
352 * elf32-sh-relocs.h: Likewise.
353 * elf32-sh.c: Likewise.
354 * targets.c: Likewise.
355 * elf32-sh64-com.c: Delete.
356 * elf32-sh64.c: Delete.
357 * elf32-sh64.h: Delete.
358 * elf64-sh64.c: Delete.
359 * Makefile.in: Regenerate.
360 * bfd-in2.h: Regenerate.
361 * configure: Regenerate.
362 * po/SRC-POTFILES.in: Regenerate.
364 2018-04-16 Alan Modra <amodra@gmail.com>
366 * Makefile.am: Remove sh-symbianelf support.
367 * config.bfd: Likewise.
368 * configure.ac: Likewise.
369 * targets.c: Likewise.
370 * elf32-sh-symbian.c: Delete.
371 * Makefile.in: Regenerate.
372 * configure: Regenerate.
373 * po/SRC-POTFILES.in: Regenerate.
375 2018-04-16 Alan Modra <amodra@gmail.com>
377 * Makefile.am: Remove vax-bsd and vax-ultrix support.
378 * config.bfd: Likewise.
379 * configure.ac: Likewise.
380 * targets.c: Likewise.
382 * Makefile.in: Regenerate.
383 * configure: Regenerate.
384 * po/SRC-POTFILES.in: Regenerate.
386 2018-04-16 Alan Modra <amodra@gmail.com>
388 * Makefile.am: Remove w65 support.
389 * archures.c: Likewise.
390 * coffcode.h: Likewise.
391 * config.bfd: Likewise.
392 * configure.ac: Likewise.
393 * targets.c: Likewise.
394 * coff-w65.c: Delete.
396 * Makefile.in: Regenerate.
397 * bfd-in2.h: Regenerate.
398 * configure: Regenerate.
399 * po/SRC-POTFILES.in: Regenerate.
401 2018-04-16 Alan Modra <amodra@gmail.com>
403 * Makefile.am: Remove we32k support.
404 * archures.c: Likewise.
405 * coffcode.h: Likewise.
406 * config.bfd: Likewise.
407 * configure.ac: Likewise.
408 * targets.c: Likewise.
409 * coff-we32k.c: Delete.
410 * cpu-we32k.c: Delete.
411 * Makefile.in: Regenerate.
412 * bfd-in2.h: Regenerate.
413 * configure: Regenerate.
414 * po/SRC-POTFILES.in: Regenerate.
416 2018-04-16 Alan Modra <amodra@gmail.com>
418 * Makefile.am: Remove m88k support.
420 * archures.c: Likewise.
421 * coffcode.h: Likewise.
422 * coffswap.h: Likewise.
423 * config.bfd: Likewise.
424 * configure.ac: Likewise.
425 * cpu-ns32k.c: Likewise.
426 * elf32-nds32.c: Likewise.
427 * mach-o.c: Likewise.
428 * netbsd-core.c: Likewise.
430 * targets.c: Likewise.
431 * coff-m88k.c: Delete.
432 * cpu-m88k.c: Delete.
433 * elf32-m88k.c: Delete.
434 * hosts/m88kmach3.h: Delete.
435 * m88kmach3.c: Delete.
436 * m88kopenbsd.c: Delete.
437 * Makefile.in: Regenerate.
438 * bfd-in2.h: Regenerate.
439 * configure: Regenerate.
440 * po/SRC-POTFILES.in: Regenerate.
442 2018-04-16 Alan Modra <amodra@gmail.com>
444 * Makefile.am: Remove i370 support.
445 * archures.c: Likewise.
446 * config.bfd: Likewise.
447 * configure.ac: Likewise.
448 * targets.c: Likewise.
449 * cpu-i370.c: Delete.
450 * elf32-i370.c: Delete.
451 * Makefile.in: Regenerate.
452 * bfd-in2.h: Regenerate.
453 * configure: Regenerate.
454 * po/SRC-POTFILES.in: Regenerate.
456 2018-04-16 Alan Modra <amodra@gmail.com>
458 * Makefile.am: Remove h8500 support.
459 * archures.c: Likewise.
460 * coffcode.h: Likewise.
461 * config.bfd: Likewise.
462 * configure.ac: Likewise.
463 * targets.c: Likewise.
464 * coff-h8500.c: Delete.
465 * cpu-h8500.c: Delete.
466 * Makefile.in: Regenerate.
467 * bfd-in2.h: Regenerate.
468 * configure: Regenerate.
469 * po/SRC-POTFILES.in: Regenerate.
471 2018-04-16 Alan Modra <amodra@gmail.com>
473 * Makefile.am: Remove h8300-coff support.
474 * coffcode.h: Likewise.
475 * config.bfd: Likewise.
476 * configure.ac: Likewise.
477 * reloc16.c: Likewise.
478 * targets.c: Likewise.
479 * coff-h8300.c: Delete.
480 * Makefile.in: Regenerate.
481 * configure: Regenerate.
482 * po/SRC-POTFILES.in: Regenerate.
484 2018-04-16 Alan Modra <amodra@gmail.com>
486 * Makefile.am: Remove IEEE 695 support.
487 * archures.c: Likewise.
489 * config.bfd: Likewise.
490 * configure.ac: Likewise.
491 * doc/bfd.texinfo: Likewise.
492 * doc/bfdint.texi: Likewise.
493 * doc/bfdsumm.texi: Likewise.
494 * section.c: Likewise.
495 * targets.c: Likewise.
498 * Makefile.in: Regenerate.
499 * bfd-in2.h: Regenerate.
500 * configure: Regenerate.
501 * po/SRC-POTFILES.in: Regenerate.
503 2018-04-16 Alan Modra <amodra@gmail.com>
505 * config.bfd: Remove tandem support.
507 2018-04-16 Alan Modra <amodra@gmail.com>
509 * Makefile.am: Remove newsos3 support.
511 * config.bfd: Likewise.
512 * configure.ac: Likewise.
513 * targets.c: Likewise.
515 * Makefile.in: Regenerate.
516 * configure: Regenerate.
517 * po/SRC-POTFILES.in: Regenerate.
519 2018-04-16 Alan Modra <amodra@gmail.com>
521 * Makefile.am: Remove netware support.
522 * bfd-in.h: Likewise.
524 * config.bfd: Likewise.
525 * configure.ac: Likewise.
526 * doc/bfdint.texi: Likewise.
528 * targets.c: Likewise.
530 * nlm-target.h: Delete.
532 * nlm32-alpha.c: Delete.
533 * nlm32-i386.c: Delete.
534 * nlm32-ppc.c: Delete.
535 * nlm32-sparc.c: Delete.
540 * Makefile.in: Regenerate.
541 * bfd-in2.h: Regenerate.
542 * configure: Regenerate.
543 * po/SRC-POTFILES.in: Regenerate.
545 2018-04-16 Alan Modra <amodra@gmail.com>
547 * archures.c: Remove tahoe support.
548 * config.bfd: Likewise.
549 * configure.ac: Likewise.
550 * hosts/tahoe.h: Delete.
551 * bfd-in2.h: Regenerate.
552 * configure: Regenerate.
554 2018-04-14 Alan Modra <amodra@gmail.com>
556 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
557 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
559 (elfNN_bed): Init relropagesize.
560 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
561 select relropagesize.
562 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
563 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
564 (ELF_MINPAGESIZE): Don't define.
565 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
566 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
567 * bfd-in2.h: Regenerate.
569 2018-04-14 Alan Modra <amodra@gmail.com>
571 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
572 on __QNXTARGET__ define.
574 2018-04-14 Alan Modra <amodra@gmail.com>
576 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
579 2018-04-11 Alan Modra <amodra@gmail.com>
581 * aout-adobe.c: Delete.
583 * coff-i860.c: Delete.
584 * coff-i960.c: Delete.
585 * cpu-i860.c: Delete.
586 * cpu-i960.c: Delete.
587 * elf32-i860.c: Delete.
588 * elf32-i960.c: Delete.
589 * hosts/i860mach3.h: Delete.
590 * Makefile.am: Remove i860, i960, bout, and adobe support.
591 * archures.c: Remove i860 and i960 support.
592 * coffcode.h: Likewise.
594 * aoutx.h: Comment updates.
595 * archive.c: Remove BOUT and i960 support.
596 * bfd.c: Remove BOUT support.
597 * coffswap.h: Remove i960 support.
598 * config.bfd: Remove i860, i960 and adobe targets.
599 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
600 * targets.c: Likewise.
601 * ieee.c: Remove i960 support.
602 * mach-o.c: Remove i860 support.
603 * Makefile.in: Regenerate.
604 * bfd-in2.h: Regenerate.
605 * configure: Regenerate.
606 * libbfd.h: Regenerate.
607 * po/SRC-POTFILES.in: Regenerate.
609 2018-04-09 Maciej W. Rozycki <macro@mips.com>
611 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
612 in the BFD symbol referred by the relocation.
613 (mips_elf64_write_rela): Likewise.
615 2018-04-09 Maciej W. Rozycki <macro@mips.com>
617 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
618 error for out-of-range `r_sym' values.
620 2018-04-09 Alan Modra <amodra@gmail.com>
622 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
623 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
624 (ppc64_elf_check_relocs): Set has_pltcall.
625 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
626 (ppc64_elf_inline_plt): New function.
627 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
628 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
629 * elf32-ppc.c (has_pltcall): Define.
630 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
631 (ppc_elf_check_relocs): Set has_pltcall.
632 (ppc_elf_inline_plt): New function.
633 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
634 (ppc_elf_size_dynamic_sections): Likewise.
635 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
637 2018-04-09 Alan Modra <amodra@gmail.com>
639 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
640 (is_plt_seq_reloc): New function.
641 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
642 (ppc_elf_tls_optimize): Handle inline plt call sequence.
643 (ppc_elf_relax_section): Handle PLTCALL reloc.
644 (ppc_elf_relocate_section): Nop out inline plt call sequence when
646 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
647 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
648 (has_tls_get_addr_call): Correct comment.
649 (is_branch_reloc): Add PLTCALL.
650 (is_plt_seq_reloc): New function.
651 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
652 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
653 entry for R_PPC64_PLTCALL.
654 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
655 (ppc_type_of_stub): Handle PLTCALL reloc.
656 (toc_adjusting_stub_needed): Likewise.
657 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
658 reloc insn. Nop out inline plt call sequence when resolving
659 locally. Handle __tls_get_addr inline plt call optimization.
661 2018-04-09 Alan Modra <amodra@gmail.com>
663 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
664 (struct ppc_stub_hash_entry): Add symtype field.
666 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
667 (create_linkage_sections): Create pltlocal and relpltlocal.
668 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
670 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
671 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
672 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
673 Keep PLT entries for inline calls against locals.
674 (ppc_build_one_stub): Use pltlocal as appropriate.
675 (ppc_size_one_stub): Likewise.
676 (ppc64_elf_size_stubs): Set symtype.
677 (build_global_entry_stubs_and_plt): Init pltlocal and write
678 relpltlocal for globals.
679 (write_plt_relocs_for_local_syms): Likewise for local syms.
680 (ppc64_elf_relocate_section): Support PLT for local syms.
681 * elf32-ppc.c (PLT_KEEP): Define.
682 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
683 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
684 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
685 Set PLT_KEEP. Adjust update_local_sym_info call.
686 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
687 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
688 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
689 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
690 (write_global_sym_plt): Init pltlocal and write relpltlocal.
691 (ppc_finish_symbols): Likewise for locals.
693 2018-04-09 Alan Modra <amodra@gmail.com>
695 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
696 for local symbols to..
697 (write_plt_relocs_for_local_syms): ..here. New function.
698 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
700 (build_global_entry_stubs_and_plt): ..here. Rename from
701 build_global_entry_stubs.
702 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
703 Call write_plt_relocs_for_local_syms.
704 * elf32-ppc.c (get_sym_h): New function.
705 (ppc_elf_relax_section): Use get_sym_h.
706 (ppc_elf_relocate_section): Move output of PLT relocs and glink
707 stubs for local symbols to..
708 (ppc_finish_symbols): ..here. New function.
709 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
711 (write_global_sym_plt): ..here. New function.
712 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
713 (ppc_finish_symbols): Declare.
715 2018-04-09 Alan Modra <amodra@gmail.com>
717 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
718 (ppc_elf_relocate_section): Likewise.
719 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
720 (ppc64_elf_relocate_section): Likewise. Correct PLT16
721 resolution to plt entry relative to toc pointer.
723 2018-04-09 Alan Modra <amodra@gmail.com>
725 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
726 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
727 file when other TLS flags are tested in a mask.
728 (TLS_MARK, NON_GOT): Define.
729 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
730 (update_local_sym_info): Don't create got entry when NON_GOT.
731 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
733 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
734 (ppc64_elf_relocate_section): Likewise.
735 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
736 __tls_get_addr calls lacking a marker reloc.
737 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
738 TLS_TPRELGD): Renumber. Update comment.
739 (TLS_MARK, NON_GOT): Define.
740 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
741 (update_local_sym_info): Don't create got entry when NON_GOT.
742 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
744 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
745 __tls_get_addr calls lacking a marker reloc.
747 2018-04-06 H.J. Lu <hongjiu.lu@intel.com>
749 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
750 R_X86_64_converted_reloc_bit.
752 2018-04-05 H.J. Lu <hongjiu.lu@intel.com>
755 * configure: Regenerated.
757 2018-04-05 Alan Modra <amodra@gmail.com>
759 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
760 (elf_hppa_info_to_howto_rel): Likewise.
762 2018-04-04 Maciej W. Rozycki <macro@mips.com>
764 * elf-hppa.h (elf_hppa_info_to_howto): Also return
765 unsuccessfully for unimplemented relocations.
766 (elf_hppa_info_to_howto_rel): Likewise.
768 2018-04-04 Maciej W. Rozycki <macro@mips.com>
770 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
771 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
772 howto lookup failure.
773 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
775 (elf32_i860_info_to_howto_rela): Likewise.
776 (elf32_i860_relocate_splitn): Likewise.
777 (elf32_i860_relocate_pc16): Likewise.
778 (elf32_i860_relocate_pc26): Likewise.
779 (elf32_i860_relocate_section): Likewise.
781 2018-04-04 Maciej W. Rozycki <macro@mips.com>
783 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
784 check for `visium_elf_howto_table' table access.
786 2018-04-04 Maciej W. Rozycki <macro@mips.com>
788 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
789 check for `iq2000_elf_howto_table' table access.
791 2018-04-04 Maciej W. Rozycki <macro@mips.com>
793 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
794 for `elf32_frv_howto_table' table access.
796 2018-04-04 Maciej W. Rozycki <macro@mips.com>
798 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
799 unsuccessfully for placeholder howtos.
800 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
801 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
803 2018-03-29 Maciej W. Rozycki <macro@mips.com>
805 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
806 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
808 2018-03-28 Maciej W. Rozycki <macro@mips.com>
810 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
811 ATTRIBUTE_UNUSED from `abfd'.
813 2018-03-28 Maciej W. Rozycki <macro@mips.com>
815 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
816 `_bfd_error_handler' call formatting.
818 2018-03-28 Maciej W. Rozycki <macro@mips.com>
820 * elf32-mips.c (mips_info_to_howto_rel): Call
821 `mips_elf32_rtype_to_howto' directly rather than via
822 `->elf_backend_mips_rtype_to_howto'.
824 2018-03-28 Renlin Li <renlin.li@arm.com>
827 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
828 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
829 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
830 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
831 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
832 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
833 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
834 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
835 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
836 (elfNN_aarch64_final_link_relocate): Support new relocations.
837 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
839 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
841 2018-03-28 Renlin Li <renlin.li@arm.com>
844 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
845 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
846 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
847 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
848 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
849 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
850 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
851 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
852 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
853 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
854 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
855 TLSLE_LDST16_TPREL_LO12,
856 TLSLE_LDST16_TPREL_LO12_NC,
857 TLSLE_LDST32_TPREL_LO12,
858 TLSLE_LDST32_TPREL_LO12_NC,
859 TLSLE_LDST64_TPREL_LO12,
860 TLSLE_LDST64_TPREL_LO12_NC,
861 TLSLE_LDST8_TPREL_LO12,
862 TLSLE_LDST8_TPREL_LO12_NC.
863 * bfd-in2.h: Regenerated.
864 * libbfd.h: Regenerated.
866 2018-03-28 Eric Botcazou <ebotcazou@adacore.com>
869 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
870 has_old_style_got_reloc.
871 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
872 relocations. Fix a couple of long lines.
873 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
874 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
877 2018-03-25 H.J. Lu <hongjiu.lu@intel.com>
880 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
881 ENDBR64 to the TLSDESC PLT entry.
883 2018-03-21 Alan Modra <amodra@gmail.com>
885 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
886 symbols. Use size_t counts. Delete redundant opd test.
888 2018-03-21 Alan Modra <amodra@gmail.com>
890 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
892 2018-03-21 Alan Modra <amodra@gmail.com>
894 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
896 (update_local_sym_info): Likewise for local_got_tls_masks.
897 (ppc_elf_tls_optimize): Likewise for lgot_masks.
899 2018-03-21 Alan Modra <amodra@gmail.com>
901 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
902 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
903 do in size_dynamic_sections.
905 2018-03-21 Alan Modra <amodra@gmail.com>
907 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
908 without first checking array bounds.
909 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
911 2018-03-20 H.J. Lu <hongjiu.lu@intel.com>
914 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
915 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
917 2018-03-19 Nick Clifton <nickc@redhat.com>
919 * po/es.po: Updated Spanish translation.
921 2018-03-15 Max Filippov <jcmvbkbc@gmail.com>
923 * elf32-xtensa.c (xlate_map_entry): Change types of address
924 fields from 'unsigned' to 'bfd_vma'.
925 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
926 the key argument to bsearch. Allow offsets past the end of a
927 section, use the last map entry for translation of such offsets.
929 2018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
931 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
932 Not support the target feature.
933 (nds32_elf_ex9_itb_base): Likewise.
934 (nds32_elf_ex9_import_table): Likewise.
935 (nds32_elf_ex9_finish): Likewise.
936 (nds32_elf_ex9_reloc_jmp): Likewise.
937 (nds32_elf_get_insn_with_reg): Likewise.
938 (nds32_get_local_syms): Likewise.
939 (nds32_elf_ex9_replace_instruction): Likewise.
940 (nds32_elf_ifc_calc): Likewise.
941 (nds32_elf_ifc_finish): Likewise.
942 (nds32_elf_ifc_replace): Likewise.
943 (nds32_elf_ifc_reloc): Likewise.
945 2018-03-14 Alan Modra <amodra@gmail.com>
947 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
948 sfpr size added before defining alias symbols.
949 (ppc64_elf_build_stubs): Add stub section padding before
950 copying sfpr contents and defining save/restore alias symbols.
952 2018-03-14 H.J. Lu <hongjiu.lu@intel.com>
955 * elflink.c (elf_gc_mark_debug_section): Also check the local
956 debug definition section.
958 2018-03-13 Nick Clifton <nickc@redhat.com>
961 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
962 function. Add an end address parameter. Check access of the data
963 pointer to make sure that they do not extend beyond the end
964 address. Return FALSE if any check fails. Add the end address
965 pointer to the ui structure.
966 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
967 codes to make sure that they do not extend beyond the end address
968 pointer. Print an error message and return immediately if any
971 2018-03-09 Nick Clifton <nickc@redhat.com>
973 * elf64-s390.c (elf_s390_relocate_section): Move check for
974 relocations against non-allocated sections to before the code that
975 handles ifunc relocations.
976 * elf32-s390.c (elf_s390_relocate_section): Likewise.
977 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
978 relocs against IFUNC symbols in non-allocated sections as relocs
979 against FUNC symbols.
980 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
982 2018-03-08 H.J. Lu <hongjiu.lu@intel.com>
985 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
986 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
987 relocation against FUNC symbol.
988 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
990 2018-03-07 Renlin Li <renlin.li@arm.com>
993 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
994 symbol, and don't emit relocation in specific case.
996 2018-03-07 Alan Modra <amodra@gmail.com>
998 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
999 (mips_elf64_slurp_one_reloc_table): Pass on error.
1001 2018-03-03 James Cowgill <james.cowgill@mips.com>
1002 Maciej W. Rozycki <macro@mips.com>
1005 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
1006 after calling `undefined_symbol' hook if this is an error
1007 condition. Assume the value of 0 for the symbol requested
1010 2018-03-02 Jim Wilson <jimw@sifive.com>
1013 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
1014 and nop instead of 4.
1015 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
1018 2018-03-01 Jim Wilson <jimw@sifive.com>
1021 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
1022 else if instead of if.
1024 2018-03-01 Alan Modra <amodra@gmail.com>
1026 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
1028 2018-02-28 Alan Modra <amodra@gmail.com>
1031 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
1033 2018-02-28 Nick Clifton <nickc@redhat.com>
1037 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
1038 pointer. Drop unused abfd parameter. Check the size of the block
1039 before initialising the data field. Return the end pointer if the
1041 (read_attribute_value): Adjust invocations of read_n_bytes.
1044 * dwarf1.c (parse_die): Check the length of form blocks before
1045 advancing the data pointer.
1047 2018-02-28 Alan Modra <amodra@gmail.com>
1050 * aoutx.h (translate_symbol_table): Print an error message and set
1051 bfd_error on finding an invalid name string offset.
1053 2018-02-27 H.J. Lu <hongjiu.lu@intel.com>
1055 * config.in: Regenerated.
1056 * configure: Likewise.
1057 * configure.ac: Add --enable-separate-code.
1058 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
1059 to 1 for Linux/x86 targets,
1060 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
1061 DEFAULT_LD_Z_SEPARATE_CODE is 1.
1063 2018-02-27 Nick Clifton <nickc@redhat.com>
1065 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
1067 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
1068 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
1069 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
1070 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
1071 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1072 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
1073 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1074 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
1075 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
1078 * elf-bfd.h (struct elf_backend_data): Change the return type of
1079 the elf_info_to_howto and elf_info_to_howto_rel function pointers
1081 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
1082 value from the info_to_howto function and fail if that function
1084 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
1085 from the info_to_howto function.
1086 (elf32_h8_relax_section): Likewise.
1087 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
1088 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
1089 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
1090 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1091 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
1092 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
1093 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
1094 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
1095 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
1096 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
1097 (riscv_elf_relocate_section): Likewise.
1098 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
1099 bfd_boolean. Issue an error message, set an error value and
1100 return FALSE if the reloc is not recognized.
1101 (elf_hppa_info_to_howto_rel): Likewise.
1102 * elf-m10200.c (mn10200_info_to_howto): Likewise.
1103 * elf-m10300.c (mn10300_info_to_howto): Likewise.
1104 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
1105 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
1106 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
1107 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
1108 * elf32-bfin.c (bfin_info_to_howto): Likewise.
1109 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
1110 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
1111 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
1112 (cris_info_to_howto_rela): Likewise.
1113 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
1114 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
1115 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
1117 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
1118 (elf32_dlx_info_to_howto_rel): Likewise.
1119 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
1120 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
1121 * elf32-frv.c (frv_info_to_howto_rela)
1122 (frvfdpic_info_to_howto_rel): Likewise.
1123 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
1124 * elf32-gen.c (elf_generic_info_to_howto)
1125 (elf_generic_info_to_howto_rel): Likewise.
1126 * elf32-h8300.c (elf32_h8_info_to_howto)
1127 (elf32_h8_info_to_howto_rel): Likewise.
1128 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
1129 * elf32-i386.c (elf_i386_reloc_type_lookup)
1130 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
1131 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
1133 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
1134 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
1135 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
1136 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
1137 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
1138 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
1140 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
1141 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
1142 * elf32-m68k.c (rtype_to_howto): Likewise.
1143 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
1144 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
1145 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
1146 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
1147 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1149 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
1150 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
1151 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
1152 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
1154 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
1155 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
1156 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
1157 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
1158 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
1159 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
1160 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
1161 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
1162 * elf32-score.c (s3_bfd_score_info_to_howto)
1163 (_bfd_score_info_to_howto): Likewise.
1164 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
1165 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
1166 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
1167 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
1168 (elf32_tic6x_info_to_howto_rel): Likewise.
1169 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
1170 * elf32-v850.c (v850_elf_info_to_howto_rel)
1171 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
1172 * elf32-vax.c (rtype_to_howto): Likewise.
1173 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
1174 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
1175 (elf32_wasm32_info_to_howto_rela): Likewise.
1176 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
1177 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
1178 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
1179 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
1180 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
1181 * elf64-gen.c (elf_generic_info_to_howto)
1182 (elf_generic_info_to_howto_rel): Likewise.
1183 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
1184 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
1185 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
1186 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
1187 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1188 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
1190 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
1191 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1193 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
1194 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
1195 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
1196 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1197 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
1198 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
1199 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
1200 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
1201 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
1202 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
1205 2018-02-26 Jim Wilson <jimw@sifive.com>
1206 Stephan Schreiber <info@fs-driver.org>
1209 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
1210 call, set changed_contents and changed_relocs. Likewise after
1211 successful ia64_elf_relax_br call.
1213 2018-02-26 Alan Modra <amodra@gmail.com>
1215 * elf.c (assign_file_positions_except_relocs): Don't segfault
1216 when actual number of phdrs is less than allocated. Delete
1217 outdated comment. Formatting.
1219 2018-02-26 Alan Modra <amodra@gmail.com>
1221 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
1222 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
1223 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
1224 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
1225 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
1226 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
1227 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
1228 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
1229 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
1230 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
1231 error/warning messages.
1233 2018-02-26 Alan Modra <amodra@gmail.com>
1235 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
1236 * syms.c: Standardize error/warning messages.
1238 2018-02-26 Alan Modra <amodra@gmail.com>
1240 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
1241 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
1242 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
1243 * peXXigen.c, * peicode.h: Standardize error/warning messages.
1245 2018-02-26 Alan Modra <amodra@gmail.com>
1247 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
1249 2018-02-26 Alan Modra <amodra@gmail.com>
1251 * elfxx-mips.c: Standardize error/warning messages.
1253 2018-02-26 Alan Modra <amodra@gmail.com>
1255 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
1256 * elflink.c: Standardize error/warning messages. Replace use of
1257 linker callback einfo with _bfd_error_handler when possible.
1259 2018-02-26 Alan Modra <amodra@gmail.com>
1261 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
1262 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
1263 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
1264 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
1265 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
1266 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
1267 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
1268 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
1269 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
1270 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
1271 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
1272 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
1273 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
1274 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
1275 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
1276 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
1277 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
1278 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
1279 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
1280 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
1281 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
1282 unrecognized/unsupported reloc message.
1284 2018-02-26 Alan Modra <amodra@gmail.com>
1286 * elf32-ppc.c: Standardize error/warning messages. Use
1287 _bfd_error_handler rather than einfo when einfo features not used.
1288 * elf64-ppc.c: Likewise.
1290 2018-02-23 Alan Modra <amodra@gmail.com>
1293 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
1294 segment if no matching LOAD segment.
1296 2018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1298 * elf32-nds32.h: Define mask for ict_model.
1300 2018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
1302 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
1304 2018-02-19 Maciej W. Rozycki <macro@mips.com>
1307 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
1309 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
1310 .reginfo section has wrong size.
1312 2018-02-19 Maciej W. Rozycki <macro@mips.com>
1314 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
1315 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
1316 `.MIPS.abiflags' sections.
1317 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
1320 2018-02-19 Maciej W. Rozycki <macro@mips.com>
1322 * section.c (SEC_FIXED_SIZE): New macro.
1323 * bfd-in2.h: Regenerate.
1325 2018-02-19 Maciej W. Rozycki <macro@mips.com>
1327 * section.c (SEC_HAS_GOT_REF): Remove macro.
1328 * bfd-in2.h: Regenerate.
1330 2018-02-19 Alan Modra <amodra@gmail.com>
1332 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
1334 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
1335 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
1336 (_bfd_riscv_relax_pc): Likewise and fix typos.
1337 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
1338 * libbfd.h: Regenerate.
1340 2018-02-19 Alan Modra <amodra@gmail.com>
1342 * dwarf2.c (read_section): Don't use 'll' format modifier.
1343 (find_abstract_instance): Likewise.
1344 * elfcore.h (elf_core_file_p): Likewise.
1346 2018-02-19 Alan Modra <amodra@gmail.com>
1348 * bfd-in.h: Include inttypes.h or if not available define
1349 PRId64, PRIu64 and PRIx64.
1350 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
1351 modifier to print bfd_vma.
1352 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
1353 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
1354 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
1355 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
1356 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
1357 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
1358 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
1359 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
1360 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
1361 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
1362 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
1363 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
1364 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
1365 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
1366 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
1367 and cast input to uint64_t, and similarly for Ld and Lu.
1368 * bfd-in2.h: Regenerate.
1370 2018-02-19 Alan Modra <amodra@gmail.com>
1372 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
1373 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
1374 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
1375 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
1376 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
1377 * reloc.c: Replace use of %R and %T in format strings passed to
1378 einfo and friends by %pR and %pT.
1380 2018-02-19 Alan Modra <amodra@gmail.com>
1382 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
1384 * aout-adobe.c: Update all messages using %A and %B.
1385 * aout-cris.c: Likewise.
1386 * aoutx.h: Likewise.
1387 * archive.c: Likewise.
1388 * binary.c: Likewise.
1389 * cache.c: Likewise.
1390 * coff-alpha.c: Likewise.
1391 * coff-arm.c: Likewise.
1392 * coff-i860.c: Likewise.
1393 * coff-mcore.c: Likewise.
1394 * coff-ppc.c: Likewise.
1395 * coff-rs6000.c: Likewise.
1396 * coff-sh.c: Likewise.
1397 * coff-tic4x.c: Likewise.
1398 * coff-tic54x.c: Likewise.
1399 * coff-tic80.c: Likewise.
1400 * coff64-rs6000.c: Likewise.
1401 * coffcode.h: Likewise.
1402 * coffgen.c: Likewise.
1403 * cofflink.c: Likewise.
1404 * coffswap.h: Likewise.
1405 * compress.c: Likewise.
1406 * cpu-arm.c: Likewise.
1407 * ecoff.c: Likewise.
1408 * elf-attrs.c: Likewise.
1409 * elf-eh-frame.c: Likewise.
1410 * elf-ifunc.c: Likewise.
1411 * elf-m10300.c: Likewise.
1412 * elf-properties.c: Likewise.
1413 * elf-s390-common.c: Likewise.
1415 * elf32-arc.c: Likewise.
1416 * elf32-arm.c: Likewise.
1417 * elf32-avr.c: Likewise.
1418 * elf32-bfin.c: Likewise.
1419 * elf32-cr16.c: Likewise.
1420 * elf32-cr16c.c: Likewise.
1421 * elf32-cris.c: Likewise.
1422 * elf32-crx.c: Likewise.
1423 * elf32-d10v.c: Likewise.
1424 * elf32-d30v.c: Likewise.
1425 * elf32-epiphany.c: Likewise.
1426 * elf32-fr30.c: Likewise.
1427 * elf32-frv.c: Likewise.
1428 * elf32-gen.c: Likewise.
1429 * elf32-hppa.c: Likewise.
1430 * elf32-i370.c: Likewise.
1431 * elf32-i386.c: Likewise.
1432 * elf32-i960.c: Likewise.
1433 * elf32-ip2k.c: Likewise.
1434 * elf32-iq2000.c: Likewise.
1435 * elf32-lm32.c: Likewise.
1436 * elf32-m32c.c: Likewise.
1437 * elf32-m32r.c: Likewise.
1438 * elf32-m68hc11.c: Likewise.
1439 * elf32-m68hc12.c: Likewise.
1440 * elf32-m68hc1x.c: Likewise.
1441 * elf32-m68k.c: Likewise.
1442 * elf32-mcore.c: Likewise.
1443 * elf32-mep.c: Likewise.
1444 * elf32-metag.c: Likewise.
1445 * elf32-microblaze.c: Likewise.
1446 * elf32-moxie.c: Likewise.
1447 * elf32-msp430.c: Likewise.
1448 * elf32-mt.c: Likewise.
1449 * elf32-nds32.c: Likewise.
1450 * elf32-nios2.c: Likewise.
1451 * elf32-or1k.c: Likewise.
1452 * elf32-pj.c: Likewise.
1453 * elf32-ppc.c: Likewise.
1454 * elf32-rl78.c: Likewise.
1455 * elf32-rx.c: Likewise.
1456 * elf32-s390.c: Likewise.
1457 * elf32-score.c: Likewise.
1458 * elf32-score7.c: Likewise.
1459 * elf32-sh-symbian.c: Likewise.
1460 * elf32-sh.c: Likewise.
1461 * elf32-sh64.c: Likewise.
1462 * elf32-sparc.c: Likewise.
1463 * elf32-spu.c: Likewise.
1464 * elf32-tic6x.c: Likewise.
1465 * elf32-tilepro.c: Likewise.
1466 * elf32-v850.c: Likewise.
1467 * elf32-vax.c: Likewise.
1468 * elf32-visium.c: Likewise.
1469 * elf32-wasm32.c: Likewise.
1470 * elf32-xgate.c: Likewise.
1471 * elf32-xtensa.c: Likewise.
1472 * elf64-alpha.c: Likewise.
1473 * elf64-gen.c: Likewise.
1474 * elf64-hppa.c: Likewise.
1475 * elf64-ia64-vms.c: Likewise.
1476 * elf64-mmix.c: Likewise.
1477 * elf64-ppc.c: Likewise.
1478 * elf64-s390.c: Likewise.
1479 * elf64-sh64.c: Likewise.
1480 * elf64-sparc.c: Likewise.
1481 * elf64-x86-64.c: Likewise.
1482 * elfcode.h: Likewise.
1483 * elfcore.h: Likewise.
1484 * elflink.c: Likewise.
1485 * elfnn-aarch64.c: Likewise.
1486 * elfnn-ia64.c: Likewise.
1487 * elfnn-riscv.c: Likewise.
1488 * elfxx-mips.c: Likewise.
1489 * elfxx-sparc.c: Likewise.
1490 * elfxx-tilegx.c: Likewise.
1491 * elfxx-x86.c: Likewise.
1492 * hpux-core.c: Likewise.
1495 * libbfd.c: Likewise.
1496 * linker.c: Likewise.
1497 * mach-o.c: Likewise.
1498 * merge.c: Likewise.
1500 * oasys.c: Likewise.
1501 * pdp11.c: Likewise.
1502 * pe-mips.c: Likewise.
1503 * peXXigen.c: Likewise.
1504 * peicode.h: Likewise.
1505 * reloc.c: Likewise.
1506 * rs6000-core.c: Likewise.
1508 * stabs.c: Likewise.
1509 * vms-alpha.c: Likewise.
1510 * xcofflink.c: Likewise.
1512 2018-02-19 Alan Modra <amodra@gmail.com>
1515 * elf.c (IS_TBSS): Define.
1516 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
1517 (assign_file_positions_for_non_load_sections): Revert last change.
1518 Properly calculate load segment limits to compare against relro limits.
1520 2018-02-17 Alan Modra <amodra@gmail.com>
1523 * elf.c (assign_file_positions_for_non_load_sections): Ignore
1524 degenerate zero size PT_LOAD segments when finding one overlapping
1525 the PT_GNU_RELRO segment.
1527 2018-02-16 Alan Modra <amodra@gmail.com>
1529 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
1530 (_bfd_bool_bfd_true): Rename from bfd_true.
1531 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
1532 (_bfd_int_bfd_0): Rename from bfd_0.
1533 (_bfd_uint_bfd_0): Rename from bfd_0u.
1534 (_bfd_long_bfd_0): Rename from bfd_0l.
1535 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
1536 (_bfd_void_bfd): Rename from bfd_void.
1537 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
1538 (_bfd_bool_bfd_link_false_error),
1539 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
1540 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
1541 (_bfd_bool_bfd_asection_bfd_asection_true),
1542 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
1543 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
1544 * archive.c (_bfd_noarchive_get_elt_at_index),
1545 (_bfd_noarchive_openr_next_archived_file),
1546 (_bfd_noarchive_construct_extended_name_table),
1547 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
1548 (_bfd_noarchive_write_armap): New functions.
1549 * archures.c (_bfd_nowrite_set_arch_mach): New function.
1550 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
1551 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
1552 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
1553 (alpha_ecoff_swap_coff_lineno_out),
1554 (alpha_ecoff_swap_coff_reloc_out): New functions.
1555 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
1556 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
1557 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
1558 (mips_ecoff_swap_coff_lineno_out),
1559 (mips_ecoff_swap_coff_reloc_out): New functions.
1560 * coffcode.h (coff_set_alignment_hook): Replace define with
1562 (symname_in_debug_hook): Likewise.
1563 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
1564 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
1565 * elf.c (assign_file_positions_except_relocs): Test
1566 elf_backend_allow_non_load_phdr for NULL.
1567 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
1568 _bfd_elf_link_omit_section_dynsym. Update uses.
1569 (_bfd_elf_omit_section_dynsym_all): New function.
1570 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
1571 (_bfd_elf_omit_section_dynsym_default): Declare.
1572 (_bfd_elf_omit_section_dynsym_all): Declare.
1573 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
1574 (_bfd_nolink_bfd_get_relocated_section_contents),
1575 (_bfd_nolink_bfd_lookup_section_flags),
1576 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
1577 (_bfd_nolink_bfd_link_hash_table_create),
1578 (_bfd_nolink_bfd_link_just_syms),
1579 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
1580 (_bfd_nolink_bfd_link_split_section),
1581 (_bfd_nolink_section_already_linked),
1582 (_bfd_nolink_bfd_define_common_symbol),
1583 (_bfd_nolink_bfd_define_start_stop): New functions.
1584 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
1585 (_bfd_norelocs_bfd_reloc_name_lookup),
1586 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
1587 * section.c (_bfd_nowrite_set_section_contents): New function.
1588 * syms.c (_bfd_nosymbols_canonicalize_symtab),
1589 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
1590 (_bfd_nosymbols_get_symbol_version_string),
1591 (_bfd_nosymbols_bfd_is_local_label_name),
1592 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
1593 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
1594 (_bfd_nosymbols_bfd_make_debug_symbol),
1595 ( _bfd_nosymbols_read_minisymbols),
1596 ( _bfd_nosymbols_minisymbol_to_symbol),
1597 (_bfd_nodynamic_get_synthetic_symtab): New functions.
1598 * libbfd-in.h: Declare new functions. Update existing defines,
1600 * aix386-core.c: Update to use new hooks. Formatting.
1601 * aout-adobe.c: Likewise.
1602 * aout-arm.c: Likewise.
1603 * aout-target.h: Likewise.
1604 * aout-tic30.c: Likewise.
1605 * aoutf1.h: Likewise.
1606 * binary.c: Likewise.
1608 * cisco-core.c: Likewise.
1609 * coff-alpha.c: Likewise.
1610 * coff-i386.c: Likewise.
1611 * coff-i860.c: Likewise.
1612 * coff-i960.c: Likewise.
1613 * coff-ia64.c: Likewise.
1614 * coff-mips.c: Likewise.
1615 * coff-ppc.c: Likewise.
1616 * coff-rs6000.c: Likewise.
1617 * coff-sh.c: Likewise.
1618 * coff-tic30.c: Likewise.
1619 * coff-tic54x.c: Likewise.
1620 * coff-x86_64.c: Likewise.
1621 * coff64-rs6000.c: Likewise.
1622 * coffcode.h: Likewise.
1623 * elf-m10300.c: Likewise.
1624 * elf32-cr16.c: Likewise.
1625 * elf32-lm32.c: Likewise.
1626 * elf32-m32r.c: Likewise.
1627 * elf32-metag.c: Likewise.
1628 * elf32-score.c: Likewise.
1629 * elf32-score7.c: Likewise.
1630 * elf32-tilepro.c: Likewise.
1631 * elf32-xstormy16.c: Likewise.
1632 * elf32-xtensa.c: Likewise.
1633 * elf64-alpha.c: Likewise.
1634 * elf64-hppa.c: Likewise.
1635 * elf64-ia64-vms.c: Likewise.
1636 * elf64-mmix.c: Likewise.
1637 * elf64-sh64.c: Likewise.
1638 * elfnn-ia64.c: Likewise.
1639 * elfxx-sparc.c: Likewise.
1640 * elfxx-target.h: Likewise.
1641 * elfxx-tilegx.c: Likewise.
1642 * elfxx-x86.h: Likewise.
1643 * hp300hpux.c: Likewise.
1644 * hppabsd-core.c: Likewise.
1645 * hpux-core.c: Likewise.
1646 * i386msdos.c: Likewise.
1647 * i386os9k.c: Likewise.
1650 * irix-core.c: Likewise.
1651 * libaout.h: Likewise.
1652 * libecoff.h: Likewise.
1653 * mach-o-target.c: Likewise.
1654 * mach-o.c: Likewise.
1655 * mipsbsd.c: Likewise.
1657 * netbsd-core.c: Likewise.
1658 * nlm-target.h: Likewise.
1659 * oasys.c: Likewise.
1660 * osf-core.c: Likewise.
1661 * pdp11.c: Likewise.
1662 * pe-mips.c: Likewise.
1663 * pe-x86_64.c: Likewise.
1665 * plugin.c: Likewise.
1666 * ppcboot.c: Likewise.
1667 * ptrace-core.c: Likewise.
1668 * sco5-core.c: Likewise.
1670 * sparclynx.c: Likewise.
1672 * tekhex.c: Likewise.
1673 * trad-core.c: Likewise.
1674 * verilog.c: Likewise.
1675 * versados.c: Likewise.
1676 * vms-alpha.c: Likewise.
1677 * vms-lib.c: Likewise.
1678 * wasm-module.c: Likewise.
1680 * libbfd.h: Regenerate.
1682 2018-02-15 Jim Wilson <jimw@sifive.com>
1684 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
1685 symbols whose section address is zero.
1687 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
1688 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
1689 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
1690 Add %X%P to error messages.
1692 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
1695 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
1696 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
1697 and assert that the result of the call is not NULL.
1699 2018-02-14 Nick Clifton <nickc@redhat.com>
1702 Revert previous delta. Add extra casts to avoid compile time
1704 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
1705 cast to avoid warning from gcc v8 compiler.
1706 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
1707 (_bfd_generic_bfd_set_private_flags): Likewise.
1708 (_bfd_generic_bfd_copy_private_section_data): Likewise.
1709 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
1710 (_bfd_generic_bfd_copy_private_header_data): Likewise.
1711 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
1712 (_bfd_noarchive_construct_extended_name_table): Likewise.
1713 (_bfd_noarchive_truncate_arname): Likewise.
1714 (_bfd_noarchive_write_ar_hdr): Likewise.
1715 (_bfd_noarchive_get_elt_at_index): Likewise.
1716 (_bfd_nosymbols_canonicalize_symtab): Likewise.
1717 (_bfd_nosymbols_print_symbol): Likewise.
1718 (_bfd_nosymbols_get_symbol_info): Likewise.
1719 (_bfd_nosymbols_get_symbol_version_string): Likewise.
1720 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
1721 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
1722 (_bfd_nosymbols_get_lineno): Likewise.
1723 (_bfd_nosymbols_find_nearest_line): Likewise.
1724 (_bfd_nosymbols_find_line): Likewise.
1725 (_bfd_nosymbols_find_inliner_info): Likewise.
1726 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
1727 (_bfd_nosymbols_read_minisymbols): Likewise.
1728 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
1729 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
1730 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
1731 (_bfd_nowrite_set_arch_mach): Likewise.
1732 (_bfd_nowrite_set_section_contents): Likewise.
1733 (_bfd_nolink_sizeof_headers): Likewise.
1734 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
1735 (_bfd_nolink_bfd_relax_section): Likewise.
1736 (_bfd_nolink_bfd_gc_sections): Likewise.
1737 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
1738 (_bfd_nolink_bfd_merge_sections): Likewise.
1739 (_bfd_nolink_bfd_is_group_section): Likewise.
1740 (_bfd_nolink_bfd_discard_group): Likewise.
1741 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
1742 (_bfd_nolink_bfd_link_add_symbols): Likewise.
1743 (_bfd_nolink_bfd_link_just_syms): Likewise.
1744 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
1745 (_bfd_nolink_bfd_final_link): Likewise.
1746 (_bfd_nolink_bfd_link_split_section): Likewise.
1747 (_bfd_nolink_section_already_linked): Likewise.
1748 (_bfd_nolink_bfd_define_common_symbol): Likewise.
1749 (_bfd_nolink_bfd_define_start_stop): Likewise.
1750 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
1751 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
1752 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
1753 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
1754 * libbfd.c (bfd_false_any): Delete.
1755 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
1756 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
1757 * libbfd.h (extern): Regenerate
1758 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
1759 cast to avoid warning from gcc v8 compiler.
1760 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
1761 * binary.c (binary_get_symbol_info): Likewise.
1762 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
1763 * coff-mips.c (mips_ecoff_backend_data): Likewise.
1764 * coffcode.h (coff_set_alignment_hook): Likewise.
1765 (symname_in_debug_hook): Likewise.
1766 (bfd_coff_backend_data bigobj_swap_table): Likewise.
1767 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
1768 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
1769 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
1770 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
1771 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
1772 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
1773 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
1774 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
1775 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
1776 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
1777 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
1778 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
1779 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
1780 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
1781 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
1782 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
1783 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
1784 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
1785 (bfd_elfNN_bfd_set_private_flags): Likewise.
1786 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
1787 (elf_backend_init_index_section): Likewise.
1788 (elf_backend_allow_non_load_phdr): Likewise.
1789 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
1790 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
1791 * ieee.c (ieee_construct_extended_name_table): Likewise.
1792 (ieee_write_armap): Likewise.
1793 (ieee_write_ar_hdr): Likewise.
1794 (ieee_bfd_is_target_special_symbol): Likewise.
1795 * ihex.c (ihex_canonicalize_symtab): Likewise.
1796 (ihex_bfd_is_target_special_symbol): Likewise.
1797 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
1798 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
1799 (_bfd_ecoff_set_alignment_hook): Likewise.
1800 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
1801 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
1802 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
1803 * oasys.c (oasys_construct_extended_name_table): Likewise.
1804 (oasys_write_armap): Likewise.
1805 (oasys_write_ar_hdr): Likewise.
1806 (oasys_bfd_is_target_special_symbol): Likewise.
1807 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
1808 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
1809 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
1810 * som.c (som_bfd_is_target_special_symbol): Likewise.
1811 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
1812 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
1813 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
1814 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
1815 (versados_bfd_reloc_name_lookup): Likewise.
1816 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
1817 (vms_bfd_define_start_stop): Likewise.
1818 (alpha_vms_bfd_is_target_special_symbol): Likewise.
1819 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
1820 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
1822 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
1825 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
1826 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
1827 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
1828 R_X86_64_PC32 reloc against dynamic function in data section.
1829 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
1830 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
1831 against dynamic function in data section.
1832 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
1833 function address only if pcrel_plt is true.
1834 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
1835 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
1836 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
1837 PC-relative relocation against a function definition in data
1838 secton in PIE. Remove the obsolete comments.
1839 (elf_x86_link_hash_table): Add pcrel_plt.
1841 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
1843 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
1844 instead of bfd_link_pic, for building shared library.
1846 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
1849 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
1850 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
1851 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
1852 against protected function in shared object.
1854 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
1857 * po/ru.po: Fix typo in Russian translation.
1859 2018-02-13 Maciej W. Rozycki <macro@mips.com>
1861 * wasm-module.c (wasm_scan_name_function_section): Rename
1862 `index' local variable to `idx'.
1864 2018-02-13 Nick Clifton <nickc@redhat.com>
1867 Fix compile time warnings generated by gcc version 8.
1868 * libbfd-in.h: Remove extraneous text from prototypes.
1869 Add prototypes for bfd_false_any, bfd_true_any,
1870 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
1871 bfd_n1_any, bfd_void_any.
1872 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
1874 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
1875 (_bfd_generic_bfd_set_private_flags): Likewise.
1876 (_bfd_generic_bfd_copy_private_section_data): Likewise.
1877 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
1878 (_bfd_generic_bfd_copy_private_header_data): Likewise.
1879 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
1880 (_bfd_noarchive_construct_extended_name_table): Likewise.
1881 (_bfd_noarchive_truncate_arname): Likewise.
1882 (_bfd_noarchive_write_ar_hdr): Likewise.
1883 (_bfd_noarchive_get_elt_at_index): Likewise.
1884 (_bfd_nosymbols_canonicalize_symtab): Likewise.
1885 (_bfd_nosymbols_print_symbol): Likewise.
1886 (_bfd_nosymbols_get_symbol_info): Likewise.
1887 (_bfd_nosymbols_get_symbol_version_string): Likewise.
1888 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
1889 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
1890 (_bfd_nosymbols_get_lineno): Likewise.
1891 (_bfd_nosymbols_find_nearest_line): Likewise.
1892 (_bfd_nosymbols_find_line): Likewise.
1893 (_bfd_nosymbols_find_inliner_info): Likewise.
1894 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
1895 (_bfd_nosymbols_read_minisymbols): Likewise.
1896 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
1897 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
1898 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
1899 (_bfd_nowrite_set_arch_mach): Likewise.
1900 (_bfd_nowrite_set_section_contents): Likewise.
1901 (_bfd_nolink_sizeof_headers): Likewise.
1902 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
1903 (_bfd_nolink_bfd_relax_section): Likewise.
1904 (_bfd_nolink_bfd_gc_sections): Likewise.
1905 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
1906 (_bfd_nolink_bfd_merge_sections): Likewise.
1907 (_bfd_nolink_bfd_is_group_section): Likewise.
1908 (_bfd_nolink_bfd_discard_group): Likewise.
1909 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
1910 (_bfd_nolink_bfd_link_add_symbols): Likewise.
1911 (_bfd_nolink_bfd_link_just_syms): Likewise.
1912 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
1913 (_bfd_nolink_bfd_final_link): Likewise.
1914 (_bfd_nolink_bfd_link_split_section): Likewise.
1915 (_bfd_nolink_section_already_linked): Likewise.
1916 (_bfd_nolink_bfd_define_common_symbol): Likewise.
1917 (_bfd_nolink_bfd_define_start_stop): Likewise.
1918 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
1919 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
1920 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
1921 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
1922 * libbfd.c (bfd_false_any): New function. Like bfd_false but
1923 accepts one or more arguments.
1924 (bfd_true_any): Likewise.
1925 (bfd_nullvoidptr_any): Likewise.
1926 (bfd_0_any): Likewise.
1927 (bfd_0u_any): Likewise.
1928 (bfd_0l_any): Likewise.
1929 (_bfd_n1_any): Likewise.
1930 (bfd_void_any): Likewise.
1931 * libbfd.h (extern): Regenerate
1932 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
1933 based dummy function.
1934 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
1935 * binary.c (binary_get_symbol_info): Likewise.
1936 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
1937 * coff-mips.c (mips_ecoff_backend_data): Likewise.
1938 * coffcode.h (coff_set_alignment_hook): Likewise.
1939 (symname_in_debug_hook): Likewise.
1940 (bfd_coff_backend_data bigobj_swap_table): Likewise.
1941 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
1942 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
1943 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
1944 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
1945 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
1946 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
1947 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
1948 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
1949 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
1950 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
1951 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
1952 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
1953 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
1954 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
1955 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
1956 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
1957 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
1958 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
1959 (bfd_elfNN_bfd_set_private_flags): Likewise.
1960 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
1961 (elf_backend_init_index_section): Likewise.
1962 (elf_backend_allow_non_load_phdr): Likewise.
1963 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
1964 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
1965 * ieee.c (ieee_construct_extended_name_table): Likewise.
1966 (ieee_write_armap): Likewise.
1967 (ieee_write_ar_hdr): Likewise.
1968 (ieee_bfd_is_target_special_symbol): Likewise.
1969 * ihex.c (ihex_canonicalize_symtab): Likewise.
1970 (ihex_bfd_is_target_special_symbol): Likewise.
1971 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
1972 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
1973 (_bfd_ecoff_set_alignment_hook): Likewise.
1974 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
1975 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
1976 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
1977 * oasys.c (oasys_construct_extended_name_table): Likewise.
1978 (oasys_write_armap): Likewise.
1979 (oasys_write_ar_hdr): Likewise.
1980 (oasys_bfd_is_target_special_symbol): Likewise.
1981 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
1982 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
1983 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
1984 * som.c (som_bfd_is_target_special_symbol): Likewise.
1985 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
1986 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
1987 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
1988 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
1989 (versados_bfd_reloc_name_lookup): Likewise.
1990 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
1991 (vms_bfd_define_start_stop): Likewise.
1992 (alpha_vms_bfd_is_target_special_symbol): Likewise.
1993 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
1994 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
1995 * elf32-arc.c (get_replace_function): Assign replacement function
1997 * elf32-i370.c (i370_noop): Update prototype.
1999 2018-02-13 Alan Modra <amodra@gmail.com>
2002 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
2003 relocation sections. If size reduces to just the flag word,
2004 remove that too and mark with SEC_EXCLUDE.
2005 * elflink.c (bfd_elf_final_link): Strip empty group sections.
2007 2018-02-13 Alan Modra <amodra@gmail.com>
2010 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
2013 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
2015 * i386msdos.c (msdos_mkobject); New function.
2016 (msdos_object_p): New function.
2017 (i386_msdos_vec): Use msdos_object_p as the check_format
2019 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
2020 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
2022 * peXXigen.c: Likewise.
2023 * coff-ia64.c: Likewise.
2025 2018-02-12 Nick Clifton <nickc@redhat.com>
2027 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
2029 * elf32-arc.c (elf_arc_relocate_section): Likewise.
2031 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
2033 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
2034 (sparc_elf_append_rela): Assert that there is enough room in section.
2035 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
2036 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
2037 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
2038 For a symbol subject to a GOT relocation, reserve a slot in the
2039 relocation section if the symbol isn't dynamic and we are in PIC mode.
2040 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
2041 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
2042 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
2043 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
2044 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
2045 resolved_to_zero. Do not generate a dynamic GOT relocation for an
2046 undefined weak symbol with non-default visibility. Remove superfluous
2047 'else' and fix formatting.
2049 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
2051 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
2053 (i386_elf32_sol2_vec): Don't declare.
2054 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
2055 Don't set need_global_offset_table.
2056 (elf_i386_solaris_arch_bed): New.
2057 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
2059 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
2060 target_os != is_nacl instead of target_os == is_normal.
2061 (x86_64_elf64_sol2_vec): Don't declare.
2062 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
2063 is_nacl instead of target_os == is_normal. Don't set
2064 need_global_offset_table.
2065 (elf_x86_64_solaris_arch_bed): New.
2066 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
2068 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
2069 _GLOBAL_OFFSET_TABLE_ for Solaris.
2070 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
2071 need_global_offset_table.
2072 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
2073 (elf_x86_link_hash_table): Remove need_global_offset_table.
2074 (elf_x86_init_table): Likewise.
2076 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2078 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2080 (i386_elf32_sol2_vec): Declared.
2081 (elf_i386_link_setup_gnu_properties): Set
2082 need_global_offset_table with info->output_bfd->xvec.
2083 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2085 (x86_64_elf64_sol2_vec): Declared.
2086 (elf_x86_64_link_setup_gnu_properties): Set
2087 need_global_offset_table with info->output_bfd->xvec.
2089 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2091 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2093 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
2095 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2097 (elf_x86_64_link_setup_gnu_properties): Set
2098 need_global_offset_table for Solaris.
2099 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
2100 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
2101 (_bfd_x86_elf_link_setup_gnu_properties): Copy
2102 need_global_offset_table.
2103 * elfxx-x86.h (elf_x86_link_hash_table): Add
2104 need_global_offset_table.
2105 (elf_x86_init_table): Likewise.
2107 2018-02-08 Jim Wilson <jimw@sifive.com>
2109 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
2112 2018-02-08 Nick Clifton <nickc@redhat.com>
2115 * elf.c (elf_parse_notes): Reject notes with excessuively large
2118 2018-02-07 Alan Modra <amodra@gmail.com>
2120 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
2121 * elf32-ppc.c: Remove speculation barrier support.
2122 * elf32-ppc.h: Likewise.
2123 * elf64-ppc.c: Likewise.
2124 * elf64-ppc.h: Likewise.
2126 2018-02-06 Jim Wilson <jimw@sifive.com>
2128 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
2129 callback to report an error.
2131 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
2134 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
2135 into call to !bfd_link_executable and tidy up.
2136 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
2137 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
2138 !bfd_link_executable.
2139 <R_SPARC_TLS_IE_HI22>: Likewise.
2140 <GOT relocations>: Remove useless code, tidy and merge related blocks.
2141 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
2142 !bfd_link_executable.
2143 <R_SPARC_WPLT30>: Tidy up.
2144 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
2145 !bfd_link_executable.
2146 (allocate_dynrelocs): Likewise.
2147 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
2148 <R_SPARC_TLS_GD_HI22>: Merge into...
2149 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
2150 sparc_elf_tls_transition and remove redundant code.
2151 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
2152 !bfd_link_executable.
2153 <R_SPARC_TLS_LDO_HIX22>: Likewise.
2154 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
2155 <R_SPARC_TLS_LDM_CALL>: Likewise.
2156 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
2157 <R_SPARC_TLS_GD_ADD>: Likewise.
2158 <R_SPARC_TLS_LDM_ADD>: Likewise.
2159 <R_SPARC_TLS_LDO_ADD>: Likewise.
2160 <R_SPARC_TLS_IE_LD>: Likewise.
2162 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
2165 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
2166 functions failed to find the function name, try the generic elf
2167 find function instead.
2169 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
2171 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
2172 'memcpy' instead of 'strncpy' when writing the magic number.
2174 2018-02-06 Nick Clifton <nickc@redhat.com>
2177 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
2178 section before attempting to read it in.
2179 (bfd_get_alt_debug_link_info): Likewise.
2181 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
2183 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
2184 line information in addition to name, if they can be found.
2186 2018-02-05 Renlin Li <renlin.li@arm.com>
2189 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
2190 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
2191 check for writeable section as well.
2193 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
2196 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
2197 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
2198 undefined weak symbol to 0.
2199 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
2200 if _GLOBAL_OFFSET_TABLE_ is referenced.
2201 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
2202 got_referenced instead of ref_regular_nonweak. Remove the
2203 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
2204 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
2206 2018-02-05 Maciej W. Rozycki <macro@mips.com>
2208 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
2209 initialize `hi_reloc'.
2211 2018-02-05 Maciej W. Rozycki <macro@mips.com>
2213 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
2214 SHT_MIPS_REGINFO sections don't assert the correct size and
2215 report an error instead.
2217 2018-02-05 Maciej W. Rozycki <macro@mips.com>
2219 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
2220 status from `->elf_backend_section_processing'.
2222 2018-02-02 Jim Wilson <jimw@sifive.com>
2225 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
2226 If link_info->wrap_hash, check for a duplicate symbol and ignore.
2227 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
2228 Pass new argument to riscv_relax_delete_bytes.
2229 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
2230 ATTRIBUTE_UNUSED from link_info parameter.
2232 2018-02-02 Alan Modra <amodra@gmail.com>
2234 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
2235 emitted for toc sequence optimization. Set and use "howto" later.
2237 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
2239 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
2240 arithmetic on NULL pointer.
2241 * elflink.c (_bfd_elf_archive_symbol_lookup,
2242 elf_link_add_archive_symbols): Likewise.
2244 2018-01-31 Michael Matz <matz@suse.de>
2246 * elflink.c (bfd_elf_define_start_stop): Fix check of
2249 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
2252 * elflink.c (bfd_elf_define_start_stop): Check if __start and
2253 __stop symbols are referenced by shared objects.
2255 2018-01-30 Alan Modra <amodra@gmail.com>
2258 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
2259 segment when demand paged with lma on the same page. Test this
2260 before load/non-load, executable/non-executable,
2261 writable/non-writable tests and simplify. Delete bogus relro
2262 condition in writable/non-writable test. Delete outdated
2263 comment. Formatting.
2265 2018-01-30 Alan Modra <amodra@gmail.com>
2267 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
2270 2018-01-29 Alan Modra <amodra@gmail.com>
2273 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
2274 range before converting to a symbol table pointer.
2276 2018-01-27 Nick Clifton <nickc@redhat.com>
2278 * po/ru.po: Updated Russian translation.
2280 2018-01-26 Alan Modra <amodra@gmail.com>
2282 * elflink.c (bfd_elf_define_start_stop): Override symbols when
2283 they are defined dynamically.
2285 2018-01-26 Alan Modra <amodra@gmail.com>
2287 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
2288 .branch_lt changes size.
2290 2018-01-25 Alan Modra <amodra@gmail.com>
2293 * elfcode.h (elf_object_p): Avoid integer overflow.
2295 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
2298 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2299 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
2302 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
2305 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
2306 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
2307 bfd_link_executable for TLS check.
2308 (_bfd_sparc_elf_check_relocs): Likewise.
2309 (allocate_dynrelocs): Likewise.
2310 (_bfd_sparc_elf_relocate_section): Likewise.
2312 2018-01-24 Renlin Li <renlin.li@arm.com>
2314 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
2315 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
2316 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
2317 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
2318 BFD_RELOC_AARCH64_MOVW_PREL_G3.
2319 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
2320 (_bfd_aarch64_elf_resolve_relocation): Likewise.
2322 2018-01-24 Renlin Li <renlin.li@arm.com>
2324 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
2325 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
2326 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
2327 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
2328 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
2329 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
2330 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
2331 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
2332 BFD_RELOC_AARCH64_MOVW_PREL_G3.
2333 * bfd-in2.h: Regenerate.
2334 * libbfd.h: Regenerate.
2336 2018-01-23 Maciej W. Rozycki <macro@mips.com>
2338 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
2339 `mips_elf32_section_processing' comment reference.
2341 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
2344 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
2345 versioned __tls_get_addr symbol.
2347 2018-01-19 Nick Clifton <nickc@redhat.com>
2349 * po/fr.po: Updated French translation.
2351 2018-01-18 Alan Modra <amodra@gmail.com>
2353 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
2354 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
2355 (ppc64_elf_build_stubs): Likewise.
2357 2018-01-17 Nick Clifton <nickc@redhat.com>
2359 * po/ru.po: Updated Russian translation.
2360 * po/uk/po: Updated Ukranian translation.
2362 2018-01-17 Alan Modra <amodra@gmail.com>
2364 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
2366 2018-01-17 Alan Modra <amodra@gmail.com>
2368 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
2369 (CRSETEQ, BEQCTRM): Define.
2370 (is_nonpic_glink_stub): Don't check bctr.
2371 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
2372 (ppc_elf_relax_section): Size speculation barrier.
2373 (output_bctr): New function.
2374 (write_glink_stub): Use output_bctr.
2375 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
2376 (ppc_elf_finish_dynamic_symbol): Likewise.
2377 (ppc_elf_finish_dynamic_sections): Use output_bctr.
2378 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
2379 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
2380 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
2381 (size_global_entry_stubs): Handle speculation barrier sizing.
2382 (plt_stub_size): Likewise.
2383 (output_bctr): New function.
2384 (build_plt_stub, build_tls_get_addr_stub): Output speculation
2386 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
2387 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
2388 (build_global_entry_stubs): Output speculation barrier.
2389 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
2390 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
2392 2018-01-17 Alan Modra <amodra@gmail.com>
2394 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
2395 __tls_get_addr_opt, and alignment sizing.
2396 (TLS_GET_ADDR_GLINK_SIZE): Delete.
2397 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
2398 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
2400 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
2401 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
2402 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
2404 (write_glink_stub): Handle __tls_get_addr_opt stub.
2405 Pad out to size given by GLINK_ENTRY_SIZE.
2406 (ppc_elf_relocate_section): Adjust write_glink_stub call.
2407 (ppc_elf_finish_dynamic_symbol): Likewise.
2408 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
2409 insn array since so many need rewriting.
2410 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
2411 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
2412 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
2413 nops. Adjust all uses.
2414 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
2415 in glink_vma calculation.
2416 (struct ppc_link_hash_table): Add global_entry section pointer.
2417 (create_linkage_sections): Create separate section for global
2419 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
2420 (size_global_entry_stubs): Handle sizing for aligned stubs.
2421 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
2422 and don't stash end of glink branch table in rawsize.
2423 (ppc_build_one_stub): Rewrite stub size calculations.
2424 (build_global_entry_stubs): Use new section.
2425 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
2426 Build lazy link stubs out to end of section. Build global entry
2427 stubs in new section.
2429 2018-01-15 Nick Clifton <nickc@redhat.com>
2431 * po/uk.po: Updated Ukranian translation.
2433 2018-01-13 Nick Clifton <nickc@redhat.com>
2435 * po/bfd.pot: Regenerated.
2437 2018-01-13 Nick Clifton <nickc@redhat.com>
2439 * version.m4: Bump version to 2.30.51
2440 * configure: Regenerate.
2442 2018-01-13 Nick Clifton <nickc@redhat.com>
2444 2.30 branch created.
2446 2018-01-12 Jens Widell <jl@opera.com>
2448 * elf.c (setup_group): Optimize search for group by remembering
2449 last found group and restarting search at that index.
2450 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
2452 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
2454 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
2455 bfd_link_common_skip_none in switch.
2457 2018-01-12 Alan Modra <amodra@gmail.com>
2460 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
2461 references on forced local symbols.
2463 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
2465 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2466 .reginfo section has wrong size.
2468 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2471 * elf.c (_bfd_elf_map_sections_to_segments): When generating
2472 separate code and read-only data LOAD segments, create a new
2473 LOAD segment if the previous section contains text and the
2474 current section doesn't or vice versa. Don't put a writable
2475 section in a read-only segment if there is a RELRO segment.
2477 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2480 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
2481 references on forced local symbols.
2483 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2486 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
2487 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
2489 2018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2492 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
2494 2018-01-03 John Baldwin <jhb@FreeBSD.org>
2496 * elf.c (elfcore_grok_freebsd_note): Handle
2497 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
2498 NT_FREEBSD_PROCSTAT_VMMAP.
2500 2018-01-03 Alan Modra <amodra@gmail.com>
2502 Update year range in copyright notice of all files.
2504 For older changes see ChangeLog-2017
2506 Copyright (C) 2018 Free Software Foundation, Inc.
2508 Copying and distribution of this file, with or without modification,
2509 are permitted in any medium without royalty provided the copyright
2510 notice and this notice are preserved.
2516 version-control: never