1 2017-05-19 Alan Modra <amodra@gmail.com>
3 * elflink.c (_bfd_elf_gc_mark_extra_sections): Don't keep
4 debug and special sections when no non-note alloc sections in an
7 2017-05-18 Alan Modra <amodra@gmail.com>
9 * arc-got.h: Don't compare boolean values against TRUE or FALSE.
10 * elf-m10300.c: Likewise.
12 * elf32-arc.c: Likewise.
13 * elf32-bfin.c: Likewise.
14 * elf32-m68k.c: Likewise.
15 * elf32-nds32.c: Likewise.
16 * elf32-tilepro.c: Likewise.
17 * elflink.c: Likewise.
18 * elfnn-aarch64.c: Likewise.
19 * elfnn-riscv.c: Likewise.
20 * elfxx-tilegx.c: Likewise.
22 * peXXigen.c: Likewise.
23 * vms-alpha.c: Likewise.
24 * vms-lib.c: Likewise.
26 2017-05-17 H.J. Lu <hongjiu.lu@intel.com>
29 * elflink.c (elf_gc_mark_debug_section): New function.
30 (_bfd_elf_gc_mark_extra_sections): Mark any debug sections
31 referenced by kept debug sections.
33 2017-05-16 Alan Modra <amodra@gmail.com>
35 * elf-m10300.c: Rename occurrences of non_ir_ref.
36 * elf32-arm.c: Likewise.
37 * elf32-bfin.c: Likewise.
38 * elf32-cr16.c: Likewise.
39 * elf32-cris.c: Likewise.
40 * elf32-d10v.c: Likewise.
41 * elf32-dlx.c: Likewise.
42 * elf32-fr30.c: Likewise.
43 * elf32-frv.c: Likewise.
44 * elf32-hppa.c: Likewise.
45 * elf32-i370.c: Likewise.
46 * elf32-i386.c: Likewise.
47 * elf32-iq2000.c: Likewise.
48 * elf32-lm32.c: Likewise.
49 * elf32-m32c.c: Likewise.
50 * elf32-m32r.c: Likewise.
51 * elf32-m68hc1x.c: Likewise.
52 * elf32-m68k.c: Likewise.
53 * elf32-mcore.c: Likewise.
54 * elf32-metag.c: Likewise.
55 * elf32-microblaze.c: Likewise.
56 * elf32-moxie.c: Likewise.
57 * elf32-msp430.c: Likewise.
58 * elf32-mt.c: Likewise.
59 * elf32-nios2.c: Likewise.
60 * elf32-or1k.c: Likewise.
61 * elf32-ppc.c: Likewise.
62 * elf32-rl78.c: Likewise.
63 * elf32-s390.c: Likewise.
64 * elf32-score.c: Likewise.
65 * elf32-score7.c: Likewise.
66 * elf32-sh.c: Likewise.
67 * elf32-tic6x.c: Likewise.
68 * elf32-tilepro.c: Likewise.
69 * elf32-v850.c: Likewise.
70 * elf32-vax.c: Likewise.
71 * elf32-xstormy16.c: Likewise.
72 * elf32-xtensa.c: Likewise.
73 * elf64-alpha.c: Likewise.
74 * elf64-hppa.c: Likewise.
75 * elf64-ia64-vms.c: Likewise.
76 * elf64-mmix.c: Likewise.
77 * elf64-ppc.c: Likewise.
78 * elf64-s390.c: Likewise.
79 * elf64-sh64.c: Likewise.
80 * elf64-x86-64.c: Likewise.
81 * elflink.c: Likewise.
82 * elfnn-aarch64.c: Likewise.
83 * elfnn-ia64.c: Likewise.
84 * elfnn-riscv.c: Likewise.
85 * elfxx-mips.c: Likewise.
86 * elfxx-sparc.c: Likewise.
87 * elfxx-tilegx.c: Likewise.
90 2017-05-16 Alan Modra <amodra@gmail.com>
92 * elf64-ppc.c (add_symbol_adjust): Transfer non_ir_ref_dynamic.
93 * elflink.c (elf_link_add_object_symbols): Update to use
95 (elf_link_input_bfd): Test non_ir_ref_dynamic in addition to
97 * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
99 2017-05-15 Maciej W. Rozycki <macro@imgtec.com>
101 * elfxx-mips.c (print_mips_ases): Handle MIPS16e2 ASE.
103 2017-05-12 H.J. Lu <hongjiu.lu@intel.com>
105 * elf32-i386.c (elf_i386_parse_gnu_properties): Merge
106 GNU_PROPERTY_X86_ISA_1_USED and GNU_PROPERTY_X86_ISA_1_NEEDED
108 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
110 2017-05-11 H.J. Lu <hongjiu.lu@intel.com>
112 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Rename plt_bnd
114 (elf_x86_64_link_hash_table): Rename plt_bnd/plt_bnd_eh_frame
115 to plt_second/plt_second_eh_frame.
116 (elf_x86_64_link_hash_newfunc): Updated.
117 (elf_x86_64_allocate_dynrelocs): Likewise.
118 (elf_x86_64_size_dynamic_sections): Likewise.
119 (elf_x86_64_relocate_section): Likewise.
120 (elf_x86_64_finish_dynamic_symbol): Likewise.
121 (elf_x86_64_finish_dynamic_sections): Likewise.
122 (elf_x86_64_plt_type): Rename plt_bnd to plt_second.
123 (elf_x86_64_get_synthetic_symtab): Updated. Also scan the
125 (elf_backend_setup_gnu_properties): Updated. Create the
126 .plt.sec section instead of the .plt.sec section.
128 2017-05-11 H.J. Lu <hongjiu.lu@intel.com>
130 * elf32-i386.c (elf_i386_allocate_dynrelocs): Partially revert
131 commit 25070364b0ce33eed46aa5d78ebebbec6accec7e.
132 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewse.
134 2017-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
136 * elf64-sparc.c (elf64_sparc_set_reloc): New function.
137 (bfd_elf64_set_reloc): Define.
138 (elf64_sparc_write_relocs): Use `canon_reloc_count'.
140 2017-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
142 * targets.c (BFD_JUMP_TABLE_RELOCS): Add NAME##_set_reloc.
143 (struct bfd_target): New field _bfd_set_reloc.
144 * bfd.c (bfd_set_reloc): Call backend _set_bfd.
145 * reloc.c (_bfd_generic_set_reloc): New function.
146 * coffcode.h (coff_set_reloc): Define to _bfd_generic_set_reloc.
147 * nlm-target.h (nlm_set_reloc): Likewise.
148 * coff-rs6000.c (_bfd_xcoff_set_reloc): Likewise.
149 * aout-tic30.c (MY_set_reloc): Likewise.
150 * aout-target.h (MY_set_reloc): Likewise.
151 * elfxx-target.h (bfd_elfNN_set_reloc): Likewise.
152 * coff-alpha.c (_bfd_ecoff_set_reloc): Likewise.
153 * mach-o-target.c (bfd_mach_o_set_reloc): Likewise.
154 * vms-alpha.c (alpha_vms_set_reloc): Likewise.
155 * aout-adobe.c (aout_32_set_reloc): Likewise.
156 * bout.c (b_out_set_reloc): Likewise.
157 * coff-mips.c (_bfd_ecoff_set_reloc): Likewise.
158 * i386os9k.c (aout_32_set_reloc): Likewise.
159 * ieee.c (ieee_set_reloc): Likewise.
160 * oasys.c (oasys_set_reloc): Likewise.
161 * som.c (som_set_reloc): Likewise.
162 * versados.c (versados_set_reloc): Likewise.
163 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
164 _bfd_generic_set_reloc.
165 (rs6000_xcoff64_aix_vec): LIkewise.
166 * libbfd.c (_bfd_norelocs_set_reloc): New function.
167 * libbfd-in.h: Prototype for _bfd_norelocs_set_reloc.
168 * i386msdos.c (msdos_set_reloc): Define to
169 _bfd_norelocs_set_reloc.
170 * elfcode.h (elf_set_reloc): Define.
171 * bfd-in2.h: Regenerated.
173 2017-05-10 H.J. Lu <hongjiu.lu@intel.com>
176 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Use .plt.bnd
177 for IFUNC function address.
179 2017-05-10 Claudiu Zissulescu <claziss@synopsys.com>
181 * elf32-arc.c (FEATURE_LIST_NAME): Define.
182 (CONFLICT_LIST): Likewise.
183 (opcode/arc-attrs.h): Include.
184 (arc_elf_print_private_bfd_data): Print OSABI v4 flag.
185 (arc_extract_features): New file.
186 (arc_stralloc): Likewise.
187 (arc_elf_merge_attributes): Likewise.
188 (arc_elf_merge_private_bfd_data): Use object attributes.
189 (bfd_arc_get_mach_from_attributes): New function.
190 (arc_elf_object_p): Use object attributes.
191 (arc_elf_final_write_processing): Likewise.
192 (elf32_arc_obj_attrs_arg_type): New function.
193 (elf32_arc_obj_attrs_handle_unknown): Likewise.
194 (elf32_arc_section_from_shdr): Likewise.
195 (elf_backend_obj_attrs_vendor): Define.
196 (elf_backend_obj_attrs_section): Likewise.
197 (elf_backend_obj_attrs_arg_type): Likewise.
198 (elf_backend_obj_attrs_section_type): Likewise.
199 (elf_backend_obj_attrs_handle_unknown): Likewise.
200 (elf_backend_section_from_shdr): Likewise.
202 2017-05-09 Andrew Goedhart <Andrewgoedhart@simplepowersolutions.co.za>
205 * elf32-arm.c (elf32_arm_final_link_relocate): Set the bottom bit
206 of the value when resolving a R_ARM_THM_ALU_PREL_11_0 relocation
207 and the destination is a Thumb symbol.
209 2017-05-08 H.J. Lu <hongjiu.lu@intel.com>
211 * elf32-i386.c (elf_i386_get_synthetic_symtab): Add missing
212 initializer to silence GCC 4.2.
213 * lf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
215 2017-05-08 H.J. Lu <hongjiu.lu@intel.com>
217 * elf64-x86-64.c (PLT_ENTRY_SIZE): Renamed to ...
218 (LAZY_PLT_ENTRY_SIZE): This.
219 (NON_LAZY_PLT_ENTRY_SIZE): New.
220 (elf_x86_64_plt0_entry): Renamed to ...
221 (elf_x86_64_lazy_plt0_entry): This.
222 (elf_x86_64_plt_entry): Renamed to ...
223 (elf_x86_64_lazy_plt_entry): This.
224 (elf_x86_64_bnd_plt0_entry): Renamed to ...
225 (elf_x86_64_lazy_bnd_plt0_entry): This.
226 (elf_x86_64_legacy_plt_entry): Removed.
227 (elf_x86_64_bnd_plt_entry): Renamed to ...
228 (elf_x86_64_lazy_bnd_plt_entry): This.
229 (elf_x86_64_legacy_plt2_entry): Renamed to ...
230 (elf_x86_64_non_lazy_plt_entry): This.
231 (elf_x86_64_bnd_plt2_entry): Renamed to ...
232 (elf_x86_64_non_lazy_bnd_plt_entry): This.
233 (elf_x86_64_eh_frame_plt): Renamed to ...
234 (elf_x86_64_eh_frame_lazy_plt): This.
235 (elf_x86_64_eh_frame_bnd_plt): Renamed to ...
236 (elf_x86_64_eh_frame_lazy_bnd_plt): This.
237 (elf_x86_64_eh_frame_plt_got): Renamed to ...
238 (elf_x86_64_eh_frame_non_lazy_plt): This.
239 (elf_x86_64_lazy_plt_layout): New.
240 (elf_x86_64_non_lazy_plt_layout): Likewise.
241 (elf_x86_64_plt_layout): Likewise.
242 (elf_x86_64_backend_data): Remove PLT layout information. Add
243 os for target system.
244 (GET_PLT_ENTRY_SIZE): Removed.
245 (elf_x86_64_lazy_plt): New.
246 (elf_x86_64_non_lazy_plt): Likewise.
247 (elf_x86_64_lazy_bnd_plt): Likewise.
248 (elf_x86_64_non_lazy_bnd_plt): Likewise.
249 (elf_x86-64_arch_bed): Updated.
250 (elf_x86_64_link_hash_table): Add plt, lazy_plt and non_lazy_plt.
251 (elf_x86_64_create_dynamic_sections): Removed.
252 (elf_x86_64_check_relocs): Don't check elf.dynobj. Don't call
253 _bfd_elf_create_ifunc_sections nor _bfd_elf_create_got_section.
254 (elf_x86-64_adjust_dynamic_symbol): Updated.
255 (elf_x86_64_allocate_dynrelocs): Updated. Pass 0 as PLT header
256 size to _bfd_elf_allocate_ifunc_dyn_relocs and don't allocate
257 size for PLT0 if there is no PLT0. Get plt_entry_size from
258 non_lazy_plt for non-lazy PLT entries.
259 (elf_x86_64_size_dynamic_sections): Updated. Get plt_entry_size
260 from non_lazy_plt for non-lazy PLT entries.
261 (elf_x86-64_relocate_section): Updated. Properly get PLT index
263 (elf_x86_64_finish_dynamic_symbol): Updated. Fill the first slot
264 in the PLT entry with generic PLT layout. Fill the non-lazy PLT
265 entries with non-lazy PLT layout. Don't fill the second and third
266 slots in the PLT entry if there is no PLT0.
267 (elf_x86_64_finish_dynamic_sections): Updated. Don't fill PLT0
268 if there is no PLT0. Set sh_entsize on the .plt.got section.
269 (compare_relocs): New.
270 (elf_x86_64_plt_type): Likewise.
271 (elf_x86_64_plt): Likewise.
272 (elf_x86_64_nacl_plt): New. Forward declaration.
273 (elf_x86_64_get_plt_sym_val): Removed.
274 (elf_x86_64_get_synthetic_symtab): Rewrite to check PLT sections
275 against all dynamic relocations.
276 (elf_x86_64_link_setup_gnu_properties): New function.
277 (elf_backend_create_dynamic_sections): Updated.
278 (elf_backend_setup_gnu_properties): New.
279 (elf_x86_64_nacl_plt): New.
280 (elf_x86_64_nacl_arch_bed): Updated.
282 2017-05-08 H.J. Lu <hongjiu.lu@intel.com>
284 * elf32-i386.c (PLT_ENTRY_SIZE): Renamed to ...
285 (LAZY_PLT_ENTRY_SIZE): This.
286 (NON_LAZY_PLT_ENTRY_SIZE): New.
287 (elf_i386_plt0_entry): Renamed to ...
288 (elf_i386_lazy_plt0_entry): This.
289 (elf_i386_plt_entry): Renamed to ...
290 (elf_i386_lazy_plt_entry): This.
291 (elf_i386_pic_plt0_entry): Renamed to ...
292 (elf_i386_pic_lazy_plt0_entry): This.
293 (elf_i386_pic_plt_entry): Renamed to ...
294 (elf_i386_pic_lazy_plt_entry): This.
295 (elf_i386_got_plt_entry): Renamed to ...
296 (elf_i386_non_lazy_plt_entry): This.
297 (elf_i386_pic_got_plt_entry): Renamed to ...
298 (elf_i386_pic_non_lazy_plt_entry): This.
299 (elf_i386_eh_frame_plt): Renamed to ...
300 (elf_i386_eh_frame_lazy_plt): This.
301 (elf_i386_eh_frame_plt_got): Renamed to ...
302 (elf_i386_eh_frame_non_lazy_plt): This.
303 (elf_i386_plt_layout): Renamed to ...
304 (elf_i386_lazy_plt_layout): This. Remove eh_frame_plt_got and
305 eh_frame_plt_got_size.
306 (elf_i386_non_lazy_plt_layout): New.
307 (elf_i386_plt_layout): Likewise.
308 (elf_i386_non_lazy_plt): Likewise.
309 (GET_PLT_ENTRY_SIZE): Removed.
310 (elf_i386_plt): Renamed to ...
311 (elf_i386_lazy_plt): This.
312 (elf_i386_backend_data): Remove plt. Rename is_vxworks to os.
313 (elf_i386_arch_bed): Updated.
314 (elf_i386_link_hash_table): Add plt, lazy_plt and non_lazy_plt.
315 (elf_i386_create_dynamic_sections): Removed.
316 (elf_i386_check_relocs): Don't check elf.dynobj. Don't call
317 _bfd_elf_create_ifunc_sections nor _bfd_elf_create_got_section.
318 (elf_i386_adjust_dynamic_symbol): Updated.
319 (elf_i386_allocate_dynrelocs): Updated. Pass 0 as PLT header
320 size to _bfd_elf_allocate_ifunc_dyn_relocs and don't allocate
321 size for PLT0 if there is no PLT0.
322 (elf_i386_size_dynamic_sections): Updated. Check whether GOT
323 output section is discarded only if GOT isn't empty.
324 (elf_i386_relocate_section): Updated. Properly get PLT index
326 (elf_i386_finish_dynamic_symbol): Updated. Don't fill the
327 second and third slots in the PLT entry if there is no PLT0.
328 (elf_i386_finish_dynamic_sections): Updated. Don't fill PLT0
329 if there is no PLT0. Set sh_entsize on the .plt.got section.
330 (elf_i386_nacl_plt): Forward declaration.
331 (elf_i386_get_plt_sym_val): Removed.
332 (elf_i386_get_synthetic_symtab): Rewrite to check PLT sections
333 against all dynamic relocations.
334 (elf_i386_link_setup_gnu_properties): New function.
335 (elf_backend_create_dynamic_sections): Updated.
336 (elf_backend_setup_gnu_properties): New.
337 (elf_i386_nacl_plt): Updated.
338 (elf_i386_nacl_arch_bed): Likewise.
339 (elf_i386_vxworks_arch_bed): Likewise.
341 2017-05-08 Thomas Preud'homme <thomas.preudhomme@arm.com>
343 * elflink.c (elf_output_implib): Remove executable flag from import
345 * elf32-arm.c (elf32_arm_filter_implib_symbols): Assert that the import
346 library is a relocatable object file.
348 2017-05-01 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
351 * elf32-avr.c (avr_should_move_sym): New function.
352 (avr_should_reduce_sym_size): Likewise.
353 (avr_should_increase_sym_size): Likewise.
354 (elf32_avr_relax_delete_bytes): Adjust symbol values
355 and sizes by calling new functions.
357 2017-05-01 Palmer Dabbelt <palmer@dabbelt.com>
359 * config.bfd (riscv32-*): Enable rv64.
361 2017-05-02 Alan Modra <amodra@gmail.com>
364 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Test h->non_elf
365 rather than h->root.type == bfd_link_hash_new.
366 (bfd_elf_record_link_assignment): Similarly, call
367 bfd_elf_link_mark_dynamic_symbol when h->non_elf.
369 2017-04-29 Alan Modra <amodra@gmail.com>
372 * reloc.c (reloc_offset_in_range): New function.
373 (bfd_perform_relocation, bfd_install_relocation): Use it.
374 (_bfd_final_link_relocate): Likewise.
376 2017-04-28 H.J. Lu <hongjiu.lu@intel.com>
378 * elf32-i386.c (elf_i386_allocate_dynrelocs): Check plt_got
379 before using .plt.got.
380 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewise.
382 2017-04-27 H.J. Lu <hongjiu.lu@intel.com>
384 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Use "="
385 instead of "+=" to update 0.
387 2017-04-27 H.J. Lu <hongjiu.lu@intel.com>
389 * elf32-i386.c (elf_i386_create_dynamic_sections): Create the
390 .plt.got section here.
391 (elf_i386_check_relocs): Don't create the .plt.got section.
392 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Create
393 the .plt.got and .plt.bnd sections here.
394 (elf_x86_64_check_relocs): Don't create the .plt.got nor
397 2017-04-27 H.J. Lu <hongjiu.lu@intel.com>
399 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Remove
401 (elf_x86_64_link_hash_newfunc): Don't clear has_bnd_reloc.
402 (elf_x86_64_copy_indirect_symbol): Don't copy has_bnd_reloc.
403 (elf_x86_64_check_relocs): Don't set has_bnd_reloc.
404 (elf_x86_64_finish_dynamic_symbol): Check bndplt instead of
407 2017-04-27 H.J. Lu <hongjiu.lu@intel.com>
409 * elf-bfd.h (elf_backend_data): Change setup_gnu_properties
411 (_bfd_elf_link_setup_gnu_properties): Return bfd *.
412 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Return
413 the first relocatable ELF input with GNU properties.
415 2017-04-27 H.J. Lu <hongjiu.lu@intel.com>
417 * elf32-i386.c (elf_i386_finish_dynamic_sections): Simplify
420 2017-04-27 Alan Modra <amodra@gmail.com>
422 * elf-bfd.h (struct elf_backend_data): Make asection param of
423 elf_backend_eh_frame_address_size const.
424 (_bfd_elf_eh_frame_address_size): Likewise.
425 * elf32-m32c.c (_bfd_m32c_elf_eh_frame_address_size): Likewise.
426 * elf32-msp430.c (elf32_msp430_eh_frame_address_size): Likewise.
427 * elfxx-mips.c (_bfd_mips_elf_eh_frame_address_size): Likewise.
428 * elfxx-mips.h (_bfd_mips_elf_eh_frame_address_size): Likewise.
429 * elf-eh-frame.c (_bfd_elf_eh_frame_address_size): Likewise.
430 (next_cie_fde_offset): Constify params.
431 (offset_adjust, adjust_eh_frame_local_symbols): Likewise.
433 2017-04-27 Alan Modra <amodra@gmail.com>
435 * elf-bfd.h (struct eh_cie_fde): Add aug_str_len and aug_data_len.
436 (_bfd_elf_adjust_eh_frame_global_symbol): Declare.
437 * elf-eh-frame.c (_bfd_elf_parse_eh_frame): Set aug_str_len and
439 (offset_adjust): New function.
440 (_bfd_elf_adjust_eh_frame_global_symbol): Likewise.
441 (adjust_eh_frame_local_symbols): Likewise.
442 (_bfd_elf_discard_section_eh_frame): Call adjust_eh_frame_local_symbols
443 after changing anything. Return true if anything changed.
444 * elflink.c (bfd_elf_discard_info): If .eh_frame changed, call
445 _bfd_elf_adjust_eh_frame_global_symbol for globals.
447 2017-04-27 Alan Modra <amodra@gmail.com>
449 * elflink.c (_bfd_elf_link_hash_hide_symbol): Clear dynstr_index
452 2017-04-27 Alan Modra <amodra@gmail.com>
454 * elf32-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
455 (ppc_elf_select_plt_layout, ppc_elf_tls_setup): Use it.
456 (ppc_elf_adjust_dynamic_symbol, allocate_dynrelocs): Likewise.
457 (ppc_elf_relocate_section): Likewise. Delete silly optimisation
458 for undef and undefweak dyn_relocs.
459 * elf64-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
460 (ppc64_elf_adjust_dynamic_symbol, ppc64_elf_tls_setup): Use it.
461 (allocate_got, allocate_dynrelocs): Likewise.
462 (ppc64_elf_relocate_section): Likewise.
464 2017-04-26 H.J. Lu <hongjiu.lu@intel.com>
466 * elf32-i386.c (elf_i386_size_dynamic_sections): Alwasys add
467 DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rel.plt section.
468 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Alwasys
469 add DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rela.plt section.
471 2017-04-26 Nick Clifton <nickc@redhat.com>
474 * reloc.c (bfd_perform_relocation): Check for a negative address
477 2017-04-26 Maciej W. Rozycki <macro@imgtec.com>
480 * elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
482 * elfxx-target.h [!elf_backend_always_renumber_dynsyms]
483 (elf_backend_always_renumber_dynsyms): Define.
484 (elfNN_bed): Initialize `always_renumber_dynsyms' member.
485 * elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
486 * elflink.c (bfd_elf_size_dynamic_sections): Also call
487 `_bfd_elf_link_renumber_dynsyms' if the backend has requested
489 (bfd_elf_size_dynsym_hash_dynstr): Likewise.
491 2017-04-26 Maciej W. Rozycki <macro@imgtec.com>
493 * elflink.c (bfd_elf_size_dynamic_sections): Only call
494 `_bfd_elf_link_renumber_dynsyms' after section GC if dynamic
495 sections have been created.
497 2017-04-26 Nick Clifton <nickc@redhat.com>
500 * compress.c (bfd_init_section_compress_status): Check the return
501 value from bfd_malloc.
503 2017-04-24 H.J. Lu <hongjiu.lu@intel.com>
505 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Add
506 no_finish_dynamic_symbol.
507 (elf_x86_64_link_hash_newfunc): Set no_finish_dynamic_symbol to
509 (elf_x86_64_allocate_dynrelocs): If a symbol isn't undefined
510 weak symbol, don't make it dynamic.
511 (elf_x86_64_relocate_section): If a symbol isn't dynamic in PIC,
512 set no_finish_dynamic_symbol and generate R_X86_64_RELATIVE
513 relocation for GOT reference.
514 (elf_x86_64_finish_dynamic_symbol): Abort if
515 no_finish_dynamic_symbol isn't 0.
517 2017-04-24 H.J. Lu <hongjiu.lu@intel.com>
520 * elf32-i386.c (elf_i386_allocate_dynrelocs): If a symbol isn't
521 undefined weak symbol, don't make it dynamic.
522 (elf_i386_relocate_section): If a symbol isn't dynamic in PIC,
523 set no_finish_dynamic_symbol and generate R_386_RELATIVE
524 relocation for R_386_GOT32.
526 2017-04-24 H.J. Lu <hongjiu.lu@intel.com>
529 * elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.
531 2017-04-23 Alan Modra <amodra@gmail.com>
534 * section.c (GLOBAL_SYM_INIT): Make available in bfd.h.
535 * elf.c (lcomm_sym): New.
536 (_bfd_elf_large_com_section): Use lcomm_sym section symbol.
537 * bfd-in2.h: Regenerate.
539 2017-04-23 Alan Modra <amodra@gmail.com>
542 * elf-bfd.h (struct elf_backend_data <get_reloc_section>): Change
543 parameters and comment.
544 (_bfd_elf_get_reloc_section): Delete.
545 (_bfd_elf_plt_get_reloc_section): Declare.
546 * elf.c (_bfd_elf_plt_get_reloc_section, elf_get_reloc_section):
547 New functions. Don't blindly skip over assumed .rel/.rela prefix.
549 (_bfd_elf_get_reloc_section): ..here. Delete.
550 (assign_section_numbers): Call elf_get_reloc_section.
551 * elf64-ppc.c (elf_backend_get_reloc_section): Define.
552 * elfxx-target.h (elf_backend_get_reloc_section): Update.
554 2017-04-23 Alan Modra <amodra@gmail.com>
557 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Don't segfault when
560 2017-04-21 H.J. Lu <hongjiu.lu@intel.com>
563 * elf32-i386.c (elf_i386_link_hash_entry): Add
564 no_finish_dynamic_symbol.
565 (elf_i386_link_hash_newfunc): Set no_finish_dynamic_symbol to 0.
566 (elf_i386_allocate_dynrelocs): If a symbol isn't undefined weak
567 symbol, don't make it dynamic in PIE.
568 (elf_i386_relocate_section): If a symbol isn't dynamic in PIE,
569 set no_finish_dynamic_symbol and generate R_386_RELATIVE
570 relocation for R_386_GOT32
571 (elf_i386_finish_dynamic_symbol): Abort if no_finish_dynamic_symbol
574 2017-04-21 H.J. Lu <hongjiu.lu@intel.com>
578 * elflink.c (elf_link_add_object_symbols): Require
579 --no-dynamic-linker with -E/--dynamic-list when creating
582 2017-04-20 Maciej W. Rozycki <macro@imgtec.com>
584 * elflink.c (_bfd_elf_symbol_refs_local_p): Always return TRUE
587 2017-04-20 Maciej W. Rozycki <macro@imgtec.com>
589 * elfxx-mips.c (_bfd_mips_elf_final_link): Reorder comment about
590 dynamic symbol sorting.
592 2017-04-20 H.J. Lu <hongjiu.lu@intel.com>
595 * elflink.c (elf_link_add_object_symbols): Preserve
596 dynamic_ref_after_ir_def when restoring the symbol table for
597 unneeded dynamic object.
599 2017-04-19 H.J. Lu <hongjiu.lu@intel.com>
602 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Don't abort
603 on on undefined IFUNC symbol in the second PLT.
605 2017-04-19 Wedson Almeida Filho <wedsonaf@gmail.com>
607 * peXXigen.c (pe_print_reloc): Correct chunk_end.
609 2017-04-19 Alan Modra <amodra@gmail.com>
611 * elflink.c (_bfd_elf_adjust_dynamic_symbol): Hide undefweak
612 or make dynamic for info->dynamic_undefined_weak 0 and 1.
613 * elf32-ppc.c:Formatting.
614 (ensure_undefweak_dynamic): Don't make dynamic when
615 info->dynamic_undefined_weak is zero.
616 (allocate_dynrelocs): Discard undefweak dyn_relocs for
617 info->dynamic_undefined_weak. Discard undef dyn_relocs when
618 not default visibility. Discard undef and undefweak
620 (ppc_elf_relocate_section): Adjust to suit.
621 * elf64-ppc.c: Formatting.
622 (ensure_undefweak_dynamic): Don't make dynamic when
623 info->dynamic_undefined_weak is zero.
624 (allocate_dynrelocs): Discard undefweak dyn_relocs for
625 info->dynamic_undefined_weak. Discard them earlier.
627 2017-04-17 H.J. Lu <hongjiu.lu@intel.com>
630 * elflink.c (bfd_elf_size_dynamic_sections): Get soname index
631 before generating the version definition section.
633 2017-04-17 Alan Modra <amodra@gmail.com>
635 * elflink.c (_bfd_elf_merge_symbol): Undo dynamic linking
636 state when a regular object file defines a symbol with
637 incompatible type to that defined by an earlier shared lib.
639 2017-04-13 Alan Modra <amodra@gmail.com>
641 * coffcode.h: Wrap some overly long _bfd_error_handler args.
643 * elf32-arm.c: Likewise.
644 * elf32-i386.c: Likewise.
645 * elf32-mep.c: Likewise.
646 * elf64-ia64-vms.c: Likewise.
647 * elf64-x86-64.c: Likewise.
648 * elflink.c: Likewise.
649 * elfnn-ia64.c: Likewise.
650 * elfxx-mips.c: Likewise.
652 2017-04-13 Alan Modra <amodra@gmail.com>
654 * aoutx.h: Use %B and %A in error messages throughout file.
655 * aout-cris.c: Likewise.
656 * archive.c: Likewise.
657 * binary.c: Likewise.
658 * coff-rs6000.c: Likewise.
659 * coff-tic4x.c: Likewise.
660 * coffcode.h: Likewise.
661 * coffgen.c: Likewise.
662 * cofflink.c: Likewise.
663 * coffswap.h: Likewise.
664 * cpu-arm.c: Likewise.
665 * elf-eh-frame.c: Likewise.
666 * elf-m10300.c: Likewise.
668 * elf32-arc.c: Likewise.
669 * elf32-arm.c: Likewise.
670 * elf32-bfin.c: Likewise.
671 * elf32-frv.c: Likewise.
672 * elf32-iq2000.c: Likewise.
673 * elf32-m32c.c: Likewise.
674 * elf32-microblaze.c: Likewise.
675 * elf32-nds32.c: Likewise.
676 * elf32-rl78.c: Likewise.
677 * elf32-rx.c: Likewise.
678 * elf32-score.c: Likewise.
679 * elf32-score7.c: Likewise.
680 * elf32-sh64.c: Likewise.
681 * elf32-v850.c: Likewise.
682 * elf32-vax.c: Likewise.
683 * elf32-visium.c: Likewise.
684 * elf64-ia64-vms.c: Likewise.
685 * elf64-mmix.c: Likewise.
686 * elf64-sh64.c: Likewise.
687 * elfcode.h: Likewise.
688 * elfnn-aarch64.c: Likewise.
689 * elfnn-ia64.c: Likewise.
690 * elfxx-mips.c: Likewise.
691 * hpux-core.c: Likewise.
694 * linker.c: Likewise.
699 * peXXigen.c: Likewise.
700 * rs6000-core.c: Likewise.
701 * vms-alpha.c: Likewise.
702 * xcofflink.c: Likewise.
704 2017-04-13 Alan Modra <amodra@gmail.com>
706 * bfd.c (PRINT_TYPE): Define.
707 (_doprnt): New function.
708 (error_handler_internal): Use _doprnt.
709 * coff-arm.c: Put %A and %B arguments to _bfd_error_handler
710 calls in their natural order, throughout file.
711 * coff-mcore.c: Likewise.
712 * coff-ppc.c: Likewise.
713 * coff-tic80.c: Likewise.
714 * cofflink.c: Likewise.
715 * elf-s390-common.c: Likewise.
717 * elf32-arm.c: Likewise.
718 * elf32-i386.c: Likewise.
719 * elf32-m32r.c: Likewise.
720 * elf32-msp430.c: Likewise.
721 * elf32-spu.c: Likewise.
722 * elf64-ia64-vms.c: Likewise.
723 * elf64-sparc.c: Likewise.
724 * elf64-x86-64.c: Likewise.
725 * elflink.c: Likewise.
726 * elfnn-aarch64.c: Likewise.
727 * elfnn-ia64.c: Likewise.
728 * elfxx-mips.c: Likewise.
730 2017-04-13 Alan Modra <amodra@gmail.com>
732 * elf32-arm.c (arm_type_of_stub): Supply missing args to "long
733 branch veneers" error. Fix double space and format message.
734 * elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
735 * elf64-ppc.c (tocsave_find): Supply missing %B arg.
737 2017-04-13 Alan Modra <amodra@gmail.com>
739 * bfd-in2.h: Regenerate.
741 2017-04-11 H.J. Lu <hongjiu.lu@intel.com>
743 * elf-properties.c (_bfd_elf_parse_gnu_properties): Remove the
744 extra `\n' in warning/error messages.
745 * elf32-i386.c (elf_i386_parse_gnu_properties): Likewise.
746 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
748 2017-04-11 H.J. Lu <hongjiu.lu@intel.com>
750 * elf-properties.c (_bfd_elf_parse_gnu_properties): Ignore
751 processor-specific properties with generic ELF target vector.
753 2017-04-10 Qing Zhao <qing.zhao@oracle.com>
755 * elf32-sparc.c (elf_backend_fixup_symbol): New.
756 * elf64-sparc.c (elf_backend_fixup_symbol): New.
757 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
758 (_bfd_sparc_elf_link_hash_entry): Add has_got_reloc and
760 (link_hash_newfunc): Initialize has_got_reloc and
762 (_bfd_sparc_elf_size_dynamic_sections): Set interp to .interp
764 (_bfd_sparc_elf_copy_indirect_symbol): Copy has_got_reloc and
766 (_bfd_sparc_elf_check_relocs): Set has_got_reloc and
768 (_bfd_sparc_elf_fixup_symbol): New function.
769 (allocate_dynrelocs): Don't allocate space for dynamic
770 relocations and discard relocations against resolved undefined
771 weak symbols in executable. Don't make resolved undefined weak
772 symbols in executable dynamic. Keep dynamic non-GOT/non-PLT
773 relocation against undefined weak symbols in PIE.
774 (_bfd_sparc_elf_relocate_section): Don't generate dynamic
775 relocations against resolved undefined weak symbols in PIE
776 (_bfd_sparc_elf_finish_dynamic_symbol): Keep PLT/GOT entries
777 without ynamic PLT/GOT relocations for resolved undefined weak
779 Don't generate dynamic relocation against resolved undefined
780 weak symbol in executable.
781 (pie_finish_undefweak_symbol): New function.
782 (_bfd_sparc_elf_finish_dynamic_sections): Call
783 pie_finish_undefweak_symbol on all symbols in PIE.
784 * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Add interp.
785 (_bfd_sparc_elf_fixup_symbol): New function.
787 2017-04-10 Nick Clifton <nickc@redhat.com>
789 * config.bfd: Remove ns32k from obsolete list.
791 2017-04-10 Alan Modra <amodra@gmail.com>
794 * elf.c (special_sections_f): Match .fini_array and .fini_array.*.
795 (special_sections_i): Likewise for .init_array.
796 (special_sections_p): Likewise for .preinit_array.
798 2017-04-07 H.J. Lu <hongjiu.lu@intel.com>
802 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
803 ELF_COMMON_DEF_P for common symbols.
804 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
805 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
806 * elflink.c (_bfd_elf_merge_symbol): Revert commits
807 202ac193bbbecc96a4978d1ac3d17148253f9b01 and
808 07492f668d2173da7a2bda3707ff0985e0f460b6.
810 2017-04-07 Pedro Alves <palves@redhat.com>
812 * opncls.c (bfd_get_debug_link_info): Rename to...
813 (bfd_get_debug_link_info_1): ... this. Change type of second
814 parameter to void pointer. Adjust.
815 (bfd_get_debug_link_info): Reimplement on top of
816 bfd_get_debug_link_info_1.
817 (separate_debug_file_exists, separate_alt_debug_file_exists):
818 Change type of second parameter to void pointer. Adjust.
819 (get_func_type, check_func_type): Change type of second parameter
821 (find_separate_debug_file): Add 'func_data' parameter. Pass it to
822 the callback functions instead of passing the address of a local.
823 (bfd_follow_gnu_debuglink): Pass address of unsigned long local to
824 find_separate_debug_file.
825 (get_alt_debug_link_info_shim): Change type of second parameter to
826 void pointer. Adjust.
827 (bfd_follow_gnu_debugaltlink): Adjust to pass NULL to
828 find_separate_debug_file.
829 (get_build_id_name, bfd_boolean check_build_id_file): Change type
830 of second parameter to void pointer. Adjust.
831 (bfd_follow_build_id_debuglink): Pass address of bfd_build_id
832 pointer local to find_separate_debug_file.
834 2017-04-07 Tristan Gingold <gingold@gingold-Precision-7510>
836 * coffgen.c (_bfd_coff_gc_mark_hook): Handle PE weak
837 external symbols with a definition.
838 (_bfd_coff_gc_mark_extra_sections): Fix typo.
840 2017-04-07 Alan Modra <amodra@gmail.com>
842 * po/SRC-POTFILES.in: Regenerate.
844 2017-04-05 Alan Modra <amodra@gmail.com>
846 * elf64-ppc.c (ppc64_elf_gc_sweep_hook): Support ELFv2 PLT
849 2017-04-02 Jon Turney <jon.turney@dronecode.org.uk>
851 (_bfd_XXi_swap_aouthdr_out): For clarity, use defines rather than
852 numbers for DataDirectory entry indicies passed to
855 2017-04-04 H.J. Lu <hongjiu.lu@intel.com>
857 * elf.c (get_program_header_size): Add a GNU_MBIND segment for
858 each GNU_MBIND section and align GNU_MBIND section to page size.
859 (_bfd_elf_map_sections_to_segments): Create a GNU_MBIND
860 segment for each GNU_MBIND section.
861 (_bfd_elf_init_private_section_data): Copy sh_info from input
862 for GNU_MBIND section.
864 2017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
866 * elfnn-riscv.c (GP_NAME): Delete.
867 (riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
868 (_bfd_riscv_relax_lui): Likewise.
870 2017-04-04 Nick Clifton <nickc@redhat.com>
873 * elflink.c (_bfd_elf_define_linkage_sym): Prevent null pointer
875 (bfd_elf_final_link): Only initialize the extended symbol index
876 section if there are extended symbol tables to list.
878 2017-04-03 H.J. Lu <hongjiu.lu@intel.com>
880 * Makefile.am (BFD32_BACKENDS): Add elf-properties.lo.
881 (BFD32_BACKENDS_CFILES): Add elf-properties.c.
882 * configure.ac (elf): Add elf-properties.lo.
883 * Makefile.in: Regenerated.
884 * configure: Likewise.
885 * elf-bfd.h (elf_property_kind): New.
886 (elf_property): Likewise.
887 (elf_property_list): Likewise.
888 (elf_properties): Likewise.
889 (_bfd_elf_parse_gnu_properties): Likewise.
890 (_bfd_elf_get_property): Likewise.
891 (_bfd_elf_link_setup_gnu_properties): Likewise.
892 (elf_backend_data): Add parse_gnu_properties, merge_gnu_properties
893 and setup_gnu_properties.
894 (elf_obj_tdata): Add properties.
895 * elf-properties.c: New file.
896 * elf32-i386.c (elf_i386_parse_gnu_properties): New.
897 (elf_i386_merge_gnu_properties): Likewise.
898 (elf_backend_parse_gnu_properties): Likewise.
899 (elf_backend_merge_gnu_properties): Likewise.
900 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
901 (elf_x86_64_merge_gnu_properties): Likewise.
902 (elf_backend_parse_gnu_properties): Likewise.
903 (elf_backend_merge_gnu_properties): Likewise.
904 * elfxx-target.h (elf_backend_merge_gnu_properties): Likewise.
905 (elf_backend_parse_gnu_properties): Likewise.
906 (elf_backend_setup_gnu_properties): Likewise.
907 (elfNN_bed): Add elf_backend_parse_gnu_properties,
908 elf_backend_merge_gnu_properties and
909 elf_backend_setup_gnu_properties.
911 2017-03-30 Pip Cet <pipcet@gmail.com>
913 * elf32-wasm32.c: Add relocation code, two relocs.
914 * reloc.c: Add wasm32 relocations.
915 * libbfd.h: Regenerate.
916 * bfd-in2.h: Regenerate.
917 * bfd/po/bfd.pot: Regenerate.
919 2017-03-29 Nick Clifton <nickc@redhat.com>
922 * coff-bfd.h (struct coff_section_data): Add new fields:
924 * coffgen.c (coff_find_nearest_line_with_names): Cache the bias
925 computed for PE binaries.
926 * dwarf2.c (scan_unit_for_symbols): Only warn once about each
929 2017-03-28 Hans-Peter Nilsson <hp@axis.com>
932 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Adjust BFD_ASSERT
933 to handle a local symbol with a hash-symbol-entry; without PLT.
934 Add BFD_ASSERT for an incidental case with GOT entry present.
935 (cris_elf_check_relocs): Increment PLT refcount only if the symbol
936 isn't forced-or-set local.
938 2017-03-27 Pip Cet <pipcet@gmail.com>
940 * wasm-module.c: New file to support WebAssembly modules.
941 * wasm-module.h: New file to support WebAssembly modules.
942 * doc/webassembly.texi: Start documenting wasm-module.c.
943 * config.bfd: Add wasm_vec.
944 * targets.c: Likewise.
945 * configure.ac: Likewise.
946 * Makefile.am: Add entries for wasm-module.c.
947 * Makefile.in: Regenerate.
948 * configure: Regenerate.
949 * po/SRC-POTFILES.in: Regenerate.
951 2017-03-27 Pip Cet <pipcet@gmail.com>
953 * cpu-wasm32.c: New file to support wasm32 architecture.
954 * elf32-wasm32.c: New file to support wasm32 architecture.
955 * Makefile.am: Add wasm32 architecture.
956 * archures.c: Likewise.
957 * config.bfd: Likewise.
958 * configure.ac: Likewise.
959 * targets.c: Likewise.
960 * Makefile.in: Regenerate.
961 * bfd-in2.h: Regenerate.
962 * configure: Regenerate.
963 * po/SRC-POTFILES.in: Regenerate.
965 2017-03-20 Alan Modra <amodra@gmail.com>
968 * elf64-ppc.c (compare_symbols): Stabilize sort.
970 2017-03-18 Alan Modra <amodra@gmail.com>
972 * elf64-ppc.c (struct ppc_link_hash_table): Add
973 local_ifunc_resolver and maybe_local_ifunc_resolver.
974 (ppc_build_one_stub): Set flags on emitting dynamic
976 (ppc64_elf_relocate_section): Likewise.
977 (ppc64_elf_finish_dynamic_symbol): Likewise.
978 (ppc64_elf_finish_dynamic_sections): Error on DT_TEXTREL with
979 local dynamic relocs to ifuncs.
980 * elf32-ppc.c (struct ppc_elf_link_hash_table): Add
981 local_ifunc_resolver and maybe_local_ifunc_resolver.
982 (ppc_elf_relocate_section): Set flag on emitting dynamic
983 relocation to ifuncs.
984 (ppc_elf_finish_dynamic_symbol): Likewise.
985 (ppc_elf_finish_dynamic_sections): Error on DT_TEXTREL with local
986 dynamic relocs to ifuncs.
988 2017-03-13 Nick Clifton <nickc@redhat.com>
991 * reloc.c (BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC): Rename to
992 BFD_RELOC_AARCH64_TLSDESC_LD64_LO12.
993 (BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC): Rename to
994 BFD_RELOC_AARCH64_TLSDESC_ADD_LO12.
995 * bfd-in2.h: Regenerate.
996 * libbfd.h: Regenerate.
997 * elfnn-aarch64.c (IS_AARCH64_TLS_RELAX_RELOC): Update reloc
999 (IS_AARCH64_TLSDESC_RELOC): Likewise.
1000 (elfNN_aarch64_howto_table): Likewise.
1001 (aarch64_tls_transition_without_check): Likewise.
1002 (aarch64_reloc_got_type): Likewise.
1003 (elfNN_aarch64_final_link_relocate): Likewise.
1004 (elfNN_aarch64_tls_relax): Likewise.
1005 (elfNN_aarch64_relocate_section): Likewise.
1006 (elfNN_aarch64_gc_sweep_hook): Likewise.
1007 (elfNN_aarch64_check_relocs): Likewise.
1008 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
1009 (_bfd_aarch64_elf_resolve_relocation): Likewise.
1011 2017-03-11 Alan Modra <amodra@gmail.com>
1013 * elf32-ppc.c: Remove ATTRIBUTE_UNUSED throughout when function
1014 parameter is in fact used. Whitespace fixes.
1015 * elf64-ppc.c: Likewise.
1017 2017-03-09 Sam Thursfield <sam.thursfield@codethink.co.uk>
1019 * rs6000-core.c (CORE_NEW): Simplify macro when
1020 AIX_CORE_DUMPX_CORE and BFD64 are true to avoid compile warning.
1022 2017-03-07 Alan Modra <amodra@gmail.com>
1026 * elf64-ppc.c (ppc64_elf_relocate_section): Add missing
1029 2017-03-05 Alan Modra <amodra@gmail.com>
1031 * elf-bfd.h (struct eh_cie_fde): Add u.cie.per_encoding_aligned8.
1032 * elf-eh-frame.c (size_of_output_cie_fde): Don't align here.
1033 (next_cie_fde_offset): New function.
1034 (_bfd_elf_parse_eh_frame): Set u.cie.per_encoding_aligned8.
1035 (_bfd_elf_discard_section_eh_frame): Align zero terminator to
1036 four bytes. Align CIEs to four or eight bytes depending on
1037 per_encoding_aligned8. Align FDEs according to their encoding.
1038 Pad last FDE to output section alignment.
1039 (_bfd_elf_write_section_eh_frame): Adjust to suit. Remove
1041 * elf64-ppc.c (glink_eh_frame_cie): Delete padding.
1042 (ppc64_elf_size_stubs): Pad glink eh_frame as per elf-eh-frame.c.
1043 (ppc64_elf_finish_dynamic_sections): Adjust to suit.
1045 2017-03-02 Martin Bickel <binutils@ineranves.de>
1048 * elf.c (rewrite_elf_program_header): Do not issue a warning for
1049 empty segments which have a zero filesz, but a non-zero memsz.
1051 2017-03-02 Alan Modra <amodra@gmail.com>
1053 * elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.
1055 2017-02-28 Alan Modra <amodra@gmail.com>
1057 * elf64-ppc.c (ppc64_elf_ha_reloc): Revert last change.
1058 (ppc64_elf_relocate_section): Likewise.
1060 2017-02-28 Alan Modra <amodra@gmail.com>
1063 * elf32-nios2.c (nios2_elf32_relocate_section): Use htab
1064 rather than elf32_nios2_hash_table or elf_hash_table.
1065 (create_got_section): Likewise.
1066 (nios2_elf32_finish_dynamic_symbol): Likewise.
1067 (nios2_elf32_adjust_dynamic_symbol): Likewise.
1068 (nios2_elf32_size_dynamic_sections): Likewise.
1069 (nios2_elf32_check_relocs): Delete dynobj, sgot, and srelgot
1070 vars. Use htab equivalents directly instead. Don't create
1071 all dynamic sections on needing just the GOT. Use a goto
1072 rather than a fall-through with reloc test. Ensure
1073 htab->dynobj is set when making dynamic sreloc section.
1074 (nios2_elf32_finish_dynamic_sections): Delete dynobj, use htab
1075 equivalent directly instead. Don't segfault on looking for
1076 .dynamic when dynamic sections have not been created. Don't
1077 segfault on .got.plt being discarded.
1078 (nios2_elf32_size_dynamic_sections): Delete plt and got vars.
1079 Don't set "relocs" on .rela.plt. Do handle .sbss. Delete
1080 fixme and another not so relevant comment.
1081 (nios2_elf_add_symbol_hook): Delete dynobj var. If not
1082 already set, set hash table dynobj on creating .sbss.
1084 2017-02-28 Alan Modra <amodra@gmail.com>
1086 * reloc.c (BFD_RELOC_PPC_16DX_HA): New.
1087 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_16DX_HA>): New howto.
1088 (ppc64_elf_reloc_type_lookup): Translate new bfd reloc.
1089 (ppc64_elf_ha_reloc): Correct overflow test on REL16DX_HA.
1090 (ppc64_elf_relocate_section): Likewise.
1091 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_16DX_HA>): New howto.
1092 (ppc_elf_reloc_type_lookup): Translate new bfd reloc.
1093 (ppc_elf_check_relocs): Handle R_PPC_16DX_HA to pacify gcc.
1094 * libbfd.h: Regenerate.
1095 * bfd-in2.h: Regenerate.
1097 2017-02-28 Alan Modra <amodra@gmail.com>
1099 * elflink.c (_bfd_elf_create_dynamic_sections): Don't make
1100 dynamic .data.rel.ro read-only.
1101 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Compare section
1102 rather than section flags when deciding where copy reloc goes.
1103 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
1104 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
1105 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Likewise.
1106 * elf32-metag.c (elf_metag_finish_dynamic_symbol): Likewise.
1107 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Likewise.
1108 * elf32-nios2.c (nios2_elf32_finish_dynamic_symbol): Likewise.
1109 * elf32-or1k.c (or1k_elf_finish_dynamic_symbol): Likewise.
1110 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Likewise.
1111 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
1112 * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
1113 * elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
1114 * elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Likewise.
1115 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
1116 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
1117 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Likewise.
1118 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Likewise.
1119 * elfxx-mips.c (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
1120 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
1121 * elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
1123 2017-02-28 Maciej W. Rozycki <macro@imgtec.com>
1125 * elfxx-mips.c (mips_elf_perform_relocation): Also handle the
1126 `jalr $0, $25' instruction encoding.
1128 2017-02-27 Nick Clifton <nickc@redhat.com>
1131 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Avoid
1132 generating a seg-fault when encountering a symbol that has been
1133 deleted by garbage collection.
1135 2017-02-25 Alan Modra <amodra@gmail.com>
1137 * elf32-arc.c (struct dynamic_sections): Delete.
1138 (enum dyn_section_types): Delete.
1139 (dyn_section_names): Delete.
1140 (arc_create_dynamic_sections): Delete.
1141 (elf_arc_finish_dynamic_sections): Don't call the above. Don't
1142 segfault on discarded .rela.plt section.
1143 (elf_arc_size_dynamic_sections): Formatting. Don't call
1144 arc_create_dynamic_sections. Don't allocate memory for sections
1145 handled by the generic linker. Correct code finding relocs in
1146 read-only sections. Set SEC_EXCLUDE on zero size .got,
1147 .got.plt, and .dynbss sections. Do set .interp for pies.
1149 2017-02-24 Andrew Waterman <andrew@sifive.com>
1151 * elfnn-riscv.c (GP_NAME): New macro.
1152 (riscv_global_pointer_value): Use it.
1153 (_bfd_riscv_relax_lui): If symbol and global pointer are in same
1154 output section, consider only that section's alignment.
1156 2017-02-23 Maciej W. Rozycki <macro@imgtec.com>
1158 * elfxx-mips.h (_bfd_mips_relax_section): Remove prototype.
1159 * elfxx-mips.c (_bfd_mips_relax_section): Remove function.
1160 * elf64-mips.c (bfd_elf64_bfd_relax_section): Remove macro.
1161 * elfn32-mips.c (bfd_elf32_bfd_relax_section): Likewise.
1163 2017-02-23 Maciej W. Rozycki <macro@imgtec.com>
1165 * elfxx-mips.c (mips_elf_calculate_relocation) <R_MIPS_JALR>
1166 <R_MICROMIPS_JALR>: Discard relocation if `cross_mode_jump_p'
1169 2017-02-23 Alan Modra <amodra@gmail.com>
1172 * elf32-ppc.c (ppc_elf_howto_raw): Correct dst_mask on all VLE
1174 (ppc_elf_vle_split16): Correct field mask and shift for 16D relocs.
1175 (ppc_elf_relocate_section): Correct calculation for VLE SDAREL
1178 2017-02-22 Maciej W. Rozycki <macro@imgtec.com>
1181 * elflink.c (bfd_elf_size_dynamic_sections): Move symbol version
1182 processing ahead of the call to `elf_gc_sweep_symbol'.
1184 2017-02-22 Nick Clifton <nickc@redhat.com>
1187 * opncls.c (bfd_create_gnu_debuglink_section): Give the newly
1188 created section 4-byte alignment.
1190 2017-02-22 Alan Modra <amodra@gmail.com>
1192 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Don't segfault
1193 on .got or .plt output section being discarded by script.
1194 * elf32-ppc.c (ppc_elf_finish_dynamic_sections): Likewise. Move
1197 2017-02-21 Alan Modra <amodra@gmail.com>
1199 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only emit
1200 DT_RELA, DT_RELASZ, and DT_RELAENT when DT_RELASZ is non-zero.
1202 2017-02-20 Alan Modra <amodra@gmail.com>
1205 * elflink.c (bfd_elf_final_link): Make DT_REL/DT_RELA zero
1206 if DT_RELSZ/DT_RELASZ is zero.
1208 2017-02-17 Nick Clifton <nickc@redhat.com>
1210 * compress.c (bfd_get_full_section_contents): Remember to reduce
1211 compressed size by the sizeof the compression header when
1212 decompressing the contents.
1214 2017-02-17 Pedro Alves <palves@redhat.com>
1216 * srec.c (Chunk): Rename to ...
1217 (_bfd_srec_len): ... this.
1218 (S3Forced): Rename to ...
1219 (_bfd_srec_forceS3): ... this.
1220 * objcopy.c: Adjust all references.
1222 2017-02-17 Pedro Alves <palves@redhat.com>
1224 * archive.c (bsd_write_armap): Rename to ...
1225 (_bfd_bsd_write_armap): ... this.
1226 (coff_write_armap): Rename to ...
1227 (_bfd_coff_write_armap): ... this.
1228 * libbfd-in.h (bsd_write_armap): Rename to ...
1229 (_bfd_bsd_write_armap): ... this.
1230 (coff_write_armap): Rename to ...
1231 (_bfd_coff_write_armap): ... this.
1232 * aout-target.h, aout-tic30.c: Adjust all users.
1233 * libbfd.h: Regenerate.
1235 2017-02-17 Pedro Alves <palves@redhat.com>
1237 * bfd-in.h (bfd_read, bfd_write): Adjust to rename.
1238 (warn_deprecated): Rename to ...
1239 (_bfd_warn_deprecated): ... this.
1240 * libbfd.c (warn_deprecated): Rename to ...
1241 (_bfd_warn_deprecated): ... this.
1242 * bfd-in2.h: Regenerate.
1244 2017-02-17 Pedro Alves <palves@redhat.com>
1246 * bfdio.c (real_ftell): Rename to ...
1247 (_bfd_real_ftell): ... this.
1248 (real_fseek): Rename to ...
1249 (_bfd_real_fseek): ... this.
1250 (real_fopen): Rename to ...
1251 (_bfd_real_fopen): ... this.
1252 * libbfd-in.h (real_ftell): Rename to ...
1253 (_bfd_real_ftell): ... this.
1254 (real_fseek): Rename to ...
1255 (_bfd_real_fseek): ... this.
1256 (real_fopen): Rename to ...
1257 (_bfd_real_fopen): ... this.
1258 * cache.c, dwarf2.c, opncls.c: Adjust all callers.
1259 * libbfd.h: Regenerate.
1261 2017-02-17 Pedro Alves <palves@redhat.com>
1263 * dwarf2.c, elf-attrs.c, elf32-nds32.c: Adjust all callers.
1264 * libbfd.c (read_unsigned_leb128): Rename to ...
1265 (_bfd_read_unsigned_leb128): ... this.
1266 (read_signed_leb128): Rename to ...
1267 (_bfd_read_signed_leb128): ... this.
1268 (safe_read_leb128): Rename to ...
1269 (_bfd_safe_read_leb128): ... this.
1270 * libbfd-in.h (read_unsigned_leb128): Rename to ...
1271 (_bfd_read_unsigned_leb128): ... this.
1272 (read_signed_leb128): Rename to ...
1273 (_bfd_read_signed_leb128): ... this.
1274 (safe_read_leb128): Rename to ...
1275 (_bfd_safe_read_leb128): ... this.
1276 * libbfd.h: Renegerate.
1278 2017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
1280 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Perform symbol lookup
1281 before trying to fine matching file and line information.
1283 2017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
1285 * dwarf2.c (struct dwarf2_debug): Add orig_bfd member.
1286 (_bfd_dwarf2_slurp_debug_info): If stashed debug information does
1287 not match current bfd, then reload debug information. Record bfd
1288 we're loading debug info for in the stash. If we have debug
1289 informatin in the cache then perform section placement before
1292 2017-02-16 Alan Modra <amodra@gmail.com>
1295 * elf-bfd.h (struct elf_backend_data): Add no_page_alias.
1296 * elfxx-target.h (elf_backend_no_page_alias): Define.
1297 (elfNN_bed): Init new field.
1298 * elf.c (assign_file_positions_for_load_sections): If no_page_alias
1299 ensure PT_LOAD segment starts on a new page.
1300 * elf32-hppa.c (elf_backend_no_page_alias): Define.
1302 2017-02-16 Alan Modra <amodra@gmail.com>
1305 * elf32-hppa.c (allocate_plt_static): Allocate space for relocs
1308 2017-02-16 Jiong Wang <jiong.wang@arm.com>
1310 * bfd.c (BFD_FLAGS_SAVED): Add BFD_LINKER_CREATED.
1311 * bfd-in2.h: Regenerated.
1313 2017-02-15 H.J. Lu <hongjiu.lu@intel.com>
1316 * elf32-i386.c (elf_i386_relocate_section): Allow
1317 "lea foo@GOT, %reg" in PIC.
1319 2017-02-15 H.J. Lu <hongjiu.lu@intel.com>
1322 * elf32-i386.c (elf_i386_relocate_section): Properly get IFUNC
1323 symbol name when reporting R_386_GOT32/R_386_GOT32X relocation
1324 error against local IFUNC symbol without a base register for
1327 2017-02-15 Maciej W. Rozycki <macro@imgtec.com>
1329 * elf32-ppc.c (ppc_elf_check_relocs): Use `%H:' rather than
1330 `%P: %H:' with `info->callbacks->einfo'.
1331 (ppc_elf_relocate_section): Likewise.
1332 * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
1333 (ppc64_elf_edit_toc): Likewise.
1334 (ppc64_elf_relocate_section): Likewise.
1336 2017-02-14 Alan Modra <amodra@gmail.com>
1338 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Support
1339 --gc-keep-exported, and test versioned field of sym rather than
1340 looking for @ in name.
1342 2017-02-13 Palmer Dabbelt <palmer@dabbelt.com>
1344 * elfnn-riscv.c (riscv_global_pointer_value): Change _gp to
1347 2017-02-13 Nick Clifton <nickc@redhat.com>
1350 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Check for an invalid
1353 2017-02-07 Andrew Waterman <andrew@sifive.com>
1355 * elfnn-riscv.c (riscv_elf_finish_dynamic_sections): Only write PLT
1356 entry size if PLT header is written.
1358 2017-02-06 Sheldon Lobo <sheldon.lobo@oracle.com>
1360 Fix sparc64 dynamic relocation processing to use the dynamic
1362 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Use 'dynamic'
1363 to determine if bfd_get_symcount() or bfd_get_dynamic_symcount()
1366 2017-02-03 Nick Clifton <nickc@redhat.com>
1369 * coffcode.h (coff_write_object_contents): Enlarge size of
1370 s_name_buf in order to avoid compile time warning about possible
1372 * elf32-nds32.c (nds32_elf_ex9_import_table): Mask off lower
1373 32-bits of insn value before printing into buffer.
1375 2017-02-02 Maciej W. Rozycki <macro@imgtec.com>
1377 * elfxx-mips.c (mips_elf_hash_sort_data): Add
1378 `max_local_dynindx'.
1379 (mips_elf_sort_hash_table): Handle it.
1380 (mips_elf_sort_hash_table_f) <GGA_NONE>: For forced local
1381 symbols bump up `max_local_dynindx' rather than
1382 `max_non_got_dynindx'.
1384 2017-02-02 Maciej W. Rozycki <macro@imgtec.com>
1386 * elfxx-mips.c (mips_elf_hash_sort_data): Convert the
1387 `min_got_dynindx', `max_unref_got_dynindx' and
1388 `max_non_got_dynindx' members to the `bfd_size_type' data type.
1389 (mips_elf_sort_hash_table): Adjust accordingly.
1391 2017-02-02 Maciej W. Rozycki <macro@imgtec.com>
1393 * elfxx-mips.c (mips_elf_sort_hash_table): Use `htab' throughout
1394 to access the hash table.
1396 2017-02-02 Maciej W. Rozycki <macro@imgtec.com>
1398 * elfxx-mips.c (mips_elf_sort_hash_table): Move assertion on
1399 non-NULL `htab' to the beginning.
1401 2017-02-02 Maciej W. Rozycki <macro@imgtec.com>
1403 * elflink.c (elf_gc_sweep): Wrap overlong line.
1405 2017-01-30 Maciej W. Rozycki <macro@imgtec.com>
1407 * elfxx-mips.h (_bfd_mips_elf_insn32): Rename prototype to...
1408 (_bfd_mips_elf_linker_flags): ... this. Add another parameter.
1409 * elfxx-mips.c (mips_elf_link_hash_table): Add
1410 `ignore_branch_isa' member.
1411 (mips_elf_perform_relocation): Do not treat an ISA mode mismatch
1412 in branch relocation calculation as an error if
1413 `ignore_branch_isa' has been set.
1414 (_bfd_mips_elf_insn32): Rename to...
1415 (_bfd_mips_elf_linker_flags): ... this. Rename the `on'
1416 parameter to `insn32' and add an `ignore_branch_isa' parameter.
1417 Handle the new parameter.
1419 2017-01-27 Hans-Peter Nilsson <hp@axis.com>
1421 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Remove now unused
1422 local variable dynobj.
1425 * elf32-cris.c (elf_cris_size_dynamic_sections): Handle sdynrelro.
1426 (elf_cris_adjust_dynamic_symbol): Place variables copied into the
1427 executable from read-only sections into sdynrelro.
1428 (elf_cris_finish_dynamic_symbol): Select sreldynrelro for
1429 dynamic relocs in sdynrelro.
1430 (elf_backend_want_dynrelro): Define.
1432 2017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
1434 * config.bfd (*-*-rtemsaout*): Mark as removed.
1436 2017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
1438 * config.bfd (powerpcle-*-rtems*): Do not mark as removed.
1439 (arm-*-rtems*): Move to (arm*-*-eabi*).
1440 (i[3-7]86-*-rtems*): Move to (i[3-7]86-*-elf*).
1441 (m68-*-rtems*): Move to (m68*-*-elf*).
1443 2017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
1445 * config.bfd (*-*-rtemscoff*): Mark as removed.
1447 2017-01-24 Maciej W. Rozycki <macro@imgtec.com>
1450 * elflink.c (bfd_elf_record_link_assignment): Revert last
1451 change and don't ever clear `forced_local'. Set `mark'
1453 (elf_gc_sweep_symbol_info, elf_gc_sweep_symbol): Reorder within
1455 (elf_gc_sweep): Move the call to `elf_gc_sweep_symbol'...
1456 (bfd_elf_size_dynamic_sections): ... here.
1457 * elf32-ppc.c (ppc_elf_tls_setup): Don't clear `forced_local'
1458 and set `mark' instead in `__tls_get_addr_opt' processing.
1459 * elf64-ppc.c (ppc64_elf_tls_setup): Likewise.
1461 2017-01-24 Alan Modra <amodra@gmail.com>
1463 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Merge two cases
1464 where dynamic relocs are preferable. Allow ifunc too.
1465 (ensure_undefweak_dynamic): New function.
1466 (allocate_dynrelocs): Use it here. Move plt handling last and
1467 don't make symbols dynamic, simplifying loop. Only make undef
1468 weak symbols with GOT entries dynamic. Correct condition
1469 for GOT relocs. Handle dynamic relocs on ifuncs. Correct
1470 comments. Remove goto.
1471 (ppc_elf_relocate_section): Correct test for using dynamic
1472 symbol on GOT relocs. Rearrange test for emitting GOT relocs
1473 to suit. Set up explicit tls_index entries and implicit GOT
1474 tls_index entries resolvable at link time for
1475 __tls_get_addr_opt. Simplify test to clear mem for prelink.
1476 * elf64-ppc.c (allocate_got): Correct condition for GOT relocs.
1477 (ensure_undefweak_dynamic): New function.
1478 (allocate_dynrelocs): Use it here. Only make undef weak symbols
1479 with GOT entries dynamic. Remove unnecessary test of
1480 WILL_CALL_FINISH_DYNAMIC_SYMBOL in PLT handling.
1481 (ppc64_elf_relocate_section): Correct test for using dynamic
1482 symbol on GOT relocs. Rearrange test for emitting GOT relocs
1483 to suit. Set up explicit tls_index entries and implicit GOT
1484 tls_index entries resolvable at link time for __tls_get_addr_opt.
1485 Simplify expression to clear mem for prelink.
1487 2017-01-23 Yury Norov <ynorov@caviumnetworks.com>
1489 * elfnn-aarch64.c: Fix relaxations for ILP32 mode.
1491 2017-01-20 Jiong Wang <jiong.wang@arm.com>
1493 * elfnn-aarch64.c (elf_aarch64_hash_symbol): New function.
1494 (elf_backend_hash_symbol): Define.
1496 2017-01-18 Maciej W. Rozycki <macro@imgtec.com>
1499 * elflink.c (bfd_elf_record_link_assignment): Clear any
1500 `forced_local' marking for DSO symbols that are not being
1503 2017-01-17 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1505 * elfnn-riscv.c (riscv_elf_object_p): New function.
1507 2017-01-12 H.J. Lu <hongjiu.lu@intel.com>
1510 * elf64-x86-64.c (elf_x86_64_link_hash_table): Add
1512 (elf_x86_64_check_relocs): Create .eh_frame section for the
1514 (elf_x86_64_size_dynamic_sections): Allocate and initialize
1515 .eh_frame section for the .plt.bnd section.
1516 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
1517 for the .plt.bnd section.
1519 2017-01-12 Nick Clifton <nickc@redhat.com>
1522 * opncls.c (find_separate_debug_file): Add include_dirs
1523 parameter. Only include the directory part of the bfd's filename
1524 in search paths if include_dirs is true. Add a couple of extra
1525 locations for looking for debug files.
1526 ( bfd_follow_gnu_debuglink): Update invocation of
1527 find_separate_debug_file.
1528 (bfd_follow_gnu_debugaltlink): Likewise.
1529 (get_build_id): New function: Finds the build-id of the given bfd.
1530 (get_build_id_name): New function: Computes the name of the
1531 separate debug info file for a bfd, based upon its build-id.
1532 (check_build_id_file): New function: Checks to see if a separate
1533 debug info file exists at the given location, and that its
1534 build-id matches that of the original bfd.
1535 (bfd_follow_build_id_debuglink): New function: Finds a separate
1536 debug info file for a given bfd by using the build-id method.
1537 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Try using the build-id
1538 method of locating a separate debug info file before using the
1540 * bfd-in2.h: Regenerate.
1542 2017-01-11 H.J. Lu <hongjiu.lu@intel.com>
1545 * elf64-x86-64.c (elf_x86_64_eh_frame_bnd_plt): New.
1546 (elf_x86_64_bnd_arch_bed): Use elf_x86_64_eh_frame_bnd_plt and
1547 elf_x86_64_eh_frame_plt_got.
1548 (elf_x86_64_size_dynamic_sections): Get unwind info from
1549 elf_x86_64_bnd_arch_bed for the BND PLT.
1551 2017-01-11 Jeremy Soller <jackpot51@gmail.com>
1553 * config.bfd: Add entries for i686-redox and x86_64-redox.
1555 2017-01-10 H.J. Lu <hongjiu.lu@intel.com>
1557 * elf32-i386.c (elf_i386_check_relocs): Align .eh_frame section
1559 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Align
1560 .eh_frame section to 4 bytes for x32.
1561 (elf_x86_64_check_relocs): Likewise.
1563 2017-01-10 H.J. Lu <hongjiu.lu@intel.com>
1566 * elf32-i386.c (elf_i386_eh_frame_plt_got): New.
1567 (PLT_GOT_FDE_LENGTH): Likewise.
1568 (elf_i386_plt_layout): Add eh_frame_plt_got and
1569 eh_frame_plt_got_size.
1570 (elf_i386_plt): Updated.
1571 (elf_i386_link_hash_table): Add plt_got_eh_frame.
1572 (elf_i386_check_relocs): Create .eh_frame section for .plt.got.
1573 (elf_i386_size_dynamic_sections): Allocate and initialize
1574 .eh_frame section for .plt.got.
1575 (elf_i386_finish_dynamic_sections): Adjust .eh_frame section for
1577 (elf_i386_nacl_plt): Add FIXME for eh_frame_plt_got and
1578 eh_frame_plt_got_size.
1579 * elf64-x86-64.c (elf_x86_64_eh_frame_plt_got): New.
1580 (PLT_GOT_FDE_LENGTH): Likewise.
1581 (elf_x86_64_backend_data): Add eh_frame_plt_got and
1582 eh_frame_plt_got_size.
1583 (elf_x86_64_arch_bed): Updated.
1584 (elf_x86_64_bnd_arch_bed): Add FIXME for eh_frame_plt_got and
1585 eh_frame_plt_got_size.
1586 (elf_x86_64_nacl_arch_bed): Likewise.
1587 (elf_x86_64_link_hash_table): Add plt_got_eh_frame.
1588 (elf_x86_64_check_relocs): Create .eh_frame section for .plt.got.
1589 (elf_x86_64_size_dynamic_sections): Allocate and initialize
1590 .eh_frame section for .plt.got.
1591 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
1594 2017-01-10 H.J. Lu <hongjiu.lu@intel.com>
1596 * elf32-i386.c (elf_i386_size_dynamic_sections): Set
1597 plt_eh_frame->size to eh_frame_plt_size and use eh_frame_plt.
1599 2017-01-09 Nick Clifton <nickc@redhat.com>
1601 * dwarf2.c (lookup_address_in_function_table): Return early if
1602 there are no functions in the given comp unit, or if the high
1603 address of the last function in the comp unit is less than the
1606 2017-01-09 Nick Clifton <nickc@redhat.com>
1609 * coffgen.c (_bfd_coff_get_external_symbols): Generate an error
1610 message if there are too many symbols to load.
1612 2017-01-04 James Clarke <jrtc27@jrtc27.com>
1614 * elf64-alpha.c (elf64_alpha_relax_opt_call): Don't set tsec_free
1615 if relocs are cached.
1617 2017-01-03 Rich Felker <bugdal@aerifal.cx>
1620 * elf32-microblaze.c (microblaze_elf_check_relocs): Add an entry
1621 for R_MICROBLAZE_GOTOFF_64.
1623 2017-01-03 Nick Clifton <nickc@redhat.com>
1625 * mach-o.c (bfd_mach_o_lookup_uuid_command): Fix compile time
1626 warning about using a possibly uninitialised variable.
1628 2017-01-02 Alan Modra <amodra@gmail.com>
1630 * elf32-hppa.c (ensure_undef_weak_dynamic): New function.
1631 (allocate_plt_static, allocate_dynrelocs): Use it.
1633 2017-01-02 Alan Modra <amodra@gmail.com>
1635 * elf-hppa.h (elf_hppa_fake_sections): Set SHF_INFO_LINK for
1636 .PARISC.unwind section.
1638 2017-01-02 Alan Modra <amodra@gmail.com>
1641 * elfxx-sparc.c (gdop_relative_offset_ok): New function.
1642 (_bfd_sparc_elf_relocate_section): Use it to validate GOT
1643 indirect to GOT pointer relative code edit.
1645 2017-01-02 Alan Modra <amodra@gmail.com>
1647 Update year range in copyright notice of all files.
1649 For older changes see ChangeLog-2016
1651 Copyright (C) 2017 Free Software Foundation, Inc.
1653 Copying and distribution of this file, with or without modification,
1654 are permitted in any medium without royalty provided the copyright
1655 notice and this notice are preserved.
1661 version-control: never