Constify elf_backend_eh_frame_address_size
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
76c20d54
AM
12017-04-27 Alan Modra <amodra@gmail.com>
2
3 * elf-bfd.h (struct elf_backend_data): Make asection param of
4 elf_backend_eh_frame_address_size const.
5 (_bfd_elf_eh_frame_address_size): Likewise.
6 * elf32-m32c.c (_bfd_m32c_elf_eh_frame_address_size): Likewise.
7 * elf32-msp430.c (elf32_msp430_eh_frame_address_size): Likewise.
8 * elfxx-mips.c (_bfd_mips_elf_eh_frame_address_size): Likewise.
9 * elfxx-mips.h (_bfd_mips_elf_eh_frame_address_size): Likewise.
10 * elf-eh-frame.c (_bfd_elf_eh_frame_address_size): Likewise.
11 (next_cie_fde_offset): Constify params.
12 (offset_adjust, adjust_eh_frame_local_symbols): Likewise.
13
d7153c4a
AM
142017-04-27 Alan Modra <amodra@gmail.com>
15
16 * elf-bfd.h (struct eh_cie_fde): Add aug_str_len and aug_data_len.
17 (_bfd_elf_adjust_eh_frame_global_symbol): Declare.
18 * elf-eh-frame.c (_bfd_elf_parse_eh_frame): Set aug_str_len and
19 aug_data_len.
20 (offset_adjust): New function.
21 (_bfd_elf_adjust_eh_frame_global_symbol): Likewise.
22 (adjust_eh_frame_local_symbols): Likewise.
23 (_bfd_elf_discard_section_eh_frame): Call adjust_eh_frame_local_symbols
24 after changing anything. Return true if anything changed.
25 * elflink.c (bfd_elf_discard_info): If .eh_frame changed, call
26 _bfd_elf_adjust_eh_frame_global_symbol for globals.
27
641338d8
AM
282017-04-27 Alan Modra <amodra@gmail.com>
29
30 * elflink.c (_bfd_elf_link_hash_hide_symbol): Clear dynstr_index
31 when force_local.
32
21d68fcd
AM
332017-04-27 Alan Modra <amodra@gmail.com>
34
35 * elf32-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
36 (ppc_elf_select_plt_layout, ppc_elf_tls_setup): Use it.
37 (ppc_elf_adjust_dynamic_symbol, allocate_dynrelocs): Likewise.
38 (ppc_elf_relocate_section): Likewise. Delete silly optimisation
39 for undef and undefweak dyn_relocs.
40 * elf64-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
41 (ppc64_elf_adjust_dynamic_symbol, ppc64_elf_tls_setup): Use it.
42 (allocate_got, allocate_dynrelocs): Likewise.
43 (ppc64_elf_relocate_section): Likewise.
44
97d343d4
L
452017-04-26 H.J. Lu <hongjiu.lu@intel.com>
46
47 * elf32-i386.c (elf_i386_size_dynamic_sections): Alwasys add
48 DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rel.plt section.
49 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Alwasys
50 add DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rela.plt section.
51
04b31182
NC
522017-04-26 Nick Clifton <nickc@redhat.com>
53
54 PR binutils/21434
55 * reloc.c (bfd_perform_relocation): Check for a negative address
56 in the reloc.
57
23ec1e32
MR
582017-04-26 Maciej W. Rozycki <macro@imgtec.com>
59
60 PR ld/21334
61 * elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
62 member.
63 * elfxx-target.h [!elf_backend_always_renumber_dynsyms]
64 (elf_backend_always_renumber_dynsyms): Define.
65 (elfNN_bed): Initialize `always_renumber_dynsyms' member.
66 * elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
67 * elflink.c (bfd_elf_size_dynamic_sections): Also call
68 `_bfd_elf_link_renumber_dynsyms' if the backend has requested
69 it.
70 (bfd_elf_size_dynsym_hash_dynstr): Likewise.
71
c46cec3a
MR
722017-04-26 Maciej W. Rozycki <macro@imgtec.com>
73
74 * elflink.c (bfd_elf_size_dynamic_sections): Only call
75 `_bfd_elf_link_renumber_dynsyms' after section GC if dynamic
76 sections have been created.
77
e63d1232
NC
782017-04-26 Nick Clifton <nickc@redhat.com>
79
80 PR binutils/21431
81 * compress.c (bfd_init_section_compress_status): Check the return
82 value from bfd_malloc.
83
9e9821dd
L
842017-04-24 H.J. Lu <hongjiu.lu@intel.com>
85
86 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Add
87 no_finish_dynamic_symbol.
88 (elf_x86_64_link_hash_newfunc): Set no_finish_dynamic_symbol to
89 0.
90 (elf_x86_64_allocate_dynrelocs): If a symbol isn't undefined
91 weak symbol, don't make it dynamic.
92 (elf_x86_64_relocate_section): If a symbol isn't dynamic in PIC,
93 set no_finish_dynamic_symbol and generate R_X86_64_RELATIVE
94 relocation for GOT reference.
95 (elf_x86_64_finish_dynamic_symbol): Abort if
96 no_finish_dynamic_symbol isn't 0.
97
0dc9a308
L
982017-04-24 H.J. Lu <hongjiu.lu@intel.com>
99
100 PR ld/21402
101 * elf32-i386.c (elf_i386_allocate_dynrelocs): If a symbol isn't
102 undefined weak symbol, don't make it dynamic.
103 (elf_i386_relocate_section): If a symbol isn't dynamic in PIC,
104 set no_finish_dynamic_symbol and generate R_386_RELATIVE
105 relocation for R_386_GOT32.
106
1587442d
L
1072017-04-24 H.J. Lu <hongjiu.lu@intel.com>
108
109 PR ld/21425
110 * elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.
111
7eacd66b
AM
1122017-04-23 Alan Modra <amodra@gmail.com>
113
114 PR 21414
115 * section.c (GLOBAL_SYM_INIT): Make available in bfd.h.
116 * elf.c (lcomm_sym): New.
117 (_bfd_elf_large_com_section): Use lcomm_sym section symbol.
118 * bfd-in2.h: Regenerate.
119
bce964aa
AM
1202017-04-23 Alan Modra <amodra@gmail.com>
121
122 PR 21412
123 * elf-bfd.h (struct elf_backend_data <get_reloc_section>): Change
124 parameters and comment.
125 (_bfd_elf_get_reloc_section): Delete.
126 (_bfd_elf_plt_get_reloc_section): Declare.
127 * elf.c (_bfd_elf_plt_get_reloc_section, elf_get_reloc_section):
128 New functions. Don't blindly skip over assumed .rel/.rela prefix.
129 Extracted from..
130 (_bfd_elf_get_reloc_section): ..here. Delete.
131 (assign_section_numbers): Call elf_get_reloc_section.
132 * elf64-ppc.c (elf_backend_get_reloc_section): Define.
133 * elfxx-target.h (elf_backend_get_reloc_section): Update.
134
97e83a10
AM
1352017-04-23 Alan Modra <amodra@gmail.com>
136
137 PR 21409
138 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Don't segfault when
139 no symbols.
140
e133d005
L
1412017-04-21 H.J. Lu <hongjiu.lu@intel.com>
142
143 PR ld/21402
144 * elf32-i386.c (elf_i386_link_hash_entry): Add
145 no_finish_dynamic_symbol.
146 (elf_i386_link_hash_newfunc): Set no_finish_dynamic_symbol to 0.
147 (elf_i386_allocate_dynrelocs): If a symbol isn't undefined weak
148 symbol, don't make it dynamic in PIE.
149 (elf_i386_relocate_section): If a symbol isn't dynamic in PIE,
150 set no_finish_dynamic_symbol and generate R_386_RELATIVE
151 relocation for R_386_GOT32
152 (elf_i386_finish_dynamic_symbol): Abort if no_finish_dynamic_symbol
153 isn't 0.
154
3c5fce9b
L
1552017-04-21 H.J. Lu <hongjiu.lu@intel.com>
156
157 PR ld/19617
158 PR ld/21086
159 * elflink.c (elf_link_add_object_symbols): Require
160 --no-dynamic-linker with -E/--dynamic-list when creating
161 dynamic sections.
162
0fad2956
MR
1632017-04-20 Maciej W. Rozycki <macro@imgtec.com>
164
165 * elflink.c (_bfd_elf_symbol_refs_local_p): Always return TRUE
166 if forced local.
167
64575f78
MR
1682017-04-20 Maciej W. Rozycki <macro@imgtec.com>
169
170 * elfxx-mips.c (_bfd_mips_elf_final_link): Reorder comment about
171 dynamic symbol sorting.
172
59fa66c5
L
1732017-04-20 H.J. Lu <hongjiu.lu@intel.com>
174
175 PR ld/21382
176 * elflink.c (elf_link_add_object_symbols): Preserve
177 dynamic_ref_after_ir_def when restoring the symbol table for
178 unneeded dynamic object.
179
e492d2f8
L
1802017-04-19 H.J. Lu <hongjiu.lu@intel.com>
181
182 PR ld/21401
183 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Don't abort
184 on on undefined IFUNC symbol in the second PLT.
185
10169134
WAF
1862017-04-19 Wedson Almeida Filho <wedsonaf@gmail.com>
187
188 * peXXigen.c (pe_print_reloc): Correct chunk_end.
189
954b63d4
AM
1902017-04-19 Alan Modra <amodra@gmail.com>
191
192 * elflink.c (_bfd_elf_adjust_dynamic_symbol): Hide undefweak
193 or make dynamic for info->dynamic_undefined_weak 0 and 1.
194 * elf32-ppc.c:Formatting.
195 (ensure_undefweak_dynamic): Don't make dynamic when
196 info->dynamic_undefined_weak is zero.
197 (allocate_dynrelocs): Discard undefweak dyn_relocs for
198 info->dynamic_undefined_weak. Discard undef dyn_relocs when
199 not default visibility. Discard undef and undefweak
200 dyn_relocs earlier.
201 (ppc_elf_relocate_section): Adjust to suit.
202 * elf64-ppc.c: Formatting.
203 (ensure_undefweak_dynamic): Don't make dynamic when
204 info->dynamic_undefined_weak is zero.
205 (allocate_dynrelocs): Discard undefweak dyn_relocs for
206 info->dynamic_undefined_weak. Discard them earlier.
207
e6699019
L
2082017-04-17 H.J. Lu <hongjiu.lu@intel.com>
209
210 PR ld/21389
211 * elflink.c (bfd_elf_size_dynamic_sections): Get soname index
212 before generating the version definition section.
213
c5d37467
AM
2142017-04-17 Alan Modra <amodra@gmail.com>
215
216 * elflink.c (_bfd_elf_merge_symbol): Undo dynamic linking
217 state when a regular object file defines a symbol with
218 incompatible type to that defined by an earlier shared lib.
219
63a5468a
AM
2202017-04-13 Alan Modra <amodra@gmail.com>
221
222 * coffcode.h: Wrap some overly long _bfd_error_handler args.
223 * elf.c: Likewise.
224 * elf32-arm.c: Likewise.
225 * elf32-i386.c: Likewise.
226 * elf32-mep.c: Likewise.
227 * elf64-ia64-vms.c: Likewise.
228 * elf64-x86-64.c: Likewise.
229 * elflink.c: Likewise.
230 * elfnn-ia64.c: Likewise.
231 * elfxx-mips.c: Likewise.
232
dae82561
AM
2332017-04-13 Alan Modra <amodra@gmail.com>
234
235 * aoutx.h: Use %B and %A in error messages throughout file.
236 * aout-cris.c: Likewise.
237 * archive.c: Likewise.
238 * binary.c: Likewise.
239 * coff-rs6000.c: Likewise.
240 * coff-tic4x.c: Likewise.
241 * coffcode.h: Likewise.
242 * coffgen.c: Likewise.
243 * cofflink.c: Likewise.
244 * coffswap.h: Likewise.
245 * cpu-arm.c: Likewise.
246 * elf-eh-frame.c: Likewise.
247 * elf-m10300.c: Likewise.
248 * elf.c: Likewise.
249 * elf32-arc.c: Likewise.
250 * elf32-arm.c: Likewise.
251 * elf32-bfin.c: Likewise.
252 * elf32-frv.c: Likewise.
253 * elf32-iq2000.c: Likewise.
254 * elf32-m32c.c: Likewise.
255 * elf32-microblaze.c: Likewise.
256 * elf32-nds32.c: Likewise.
257 * elf32-rl78.c: Likewise.
258 * elf32-rx.c: Likewise.
259 * elf32-score.c: Likewise.
260 * elf32-score7.c: Likewise.
261 * elf32-sh64.c: Likewise.
262 * elf32-v850.c: Likewise.
263 * elf32-vax.c: Likewise.
264 * elf32-visium.c: Likewise.
265 * elf64-ia64-vms.c: Likewise.
266 * elf64-mmix.c: Likewise.
267 * elf64-sh64.c: Likewise.
268 * elfcode.h: Likewise.
269 * elfnn-aarch64.c: Likewise.
270 * elfnn-ia64.c: Likewise.
271 * elfxx-mips.c: Likewise.
272 * hpux-core.c: Likewise.
273 * ieee.c: Likewise.
274 * ihex.c: Likewise.
275 * linker.c: Likewise.
276 * merge.c: Likewise.
277 * mmo.c: Likewise.
278 * oasys.c: Likewise.
279 * pdp11.c: Likewise.
280 * peXXigen.c: Likewise.
281 * rs6000-core.c: Likewise.
282 * vms-alpha.c: Likewise.
283 * xcofflink.c: Likewise.
284
c08bb8dd
AM
2852017-04-13 Alan Modra <amodra@gmail.com>
286
287 * bfd.c (PRINT_TYPE): Define.
288 (_doprnt): New function.
289 (error_handler_internal): Use _doprnt.
290 * coff-arm.c: Put %A and %B arguments to _bfd_error_handler
291 calls in their natural order, throughout file.
292 * coff-mcore.c: Likewise.
293 * coff-ppc.c: Likewise.
294 * coff-tic80.c: Likewise.
295 * cofflink.c: Likewise.
296 * elf-s390-common.c: Likewise.
297 * elf.c: Likewise.
298 * elf32-arm.c: Likewise.
299 * elf32-i386.c: Likewise.
300 * elf32-m32r.c: Likewise.
301 * elf32-msp430.c: Likewise.
302 * elf32-spu.c: Likewise.
303 * elf64-ia64-vms.c: Likewise.
304 * elf64-sparc.c: Likewise.
305 * elf64-x86-64.c: Likewise.
306 * elflink.c: Likewise.
307 * elfnn-aarch64.c: Likewise.
308 * elfnn-ia64.c: Likewise.
309 * elfxx-mips.c: Likewise.
310
10463f39
AM
3112017-04-13 Alan Modra <amodra@gmail.com>
312
313 * elf32-arm.c (arm_type_of_stub): Supply missing args to "long
314 branch veneers" error. Fix double space and format message.
315 * elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
316 * elf64-ppc.c (tocsave_find): Supply missing %B arg.
317
4af8774e
AM
3182017-04-13 Alan Modra <amodra@gmail.com>
319
320 * bfd-in2.h: Regenerate.
321
e4097f5e
L
3222017-04-11 H.J. Lu <hongjiu.lu@intel.com>
323
324 * elf-properties.c (_bfd_elf_parse_gnu_properties): Remove the
325 extra `\n' in warning/error messages.
326 * elf32-i386.c (elf_i386_parse_gnu_properties): Likewise.
327 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
328
537616aa
L
3292017-04-11 H.J. Lu <hongjiu.lu@intel.com>
330
331 * elf-properties.c (_bfd_elf_parse_gnu_properties): Ignore
332 processor-specific properties with generic ELF target vector.
333
bb1dd176
QZ
3342017-04-10 Qing Zhao <qing.zhao@oracle.com>
335
336 * elf32-sparc.c (elf_backend_fixup_symbol): New.
337 * elf64-sparc.c (elf_backend_fixup_symbol): New.
338 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
339 (_bfd_sparc_elf_link_hash_entry): Add has_got_reloc and
340 has_non_got_reloc.
341 (link_hash_newfunc): Initialize has_got_reloc and
342 has_non_got_reloc.
343 (_bfd_sparc_elf_size_dynamic_sections): Set interp to .interp
344 section.
345 (_bfd_sparc_elf_copy_indirect_symbol): Copy has_got_reloc and
346 has_non_got_reloc.
347 (_bfd_sparc_elf_check_relocs): Set has_got_reloc and
348 has_non_got_reloc.
349 (_bfd_sparc_elf_fixup_symbol): New function.
350 (allocate_dynrelocs): Don't allocate space for dynamic
351 relocations and discard relocations against resolved undefined
352 weak symbols in executable. Don't make resolved undefined weak
353 symbols in executable dynamic. Keep dynamic non-GOT/non-PLT
354 relocation against undefined weak symbols in PIE.
355 (_bfd_sparc_elf_relocate_section): Don't generate dynamic
356 relocations against resolved undefined weak symbols in PIE
357 (_bfd_sparc_elf_finish_dynamic_symbol): Keep PLT/GOT entries
358 without ynamic PLT/GOT relocations for resolved undefined weak
359 symbols.
360 Don't generate dynamic relocation against resolved undefined
361 weak symbol in executable.
362 (pie_finish_undefweak_symbol): New function.
363 (_bfd_sparc_elf_finish_dynamic_sections): Call
364 pie_finish_undefweak_symbol on all symbols in PIE.
365 * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Add interp.
366 (_bfd_sparc_elf_fixup_symbol): New function.
367
d236cfd4
NC
3682017-04-10 Nick Clifton <nickc@redhat.com>
369
370 * config.bfd: Remove ns32k from obsolete list.
371
6f9dbcd4
AM
3722017-04-10 Alan Modra <amodra@gmail.com>
373
374 PR 21287
375 * elf.c (special_sections_f): Match .fini_array and .fini_array.*.
376 (special_sections_i): Likewise for .init_array.
377 (special_sections_p): Likewise for .preinit_array.
378
8170f769
L
3792017-04-07 H.J. Lu <hongjiu.lu@intel.com>
380
381 PR ld/19579
382 PR ld/21306
383 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
384 ELF_COMMON_DEF_P for common symbols.
385 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
386 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
387 * elflink.c (_bfd_elf_merge_symbol): Revert commits
388 202ac193bbbecc96a4978d1ac3d17148253f9b01 and
389 07492f668d2173da7a2bda3707ff0985e0f460b6.
390
49f4617b
PA
3912017-04-07 Pedro Alves <palves@redhat.com>
392
393 * opncls.c (bfd_get_debug_link_info): Rename to...
394 (bfd_get_debug_link_info_1): ... this. Change type of second
395 parameter to void pointer. Adjust.
396 (bfd_get_debug_link_info): Reimplement on top of
397 bfd_get_debug_link_info_1.
398 (separate_debug_file_exists, separate_alt_debug_file_exists):
399 Change type of second parameter to void pointer. Adjust.
400 (get_func_type, check_func_type): Change type of second parameter
401 to void pointer.
402 (find_separate_debug_file): Add 'func_data' parameter. Pass it to
403 the callback functions instead of passing the address of a local.
404 (bfd_follow_gnu_debuglink): Pass address of unsigned long local to
405 find_separate_debug_file.
406 (get_alt_debug_link_info_shim): Change type of second parameter to
407 void pointer. Adjust.
408 (bfd_follow_gnu_debugaltlink): Adjust to pass NULL to
409 find_separate_debug_file.
410 (get_build_id_name, bfd_boolean check_build_id_file): Change type
411 of second parameter to void pointer. Adjust.
412 (bfd_follow_build_id_debuglink): Pass address of bfd_build_id
413 pointer local to find_separate_debug_file.
414
4152017-04-07 Tristan Gingold <gingold@gingold-Precision-7510>
1fd6d111
TG
416
417 * coffgen.c (_bfd_coff_gc_mark_hook): Handle PE weak
418 external symbols with a definition.
419 (_bfd_coff_gc_mark_extra_sections): Fix typo.
420
86abf93a
AM
4212017-04-07 Alan Modra <amodra@gmail.com>
422
423 * po/SRC-POTFILES.in: Regenerate.
424
8dea77f0
AM
4252017-04-05 Alan Modra <amodra@gmail.com>
426
427 * elf64-ppc.c (ppc64_elf_gc_sweep_hook): Support ELFv2 PLT
428 reference counting.
429
477bdd39
JT
4302017-04-02 Jon Turney <jon.turney@dronecode.org.uk>
431
432 (_bfd_XXi_swap_aouthdr_out): For clarity, use defines rather than
433 numbers for DataDirectory entry indicies passed to
434 add_data_entry().
435
a91e1603
L
4362017-04-04 H.J. Lu <hongjiu.lu@intel.com>
437
438 * elf.c (get_program_header_size): Add a GNU_MBIND segment for
439 each GNU_MBIND section and align GNU_MBIND section to page size.
440 (_bfd_elf_map_sections_to_segments): Create a GNU_MBIND
441 segment for each GNU_MBIND section.
442 (_bfd_elf_init_private_section_data): Copy sh_info from input
443 for GNU_MBIND section.
444
b5292032
PD
4452017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
446
447 * elfnn-riscv.c (GP_NAME): Delete.
448 (riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
449 (_bfd_riscv_relax_lui): Likewise.
450
ad32986f
NC
4512017-04-04 Nick Clifton <nickc@redhat.com>
452
453 PR binutils/21342
454 * elflink.c (_bfd_elf_define_linkage_sym): Prevent null pointer
455 dereference.
456 (bfd_elf_final_link): Only initialize the extended symbol index
457 section if there are extended symbol tables to list.
458
46bed679
L
4592017-04-03 H.J. Lu <hongjiu.lu@intel.com>
460
461 * Makefile.am (BFD32_BACKENDS): Add elf-properties.lo.
462 (BFD32_BACKENDS_CFILES): Add elf-properties.c.
463 * configure.ac (elf): Add elf-properties.lo.
464 * Makefile.in: Regenerated.
465 * configure: Likewise.
466 * elf-bfd.h (elf_property_kind): New.
467 (elf_property): Likewise.
468 (elf_property_list): Likewise.
469 (elf_properties): Likewise.
470 (_bfd_elf_parse_gnu_properties): Likewise.
471 (_bfd_elf_get_property): Likewise.
472 (_bfd_elf_link_setup_gnu_properties): Likewise.
473 (elf_backend_data): Add parse_gnu_properties, merge_gnu_properties
474 and setup_gnu_properties.
475 (elf_obj_tdata): Add properties.
476 * elf-properties.c: New file.
477 * elf32-i386.c (elf_i386_parse_gnu_properties): New.
478 (elf_i386_merge_gnu_properties): Likewise.
479 (elf_backend_parse_gnu_properties): Likewise.
480 (elf_backend_merge_gnu_properties): Likewise.
481 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
482 (elf_x86_64_merge_gnu_properties): Likewise.
483 (elf_backend_parse_gnu_properties): Likewise.
484 (elf_backend_merge_gnu_properties): Likewise.
485 * elfxx-target.h (elf_backend_merge_gnu_properties): Likewise.
486 (elf_backend_parse_gnu_properties): Likewise.
487 (elf_backend_setup_gnu_properties): Likewise.
488 (elfNN_bed): Add elf_backend_parse_gnu_properties,
489 elf_backend_merge_gnu_properties and
490 elf_backend_setup_gnu_properties.
491
f96bd6c2
PC
4922017-03-30 Pip Cet <pipcet@gmail.com>
493
494 * elf32-wasm32.c: Add relocation code, two relocs.
495 * reloc.c: Add wasm32 relocations.
496 * libbfd.h: Regenerate.
497 * bfd-in2.h: Regenerate.
498 * bfd/po/bfd.pot: Regenerate.
499
e643cb45
NC
5002017-03-29 Nick Clifton <nickc@redhat.com>
501
502 PR binutils/18025
503 * coff-bfd.h (struct coff_section_data): Add new fields:
504 saved_bias and bias.
505 * coffgen.c (coff_find_nearest_line_with_names): Cache the bias
506 computed for PE binaries.
507 * dwarf2.c (scan_unit_for_symbols): Only warn once about each
508 missing abbrev.
509
086554e8
HPN
5102017-03-28 Hans-Peter Nilsson <hp@axis.com>
511
512 PR ld/16044
513 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Adjust BFD_ASSERT
514 to handle a local symbol with a hash-symbol-entry; without PLT.
515 Add BFD_ASSERT for an incidental case with GOT entry present.
516 (cris_elf_check_relocs): Increment PLT refcount only if the symbol
517 isn't forced-or-set local.
518
a6be0538
PC
5192017-03-27 Pip Cet <pipcet@gmail.com>
520
521 * wasm-module.c: New file to support WebAssembly modules.
522 * wasm-module.h: New file to support WebAssembly modules.
523 * doc/webassembly.texi: Start documenting wasm-module.c.
524 * config.bfd: Add wasm_vec.
525 * targets.c: Likewise.
526 * configure.ac: Likewise.
527 * Makefile.am: Add entries for wasm-module.c.
528 * Makefile.in: Regenerate.
529 * configure: Regenerate.
530 * po/SRC-POTFILES.in: Regenerate.
531
79b1d3cb
PC
5322017-03-27 Pip Cet <pipcet@gmail.com>
533
534 * cpu-wasm32.c: New file to support wasm32 architecture.
535 * elf32-wasm32.c: New file to support wasm32 architecture.
536 * Makefile.am: Add wasm32 architecture.
537 * archures.c: Likewise.
538 * config.bfd: Likewise.
539 * configure.ac: Likewise.
540 * targets.c: Likewise.
541 * Makefile.in: Regenerate.
542 * bfd-in2.h: Regenerate.
543 * configure: Regenerate.
544 * po/SRC-POTFILES.in: Regenerate.
545
aaed6f5b
AM
5462017-03-20 Alan Modra <amodra@gmail.com>
547
548 PR 21266
549 * elf64-ppc.c (compare_symbols): Stabilize sort.
550
82e66161
AM
5512017-03-18 Alan Modra <amodra@gmail.com>
552
553 * elf64-ppc.c (struct ppc_link_hash_table): Add
554 local_ifunc_resolver and maybe_local_ifunc_resolver.
555 (ppc_build_one_stub): Set flags on emitting dynamic
556 relocation to ifunc.
557 (ppc64_elf_relocate_section): Likewise.
558 (ppc64_elf_finish_dynamic_symbol): Likewise.
559 (ppc64_elf_finish_dynamic_sections): Error on DT_TEXTREL with
560 local dynamic relocs to ifuncs.
561 * elf32-ppc.c (struct ppc_elf_link_hash_table): Add
562 local_ifunc_resolver and maybe_local_ifunc_resolver.
563 (ppc_elf_relocate_section): Set flag on emitting dynamic
564 relocation to ifuncs.
565 (ppc_elf_finish_dynamic_symbol): Likewise.
566 (ppc_elf_finish_dynamic_sections): Error on DT_TEXTREL with local
567 dynamic relocs to ifuncs.
568
f955cccf
NC
5692017-03-13 Nick Clifton <nickc@redhat.com>
570
571 PR binutils/21202
572 * reloc.c (BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC): Rename to
573 BFD_RELOC_AARCH64_TLSDESC_LD64_LO12.
574 (BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC): Rename to
575 BFD_RELOC_AARCH64_TLSDESC_ADD_LO12.
576 * bfd-in2.h: Regenerate.
577 * libbfd.h: Regenerate.
578 * elfnn-aarch64.c (IS_AARCH64_TLS_RELAX_RELOC): Update reloc
579 names.
580 (IS_AARCH64_TLSDESC_RELOC): Likewise.
581 (elfNN_aarch64_howto_table): Likewise.
582 (aarch64_tls_transition_without_check): Likewise.
583 (aarch64_reloc_got_type): Likewise.
584 (elfNN_aarch64_final_link_relocate): Likewise.
585 (elfNN_aarch64_tls_relax): Likewise.
586 (elfNN_aarch64_relocate_section): Likewise.
587 (elfNN_aarch64_gc_sweep_hook): Likewise.
588 (elfNN_aarch64_check_relocs): Likewise.
589 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
590 (_bfd_aarch64_elf_resolve_relocation): Likewise.
591
4aef7643
AM
5922017-03-11 Alan Modra <amodra@gmail.com>
593
594 * elf32-ppc.c: Remove ATTRIBUTE_UNUSED throughout when function
595 parameter is in fact used. Whitespace fixes.
596 * elf64-ppc.c: Likewise.
597
f03265d9
ST
5982017-03-09 Sam Thursfield <sam.thursfield@codethink.co.uk>
599
600 * rs6000-core.c (CORE_NEW): Simplify macro when
601 AIX_CORE_DUMPX_CORE and BFD64 are true to avoid compile warning.
602
b1b07054
AM
6032017-03-07 Alan Modra <amodra@gmail.com>
604
605 PR 21224
606 PR 20519
607 * elf64-ppc.c (ppc64_elf_relocate_section): Add missing
608 dyn_relocs check.
609
2e0ce1c8
AM
6102017-03-05 Alan Modra <amodra@gmail.com>
611
612 * elf-bfd.h (struct eh_cie_fde): Add u.cie.per_encoding_aligned8.
613 * elf-eh-frame.c (size_of_output_cie_fde): Don't align here.
614 (next_cie_fde_offset): New function.
615 (_bfd_elf_parse_eh_frame): Set u.cie.per_encoding_aligned8.
616 (_bfd_elf_discard_section_eh_frame): Align zero terminator to
617 four bytes. Align CIEs to four or eight bytes depending on
618 per_encoding_aligned8. Align FDEs according to their encoding.
619 Pad last FDE to output section alignment.
620 (_bfd_elf_write_section_eh_frame): Adjust to suit. Remove
621 assertion.
622 * elf64-ppc.c (glink_eh_frame_cie): Delete padding.
623 (ppc64_elf_size_stubs): Pad glink eh_frame as per elf-eh-frame.c.
624 (ppc64_elf_finish_dynamic_sections): Adjust to suit.
625
f98450c6
NC
6262017-03-02 Martin Bickel <binutils@ineranves.de>
627
628 PR ld/21212
629 * elf.c (rewrite_elf_program_header): Do not issue a warning for
d20928fa 630 empty segments which have a zero filesz, but a non-zero memsz.
f98450c6 631
673cff9b
AM
6322017-03-02 Alan Modra <amodra@gmail.com>
633
634 * elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.
635
3de43e7b
AM
6362017-02-28 Alan Modra <amodra@gmail.com>
637
638 * elf64-ppc.c (ppc64_elf_ha_reloc): Revert last change.
639 (ppc64_elf_relocate_section): Likewise.
640
4ef97a1b
AM
6412017-02-28 Alan Modra <amodra@gmail.com>
642
643 PR 20995
644 * elf32-nios2.c (nios2_elf32_relocate_section): Use htab
645 rather than elf32_nios2_hash_table or elf_hash_table.
646 (create_got_section): Likewise.
647 (nios2_elf32_finish_dynamic_symbol): Likewise.
648 (nios2_elf32_adjust_dynamic_symbol): Likewise.
649 (nios2_elf32_size_dynamic_sections): Likewise.
650 (nios2_elf32_check_relocs): Delete dynobj, sgot, and srelgot
651 vars. Use htab equivalents directly instead. Don't create
652 all dynamic sections on needing just the GOT. Use a goto
653 rather than a fall-through with reloc test. Ensure
654 htab->dynobj is set when making dynamic sreloc section.
655 (nios2_elf32_finish_dynamic_sections): Delete dynobj, use htab
656 equivalent directly instead. Don't segfault on looking for
657 .dynamic when dynamic sections have not been created. Don't
658 segfault on .got.plt being discarded.
659 (nios2_elf32_size_dynamic_sections): Delete plt and got vars.
660 Don't set "relocs" on .rela.plt. Do handle .sbss. Delete
661 fixme and another not so relevant comment.
662 (nios2_elf_add_symbol_hook): Delete dynobj var. If not
663 already set, set hash table dynobj on creating .sbss.
664
7ba71655
AM
6652017-02-28 Alan Modra <amodra@gmail.com>
666
667 * reloc.c (BFD_RELOC_PPC_16DX_HA): New.
668 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_16DX_HA>): New howto.
669 (ppc64_elf_reloc_type_lookup): Translate new bfd reloc.
670 (ppc64_elf_ha_reloc): Correct overflow test on REL16DX_HA.
671 (ppc64_elf_relocate_section): Likewise.
672 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_16DX_HA>): New howto.
673 (ppc_elf_reloc_type_lookup): Translate new bfd reloc.
674 (ppc_elf_check_relocs): Handle R_PPC_16DX_HA to pacify gcc.
675 * libbfd.h: Regenerate.
676 * bfd-in2.h: Regenerate.
677
afbf7e8e
AM
6782017-02-28 Alan Modra <amodra@gmail.com>
679
680 * elflink.c (_bfd_elf_create_dynamic_sections): Don't make
681 dynamic .data.rel.ro read-only.
682 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Compare section
683 rather than section flags when deciding where copy reloc goes.
684 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
685 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
686 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Likewise.
687 * elf32-metag.c (elf_metag_finish_dynamic_symbol): Likewise.
688 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Likewise.
689 * elf32-nios2.c (nios2_elf32_finish_dynamic_symbol): Likewise.
690 * elf32-or1k.c (or1k_elf_finish_dynamic_symbol): Likewise.
691 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Likewise.
692 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
693 * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
694 * elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
695 * elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Likewise.
696 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
697 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
698 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Likewise.
699 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Likewise.
700 * elfxx-mips.c (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
701 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
702 * elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
703
0e392101
MR
7042017-02-28 Maciej W. Rozycki <macro@imgtec.com>
705
706 * elfxx-mips.c (mips_elf_perform_relocation): Also handle the
707 `jalr $0, $25' instruction encoding.
708
bd757ca7
NC
7092017-02-27 Nick Clifton <nickc@redhat.com>
710
711 PR ld/21180
712 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Avoid
713 generating a seg-fault when encountering a symbol that has been
714 deleted by garbage collection.
715
034fed0b
AM
7162017-02-25 Alan Modra <amodra@gmail.com>
717
718 * elf32-arc.c (struct dynamic_sections): Delete.
719 (enum dyn_section_types): Delete.
720 (dyn_section_names): Delete.
721 (arc_create_dynamic_sections): Delete.
722 (elf_arc_finish_dynamic_sections): Don't call the above. Don't
723 segfault on discarded .rela.plt section.
724 (elf_arc_size_dynamic_sections): Formatting. Don't call
725 arc_create_dynamic_sections. Don't allocate memory for sections
726 handled by the generic linker. Correct code finding relocs in
727 read-only sections. Set SEC_EXCLUDE on zero size .got,
728 .got.plt, and .dynbss sections. Do set .interp for pies.
729
d0f744f9
AW
7302017-02-24 Andrew Waterman <andrew@sifive.com>
731
732 * elfnn-riscv.c (GP_NAME): New macro.
733 (riscv_global_pointer_value): Use it.
734 (_bfd_riscv_relax_lui): If symbol and global pointer are in same
735 output section, consider only that section's alignment.
736
5d58c733
MR
7372017-02-23 Maciej W. Rozycki <macro@imgtec.com>
738
739 * elfxx-mips.h (_bfd_mips_relax_section): Remove prototype.
740 * elfxx-mips.c (_bfd_mips_relax_section): Remove function.
741 * elf64-mips.c (bfd_elf64_bfd_relax_section): Remove macro.
742 * elfn32-mips.c (bfd_elf32_bfd_relax_section): Likewise.
743
c1556ecd
MR
7442017-02-23 Maciej W. Rozycki <macro@imgtec.com>
745
746 * elfxx-mips.c (mips_elf_calculate_relocation) <R_MIPS_JALR>
747 <R_MICROMIPS_JALR>: Discard relocation if `cross_mode_jump_p'
748 or misaligned.
749
5499c7c7
AM
7502017-02-23 Alan Modra <amodra@gmail.com>
751
752 PR 20744
753 * elf32-ppc.c (ppc_elf_howto_raw): Correct dst_mask on all VLE
754 16D relocations.
755 (ppc_elf_vle_split16): Correct field mask and shift for 16D relocs.
756 (ppc_elf_relocate_section): Correct calculation for VLE SDAREL
757 relocs.
758
902e9fc7
MR
7592017-02-22 Maciej W. Rozycki <macro@imgtec.com>
760
761 PR ld/20828
762 * elflink.c (bfd_elf_size_dynamic_sections): Move symbol version
763 processing ahead of the call to `elf_gc_sweep_symbol'.
764
758d96d8
NC
7652017-02-22 Nick Clifton <nickc@redhat.com>
766
767 PR binutils/21193
768 * opncls.c (bfd_create_gnu_debuglink_section): Give the newly
769 created section 4-byte alignment.
770
6528b6eb
AM
7712017-02-22 Alan Modra <amodra@gmail.com>
772
773 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Don't segfault
774 on .got or .plt output section being discarded by script.
775 * elf32-ppc.c (ppc_elf_finish_dynamic_sections): Likewise. Move
776 vxworks splt temp.
777
24f1a751
AM
7782017-02-21 Alan Modra <amodra@gmail.com>
779
780 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only emit
781 DT_RELA, DT_RELASZ, and DT_RELAENT when DT_RELASZ is non-zero.
782
64487780
AM
7832017-02-20 Alan Modra <amodra@gmail.com>
784
785 PR 21181
786 * elflink.c (bfd_elf_final_link): Make DT_REL/DT_RELA zero
787 if DT_RELSZ/DT_RELASZ is zero.
788
6438d1be
NC
7892017-02-17 Nick Clifton <nickc@redhat.com>
790
791 * compress.c (bfd_get_full_section_contents): Remember to reduce
792 compressed size by the sizeof the compression header when
793 decompressing the contents.
794
4bc26c69
PA
7952017-02-17 Pedro Alves <palves@redhat.com>
796
797 * srec.c (Chunk): Rename to ...
798 (_bfd_srec_len): ... this.
799 (S3Forced): Rename to ...
800 (_bfd_srec_forceS3): ... this.
801 * objcopy.c: Adjust all references.
802
7ec22e0f
PA
8032017-02-17 Pedro Alves <palves@redhat.com>
804
805 * archive.c (bsd_write_armap): Rename to ...
806 (_bfd_bsd_write_armap): ... this.
807 (coff_write_armap): Rename to ...
808 (_bfd_coff_write_armap): ... this.
809 * libbfd-in.h (bsd_write_armap): Rename to ...
810 (_bfd_bsd_write_armap): ... this.
811 (coff_write_armap): Rename to ...
812 (_bfd_coff_write_armap): ... this.
813 * aout-target.h, aout-tic30.c: Adjust all users.
814 * libbfd.h: Regenerate.
815
8c8402cc
PA
8162017-02-17 Pedro Alves <palves@redhat.com>
817
818 * bfd-in.h (bfd_read, bfd_write): Adjust to rename.
819 (warn_deprecated): Rename to ...
820 (_bfd_warn_deprecated): ... this.
821 * libbfd.c (warn_deprecated): Rename to ...
822 (_bfd_warn_deprecated): ... this.
823 * bfd-in2.h: Regenerate.
824
c7c3d11b
PA
8252017-02-17 Pedro Alves <palves@redhat.com>
826
827 * bfdio.c (real_ftell): Rename to ...
828 (_bfd_real_ftell): ... this.
829 (real_fseek): Rename to ...
830 (_bfd_real_fseek): ... this.
831 (real_fopen): Rename to ...
832 (_bfd_real_fopen): ... this.
833 * libbfd-in.h (real_ftell): Rename to ...
834 (_bfd_real_ftell): ... this.
835 (real_fseek): Rename to ...
836 (_bfd_real_fseek): ... this.
837 (real_fopen): Rename to ...
838 (_bfd_real_fopen): ... this.
839 * cache.c, dwarf2.c, opncls.c: Adjust all callers.
840 * libbfd.h: Regenerate.
841
4265548c
PA
8422017-02-17 Pedro Alves <palves@redhat.com>
843
844 * dwarf2.c, elf-attrs.c, elf32-nds32.c: Adjust all callers.
845 * libbfd.c (read_unsigned_leb128): Rename to ...
846 (_bfd_read_unsigned_leb128): ... this.
847 (read_signed_leb128): Rename to ...
848 (_bfd_read_signed_leb128): ... this.
849 (safe_read_leb128): Rename to ...
850 (_bfd_safe_read_leb128): ... this.
851 * libbfd-in.h (read_unsigned_leb128): Rename to ...
852 (_bfd_read_unsigned_leb128): ... this.
853 (read_signed_leb128): Rename to ...
854 (_bfd_read_signed_leb128): ... this.
855 (safe_read_leb128): Rename to ...
856 (_bfd_safe_read_leb128): ... this.
857 * libbfd.h: Renegerate.
858
3239a423
AB
8592017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
860
861 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Perform symbol lookup
862 before trying to fine matching file and line information.
863
90ed9b8b
AB
8642017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
865
866 * dwarf2.c (struct dwarf2_debug): Add orig_bfd member.
867 (_bfd_dwarf2_slurp_debug_info): If stashed debug information does
868 not match current bfd, then reload debug information. Record bfd
869 we're loading debug info for in the stash. If we have debug
870 informatin in the cache then perform section placement before
871 returning.
872
a8c75b76
AM
8732017-02-16 Alan Modra <amodra@gmail.com>
874
875 PR 21000
876 * elf-bfd.h (struct elf_backend_data): Add no_page_alias.
877 * elfxx-target.h (elf_backend_no_page_alias): Define.
878 (elfNN_bed): Init new field.
879 * elf.c (assign_file_positions_for_load_sections): If no_page_alias
880 ensure PT_LOAD segment starts on a new page.
881 * elf32-hppa.c (elf_backend_no_page_alias): Define.
882
247d6c4c
AM
8832017-02-16 Alan Modra <amodra@gmail.com>
884
885 PR 21132
886 * elf32-hppa.c (allocate_plt_static): Allocate space for relocs
887 if pic.
888
90571206
JW
8892017-02-16 Jiong Wang <jiong.wang@arm.com>
890
891 * bfd.c (BFD_FLAGS_SAVED): Add BFD_LINKER_CREATED.
892 * bfd-in2.h: Regenerated.
893
2a568401
L
8942017-02-15 H.J. Lu <hongjiu.lu@intel.com>
895
896 PR ld/21168
897 * elf32-i386.c (elf_i386_relocate_section): Allow
898 "lea foo@GOT, %reg" in PIC.
899
a5def14f
L
9002017-02-15 H.J. Lu <hongjiu.lu@intel.com>
901
902 PR ld/20244
903 * elf32-i386.c (elf_i386_relocate_section): Properly get IFUNC
904 symbol name when reporting R_386_GOT32/R_386_GOT32X relocation
905 error against local IFUNC symbol without a base register for
906 PIC.
907
174d0a74
MR
9082017-02-15 Maciej W. Rozycki <macro@imgtec.com>
909
910 * elf32-ppc.c (ppc_elf_check_relocs): Use `%H:' rather than
911 `%P: %H:' with `info->callbacks->einfo'.
912 (ppc_elf_relocate_section): Likewise.
913 * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
914 (ppc64_elf_edit_toc): Likewise.
915 (ppc64_elf_relocate_section): Likewise.
916
e278ae05
AM
9172017-02-14 Alan Modra <amodra@gmail.com>
918
919 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Support
920 --gc-keep-exported, and test versioned field of sym rather than
921 looking for @ in name.
922
10ddfe62
PD
9232017-02-13 Palmer Dabbelt <palmer@dabbelt.com>
924
925 * elfnn-riscv.c (riscv_global_pointer_value): Change _gp to
926 __global_pointer$.
927
d11135f5
NC
9282017-02-13 Nick Clifton <nickc@redhat.com>
929
930 PR binutils/21151
931 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Check for an invalid
932 unit length field.
933
cc162427
AW
9342017-02-07 Andrew Waterman <andrew@sifive.com>
935
936 * elfnn-riscv.c (riscv_elf_finish_dynamic_sections): Only write PLT
937 entry size if PLT header is written.
938
3d044c0c
SL
9392017-02-06 Sheldon Lobo <sheldon.lobo@oracle.com>
940
941 Fix sparc64 dynamic relocation processing to use the dynamic
942 symbol count.
943 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Use 'dynamic'
944 to determine if bfd_get_symcount() or bfd_get_dynamic_symcount()
945 should be used.
946
1b7e3d2f
NC
9472017-02-03 Nick Clifton <nickc@redhat.com>
948
949 PR 21096
950 * coffcode.h (coff_write_object_contents): Enlarge size of
951 s_name_buf in order to avoid compile time warning about possible
952 integer truncation.
953 * elf32-nds32.c (nds32_elf_ex9_import_table): Mask off lower
954 32-bits of insn value before printing into buffer.
955
e17b0c35
MR
9562017-02-02 Maciej W. Rozycki <macro@imgtec.com>
957
958 * elfxx-mips.c (mips_elf_hash_sort_data): Add
959 `max_local_dynindx'.
960 (mips_elf_sort_hash_table): Handle it.
961 (mips_elf_sort_hash_table_f) <GGA_NONE>: For forced local
962 symbols bump up `max_local_dynindx' rather than
963 `max_non_got_dynindx'.
964
55f8b9d2
MR
9652017-02-02 Maciej W. Rozycki <macro@imgtec.com>
966
967 * elfxx-mips.c (mips_elf_hash_sort_data): Convert the
968 `min_got_dynindx', `max_unref_got_dynindx' and
969 `max_non_got_dynindx' members to the `bfd_size_type' data type.
970 (mips_elf_sort_hash_table): Adjust accordingly.
971
0f8c4b60
MR
9722017-02-02 Maciej W. Rozycki <macro@imgtec.com>
973
974 * elfxx-mips.c (mips_elf_sort_hash_table): Use `htab' throughout
975 to access the hash table.
976
17a80fa8
MR
9772017-02-02 Maciej W. Rozycki <macro@imgtec.com>
978
979 * elfxx-mips.c (mips_elf_sort_hash_table): Move assertion on
980 non-NULL `htab' to the beginning.
981
8f56d4fd
MR
9822017-02-02 Maciej W. Rozycki <macro@imgtec.com>
983
984 * elflink.c (elf_gc_sweep): Wrap overlong line.
985
8b10b0b3
MR
9862017-01-30 Maciej W. Rozycki <macro@imgtec.com>
987
988 * elfxx-mips.h (_bfd_mips_elf_insn32): Rename prototype to...
989 (_bfd_mips_elf_linker_flags): ... this. Add another parameter.
990 * elfxx-mips.c (mips_elf_link_hash_table): Add
991 `ignore_branch_isa' member.
992 (mips_elf_perform_relocation): Do not treat an ISA mode mismatch
993 in branch relocation calculation as an error if
994 `ignore_branch_isa' has been set.
995 (_bfd_mips_elf_insn32): Rename to...
996 (_bfd_mips_elf_linker_flags): ... this. Rename the `on'
997 parameter to `insn32' and add an `ignore_branch_isa' parameter.
998 Handle the new parameter.
999
1fbd05e1
HPN
10002017-01-27 Hans-Peter Nilsson <hp@axis.com>
1001
22d9a0de
HPN
1002 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Remove now unused
1003 local variable dynobj.
1004
1fbd05e1
HPN
1005 PR ld/20995
1006 * elf32-cris.c (elf_cris_size_dynamic_sections): Handle sdynrelro.
1007 (elf_cris_adjust_dynamic_symbol): Place variables copied into the
1008 executable from read-only sections into sdynrelro.
1009 (elf_cris_finish_dynamic_symbol): Select sreldynrelro for
1010 dynamic relocs in sdynrelro.
1011 (elf_backend_want_dynrelro): Define.
1012
4a7324e1
SH
10132017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
1014
1015 * config.bfd (*-*-rtemsaout*): Mark as removed.
1016
c75b4ebd
SH
10172017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
1018
1019 * config.bfd (powerpcle-*-rtems*): Do not mark as removed.
1020 (arm-*-rtems*): Move to (arm*-*-eabi*).
1021 (i[3-7]86-*-rtems*): Move to (i[3-7]86-*-elf*).
1022 (m68-*-rtems*): Move to (m68*-*-elf*).
1023
850d84f6
SH
10242017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
1025
1026 * config.bfd (*-*-rtemscoff*): Mark as removed.
1027
b531344c
MR
10282017-01-24 Maciej W. Rozycki <macro@imgtec.com>
1029
1030 PR ld/20828
1031 * elflink.c (bfd_elf_record_link_assignment): Revert last
1032 change and don't ever clear `forced_local'. Set `mark'
1033 unconditionally.
1034 (elf_gc_sweep_symbol_info, elf_gc_sweep_symbol): Reorder within
1035 file.
1036 (elf_gc_sweep): Move the call to `elf_gc_sweep_symbol'...
1037 (bfd_elf_size_dynamic_sections): ... here.
1038 * elf32-ppc.c (ppc_elf_tls_setup): Don't clear `forced_local'
1039 and set `mark' instead in `__tls_get_addr_opt' processing.
1040 * elf64-ppc.c (ppc64_elf_tls_setup): Likewise.
1041
f0158f44
AM
10422017-01-24 Alan Modra <amodra@gmail.com>
1043
1044 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Merge two cases
1045 where dynamic relocs are preferable. Allow ifunc too.
1046 (ensure_undefweak_dynamic): New function.
1047 (allocate_dynrelocs): Use it here. Move plt handling last and
1048 don't make symbols dynamic, simplifying loop. Only make undef
1049 weak symbols with GOT entries dynamic. Correct condition
1050 for GOT relocs. Handle dynamic relocs on ifuncs. Correct
1051 comments. Remove goto.
1052 (ppc_elf_relocate_section): Correct test for using dynamic
1053 symbol on GOT relocs. Rearrange test for emitting GOT relocs
1054 to suit. Set up explicit tls_index entries and implicit GOT
1055 tls_index entries resolvable at link time for
1056 __tls_get_addr_opt. Simplify test to clear mem for prelink.
1057 * elf64-ppc.c (allocate_got): Correct condition for GOT relocs.
1058 (ensure_undefweak_dynamic): New function.
1059 (allocate_dynrelocs): Use it here. Only make undef weak symbols
1060 with GOT entries dynamic. Remove unnecessary test of
1061 WILL_CALL_FINISH_DYNAMIC_SYMBOL in PLT handling.
1062 (ppc64_elf_relocate_section): Correct test for using dynamic
1063 symbol on GOT relocs. Rearrange test for emitting GOT relocs
1064 to suit. Set up explicit tls_index entries and implicit GOT
1065 tls_index entries resolvable at link time for __tls_get_addr_opt.
1066 Simplify expression to clear mem for prelink.
1067
2d0ca824
YN
10682017-01-23 Yury Norov <ynorov@caviumnetworks.com>
1069
1070 * elfnn-aarch64.c: Fix relaxations for ILP32 mode.
1071
7f784814
JW
10722017-01-20 Jiong Wang <jiong.wang@arm.com>
1073
1074 * elfnn-aarch64.c (elf_aarch64_hash_symbol): New function.
1075 (elf_backend_hash_symbol): Define.
1076
81ff47b3
MR
10772017-01-18 Maciej W. Rozycki <macro@imgtec.com>
1078
1079 PR ld/20828
1080 * elflink.c (bfd_elf_record_link_assignment): Clear any
1081 `forced_local' marking for DSO symbols that are not being
1082 provided.
1083
640d6bfd
KLC
10842017-01-17 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1085
1086 * elfnn-riscv.c (riscv_elf_object_p): New function.
1087
8361ed4d
L
10882017-01-12 H.J. Lu <hongjiu.lu@intel.com>
1089
1090 PR ld/21038
1091 * elf64-x86-64.c (elf_x86_64_link_hash_table): Add
1092 plt_bnd_eh_frame.
1093 (elf_x86_64_check_relocs): Create .eh_frame section for the
1094 .plt.bnd section.
1095 (elf_x86_64_size_dynamic_sections): Allocate and initialize
1096 .eh_frame section for the .plt.bnd section.
1097 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
1098 for the .plt.bnd section.
1099
2425a30e
NC
11002017-01-12 Nick Clifton <nickc@redhat.com>
1101
1102 PR binutils/20876
1103 * opncls.c (find_separate_debug_file): Add include_dirs
1104 parameter. Only include the directory part of the bfd's filename
1105 in search paths if include_dirs is true. Add a couple of extra
1106 locations for looking for debug files.
1107 ( bfd_follow_gnu_debuglink): Update invocation of
1108 find_separate_debug_file.
1109 (bfd_follow_gnu_debugaltlink): Likewise.
1110 (get_build_id): New function: Finds the build-id of the given bfd.
1111 (get_build_id_name): New function: Computes the name of the
1112 separate debug info file for a bfd, based upon its build-id.
1113 (check_build_id_file): New function: Checks to see if a separate
1114 debug info file exists at the given location, and that its
1115 build-id matches that of the original bfd.
1116 (bfd_follow_build_id_debuglink): New function: Finds a separate
1117 debug info file for a given bfd by using the build-id method.
1118 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Try using the build-id
1119 method of locating a separate debug info file before using the
1120 debuglink method.
1121 * bfd-in2.h: Regenerate.
1122
9e659176
L
11232017-01-11 H.J. Lu <hongjiu.lu@intel.com>
1124
1125 PR ld/21038
1126 * elf64-x86-64.c (elf_x86_64_eh_frame_bnd_plt): New.
1127 (elf_x86_64_bnd_arch_bed): Use elf_x86_64_eh_frame_bnd_plt and
1128 elf_x86_64_eh_frame_plt_got.
1129 (elf_x86_64_size_dynamic_sections): Get unwind info from
1130 elf_x86_64_bnd_arch_bed for the BND PLT.
1131
f2e2d2f5
JS
11322017-01-11 Jeremy Soller <jackpot51@gmail.com>
1133
1134 * config.bfd: Add entries for i686-redox and x86_64-redox.
1135
52b232b3
L
11362017-01-10 H.J. Lu <hongjiu.lu@intel.com>
1137
1138 * elf32-i386.c (elf_i386_check_relocs): Align .eh_frame section
1139 to 4 bytes.
1140 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Align
1141 .eh_frame section to 4 bytes for x32.
1142 (elf_x86_64_check_relocs): Likewise.
1143
fff53dae
L
11442017-01-10 H.J. Lu <hongjiu.lu@intel.com>
1145
1146 PR ld/20830
1147 * elf32-i386.c (elf_i386_eh_frame_plt_got): New.
1148 (PLT_GOT_FDE_LENGTH): Likewise.
1149 (elf_i386_plt_layout): Add eh_frame_plt_got and
1150 eh_frame_plt_got_size.
1151 (elf_i386_plt): Updated.
1152 (elf_i386_link_hash_table): Add plt_got_eh_frame.
1153 (elf_i386_check_relocs): Create .eh_frame section for .plt.got.
1154 (elf_i386_size_dynamic_sections): Allocate and initialize
1155 .eh_frame section for .plt.got.
1156 (elf_i386_finish_dynamic_sections): Adjust .eh_frame section for
1157 .plt.got.
1158 (elf_i386_nacl_plt): Add FIXME for eh_frame_plt_got and
1159 eh_frame_plt_got_size.
1160 * elf64-x86-64.c (elf_x86_64_eh_frame_plt_got): New.
1161 (PLT_GOT_FDE_LENGTH): Likewise.
1162 (elf_x86_64_backend_data): Add eh_frame_plt_got and
1163 eh_frame_plt_got_size.
1164 (elf_x86_64_arch_bed): Updated.
1165 (elf_x86_64_bnd_arch_bed): Add FIXME for eh_frame_plt_got and
1166 eh_frame_plt_got_size.
1167 (elf_x86_64_nacl_arch_bed): Likewise.
1168 (elf_x86_64_link_hash_table): Add plt_got_eh_frame.
1169 (elf_x86_64_check_relocs): Create .eh_frame section for .plt.got.
1170 (elf_x86_64_size_dynamic_sections): Allocate and initialize
1171 .eh_frame section for .plt.got.
1172 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
1173 for .plt.got.
1174
f129e49f
L
11752017-01-10 H.J. Lu <hongjiu.lu@intel.com>
1176
1177 * elf32-i386.c (elf_i386_size_dynamic_sections): Set
1178 plt_eh_frame->size to eh_frame_plt_size and use eh_frame_plt.
1179
cd6581da
NC
11802017-01-09 Nick Clifton <nickc@redhat.com>
1181
1182 * dwarf2.c (lookup_address_in_function_table): Return early if
1183 there are no functions in the given comp unit, or if the high
1184 address of the last function in the comp unit is less than the
1185 desired address.
1186
98f02962
NC
11872017-01-09 Nick Clifton <nickc@redhat.com>
1188
1189 PR binutils/21013
1190 * coffgen.c (_bfd_coff_get_external_symbols): Generate an error
1191 message if there are too many symbols to load.
1192
ae4fda66
JC
11932017-01-04 James Clarke <jrtc27@jrtc27.com>
1194
1195 * elf64-alpha.c (elf64_alpha_relax_opt_call): Don't set tsec_free
1196 if relocs are cached.
1197
de1010f4
RF
11982017-01-03 Rich Felker <bugdal@aerifal.cx>
1199
1200 PR ld/21017
1201 * elf32-microblaze.c (microblaze_elf_check_relocs): Add an entry
1202 for R_MICROBLAZE_GOTOFF_64.
1203
09fe2662
NC
12042017-01-03 Nick Clifton <nickc@redhat.com>
1205
1206 * mach-o.c (bfd_mach_o_lookup_uuid_command): Fix compile time
1207 warning about using a possibly uninitialised variable.
1208
595e0a47
AM
12092017-01-02 Alan Modra <amodra@gmail.com>
1210
1211 * elf32-hppa.c (ensure_undef_weak_dynamic): New function.
1212 (allocate_plt_static, allocate_dynrelocs): Use it.
1213
7bd9df3b
AM
12142017-01-02 Alan Modra <amodra@gmail.com>
1215
1216 * elf-hppa.h (elf_hppa_fake_sections): Set SHF_INFO_LINK for
1217 .PARISC.unwind section.
1218
5b86074c
AM
12192017-01-02 Alan Modra <amodra@gmail.com>
1220
1221 PR ld/20989
1222 * elfxx-sparc.c (gdop_relative_offset_ok): New function.
1223 (_bfd_sparc_elf_relocate_section): Use it to validate GOT
1224 indirect to GOT pointer relative code edit.
1225
2571583a
AM
12262017-01-02 Alan Modra <amodra@gmail.com>
1227
1228 Update year range in copyright notice of all files.
1229
5c1ad6b5 1230For older changes see ChangeLog-2016
3499769a 1231\f
5c1ad6b5 1232Copyright (C) 2017 Free Software Foundation, Inc.
3499769a
AM
1233
1234Copying and distribution of this file, with or without modification,
1235are permitted in any medium without royalty provided the copyright
1236notice and this notice are preserved.
1237
1238Local Variables:
1239mode: change-log
1240left-margin: 8
1241fill-column: 74
1242version-control: never
1243End:
This page took 0.150603 seconds and 4 git commands to generate.