]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - bfd/ChangeLog
x86: Add _bfd_x86_elf_mkobject
[thirdparty/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
39946cc2
L
12017-09-01 H.J. Lu <hongjiu.lu@intel.com>
2
3 * elf32-i386.c (elf_i386_mkobject): Removed.
4 (bfd_elf32_mkobject): Likewise.
5 * elf64-x86-64.c (elf_x86_64_mkobject): Likewise.
6 (bfd_elf64_mkobject): Likewise.
7 (bfd_elf32_mkobject): Likewise.
8 * elfxx-x86.c (_bfd_x86_elf_mkobject): New function.
9 (_bfd_x86_elf_mkobject): New.
10 (bfd_elf64_mkobject): Likewise.
11 (bfd_elf32_mkobject): Likewise.
12
a6798bab
L
132017-09-01 H.J. Lu <hongjiu.lu@intel.com>
14
15 * elf32-i386.c (elf_i386_link_setup_gnu_properties): Updated.
16 Call _bfd_x86_elf_link_setup_gnu_properties.
17 * elf64-x86-64.c (elf_x86_lazy_plt_layout): Initialize
18 pic_plt0_entry and pic_plt_entry fields with the non-PIC PLT
19 entries.
20 (elf_x86_64_non_lazy_plt): Likewise.
21 (elf_x86_64_lazy_bnd_plt): Likewise.
22 (elf_x86_64_non_lazy_bnd_plt): Likewise.
23 (elf_x86_64_lazy_ibt_plt): Likewise.
24 (elf_x32_lazy_ibt_plt): Likewise.
25 (elf_x86_64_non_lazy_ibt_plt): Likewise.
26 (elf_x32_non_lazy_ibt_plt): Likewise.
27 (elf_x86_64_nacl_plt): Likewise.
28 (elf_x86_64_link_setup_gnu_properties): Updated. Call
29 _bfd_x86_elf_link_setup_gnu_properties.
30 * elfxx-x86.c: Include elf-vxworks.h".
31 (_bfd_x86_elf_link_setup_gnu_properties): New function.
32 * elfxx-x86.h (elf_x86_lazy_plt_layout): Remove "for i386 only"
33 comments for pic_plt0_entry and pic_plt_entry.
34 (elf_x86_non_lazy_plt_layout): Likewise.
35 (elf_x86_plt_layout_table): New.
36 (_bfd_x86_elf_link_setup_gnu_properties): Likewise.
37
e10c9c62
L
382017-09-01 H.J. Lu <hongjiu.lu@intel.com>
39
40 PR ld/22061
41 * elf32-i386.c (elf_i386_link_setup_gnu_properties): Create
42 .eh_frame section for the second PLT.
43 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Correct
44 alignment of .eh_frame section for the second PLT.
45
7e8b6008
NC
462017-09-01 Nick Clifton <nickc@redhat.com>
47
48 PR 22059
49 * dwarf2.c (decode_line_info): Fix test for an overlong line info
50 structure.
51
2a143b99
NC
522017-09-01 Nick Clifton <nickc@redhat.com>
53
54 PR 22058
55 * elf-attrs.c (_bfd_elf_parse_attributes): Ensure that the
56 attribute buffer is NUL terminated.
57
e4f27230
NC
582017-08-31 Nick Clifton <nickc@redhat.com>
59
60 PR 22047
61 * dwarf2.c (read_section): If necessary add a terminating NUL byte
62 to dwarf string sections.
63
686335cd
AM
642017-08-31 Alan Modra <amodra@gmail.com>
65
66 * po/SRC-POTFILES.in: Regenerate.
67
9866ffe2
AM
682017-08-31 Alan Modra <amodra@gmail.com>
69
70 * elf-eh-frame.c (_bfd_elf_parse_eh_frame): Don't exit early
71 for a section containing just a terminator. Allow multiple
72 terminators at end of section.
73 * elflink.c (bfd_elf_discard_info): Iterate over .eh_frame
74 sections when not adding alignment. Assert on terminator in
75 the middle of FDEs.
76
af471f82
AM
772017-08-31 Alan Modra <amodra@gmail.com>
78
79 PR 21441
80 PR 22048
81 * elflink.c (bfd_elf_discard_info): Don't pad embedded zero
82 terminators.
83
3321e42b
L
842017-08-30 H.J. Lu <hongjiu.lu@intel.com>
85
86 * configure.ac (bfd_backends): Add elf64.lo together with
87 elfxx-x86.lo for 64-bit BFD.
88 * configure: Regenerated.
89
ef32532f
JB
902017-08-31 James Bowman <james.bowman@ftdichip.com>
91
92 * elf32-ft32.c (ft32_elf_howto_table): Use complain_overflow_dont
93 for R_FT32_18.
94
e234de6b
AM
952017-08-31 Alan Modra <amodra@gmail.com>
96
97 PR binutils/22032
98 * opncls.c (bfd_close_all_done): Don't call bfd_cache_close
99 before _close_and_cleanup. Call iovec->bclose after.
100 (bfd_close): Remove code common to, and call, bfd_close_all_done.
101
f493882d
L
1022017-08-30 H.J. Lu <hongjiu.lu@intel.com>
103
104 * elf32-i386.c (elf_i386_plt_type): Removed.
105 (elf_i386_plt): Likewise.
106 (elf_i386_get_synthetic_symtab): Updated. Call
107 _bfd_x86_elf_get_synthetic_symtab.
108 * elf64-x86-64.c (elf_x86_64_plt_type): Removed.
109 (elf_x86_64_plt): Likewise.
110 (elf_x86_64_get_synthetic_symtab): Updated. Call
111 _bfd_x86_elf_get_synthetic_symtab.
112 * elfxx-x86.c (elf_i386_get_plt_got_vma): New function.
113 (elf_x86_64_get_plt_got_vma): Likewise.
114 (elf_i386_valid_plt_reloc_p): Likewise.
115 (elf_x86_64_valid_plt_reloc_p): Likewise.
116 (_bfd_x86_elf_get_synthetic_symtab): Likewise.
117 * elfxx-x86.h (elf_x86_plt_type): New.
118 (elf_x86_plt): Likewise.
119 (_bfd_x86_elf_get_synthetic_symtab): Likewise.
120
5b86dbf4
L
1212017-08-30 H.J. Lu <hongjiu.lu@intel.com>
122
123 * elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Check
124 target_id instead of elf_machine_code.
125
765e526c
L
1262017-08-30 H.J. Lu <hongjiu.lu@intel.com>
127
128 * elf32-i386.c (ELF_DYNAMIC_INTERPRETER): Removed.
129 (elf_i386_lazy_plt_layout): Likewise.
130 (elf_i386_non_lazy_plt_layout): Likewise.
131 (elf_i386_plt_layout): Likewise.
132 (elf_i386_link_hash_table): Likewise.
133 (elf_i386_next_tls_desc_index): Likewise.
134 (elf_i386_srelplt2): Likewise.
135 (elf_i386_plt): Likewise.
136 (elf_i386_lazy_plt): Likewise.
137 (elf_i386_non_lazy_plt): Likewise.
138 (elf_i386_link_hash_table_create): Likewise.
139 (bfd_elf32_bfd_link_hash_table_create): Likewise.
140 (elf_i386_lazy_plt): Updated.
141 (elf_i386_non_lazy_plt): Likewise.
142 (elf_i386_lazy_ibt_plt): Likewise.
143 (elf_i386_non_lazy_ibt_plt): Likewise.
144 (elf_i386_allocate_dynrelocs): Likewise.
145 (elf_i386_size_dynamic_sections): Likewise.
146 (elf_i386_relocate_section): Likewise.
147 (elf_i386_finish_dynamic_symbol): Likewise.
148 (elf_i386_finish_dynamic_sections): Likewise.
149 (elf_i386_get_synthetic_symtab): Likewise.
150 (elf_i386_link_setup_gnu_properties): Likewise.
151 (elf_i386_nacl_plt): Likewise.
152 * elf64-x86-64.c (ABI_64_P): Removed.
153 (ELF64_DYNAMIC_INTERPRETER): Likewise.
154 (ELF32_DYNAMIC_INTERPRETER): Likewise.
155 (elf_x86_64_lazy_plt_layout): Likewise.
156 (elf_x86_64_non_lazy_plt_layout): Likewise.
157 (elf_x86_64_plt_layout): Likewise.
158 (elf_x86_64_link_hash_table): Likewise.
159 (elf_x86_64_plt): Likewise.
160 (elf_x86_64_lazy_plt): Likewise.
161 (elf_x86_64_non_lazy_plt): Likewise.
162 (elf_x86_64_link_hash_table_create): Likewise.
163 (bfd_elf64_bfd_link_hash_table_create): Likewise.
164 (bfd_elf32_bfd_link_hash_table_create): Likewise.
165 (elf_x86_64_lazy_plt): Updated.
166 (elf_x86_64_non_lazy_plt): Likewise.
167 (elf_x86_64_lazy_bnd_plt): Likewise.
168 (elf_x86_64_non_lazy_bnd_plt): Likewise.
169 (elf_x86_64_lazy_ibt_plt): Likewise.
170 (elf_x32_lazy_ibt_plt): Likewise.
171 (elf_x86_64_non_lazy_ibt_plt): Likewise.
172 (elf_x32_non_lazy_ibt_plt): Likewise.
173 (elf_x86_64_allocate_dynrelocs): Likewise.
174 (elf_x86_64_size_dynamic_sections): Likewise.
175 (elf_x86_64_relocate_section): Likewise.
176 (elf_x86_64_finish_dynamic_symbol): Likewise.
177 (elf_x86_64_finish_dynamic_sections): Likewise.
178 (elf_x86_64_get_synthetic_symtab): Likewise.
179 (elf_x86_64_link_setup_gnu_properties): Likewise.
180 (elf_x86_64_nacl_plt): Likewise.
181 * elfxx-x86.c: Include "objalloc.h", "elf/i386.h" and
182 "elf/x86-64.h".
183 (ELF32_DYNAMIC_INTERPRETER): New.
184 (ELF64_DYNAMIC_INTERPRETER): Likewise.
185 (ELFX32_DYNAMIC_INTERPRETER): Likewise.
186 (_bfd_x86_elf_link_hash_table_create): Likewise.
187 (_bfd_x86_elf_link_hash_table_free): Renamed to ...
188 (elf_x86_link_hash_table_free): This. Make it static.
189 * elfxx-x86.h: Don't include "objalloc.h".
190 (ABI_64_P): New.
191 (elf_x86_lazy_plt_layout): Likewise.
192 (elf_x86_non_lazy_plt_layout): Likewise.
193 (elf_x86_plt_layout): Likewise.
194 (_bfd_x86_elf_link_hash_table_create): Likewise.
195 (bfd_elf64_bfd_link_hash_table_create): Likewise.
196 (bfd_elf32_bfd_link_hash_table_create): Likewise.
197 (elf_x86_link_hash_table): Add plt, lazy_plt, non_lazy_plt,
198 srelplt2 and next_tls_desc_index.
199 (_bfd_x86_elf_link_hash_table_free): Removed.
200
70e65ca8
MR
2012017-08-30 Maciej W. Rozycki <macro@imgtec.com>
202
203 * elfxx-mips.c (mips_elf_perform_relocation): Correct microMIPS
204 branch offset interpretation.
205
7c0ed396
L
2062017-08-30 H.J. Lu <hongjiu.lu@intel.com>
207
208 PR binutils/22032
209 * opncls.c (bfd_close_all_done): Call _close_and_cleanup.
210
0f2425c4
L
2112017-08-30 H.J. Lu <hongjiu.lu@intel.com>
212
213 * elf64-x86-64.c (elf_x86_64_next_tls_desc_index): Removed.
214 (elf_x86_64_srelplt2): Likewise.
215
9a23f96e
AM
2162017-08-30 Alan Modra <amodra@gmail.com>
217
218 * elf64-ppc.c (struct ppc_link_hash_table): Add do_tls_opt.
219 (ppc64_elf_tls_optimize): Set it.
220 (ppc64_elf_relocate_section): Nop addis on TPREL16_HA, and convert
221 insn on TPREL16_LO and TPREL16_LO_DS relocs to use r13 when
222 addis would add zero.
223 * elf32-ppc.c (struct ppc_elf_link_hash_table): Add do_tls_opt.
224 (ppc_elf_tls_optimize): Set it.
225 (ppc_elf_relocate_section): Nop addis on TPREL16_HA, and convert
226 insn on TPREL16_LO relocs to use r2 when addis would add zero.
227
b9f04fe0
AM
2282017-08-30 Alan Modra <amodra@gmail.com>
229
230 * elf64-ppc.c (ppc64_elf_relocate_section): When optimizing
231 __tls_get_addr call sequences to LE, don't move the addi down
232 to the nop. Replace the bl with addi and leave the nop alone.
233
5f0f0847
L
2342017-08-29 H.J. Lu <hongjiu.lu@intel.com>
235
236 * elf32-i386.c (elf_i386_pie_finish_undefweak_symbol):
237 Re-indent.
238 * elf64-x86-64.c (elf_x86_64_finish_local_dynamic_symbol):
239 Likewise.
240 (elf_x86_64_pie_finish_undefweak_symbol): Likewise.
241
443701f5
L
2422017-08-29 H.J. Lu <hongjiu.lu@intel.com>
243
244 * Makefile.am (BFD32_BACKENDS): Add elfxx-x86.lo.
245 (BFD64_BACKENDS): Likewise.
246 (BFD32_BACKENDS_CFILES): Add elfxx-x86.c.
247 (BFD64_BACKENDS_CFILES): Likewise.
248 * Makefile.in: Regenerated.
249 * configure.ac (bfd_backends): Add elfxx-x86.lo together with
250 elf32-i386.lo and elf64-x86-64.lo.
251 * configure: Regenerated.
252 * elf32-i386.c: Include "elfxx-x86.h" instead of "sysdep.h",
253 "bfd.h", "bfdlink.h", "libbfd.h", "elf-bfd.h", "bfd_stdint.h",
254 "objalloc.h" and "hashtab.h".
255 (ELIMINATE_COPY_RELOCS): Removed.
256 (UNDEFINED_WEAK_RESOLVED_TO_ZERO):Likewise.
257 (SYMBOL_NO_COPYRELOC): Likewise.
258 (elf_i386_link_hash_entry): Likewise.
259 (GOT_UNKNOWN): Likewise.
260 (GOT_NORMAL): Likewise.
261 (GOT_TLS_GD): Likewise.
262 (elf_i386_hash_entry): Likewise.
263 (elf_i386_obj_tdata): Likewise.
264 (elf_i386_tdata): Likewise.
265 (elf_i386_local_got_tls_type): Likewise.
266 (elf_i386_local_tlsdesc_gotent): Likewise.
267 (elf_i386_hash_table): Likewise.
268 (elf_i386_link_hash_newfunc): Likewise.
269 (elf_i386_local_htab_hash): Likewise.
270 (elf_i386_local_htab_eq): Likewise.
271 (elf_i386_get_local_sym_hash): Likewise.
272 (elf_i386_link_hash_table_free): Likewise.
273 (elf_i386_copy_indirect_symbol): Likewise.
274 (elf_i386_fixup_symbol): Likewise.
275 (elf_i386_readonly_dynrelocs): Likewise.
276 (elf_i386_always_size_sections): Likewise.
277 (elf_i386_set_tls_module_base): Likewise.
278 (elf_i386_dtpoff_base): Likewise.
279 (compare_relocs): Likewise.
280 (elf_i386_hash_symbol): Likewise.
281 (elf_i386_parse_gnu_properties): Likewise.
282 (elf_i386_merge_gnu_properties): Likewise.
283 (elf_i386_link_check_relocs): Likewise.
284 (elf_i386_merge_symbol_attribute): Likewise.
285 (bfd_elf32_bfd_link_check_relocs): Likewise.
286 (elf_backend_copy_indirect_symbol): Likewise.
287 (elf_backend_always_size_sections): Likewise.
288 (elf_backend_omit_section_dynsym): Likewise.
289 (elf_backend_hash_symbol): Likewise.
290 (elf_backend_fixup_symbol): Likewise.
291 (elf_backend_parse_gnu_properties): Likewise.
292 (elf_backend_merge_gnu_properties): Likewise.
293 (elf_backend_merge_symbol_attribute): Likewise.
294 (elf_i386_mkobject): Updated.
295 (elf_i386_link_hash_table_create): Likewise.
296 (elf_i386_check_tls_transition): Likewise.
297 (elf_i386_tls_transition): Likewise.
298 (elf_i386_convert_load_reloc): Likewise.
299 (elf_i386_check_relocs): Likewise.
300 (elf_i386_adjust_dynamic_symbol): Likewise.
301 (elf_i386_allocate_dynrelocs): Likewise.
302 (elf_i386_convert_load): Likewise.
303 (elf_i386_size_dynamic_sections): Likewise.
304 (elf_i386_relocate_section): Likewise.
305 (elf_i386_finish_dynamic_symbol ): Likewise.
306 (elf_i386_finish_dynamic_sections): Likewise.
307 (elf_i386_output_arch_local_syms): Likewise.
308 (elf_i386_get_synthetic_symtab): Likewise.
309 (elf_i386_link_setup_gnu_properties): Likewise.
310 (elf_i386_link_hash_table): Use elf_x86_link_hash_table, instead
311 of elf_link_hash_table, as base.
312 (elf_i386_next_tls_desc_index): New.
313 (elf_i386_srelplt2): Likewise.
314 (elf_i386_plt): Likewise.
315 (elf_i386_lazy_plt): Likewise.
316 (elf_i386_non_lazy_plt): Likewise.
317 * elf32-x86-64.c: Include "elfxx-x86.h" instead of "sysdep.h",
318 "bfd.h", "bfdlink.h", "libbfd.h", "elf-bfd.h", "bfd_stdint.h",
319 "objalloc.h" and "hashtab.h".
320 (ELIMINATE_COPY_RELOCS): Removed.
321 (UNDEFINED_WEAK_RESOLVED_TO_ZERO):Likewise.
322 (SYMBOL_NO_COPYRELOC): Likewise.
323 (elf_x86_64_link_hash_entry): Likewise.
324 (GOT_UNKNOWN): Likewise.
325 (GOT_NORMAL): Likewise.
326 (GOT_TLS_GD): Likewise.
327 (elf_x86_64_hash_entry): Likewise.
328 (elf_x86_64_obj_tdata): Likewise.
329 (elf_x86_64_tdata): Likewise.
330 (elf_x86_64_local_got_tls_type): Likewise.
331 (elf_x86_64_local_tlsdesc_gotent): Likewise.
332 (elf_x86_64_hash_table): Likewise.
333 (elf_x86_64_link_hash_newfunc): Likewise.
334 (elf_x86_64_local_htab_hash): Likewise.
335 (elf_x86_64_local_htab_eq): Likewise.
336 (elf_x86_64_get_local_sym_hash): Likewise.
337 (elf_x86_64_link_hash_table_free): Likewise.
338 (elf_x86_64_copy_indirect_symbol): Likewise.
339 (elf_x86_64_fixup_symbol): Likewise.
340 (elf_x86_64_readonly_dynrelocs): Likewise.
341 (elf_x86_64_always_size_sections): Likewise.
342 (elf_x86_64_set_tls_module_base): Likewise.
343 (elf_x86_64_dtpoff_base): Likewise.
344 (compare_relocs): Likewise.
345 (elf_x86_64_merge_symbol_attribute): Likewise.
346 (elf_x86_64_hash_symbol): Likewise.
347 (elf_x86_64_parse_gnu_properties): Likewise.
348 (elf_x86_64_merge_gnu_properties): Likewise.
349 (elf_x86_64_link_check_relocs): Likewise.
350 (elf_backend_copy_indirect_symbol): Likewise.
351 (elf_backend_always_size_sections): Likewise.
352 (bfd_elf64_bfd_link_check_relocs): Likewise.
353 (elf_backend_merge_symbol_attribute): Likewise.
354 (elf_backend_hash_symbol): Likewise.
355 (elf_backend_omit_section_dynsym): Likewise.
356 (elf_backend_fixup_symbol): Likewise.
357 (elf_backend_parse_gnu_properties): Likewise.
358 (elf_backend_merge_gnu_properties): Likewise.
359 (bfd_elf32_bfd_link_check_relocs): Likewise.
360 (elf_x86_64_mkobject): Updated.
361 (elf_x86_64_link_hash_table_create): Likewise.
362 (elf_x86_64_check_tls_transition): Likewise.
363 (elf_x86_64_tls_transition): Likewise.
364 (elf_x86_64_convert_load_reloc): Likewise.
365 (elf_x86_64_check_relocs): Likewise.
366 (elf_x86_64_adjust_dynamic_symbol): Likewise.
367 (elf_x86_64_allocate_dynrelocs): Likewise.
368 (elf_x86_64_convert_load): Likewise.
369 (elf_x86_64_size_dynamic_sections): Likewise.
370 (elf_x86_64_relocate_section): Likewise.
371 (elf_x86_64_finish_dynamic_symbol ): Likewise.
372 (elf_x86_64_finish_dynamic_sections): Likewise.
373 (elf_x86_64_output_arch_local_syms): Likewise.
374 (elf_x86_64_get_synthetic_symtab): Likewise.
375 (elf_x86_64_link_setup_gnu_properties): Likewise.
376 (elf_x86_64_link_hash_table): Use elf_x86_link_hash_table,
377 instead of elf_link_hash_table, as base.
378 (elf_x86_64_next_tls_desc_index): New.
379 (elf_x86_64_srelplt2): Likewise.
380 (elf_x86_64_plt): Likewise.
381 (elf_x86_64_lazy_plt): Likewise.
382 (elf_x86_64_non_lazy_plt): Likewise.
383 * elfxx-x86.c: New file.
384 * elfxx-x86.h: Likewise.
385
823cb067
L
3862017-08-29 H.J. Lu <hongjiu.lu@intel.com>
387
388 * elf32-i386.c (elf_i386_get_synthetic_symtab): Simplify bad
389 return.
390 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
391
37c0b6ee
L
3922017-08-29 H.J. Lu <hongjiu.lu@intel.com>
393
394 * elf32-i386.c (elf_i386_get_synthetic_symtab): Check valid PLT
395 sections before checking dynamic relocations and free invalid
396 PLT section contents.
397 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
398
0fb0a767
L
3992017-08-28 H.J. Lu <hongjiu.lu@intel.com>
400
401 * elf-bfd.h (_bfd_elf_ifunc_get_synthetic_symtab): Removed.
402 * elf-ifunc.c (_bfd_elf_ifunc_get_synthetic_symtab): Likewise.
403
90efb642
L
4042017-08-28 H.J. Lu <hongjiu.lu@intel.com>
405
406 PR binutils/22018
407 * elf32-i386.c (elf_i386_get_synthetic_symtab): Check for valid
408 PLT section size.
409 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
410
596dc58f
L
4112017-08-27 H.J. Lu <hongjiu.lu@intel.com>
412
413 * elf32-i386.c (elf_i386_link_hash_newfunc): Initialize
414 def_protected.
415 * elf64-x86-64.c (elf_x86_64_link_hash_newfunc): Likewise.
416
a5b4ee94
L
4172017-08-26 H.J. Lu <hongjiu.lu@intel.com>
418
419 PR ld/21997
420 * elf-bfd.h (elf_obj_tdata): Use ENUM_BITFIELD on object_id,
421 dyn_lib_class and has_gnu_symbols. Change bad_symtab to bitfield.
422 Add a has_no_copy_on_protected bitfield.
423 (elf_has_no_copy_on_protected): New.
424 * elf-properties.c (_bfd_elf_parse_gnu_properties): Set
425 elf_has_no_copy_on_protected for GNU_PROPERTY_NO_COPY_ON_PROTECTED.
426 (elf_merge_gnu_property_list): Likewise.
427 (_bfd_elf_link_setup_gnu_properties): Set extern_protected_data
428 to FALSE for elf_has_no_copy_on_protected.
429 * elf32-i386.c (SYMBOL_NO_COPYRELOC): New.
430 (elf_i386_link_hash_entry): Add def_protected.
431 (elf_i386_adjust_dynamic_symbol): Also check SYMBOL_NO_COPYRELOC
432 when checking info->nocopyreloc.
433 (elf_i386_link_setup_gnu_properties): Don't set
434 extern_protected_data here.
435 (elf_i386_merge_symbol_attribute): New function.
436 (elf_backend_merge_symbol_attribute): New.
437 * elf64-x86-64.c (SYMBOL_NO_COPYRELOC): New.
438 (elf_x86_64_link_hash_entry): Add def_protected.
439 (elf_x86_64_need_pic): Report protected symbol for def_protected.
440 (elf_x86_64_adjust_dynamic_symbol): Also check SYMBOL_NO_COPYRELOC
441 when checking info->nocopyreloc.
442 (elf_x86_64_relocate_section): Also check for R_X86_64_PC32
443 relocation run-time overflow and unresolvable R_X86_64_32S
444 relocation against protected data symbol defined in shared object
445 with GNU_PROPERTY_NO_COPY_ON_PROTECTED.
446 (elf_x86_64_link_setup_gnu_properties): Don't set
447 extern_protected_data here.
448 (elf_x86_64_merge_symbol_attribute): New function.
449 (elf_backend_merge_symbol_attribute): New.
450
7c8bbca5
AM
4512017-08-26 Alan Modra <amodra@gmail.com>
452
453 * elf32-ppc.c (must_be_dyn_reloc): Use bfd_link_dll. Comment.
454 (ppc_elf_check_relocs): Only set DF_STATIC_TLS in shared libs.
455 (ppc_elf_relocate_section): Comment fix.
456 * elf64-ppc.c (must_be_dyn_reloc): Use bfd_link_dll. Comment.
457 (ppc64_elf_check_relocs): Only set DF_STATIC_TLS in shared libs.
458 Support dynamic relocs for TPREL16 when non-pic too.
459 (dec_dynrel_count): Adjust TPREL16 handling as per check_relocs.
460 (ppc64_elf_relocate_section): Support dynamic relocs for TPREL16
461 when non-pic too.
462
5fdda9d6
L
4632017-08-25 H.J. Lu <hongjiu.lu@intel.com>
464
465 * elf32-i386.c (elf_i386_link_hash_entry): Remove redundant
466 "symbol" in comments.
467 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Likewise.
468
7073b5b9
L
4692017-08-24 H.J. Lu <hongjiu.lu@intel.com>
470
471 PR ld/22001
472 * elf64-x86-64.c (elf_x86_64_relocate_section): Check for
473 R_X86_64_PC32 relocation run-time overflow and unresolvable
474 R_X86_64_32S relocation with -z nocopyreloc.
475
34bb2571
L
4762017-08-24 H.J. Lu <hongjiu.lu@intel.com>
477
478 * elf32-i386.c (elf_i386_check_relocs): Revert the last change.
479 Undefined symbols may not have a type.
480 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
481
aab921ad
L
4822017-08-23 H.J. Lu <hongjiu.lu@intel.com>
483
484 * elf64-x86-64.c (elf_x86_64_need_pic): Add an argument for
485 bfd_link_info. Report shared, PIE or PDE object based on
486 bfd_link_info.
487 (elf_x86_64_check_relocs): Update elf_x86_64_need_pic call.
488 (elf_x86_64_relocate_section): Likewise.
489
b1bb697e
L
4902017-08-23 H.J. Lu <hongjiu.lu@intel.com>
491
492 * elf32-i386.c (elf_i386_check_relocs): Increment PLT count only
493 for function symbols.
494 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
495
73784fa5
L
4962017-08-23 H.J. Lu <hongjiu.lu@intel.com>
497
498 * elf32-i386.c (elf_i386_link_setup_gnu_properties): Set
499 extern_protected_data to FALSE if GNU_PROPERTY_NO_COPY_ON_PROTECTED
500 is set on any input relocatable file.
501 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Likewise.
502
46434633
AM
5032017-08-23 Alan Modra <amodra@gmail.com>
504
505 PR 21988
506 * elf64-ppc.c (ensure_undef_dynamic): Rename from
507 ensure_undefweak_dynamic. Handle undefined too.
508 * elf32-ppc.c (ensure_undef_dynamic): Likewise.
509 * elf32-hppa.c (ensure_undef_dynamic): Likewise.
510 (allocate_dynrelocs): Discard undefined non-default visibility
511 relocs first. Make undefined syms dynamic. Tidy goto.
512
487b6440
AM
5132017-08-21 Alan Modra <amodra@gmail.com>
514 H.J. Lu <hongjiu.lu@intel.com>
515
516 PR ld/21964
517 * elf-bfd.h (SYMBOLIC_BIND): Return TRUE for __start/__stop symbols.
518 * elflink.c (bfd_elf_define_start_stop): Rewrite.
519
284d826d
HPN
5202017-08-21 Hans-Peter Nilsson <hp@bitrange.com>
521
522 PR ld/20125
523 * elf64-mmix.c (mmix_elf_relax_section): Correct handling of
524 undefined weak symbols.
525
de259397
NC
5262017-08-18 Nick Clifton <nickc@redhat.com>
527
528 PR binutils/21962
529 * tekhex.c (getsym): Fix check for source pointer walking off the
530 end of the input buffer.
531
545bc2b3
SN
5322017-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
533
534 PR ld/18808
535 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Skip IFUNC
536 relocations in debug sections, change abort to _bfd_error_handler.
537
0c54f692
NC
5382017-08-14 Nick Clifton <nickc@redhat.com>
539
540 PR 21957
541 * elf.c (setup_group): Check for an empty or very small group
542 section.
543 * po/bfd.pot: Regenerate.
544
79a94a2a
AM
5452017-08-14 Alan Modra <amodra@gmail.com>
546
547 PR 21441
548 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't add
549 alignment padding here.
550 * elflink.c (bfd_elf_discard_info): Add .eh_frame padding here
551 in a reverse pass over sections.
552
98c5dfc9
L
5532017-08-11 H.J. Lu <hongjiu.lu@intel.com>
554
555 PR binutils/21943
556 * elf32-i386.c (elf_i386_get_synthetic_symtab): Allocate space
557 for @plt suffixes first.
558 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
559
24d3e51b
NC
5602017-08-08 Nick Clifton <nickc@redhat.com>
561
562 PR 21916
563 * elf-attrs.c (_bfd_elf_parse_attributes): Complain about very
564 small section lengths.
565 * elf.c (_bfd_elf_setup_sections): Skip empty entries in the group
566 table.
567 (elfcore_grok_freebsd_prstatus): Add checks to make sure that
568 there is enough data present in the note.
569
206c9c79
AM
5702017-08-08 Alan Modra <amodra@gmail.com>
571
572 PR 21017
573 * elf32-microblaze.c (microblaze_elf_check_relocs): Don't bump
574 got.refcount for GOTOFF relocs, just create .got section.
575
2980ccad
L
5762017-08-07 H.J. Lu <hongjiu.lu@intel.com>
577
578 * elflink.c (elf_link_add_object_symbols): Move common symbol
579 check after bed->common_definition.
580
b3293efa
AM
5812017-08-07 Alan Modra <amodra@gmail.com>
582
583 PR 21910
584 * elflink.c (bfd_elf_final_link): Don't segfault when sections
585 needed to define various dynamic tags have been discarded.
586
b7a18930
NC
5872017-08-07 Nick Clifton <nickc@redhat.com>
588
589 PR 21884
590 * elf32-i386.c (elf_i386_link_setup_gnu_properties): If the dynobj
591 has not been set then use the bfd returned by
592 _bfd_elf_link_setup_gnu_properties. If that is null then search
593 through all the input bfds selecting the first normal, ELF format
594 one.
595 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Likewise.
596
1d4af308
L
5972017-08-06 H.J. Lu <hongjiu.lu@intel.com>
598
599 * elf32-i386.c (elf_i386_link_hash_entry): Change tls_get_addr
600 to 1 bit.
601 (elf_i386_link_hash_newfunc): Initialize tls_get_addr to 0.
602 (elf_i386_check_tls_transition): Check tls_get_addr directly.
603 (elf_i386_convert_load_reloc): Update tls_get_addr check.
604 (elf_i386_link_check_relocs): New function.
605 (bfd_elf32_bfd_link_check_relocs): New.
606 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Change tls_get_addr
607 to 1 bit.
608 (elf_x86_64_link_hash_newfunc): Initialize tls_get_addr to 0.
609 (elf_x86_64_check_tls_transition): Check tls_get_addr directly.
610 (elf_x86_64_convert_load_reloc): Update tls_get_addr check.
611 (elf_x86_64_link_check_relocs): New function.
612 (bfd_elf64_bfd_link_check_relocs): New.
613 (bfd_elf32_bfd_link_check_relocs): Likewise.
614
a4819f54
L
6152017-08-06 H.J. Lu <hongjiu.lu@intel.com>
616
617 PR ld/21903:
618 * elflink.c (elf_link_add_object_symbols): Treat common symbol
619 as undefined for --no-define-common.
620
55ef6584
AM
6212017-08-05 Alan Modra <amodra@gmail.com>
622
623 * elf32-hppa.c (elf32_hppa_set_gp): Don't require an
624 hppa_link_hash_table.
625
d84ed528
MF
6262017-08-02 Max Filippov <jcmvbkbc@gmail.com>
627
628 * xtensa-isa.c (xtensa_isa_init): Don't update lookup table
629 entries for sysregs with negative indices.
630
1ef692ea
AK
6312017-08-01 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
632
633 * elf32-s390.c (elf_s390_finish_dynamic_sections): Skip if it
634 isn't the S/390 specific elf data.
635 * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
636
57593436
KLC
6372017-07-31 Kuan-Lin Chen <rufus@andestech.com>
638
639 * elfxx-riscv.c (riscv_elf_add_sub_reloc): New function.
640 * (howto_table) [R_RISCV_ADD8]: Use riscv_elf_add_sub_reloc.
641 [R_RISCV_ADD16]: Likewise.
642 [R_RISCV_ADD32]: Likewise.
643 [R_RISCV_ADD64]: Likewise.
644 [R_RISCV_SUB6]: Likewise.
645 [R_RISCV_SUB8]: Likewise.
646 [R_RISCV_SUB16]: Likewise.
647 [R_RISCV_SUB32]: Likewise.
648 [R_RISCV_SUB64]: Likewise.
649
d44c746a
AM
6502017-07-31 Alan Modra <amodra@gmail.com>
651
652 * elf64-ppc.c (ppc64_elf_tls_setup): Warn on --plt-localentry
653 without ld.so checks.
654
8b5f1ed8
AM
6552017-07-29 Alan Modra <amodra@gmail.com>
656
657 PR 21847
658 * elf64-ppc.c (struct ppc_link_hash_entry): Add non_zero_localentry.
659 (ppc64_elf_merge_symbol): Set non_zero_localentry.
660 (is_elfv2_localentry0): Test non_zero_localentry.
661 (ppc64_elf_tls_setup): Default to --no-plt-localentry.
662
894dde0b
AK
6632017-07-28 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
664
665 * elf32-s390.c (elf_s390_finish_dynamic_sections): Add NULL
666 pointer check for htab->elf.irelplt.
667 * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
668
8bdf0be1
NC
6692017-07-27 Nick Clifton <nickc@redhat.com>
670
671 PR 21840
672 * mach-o.c (bfd_mach_o_read_symtab_strtab): Fail if the symtab
673 size is -1.
674 * nlmcode.h (nlm_swap_auxiliary_headers_in): Replace assertion
675 with error return.
676 * section.c (bfd_make_section_with_flags): Fail if the name or bfd
677 are NULL.
678 * vms-alpha.c (bfd_make_section_with_flags): Correct computation
679 of end pointer.
680 (evax_bfd_print_emh): Check for invalid string lengths.
681
c26bb067
NC
6822017-07-25 Nick Clifton <nickc@redhat.com>
683
684 * po/fr.po: Updated French translation.
685
cfe7b9bd
BG
6862017-07-25 Benjamin Green <bengreen5mx@gmail.com>
687
688 PR 21824
689 * elf32-msp430.c (msp430_elf_relax_section): Allow conversion of
690 16-bit absolute branches into 10-bit pc-relative branches on the
691 MSP430 as well as the MSP430X.
692
d4aaa2a0
AM
6932017-07-25 Alan Modra <amodra@gmail.com>
694
695 * elf64-ppc.c (struct map_stub): Add tls_get_addr_opt_bctrl.
696 (stub_eh_frame_size): New function.
697 (ppc_size_one_stub): Set group tls_get_addr_opt_bctrl.
698 (group_sections): Init group tls_get_addr_opt_bctrl.
699 (ppc64_elf_size_stubs): Update sizing and initialization of
700 .eh_frame. Iteration over stubs via group list.
701 (ppc64_elf_build_stubs): Iterate over stubs via group list.
702 (ppc64_elf_finish_dynamic_sections): Update finalization of
703 .eh_frame.
704
ca4cf9b9
NC
7052017-07-24 Nick Clifton <nickc@redhat.com>
706
707 PR 21813
708 * mach-o.c (bfd_mach_o_canonicalize_relocs): Pass the base address
709 of the relocs to the canonicalize_one_reloc routine.
710 * mach-o.h (struct bfd_mach_o_backend_data): Update the prototype
711 for the _bfd_mach_o_canonicalize_one_reloc field.
712 * mach-o-arm.c (bfd_mach_o_arm_canonicalize_one_reloc): Add
713 res_base parameter. Use to check for corrupt pair relocs.
714 * mach-o-aarch64.c (bfd_mach_o_arm64_canonicalize_one_reloc):
715 Likewise.
716 * mach-o-i386.c (bfd_mach_o_i386_canonicalize_one_reloc):
717 Likewise.
718 * mach-o-x86-64.c (bfd_mach_o_x86_64_canonicalize_one_reloc):
719 Likewise.
720
721 * vms-alpha.c (_bfd_vms_slurp_eihd): Make sure that there is
722 enough data in the record before attempting to parse it.
723 (_bfd_vms_slurp_eeom): Likewise.
724
725 (_bfd_vms_slurp_egsd): Check for an invalid section index.
726 (image_set_ptr): Likewise.
727 (alpha_vms_slurp_relocs): Likewise.
728
8a2df5e2
NC
729 (alpha_vms_object_p): Check for a truncated record.
730
47aeb64c
NC
7312017-07-24 Nick Clifton <nickc@redhat.com>
732
733 PR 21803
734 * reloc.c (_bfd_unrecognized_reloc): New function. Reports
735 an unrecognized reloc and sets the bfd_error value.
736 * libbfd.h: Regenerate.
737 * elf32-arm.c (elf32_arm_final_link_relocate): Use the new
738 function.
739 * elf32-i386.c (elf_i386_relocate_section): Likewise.
740 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
741 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
742 * elfnn-aarch64.c (elfNN_aarch64_relocate_section): Likewise.
743 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
744
15a3a14f
AM
7452017-07-23 Alan Modra <amodra@gmail.com>
746
747 * elf64-ppc.c (ppc64_elf_size_stubs): Correct advance to
748 restore of LR.
749
f2e6a843
SN
7502017-07-19 Szabolcs Nagy <szabolcs.nagy@arm.com>
751
752 PR ld/18841
753 * elfnn-aarch64.c (elfNN_aarch64_reloc_type_class): Return
754 reloc_class_ifunc for ifunc symbols.
755
909e4e71
NC
7562017-07-19 Nick Clifton <nickc@redhat.com>
757
758 PR 21787
759 * archive.c (bfd_generic_archive_p): If the bfd does not have the
760 correct magic bytes at the start, set the error to wrong format
761 and clear the format selector before returning NULL.
762
29866fa1
NC
7632017-07-19 Nick Clifton <nickc@redhat.com>
764
765 PR 21786
766 * coff-rs6000.c (_bfd_strntol): New function.
767 (_bfd_strntoll): New function.
768 (GET_VALUE_IN_FIELD): New macro.
769 (EQ_VALUE_IN_FIELD): new macro.
770 (_bfd_xcoff_slurp_armap): Use new macros.
771 (_bfd_xcoff_archive_p): Likewise.
772 (_bfd_xcoff_read_ar_hdr): Likewise.
773 (_bfd_xcoff_openr_next_archived_file): Likewise.
774 (_bfd_xcoff_stat_arch_elt): Likewise.
6c4e7b6b
NC
775 * coff64-rs6000.c (_bfd_strntol): New function.
776 (_bfd_strntoll): New function.
777 (GET_VALUE_IN_FIELD): New macro.
778 (xcoff64_slurp_armap): Use new macros.
29866fa1 779
684d5a10
JEM
7802017-07-19 Claudiu Zissulescu <claziss@synopsys.com>
781 John Eric Martin <John.Martin@emmicro-us.com>
782
783 * bfd-in2.h: Regenerate.
784 * libbfd.h: Regenerate.
785 * elf32-arc.c (JLI): Define.
786 * reloc.c: Add JLI relocations.
787
de194d85
YC
7882017-07-18 Nick Clifton <nickc@redhat.com>
789
790 PR 21775
791 * coff-sh.c: Fix spelling typos.
792 * compress.c: Likewise.
793 * cpu-pdp11.c: Likewise.
794 * ecofflink.c: Likewise.
795 * elf-m10300.c: Likewise.
796 * elf.c: Likewise.
797 * elf32-arm.c: Likewise.
798 * elf32-m68k.c: Likewise.
799 * elf32-nds32.c: Likewise.
800 * elf32-ppc.c: Likewise.
801 * elf32-sh.c: Likewise.
802 * elf32-v850.c: Likewise.
803 * elf64-ppc.c: Likewise.
804 * elf64-x86-64.c: Likewise.
805 * elflink.c: Likewise.
806 * elfnn-aarch64.c: Likewise.
807 * elfxx-mips.c: Likewise.
808 * som.c: Likewise.
809 * sunos.c: Likewise.
810 * vms-alpha.c: Likewise.
811 * xcofflink.c: Likewise.
812
e4e21d9e
NC
8132017-07-18 Nick Clifton <nickc@redhat.com>
814
815 PR binutils/21781
816 * coffcode.h (handle_COMDAT): Replace abort with an error message
817 and return.
818
8e85f840
L
8192017-07-17 H.J. Lu <hongjiu.lu@intel.com>
820
821 PR ld/21782
822 * elf64-x86-64.c (elf_x86_64_relocate_section): Limit PIC check
823 to shared library.
824
dd57c19c
L
8252017-07-17 H.J. Lu <hongjiu.lu@intel.com>
826
827 * elf64-x86-64.c (elf_x86_64_relocate_section): Re-indent.
828
676ee2b5
AM
8292017-07-16 Alan Modra <amodra@gmail.com>
830
831 * elf64-ppc.c (ppc64_elf_relocate_section): Don't optimize
832 __tls_index GOT entries when using __tls_get_addr_opt stub.
833 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
834
429d795d
AM
8352017-07-12 Alan Modra <amodra@gmail.com>
836
837 * po/es.po: Update from translationproject.org/latest/bfd/.
838 * po/fi.po: Likewise.
839 * po/fr.po: Likewise.
840 * po/id.po: Likewise.
841 * po/ja.po: Likewise.
842 * po/ro.po: Likewise.
843 * po/ru.po: Likewise.
844 * po/sr.po: Likewise.
845 * po/sv.po: Likewise.
846 * po/tr.po: Likewise.
847 * po/uk.po: Likewise.
848 * po/vi.po: Likewise.
849 * po/zh_CN.po: Likewise.
850 * po/hr.po: New file from translationproject.org.
851 * configure.ac (ALL_LINGUAS): Add hr. Sort.
852 * configure: Regenerate.
853
0bae9e9e
NC
8542017-07-12 Nick Clifton <nickc@redhat.com>
855
856 Fix compile time warnings using gcc 7.1.1.
857 * elf32-xtensa.c (elf_xtensa_get_plt_section): Increase length of
858 plt_name buffer.
859 (elf_xtensa_get_gotplt_section): Increase length of got_name
860 buffer.
861 * mach-o-arm.c (bfd_mach_o_arm_canonicalize_one_reloc): Add a
862 default return of FALSE.
863 * mach-o-i386.c (bfd_mach_o_i386_canonicalize_one_reloc): Add a
864 default return of FALSE.
865
d42c267e
AM
8662017-07-12 Alan Modra <amodra@gmail.com>
867
868 * binary.c (binary_set_section_contents): Don't print filepos in
869 error message.
870 (coff_write_object_contents): Cast size_t for error message.
871 (coff_slurp_line_table): Don't use bfd_vma symndx.
872 (coff_slurp_reloc_table): Remove unneeded cast.
873 * dwarf2.c (read_section): Cast bfd_int64_t to long long for
874 error message.
875 (find_abstract_instance_name): Likewise.
876 * elf32-arm.c (arm_type_of_stub): Correct error arg order.
877 (bfd_elf32_arm_stm32l4xx_erratum_scan): Don't cast error arg.
878 (elf32_arm_check_relocs): Make r_symndx an int.
879 * elf32-cris.c (cris_elf_check_relocs): Delete extraneous %s in
880 format string.
881 * elf32-metag.c (elf_metag_relocate_section): Delete extra error
882 message arg.
883 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Rewrite bogus
884 error message.
885 * elf32-i386.c (elf_i386_check_relocs): Make r_symndx an int.
886 * elf32-s390.c (elf_s390_check_relocs): Likewise.
887 * elf32-tic6x.c (elf32_tic6x_check_relocs): Likewise.
888 * elf32-tilepro.c (tilepro_elf_check_relocs): Likewise.
889 * elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
890 * elf64-s390.c (elf_s390_check_relocs): Likewise.
891 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
892 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Likewise.
893 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
894 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
895 * elfxx-tilegx.c (tilegx_elf_check_relocs): Likewise.
896 * elf64-mmix.c (_bfd_mmix_after_linker_allocation): Cast size_t args
897 and use %lu for error message.
898 * elflink.c (elf_link_adjust_relocs): Delete extra error message arg.
899 * mmo.c (mmo_scan): Make stab_loc a file_ptr. Cast expression for
900 error message.
901
902 * elf32-arm.c (elf32_arm_tls_relax): Correct format string and args
903 in error message.
904 (elf32_arm_final_link_relocate): Likewise.
905 * coff-arm.c (bfd_arm_process_before_allocation): Likewise.
906 * coffcode.h (styp_to_sec_flags): Likewise.
907 * cofflink.c (_bfd_coff_write_global_sym): Likewise.
908 * ecoff.c (_bfd_ecoff_slurp_symbol_table): Likewise.
909 * elf32-arc.c (arc_elf_merge_private_bfd_data): Likewise.
910 * elf32-bfin.c (bfinfdpic_check_relocs): Likewise.
911 (elf32_bfin_merge_private_bfd_data): Likewise.
912 * elf32-cris.c (cris_elf_relocate_section): Likewise.
913 * elf32-frv.c (frv_elf_merge_private_bfd_data): Likewise.
914 * elf32-i370.c (i370_elf_merge_private_bfd_data): Likewise.
915 (i370_elf_relocate_section): Likewise.
916 * elf32-iq2000.c (iq2000_elf_merge_private_bfd_data): Likewise.
917 * elf32-m32c.c (m32c_elf_merge_private_bfd_data): Likewise.
918 * elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Likewise.
919 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
920 * elf32-mep.c (mep_elf_merge_private_bfd_data): Likewise.
921 * elf32-mt.c (mt_elf_merge_private_bfd_data): Likewise.
922 * elf64-sparc.c (elf64_sparc_merge_private_bfd_data): Likewise.
923 * elfxx-mips.c (mips_elf_merge_obj_e_flags): Likewise.
924 (_bfd_mips_elf_merge_private_bfd_data): Likewise.
925 * ieee.c (ieee_write_id, read_id): Likewise.
926 * mach-o.c (bfd_mach_o_write_contents): Likewise.
927 (bfd_mach_o_layout_commands, bfd_mach_o_read_section_32): Likewise.
928 (bfd_mach_o_read_section_64, bfd_mach_o_read_symtab_symbol): Likewise.
929 (bfd_mach_o_read_command, bfd_mach_o_header_p): Likewise.
930 * peXXigen.c (_bfd_XXi_swap_aouthdr_in): Likewise.
931 * stabs.c (_bfd_link_section_stabs): Likewise.
932
933 * coff-arm.c (coff_arm_relocate_section): Use L modifier in error
934 format.
935 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
936 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
937 * coff-rs6000.c (xcoff_reloc_type_toc): Likewise.
938 * coff-sh.c (sh_relax_section): Likewise.
939 (sh_relax_delete_bytes, sh_swap_insns): Likewise.
940 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
941 * coffcode.h (coff_slurp_reloc_table): Likewise.
942 * coffgen.c (_bfd_coff_get_external_symbols): Likewise.
943 (_bfd_coff_read_string_table): Likewise.
944 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
945 * compress.c (bfd_get_full_section_contents): Likewise.
946 * dwarf2.c (read_formatted_entries, decode_line_info): Likewise.
947 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
948 * elf.c (bfd_elf_string_from_elf_section): Likewise.
949 * elf32-arc.c (arc_special_overflow_checks): Likewise.
950 * elf32-arm.c (elf32_arm_tls_relax): Likewise.
951 (elf32_arm_final_link_relocate, elf32_arm_relocate_section): Likewise.
952 (elf32_arm_write_section): Likewise.
953 * elf32-bfin.c (bfin_relocate_section): Likewise.
954 (bfinfdpic_relocate_section): Likewise.
955 * elf32-hppa.c (hppa_build_one_stub): Likewise.
956 (final_link_relocate, elf32_hppa_relocate_section): Likewise.
957 * elf32-i386.c (elf_i386_tls_transition): Likewise.
958 (elf_i386_relocate_section): Likewise.
959 * elf32-ip2k.c (ip2k_final_link_relocate): Likewise.
960 * elf32-lm32.c (lm32_elf_finish_dynamic_sections): Likewise.
961 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
962 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
963 * elf32-metag.c (elf_metag_relocate_section): Likewise.
964 * elf32-nds32.c (unrecognized_reloc_msg): Likewise.
965 (nds32_elf_relax_longcall1, nds32_elf_relax_longcall2): Likewise.
966 (nds32_elf_relax_longcall3, nds32_elf_relax_longjump1): Likewise.
967 (nds32_elf_relax_longjump2, nds32_elf_relax_longjump3): Likewise.
968 (nds32_elf_relax_longcall4, nds32_elf_relax_longcall5): Likewise.
969 (nds32_elf_relax_longcall6, nds32_elf_relax_longjump4): Likewise.
970 (nds32_elf_relax_longjump5, nds32_elf_relax_longjump6): Likewise.
971 (nds32_elf_relax_longjump7, nds32_elf_relax_loadstore): Likewise.
972 (nds32_elf_relax_ptr, nds32_elf_ex9_build_hash_table): Likewise.
973 * elf32-nios2.c (nios2_elf32_relocate_section): Likewise.
974 * elf32-rx.c (UNSAFE_FOR_PID): Likewise.
975 * elf32-s390.c (invalid_tls_insn, elf_s390_relocate_section): Likewise.
976 * elf32-score.c (s3_bfd_score_elf_check_relocs): Likewise.
977 * elf32-score7.c (s7_bfd_score_elf_check_relocs): Likewise.
978 * elf32-sh.c (sh_elf_relax_section): Likewise.
979 (sh_elf_relax_delete_bytes, sh_elf_swap_insns): Likewise.
980 (sh_elf_relocate_section): Likewise.
981 * elf32-sh64.c (shmedia_prepare_reloc): Likewise.
982 * elf32-spu.c (spu_elf_relocate_section): Likewise.
983 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
984 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
985 * elf32-v850.c (v850_elf_relax_section): Likewise.
986 * elf32-vax.c (elf_vax_check_relocs): Likewise.
987 (elf_vax_relocate_section): Likewise.
988 * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
989 (extend_ebb_bounds_forward, extend_ebb_bounds_backward): Likewise.
990 (compute_text_actions, compute_ebb_proposed_actions): Likewise.
991 (do_fix_for_relocatable_link): Likewise.
992 * elf64-alpha.c (elf64_alpha_relax_got_load): Likewise.
993 (elf64_alpha_relax_with_lituse): Likewise.
994 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Likewise.
995 (elf_hppa_final_link_relocate): Likewise.
996 * elf64-ia64-vms.c (elf64_ia64_relax_section): Likewise.
997 (elf64_ia64_choose_gp, elf64_ia64_relocate_section): Likewise.
998 (elf64_vms_link_add_object_symbols): Likewise.
999 * elf64-mmix.c (mmix_elf_perform_relocation): Likewise.
1000 (mmix_final_link_relocate): Likewise.
1001 * elf64-s390.c (invalid_tls_insn): Likewise.
1002 (elf_s390_relocate_section): Likewise.
1003 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
1004 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
1005 (elf_x86_64_relocate_section): Likewise.
1006 * elfcode.h (elf_slurp_symbol_table): Likewise.
1007 * elfcore.h (elf_core_file_p): Likewise.
1008 * elflink.c (elf_link_read_relocs_from_section): Likewise.
1009 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
1010 (elfNN_aarch64_relocate_section): Likewise.
1011 * elfnn-ia64.c (elfNN_ia64_relax_section): Likewise.
1012 (elfNN_ia64_choose_gp, elfNN_ia64_relocate_section): Likewise.
1013 * elfnn-riscv.c (riscv_elf_relocate_section): Likewise.
1014 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
1015 (_bfd_mips_elf_relocate_section): Likewise.
1016 (_bfd_mips_elf_finish_dynamic_symbol, mips_finish_exec_plt): Likewise.
1017 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1018 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
1019 * ieee.c (ieee_slurp_external_symbols): Likewise.
1020 * ihex.c (ihex_write_object_content): Likewise.
1021 * mach-o.c (bfd_mach_o_build_exec_seg_command): Likewise.
1022 * merge.c (_bfd_merged_section_offset): Likewise.
1023 * mmo.c (mmo_write_loc_chunk): Likewise.
1024 (mmo_write_object_contents): Likewise.
1025 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Likewise.
1026 * stabs.c (_bfd_link_section_stabs): Likewise.
1027 * xcofflink.c (xcoff_link_add_symbols, xcoff_find_tc0): Likewise.
1028
e3fbc3da
AM
10292017-07-11 Alan Modra <amodra@gmail.com>
1030
1031 * elf32-ppc.c (ppc_elf_relocate_section): Fix typo.
1032
2c4d9cbe
AM
10332017-07-11 Alan Modra <amodra@gmail.com>
1034
1035 * elf32-ppc.c (ppc_elf_relocate_section): Emit "unexpected
1036 instruction" error using _bfd_error_handler, not einfo.
1037
adce5b39
NC
10382017-07-10 Nick Clifton <nickc@redhat.com>
1039
1040 * coffcode.h (coff_slurp_symbol_table): Do not include an entry
1041 for C_AIX_WEAKEXT if it has the same value as C_WEAKEXT.
1042
e6f3b9c3
JB
10432017-07-07 John Baldwin <jhb@FreeBSD.org>
1044
1045 * elf.c (elfcore_grok_freebsd_note): Handle NT_FREEBSD_PTLWPINFO.
1046
532cc313
AM
10472017-07-07 Alan Modra <amodra@gmail.com>
1048
1049 * coffcode.h (coff_slurp_symbol_table): Handle C_AIX_WEAKEXT.
1050
1cf9552b
AM
10512017-07-07 Alan Modra <amodra@gmail.com>
1052
1053 * bfd.c (_doprnt): Replace "L" with "ll" when printing bfd_vma
1054 as long long. Move code replacing "ll" with "I64", and simplify.
1055
a0b7b105
L
10562017-07-06 H.J. Lu <hongjiu.lu@intel.com>
1057
1058 * bfd.c (_doprnt): Convert 'L' to 'l' when setting wide_width
1059 to 1.
1060
1d827a72
L
10612017-07-05 H.J. Lu <hongjiu.lu@intel.com>
1062
1063 * dwarf2.c (line_info_add_include_dir_stub): Replace time with
1064 xtime.
1065 (line_info_add_file_name): Likewise.
1066 (decode_line_info): Likewise.
1067
0d702cfe
TG
10682017-07-04 Tristan Gingold <gingold@adacore.com>
1069
1070 * version.m4: Bump version to 2.29.51
1071 * configure: Regenerate.
1072
564e46b7
JW
10732017-07-04 Jiong Wang <jiong.wang@arm.com>
1074
1075 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Remove the
1076 sanity check at the head of this function.
1077
0041f7df
JK
10782017-07-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1079
1080 * dwarf2.c (struct dwarf2_debug): Add fields dwarf_line_str_buffer and
1081 dwarf_line_str_size.
1082 (struct attr_abbrev): Add field implicit_const.
1083 (dwarf_debug_sections): Add .debug_line_str.
1084 (enum dwarf_debug_section_enum): Add debug_line_str and debug_max.
1085 (dwarf_debug_section_assert): Add static assertion.
1086 (read_indirect_line_string): New.
1087 (read_abbrevs): Support DW_FORM_implicit_const.
1088 (is_str_attr): Support DW_FORM_line_strp.
1089 (read_attribute_value): Support DW_FORM_line_strp and
1090 DW_FORM_implicit_const.
1091 (read_attribute): Support DW_FORM_implicit_const.
1092 (line_info_add_include_dir, line_info_add_include_dir_stub):
1093 (line_info_add_file_name, read_formatted_entries): New.
1094 (decode_line_info, parse_comp_unit): Support DWARF 5.
1095 (_bfd_dwarf2_cleanup_debug_info): Free dwarf_line_str_buffer.
1096
d8cd8c1f
EB
10972017-07-03 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
1098
1099 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Remove the
1100 abort statement that was put for symbols that are not dynamic.
1101
15e6ed8c
TG
11022017-07-03 Tristan Gingold <gingold@adacore.com>
1103
1104 * po/bfd.pot: Regenerate
1105
76cfced5
AM
11062017-07-03 Alan Modra <amodra@gmail.com>
1107
1108 * bfd.c (_doprnt): Rewrite "ll" and "L" modifiers to "I64" for
1109 __MSVCRT__. Support "L" modifier for bfd_vma. Formatting.
1110 * elf.c (setup_group): Use "Lx" to print sh_size.
1111 (_bfd_elf_setup_sections): Remove unnecessary cast and print
1112 unknown section type in hex.
1113 (copy_special_section_fields): Style fix.
1114 (bfd_section_from_shdr): Correct format for sh_link. Use a
1115 common error message for all the variants of unrecognized
1116 section types.
1117 (assign_file_positions_for_load_sections): Use "Lx" for lma
1118 adjust error message.
1119 (assign_file_positions_for_non_load_sections): Formatting.
1120 (rewrite_elf_program_header): Formatting. Use "Lx" for
1121 bfd_vma values in error messages.
1122 * elfcode.h (elf_slurp_reloc_table_from_section): Cast
1123 ELF_R_SYM value to type expected by format.
1124 * elflink.c (elf_link_read_relocs_from_section): Use "Lx"
1125 in error messages.
1126 (elf_link_add_object_symbols): Use "Lu" for symbol sizes.
1127 (elf_link_input_bfd): Use "Lx" for r_info.
1128 (bfd_elf_gc_record_vtinherit): Use "Lx" for offset.
1129
ce9116fd
AM
11302017-07-03 Alan Modra <amodra@gmail.com>
1131
1132 * bfd.c (bfd_scan_vma): Don't use long long unless HAVE_LONG_LONG.
1133 * coff-rs6000.c (FMT20): Handle hosts with 64-bit long and
1134 Microsoft C library variant of long long format specifier.
1135 (PRINT20): Cast value to bfd_uint64_t not long long.
1136 * coffcode.h (coff_print_aux): Use BFD_VMA_FMT.
1137 * coff-x86_64.c (coff_amd64_reloc): Use bfd_uint64_t rather than
1138 long long. Don't cast to bfd_vma.
1139 * elf32-score.c (score3_bfd_getl48): Likewise.
1140 * vms-alpha.c (_bfd_vms_slurp_eisd): Likewise.
1141
cd9af601
AM
11422017-07-03 Alan Modra <amodra@gmail.com>
1143
1144 * elf.c (_bfd_elf_print_private_bfd_data): Use BFD_VMA_FMT to
1145 print d_tag.
1146 (bfd_elf_print_symbol): Don't cast symbol->flags.
1147 (_bfd_elf_symbol_from_bfd_symbol): Likewise.
1148 * elf32-ppc.c (ppc_elf_begin_write_processing): Correct
1149 _bfd_error_handler argument order.
1150 (ppc_elf_merge_private_bfd_data): Don't cast flags.
1151
33c734b2
AM
11522017-07-03 Alan Modra <amodra@gmail.com>
1153
1154 * configure.ac: Invoke AC_CHECK_TYPES for long long. Invoke
1155 AC_TYPE_LONG_DOUBLE.
1156 * configure: Regenerate.
1157 * config.in: Regenerate.
1158
3df5cd13
AW
11592017-06-29 Andrew Waterman <andrew@sifive.com>
1160
1161 * elfnn-riscv.c (riscv_elf_adjust_dynamic_symbol): Fix TLS copy
1162 relocs.
1163
ec1acaba
EB
11642017-06-29 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
1165
1166 * elfxx-sparc.c (allocate_dynrelocs): Don't make a symbol dynamic
1167 unless it is undefined weak.
1168 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Set the flag
1169 relative_reloc to direct non-dynamic symbols to R_SPARC_RELATIVE
1170 relocation.
1171 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): If symbol
1172 is not dynamic in PIC, abort.
1173
ff07562f
JW
11742017-06-29 Jiong Wang <jiong.wang@arm.com>
1175
1176 PR ld/21402
1177 * elfnn-aarch64.c (elfNN_aarch64_allocate_dynrelocs): Only make
1178 undefined weak symbols into dynamic.
1179 (elfNN_aarch64_final_link_relocate): Generate runtime RELATIVE
1180 relocation for non-dynamic symbols.
1181 (elfNN_aarch64_finish_dynamic_symbol): Add sanity check.
1182
2aff25ba
JW
11832017-06-29 Jiong Wang <jiong.wang@arm.com>
1184
1185 * elfnn-aarch64.c (aarch64_relocation_aginst_gp_p): New function.
1186 (elfNN_aarch64_final_link_relocate): Delete duplicated code for
1187 BFD_RELOC_AARCH64_LD64_GOTOFF_LO15, BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC,
1188 BFD_RELOC_AARCH64_MOVW_GOTOFF_G1.
1189 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Optimize the
1190 support for them.
1191
88ab90e8
AA
11922017-06-29 Andreas Arnez <arnez@linux.vnet.ibm.com>
1193
1194 * elf-bfd.h (elfcore_write_s390_gs_cb): Add prototype.
1195 (elfcore_write_s390_gs_bc): Likewise.
1196 * elf.c (elfcore_grok_s390_gs_cb): New function.
1197 (elfcore_grok_s390_gs_bc): New function.
1198 (elfcore_grok_note): Call them.
1199 (elfcore_write_s390_gs_cb): New function.
1200 (elfcore_write_s390_gs_bc): New function.
1201 (elfcore_write_register_note): Call them.
1202
328ce951
L
12032017-06-28 H.J. Lu <hongjiu.lu@intel.com>
1204
1205 * libbfd.c (_bfd_generic_get_section_contents): Don't call
1206 bfd_get_file_size. Check archive element size.
1207 (_bfd_generic_get_section_contents_in_window): Likewise.
1208
47fdcf63
L
12092017-06-28 H.J. Lu <hongjiu.lu@intel.com>
1210
1211 * bfd-in2.h: Regenerated.
1212 * bfdio.c (bfd_get_size): Change return type to ufile_ptr.
1213 (bfd_get_file_size): Likewise.
1214
38bf472a
MR
12152017-06-28 Maciej W. Rozycki <macro@imgtec.com>
1216 Matthew Fortune <matthew.fortune@imgtec.com>
1217
1218 * archures.c (bfd_mach_mips_interaptiv_mr2): New macro.
1219 * cpu-mips.c (I_interaptiv_mr2): New enum value.
1220 (arch_info_struct): Add "mips:interaptiv-mr2" entry.
1221 * elfxx-mips.c (_bfd_elf_mips_mach) <E_MIPS_MACH_IAMR2>: New
1222 case.
1223 (mips_set_isa_flags) <bfd_mach_mips_interaptiv_mr2>: Likewise.
1224 (bfd_mips_isa_ext) <bfd_mach_mips_interaptiv_mr2>: Likewise.
1225 (print_mips_isa_ext) <AFL_EXT_INTERAPTIV_MR2>: Likewise.
1226 (mips_mach_extensions): Add `bfd_mach_mipsisa32r3' and
1227 `bfd_mach_mips_interaptiv_mr2' entries.
1228 * bfd-in2.h: Regenerate.
1229
2d68166e
NC
12302017-06-27 Nick Clifton <nickc@redhat.com>
1231
1232 * tekhex.c (pass_over): Revert accidental conversion of a local
1233 array to a static array.
1234
68063779
SKS
12352017-06-27 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
1236
1237 PR ld/13402
1238 * elf32-avr.c (elf32_avr_adjust_diff_reloc_value): Adjust
1239 reloc addend if necessary. Adjust diff only if
1240 shrinked_insn_address < end_address.
1241
ea9aafc4
AM
12422017-06-27 Alan Modra <amodra@gmail.com>
1243
1244 PR binutils/21665
1245 * libbfd.c (_bfd_generic_get_section_contents): Warning fix.
1246 (_bfd_generic_get_section_contents_in_window): Likewise.
1247
a6cbf936
KLC
12482017-06-26 Kuan-Lin Chen <rufus@andestech.com>
1249
1250 * elfnn-riscv.c (perform_relocation): Support the new
1251 R_RISCV_32_PCREL relocation.
1252 (riscv_elf_relocate_section): Likewise.
1253 * elfxx-riscv.c (howto_table): Likewise.
1254 (riscv_reloc_map): Likewise.
1255 * bfd-in2.h (BFD_RELOC_RISCV_32_PCREL): New relocation.
1256 * libbfd.h: Regenerate.
1257
7211ae50
AM
12582017-06-27 Alan Modra <amodra@gmail.com>
1259
1260 PR binutils/21665
1261 * libbfd.c (_bfd_generic_get_section_contents): Delete abort.
1262 Use unsigned file pointer type, and remove cast.
1263 * libbfd.c (_bfd_generic_get_section_contents_in_window): Likewise.
1264 Add "count", not "sz".
1265
ab27f80c
PA
12662017-06-26 Pedro Alves <palves@redhat.com>
1267
1268 PR binutils/21665
1269 * libbfd.c (_bfd_generic_get_section_contents): Add "count", not
1270 "sz".
1271
1f473e3d
L
12722017-06-26 H.J. Lu <hongjiu.lu@intel.com>
1273
1274 PR binutils/21665
1275 * libbfd.c (_bfd_generic_get_section_contents_in_window): Add
1276 a missing line.
1277
b417536f
MR
12782017-06-26 Maciej W. Rozycki <macro@imgtec.com>
1279
1280 * cpu-mips.c (arch_info_struct): Mark the 4010 32-bit.
1281 * elfxx-mips.c (mips_set_isa_flags) <bfd_mach_mips4010>: Set
1282 E_MIPS_ARCH_2 rather than E_MIPS_ARCH_3 in `e_flags'.
1283 (mips_mach_extensions): Mark `bfd_mach_mips4010' as extending
1284 `bfd_mach_mips6000' rather than `bfd_mach_mips4000'.
1285
0630b49c
L
12862017-06-26 H.J. Lu <hongjiu.lu@intel.com>
1287
1288 PR binutils/21665
1289 * compress.c (bfd_get_full_section_contents): Don't check the
1290 file size here.
1291 * libbfd.c (_bfd_generic_get_section_contents): Check for and
ea9aafc4 1292 reject a section whose size + offset is greater than the size
0630b49c
L
1293 of the entire file.
1294 (_bfd_generic_get_section_contents_in_window): Likewise.
515a4464 1295
04e15b4a
NC
12962017-06-26 Nick Clifton <nickc@redhat.com>
1297
1298 PR binutils/21670
1299 * tekhex.c (getvalue): Check for the source pointer exceeding the
1300 end pointer before the first byte is read.
1301
cfd14a50
NC
13022017-06-26 Nick Clifton <nickc@redhat.com>
1303
1304 PR binutils/21665
ea9aafc4 1305 * opncls.c (get_build_id): Check that the section is big enough
cfd14a50
NC
1306 to contain the whole note.
1307 * compress.c (bfd_get_full_section_contents): Check for and reject
ea9aafc4 1308 a section whose size is greater than the size of the entire file.
cfd14a50
NC
1309 * elf32-v850.c (v850_elf_copy_notes): Allow for the ouput to not
1310 contain a notes section.
1311
93ec5e23
AK
13122017-06-26 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
1313
1314 * elf64-s390.c (elf_s390_additional_program_headers): Add NULL
1315 pointer checks.
1316 (elf_s390_modify_segment_map): Likewise.
1317 (bfd_elf_s390_set_options): Lisewise.
1318
57963c05
AM
13192017-06-26 Alan Modra <amodra@gmail.com>
1320
1321 * elflink.c (_bfd_elf_link_create_dynstrtab): Don't make dynobj
1322 a --just-syms bfd.
1323 (_bfd_elf_size_group_sections): Skip --just-syms bfds.
1324 (bfd_elf_size_dynamic_sections): Ignore .note.GNU-stack and
1325 .preinit_array on --just-syms bfds.
1326 (_bfd_elf_gc_mark_extra_sections): Skip --just-syms bfds.
1327 (elf_gc_sweep, bfd_elf_parse_eh_frame_entries): Likewise.
1328 (bfd_elf_gc_sections, bfd_elf_discard_info): Likewise.
1329
5cc4ca83
ST
13302017-06-25 Sergei Trofimovich <slyfox@gentoo.org>
1331
1332 * elf.c (find_link): Bounds check "hint".
1333
bff0500d
TP
13342017-06-24 Thomas Preud'homme <thomas.preudhomme@arm.com>
1335
1336 * elf32-arm.c (using_thumb_only): Update list of architectures in
1337 BFD_ASSERT for which the logic is valid.
1338 (using_thumb2_bl): Likewise.
1339 (using_thumb2): Likewise and return true for ARMv8-R.
1340 (arch_has_arm_nop): Likewise.
1341 (tag_cpu_arch_combine): New v8r table for ARMv8-R Tag_CPU_arch
1342 merging logic. Update commentis for value 15 of v8m_baseline,
1343 v8m_mainline and v4t_plus_v6_m arrays. Use v8r array to decide
1344 merging of value 15 of Tag_CPU_arch.
1345
4aa57d6a
JW
13462017-06-23 Jiong Wang <jiong.wang@arm.com>
1347
1348 * reloc.c (BFD_RELOC_AARCH64_ADR_GOTPAGE): Rename to
1349 BFD_RELOC_AARCH64_ADR_GOT_PAGE
1350 * bfd-in2.h: Regenerate.
1351
5d8763a3
L
13522017-06-22 H.J. Lu <hongjiu.lu@intel.com>
1353
1354 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Move
1355 the error_alignment label forward. Properly align program
1356 property note section.
1357
e652757b
EC
13582017-06-22 Eric Christopher <echristo@gmail.com>
1359
1360 * elf32-arm.c (elf32_arm_final_link_relocate): Use labs rather than
1361 abs to fix a truncation warning.
1362
84da4cf8
L
13632017-06-22 H.J. Lu <hongjiu.lu@intel.com>
1364
1365 * elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Resolve
1366 local undefined weak symbol to 0.
1367 * elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Likewise.
1368
48580982
L
13692017-06-22 H.J. Lu <hongjiu.lu@intel.com>
1370
1371 * elf32-i386.c (elf_i386_merge_gnu_properties): If info->shstk
1372 is set, turn on GNU_PROPERTY_X86_FEATURE_1_SHSTK.
1373 (elf_i386_link_setup_gnu_properties): If info->shstk is set,
1374 turn on GNU_PROPERTY_X86_FEATURE_1_IBT.
1375 * elf64-x86-64.c (elf_x86_64_merge_gnu_properties): If
1376 info->shstk is set, turn on GNU_PROPERTY_X86_FEATURE_1_SHSTK.
1377 (elf_x86_64_link_setup_gnu_properties): If info->shstk is set,
1378 turn on GNU_PROPERTY_X86_FEATURE_1_IBT.
1379
ee2fdd6f
L
13802017-06-22 H.J. Lu <hongjiu.lu@intel.com>
1381
1382 * elf32-i386.c (elf_i386_lazy_ibt_plt0_entry): New.
1383 (elf_i386_lazy_ibt_plt_entry): Likewise.
1384 (elf_i386_pic_lazy_ibt_plt0_entry): Likewise.
1385 (elf_i386_non_lazy_ibt_plt_entry): Likewise.
1386 (elf_i386_pic_non_lazy_ibt_plt_entry): Likewise.
1387 (elf_i386_eh_frame_lazy_ibt_plt): Likewise.
1388 (elf_i386_lazy_plt_layout): Likewise.
1389 (elf_i386_non_lazy_plt_layout): Likewise.
1390 (elf_i386_link_hash_entry): Add plt_second.
1391 (elf_i386_link_hash_table): Add plt_second and
1392 plt_second_eh_frame.
1393 (elf_i386_allocate_dynrelocs): Use the second PLT if needed.
1394 (elf_i386_size_dynamic_sections): Use .plt.got unwind info for
1395 the second PLT. Check the second PLT.
1396 (elf_i386_relocate_section): Use the second PLT to resolve
1397 PLT reference if needed.
1398 (elf_i386_finish_dynamic_symbol): Fill and use the second PLT if
1399 needed.
1400 (elf_i386_finish_dynamic_sections): Set sh_entsize on the
1401 second PLT. Generate unwind info for the second PLT.
1402 (elf_i386_plt_type): Add plt_second.
1403 (elf_i386_get_synthetic_symtab): Support the second PLT.
1404 (elf_i386_parse_gnu_properties): Support
1405 GNU_PROPERTY_X86_FEATURE_1_AND.
1406 (elf_i386_merge_gnu_properties): Support
1407 GNU_PROPERTY_X86_FEATURE_1_AND. If info->ibt is set, turn
1408 on GNU_PROPERTY_X86_FEATURE_1_IBT
1409 (elf_i386_link_setup_gnu_properties): If info->ibt is set,
1410 turn on GNU_PROPERTY_X86_FEATURE_1_IBT. Use IBT-enabled PLT
1411 for info->ibtplt, info->ibt or GNU_PROPERTY_X86_FEATURE_1_IBT
1412 is set on all relocatable inputs.
1413 * elf64-x86-64.c (elf_x86_64_lazy_ibt_plt_entry): New.
1414 (elf_x32_lazy_ibt_plt_entry): Likewise.
1415 (elf_x86_64_non_lazy_ibt_plt_entry): Likewise.
1416 (elf_x32_non_lazy_ibt_plt_entry): Likewise.
1417 (elf_x86_64_eh_frame_lazy_ibt_plt): Likewise.
1418 (elf_x32_eh_frame_lazy_ibt_plt): Likewise.
1419 (elf_x86_64_lazy_ibt_plt): Likewise.
1420 (elf_x32_lazy_ibt_plt): Likewise.
1421 (elf_x86_64_non_lazy_ibt_plt): Likewise.
1422 (elf_x32_non_lazy_ibt_plt): Likewise.
1423 (elf_x86_64_get_synthetic_symtab): Support the second PLT.
1424 (elf_x86_64_parse_gnu_properties): Support
1425 GNU_PROPERTY_X86_FEATURE_1_AND.
1426 (elf_x86_64_merge_gnu_properties): Support
1427 GNU_PROPERTY_X86_FEATURE_1_AND. If info->ibt is set, turn
1428 on GNU_PROPERTY_X86_FEATURE_1_IBT
1429 (elf_x86_64_link_setup_gnu_properties): If info->ibt is set,
1430 turn on GNU_PROPERTY_X86_FEATURE_1_IBT. Use IBT-enabled PLT
1431 for info->ibtplt, info->ibt or GNU_PROPERTY_X86_FEATURE_1_IBT
1432 is set on all relocatable inputs.
1433
d19237d9
NC
14342017-06-22 Nick Clifton <nickc@redhat.com>
1435
1436 PR binutils/21649
1437 * som.c (setup_sections): NUL terminate the space_strings buffer.
1438 Check that the space.name field does not index beyond the end of
1439 the space_strings buffer.
1440
6879f5a9
NC
14412017-06-21 Nick Clifton <nickc@redhat.com>
1442
1443 PR binutils/21646
1444 * coff-sh.c (sh_reloc): Check for an out of range reloc.
1445
7adc0a81
NC
14462017-06-21 Nick Clifton <nickc@redhat.com>
1447
1448 PR binutils/21639
1449 * vms-misc.c (_bfd_vms_save_sized_string): Use unsigned int as
1450 type of the size parameter.
1451 (_bfd_vms_save_counted_string): Add second parameter - the maximum
1452 length of the counted string.
1453 * vms.h (_bfd_vms_save_sized_string): Update prototype.
1454 (_bfd_vms_save_counted_string): Likewise.
1455 * vms-alpha.c (_bfd_vms_slurp_eisd): Update calls to
1456 _bfd_vms_save_counted_string.
1457 (_bfd_vms_slurp_ehdr): Likewise.
1458 (_bfd_vms_slurp_egsd): Likewise.
1459 (Parse_module): Likewise.
1460
6e1816be
AM
14612017-06-21 Alan Modra <amodra@gmail.com>
1462
1463 * elf64-ppc.c (ppc64_elf_size_stubs): Test for localentry:0 plt
1464 calls before tocsave calls.
1465 (ppc64_elf_relocate_section): Allow localentry:0 plt calls without
1466 following nop.
1467
20bd1b6b
NC
14682017-06-21 Nick Clifton <nickc@redhat.com>
1469
1470 PR binutils/21645
1471 * reloc.c (bfd_generic_get_relocated_section_contents): Fail if
1472 bfd_get_full_section_contents returns no contents.
1473
3de58d95
NC
14742017-06-21 Nick Clifton <nickc@redhat.com>
1475
1476 PR binutils/21638
1477 * vms-alpha.c (_bfd_vms_slurp_egsd): Check for an undersized
1478 record.
1479
cb06d03a
NC
14802017-06-21 Nick Clifton <nickc@redhat.com>
1481
1482 PR binutils/21637
1483 * vms-alpha.c (_bfd_vms_slurp_egsd): Check for an empty section
1484 list.
1485 (image_set_ptr): Likewise.
1486 (alpha_vms_fix_sec_rel): Likewise.
1487 (alpha_vms_slurp_relocs): Likewise.
1488
c458d007
NC
14892017-06-21 Nick Clifton <nickc@redhat.com>
1490
1491 PR binutils/21633
1492 * ieee.c (ieee_slurp_sections): Check for a NULL return from
1493 read_id.
1494 (ieee_archive_p): Likewise.
1495 (ieee_object_p): Likewise.
1496
ce497010
NC
14972017-06-21 Nick Clifton <nickc@redhat.com>
1498
1499 PR binutils/21640
1500 * elf.c (setup_group): Zero the group section pointer list after
1501 allocation so that loops can be caught. Check for NULL pointers
1502 when processing a group list.
1503
fd52715c
AK
15042017-06-20 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
1505
1506 * elf-s390.h: New file.
1507 * elf64-s390.c (struct elf_s390_link_hash_table): Add params
1508 field.
1509 (elf_s390_additional_program_headers): New function.
1510 (elf_s390_modify_segment_map): New function.
1511 (bfd_elf_s390_set_options): New function.
1512 (elf_backend_additional_program_headers)
1513 (elf_backend_modify_segment_map): Add macro definitions.
1514
abfa390d
L
15152017-06-19 H.J. Lu <hongjiu.lu@intel.com>
1516
1517 PR ld/21626
1518 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Check
1519 the DYNAMIC bit instead of bfd_count_sections.
1520
bc21b167
NC
15212017-06-19 Nick Clifton <nickc@redhat.com>
1522
1523 PR binutils/21618
1524 * vms-alpha.c (evax_bfd_print_emh): Check for insufficient record
1525 length.
1526 (evax_bfd_print_eeom): Likewise.
1527 (evax_bfd_print_egsd): Check for an overlarge record length.
1528 (evax_bfd_print_etir): Likewise.
1529
acb56a83
NC
15302017-06-19 Nick Clifton <nickc@redhat.com>
1531
1532 PR binutils/21612
1533 * libieee.h (struct common_header_type): Add end_p field.
1534 * ieee.c (this_byte_and_next): Do not advance input_p beyond
1535 end_p.
1536 (read_id): Check for a length that exceeds the remaining bytes in
1537 the input buffer.
1538 (ieee_seek): Initialise end_p.
1539 (ieee_archive_p): Likewise.
1540 (ieee_object_p): Likewise.
1541
72e84f96
NC
15422017-06-19 Nick Clifton <nickc@redhat.com>
1543
80053e46
NC
1544 PR binutils/21611
1545 * vms-alpha.c (_bfd_vms_slurp_eihs): Check for invalid offset
1546 before reading the EIHS structure entries.
1547
15482017-06-19 Nick Clifton <nickc@redhat.com>
1549
1550 PR binutils/21615
72e84f96
NC
1551 * vms-alpha.c (_bfd_vms_slurp_egsd): Use unsigned int for
1552 gsd_size. Check that there are enough bytes remaining to read the
1553 type and size of the next egsd. Check that the size of the egsd
1554 does not exceed the size of the record.
1555
875ffa3e
AM
15562017-06-19 Alan Modra <amodra@gmail.com>
1557
1558 * config.bfd: Correct targ_underscore for cris.
1559
bdd32e03
AM
15602017-06-18 Alan Modra <amodra@gmail.com>
1561
1562 * config.bfd: Correct targ_underscore for epiphany, ip2k,
1563 m32c, mn10200, pru, rl78, rx, crisv32 and v850.
1564
4b48e2f6
NC
15652017-06-16 Nick Clifton <nickc@redhat.com>
1566
1567 * elflink.c (bfd_elf_size_dynsym_hash_dynstr): Do not fail if the
1568 bucketlist is empty because there are no symbols to add to the
1569 list.
1570
7dba9362
AM
15712017-06-16 Alan Modra <amodra@gmail.com>
1572
1573 PR ld/20022
1574 PR ld/21557
1575 PR ld/21562
1576 PR ld/21571
1577 * targets.c (struct bfd_target): Add _bfd_define_start_stop.
1578 (BFD_JUMP_TABLE_LINK): Likewise.
1579 * elf-bfd.h (bfd_elf_define_start_stop): Declare.
1580 * elflink.c (_bfd_elf_gc_mark_rsec): Update comment.
1581 (bfd_elf_define_start_stop): New function.
1582 * linker.c (bfd_generic_define_start_stop): New function.
1583 * coff64-rs6000.c (rs6000_xcoff64_vec, rs6000_xcoff64_aix_vec): Init
1584 new field.
1585 * aout-adobe.c (aout_32_bfd_define_start_stop): Define.
1586 * aout-target.h (MY_bfd_define_start_stop): Define.
1587 * aout-tic30.c (MY_bfd_define_start_stop): Define.
1588 * binary.c (binary_bfd_define_start_stop): Define.
1589 * bout.c (b_out_bfd_define_start_stop): Define.
1590 * coff-alpha.c (_bfd_ecoff_bfd_define_start_stop): Define.
1591 * coff-mips.c (_bfd_ecoff_bfd_define_start_stop): Define.
1592 * coff-rs6000.c (_bfd_xcoff_bfd_define_start_stop): Define.
1593 * coffcode.h (coff_bfd_define_start_stop): Define.
1594 * elfxx-target.h (bfd_elfNN_bfd_define_start_stop): Define.
1595 * i386msdos.c (msdos_bfd_define_start_stop): Define.
1596 * i386os9k.c (os9k_bfd_define_start_stop): Define.
1597 * ieee.c (ieee_bfd_define_start_stop): Define.
1598 * ihex.c (ihex_bfd_define_start_stop): Define.
1599 * libbfd-in.h (_bfd_nolink_bfd_define_start_stop): Define.
1600 * mach-o-target.c (bfd_mach_o_bfd_define_start_stop): Define.
1601 * mmo.c (mmo_bfd_define_start_stop): Define.
1602 * nlm-target.h (nlm_bfd_define_start_stop): Define.
1603 * oasys.c (oasys_bfd_define_start_stop): Define.
1604 * pef.c (bfd_pef_bfd_define_start_stop): Define.
1605 * plugin.c (bfd_plugin_bfd_define_start_stop): Define.
1606 * ppcboot.c (ppcboot_bfd_define_start_stop): Define.
1607 * som.c (som_bfd_define_start_stop): Define.
1608 * srec.c (srec_bfd_define_start_stop): Define.
1609 * tekhex.c (tekhex_bfd_define_start_stop): Define.
1610 * versados.c (versados_bfd_define_start_stop): Define.
1611 * vms-alpha.c (vms_bfd_define_start_stop): Define.
1612 (alpha_vms_bfd_define_start_stop): Define.
1613 * xsym.c (bfd_sym_bfd_define_start_stop): Define.
1614 * bfd-in2.h: Regenerate.
1615 * libbfd.h: Regenerate.
1616
d68f1976
JW
16172017-06-16 Jiong Wang <jiong.wang@arm.com>
1618
1619 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Use
1620 SYMBOL_REFERENCES_LOCAL.
1621
6353d82b
JW
16222017-06-15 Jiong Wang <jiong.wang@arm.com>
1623
1624 PR ld/21532
1625 * elfnn-aarch64.c (ELIMINATE_COPY_RELOCS): Set to 1.
1626 (elfNN_aarch64_final_link_relocate): Also propagate relocations to
1627 runtime for if there needs copy relocation elimination.
1628 (need_copy_relocation_p): New function. Return true for symbol with
1629 pc-relative references and if it's against read-only sections.
1630 (elfNN_aarch64_adjust_dynamic_symbol): Use need_copy_relocation_p.
1631 (elfNN_aarch64_check_relocs): Allocate dynrelocs for relocation types
1632 that are related with accessing external objects.
1633 (elfNN_aarch64_gc_sweep_hook): Sync the relocation types with the change
1634 in elfNN_aarch64_check_relocs.
1635
63634bb4
NC
16362017-06-15 Nick Clifton <nickc@redhat.com>
1637
1638 PR binutils/21582
1639 * ieee.c (ieee_object_p): Use a static buffer to avoid compiler
1640 bugs.
62b76e4b
NC
1641 PR binutils/21581
1642 (ieee_archive_p): Likewise.
63634bb4 1643
76800cba
NC
16442017-06-15 Nick Clifton <nickc@redhat.com>
1645
1646 PR binutils/21579
1647 * vms-alpha.c (_bfd_vms_slurp_etir): Extend check of cmd_length.
1648
f7e16c2a
MF
16492017-06-14 Max Filippov <jcmvbkbc@gmail.com>
1650
1651 * elf32-xtensa.c (elf_xtensa_be_plt_entry,
1652 elf_xtensa_le_plt_entry): Add dimension for the ABI to arrays,
1653 keep both windowed and call0 ABI PLT definitions.
1654 (elf_xtensa_create_plt_entry): Use selected ABI to choose upper
1655 elf_xtensa_*_plt_entry endex.
1656 (ELF_MAXPAGESIZE): Fix at minimal supported MMU page size.
1657
f461bbd8
NC
16582017-06-14 Nick Clifton <nickc@redhat.com>
1659
1660 PR binutils/21578
1661 * elf32-sh.c (sh_elf_set_mach_from_flags): Fix check for invalid
1662 flag value.
1663
c53d2e6d
NC
16642017-06-14 Nick Clifton <nickc@redhat.com>
1665
1666 PR binutils/21589
1667 * vms-alpha.c (_bfd_vms_get_value): Add an extra parameter - the
1668 maximum value for the ascic pointer. Check that name processing
1669 does not read beyond this value.
1670 (_bfd_vms_slurp_etir): Add checks for attempts to read beyond the
1671 end of etir record.
1672
04f963fd
NC
16732017-06-14 Nick Clifton <nickc@redhat.com>
1674
1675 PR binutils/21591
1676 * versados.c (versados_mkobject): Zero the allocated tdata structure.
1677 (process_otr): Check for an invalid offset in the otr structure.
1678
319c2dbe
SH
16792017-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
1680
1681 * config.bfd (epiphany-*-elf): Accept epiphany-*-*.
1682
cbd0eecf
L
16832017-06-13 H.J. Lu <hongjiu.lu@intel.com>
1684
1685 PR ld/20022
1686 PR ld/21557
1687 PR ld/21562
1688 PR ld/21571
1689 * elf-bfd.h (elf_link_hash_entry): Add start_stop. Change the
1690 vtable field to a union.
1691 (_bfd_elf_is_start_stop): Removed.
1692 * elf32-i386.c (elf_i386_convert_load_reloc): Also check for
1693 __start_SECNAME and __stop_SECNAME symbols.
1694 * elf64-x86-64.c (elf_x86_64_convert_load_reloc): Likewise.
1695 * elflink.c (_bfd_elf_is_start_stop): Removed.
1696 (_bfd_elf_gc_mark_rsec): Check start_stop instead of calling
1697 _bfd_elf_is_start_stop.
1698 (elf_gc_propagate_vtable_entries_used): Skip __start_SECNAME and
1699 __stop_SECNAME symbols. Updated.
1700 (elf_gc_smash_unused_vtentry_relocs): Likewise.
1701 (bfd_elf_gc_record_vtinherit): Likewise.
1702 (bfd_elf_gc_record_vtentry): Likewise.
1703
10bbbc1d
NC
17042017-06-13 Nick Clifton <nickc@redhat.com>
1705
1706 PR ld/21524
1707 * elflink.c (elf_link_adjust_relocs): Generate an error when
1708 encountering a reloc against a symbol removed by garbage
1709 collection.
1710
5c3ce2bc
L
17112017-06-12 H.J. Lu <hongjiu.lu@intel.com>
1712
1713 * elf-bfd.h (elf_backend_data): Add struct bfd_link_info *
1714 to merge_gnu_properties.
1715 * elf-properties.c (elf_merge_gnu_properties): Add struct
1716 bfd_link_info * and pass it to merge_gnu_properties.
1717 (elf_merge_gnu_property_list): Add struct bfd_link_info *
1718 and pass it to elf_merge_gnu_properties.
1719 (_bfd_elf_link_setup_gnu_properties): Pass info to
1720 elf_merge_gnu_property_list.
1721 * elf32-i386.c (elf_i386_merge_gnu_properties): Add struct
1722 bfd_link_info *.
1723 * elf64-x86-64.c (elf_x86_64_merge_gnu_properties): Likewise.
1724
9b97dfbf
AM
17252017-06-11 Joe Zbiciak <joe.zbiciak@leftturnonly.info>
1726
1727 PR 21564
1728 * binary.c (binary_set_section_contents): Scale lma by octets
1729 per byte to set filepos.
1730
e3d1d408
CM
17312017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1732
1733 * elf32-arc.c (elf_arc_check_relocs): Fixed conditions to generate
1734 dynamic sections.
1735
64aa8e03
CM
17362017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1737
1738 * elf32-arc.c (elf_arc_size_dynamic_sections): Changed condition to
1739 require TEXTREL.
1740
a0abe743
CM
17412017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1742
1743 * arc-got.h (relocate_fix_got_relocs_for_got_info): Added TCB_SIZE to
1744 patched section contents for TLS IE reloc.
1745 * elf32-arc.c: Remove TCB_SIZE preprocessor macro.
1746
f4e6805f
CM
17472017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1748
1749 * elf32-arc.c (elf_arc_relocate_section): Added "call" to
1750 RELOC_FOR_GLOBAL_SYMBOL macro.
1751
cd640291
CM
17522018-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1753
1754 * elf32-arc.c (elf_arc_relocate_section): Small refactor and condition
1755 changes.
1756
7ef0acc1
VG
17572017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1758
1759 * config/tc-arc.c (md_undefined_symbol): Changed.
1760 * config/tc-arc.h (DYNAMIC_STRUCT_NAME): Removed.
1761
cc89d0b3
CM
17622017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1763
1764 * elf32-arc.c (elf_arc_relocate_section): Fixed reassign of indirect
1765 symbols.
1766
9d5c718b
CM
17672017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1768
1769 * elf32-arc.c (elf_arc_check_relocs): Added condition to disable
1770 warning and "Bad value" for local symbols ARC_32 or ARC_32_ME relocs.
1771
be9e3704
CM
17722017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1773
1774 * elf32-arc.c (ADD_RELA): Changed to only work when dynamic
1775 object is created.
1776
4ec192e6
RE
17772017-06-08 Richard Earnshaw <rearnsha@arm.com>
1778
1779 * elf32-arm.c (elf32_arm_merge_eabi_attributes): Remove assertion
1780 that the input bfd has Tag_FP_ARCH non-zero if Tag_ABI_HardFP_use
1781 is non-zero. Add clarifying comments.
1782
51fa2693
L
17832017-06-08 H.J. Lu <hongjiu.lu@intel.com>
1784
1785 * elf32-i386.c (elf_i386_check_relocs): Set local IFUNC symbol
1786 name. Use local IFUNC symbol name string to report unsupported
1787 non-PIC call to IFUNC function.
1788 (elf_i386_relocate_section): Dump local IFUNC name with minfo
1789 when generating R_386_IRELATIVE relocation.
1790 (elf_i386_finish_dynamic_symbol): Likewise.
1791 * elf_x86_64_check_relocs (elf_x86_64_check_relocs): Set local
1792 IFUNC symbol name.
1793 (elf_x86_64_relocate_section): Dump local IFUNC name with minfo
1794 when generating R_X86_64_IRELATIVE relocation.
1795 (elf_x86_64_finish_dynamic_symbol): Likewise.
1796
78e8a2ff
JM
17972017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
1798
1799 * elf.c (setup_group): Make sure BFD sections are created for all
1800 group sections in the input file when processing SHF_GROUP
1801 sections.
1802 (bfd_section_from_shdr): Avoid duplicating logic already
1803 implemented in `setup_group'.
1804
9949827b
DBR
18052017-06-06 Daniel Bonniot de Ruisselet <bonniot@gmail.com>
1806
1807 PR binutils/21546
1808 * peXXigen.c (pe_print_idata): Use the address of the first thunk
1809 if the hint address is zero.
1810
0ee3a6db
JC
18112017-06-06 James Clarke <jrtc27@jrtc27.com>
1812
1813 PR ld/19579
1814 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Check
1815 ELF_COMMON_DEF_P for common symbols.
1816
7bdf4127
AB
18172017-06-06 Andrew Burgess <andrew.burgess@embecosm.com>
1818
1819 * elf.c (_bfd_elf_make_section_from_shdr): Don't initially mark
1820 SEC_GROUP sections as SEC_EXCLUDE.
1821 (bfd_elf_set_group_contents): Replace use of abort with an assert.
1822 (assign_section_numbers): Use resolve_section_groups flag instead
1823 of relocatable link type.
1824 (_bfd_elf_init_private_section_data): Use resolve_section_groups
1825 flag instead of checking the final_link flag for part of the
1826 checks in here. Fix white space as a result.
1827 * elflink.c (elf_link_input_bfd): Use resolve_section_groups flag
1828 instead of relocatable link type.
1829 (bfd_elf_final_link): Likewise.
1830
458ad2b8
JM
18312017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
1832
1833 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Remove unused
1834 variable `bed'.
1835 * elf32-score.c (score_elf_final_link_relocate): Likewise.
1836 (s3_bfd_score_elf_check_relocs): Likewise.
1837 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1838 (score_elf_final_link_relocate): Likewise.
1839 (s7_bfd_score_elf_check_relocs): Likewise.
1840
fbebaf4a
JM
18412017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
1842
1843 * elflink.c (init_reloc_cookie_rels): Remove unused variable
1844 `bed'.
1845
056bafd4
MR
18462017-06-06 Maciej W. Rozycki <macro@imgtec.com>
1847
1848 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Subtract `count'
1849 from `reloc_count' rather than decrementing it.
1850 * elf.c (bfd_section_from_shdr): Multiply the adjustment to
1851 `reloc_count' by `int_rels_per_ext_rel'.
1852 * elf32-score.c (score_elf_final_link_relocate): Do not multiply
1853 `reloc_count' by `int_rels_per_ext_rel' for last relocation
1854 entry determination.
1855 (s3_bfd_score_elf_check_relocs): Likewise.
1856 * elf32-score7.c (score_elf_final_link_relocate): Likewise.
1857 (s7_bfd_score_elf_relocate_section): Likewise.
1858 (s7_bfd_score_elf_check_relocs): Likewise.
1859 * elf64-mips.c (mips_elf64_get_reloc_upper_bound): Remove
1860 prototype and function.
1861 (mips_elf64_slurp_one_reloc_table): Do not update `reloc_count'.
1862 (mips_elf64_slurp_reloc_table): Assert that `reloc_count' is
1863 triple rather than once the sum of REL and RELA relocation entry
1864 counts.
1865 (bfd_elf64_get_reloc_upper_bound): Remove macro.
1866 * elflink.c (_bfd_elf_link_read_relocs): Do not multiply
1867 `reloc_count' by `int_rels_per_ext_rel' for internal relocation
1868 storage allocation size determination.
1869 (elf_link_input_bfd): Multiply `.ctors' and `.dtors' section's
1870 size by `int_rels_per_ext_rel'. Do not multiply `reloc_count'
1871 by `int_rels_per_ext_rel' for last relocation entry
1872 determination.
1873 (bfd_elf_final_link): Do not multiply `reloc_count' by
1874 `int_rels_per_ext_rel' for internal relocation storage
1875 allocation size determination.
1876 (init_reloc_cookie_rels): Do not multiply `reloc_count' by
1877 `int_rels_per_ext_rel' for last relocation entry determination.
1878 (elf_gc_smash_unused_vtentry_relocs): Likewise.
1879 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
1880 (_bfd_mips_elf_relocate_section): Likewise.
1881
af54f0eb
AM
18822017-06-05 Alan Modra <amodra@gmail.com>
1883
1884 PR 21529
1885 * linker.c (_bfd_generic_link_output_symbols): Handle BSF_GNU_UNIQUE.
1886
6cf3bf88 18872017-06-01 John Baldwin <jhb@FreeBSD.org>
b5430a3c
JB
1888
1889 * elf.c (elfcore_grok_freebsd_psinfo): Use ELF header class to
1890 determine structure sizes.
1891 (elfcore_grok_freebsd_prstatus): Likewise.
1892
f378ab09
AM
18932017-06-01 Alan Modra <amodra@gmail.com>
1894
1895 * elf64-ppc.c (struct ppc_link_hash_table): Add has_plt_localentry0.
1896 (ppc64_elf_merge_symbol_attribute): Merge localentry bits from
1897 dynamic objects.
1898 (is_elfv2_localentry0): New function.
1899 (ppc64_elf_tls_setup): Default params->plt_localentry0.
1900 (plt_stub_size): Adjust size for tls_get_addr_opt stub.
1901 (build_tls_get_addr_stub): Use a simpler stub when r2 is not saved.
1902 (ppc64_elf_size_stubs): Leave stub_type as ppc_stub_plt_call for
1903 optimized localentry:0 stubs.
1904 (ppc64_elf_build_stubs): Save r2 in ELFv2 __glink_PLTresolve.
1905 (ppc64_elf_relocate_section): Leave nop unchanged for optimized
1906 localentry:0 stubs.
1907 (ppc64_elf_finish_dynamic_sections): Set PPC64_OPT_LOCALENTRY in
1908 DT_PPC64_OPT.
1909 * elf64-ppc.h (struct ppc64_elf_params): Add plt_localentry0.
1910
8c65b54f
CS
19112017-05-30 Casey Smith <clegg89@gmail.com>
1912
1913 PR ld/21523
1914 * elf32-arm.c (elf32_arm_final_link_relocate): Install an absolute
1915 value when processing the R_ARM_THM_ALU_PREL_11_0 reloc.
1916
64984c22
AK
19172017-05-30 Anton Kolesov Anton.Kolesov@synopsys.com
1918
1919 * cpu-arc.c (arc_compatible): New function.
1920
37cd3877
AK
19212017-05-30 Anton Kolesov <anton.kolesov@synopsys.com>
1922
1923 * cpu-arc.c (arch_info_struct): Remove duplicate ARC600 entry.
1924
8e2f54bc
L
19252017-05-30 H.J. Lu <hongjiu.lu@intel.com>
1926
1927 PR binutils/21519
1928 * bfdio.c (bfd_get_file_size): New function.
1929 * bfd-in2.h: Regenerated.
1930
8e7f04f1 19312017-05-23 Dilian Palauzov <git-dpa@aegee.org>
1932
1933 * elf32-arc.c (arc_elf_merge_attributes): Add fall through
1934 comments.
1935
25f94347
L
19362017-05-22 H.J. Lu <hongjiu.lu@intel.com>
1937
1938 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Use
1939 dynobj instead of htab->elf.dynobj.
1940
e5713223
MR
19412017-05-19 Maciej W. Rozycki <macro@imgtec.com>
1942
1943 * elf64-mips.c (mips_elf64_canonicalize_reloc): Remove prototype
1944 and function.
1945 (mips_elf64_canonicalize_dynamic_reloc): Likewise.
1946 (mips_elf64_slurp_one_reloc_table): Set `reloc_count' to the
1947 actual number of internal relocations retrieved. Adjust
1948 function description.
1949 (bfd_elf64_canonicalize_reloc): Remove macro.
1950 (bfd_elf64_canonicalize_dynamic_reloc): Likewise.
1951
64517994
JM
19522017-05-19 Jose E. Marchesi <jose.marchesi@oracle.com>
1953
1954 * archures.c (bfd_mach_sparc_v9m8): Define.
1955 (bfd_mach_sparc_v8plusm8): Likewise.
1956 (bfd_mach_sparc_v9_p): Adjust to M8.
1957 (bfd_mach_sparc_64bit_p): Likewise.
1958 * aoutx.h (machine_type): Handle bfd_mach_sparc_v9m8 and
1959 bfd_mach_sparc_v8plusm8.
1960 * bfd-in2.h: Regenerated.
1961 * cpu-sparc.c (arch_info_struct): Entries for sparc:v9m8 and
1962 sparc:v8plusm8.
1963 * elfxx-sparc.c (_bfd_sparc_elf_object_p): Handle
1964 bfd_mach_sparc_v8plusm8 and bfd_mach_sparc_v9m8 using the new hw
1965 capabilities ONADDSUB, ONMUL, ONDIV, DICTUNP, FPCPSHL, RLE and
1966 SHA3.
1967 * elf32-sparc.c (elf32_sparc_final_write_processing): Handle
1968 bfd_mach_sparc_v8plusm8.
1969
eb026f09
AM
19702017-05-19 Alan Modra <amodra@gmail.com>
1971
1972 * elflink.c (_bfd_elf_gc_mark_extra_sections): Don't keep
1973 debug and special sections when no non-note alloc sections in an
1974 object are kept.
1975
535b785f
AM
19762017-05-18 Alan Modra <amodra@gmail.com>
1977
1978 * arc-got.h: Don't compare boolean values against TRUE or FALSE.
1979 * elf-m10300.c: Likewise.
1980 * elf.c: Likewise.
1981 * elf32-arc.c: Likewise.
1982 * elf32-bfin.c: Likewise.
1983 * elf32-m68k.c: Likewise.
1984 * elf32-nds32.c: Likewise.
1985 * elf32-tilepro.c: Likewise.
1986 * elflink.c: Likewise.
1987 * elfnn-aarch64.c: Likewise.
1988 * elfnn-riscv.c: Likewise.
1989 * elfxx-tilegx.c: Likewise.
1990 * mach-o.c: Likewise.
1991 * peXXigen.c: Likewise.
1992 * vms-alpha.c: Likewise.
1993 * vms-lib.c: Likewise.
1994
b7c871ed
L
19952017-05-17 H.J. Lu <hongjiu.lu@intel.com>
1996
1997 PR ld/20882
1998 * elflink.c (elf_gc_mark_debug_section): New function.
1999 (_bfd_elf_gc_mark_extra_sections): Mark any debug sections
2000 referenced by kept debug sections.
2001
bc4e12de
AM
20022017-05-16 Alan Modra <amodra@gmail.com>
2003
2004 * elf-m10300.c: Rename occurrences of non_ir_ref.
2005 * elf32-arm.c: Likewise.
2006 * elf32-bfin.c: Likewise.
2007 * elf32-cr16.c: Likewise.
2008 * elf32-cris.c: Likewise.
2009 * elf32-d10v.c: Likewise.
2010 * elf32-dlx.c: Likewise.
2011 * elf32-fr30.c: Likewise.
2012 * elf32-frv.c: Likewise.
2013 * elf32-hppa.c: Likewise.
2014 * elf32-i370.c: Likewise.
2015 * elf32-i386.c: Likewise.
2016 * elf32-iq2000.c: Likewise.
2017 * elf32-lm32.c: Likewise.
2018 * elf32-m32c.c: Likewise.
2019 * elf32-m32r.c: Likewise.
2020 * elf32-m68hc1x.c: Likewise.
2021 * elf32-m68k.c: Likewise.
2022 * elf32-mcore.c: Likewise.
2023 * elf32-metag.c: Likewise.
2024 * elf32-microblaze.c: Likewise.
2025 * elf32-moxie.c: Likewise.
2026 * elf32-msp430.c: Likewise.
2027 * elf32-mt.c: Likewise.
2028 * elf32-nios2.c: Likewise.
2029 * elf32-or1k.c: Likewise.
2030 * elf32-ppc.c: Likewise.
2031 * elf32-rl78.c: Likewise.
2032 * elf32-s390.c: Likewise.
2033 * elf32-score.c: Likewise.
2034 * elf32-score7.c: Likewise.
2035 * elf32-sh.c: Likewise.
2036 * elf32-tic6x.c: Likewise.
2037 * elf32-tilepro.c: Likewise.
2038 * elf32-v850.c: Likewise.
2039 * elf32-vax.c: Likewise.
2040 * elf32-xstormy16.c: Likewise.
2041 * elf32-xtensa.c: Likewise.
2042 * elf64-alpha.c: Likewise.
2043 * elf64-hppa.c: Likewise.
2044 * elf64-ia64-vms.c: Likewise.
2045 * elf64-mmix.c: Likewise.
2046 * elf64-ppc.c: Likewise.
2047 * elf64-s390.c: Likewise.
2048 * elf64-sh64.c: Likewise.
2049 * elf64-x86-64.c: Likewise.
2050 * elflink.c: Likewise.
2051 * elfnn-aarch64.c: Likewise.
2052 * elfnn-ia64.c: Likewise.
2053 * elfnn-riscv.c: Likewise.
2054 * elfxx-mips.c: Likewise.
2055 * elfxx-sparc.c: Likewise.
2056 * elfxx-tilegx.c: Likewise.
2057 * linker.c: Likewise.
2058
4070765b
AM
20592017-05-16 Alan Modra <amodra@gmail.com>
2060
2061 * elf64-ppc.c (add_symbol_adjust): Transfer non_ir_ref_dynamic.
2062 * elflink.c (elf_link_add_object_symbols): Update to use
2063 non_ir_ref_dynamic.
2064 (elf_link_input_bfd): Test non_ir_ref_dynamic in addition to
2065 non_ir_ref.
2066 * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
2067
25499ac7
MR
20682017-05-15 Maciej W. Rozycki <macro@imgtec.com>
2069
2070 * elfxx-mips.c (print_mips_ases): Handle MIPS16e2 ASE.
2071
73caa85d
L
20722017-05-12 H.J. Lu <hongjiu.lu@intel.com>
2073
2074 * elf32-i386.c (elf_i386_parse_gnu_properties): Merge
2075 GNU_PROPERTY_X86_ISA_1_USED and GNU_PROPERTY_X86_ISA_1_NEEDED
2076 properties.
2077 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
2078
f2c29a16
L
20792017-05-11 H.J. Lu <hongjiu.lu@intel.com>
2080
2081 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Rename plt_bnd
2082 to plt_second.
2083 (elf_x86_64_link_hash_table): Rename plt_bnd/plt_bnd_eh_frame
2084 to plt_second/plt_second_eh_frame.
2085 (elf_x86_64_link_hash_newfunc): Updated.
2086 (elf_x86_64_allocate_dynrelocs): Likewise.
2087 (elf_x86_64_size_dynamic_sections): Likewise.
2088 (elf_x86_64_relocate_section): Likewise.
2089 (elf_x86_64_finish_dynamic_symbol): Likewise.
2090 (elf_x86_64_finish_dynamic_sections): Likewise.
2091 (elf_x86_64_plt_type): Rename plt_bnd to plt_second.
2092 (elf_x86_64_get_synthetic_symtab): Updated. Also scan the
2093 .plt.sec section.
2094 (elf_backend_setup_gnu_properties): Updated. Create the
2095 .plt.sec section instead of the .plt.sec section.
2096
dc2be3d2
L
20972017-05-11 H.J. Lu <hongjiu.lu@intel.com>
2098
2099 * elf32-i386.c (elf_i386_allocate_dynrelocs): Partially revert
2100 commit 25070364b0ce33eed46aa5d78ebebbec6accec7e.
2101 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewse.
2102
db84b98a
JM
21032017-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
2104
2105 * elf64-sparc.c (elf64_sparc_set_reloc): New function.
2106 (bfd_elf64_set_reloc): Define.
2107 (elf64_sparc_write_relocs): Use `canon_reloc_count'.
2108
23186865
JM
21092017-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
2110
2111 * targets.c (BFD_JUMP_TABLE_RELOCS): Add NAME##_set_reloc.
2112 (struct bfd_target): New field _bfd_set_reloc.
2113 * bfd.c (bfd_set_reloc): Call backend _set_bfd.
2114 * reloc.c (_bfd_generic_set_reloc): New function.
2115 * coffcode.h (coff_set_reloc): Define to _bfd_generic_set_reloc.
2116 * nlm-target.h (nlm_set_reloc): Likewise.
2117 * coff-rs6000.c (_bfd_xcoff_set_reloc): Likewise.
2118 * aout-tic30.c (MY_set_reloc): Likewise.
2119 * aout-target.h (MY_set_reloc): Likewise.
2120 * elfxx-target.h (bfd_elfNN_set_reloc): Likewise.
2121 * coff-alpha.c (_bfd_ecoff_set_reloc): Likewise.
2122 * mach-o-target.c (bfd_mach_o_set_reloc): Likewise.
2123 * vms-alpha.c (alpha_vms_set_reloc): Likewise.
2124 * aout-adobe.c (aout_32_set_reloc): Likewise.
2125 * bout.c (b_out_set_reloc): Likewise.
2126 * coff-mips.c (_bfd_ecoff_set_reloc): Likewise.
2127 * i386os9k.c (aout_32_set_reloc): Likewise.
2128 * ieee.c (ieee_set_reloc): Likewise.
2129 * oasys.c (oasys_set_reloc): Likewise.
2130 * som.c (som_set_reloc): Likewise.
2131 * versados.c (versados_set_reloc): Likewise.
2132 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
2133 _bfd_generic_set_reloc.
2134 (rs6000_xcoff64_aix_vec): LIkewise.
2135 * libbfd.c (_bfd_norelocs_set_reloc): New function.
2136 * libbfd-in.h: Prototype for _bfd_norelocs_set_reloc.
2137 * i386msdos.c (msdos_set_reloc): Define to
2138 _bfd_norelocs_set_reloc.
2139 * elfcode.h (elf_set_reloc): Define.
2140 * bfd-in2.h: Regenerated.
2141
aab82f4c
L
21422017-05-10 H.J. Lu <hongjiu.lu@intel.com>
2143
2144 PR ld/21481
2145 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Use .plt.bnd
2146 for IFUNC function address.
2147
53a346d8
CZ
21482017-05-10 Claudiu Zissulescu <claziss@synopsys.com>
2149
2150 * elf32-arc.c (FEATURE_LIST_NAME): Define.
2151 (CONFLICT_LIST): Likewise.
2152 (opcode/arc-attrs.h): Include.
2153 (arc_elf_print_private_bfd_data): Print OSABI v4 flag.
2154 (arc_extract_features): New file.
2155 (arc_stralloc): Likewise.
2156 (arc_elf_merge_attributes): Likewise.
2157 (arc_elf_merge_private_bfd_data): Use object attributes.
2158 (bfd_arc_get_mach_from_attributes): New function.
2159 (arc_elf_object_p): Use object attributes.
2160 (arc_elf_final_write_processing): Likewise.
2161 (elf32_arc_obj_attrs_arg_type): New function.
2162 (elf32_arc_obj_attrs_handle_unknown): Likewise.
2163 (elf32_arc_section_from_shdr): Likewise.
2164 (elf_backend_obj_attrs_vendor): Define.
2165 (elf_backend_obj_attrs_section): Likewise.
2166 (elf_backend_obj_attrs_arg_type): Likewise.
2167 (elf_backend_obj_attrs_section_type): Likewise.
2168 (elf_backend_obj_attrs_handle_unknown): Likewise.
2169 (elf_backend_section_from_shdr): Likewise.
2170
e645cf40
AG
21712017-05-09 Andrew Goedhart <Andrewgoedhart@simplepowersolutions.co.za>
2172
2173 PR ld/21458
2174 * elf32-arm.c (elf32_arm_final_link_relocate): Set the bottom bit
2175 of the value when resolving a R_ARM_THM_ALU_PREL_11_0 relocation
2176 and the destination is a Thumb symbol.
2177
dd9e66ee
L
21782017-05-08 H.J. Lu <hongjiu.lu@intel.com>
2179
2180 * elf32-i386.c (elf_i386_get_synthetic_symtab): Add missing
2181 initializer to silence GCC 4.2.
2182 * lf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
2183
38b12349
L
21842017-05-08 H.J. Lu <hongjiu.lu@intel.com>
2185
2186 * elf64-x86-64.c (PLT_ENTRY_SIZE): Renamed to ...
2187 (LAZY_PLT_ENTRY_SIZE): This.
2188 (NON_LAZY_PLT_ENTRY_SIZE): New.
2189 (elf_x86_64_plt0_entry): Renamed to ...
2190 (elf_x86_64_lazy_plt0_entry): This.
2191 (elf_x86_64_plt_entry): Renamed to ...
2192 (elf_x86_64_lazy_plt_entry): This.
2193 (elf_x86_64_bnd_plt0_entry): Renamed to ...
2194 (elf_x86_64_lazy_bnd_plt0_entry): This.
2195 (elf_x86_64_legacy_plt_entry): Removed.
2196 (elf_x86_64_bnd_plt_entry): Renamed to ...
2197 (elf_x86_64_lazy_bnd_plt_entry): This.
2198 (elf_x86_64_legacy_plt2_entry): Renamed to ...
2199 (elf_x86_64_non_lazy_plt_entry): This.
2200 (elf_x86_64_bnd_plt2_entry): Renamed to ...
2201 (elf_x86_64_non_lazy_bnd_plt_entry): This.
2202 (elf_x86_64_eh_frame_plt): Renamed to ...
2203 (elf_x86_64_eh_frame_lazy_plt): This.
2204 (elf_x86_64_eh_frame_bnd_plt): Renamed to ...
2205 (elf_x86_64_eh_frame_lazy_bnd_plt): This.
2206 (elf_x86_64_eh_frame_plt_got): Renamed to ...
2207 (elf_x86_64_eh_frame_non_lazy_plt): This.
2208 (elf_x86_64_lazy_plt_layout): New.
2209 (elf_x86_64_non_lazy_plt_layout): Likewise.
2210 (elf_x86_64_plt_layout): Likewise.
2211 (elf_x86_64_backend_data): Remove PLT layout information. Add
2212 os for target system.
2213 (GET_PLT_ENTRY_SIZE): Removed.
2214 (elf_x86_64_lazy_plt): New.
2215 (elf_x86_64_non_lazy_plt): Likewise.
2216 (elf_x86_64_lazy_bnd_plt): Likewise.
2217 (elf_x86_64_non_lazy_bnd_plt): Likewise.
2218 (elf_x86-64_arch_bed): Updated.
2219 (elf_x86_64_link_hash_table): Add plt, lazy_plt and non_lazy_plt.
2220 (elf_x86_64_create_dynamic_sections): Removed.
2221 (elf_x86_64_check_relocs): Don't check elf.dynobj. Don't call
2222 _bfd_elf_create_ifunc_sections nor _bfd_elf_create_got_section.
2223 (elf_x86-64_adjust_dynamic_symbol): Updated.
2224 (elf_x86_64_allocate_dynrelocs): Updated. Pass 0 as PLT header
2225 size to _bfd_elf_allocate_ifunc_dyn_relocs and don't allocate
2226 size for PLT0 if there is no PLT0. Get plt_entry_size from
2227 non_lazy_plt for non-lazy PLT entries.
2228 (elf_x86_64_size_dynamic_sections): Updated. Get plt_entry_size
2229 from non_lazy_plt for non-lazy PLT entries.
2230 (elf_x86-64_relocate_section): Updated. Properly get PLT index
2231 if there is no PLT0.
2232 (elf_x86_64_finish_dynamic_symbol): Updated. Fill the first slot
2233 in the PLT entry with generic PLT layout. Fill the non-lazy PLT
2234 entries with non-lazy PLT layout. Don't fill the second and third
2235 slots in the PLT entry if there is no PLT0.
2236 (elf_x86_64_finish_dynamic_sections): Updated. Don't fill PLT0
2237 if there is no PLT0. Set sh_entsize on the .plt.got section.
2238 (compare_relocs): New.
2239 (elf_x86_64_plt_type): Likewise.
2240 (elf_x86_64_plt): Likewise.
2241 (elf_x86_64_nacl_plt): New. Forward declaration.
2242 (elf_x86_64_get_plt_sym_val): Removed.
2243 (elf_x86_64_get_synthetic_symtab): Rewrite to check PLT sections
2244 against all dynamic relocations.
2245 (elf_x86_64_link_setup_gnu_properties): New function.
2246 (elf_backend_create_dynamic_sections): Updated.
2247 (elf_backend_setup_gnu_properties): New.
2248 (elf_x86_64_nacl_plt): New.
2249 (elf_x86_64_nacl_arch_bed): Updated.
2250
f604c2a2
L
22512017-05-08 H.J. Lu <hongjiu.lu@intel.com>
2252
2253 * elf32-i386.c (PLT_ENTRY_SIZE): Renamed to ...
2254 (LAZY_PLT_ENTRY_SIZE): This.
2255 (NON_LAZY_PLT_ENTRY_SIZE): New.
2256 (elf_i386_plt0_entry): Renamed to ...
2257 (elf_i386_lazy_plt0_entry): This.
2258 (elf_i386_plt_entry): Renamed to ...
2259 (elf_i386_lazy_plt_entry): This.
2260 (elf_i386_pic_plt0_entry): Renamed to ...
2261 (elf_i386_pic_lazy_plt0_entry): This.
2262 (elf_i386_pic_plt_entry): Renamed to ...
2263 (elf_i386_pic_lazy_plt_entry): This.
2264 (elf_i386_got_plt_entry): Renamed to ...
2265 (elf_i386_non_lazy_plt_entry): This.
2266 (elf_i386_pic_got_plt_entry): Renamed to ...
2267 (elf_i386_pic_non_lazy_plt_entry): This.
2268 (elf_i386_eh_frame_plt): Renamed to ...
2269 (elf_i386_eh_frame_lazy_plt): This.
2270 (elf_i386_eh_frame_plt_got): Renamed to ...
2271 (elf_i386_eh_frame_non_lazy_plt): This.
2272 (elf_i386_plt_layout): Renamed to ...
2273 (elf_i386_lazy_plt_layout): This. Remove eh_frame_plt_got and
2274 eh_frame_plt_got_size.
2275 (elf_i386_non_lazy_plt_layout): New.
2276 (elf_i386_plt_layout): Likewise.
2277 (elf_i386_non_lazy_plt): Likewise.
2278 (GET_PLT_ENTRY_SIZE): Removed.
2279 (elf_i386_plt): Renamed to ...
2280 (elf_i386_lazy_plt): This.
2281 (elf_i386_backend_data): Remove plt. Rename is_vxworks to os.
2282 (elf_i386_arch_bed): Updated.
2283 (elf_i386_link_hash_table): Add plt, lazy_plt and non_lazy_plt.
2284 (elf_i386_create_dynamic_sections): Removed.
2285 (elf_i386_check_relocs): Don't check elf.dynobj. Don't call
2286 _bfd_elf_create_ifunc_sections nor _bfd_elf_create_got_section.
2287 (elf_i386_adjust_dynamic_symbol): Updated.
2288 (elf_i386_allocate_dynrelocs): Updated. Pass 0 as PLT header
2289 size to _bfd_elf_allocate_ifunc_dyn_relocs and don't allocate
2290 size for PLT0 if there is no PLT0.
2291 (elf_i386_size_dynamic_sections): Updated. Check whether GOT
2292 output section is discarded only if GOT isn't empty.
2293 (elf_i386_relocate_section): Updated. Properly get PLT index
2294 if there is no PLT0.
2295 (elf_i386_finish_dynamic_symbol): Updated. Don't fill the
2296 second and third slots in the PLT entry if there is no PLT0.
2297 (elf_i386_finish_dynamic_sections): Updated. Don't fill PLT0
2298 if there is no PLT0. Set sh_entsize on the .plt.got section.
2299 (elf_i386_nacl_plt): Forward declaration.
2300 (elf_i386_get_plt_sym_val): Removed.
2301 (elf_i386_get_synthetic_symtab): Rewrite to check PLT sections
2302 against all dynamic relocations.
2303 (elf_i386_link_setup_gnu_properties): New function.
2304 (elf_backend_create_dynamic_sections): Updated.
2305 (elf_backend_setup_gnu_properties): New.
2306 (elf_i386_nacl_plt): Updated.
2307 (elf_i386_nacl_arch_bed): Likewise.
2308 (elf_i386_vxworks_arch_bed): Likewise.
2309
046734ff
TP
23102017-05-08 Thomas Preud'homme <thomas.preudhomme@arm.com>
2311
2312 * elflink.c (elf_output_implib): Remove executable flag from import
2313 library bfd.
2314 * elf32-arm.c (elf32_arm_filter_implib_symbols): Assert that the import
2315 library is a relocatable object file.
2316
b660e9eb
SKS
23172017-05-01 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
2318
2319 PR ld/21404
2320 * elf32-avr.c (avr_should_move_sym): New function.
2321 (avr_should_reduce_sym_size): Likewise.
2322 (avr_should_increase_sym_size): Likewise.
2323 (elf32_avr_relax_delete_bytes): Adjust symbol values
2324 and sizes by calling new functions.
2325
763a5fa4
PD
23262017-05-01 Palmer Dabbelt <palmer@dabbelt.com>
2327
2328 * config.bfd (riscv32-*): Enable rv64.
2329
73ec947d
AM
23302017-05-02 Alan Modra <amodra@gmail.com>
2331
2332 PR 21384
2333 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Test h->non_elf
2334 rather than h->root.type == bfd_link_hash_new.
2335 (bfd_elf_record_link_assignment): Similarly, call
2336 bfd_elf_link_mark_dynamic_symbol when h->non_elf.
2337
a941291c
AM
23382017-04-29 Alan Modra <amodra@gmail.com>
2339
2340 PR 21432
2341 * reloc.c (reloc_offset_in_range): New function.
2342 (bfd_perform_relocation, bfd_install_relocation): Use it.
2343 (_bfd_final_link_relocate): Likewise.
2344
750eaa47
L
23452017-04-28 H.J. Lu <hongjiu.lu@intel.com>
2346
2347 * elf32-i386.c (elf_i386_allocate_dynrelocs): Check plt_got
2348 before using .plt.got.
2349 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewise.
2350
5b66fac4
L
23512017-04-27 H.J. Lu <hongjiu.lu@intel.com>
2352
2353 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Use "="
2354 instead of "+=" to update 0.
2355
de9a3c42
L
23562017-04-27 H.J. Lu <hongjiu.lu@intel.com>
2357
2358 * elf32-i386.c (elf_i386_create_dynamic_sections): Create the
2359 .plt.got section here.
2360 (elf_i386_check_relocs): Don't create the .plt.got section.
2361 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Create
2362 the .plt.got and .plt.bnd sections here.
2363 (elf_x86_64_check_relocs): Don't create the .plt.got nor
2364 .plt.bnd sections.
2365
da3d25af
L
23662017-04-27 H.J. Lu <hongjiu.lu@intel.com>
2367
2368 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Remove
2369 has_bnd_reloc.
2370 (elf_x86_64_link_hash_newfunc): Don't clear has_bnd_reloc.
2371 (elf_x86_64_copy_indirect_symbol): Don't copy has_bnd_reloc.
2372 (elf_x86_64_check_relocs): Don't set has_bnd_reloc.
2373 (elf_x86_64_finish_dynamic_symbol): Check bndplt instead of
2374 has_bnd_reloc.
2375
fba37edd
L
23762017-04-27 H.J. Lu <hongjiu.lu@intel.com>
2377
2378 * elf-bfd.h (elf_backend_data): Change setup_gnu_properties
2379 to return bfd *.
2380 (_bfd_elf_link_setup_gnu_properties): Return bfd *.
2381 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Return
2382 the first relocatable ELF input with GNU properties.
2383
1f78f649
L
23842017-04-27 H.J. Lu <hongjiu.lu@intel.com>
2385
2386 * elf32-i386.c (elf_i386_finish_dynamic_sections): Simplify
2387 VxWorks for non-PIC.
2388
76c20d54
AM
23892017-04-27 Alan Modra <amodra@gmail.com>
2390
2391 * elf-bfd.h (struct elf_backend_data): Make asection param of
2392 elf_backend_eh_frame_address_size const.
2393 (_bfd_elf_eh_frame_address_size): Likewise.
2394 * elf32-m32c.c (_bfd_m32c_elf_eh_frame_address_size): Likewise.
2395 * elf32-msp430.c (elf32_msp430_eh_frame_address_size): Likewise.
2396 * elfxx-mips.c (_bfd_mips_elf_eh_frame_address_size): Likewise.
2397 * elfxx-mips.h (_bfd_mips_elf_eh_frame_address_size): Likewise.
2398 * elf-eh-frame.c (_bfd_elf_eh_frame_address_size): Likewise.
2399 (next_cie_fde_offset): Constify params.
2400 (offset_adjust, adjust_eh_frame_local_symbols): Likewise.
2401
d7153c4a
AM
24022017-04-27 Alan Modra <amodra@gmail.com>
2403
2404 * elf-bfd.h (struct eh_cie_fde): Add aug_str_len and aug_data_len.
2405 (_bfd_elf_adjust_eh_frame_global_symbol): Declare.
2406 * elf-eh-frame.c (_bfd_elf_parse_eh_frame): Set aug_str_len and
2407 aug_data_len.
2408 (offset_adjust): New function.
2409 (_bfd_elf_adjust_eh_frame_global_symbol): Likewise.
2410 (adjust_eh_frame_local_symbols): Likewise.
2411 (_bfd_elf_discard_section_eh_frame): Call adjust_eh_frame_local_symbols
2412 after changing anything. Return true if anything changed.
2413 * elflink.c (bfd_elf_discard_info): If .eh_frame changed, call
2414 _bfd_elf_adjust_eh_frame_global_symbol for globals.
2415
641338d8
AM
24162017-04-27 Alan Modra <amodra@gmail.com>
2417
2418 * elflink.c (_bfd_elf_link_hash_hide_symbol): Clear dynstr_index
2419 when force_local.
2420
21d68fcd
AM
24212017-04-27 Alan Modra <amodra@gmail.com>
2422
2423 * elf32-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
2424 (ppc_elf_select_plt_layout, ppc_elf_tls_setup): Use it.
2425 (ppc_elf_adjust_dynamic_symbol, allocate_dynrelocs): Likewise.
2426 (ppc_elf_relocate_section): Likewise. Delete silly optimisation
2427 for undef and undefweak dyn_relocs.
2428 * elf64-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
2429 (ppc64_elf_adjust_dynamic_symbol, ppc64_elf_tls_setup): Use it.
2430 (allocate_got, allocate_dynrelocs): Likewise.
2431 (ppc64_elf_relocate_section): Likewise.
2432
97d343d4
L
24332017-04-26 H.J. Lu <hongjiu.lu@intel.com>
2434
2435 * elf32-i386.c (elf_i386_size_dynamic_sections): Alwasys add
2436 DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rel.plt section.
2437 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Alwasys
2438 add DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rela.plt section.
2439
04b31182
NC
24402017-04-26 Nick Clifton <nickc@redhat.com>
2441
2442 PR binutils/21434
2443 * reloc.c (bfd_perform_relocation): Check for a negative address
2444 in the reloc.
2445
23ec1e32
MR
24462017-04-26 Maciej W. Rozycki <macro@imgtec.com>
2447
2448 PR ld/21334
2449 * elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
2450 member.
2451 * elfxx-target.h [!elf_backend_always_renumber_dynsyms]
2452 (elf_backend_always_renumber_dynsyms): Define.
2453 (elfNN_bed): Initialize `always_renumber_dynsyms' member.
2454 * elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
2455 * elflink.c (bfd_elf_size_dynamic_sections): Also call
2456 `_bfd_elf_link_renumber_dynsyms' if the backend has requested
2457 it.
2458 (bfd_elf_size_dynsym_hash_dynstr): Likewise.
2459
c46cec3a
MR
24602017-04-26 Maciej W. Rozycki <macro@imgtec.com>
2461
2462 * elflink.c (bfd_elf_size_dynamic_sections): Only call
2463 `_bfd_elf_link_renumber_dynsyms' after section GC if dynamic
2464 sections have been created.
2465
e63d1232
NC
24662017-04-26 Nick Clifton <nickc@redhat.com>
2467
2468 PR binutils/21431
2469 * compress.c (bfd_init_section_compress_status): Check the return
2470 value from bfd_malloc.
2471
9e9821dd
L
24722017-04-24 H.J. Lu <hongjiu.lu@intel.com>
2473
2474 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Add
2475 no_finish_dynamic_symbol.
2476 (elf_x86_64_link_hash_newfunc): Set no_finish_dynamic_symbol to
2477 0.
2478 (elf_x86_64_allocate_dynrelocs): If a symbol isn't undefined
2479 weak symbol, don't make it dynamic.
2480 (elf_x86_64_relocate_section): If a symbol isn't dynamic in PIC,
2481 set no_finish_dynamic_symbol and generate R_X86_64_RELATIVE
2482 relocation for GOT reference.
2483 (elf_x86_64_finish_dynamic_symbol): Abort if
2484 no_finish_dynamic_symbol isn't 0.
2485
0dc9a308
L
24862017-04-24 H.J. Lu <hongjiu.lu@intel.com>
2487
2488 PR ld/21402
2489 * elf32-i386.c (elf_i386_allocate_dynrelocs): If a symbol isn't
2490 undefined weak symbol, don't make it dynamic.
2491 (elf_i386_relocate_section): If a symbol isn't dynamic in PIC,
2492 set no_finish_dynamic_symbol and generate R_386_RELATIVE
2493 relocation for R_386_GOT32.
2494
1587442d
L
24952017-04-24 H.J. Lu <hongjiu.lu@intel.com>
2496
2497 PR ld/21425
2498 * elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.
2499
7eacd66b
AM
25002017-04-23 Alan Modra <amodra@gmail.com>
2501
2502 PR 21414
2503 * section.c (GLOBAL_SYM_INIT): Make available in bfd.h.
2504 * elf.c (lcomm_sym): New.
2505 (_bfd_elf_large_com_section): Use lcomm_sym section symbol.
2506 * bfd-in2.h: Regenerate.
2507
bce964aa
AM
25082017-04-23 Alan Modra <amodra@gmail.com>
2509
2510 PR 21412
2511 * elf-bfd.h (struct elf_backend_data <get_reloc_section>): Change
2512 parameters and comment.
2513 (_bfd_elf_get_reloc_section): Delete.
2514 (_bfd_elf_plt_get_reloc_section): Declare.
2515 * elf.c (_bfd_elf_plt_get_reloc_section, elf_get_reloc_section):
2516 New functions. Don't blindly skip over assumed .rel/.rela prefix.
2517 Extracted from..
2518 (_bfd_elf_get_reloc_section): ..here. Delete.
2519 (assign_section_numbers): Call elf_get_reloc_section.
2520 * elf64-ppc.c (elf_backend_get_reloc_section): Define.
2521 * elfxx-target.h (elf_backend_get_reloc_section): Update.
2522
97e83a10
AM
25232017-04-23 Alan Modra <amodra@gmail.com>
2524
2525 PR 21409
2526 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Don't segfault when
2527 no symbols.
2528
e133d005
L
25292017-04-21 H.J. Lu <hongjiu.lu@intel.com>
2530
2531 PR ld/21402
2532 * elf32-i386.c (elf_i386_link_hash_entry): Add
2533 no_finish_dynamic_symbol.
2534 (elf_i386_link_hash_newfunc): Set no_finish_dynamic_symbol to 0.
2535 (elf_i386_allocate_dynrelocs): If a symbol isn't undefined weak
2536 symbol, don't make it dynamic in PIE.
2537 (elf_i386_relocate_section): If a symbol isn't dynamic in PIE,
2538 set no_finish_dynamic_symbol and generate R_386_RELATIVE
2539 relocation for R_386_GOT32
2540 (elf_i386_finish_dynamic_symbol): Abort if no_finish_dynamic_symbol
2541 isn't 0.
2542
3c5fce9b
L
25432017-04-21 H.J. Lu <hongjiu.lu@intel.com>
2544
2545 PR ld/19617
2546 PR ld/21086
2547 * elflink.c (elf_link_add_object_symbols): Require
2548 --no-dynamic-linker with -E/--dynamic-list when creating
2549 dynamic sections.
2550
0fad2956
MR
25512017-04-20 Maciej W. Rozycki <macro@imgtec.com>
2552
2553 * elflink.c (_bfd_elf_symbol_refs_local_p): Always return TRUE
2554 if forced local.
2555
64575f78
MR
25562017-04-20 Maciej W. Rozycki <macro@imgtec.com>
2557
2558 * elfxx-mips.c (_bfd_mips_elf_final_link): Reorder comment about
2559 dynamic symbol sorting.
2560
59fa66c5
L
25612017-04-20 H.J. Lu <hongjiu.lu@intel.com>
2562
2563 PR ld/21382
2564 * elflink.c (elf_link_add_object_symbols): Preserve
2565 dynamic_ref_after_ir_def when restoring the symbol table for
2566 unneeded dynamic object.
2567
e492d2f8
L
25682017-04-19 H.J. Lu <hongjiu.lu@intel.com>
2569
2570 PR ld/21401
2571 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Don't abort
2572 on on undefined IFUNC symbol in the second PLT.
2573
10169134
WAF
25742017-04-19 Wedson Almeida Filho <wedsonaf@gmail.com>
2575
2576 * peXXigen.c (pe_print_reloc): Correct chunk_end.
2577
954b63d4
AM
25782017-04-19 Alan Modra <amodra@gmail.com>
2579
2580 * elflink.c (_bfd_elf_adjust_dynamic_symbol): Hide undefweak
2581 or make dynamic for info->dynamic_undefined_weak 0 and 1.
2582 * elf32-ppc.c:Formatting.
2583 (ensure_undefweak_dynamic): Don't make dynamic when
2584 info->dynamic_undefined_weak is zero.
2585 (allocate_dynrelocs): Discard undefweak dyn_relocs for
2586 info->dynamic_undefined_weak. Discard undef dyn_relocs when
2587 not default visibility. Discard undef and undefweak
2588 dyn_relocs earlier.
2589 (ppc_elf_relocate_section): Adjust to suit.
2590 * elf64-ppc.c: Formatting.
2591 (ensure_undefweak_dynamic): Don't make dynamic when
2592 info->dynamic_undefined_weak is zero.
2593 (allocate_dynrelocs): Discard undefweak dyn_relocs for
2594 info->dynamic_undefined_weak. Discard them earlier.
2595
e6699019
L
25962017-04-17 H.J. Lu <hongjiu.lu@intel.com>
2597
2598 PR ld/21389
2599 * elflink.c (bfd_elf_size_dynamic_sections): Get soname index
2600 before generating the version definition section.
2601
c5d37467
AM
26022017-04-17 Alan Modra <amodra@gmail.com>
2603
2604 * elflink.c (_bfd_elf_merge_symbol): Undo dynamic linking
2605 state when a regular object file defines a symbol with
2606 incompatible type to that defined by an earlier shared lib.
2607
63a5468a
AM
26082017-04-13 Alan Modra <amodra@gmail.com>
2609
2610 * coffcode.h: Wrap some overly long _bfd_error_handler args.
2611 * elf.c: Likewise.
2612 * elf32-arm.c: Likewise.
2613 * elf32-i386.c: Likewise.
2614 * elf32-mep.c: Likewise.
2615 * elf64-ia64-vms.c: Likewise.
2616 * elf64-x86-64.c: Likewise.
2617 * elflink.c: Likewise.
2618 * elfnn-ia64.c: Likewise.
2619 * elfxx-mips.c: Likewise.
2620
dae82561
AM
26212017-04-13 Alan Modra <amodra@gmail.com>
2622
2623 * aoutx.h: Use %B and %A in error messages throughout file.
2624 * aout-cris.c: Likewise.
2625 * archive.c: Likewise.
2626 * binary.c: Likewise.
2627 * coff-rs6000.c: Likewise.
2628 * coff-tic4x.c: Likewise.
2629 * coffcode.h: Likewise.
2630 * coffgen.c: Likewise.
2631 * cofflink.c: Likewise.
2632 * coffswap.h: Likewise.
2633 * cpu-arm.c: Likewise.
2634 * elf-eh-frame.c: Likewise.
2635 * elf-m10300.c: Likewise.
2636 * elf.c: Likewise.
2637 * elf32-arc.c: Likewise.
2638 * elf32-arm.c: Likewise.
2639 * elf32-bfin.c: Likewise.
2640 * elf32-frv.c: Likewise.
2641 * elf32-iq2000.c: Likewise.
2642 * elf32-m32c.c: Likewise.
2643 * elf32-microblaze.c: Likewise.
2644 * elf32-nds32.c: Likewise.
2645 * elf32-rl78.c: Likewise.
2646 * elf32-rx.c: Likewise.
2647 * elf32-score.c: Likewise.
2648 * elf32-score7.c: Likewise.
2649 * elf32-sh64.c: Likewise.
2650 * elf32-v850.c: Likewise.
2651 * elf32-vax.c: Likewise.
2652 * elf32-visium.c: Likewise.
2653 * elf64-ia64-vms.c: Likewise.
2654 * elf64-mmix.c: Likewise.
2655 * elf64-sh64.c: Likewise.
2656 * elfcode.h: Likewise.
2657 * elfnn-aarch64.c: Likewise.
2658 * elfnn-ia64.c: Likewise.
2659 * elfxx-mips.c: Likewise.
2660 * hpux-core.c: Likewise.
2661 * ieee.c: Likewise.
2662 * ihex.c: Likewise.
2663 * linker.c: Likewise.
2664 * merge.c: Likewise.
2665 * mmo.c: Likewise.
2666 * oasys.c: Likewise.
2667 * pdp11.c: Likewise.
2668 * peXXigen.c: Likewise.
2669 * rs6000-core.c: Likewise.
2670 * vms-alpha.c: Likewise.
2671 * xcofflink.c: Likewise.
2672
c08bb8dd
AM
26732017-04-13 Alan Modra <amodra@gmail.com>
2674
2675 * bfd.c (PRINT_TYPE): Define.
2676 (_doprnt): New function.
2677 (error_handler_internal): Use _doprnt.
2678 * coff-arm.c: Put %A and %B arguments to _bfd_error_handler
2679 calls in their natural order, throughout file.
2680 * coff-mcore.c: Likewise.
2681 * coff-ppc.c: Likewise.
2682 * coff-tic80.c: Likewise.
2683 * cofflink.c: Likewise.
2684 * elf-s390-common.c: Likewise.
2685 * elf.c: Likewise.
2686 * elf32-arm.c: Likewise.
2687 * elf32-i386.c: Likewise.
2688 * elf32-m32r.c: Likewise.
2689 * elf32-msp430.c: Likewise.
2690 * elf32-spu.c: Likewise.
2691 * elf64-ia64-vms.c: Likewise.
2692 * elf64-sparc.c: Likewise.
2693 * elf64-x86-64.c: Likewise.
2694 * elflink.c: Likewise.
2695 * elfnn-aarch64.c: Likewise.
2696 * elfnn-ia64.c: Likewise.
2697 * elfxx-mips.c: Likewise.
2698
10463f39
AM
26992017-04-13 Alan Modra <amodra@gmail.com>
2700
2701 * elf32-arm.c (arm_type_of_stub): Supply missing args to "long
2702 branch veneers" error. Fix double space and format message.
2703 * elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
2704 * elf64-ppc.c (tocsave_find): Supply missing %B arg.
2705
4af8774e
AM
27062017-04-13 Alan Modra <amodra@gmail.com>
2707
2708 * bfd-in2.h: Regenerate.
2709
e4097f5e
L
27102017-04-11 H.J. Lu <hongjiu.lu@intel.com>
2711
2712 * elf-properties.c (_bfd_elf_parse_gnu_properties): Remove the
2713 extra `\n' in warning/error messages.
2714 * elf32-i386.c (elf_i386_parse_gnu_properties): Likewise.
2715 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
2716
537616aa
L
27172017-04-11 H.J. Lu <hongjiu.lu@intel.com>
2718
2719 * elf-properties.c (_bfd_elf_parse_gnu_properties): Ignore
2720 processor-specific properties with generic ELF target vector.
2721
bb1dd176
QZ
27222017-04-10 Qing Zhao <qing.zhao@oracle.com>
2723
2724 * elf32-sparc.c (elf_backend_fixup_symbol): New.
2725 * elf64-sparc.c (elf_backend_fixup_symbol): New.
2726 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
2727 (_bfd_sparc_elf_link_hash_entry): Add has_got_reloc and
2728 has_non_got_reloc.
2729 (link_hash_newfunc): Initialize has_got_reloc and
2730 has_non_got_reloc.
2731 (_bfd_sparc_elf_size_dynamic_sections): Set interp to .interp
2732 section.
2733 (_bfd_sparc_elf_copy_indirect_symbol): Copy has_got_reloc and
2734 has_non_got_reloc.
2735 (_bfd_sparc_elf_check_relocs): Set has_got_reloc and
2736 has_non_got_reloc.
2737 (_bfd_sparc_elf_fixup_symbol): New function.
2738 (allocate_dynrelocs): Don't allocate space for dynamic
2739 relocations and discard relocations against resolved undefined
2740 weak symbols in executable. Don't make resolved undefined weak
2741 symbols in executable dynamic. Keep dynamic non-GOT/non-PLT
2742 relocation against undefined weak symbols in PIE.
2743 (_bfd_sparc_elf_relocate_section): Don't generate dynamic
2744 relocations against resolved undefined weak symbols in PIE
2745 (_bfd_sparc_elf_finish_dynamic_symbol): Keep PLT/GOT entries
2746 without ynamic PLT/GOT relocations for resolved undefined weak
2747 symbols.
2748 Don't generate dynamic relocation against resolved undefined
2749 weak symbol in executable.
2750 (pie_finish_undefweak_symbol): New function.
2751 (_bfd_sparc_elf_finish_dynamic_sections): Call
2752 pie_finish_undefweak_symbol on all symbols in PIE.
2753 * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Add interp.
2754 (_bfd_sparc_elf_fixup_symbol): New function.
2755
d236cfd4
NC
27562017-04-10 Nick Clifton <nickc@redhat.com>
2757
2758 * config.bfd: Remove ns32k from obsolete list.
2759
6f9dbcd4
AM
27602017-04-10 Alan Modra <amodra@gmail.com>
2761
2762 PR 21287
2763 * elf.c (special_sections_f): Match .fini_array and .fini_array.*.
2764 (special_sections_i): Likewise for .init_array.
2765 (special_sections_p): Likewise for .preinit_array.
2766
8170f769
L
27672017-04-07 H.J. Lu <hongjiu.lu@intel.com>
2768
2769 PR ld/19579
2770 PR ld/21306
2771 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
2772 ELF_COMMON_DEF_P for common symbols.
2773 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
2774 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
2775 * elflink.c (_bfd_elf_merge_symbol): Revert commits
2776 202ac193bbbecc96a4978d1ac3d17148253f9b01 and
2777 07492f668d2173da7a2bda3707ff0985e0f460b6.
2778
49f4617b
PA
27792017-04-07 Pedro Alves <palves@redhat.com>
2780
2781 * opncls.c (bfd_get_debug_link_info): Rename to...
2782 (bfd_get_debug_link_info_1): ... this. Change type of second
2783 parameter to void pointer. Adjust.
2784 (bfd_get_debug_link_info): Reimplement on top of
2785 bfd_get_debug_link_info_1.
2786 (separate_debug_file_exists, separate_alt_debug_file_exists):
2787 Change type of second parameter to void pointer. Adjust.
2788 (get_func_type, check_func_type): Change type of second parameter
2789 to void pointer.
2790 (find_separate_debug_file): Add 'func_data' parameter. Pass it to
2791 the callback functions instead of passing the address of a local.
2792 (bfd_follow_gnu_debuglink): Pass address of unsigned long local to
2793 find_separate_debug_file.
2794 (get_alt_debug_link_info_shim): Change type of second parameter to
2795 void pointer. Adjust.
2796 (bfd_follow_gnu_debugaltlink): Adjust to pass NULL to
2797 find_separate_debug_file.
2798 (get_build_id_name, bfd_boolean check_build_id_file): Change type
2799 of second parameter to void pointer. Adjust.
2800 (bfd_follow_build_id_debuglink): Pass address of bfd_build_id
2801 pointer local to find_separate_debug_file.
2802
28032017-04-07 Tristan Gingold <gingold@gingold-Precision-7510>
1fd6d111
TG
2804
2805 * coffgen.c (_bfd_coff_gc_mark_hook): Handle PE weak
2806 external symbols with a definition.
2807 (_bfd_coff_gc_mark_extra_sections): Fix typo.
2808
86abf93a
AM
28092017-04-07 Alan Modra <amodra@gmail.com>
2810
2811 * po/SRC-POTFILES.in: Regenerate.
2812
8dea77f0
AM
28132017-04-05 Alan Modra <amodra@gmail.com>
2814
2815 * elf64-ppc.c (ppc64_elf_gc_sweep_hook): Support ELFv2 PLT
2816 reference counting.
2817
477bdd39
JT
28182017-04-02 Jon Turney <jon.turney@dronecode.org.uk>
2819
2820 (_bfd_XXi_swap_aouthdr_out): For clarity, use defines rather than
2821 numbers for DataDirectory entry indicies passed to
2822 add_data_entry().
2823
a91e1603
L
28242017-04-04 H.J. Lu <hongjiu.lu@intel.com>
2825
2826 * elf.c (get_program_header_size): Add a GNU_MBIND segment for
2827 each GNU_MBIND section and align GNU_MBIND section to page size.
2828 (_bfd_elf_map_sections_to_segments): Create a GNU_MBIND
2829 segment for each GNU_MBIND section.
2830 (_bfd_elf_init_private_section_data): Copy sh_info from input
2831 for GNU_MBIND section.
2832
b5292032
PD
28332017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
2834
2835 * elfnn-riscv.c (GP_NAME): Delete.
2836 (riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
2837 (_bfd_riscv_relax_lui): Likewise.
2838
ad32986f
NC
28392017-04-04 Nick Clifton <nickc@redhat.com>
2840
2841 PR binutils/21342
2842 * elflink.c (_bfd_elf_define_linkage_sym): Prevent null pointer
2843 dereference.
2844 (bfd_elf_final_link): Only initialize the extended symbol index
2845 section if there are extended symbol tables to list.
2846
46bed679
L
28472017-04-03 H.J. Lu <hongjiu.lu@intel.com>
2848
2849 * Makefile.am (BFD32_BACKENDS): Add elf-properties.lo.
2850 (BFD32_BACKENDS_CFILES): Add elf-properties.c.
2851 * configure.ac (elf): Add elf-properties.lo.
2852 * Makefile.in: Regenerated.
2853 * configure: Likewise.
2854 * elf-bfd.h (elf_property_kind): New.
2855 (elf_property): Likewise.
2856 (elf_property_list): Likewise.
2857 (elf_properties): Likewise.
2858 (_bfd_elf_parse_gnu_properties): Likewise.
2859 (_bfd_elf_get_property): Likewise.
2860 (_bfd_elf_link_setup_gnu_properties): Likewise.
2861 (elf_backend_data): Add parse_gnu_properties, merge_gnu_properties
2862 and setup_gnu_properties.
2863 (elf_obj_tdata): Add properties.
2864 * elf-properties.c: New file.
2865 * elf32-i386.c (elf_i386_parse_gnu_properties): New.
2866 (elf_i386_merge_gnu_properties): Likewise.
2867 (elf_backend_parse_gnu_properties): Likewise.
2868 (elf_backend_merge_gnu_properties): Likewise.
2869 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
2870 (elf_x86_64_merge_gnu_properties): Likewise.
2871 (elf_backend_parse_gnu_properties): Likewise.
2872 (elf_backend_merge_gnu_properties): Likewise.
2873 * elfxx-target.h (elf_backend_merge_gnu_properties): Likewise.
2874 (elf_backend_parse_gnu_properties): Likewise.
2875 (elf_backend_setup_gnu_properties): Likewise.
2876 (elfNN_bed): Add elf_backend_parse_gnu_properties,
2877 elf_backend_merge_gnu_properties and
2878 elf_backend_setup_gnu_properties.
2879
f96bd6c2
PC
28802017-03-30 Pip Cet <pipcet@gmail.com>
2881
2882 * elf32-wasm32.c: Add relocation code, two relocs.
2883 * reloc.c: Add wasm32 relocations.
2884 * libbfd.h: Regenerate.
2885 * bfd-in2.h: Regenerate.
2886 * bfd/po/bfd.pot: Regenerate.
2887
e643cb45
NC
28882017-03-29 Nick Clifton <nickc@redhat.com>
2889
2890 PR binutils/18025
2891 * coff-bfd.h (struct coff_section_data): Add new fields:
2892 saved_bias and bias.
2893 * coffgen.c (coff_find_nearest_line_with_names): Cache the bias
2894 computed for PE binaries.
2895 * dwarf2.c (scan_unit_for_symbols): Only warn once about each
2896 missing abbrev.
2897
086554e8
HPN
28982017-03-28 Hans-Peter Nilsson <hp@axis.com>
2899
2900 PR ld/16044
2901 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Adjust BFD_ASSERT
2902 to handle a local symbol with a hash-symbol-entry; without PLT.
2903 Add BFD_ASSERT for an incidental case with GOT entry present.
2904 (cris_elf_check_relocs): Increment PLT refcount only if the symbol
2905 isn't forced-or-set local.
2906
a6be0538
PC
29072017-03-27 Pip Cet <pipcet@gmail.com>
2908
2909 * wasm-module.c: New file to support WebAssembly modules.
2910 * wasm-module.h: New file to support WebAssembly modules.
2911 * doc/webassembly.texi: Start documenting wasm-module.c.
2912 * config.bfd: Add wasm_vec.
2913 * targets.c: Likewise.
2914 * configure.ac: Likewise.
2915 * Makefile.am: Add entries for wasm-module.c.
2916 * Makefile.in: Regenerate.
2917 * configure: Regenerate.
2918 * po/SRC-POTFILES.in: Regenerate.
2919
79b1d3cb
PC
29202017-03-27 Pip Cet <pipcet@gmail.com>
2921
2922 * cpu-wasm32.c: New file to support wasm32 architecture.
2923 * elf32-wasm32.c: New file to support wasm32 architecture.
2924 * Makefile.am: Add wasm32 architecture.
2925 * archures.c: Likewise.
2926 * config.bfd: Likewise.
2927 * configure.ac: Likewise.
2928 * targets.c: Likewise.
2929 * Makefile.in: Regenerate.
2930 * bfd-in2.h: Regenerate.
2931 * configure: Regenerate.
2932 * po/SRC-POTFILES.in: Regenerate.
2933
aaed6f5b
AM
29342017-03-20 Alan Modra <amodra@gmail.com>
2935
2936 PR 21266
2937 * elf64-ppc.c (compare_symbols): Stabilize sort.
2938
82e66161
AM
29392017-03-18 Alan Modra <amodra@gmail.com>
2940
2941 * elf64-ppc.c (struct ppc_link_hash_table): Add
2942 local_ifunc_resolver and maybe_local_ifunc_resolver.
2943 (ppc_build_one_stub): Set flags on emitting dynamic
2944 relocation to ifunc.
2945 (ppc64_elf_relocate_section): Likewise.
2946 (ppc64_elf_finish_dynamic_symbol): Likewise.
2947 (ppc64_elf_finish_dynamic_sections): Error on DT_TEXTREL with
2948 local dynamic relocs to ifuncs.
2949 * elf32-ppc.c (struct ppc_elf_link_hash_table): Add
2950 local_ifunc_resolver and maybe_local_ifunc_resolver.
2951 (ppc_elf_relocate_section): Set flag on emitting dynamic
2952 relocation to ifuncs.
2953 (ppc_elf_finish_dynamic_symbol): Likewise.
2954 (ppc_elf_finish_dynamic_sections): Error on DT_TEXTREL with local
2955 dynamic relocs to ifuncs.
2956
f955cccf
NC
29572017-03-13 Nick Clifton <nickc@redhat.com>
2958
2959 PR binutils/21202
2960 * reloc.c (BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC): Rename to
2961 BFD_RELOC_AARCH64_TLSDESC_LD64_LO12.
2962 (BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC): Rename to
2963 BFD_RELOC_AARCH64_TLSDESC_ADD_LO12.
2964 * bfd-in2.h: Regenerate.
2965 * libbfd.h: Regenerate.
2966 * elfnn-aarch64.c (IS_AARCH64_TLS_RELAX_RELOC): Update reloc
2967 names.
2968 (IS_AARCH64_TLSDESC_RELOC): Likewise.
2969 (elfNN_aarch64_howto_table): Likewise.
2970 (aarch64_tls_transition_without_check): Likewise.
2971 (aarch64_reloc_got_type): Likewise.
2972 (elfNN_aarch64_final_link_relocate): Likewise.
2973 (elfNN_aarch64_tls_relax): Likewise.
2974 (elfNN_aarch64_relocate_section): Likewise.
2975 (elfNN_aarch64_gc_sweep_hook): Likewise.
2976 (elfNN_aarch64_check_relocs): Likewise.
2977 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
2978 (_bfd_aarch64_elf_resolve_relocation): Likewise.
2979
4aef7643
AM
29802017-03-11 Alan Modra <amodra@gmail.com>
2981
2982 * elf32-ppc.c: Remove ATTRIBUTE_UNUSED throughout when function
2983 parameter is in fact used. Whitespace fixes.
2984 * elf64-ppc.c: Likewise.
2985
f03265d9
ST
29862017-03-09 Sam Thursfield <sam.thursfield@codethink.co.uk>
2987
2988 * rs6000-core.c (CORE_NEW): Simplify macro when
2989 AIX_CORE_DUMPX_CORE and BFD64 are true to avoid compile warning.
2990
b1b07054
AM
29912017-03-07 Alan Modra <amodra@gmail.com>
2992
2993 PR 21224
2994 PR 20519
2995 * elf64-ppc.c (ppc64_elf_relocate_section): Add missing
2996 dyn_relocs check.
2997
2e0ce1c8
AM
29982017-03-05 Alan Modra <amodra@gmail.com>
2999
3000 * elf-bfd.h (struct eh_cie_fde): Add u.cie.per_encoding_aligned8.
3001 * elf-eh-frame.c (size_of_output_cie_fde): Don't align here.
3002 (next_cie_fde_offset): New function.
3003 (_bfd_elf_parse_eh_frame): Set u.cie.per_encoding_aligned8.
3004 (_bfd_elf_discard_section_eh_frame): Align zero terminator to
3005 four bytes. Align CIEs to four or eight bytes depending on
3006 per_encoding_aligned8. Align FDEs according to their encoding.
3007 Pad last FDE to output section alignment.
3008 (_bfd_elf_write_section_eh_frame): Adjust to suit. Remove
3009 assertion.
3010 * elf64-ppc.c (glink_eh_frame_cie): Delete padding.
3011 (ppc64_elf_size_stubs): Pad glink eh_frame as per elf-eh-frame.c.
3012 (ppc64_elf_finish_dynamic_sections): Adjust to suit.
3013
f98450c6
NC
30142017-03-02 Martin Bickel <binutils@ineranves.de>
3015
3016 PR ld/21212
3017 * elf.c (rewrite_elf_program_header): Do not issue a warning for
d20928fa 3018 empty segments which have a zero filesz, but a non-zero memsz.
f98450c6 3019
673cff9b
AM
30202017-03-02 Alan Modra <amodra@gmail.com>
3021
3022 * elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.
3023
3de43e7b
AM
30242017-02-28 Alan Modra <amodra@gmail.com>
3025
3026 * elf64-ppc.c (ppc64_elf_ha_reloc): Revert last change.
3027 (ppc64_elf_relocate_section): Likewise.
3028
4ef97a1b
AM
30292017-02-28 Alan Modra <amodra@gmail.com>
3030
3031 PR 20995
3032 * elf32-nios2.c (nios2_elf32_relocate_section): Use htab
3033 rather than elf32_nios2_hash_table or elf_hash_table.
3034 (create_got_section): Likewise.
3035 (nios2_elf32_finish_dynamic_symbol): Likewise.
3036 (nios2_elf32_adjust_dynamic_symbol): Likewise.
3037 (nios2_elf32_size_dynamic_sections): Likewise.
3038 (nios2_elf32_check_relocs): Delete dynobj, sgot, and srelgot
3039 vars. Use htab equivalents directly instead. Don't create
3040 all dynamic sections on needing just the GOT. Use a goto
3041 rather than a fall-through with reloc test. Ensure
3042 htab->dynobj is set when making dynamic sreloc section.
3043 (nios2_elf32_finish_dynamic_sections): Delete dynobj, use htab
3044 equivalent directly instead. Don't segfault on looking for
3045 .dynamic when dynamic sections have not been created. Don't
3046 segfault on .got.plt being discarded.
3047 (nios2_elf32_size_dynamic_sections): Delete plt and got vars.
3048 Don't set "relocs" on .rela.plt. Do handle .sbss. Delete
3049 fixme and another not so relevant comment.
3050 (nios2_elf_add_symbol_hook): Delete dynobj var. If not
3051 already set, set hash table dynobj on creating .sbss.
3052
7ba71655
AM
30532017-02-28 Alan Modra <amodra@gmail.com>
3054
3055 * reloc.c (BFD_RELOC_PPC_16DX_HA): New.
3056 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_16DX_HA>): New howto.
3057 (ppc64_elf_reloc_type_lookup): Translate new bfd reloc.
3058 (ppc64_elf_ha_reloc): Correct overflow test on REL16DX_HA.
3059 (ppc64_elf_relocate_section): Likewise.
3060 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_16DX_HA>): New howto.
3061 (ppc_elf_reloc_type_lookup): Translate new bfd reloc.
3062 (ppc_elf_check_relocs): Handle R_PPC_16DX_HA to pacify gcc.
3063 * libbfd.h: Regenerate.
3064 * bfd-in2.h: Regenerate.
3065
afbf7e8e
AM
30662017-02-28 Alan Modra <amodra@gmail.com>
3067
3068 * elflink.c (_bfd_elf_create_dynamic_sections): Don't make
3069 dynamic .data.rel.ro read-only.
3070 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Compare section
3071 rather than section flags when deciding where copy reloc goes.
3072 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
3073 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
3074 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Likewise.
3075 * elf32-metag.c (elf_metag_finish_dynamic_symbol): Likewise.
3076 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Likewise.
3077 * elf32-nios2.c (nios2_elf32_finish_dynamic_symbol): Likewise.
3078 * elf32-or1k.c (or1k_elf_finish_dynamic_symbol): Likewise.
3079 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Likewise.
3080 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
3081 * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
3082 * elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
3083 * elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Likewise.
3084 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
3085 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
3086 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Likewise.
3087 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Likewise.
3088 * elfxx-mips.c (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
3089 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
3090 * elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
3091
0e392101
MR
30922017-02-28 Maciej W. Rozycki <macro@imgtec.com>
3093
3094 * elfxx-mips.c (mips_elf_perform_relocation): Also handle the
3095 `jalr $0, $25' instruction encoding.
3096
bd757ca7
NC
30972017-02-27 Nick Clifton <nickc@redhat.com>
3098
3099 PR ld/21180
3100 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Avoid
3101 generating a seg-fault when encountering a symbol that has been
3102 deleted by garbage collection.
3103
034fed0b
AM
31042017-02-25 Alan Modra <amodra@gmail.com>
3105
3106 * elf32-arc.c (struct dynamic_sections): Delete.
3107 (enum dyn_section_types): Delete.
3108 (dyn_section_names): Delete.
3109 (arc_create_dynamic_sections): Delete.
3110 (elf_arc_finish_dynamic_sections): Don't call the above. Don't
3111 segfault on discarded .rela.plt section.
3112 (elf_arc_size_dynamic_sections): Formatting. Don't call
3113 arc_create_dynamic_sections. Don't allocate memory for sections
3114 handled by the generic linker. Correct code finding relocs in
3115 read-only sections. Set SEC_EXCLUDE on zero size .got,
3116 .got.plt, and .dynbss sections. Do set .interp for pies.
3117
d0f744f9
AW
31182017-02-24 Andrew Waterman <andrew@sifive.com>
3119
3120 * elfnn-riscv.c (GP_NAME): New macro.
3121 (riscv_global_pointer_value): Use it.
3122 (_bfd_riscv_relax_lui): If symbol and global pointer are in same
3123 output section, consider only that section's alignment.
3124
5d58c733
MR
31252017-02-23 Maciej W. Rozycki <macro@imgtec.com>
3126
3127 * elfxx-mips.h (_bfd_mips_relax_section): Remove prototype.
3128 * elfxx-mips.c (_bfd_mips_relax_section): Remove function.
3129 * elf64-mips.c (bfd_elf64_bfd_relax_section): Remove macro.
3130 * elfn32-mips.c (bfd_elf32_bfd_relax_section): Likewise.
3131
c1556ecd
MR
31322017-02-23 Maciej W. Rozycki <macro@imgtec.com>
3133
3134 * elfxx-mips.c (mips_elf_calculate_relocation) <R_MIPS_JALR>
3135 <R_MICROMIPS_JALR>: Discard relocation if `cross_mode_jump_p'
3136 or misaligned.
3137
5499c7c7
AM
31382017-02-23 Alan Modra <amodra@gmail.com>
3139
3140 PR 20744
3141 * elf32-ppc.c (ppc_elf_howto_raw): Correct dst_mask on all VLE
3142 16D relocations.
3143 (ppc_elf_vle_split16): Correct field mask and shift for 16D relocs.
3144 (ppc_elf_relocate_section): Correct calculation for VLE SDAREL
3145 relocs.
3146
902e9fc7
MR
31472017-02-22 Maciej W. Rozycki <macro@imgtec.com>
3148
3149 PR ld/20828
3150 * elflink.c (bfd_elf_size_dynamic_sections): Move symbol version
3151 processing ahead of the call to `elf_gc_sweep_symbol'.
3152
758d96d8
NC
31532017-02-22 Nick Clifton <nickc@redhat.com>
3154
3155 PR binutils/21193
3156 * opncls.c (bfd_create_gnu_debuglink_section): Give the newly
3157 created section 4-byte alignment.
3158
6528b6eb
AM
31592017-02-22 Alan Modra <amodra@gmail.com>
3160
3161 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Don't segfault
3162 on .got or .plt output section being discarded by script.
3163 * elf32-ppc.c (ppc_elf_finish_dynamic_sections): Likewise. Move
3164 vxworks splt temp.
3165
24f1a751
AM
31662017-02-21 Alan Modra <amodra@gmail.com>
3167
3168 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only emit
3169 DT_RELA, DT_RELASZ, and DT_RELAENT when DT_RELASZ is non-zero.
3170
64487780
AM
31712017-02-20 Alan Modra <amodra@gmail.com>
3172
3173 PR 21181
3174 * elflink.c (bfd_elf_final_link): Make DT_REL/DT_RELA zero
3175 if DT_RELSZ/DT_RELASZ is zero.
3176
6438d1be
NC
31772017-02-17 Nick Clifton <nickc@redhat.com>
3178
3179 * compress.c (bfd_get_full_section_contents): Remember to reduce
3180 compressed size by the sizeof the compression header when
3181 decompressing the contents.
3182
4bc26c69
PA
31832017-02-17 Pedro Alves <palves@redhat.com>
3184
3185 * srec.c (Chunk): Rename to ...
3186 (_bfd_srec_len): ... this.
3187 (S3Forced): Rename to ...
3188 (_bfd_srec_forceS3): ... this.
3189 * objcopy.c: Adjust all references.
3190
7ec22e0f
PA
31912017-02-17 Pedro Alves <palves@redhat.com>
3192
3193 * archive.c (bsd_write_armap): Rename to ...
3194 (_bfd_bsd_write_armap): ... this.
3195 (coff_write_armap): Rename to ...
3196 (_bfd_coff_write_armap): ... this.
3197 * libbfd-in.h (bsd_write_armap): Rename to ...
3198 (_bfd_bsd_write_armap): ... this.
3199 (coff_write_armap): Rename to ...
3200 (_bfd_coff_write_armap): ... this.
3201 * aout-target.h, aout-tic30.c: Adjust all users.
3202 * libbfd.h: Regenerate.
3203
8c8402cc
PA
32042017-02-17 Pedro Alves <palves@redhat.com>
3205
3206 * bfd-in.h (bfd_read, bfd_write): Adjust to rename.
3207 (warn_deprecated): Rename to ...
3208 (_bfd_warn_deprecated): ... this.
3209 * libbfd.c (warn_deprecated): Rename to ...
3210 (_bfd_warn_deprecated): ... this.
3211 * bfd-in2.h: Regenerate.
3212
c7c3d11b
PA
32132017-02-17 Pedro Alves <palves@redhat.com>
3214
3215 * bfdio.c (real_ftell): Rename to ...
3216 (_bfd_real_ftell): ... this.
3217 (real_fseek): Rename to ...
3218 (_bfd_real_fseek): ... this.
3219 (real_fopen): Rename to ...
3220 (_bfd_real_fopen): ... this.
3221 * libbfd-in.h (real_ftell): Rename to ...
3222 (_bfd_real_ftell): ... this.
3223 (real_fseek): Rename to ...
3224 (_bfd_real_fseek): ... this.
3225 (real_fopen): Rename to ...
3226 (_bfd_real_fopen): ... this.
3227 * cache.c, dwarf2.c, opncls.c: Adjust all callers.
3228 * libbfd.h: Regenerate.
3229
4265548c
PA
32302017-02-17 Pedro Alves <palves@redhat.com>
3231
3232 * dwarf2.c, elf-attrs.c, elf32-nds32.c: Adjust all callers.
3233 * libbfd.c (read_unsigned_leb128): Rename to ...
3234 (_bfd_read_unsigned_leb128): ... this.
3235 (read_signed_leb128): Rename to ...
3236 (_bfd_read_signed_leb128): ... this.
3237 (safe_read_leb128): Rename to ...
3238 (_bfd_safe_read_leb128): ... this.
3239 * libbfd-in.h (read_unsigned_leb128): Rename to ...
3240 (_bfd_read_unsigned_leb128): ... this.
3241 (read_signed_leb128): Rename to ...
3242 (_bfd_read_signed_leb128): ... this.
3243 (safe_read_leb128): Rename to ...
3244 (_bfd_safe_read_leb128): ... this.
3245 * libbfd.h: Renegerate.
3246
3239a423
AB
32472017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
3248
3249 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Perform symbol lookup
3250 before trying to fine matching file and line information.
3251
90ed9b8b
AB
32522017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
3253
3254 * dwarf2.c (struct dwarf2_debug): Add orig_bfd member.
3255 (_bfd_dwarf2_slurp_debug_info): If stashed debug information does
3256 not match current bfd, then reload debug information. Record bfd
3257 we're loading debug info for in the stash. If we have debug
3258 informatin in the cache then perform section placement before
3259 returning.
3260
a8c75b76
AM
32612017-02-16 Alan Modra <amodra@gmail.com>
3262
3263 PR 21000
3264 * elf-bfd.h (struct elf_backend_data): Add no_page_alias.
3265 * elfxx-target.h (elf_backend_no_page_alias): Define.
3266 (elfNN_bed): Init new field.
3267 * elf.c (assign_file_positions_for_load_sections): If no_page_alias
3268 ensure PT_LOAD segment starts on a new page.
3269 * elf32-hppa.c (elf_backend_no_page_alias): Define.
3270
247d6c4c
AM
32712017-02-16 Alan Modra <amodra@gmail.com>
3272
3273 PR 21132
3274 * elf32-hppa.c (allocate_plt_static): Allocate space for relocs
3275 if pic.
3276
90571206
JW
32772017-02-16 Jiong Wang <jiong.wang@arm.com>
3278
3279 * bfd.c (BFD_FLAGS_SAVED): Add BFD_LINKER_CREATED.
3280 * bfd-in2.h: Regenerated.
3281
2a568401
L
32822017-02-15 H.J. Lu <hongjiu.lu@intel.com>
3283
3284 PR ld/21168
3285 * elf32-i386.c (elf_i386_relocate_section): Allow
3286 "lea foo@GOT, %reg" in PIC.
3287
a5def14f
L
32882017-02-15 H.J. Lu <hongjiu.lu@intel.com>
3289
3290 PR ld/20244
3291 * elf32-i386.c (elf_i386_relocate_section): Properly get IFUNC
3292 symbol name when reporting R_386_GOT32/R_386_GOT32X relocation
3293 error against local IFUNC symbol without a base register for
3294 PIC.
3295
174d0a74
MR
32962017-02-15 Maciej W. Rozycki <macro@imgtec.com>
3297
3298 * elf32-ppc.c (ppc_elf_check_relocs): Use `%H:' rather than
3299 `%P: %H:' with `info->callbacks->einfo'.
3300 (ppc_elf_relocate_section): Likewise.
3301 * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
3302 (ppc64_elf_edit_toc): Likewise.
3303 (ppc64_elf_relocate_section): Likewise.
3304
e278ae05
AM
33052017-02-14 Alan Modra <amodra@gmail.com>
3306
3307 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Support
3308 --gc-keep-exported, and test versioned field of sym rather than
3309 looking for @ in name.
3310
10ddfe62
PD
33112017-02-13 Palmer Dabbelt <palmer@dabbelt.com>
3312
3313 * elfnn-riscv.c (riscv_global_pointer_value): Change _gp to
3314 __global_pointer$.
3315
d11135f5
NC
33162017-02-13 Nick Clifton <nickc@redhat.com>
3317
3318 PR binutils/21151
3319 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Check for an invalid
3320 unit length field.
3321
cc162427
AW
33222017-02-07 Andrew Waterman <andrew@sifive.com>
3323
3324 * elfnn-riscv.c (riscv_elf_finish_dynamic_sections): Only write PLT
3325 entry size if PLT header is written.
3326
3d044c0c
SL
33272017-02-06 Sheldon Lobo <sheldon.lobo@oracle.com>
3328
3329 Fix sparc64 dynamic relocation processing to use the dynamic
3330 symbol count.
3331 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Use 'dynamic'
3332 to determine if bfd_get_symcount() or bfd_get_dynamic_symcount()
3333 should be used.
3334
1b7e3d2f
NC
33352017-02-03 Nick Clifton <nickc@redhat.com>
3336
3337 PR 21096
3338 * coffcode.h (coff_write_object_contents): Enlarge size of
3339 s_name_buf in order to avoid compile time warning about possible
3340 integer truncation.
3341 * elf32-nds32.c (nds32_elf_ex9_import_table): Mask off lower
3342 32-bits of insn value before printing into buffer.
3343
e17b0c35
MR
33442017-02-02 Maciej W. Rozycki <macro@imgtec.com>
3345
3346 * elfxx-mips.c (mips_elf_hash_sort_data): Add
3347 `max_local_dynindx'.
3348 (mips_elf_sort_hash_table): Handle it.
3349 (mips_elf_sort_hash_table_f) <GGA_NONE>: For forced local
3350 symbols bump up `max_local_dynindx' rather than
3351 `max_non_got_dynindx'.
3352
55f8b9d2
MR
33532017-02-02 Maciej W. Rozycki <macro@imgtec.com>
3354
3355 * elfxx-mips.c (mips_elf_hash_sort_data): Convert the
3356 `min_got_dynindx', `max_unref_got_dynindx' and
3357 `max_non_got_dynindx' members to the `bfd_size_type' data type.
3358 (mips_elf_sort_hash_table): Adjust accordingly.
3359
0f8c4b60
MR
33602017-02-02 Maciej W. Rozycki <macro@imgtec.com>
3361
3362 * elfxx-mips.c (mips_elf_sort_hash_table): Use `htab' throughout
3363 to access the hash table.
3364
17a80fa8
MR
33652017-02-02 Maciej W. Rozycki <macro@imgtec.com>
3366
3367 * elfxx-mips.c (mips_elf_sort_hash_table): Move assertion on
3368 non-NULL `htab' to the beginning.
3369
8f56d4fd
MR
33702017-02-02 Maciej W. Rozycki <macro@imgtec.com>
3371
3372 * elflink.c (elf_gc_sweep): Wrap overlong line.
3373
8b10b0b3
MR
33742017-01-30 Maciej W. Rozycki <macro@imgtec.com>
3375
3376 * elfxx-mips.h (_bfd_mips_elf_insn32): Rename prototype to...
3377 (_bfd_mips_elf_linker_flags): ... this. Add another parameter.
3378 * elfxx-mips.c (mips_elf_link_hash_table): Add
3379 `ignore_branch_isa' member.
3380 (mips_elf_perform_relocation): Do not treat an ISA mode mismatch
3381 in branch relocation calculation as an error if
3382 `ignore_branch_isa' has been set.
3383 (_bfd_mips_elf_insn32): Rename to...
3384 (_bfd_mips_elf_linker_flags): ... this. Rename the `on'
3385 parameter to `insn32' and add an `ignore_branch_isa' parameter.
3386 Handle the new parameter.
3387
1fbd05e1
HPN
33882017-01-27 Hans-Peter Nilsson <hp@axis.com>
3389
22d9a0de
HPN
3390 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Remove now unused
3391 local variable dynobj.
3392
1fbd05e1
HPN
3393 PR ld/20995
3394 * elf32-cris.c (elf_cris_size_dynamic_sections): Handle sdynrelro.
3395 (elf_cris_adjust_dynamic_symbol): Place variables copied into the
3396 executable from read-only sections into sdynrelro.
3397 (elf_cris_finish_dynamic_symbol): Select sreldynrelro for
3398 dynamic relocs in sdynrelro.
3399 (elf_backend_want_dynrelro): Define.
3400
4a7324e1
SH
34012017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
3402
3403 * config.bfd (*-*-rtemsaout*): Mark as removed.
3404
c75b4ebd
SH
34052017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
3406
3407 * config.bfd (powerpcle-*-rtems*): Do not mark as removed.
3408 (arm-*-rtems*): Move to (arm*-*-eabi*).
3409 (i[3-7]86-*-rtems*): Move to (i[3-7]86-*-elf*).
3410 (m68-*-rtems*): Move to (m68*-*-elf*).
3411
850d84f6
SH
34122017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
3413
3414 * config.bfd (*-*-rtemscoff*): Mark as removed.
3415
b531344c
MR
34162017-01-24 Maciej W. Rozycki <macro@imgtec.com>
3417
3418 PR ld/20828
3419 * elflink.c (bfd_elf_record_link_assignment): Revert last
3420 change and don't ever clear `forced_local'. Set `mark'
3421 unconditionally.
3422 (elf_gc_sweep_symbol_info, elf_gc_sweep_symbol): Reorder within
3423 file.
3424 (elf_gc_sweep): Move the call to `elf_gc_sweep_symbol'...
3425 (bfd_elf_size_dynamic_sections): ... here.
3426 * elf32-ppc.c (ppc_elf_tls_setup): Don't clear `forced_local'
3427 and set `mark' instead in `__tls_get_addr_opt' processing.
3428 * elf64-ppc.c (ppc64_elf_tls_setup): Likewise.
3429
f0158f44
AM
34302017-01-24 Alan Modra <amodra@gmail.com>
3431
3432 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Merge two cases
3433 where dynamic relocs are preferable. Allow ifunc too.
3434 (ensure_undefweak_dynamic): New function.
3435 (allocate_dynrelocs): Use it here. Move plt handling last and
3436 don't make symbols dynamic, simplifying loop. Only make undef
3437 weak symbols with GOT entries dynamic. Correct condition
3438 for GOT relocs. Handle dynamic relocs on ifuncs. Correct
3439 comments. Remove goto.
3440 (ppc_elf_relocate_section): Correct test for using dynamic
3441 symbol on GOT relocs. Rearrange test for emitting GOT relocs
3442 to suit. Set up explicit tls_index entries and implicit GOT
3443 tls_index entries resolvable at link time for
3444 __tls_get_addr_opt. Simplify test to clear mem for prelink.
3445 * elf64-ppc.c (allocate_got): Correct condition for GOT relocs.
3446 (ensure_undefweak_dynamic): New function.
3447 (allocate_dynrelocs): Use it here. Only make undef weak symbols
3448 with GOT entries dynamic. Remove unnecessary test of
3449 WILL_CALL_FINISH_DYNAMIC_SYMBOL in PLT handling.
3450 (ppc64_elf_relocate_section): Correct test for using dynamic
3451 symbol on GOT relocs. Rearrange test for emitting GOT relocs
3452 to suit. Set up explicit tls_index entries and implicit GOT
3453 tls_index entries resolvable at link time for __tls_get_addr_opt.
3454 Simplify expression to clear mem for prelink.
3455
2d0ca824
YN
34562017-01-23 Yury Norov <ynorov@caviumnetworks.com>
3457
3458 * elfnn-aarch64.c: Fix relaxations for ILP32 mode.
3459
7f784814
JW
34602017-01-20 Jiong Wang <jiong.wang@arm.com>
3461
3462 * elfnn-aarch64.c (elf_aarch64_hash_symbol): New function.
3463 (elf_backend_hash_symbol): Define.
3464
81ff47b3
MR
34652017-01-18 Maciej W. Rozycki <macro@imgtec.com>
3466
3467 PR ld/20828
3468 * elflink.c (bfd_elf_record_link_assignment): Clear any
3469 `forced_local' marking for DSO symbols that are not being
3470 provided.
3471
640d6bfd
KLC
34722017-01-17 Kuan-Lin Chen <kuanlinchentw@gmail.com>
3473
3474 * elfnn-riscv.c (riscv_elf_object_p): New function.
3475
8361ed4d
L
34762017-01-12 H.J. Lu <hongjiu.lu@intel.com>
3477
3478 PR ld/21038
3479 * elf64-x86-64.c (elf_x86_64_link_hash_table): Add
3480 plt_bnd_eh_frame.
3481 (elf_x86_64_check_relocs): Create .eh_frame section for the
3482 .plt.bnd section.
3483 (elf_x86_64_size_dynamic_sections): Allocate and initialize
3484 .eh_frame section for the .plt.bnd section.
3485 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
3486 for the .plt.bnd section.
3487
2425a30e
NC
34882017-01-12 Nick Clifton <nickc@redhat.com>
3489
3490 PR binutils/20876
3491 * opncls.c (find_separate_debug_file): Add include_dirs
3492 parameter. Only include the directory part of the bfd's filename
3493 in search paths if include_dirs is true. Add a couple of extra
3494 locations for looking for debug files.
3495 ( bfd_follow_gnu_debuglink): Update invocation of
3496 find_separate_debug_file.
3497 (bfd_follow_gnu_debugaltlink): Likewise.
3498 (get_build_id): New function: Finds the build-id of the given bfd.
3499 (get_build_id_name): New function: Computes the name of the
3500 separate debug info file for a bfd, based upon its build-id.
3501 (check_build_id_file): New function: Checks to see if a separate
3502 debug info file exists at the given location, and that its
3503 build-id matches that of the original bfd.
3504 (bfd_follow_build_id_debuglink): New function: Finds a separate
3505 debug info file for a given bfd by using the build-id method.
3506 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Try using the build-id
3507 method of locating a separate debug info file before using the
3508 debuglink method.
3509 * bfd-in2.h: Regenerate.
3510
9e659176
L
35112017-01-11 H.J. Lu <hongjiu.lu@intel.com>
3512
3513 PR ld/21038
3514 * elf64-x86-64.c (elf_x86_64_eh_frame_bnd_plt): New.
3515 (elf_x86_64_bnd_arch_bed): Use elf_x86_64_eh_frame_bnd_plt and
3516 elf_x86_64_eh_frame_plt_got.
3517 (elf_x86_64_size_dynamic_sections): Get unwind info from
3518 elf_x86_64_bnd_arch_bed for the BND PLT.
3519
f2e2d2f5
JS
35202017-01-11 Jeremy Soller <jackpot51@gmail.com>
3521
3522 * config.bfd: Add entries for i686-redox and x86_64-redox.
3523
52b232b3
L
35242017-01-10 H.J. Lu <hongjiu.lu@intel.com>
3525
3526 * elf32-i386.c (elf_i386_check_relocs): Align .eh_frame section
3527 to 4 bytes.
3528 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Align
3529 .eh_frame section to 4 bytes for x32.
3530 (elf_x86_64_check_relocs): Likewise.
3531
fff53dae
L
35322017-01-10 H.J. Lu <hongjiu.lu@intel.com>
3533
3534 PR ld/20830
3535 * elf32-i386.c (elf_i386_eh_frame_plt_got): New.
3536 (PLT_GOT_FDE_LENGTH): Likewise.
3537 (elf_i386_plt_layout): Add eh_frame_plt_got and
3538 eh_frame_plt_got_size.
3539 (elf_i386_plt): Updated.
3540 (elf_i386_link_hash_table): Add plt_got_eh_frame.
3541 (elf_i386_check_relocs): Create .eh_frame section for .plt.got.
3542 (elf_i386_size_dynamic_sections): Allocate and initialize
3543 .eh_frame section for .plt.got.
3544 (elf_i386_finish_dynamic_sections): Adjust .eh_frame section for
3545 .plt.got.
3546 (elf_i386_nacl_plt): Add FIXME for eh_frame_plt_got and
3547 eh_frame_plt_got_size.
3548 * elf64-x86-64.c (elf_x86_64_eh_frame_plt_got): New.
3549 (PLT_GOT_FDE_LENGTH): Likewise.
3550 (elf_x86_64_backend_data): Add eh_frame_plt_got and
3551 eh_frame_plt_got_size.
3552 (elf_x86_64_arch_bed): Updated.
3553 (elf_x86_64_bnd_arch_bed): Add FIXME for eh_frame_plt_got and
3554 eh_frame_plt_got_size.
3555 (elf_x86_64_nacl_arch_bed): Likewise.
3556 (elf_x86_64_link_hash_table): Add plt_got_eh_frame.
3557 (elf_x86_64_check_relocs): Create .eh_frame section for .plt.got.
3558 (elf_x86_64_size_dynamic_sections): Allocate and initialize
3559 .eh_frame section for .plt.got.
3560 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
3561 for .plt.got.
3562
f129e49f
L
35632017-01-10 H.J. Lu <hongjiu.lu@intel.com>
3564
3565 * elf32-i386.c (elf_i386_size_dynamic_sections): Set
3566 plt_eh_frame->size to eh_frame_plt_size and use eh_frame_plt.
3567
cd6581da
NC
35682017-01-09 Nick Clifton <nickc@redhat.com>
3569
3570 * dwarf2.c (lookup_address_in_function_table): Return early if
3571 there are no functions in the given comp unit, or if the high
3572 address of the last function in the comp unit is less than the
3573 desired address.
3574
98f02962
NC
35752017-01-09 Nick Clifton <nickc@redhat.com>
3576
3577 PR binutils/21013
3578 * coffgen.c (_bfd_coff_get_external_symbols): Generate an error
3579 message if there are too many symbols to load.
3580
ae4fda66
JC
35812017-01-04 James Clarke <jrtc27@jrtc27.com>
3582
3583 * elf64-alpha.c (elf64_alpha_relax_opt_call): Don't set tsec_free
3584 if relocs are cached.
3585
de1010f4
RF
35862017-01-03 Rich Felker <bugdal@aerifal.cx>
3587
3588 PR ld/21017
3589 * elf32-microblaze.c (microblaze_elf_check_relocs): Add an entry
3590 for R_MICROBLAZE_GOTOFF_64.
3591
09fe2662
NC
35922017-01-03 Nick Clifton <nickc@redhat.com>
3593
3594 * mach-o.c (bfd_mach_o_lookup_uuid_command): Fix compile time
3595 warning about using a possibly uninitialised variable.
3596
595e0a47
AM
35972017-01-02 Alan Modra <amodra@gmail.com>
3598
3599 * elf32-hppa.c (ensure_undef_weak_dynamic): New function.
3600 (allocate_plt_static, allocate_dynrelocs): Use it.
3601
7bd9df3b
AM
36022017-01-02 Alan Modra <amodra@gmail.com>
3603
3604 * elf-hppa.h (elf_hppa_fake_sections): Set SHF_INFO_LINK for
3605 .PARISC.unwind section.
3606
5b86074c
AM
36072017-01-02 Alan Modra <amodra@gmail.com>
3608
3609 PR ld/20989
3610 * elfxx-sparc.c (gdop_relative_offset_ok): New function.
3611 (_bfd_sparc_elf_relocate_section): Use it to validate GOT
3612 indirect to GOT pointer relative code edit.
3613
2571583a
AM
36142017-01-02 Alan Modra <amodra@gmail.com>
3615
3616 Update year range in copyright notice of all files.
3617
5c1ad6b5 3618For older changes see ChangeLog-2016
3499769a 3619\f
5c1ad6b5 3620Copyright (C) 2017 Free Software Foundation, Inc.
3499769a
AM
3621
3622Copying and distribution of this file, with or without modification,
3623are permitted in any medium without royalty provided the copyright
3624notice and this notice are preserved.
3625
3626Local Variables:
3627mode: change-log
3628left-margin: 8
3629fill-column: 74
3630version-control: never
3631End: