Generic ELF target group signature symbol
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2019-05-27 Alan Modra <amodra@gmail.com>
2
3 PR 24596
4 * linker.c (_bfd_generic_link_output_symbols): Heed BSF_KEEP.
5
6 2019-05-24 Szabolcs Nagy <szabolcs.nagy@arm.com>
7
8 * elfnn-aarch64.c (elfNN_aarch64_merge_symbol_attribute): New function.
9 (struct elf_aarch64_link_hash_table): Add variant_pcs member.
10 (elfNN_aarch64_allocate_dynrelocs): Update variant_pcs.
11 (elfNN_aarch64_size_dynamic_sections): Add DT_AARCH64_VARIANT_PCS.
12 (elf_backend_merge_symbol_attribute): Define.
13
14 2019-05-24 Alan Modra <amodra@gmail.com>
15
16 * po/SRC-POTFILES.in: Regenerate.
17
18 2019-05-24 Alan Modra <amodra@gmail.com>
19
20 * elf64-ppc.c: Comment on powerxx _notoc stub variants.
21 (LI_R11_0, LIS_R11, ORI_R11_R11_0, SLDI_R11_R11_34): Define.
22 (PADDI_R12_PC, PLD_R12_PC, D34, HA34): Define.
23 (struct ppc_link_hash_table): Add powerxx_stubs.
24 (ppc64_elf_check_relocs): Set powerxx_stubs.
25 (build_powerxx_offset, size_powerxx_offset),
26 (num_relocs_for_powerxx_offset),
27 (emit_relocs_for_powerxx_offset): New functions.
28 (plt_stub_size): Size powerxx stubs.
29 (ppc_build_one_stub): Emit powerxx stubs.
30 (ppc_size_one_stub): Size powerxx stubs. Omit .eh_frame for
31 powerxx stubs.
32
33 2019-05-24 Alan Modra <amodra@gmail.com>
34
35 * elf64-ppc.c (ppc64_elf_check_relocs): Set has_gotrel for
36 R_PPC64_GOT_PCREL34.
37 (xlate_pcrel_opt): New function.
38 (ppc64_elf_edit_toc): Handle R_PPC64_GOT_PCREL34.
39 (ppc64_elf_relocate_section): Edit GOT indirect to GOT relative
40 for R_PPC64_GOT_PCREL34. Implement R_PPC64_PCREL_OPT optimisation.
41
42 2019-05-24 Alan Modra <amodra@gmail.com>
43
44 * reloc.c (BFD_RELOC_PPC64_D34, BFD_RELOC_PPC64_D34_LO),
45 (BFD_RELOC_PPC64_D34_HI30, BFD_RELOC_PPC64_D34_HA30),
46 (BFD_RELOC_PPC64_PCREL34, BFD_RELOC_PPC64_GOT_PCREL34),
47 (BFD_RELOC_PPC64_PLT_PCREL34),
48 (BFD_RELOC_PPC64_ADDR16_HIGHER34, BFD_RELOC_PPC64_ADDR16_HIGHERA34),
49 (BFD_RELOC_PPC64_ADDR16_HIGHEST34, BFD_RELOC_PPC64_ADDR16_HIGHESTA34),
50 (BFD_RELOC_PPC64_REL16_HIGHER34, BFD_RELOC_PPC64_REL16_HIGHERA34),
51 (BFD_RELOC_PPC64_REL16_HIGHEST34, BFD_RELOC_PPC64_REL16_HIGHESTA34),
52 (BFD_RELOC_PPC64_D28, BFD_RELOC_PPC64_PCREL28): New reloc enums.
53 * elf64-ppc.c (PNOP): Define.
54 (ppc64_elf_howto_raw): Add reloc howtos for new relocations.
55 (ppc64_elf_reloc_type_lookup): Translate new bfd reloc numbers.
56 (ppc64_elf_ha_reloc): Adjust addend for highera34 and highesta34
57 relocs.
58 (ppc64_elf_prefix_reloc): New function.
59 (struct ppc_link_hash_table): Add notoc_plt.
60 (is_branch_reloc): Add R_PPC64_PLTCALL_NOTOC.
61 (is_plt_seq_reloc): Add R_PPC64_PLT_PCREL34,
62 R_PPC64_PLT_PCREL34_NOTOC, and R_PPC64_PLTSEQ_NOTOC.
63 (ppc64_elf_check_relocs): Handle pcrel got and plt relocs. Set
64 has_pltcall for section on seeing R_PPC64_PLTCALL_NOTOC. Handle
65 possible need for dynamic relocs on non-pcrel powerxx relocs.
66 (dec_dynrel_count): Handle non-pcrel powerxx relocs.
67 (ppc64_elf_inline_plt): Handle R_PPC64_PLTCALL_NOTOC.
68 (toc_adjusting_stub_needed): Likewise.
69 (ppc64_elf_tls_optimize): Handle R_PPC64_PLTSEQ_NOTOC.
70 (ppc64_elf_relocate_section): Handle new powerxx relocs.
71 * bfd-in2.h: Regenerate.
72 * libbfd.h: Regenerate.
73
74 2019-05-23 Jose E. Marchesi <jose.marchesi@oracle.com>
75
76 * config.bfd (targ_cpu): Process bpf-*-none only if BFD64.
77 * configure.ac: Set target_size=64 for bpf_elf64_le_vec and
78 bpf_elf64_be_vec.
79 * configure: Regenerate.
80
81 2019-05-23 Jose E. Marchesi <jose.marchesi@oracle.com>
82
83 * configure: Regenerated.
84 * Makefile.am (ALL_MACHINES): Add cpu-bpf.lo.
85 (ALL_MACHINES_CFILES): Add cpu-bpf.c.
86 (BFD64_BACKENDS): Add elf64-bpf.lo.
87 (BFD64_BACKENDS_CFILES): Add elf64-bpf.c.
88 * Makefile.in (SOURCE_HFILES): Regenerate.
89 * config.bfd (targ_cpu): Handle bpf-*-* targets.
90 * cpu-bpf.c: New file.
91 * elf64-bpf.c: Likewise.
92 * targets.c (_bfd_target_vector): Add bpf_elf64_be_vec and
93 bpf_elf64_le_vec.
94 * archures.c: Define architecture bfd_arch_bpf and machine
95 bfd_arch_bpf.
96 * reloc.c: Define BFD relocations used by the BPF target.
97 * bfd-in2.h: Regenerated.
98 * libbfd.h: Likewise.
99
100 2019-05-22 Alan Modra <amodra@gmail.com>
101
102 * elf32-arm.c (arm_allocate_glue_section_space): Clear section
103 contents.
104
105 2019-05-22 Alan Modra <amodra@gmail.com>
106
107 * vms-alpha.c (_bfd_vms_write_etir): Don't attempt further
108 processing on "size error in section".
109
110 2019-05-22 Alan Modra <amodra@gmail.com>
111
112 * som.c (som_bfd_free_cached_info): Call
113 _bfd_generic_close_and_cleanup.
114
115 2019-05-21 Faraz Shahbazker <fshahbazker@wavecomp.com>
116
117 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Generate error
118 for TLS_TPREL_HI16(/LO16) relocations in shared library.
119
120 2019-05-21 Faraz Shahbazker <fshahbazker@wavecomp.com>
121
122 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Add NULL pointer
123 checks. Search the RELA table for n64 relocations.
124
125 2019-05-21 Matthew Fortune <matthew.fortune@mips.com>
126 Faraz Shahbazker <fshahbazker@wavecomp.com>
127
128 * elfxx-mips.c (LA25_BC): New macro.
129 (mips_elf_link_hash_table)<compact_branches>: New field.
130 (STUB_JALRC): New macro.
131 (mipsr6_o32_exec_plt0_entry_compact): New array.
132 (mipsr6_n32_exec_plt0_entry_compact): Likewise.
133 (mipsr6_n64_exec_plt0_entry_compact): Likewise.
134 (mipsr6_exec_plt_entry_compact): Likewise.
135 (mips_elf_create_la25_stub): Use BC instead of J for stubs
136 when compact_branches is true.
137 (_bfd_mips_elf_finish_dynamic_symbol): Choose the compact
138 PLT for MIPSR6 with compact_branches. Do not reorder the
139 compact branches PLT. Switch the lazy stub for MIPSR6
140 with compact_branches to use JALRC.
141 (mips_finish_exec_plt): Choose the compact PLT0 for MIPSR6
142 when compact_branches is true.
143 (_bfd_mips_elf_compact_branches): New function.
144 * elfxx-mips.h (_bfd_mips_elf_compact_branches): New prototype.
145
146 2019-05-21 Tamar Christina <tamar.christina@arm.com>
147
148 PR ld/24373
149 * elfnn-aarch64.c (_bfd_aarch64_erratum_843419_branch_to_stub):
150 Fix print formatter.
151
152 2019-05-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
153
154 PR 24460
155 * elf32-arm.c (get_value_helper): Remove.
156 (elf32_arm_final_link_relocate): Fix branch future relocations.
157
158 2019-05-21 Tamar Christina <tamar.christina@arm.com>
159
160 PR ld/24373
161 * bfd-in.h (enum erratum_84319_opts): New
162 (bfd_elf64_aarch64_set_options, bfd_elf32_aarch64_set_options): Change
163 int to enum erratum_84319_opts.
164 * bfd-in2.h: Regenerate.
165 * elfnn-aarch64.c (struct elf_aarch64_link_hash_table): Change
166 fix_erratum_843419 to use new enum, remove fix_erratum_843419_adr.
167 (_bfd_aarch64_add_stub_entry_after): Conditionally create erratum stub.
168 (aarch64_size_one_stub): Conditionally size erratum 843419 stubs.
169 (_bfd_aarch64_resize_stubs): Amend comment.
170 (elfNN_aarch64_size_stubs): Don't generate stubs when no workaround
171 requested.
172 (bfd_elfNN_aarch64_set_options): Use new fix_erratum_843419 enum.
173 (_bfd_aarch64_erratum_843419_branch_to_stub): Implement selection of
174 erratum workaround.
175 (clear_erratum_843419_entry): Update erratum conditional.
176
177 2019-05-21 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
178
179 PR ld/24571
180 * bfd/elf32-avr.c (elf32_avr_relax_section): Adjust range check
181 when computing distance_short_enough.
182
183 2019-05-21 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
184
185 PR ld/24564
186 * bfd/elf32-avr.c (avr_relative_distance_considering_wrap_around):
187 Wrap around even if distance equals avr_pc_wrap_around.
188
189 2019-05-20 Nick Clifton <nickc@redhat.com>
190
191 * po/fr.po: Updated French translation.
192
193 2019-05-16 Andre Vieira <andre.simoesdiasvieira@arm.com>
194
195 * elf32-arm.c (elf32_arm_merge_eabi_attributes): Add case for Tag_MVE_arch.
196
197 2019-05-16 Alan Modra <amodra@gmail.com>
198
199 * elf32-arm.c (elf32_arm_write_section): Revert last change.
200
201 2019-05-15 Alan Modra <amodra@gmail.com>
202
203 * elf32-arm.c (elf32_arm_write_section): Don't leave
204 error case of STM32L4XX_ERRATUM_BRANCH_TO_VENEER with
205 unitialised section contents.
206
207 2019-05-14 Jamey Hicks <jamey.hicks@gmail.com>
208
209 PR 19921
210 * verilog.c: (VerilogDataWidth): New variable.
211 (verilog_write_record): Emit bytes in VerilogDataWidth bundles.
212
213 2019-05-08 Nick Clifton <nickc@redhat.com>
214
215 PR 24523
216 * elf32-m68k.c (elf32_m68k_merge_private_bfd_data): Return TRUE
217 rather than FALSE if encountering a non-ELF file.
218
219 2019-05-06 Alan Modra <amodra@gmail.com>
220
221 * elf32-pj.c (pj_elf_reloc): Don't report undefined weak as an error.
222
223 2019-05-06 Alan Modra <amodra@gmail.com>
224
225 * reloc.c (BFD_RELOC_PPC64_TPREL16_HIGH, BFD_RELOC_PPC64_TPREL16_HIGHA),
226 (BFD_RELOC_PPC64_DTPREL16_HIGH, BFD_RELOC_PPC64_DTPREL16_HIGHA):
227 Sort before BFD_RELOC_PPC64_DTPREL16_HIGHESTA entry.
228 * libbfd.h: Regenerate.
229 * bfd-in2.h: Regenerate.
230
231 2019-05-04 Alan Modra <amodra@gmail.com>
232
233 PR 24511
234 * syms.c (coff_section_type): Only allow '.', '$' and numeric
235 following the standard section names.
236 (bfd_decode_symclass): Prioritize section flag tests in
237 decode_section_type before name tests in coff_section_type.
238 * plugin.c (bfd_plugin_canonicalize_symtab): Init fake_section
239 and fake_common_section using BFD_FAKE_SECTION. Use "fake" as
240 their names and choose standard .text section flags for
241 fake_section.
242
243 2019-05-02 Nick Clifton <nickc@redhat.com>
244
245 PR 24493
246 * coffcode.h (styp_to_sec_flags): Treat .gnu.debuglink and
247 .gnu.debugaltlink sections as debugging sections.
248
249 2019-04-30 Alan Modra <amodra@gmail.com>
250
251 * elf64-ppc.c (struct ppc64_elf_obj_tdata): Add has_gotrel.
252 (struct _ppc64_elf_section_data): Likewise.
253 (ppc64_elf_check_relocs): Set above fields.
254 (ppc64_elf_edit_toc): Add a pass over GOT relocs.
255 (ppc64_elf_relocate_section): Edit GOT indirect to GOT relative
256 when possible.
257
258 2019-04-26 H.J. Lu <hongjiu.lu@intel.com>
259
260 PR ld/24486
261 * elflink.c (elf_link_output_extsym): Don't complain undefined
262 weak dynamic reference.
263
264 2019-04-25 Sudakshina Das <sudi.das@arm.com>
265
266 * elfnn-aarch64.c (PLT_BTI_ENTRY_SIZE): Remove.
267 (PLT_BTI_TLSDESC_ENTRY_SIZE): Remove.
268 (PLT_PAC_ENTRY_SIZE, PLT_BTI_PAC_ENTRY_SIZE): Remove.
269 (PLT_BTI_SMALL_ENTRY_SIZE, PLT_PAC_SMALL_ENTRY_SIZE): Update.
270 (elfNN_aarch64_small_plt0_pac_entry): Remove.
271 (elfNN_aarch64_small_plt0_bti_pac_entry): Remove.
272 (elfNN_aarch64_small_plt0_bti_entry): Update.
273 (elfNN_aarch64_small_plt_bti_entry): Update.
274 (elfNN_aarch64_small_plt_pac_entry): Update.
275 (elfNN_aarch64_tlsdesc_small_plt_bti_entry): Update.
276 (setup_plt_values): Setup new entries.
277 (elfNN_aarch64_finish_dynamic_sections): Remove size change.
278 (elfNN_aarch64_plt_sym_val): Likewise.
279
280 2019-04-22 Jim Wilson <jimw@sifive.com>
281
282 * elfnn-riscv.c (PRSTATUS_SIZE) [ARCH_SIZE==32]: Change from 0 to 204.
283
284 2019-04-19 Alan Modra <amodra@gmail.com>
285
286 * elf32-s12z.c (elf_backend_can_gc_sections): Don't define
287
288 2019-04-17 H.J. Lu <hongjiu.lu@intel.com>
289
290 * elf64-x86-64.c (elf_x86_64_need_pic): Suggest -fPIE when not
291 building shared object.
292 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Likewise.
293
294 2019-04-17 H.J. Lu <hongjiu.lu@intel.com>
295
296 PR ld/24458
297 * elfxx-x86.h (SYMBOL_DEFINED_NON_SHARED_P): Also check x86
298 linker_def.
299
300 2019-04-15 Thomas Preud'homme <thomas.preudhomme@arm.com>
301
302 * reloc.c (BFD_RELOC_ARM_T32_VLDR_VSTR_OFF_IMM): New internal
303 relocation.
304 * bfd-in2.h: Regenerate.
305 * libbfd.h: Likewise.
306
307 2019-04-15 Sudakshina Das <sudi.das@arm.com>
308
309 * reloc.c (BFD_RELOC_ARM_THUMB_LOOP12): New.
310 * bfd-in2.h: Regenerated.
311 * libbfd.h: Regenerated.
312
313 2019-04-15 Sudakshina Das <sudi.das@arm.com>
314
315 * reloc.c (BFD_RELOC_THUMB_PCREL_BFCSEL): New relocation.
316 * bfd-in2.h: Regenerated.
317 * libbfd.h: Likewise.
318
319 2019-04-15 Sudakshina Das <sudi.das@arm.com>
320
321 * reloc.c (BFD_RELOC_ARM_THUMB_BF13): New.
322 * bfd-in2.h: Regenerated.
323 * libbfd.h: Regenerated.
324 * elf32-arm.c (elf32_arm_howto_table_1): New entry for R_ARM_THM_BF13.
325 (elf32_arm_reloc_map elf32_arm_reloc_map): Map BFD_RELOC_ARM_THUMB_BF13
326 and R_ARM_THM_BF12 together.
327 (elf32_arm_final_link_relocate): New switch case for R_ARM_THM_BF13.
328
329 2019-04-15 Sudakshina Das <sudi.das@arm.com>
330
331 * reloc.c (BFD_RELOC_ARM_THUMB_BF19): New
332 * libbfd.h: Regenerated.
333 * bfd-in2.h: Regenerated.
334 * bfd-elf32-arm.c (elf32_arm_howto_table_1): New entry for R_ARM_THM_BF18.
335 (elf32_arm_reloc_map elf32_arm_reloc_map): Map BFD_RELOC_ARM_THUMB_BF19
336 and R_ARM_THM_BF18 together.
337 (elf32_arm_final_link_relocate): New switch case for R_ARM_THM_BF19.
338
339 2019-04-15 Sudakshina Das <sudi.das@arm.com>
340
341 * reloc.c (BFD_RELOC_ARM_THUMB_BF17): New enum.
342 * bfd-in2.h: Regenerated.
343 * libbfd.h: Regenerated.
344 * bfd-elf32-arm.c (elf32_arm_howto_table_1): New entry for R_ARM_THM_BF16.
345 (elf32_arm_reloc_map elf32_arm_reloc_map): Map BFD_RELOC_ARM_THUMB_BF17
346 and R_ARM_THM_BF16 together.
347 (get_value_helper): New reloc helper.
348 (elf32_arm_final_link_relocate): New switch case for R_ARM_THM_BF16.
349
350 2019-04-15 Sudakshina Das <sudi.das@arm.com>
351
352 * reloc.c (BFD_RELOC_THUMB_PCREL_BRANCH5): New enum.
353 * bfd-in2.h: Regenerate.
354 * libbfd.h: Regenerate.
355
356 2019-04-15 Thomas Preud'homme <thomas.preudhomme@arm.com>
357
358 * archures.c (bfd_mach_arm_8_1M_MAIN): Define.
359 * bfd-in2.h: Regenerate.
360 * cpu-arm.c (arch_info_struct): Add entry for Armv8.1-M Mainline.
361 * elf32-arm.c (using_thumb_only): Return true for Armv8.1-M Mainline
362 and update assert.
363 (using_thumb2): Likewise.
364 (using_thumb2_bl): Update assert.
365 (arch_has_arm_nop): Likewise.
366 (bfd_arm_get_mach_from_attributes): Add case for Armv8.1-M Mainline.
367 (tag_cpu_arch_combine): Add logic for Armv8.1-M Mainline merging.
368
369 2019-04-11 H.J. Lu <hongjiu.lu@intel.com>
370
371 * elf-linker-x86.h (elf_x86_cet_report): New.
372 (elf_linker_x86_params): Add cet_report.
373 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Report
374 missing IBT and SHSTK properties if needed.
375
376 2019-04-11 H.J. Lu <hongjiu.lu@intel.com>
377
378 PR ld/24436
379 * elf-m10300.c (mn10300_elf_check_relocs): Remove BFD_ASSERT of
380 "h != NULL". Don't check "h != NULL" before calling.
381 bfd_elf_gc_record_vtentry.
382 * elf32-arm.c (elf32_arm_check_relocs): Likewise.
383 * elf32-bfin.c (bfin_check_relocs): Likewise.
384 * elf32-cris.c (cris_elf_check_relocs): Likewise.
385 * elf32-csky.c (csky_elf_check_relocs): Likewise.
386 * elf32-d10v.c (elf32_d10v_check_relocs): Likewise.
387 * elf32-dlx.c (elf32_dlx_check_relocs): Likewise.
388 * elf32-fr30.c (fr30_elf_check_relocs): Likewise.
389 * elf32-frv.c (elf32_frv_check_relocs): Likewise.
390 * elf32-hppa.c (elf32_hppa_check_relocs): Likewise.
391 * elf32-i386.c (elf_i386_check_relocs): Likewise.
392 * elf32-iq2000.c (iq2000_elf_check_relocs): Likewise.
393 * elf32-m32r.c (m32r_elf_check_relocs): Likewise.
394 * elf32-m68hc1x.c (elf32_m68hc11_check_relocs): Likewise.
395 * elf32-m68k.c (elf_m68k_check_relocs): Likewise.
396 * elf32-mcore.c (mcore_elf_check_relocs): Likewise.
397 * elf32-metag.c (elf_metag_check_relocs): Likewise.
398 * elf32-or1k.c (or1k_elf_check_relocs): Likewise.
399 * elf32-ppc.c (ppc_elf_check_relocs): Likewise.
400 * elf32-s390.c (elf_s390_check_relocs): Likewise.
401 * elf32-sh.c (sh_elf_check_relocs): Likewise.
402 * elf32-v850.c (v850_elf_check_relocs): Likewise.
403 * elf32-vax.c (elf_vax_check_relocs): Likewise.
404 * elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise.
405 * elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
406 * elf64-mmix.c (mmix_elf_check_relocs): Likewise.
407 * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
408 * elf64-s390.c (elf_s390_check_relocs): Likewise.
409 * elf64-x86-64.c (elf_s390_check_relocs): Likewise.
410 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
411 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
412 * elflink.c (bfd_elf_gc_record_vtinherit): Check for corrupt
413 VTENTRY entry.
414
415 2019-04-11 Alan Modra <amodra@gmail.com>
416
417 PR 24435
418 * elflink.c (elf_link_add_object_symbols): Don't read partial
419 dynamic entries from fuzzed objects.
420
421 2019-04-11 Tamar Christina <tamar.christina@arm.com>
422
423 PR ld/24302
424 * elfnn-aarch64.c (elfNN_aarch64_size_dynamic_sections): Don't emit
425 DT_TLSDESC_GOT and DT_TLSDESC_PLT when DF_BIND_NOW.
426 (elfNN_aarch64_finish_dynamic_sections): Don't write PLT if DF_BIND_NOW.
427
428 2019-04-10 Michael Forney <mforney@mforney.org>
429
430 PR 24427
431 * doc/chew.c (free_words): Correctly free "push_text" strings.
432
433 2019-04-08 H.J. Lu <hongjiu.lu@intel.com>
434
435 * config.bfd: Remove i[3-7]86-*-kaos* and i[3-7]86-*-chaos targets.
436
437 2019-04-08 Alan Modra <amodra@gmail.com>
438
439 * configure.ac (elfxx_x86): Define and use.
440 * configure: Regenerate.
441
442 2019-04-06 H.J. Lu <hongjiu.lu@intel.com>
443
444 * elf-linker-x86.h: New file.
445 * elf32-i386.c (elf_i386_convert_load_reloc): Use htab->params
446 to get x86-specific linker options.
447 * elf64-x86-64.c (elf_x86_64_convert_load_reloc): Likewise.
448 (elf_x86_64_check_relocs): Likewise.
449 (elf_x86_64_relocate_section): Likewise.
450 (elf_x86_64_link_setup_gnu_properties): Likewise.
451 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Likewise.
452 (_bfd_x86_elf_link_setup_gnu_properties): Likewise.
453 (_bfd_elf_linker_x86_set_options): New function.
454 * elfxx-x86.h: Include "elf-linker-x86.h".
455 (elf_x86_link_hash_table): Add params.
456
457 2019-04-03 Alan Modra <amodra@gmail.com>
458
459 * coff-i386.c, * coff-x86_64.c, * coffgen.c, * dwarf2.c,
460 * elf-m10200.c, * elf.c, * elf32-arm.c, * elf32-bfin.c,
461 * elf32-csky.c, * elf32-m32r.c, * elf32-microblaze.c, * elf32-pru.c,
462 * elf32-rx.c, * elf32-xgate.c, * elf64-sparc.c, * elfnn-ia64.c,
463 * elfxx-riscv.c, * elfxx-sparc.c, * linker.c, * mach-o.c,
464 * pe-x86_64.c, * pei-x86_64.c, * plugin.c: Whitespace fixes.
465
466 2019-04-02 Jim Wilson <jimw@sifive.com>
467
468 PR 24389
469 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Move read of
470 ELF header flags to after check for ELF object file. Loop through
471 sections looking for code sections, if none, then skip ABI checks.
472
473 2019-03-30 Andrew Waterman <andrew@sifive.com>
474
475 * elfnn-riscv.c (_bfd_riscv_relax_call): Only check ARCH_SIZE for
476 rd == X_RA case.
477
478 2019-03-29 Max Filippov <jcmvbkbc@gmail.com>
479
480 * elf32-xtensa.c (shrink_dynamic_reloc_sections): Add
481 info->export_dynamic to the conditional.
482
483 2019-03-28 Alan Modra <amodra@gmail.com>
484
485 PR 24392
486 * configure.ac: Invoke AC_CHECK_SIZEOF(int).
487 * configure: Regenerate.
488 * coffgen.c (coff_get_reloc_upper_bound): Replace gcc diagnostic
489 workaround with SIZEOF_LONG vs. SIZEOF_INT check.
490 * elf.c (_bfd_elf_get_reloc_upper_bound): Likewise.
491 * elf64-sparc.c (elf64_sparc_get_reloc_upper_bound): Likewise.
492 * mach-o.c (bfd_mach_o_get_reloc_upper_bound): Likewise.
493
494 2019-03-21 Jim Wilson <jimw@sifive.com>
495
496 PR 24365
497 * elfnn-riscv.c (riscv_elf_relocate_section): For STT_SECTION check,
498 verify sym non-NULL before using. Add identical check using h.
499
500 2019-03-21 Sudakshina Das <sudi.das@arm.com>
501
502 * elf-bfd.h (struct elf_backend_data): Add argument to
503 merge_gnu_properties.
504 * elf-properties.c (elf_merge_gnu_properties): Add argument to
505 itself and while calling bed->merge_gnu_properties.
506 (elf_merge_gnu_property_list): Update the calls for
507 elf_merge_gnu_properties.
508 * elfnn-aarch64.c (elfNN_aarch64_merge_gnu_properties): Update handling
509 of --force-bti warning and add argument.
510 * elfxx-aarch64.c (_bfd_aarch64_elf_link_setup_gnu_properties): Add
511 warning.
512 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Add argument.
513 * elfxx-x86.h (_bfd_x86_elf_merge_gnu_properties): Likewise in
514 declaration.
515
516 2019-03-20 Sudakshina Das <sudi.das@arm.com>
517
518 * elfxx-aarch64.c (_bfd_aarch64_elf_link_fixup_gnu_properties): Define.
519 * elfxx-aarch64.h (_bfd_aarch64_elf_link_fixup_gnu_properties): Declare.
520 (elf_backend_fixup_gnu_properties): Define for AArch64.
521
522 2019-03-18 Alan Modra <amodra@gmail.com>
523
524 PR 24355
525 * elf32-ppc.c (ppc_finish_symbols): Don't call write_glink_stub
526 for local iplt syms with ent->plt.offset == -1. Remove ineffective
527 attempt at writing glink stubs only once.
528
529 2019-03-16 Alan Modra <amodra@gmail.com>
530
531 PR 24337
532 * elf.c (_bfd_elf_rela_local_sym): Revert last change.
533 (_bfd_elf_rel_local_sym): Likewise.
534 * elflink.c (elf_link_input_bfd): Use bfd_und_section for
535 section of symbols with unrecognized shndx.
536
537 2019-03-15 H.J. Lu <hongjiu.lu@intel.com>
538
539 PR ld/24267
540 * coffgen.c (_bfd_coff_section_already_linked): Skip discarded
541 section.
542 * cofflink.c (coff_link_add_symbols): Check for symbols defined
543 in discarded section.
544
545 2019-03-15 Alan Modra <amodra@gmail.com>
546
547 PR 24339
548 * elflink.c (elf_link_add_object_symbols): Bail out on a local
549 symbol after globals if elf_bad_symtab is not set.
550
551 2019-03-15 Alan Modra <amodra@gmail.com>
552
553 PR 24337
554 * elf.c (_bfd_elf_rela_local_sym): Don't segfault on NULL sec.
555 (_bfd_elf_rel_local_sym): Likewise.
556
557 2019-03-15 Alan Modra <amodra@gmail.com>
558
559 PR 24336
560 * elflink.c (elf_link_read_relocs_from_section): Handle fuzzed
561 object files with sh_size not a multiple of sh_entsize.
562
563 2019-03-15 H.J. Lu <hongjiu.lu@intel.com>
564
565 PR ld/24338
566 * elf64-x86-64.c (elf_x86_64_relocate_section): Check for corrupt
567 input with bad relocation.
568
569 22019-03-15 H.J. Lu <hongjiu.lu@intel.com>
570
571 * elf64-x86-64.c (elf_x86_64_relocate_section): Re-indent.
572
573 2019-03-14 Nick Clifton <nickc@redhat.com>
574
575 PR 24334
576 * dwarf2.c (struct dwarf2_debug): Add sec_vma_count field.
577 (save_section_vma): Initialise field to the number of entries in
578 the sec_vma table.
579 (section_vma_same): Check that the number of entries in the
580 sec_vma table matches the number of sections in the bfd.
581
582 2019-03-14 Nick Clifton <nickc@redhat.com>
583
584 PR 24333
585 * elflink.c (_bfd_elf_add_default_symbol): Add a check for a NULL
586 section owner pointer when adding the default symbol.
587
588 2019-03-14 Nick Clifton <nickc@redhat.com>
589
590 PR 24332
591 * elflink.c (elf_link_add_object_symbols): Add new local variable
592 extversym_end. Initialise it to point to the end of the version
593 symbol table, if present. Check it when initialising and updating
594 the ever pointer.
595
596 2019-03-13 Sudakshina Das <sudi.das@arm.com>
597
598 * elfnn-aarch64.c (PLT_PAC_ENTRY_SIZE, PLT_PAC_SMALL_ENTRY_SIZE): New.
599 (PLT_BTI_PAC_ENTRY_SIZE, PLT_BTI_PAC_SMALL_ENTRY_SIZE): New.
600 (setup_plt_values): Account for PAC or PAC and BTI enabled PLTs.
601 (elfNN_aarch64_size_dynamic_sections): Add checks for PLT_BTI_PAC
602 and PLT_PAC_PLT.
603 (elfNN_aarch64_finish_dynamic_sections): Account for PLT_BTI_PAC.
604 (get_plt_type): Add case for DT_AARCH64_PAC_PLT.
605 (elfNN_aarch64_plt_sym_val): Add cases for PLT_BTI_PAC and PLT_PAC.
606
607 2019-03-13 Sudakshina Das <sudi.das@arm.com>
608 Szabolcs Nagy <szabolcs.nagy@arm.com>
609
610 * bfd-in.h (aarch64_plt_type, aarch64_enable_bti_type): New.
611 (aarch64_bti_pac_info): New.
612 (bfd_elf64_aarch64_set_options): Add aarch64_bti_pac_info argument.
613 (bfd_elf32_aarch64_set_options): Likewise.
614 * bfd-in2.h: Regenerate
615 * elfnn-aarch64.c (PLT_BTI_ENTRY_SIZE): New.
616 (PLT_BTI_SMALL_ENTRY_SIZE, PLT_BTI_TLSDESC_ENTRY_SIZE): New.
617 (elfNN_aarch64_small_plt0_bti_entry): New.
618 (elfNN_aarch64_small_plt_bti_entry): New.
619 (elfNN_aarch64_tlsdesc_small_plt_bti_entry): New.
620 (elf_aarch64_obj_tdata): Add no_bti_warn and plt_type fields.
621 (elf_aarch64_link_hash_table): Add plt0_entry, plt_entry and
622 tlsdesc_plt_entry_size fields.
623 (elfNN_aarch64_link_hash_table_create): Initialise the new fields.
624 (setup_plt_values): New helper function.
625 (bfd_elfNN_aarch64_set_options): Use new bp_info to set plt sizes and
626 bti enable type.
627 (elfNN_aarch64_allocate_dynrelocs): Use new size members instead of
628 fixed macros.
629 (elfNN_aarch64_size_dynamic_sections): Likewise and add checks.
630 (elfNN_aarch64_create_small_pltn_entry): Use new generic pointers
631 to plt stubs instead of fixed ones and update filling them according
632 to the need for bti.
633 (elfNN_aarch64_init_small_plt0_entry): Likewise.
634 (elfNN_aarch64_finish_dynamic_sections): Likewise.
635 (get_plt_type, elfNN_aarch64_get_synthetic_symtab): New.
636 (elfNN_aarch64_plt_sym_val): Update size accordingly.
637 (elfNN_aarch64_link_setup_gnu_properties): Set up plts if BTI GNU NOTE
638 is set.
639 (bfd_elfNN_get_synthetic_symtab): Define.
640 (elfNN_aarch64_merge_gnu_properties): Give out warning with --force-bti
641 and mising BTI NOTE SECTION.
642
643
644 2019-03-13 Sudakshina Das <sudi.das@arm.com>
645
646 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Exclude
647 linker created inputs from merge.
648 * elfnn-aarch64.c (struct elf_aarch64_obj_tdata): Add field for
649 GNU_PROPERTY_AARCH64_FEATURE_1_AND properties.
650 (elfNN_aarch64_link_setup_gnu_properties): New.
651 (elfNN_aarch64_merge_gnu_properties): New.
652 (elf_backend_setup_gnu_properties): Define for AArch64.
653 (elf_backend_merge_gnu_properties): Likewise.
654 * elfxx-aarch64.c (_bfd_aarch64_elf_link_setup_gnu_properties): Define.
655 (_bfd_aarch64_elf_parse_gnu_properties): Define.
656 (_bfd_aarch64_elf_merge_gnu_properties): Define.
657 * elfxx-aarch64.h (_bfd_aarch64_elf_link_setup_gnu_properties): Declare.
658 (_bfd_aarch64_elf_parse_gnu_properties): Declare.
659 (_bfd_aarch64_elf_merge_gnu_properties): Declare.
660 (elf_backend_parse_gnu_properties): Define for AArch64.
661
662 2019-03-13 H.J. Lu <hongjiu.lu@intel.com>
663
664 PR ld/24322
665 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Properly
666 merge GNU_PROPERTY_X86_FEATURE_1_[IBT|SHSTK].
667
668 2019-03-12 Alan Modra <amodra@gmail.com>
669
670 * coffcode.h (buy_and_read): Delete unnecessary forward decl. Add
671 nmemb parameter. Use bfd_alloc2.
672 (coff_slurp_line_table): Use bfd_alloc2. Update buy_and_read calls.
673 Delete assertion.
674 (coff_slurp_symbol_table): Use bfd_alloc2 and bfd_zalloc2.
675 (coff_slurp_reloc_table): Use bfd_alloc2. Update buy_and_read calls.
676 * coffgen.c (coff_get_reloc_upper_bound): Ensure size calculation
677 doesn't overflow.
678 * elf.c (bfd_section_from_shdr): Use bfd_zalloc2. Style fix.
679 (assign_section_numbers): Style fix.
680 (swap_out_syms): Use bfd_malloc2.
681 (_bfd_elf_get_reloc_upper_bound): Ensure size calculation doesn't
682 overflow.
683 (_bfd_elf_make_empty_symbol): Style fix.
684 (elfobj_grok_stapsdt_note_1): Formatting.
685 * elfcode.h (elf_object_p): Use bfd_alloc2.
686 (elf_write_relocs, elf_write_shdrs_and_ehdr): Likewise.
687 (elf_slurp_symbol_table): Use bfd_zalloc2.
688 (elf_slurp_reloc_table): Use bfd_alloc2.
689 (_bfd_elf_bfd_from_remote_memory): Use bfd_malloc2.
690 * elf64-sparc (elf64_sparc_get_reloc_upper_bound): Ensure
691 size calculation doesn't overflow.
692 (elf64_sparc_get_dynamic_reloc_upper_bound): Likewise.
693 * mach-o.c (bfd_mach_o_get_reloc_upper_bound): Likewise.
694 * pdp11.c (get_reloc_upper_bound): Copy aoutx.h version.
695
696 2019-03-08 Alan Modra <amodra@gmail.com>
697
698 PR 24311
699 * merge.c (merge_strings): Return secinfo. Don't pad section
700 to alignment here.
701 (_bfd_merge_sections): Pad section to alignment here, if input
702 sections contributing to merged output all pad to alignment.
703 Formatting.
704
705 2019-03-06 Nick Clifton <nickc@redhat.com>
706
707 * dwarf2.c (_bfd_dwarf2_find_symbol_bias): Check for a NULL symbol
708 table pointer.
709 * coffgen.c (coff_find_nearest_line_with_names): Do not call
710 _bfd_dwarf2_find_symbol_bias if there is no symbol table available.
711
712 2019-03-01 Andreas Krebbel <krebbel@linux.ibm.com>
713
714 This reverts commit 5a12586d44fa8d5dfc74cbca4f2f36a273a16335.
715 2019-01-14 Maamoun Tarsha <maamountk@hotmail.com>
716
717 PR 20113
718 * elf32-s390.c (allocate_dynrelocs): Update comment.
719
720 2019-02-28 Tamar Christina <tamar.christina@arm.com>
721
722 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Correct CIE parse.
723
724 2019-02-28 Nick Clifton <nickc@redhat.com>
725
726 PR 24273
727 * elf.c (bfd_elf_string_from_elf_section): Check for a string
728 section that is not NUL terminated.
729
730 2019-02-27 H.J. Lu <hongjiu.lu@intel.com>
731
732 PR ld/24276
733 * elf64-x86-64.c (elf_x86_64_check_relocs): Skip symbol defined
734 by linker when checking copy reloc on protected symbol.
735
736 2019-02-24 Alan Modra <amodra@gmail.com>
737
738 PR 24144
739 * pdp11.c (set_section_contents): Revert 2015-02-24 change.
740
741 2019-02-20 Eric Tsai <erictsai@cadence.com>
742
743 * elf32-xtensa.c (is_resolvable_asm_expansion): Scan output
744 sections between the call site and call destination and adjust
745 call distance by the largest alignment.
746
747 2019-02-20 Alan Hayward <alan.hayward@arm.com>
748
749 * elf-bfd.h (elfcore_write_aarch_pauth): Add declaration.
750 * elf.c (elfcore_grok_aarch_pauth): New function.
751 (elfcore_grok_note): Check for NT_ARM_PAC_MASK.
752 (elfcore_write_aarch_pauth): New function.
753 (elfcore_write_register_note): Check for AArch64 pauth section.
754
755 2019-02-20 Alan Modra <amodra@gmail.com>
756
757 PR 24225
758 * elf32-nios2.c (nios2_elf32_relocate_section): Check asprintf
759 return value.
760
761 2019-02-20 Michael Roitzsch <reactorcontrol@icloud.com>
762
763 * configure.ac (SHARED_LIBADD): Add -liberty -lintl for all
764 Darwin hosts, not just or1k.
765 * configure: Regenerate.
766
767 2019-02-20 Alan Modra <amodra@gmail.com>
768
769 PR 24236
770 * archive64.c (_bfd_archive_64_bit_slurp_armap): Move code adding
771 sentinel NUL to string buffer nearer to loop where it is used.
772 Don't go past sentinel when scanning strings, and don't write
773 NUL again.
774 * archive.c (do_slurp_coff_armap): Simplify string handling to
775 archive64.c style.
776
777 2019-02-19 Alan Modra <amodra@gmail.com>
778
779 PR 24235
780 * pei-x86_64.c (pex64_bfd_print_pdata_section): Correct checks
781 attempting to prevent read past end of section.
782
783 2019-02-18 Alan Modra <amodra@gmail.com>
784
785 PR 24225
786 * elf32-nios2.c (nios2_elf32_relocate_section): Use asprintf and
787 PRIx64 to generate warning messages. Print local sym names too.
788
789 2019-02-09 Vineet Gupta <vgupta@synopsys.com>
790
791 * elf32-arc (INIT_SYM_STRING): Delete.
792 (FINI_SYM_STRING): Likewise.
793 (init_str): Likewise.
794 (fini_str): Likewise.
795
796 2019-02-08 Alan Modra <amodra@gmail.com>
797
798 * elf32-ppc.c (ppc_elf_relocate_section): Add %X to "unsupported
799 for bss-plt" warning to make it an error.
800
801 2019-02-07 Eric Botcazou <ebotcazou@adacore.com>
802
803 PR ld/18841
804 * elf32-sparc.c (elf32_sparc_reloc_type_class): Return
805 reloc_class_ifunc for ifunc symbols.
806 * elf64-sparc.c (elf64_sparc_reloc_type_class): Likewise.
807
808 2019-02-07 Eric Botcazou <ebotcazou@adacore.com>
809
810 * elf32-visium.c (visium_elf_howto_parity_reloc): Minor tweak.
811 <R_VISIUM_PC16>: Use explicit range test to detect an overflow.
812
813 2019-02-07 Nick Clifton <nickc@redhat.com>
814
815 * config.bfd: Move the powerpc-lynxos and powerpc-windiss targets
816 into the definitely obsolete list.
817
818 2019-02-05 H.J. Lu <hongjiu.lu@intel.com>
819
820 PR ld/24151
821 * elf64-x86-64.c (elf_x86_64_need_pic): Check
822 SYMBOL_DEFINED_NON_SHARED_P instead of def_regular.
823 (elf_x86_64_relocate_section): Move PIC check for PC-relative
824 relocations to ...
825 (elf_x86_64_check_relocs): Here.
826 (elf_x86_64_finish_dynamic_symbol): Use SYMBOL_DEFINED_NON_SHARED_P
827 to check if a symbol is defined in a non-shared object.
828 * elfxx-x86.h (SYMBOL_DEFINED_NON_SHARED_P): New.
829
830 2019-01-21 Sergio Durigan Junior <sergiodj@redhat.com>
831
832 * elf32-arm.c (elf32_arm_final_link_relocate): Use 'llabs' instead
833 of 'labs' (and fix GCC warning).
834
835 2019-01-25 Nick Clifton <nickc@redhat.com>
836
837 * po/ru.po: Updated Russian translation.
838
839 2019-01-23 Nick Clifton <nickc@redhat.com>
840
841 * po/fr.po: Updated French translation.
842
843 2019-01-21 Nick Clifton <nickc@redhat.com>
844
845 * po/pt.po: Updated Portuguese translation.
846 * po/uk.po: Updated Ukranian translation.
847
848 2019-01-21 Yuri Chornoivan <yurchor@ukr.net>
849
850 PR 24108
851 * elf32-nds32.c (nds32_relocate_section): Add space between words
852 in error message.
853 * elfnn-riscv.c (riscv_version_mismatch): Fix spelling mistake in
854 error message.
855 (riscv_i_or_e_p): Likewise.
856 (riscv_merge_arch_attr_info): Likewise.
857
858 2019-01-19 Nick Clifton <nickc@redhat.com>
859
860 * version.m4: Reset to 2.32.51
861 * configure: Regenerate.
862 * po/bfd.pot: Regenerate.
863
864 2018-06-24 Nick Clifton <nickc@redhat.com>
865
866 2.32 branch created.
867
868 2019-01-16 Kito Cheng <kito@andestech.com>
869
870 * elf-attrs.c (vendor_obj_attr_size): Return 0 if size is 0 even
871 for OBJ_ATTR_PROC.
872
873 2019-01-16 Kito Cheng <kito@andestech.com>
874 Nelson Chu <nelson@andestech.com>
875
876 * elfnn-riscv.c (in_subsets): New.
877 (out_subsets): Likewise.
878 (merged_subsets): Likewise.
879 (riscv_std_ext_p): Likewise.
880 (riscv_non_std_ext_p): Likewise.
881 (riscv_std_sv_ext_p): Likewise.
882 (riscv_non_std_sv_ext_p): Likewise.
883 (riscv_version_mismatch): Likewise.
884 (riscv_i_or_e_p): Likewise.
885 (riscv_merge_std_ext): Likewise.
886 (riscv_merge_non_std_and_sv_ext): Likewise.
887 (riscv_merge_arch_attr_info): Likewise.
888 (riscv_merge_attributes): Likewise.
889 (_bfd_riscv_elf_merge_private_bfd_data): Merge attribute.
890
891 * elfnn-riscv.c (riscv_elf_obj_attrs_arg_type): New.
892 (elf_backend_obj_attrs_vendor): Define.
893 (elf_backend_obj_attrs_section_type): Likewise.
894 (elf_backend_obj_attrs_section): Likewise.
895 (elf_backend_obj_attrs_arg_type): Define as
896 riscv_elf_obj_attrs_arg_type.
897 * elfxx-riscv.c (riscv_estimate_digit): New.
898 (riscv_estimate_arch_strlen1): Likewise.
899 (riscv_estimate_arch_strlen): Likewise.
900 (riscv_arch_str1): Likewise.
901 (riscv_arch_str): Likewise.
902 * elfxx-riscv.h (riscv_arch_str): Declare.
903
904 2019-01-14 John Darrington <john@darrington.wattle.id.au>
905
906 * bfd-in2.h [BFD_RELOC_S12Z_OPR]: New reloc.
907 * libbfd.h: regen.
908 * elf32-s12z.c (eld_s12z_howto_table): R_S12Z_OPR takes non zero
909 source field. (md_apply_fix): Apply final fix
910 to BFD_RELOC_S12Z_OPR.
911 * reloc.c[BFD_RELOC_S12Z_OPR]: New reloc.
912
913 2019-01-14 Maamoun Tarsha <maamountk@hotmail.com>
914
915 PR 20113
916 * elf32-s390.c (allocate_dynrelocs): Update comment.
917
918 2019-01-09 Andrew Paprocki <andrew@ishiboo.com>
919
920 * warning.m4: Adjust egrep pattern for non-GNU compilers.
921 * configure: Regenerate.
922
923 2019-01-08 Alan Modra <amodra@gmail.com>
924
925 PR 23699
926 PR 24065
927 * ihex.c (ihex_write_object_contents): Properly check 32-bit
928 address range.
929
930 2019-01-05 Yoshinori Sato <ysato@users.sourceforge.jp>
931
932 * bfd/archures.c: Add bfd_mach_rx_v2 and bfd_mach_rx_v3.
933 * bfd/bfd-in2.h: Regenerate.
934 * bfd/cpu-rx.c (arch_info_struct): Add RXv2 and RXv3 entry.
935 * bfd/elf32-rx.c (elf32_rx_machine): Add RXv2 and RXv3 support.
936
937 2019-01-04 Lifang Xia <lifang_xia@c-sky.com>
938
939 * config.bfd (csky-*-elf* | csky-*-linux*): Modify the csky
940 default target, little endian target is more suitable.
941
942 2019-01-04 Alan Modra <amodra@gmail.com>
943
944 PR 24061
945 PR 21786
946 * coff-rs6000.c (GET_VALUE_IN_FIELD): Add base parameter and
947 adjust all callers.
948 (EQ_VALUE_IN_FIELD): Likewise.
949 * coff64-rs6000.c (GET_VALUE_IN_FIELD): Likewise.
950
951 2019-01-01 Alan Modra <amodra@gmail.com>
952
953 Update year range in copyright notice of all files.
954
955 For older changes see ChangeLog-2018
956 \f
957 Copyright (C) 2019 Free Software Foundation, Inc.
958
959 Copying and distribution of this file, with or without modification,
960 are permitted in any medium without royalty provided the copyright
961 notice and this notice are preserved.
962
963 Local Variables:
964 mode: change-log
965 left-margin: 8
966 fill-column: 74
967 version-control: never
968 End:
This page took 0.046944 seconds and 5 git commands to generate.