45dbbe4d64192630fba33f33fef4bf5e4895b24a
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2016-05-20 H.J. Lu <hongjiu.lu@intel.com>
2
3 * elf32-i386.c (elf_i386_check_relocs): Don't check R_386_GOT32
4 when setting need_convert_load.
5
6 2016-05-20 Maciej W. Rozycki <macro@imgtec.com>
7
8 * elfxx-mips.c (mips_elf_read_rel_addend): Adjust the addend for
9 microMIPS JALX.
10
11 2016-05-19 H.J. Lu <hongjiu.lu@intel.com>
12
13 PR ld/20117
14 * elf32-i386.c (elf_i386_convert_load_reloc): Don't check
15 R_386_GOT32X.
16 (elf_i386_convert_load): Don't convert R_386_GOT32.
17
18 2016-05-20 Alan Modra <amodra@gmail.com>
19
20 PR gas/20118
21 * elf.c (elf_fake_sections): Set sh_entsize for SHT_INIT_ARRAY,
22 SHT_FINI_ARRAY, and SHT_PREINIT_ARRAY.
23
24 2016-05-19 Cupertino Miranda <cmiranda@synopsys.com>
25
26 * elf32-arc.c (arc_elf_final_write_processing): Changed.
27 (debug_arc_reloc): Likewise.
28 (elf_arc_relocate_section): Likewise.
29 (elf_arc_check_relocs): Likewise.
30 (elf_arc_adjust_dynamic_symbol): Likewise.
31 (elf_arc_add_symbol_hook): Likewise.
32
33 2016-05-19 Maciej W. Rozycki <macro@imgtec.com>
34
35 * config.bfd: Remove `am34-*-linux*' support.
36
37 2016-05-19 Alan Modra <amodra@gmail.com>
38
39 * elf64-ppc.c (allocate_dynrelocs): Allocate got and other dynamic
40 relocs before plt relocs.
41
42 2016-05-19 Alan Modra <amodra@gmail.com>
43
44 * elf64-ppc.c (ppc64_elf_branch_reloc): Check for NULL owner
45 before dereferencing.
46
47 2016-05-18 Nick Clifton <nickc@redhat.com>
48
49 * po/sv.po: Updated Swedish translation.
50
51 2016-05-18 Alan Modra <amodra@gmail.com>
52
53 * elf32-arm.c (elf32_arm_size_stubs): Free or cache local syms
54 for each BFD. Don't goto error_ret_free_local from outside loop.
55
56 2016-05-17 Maciej W. Rozycki <macro@imgtec.com>
57
58 * elf-s390-common.c (elf_s390_add_symbol_hook): Remove
59 STB_GNU_UNIQUE handling.
60 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
61 * elf32-arm.c (elf32_arm_add_symbol_hook): Likewise.
62 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
63 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
64 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
65 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
66 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
67 * elf64-x86-64.c (elf_x86_64_add_symbol_hook): Likewise.
68 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
69 * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Likewise.
70 * elf32-i386.c (elf_i386_add_symbol_hook): Remove function.
71 (elf_backend_add_symbol_hook): Remove macro.
72 * elflink.c (elf_link_add_object_symbols): Set `has_gnu_symbols'
73 for STB_GNU_UNIQUE symbols.
74
75 2016-05-16 Maciej W. Rozycki <macro@imgtec.com>
76
77 * elf32-v850.c (v850_elf_copy_notes): New function, factored out
78 from...
79 (v850_elf_copy_private_bfd_data): ... here. Call the new
80 function and `_bfd_elf_copy_private_bfd_data'.
81
82 2016-05-13 H.J. Lu <hongjiu.lu@intel.com>
83
84 PR ld/20093
85 * elf64-x86-64.c (elf_x86_64_convert_load_reloc): Don't convert
86 GOTPCREL relocation against large section.
87
88 2016-05-13 Alan Modra <amodra@gmail.com>
89
90 * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_sections): Use
91 linker dynamic sections in calculating size and address of
92 dynamic tags rather than using output sections. Remove asserts.
93 * elf32-arm.c (elf32_arm_finish_dynamic_sections): Likewise.
94 * elf32-cr16.c (_bfd_cr16_elf_finish_dynamic_sections): Likewise.
95 * elf32-cris.c (elf_cris_finish_dynamic_sections): Likewise.
96 * elf32-i370.c (i370_elf_finish_dynamic_sections): Likewise.
97 * elf32-lm32.c (lm32_elf_finish_dynamic_sections): Likewise.
98 * elf32-m32r.c (m32r_elf_finish_dynamic_sections): Likewise.
99 * elf32-m68k.c (elf_m68k_finish_dynamic_sections): Likewise.
100 * elf32-metag.c (elf_metag_finish_dynamic_sections): Likewise.
101 * elf32-microblaze.c (microblaze_elf_finish_dynamic_sections): Likewise.
102 * elf32-nds32.c (nds32_elf_finish_dynamic_sections): Likewise.
103 * elf32-nios2.c (nios2_elf32_finish_dynamic_sections): Likewise.
104 * elf32-or1k.c (or1k_elf_finish_dynamic_sections): Likewise.
105 * elf32-s390.c (elf_s390_finish_dynamic_sections): Likewise.
106 * elf32-score.c (s3_bfd_score_elf_finish_dynamic_sections): Likewise.
107 * elf32-score7.c (s7_bfd_score_elf_finish_dynamic_sections): Likewise.
108 * elf32-vax.c (elf_vax_finish_dynamic_sections): Likewise.
109 * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Likewise.
110 * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Likewise.
111 * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
112 * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Likewise.
113 * elflink.c (bfd_elf_final_link): Likewise.
114 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Likewise.
115 * elfxx-sparc.c (sparc_finish_dyn): Likewise. Adjust error message.
116 * elf32-arc.c (GET_SYMBOL_OR_SECTION): Remove ASSERT arg and
117 don't set doit. Look up dynobj section.
118 (elf_arc_finish_dynamic_sections): Adjust GET_SYMBOL_OR_SECTION
119 invocation and dynamic tag vma calculation. Don't test
120 boolean var == TRUE.
121 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_sections): Fix
122 DT_JMPREL calc.
123
124 2016-05-13 Alan Modra <amodra@gmail.com>
125
126 * elflink.c (elf_link_sort_relocs): Wrap overlong lines. Fix
127 octets_per_byte. Put dynamic .rela.plt last in link orders.
128 Assign output_offset for reloc sections rather than writing
129 sorted relocs from block corresponding to output_offset.
130
131 2016-05-12 Alan Modra <amodra@gmail.com>
132
133 * elf-bfd.h (elf_reloc_type_class): Put reloc_class_plt last.
134
135 2016-05-11 Andrew Bennett <andrew.bennett@imgtec.com>
136
137 * elfxx-mips.c (print_mips_ases): Add DSPR3.
138
139 2016-05-11 Alan Modra <amodra@gmail.com>
140
141 * elf32-hppa.c (elf32_hppa_init_stub_bfd): New function.
142 (elf32_hppa_check_relocs): Don't set dynobj.
143 (elf32_hppa_size_stubs): Test !SEC_LINKER_CREATED for stub sections.
144 (elf32_hppa_build_stubs): Likewise.
145 * elf32-hppa.h (elf32_hppa_init_stub_bfd): Declare.
146
147 2016-05-11 Alan Modra <amodra@gmail.com>
148
149 PR 20060
150 * elf64-ppc.c (ppc64_elf_tls_setup): Clear forced_local.
151 * elf32-ppc.c (ppc_elf_tls_setup): Likewise.
152
153 2016-05-10 Jiong Wang <jiong.wang@arm.com>
154
155 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Remove redundant
156 aarch64_tls_transition check.
157
158 2016-05-10 Thomas Preud'homme <thomas.preudhomme@arm.com>
159
160 * elf32-arm.c (enum elf32_arm_stub_type): New max_stub_type
161 enumerator.
162 (arm_stub_sym_claimed): New function.
163 (elf32_arm_create_stub): Use veneered symbol name and section if
164 veneer needs to claim its symbol, and keep logic unchanged otherwise.
165 (arm_stub_claim_sym): New function.
166 (arm_map_one_stub): Call arm_stub_claim_sym if veneer needs to claim
167 veneered symbol, otherwise create local symbol as before.
168
169 2016-05-10 Thomas Preud'homme <thomas.preudhomme@arm.com>
170
171 * elf32-arm.c (elf32_arm_size_stubs): Use new macros
172 ARM_GET_SYM_BRANCH_TYPE and ARM_SET_SYM_BRANCH_TYPE to respectively get
173 and set branch type of a symbol.
174 (bfd_elf32_arm_process_before_allocation): Likewise.
175 (elf32_arm_relocate_section): Likewise and fix identation along the
176 way.
177 (allocate_dynrelocs_for_symbol): Likewise.
178 (elf32_arm_finish_dynamic_symbol): Likewise.
179 (elf32_arm_swap_symbol_in): Likewise.
180 (elf32_arm_swap_symbol_out): Likewise.
181
182 2016-05-10 Thomas Preud'homme <thomas.preudhomme@arm.com>
183
184 * bfd-in.h (elf32_arm_size_stubs): Add an output section parameter.
185 * bfd-in2.h: Regenerated.
186 * elf32-arm.c (struct elf32_arm_link_hash_table): Add an output section
187 parameter to add_stub_section callback.
188 (elf32_arm_create_or_find_stub_sec): Get output section from link_sec
189 and pass it down to add_stub_section.
190 (elf32_arm_add_stub): Set section to stub_sec if NULL before using it
191 for error message.
192 (elf32_arm_size_stubs): Add output section parameter to
193 add_stub_section function pointer parameter.
194
195 2016-05-10 Thomas Preud'homme <thomas.preudhomme@arm.com>
196
197 * elf32-arm.c (elf32_arm_create_stub): New function.
198 (elf32_arm_size_stubs): Use elf32_arm_create_stub for stub creation.
199
200 2016-05-10 Thomas Preud'homme <thomas.preudhomme@arm.com>
201
202 * elf32-arm.c (enum elf32_arm_stub_type): Delete
203 arm_stub_a8_veneer_lwm enumerator.
204 (arm_stub_a8_veneer_lwm): New unsigned constant to replace
205 aforementioned enumerator.
206 (struct elf32_arm_stub_hash_entry): Delete target_addend
207 field and add source_value.
208 (struct a8_erratum_fix): Delete addend field and add target_offset.
209 (stub_hash_newfunc): Initialize source_value field amd remove
210 initialization for target_addend.
211 (arm_build_one_stub): Stop special casing Thumb relocations: promote
212 the else to being always executed, moving the
213 arm_stub_a8_veneer_b_cond specific code in it. Remove
214 stub_entry->target_addend from points_to computation.
215 (cortex_a8_erratum_scan): Store in a8_erratum_fix structure the offset
216 to target symbol from start of section rather than the offset from the
217 stub address.
218 (elf32_arm_size_stubs): Set stub_entry's source_value and target_value
219 fields from struct a8_erratum_fix's offset and target_offset
220 respectively.
221 (make_branch_to_a8_stub): Rename target variable to loc. Compute
222 veneered_insn_loc and loc using stub_entry's source_value.
223
224 2016-05-10 Thomas Preud'homme <thomas.preudhomme@arm.com>
225
226 (elf32_arm_merge_eabi_attributes): Add merging logic for
227 Tag_DSP_extension.
228
229 2016-05-10 Pip Cet <pipcet@gmail.com>
230
231 PR ld/20059
232 * elfxx-target.h (bfd_elfNN_bfd_copy_link_hash_symbol_type):
233 Define as _bfd_generic_copy_link_hash_symbol_type when using
234 generic hash table.
235
236 2016-05-09 Nick Clifton <nickc@redhat.com>
237
238 PR binutils/20063
239 * elf.c (bfd_elf_get_elf_syms): Check for out of range sh_link
240 field before accessing sections array.
241
242 2016-05-09 Christophe Monat <christophe.monat@st.com>
243
244 PR ld/20030
245 * elf32-arm.c (is_thumb2_vldm): Account for T1 (DP) encoding.
246 (stm32l4xx_need_create_replacing_stub): Rename ambiguous nb_regs
247 to nb_words.
248 (create_instruction_vldmia): Add is_dp to disambiguate SP/DP
249 encoding.
250 (create_instruction_vldmdb): Likewise.
251 (stm32l4xx_create_replacing_stub_vldm): is_dp detects DP encoding,
252 uses it to re-encode.
253
254 2016-05-09 Nick Clifton <nickc@redhat.com>
255
256 PR 19938
257 * elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Revert accidental
258 commit.
259
260 2016-05-09 Alan Modra <amodra@gmail.com>
261
262 * elf64-ppc.c (ppc64_elf_init_stub_bfd): Remove redundant NULL check.
263
264 2016-05-06 H.J. Lu <hongjiu.lu@intel.com>
265
266 PR ld/17550
267 * elf-bfd.h (elf_link_hash_entry): Update comments for indx,
268 documenting that indx == -3 if symbol is defined in a discarded
269 section.
270 * elflink.c (elf_link_add_object_symbols): Set indx to -3 if
271 symbol is defined in a discarded section.
272 (elf_link_output_extsym): Strip a global symbol defined in a
273 discarded section.
274
275 2016-05-06 H.J. Lu <hongjiu.lu@intel.com>
276
277 * elf32-i386.c (elf_backend_add_symbol_hook): Defined for Intel
278 MCU.
279
280 2016-05-05 H.J. Lu <hongjiu.lu@intel.com>
281
282 * elf32-i386.c (elf_i386_convert_load): Extract the GOT load
283 conversion to ...
284 (elf_i386_convert_load_reloc): This. New function.
285 * elf64-x86-64.c (elf_x86_64_convert_load): Extract the GOT load
286 conversion to ...
287 (elf_x86_64_convert_load_reloc): This. New function.
288
289 2016-05-05 H.J. Lu <hongjiu.lu@intel.com>
290
291 * elf32-i386.c (elf_i386_check_tls_transition): Remove abfd.
292 Don't check if contents == NULL.
293 (elf_i386_tls_transition): Add from_relocate_section. Check
294 from_relocate_section instead of contents != NULL. Update
295 elf_i386_check_tls_transition call.
296 (elf_i386_check_relocs): Cache the section contents if
297 keep_memory is FALSE. Pass FALSE as from_relocate_section to
298 elf_i386_tls_transition.
299 (elf_i386_relocate_section): Pass TRUE as from_relocate_section
300 to elf_i386_tls_transition.
301 (elf_backend_caches_rawsize): New.
302 * elf64-x86-64.c (elf_x86_64_check_tls_transition): Don't check
303 if contents == NULL.
304 (elf_x86_64_tls_transition): Add from_relocate_section. Check
305 from_relocate_section instead of contents != NULL.
306 (elf_x86_64_check_relocs): Cache the section contents if
307 keep_memory is FALSE. Pass FALSE as from_relocate_section to
308 elf_x86_64_tls_transition.
309 (elf_x86_64_relocate_section): Pass TRUE as from_relocate_section
310 to elf_x86_64_tls_transition.
311 (elf_backend_caches_rawsize): New.
312
313 2016-05-03 Maciej W. Rozycki <macro@imgtec.com>
314
315 PR 10549
316 * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Handle
317 STB_GNU_UNIQUE.
318
319 2016-05-03 Jiong Wang <jiong.wang@arm.com>
320
321 * bfd-in.h (bfd_elf64_aarch64_set_options): Update prototype.
322 * bfd-in2.h (bfd_elf64_aarch64_set_options): Likewise.
323 * elfnn-aarch64.c (bfd_elfNN_aarch64_set_options): Initialize
324 no_apply_dynamic_relocs.
325 (elfNN_aarch64_final_link_relocate): Apply absolute relocations even though
326 dynamic relocations generated.
327
328 2016-04-29 H.J. Lu <hongjiu.lu@intel.com>
329
330 * elf32-i386.c (elf_i386_size_dynamic_sections): Move interp
331 setting to ...
332 (elf_i386_create_dynamic_sections): Here.
333 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Move
334 interp setting to ...
335 (elf_x86_64_create_dynamic_sections): Here.
336
337 2016-04-29 H.J. Lu <hongjiu.lu@intel.com>
338
339 * elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Take GOT_RELOC
340 and replace (EH)->has_got_reloc with GOT_RELOC.
341 (elf_i386_fixup_symbol): Pass has_got_reloc to
342 UNDEFINED_WEAK_RESOLVED_TO_ZERO.
343 (elf_i386_allocate_dynrelocs): Likewise.
344 (elf_i386_relocate_section): Likewise.
345 (elf_i386_finish_dynamic_symbol): Likewise.
346 (elf_i386_convert_load): Pass TRUE to
347 UNDEFINED_WEAK_RESOLVED_TO_ZERO.
348 * elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Take
349 GOT_RELOC and replace (EH)->has_got_reloc with GOT_RELOC.
350 (elf_x86_64_fixup_symbol): Pass has_got_reloc to
351 UNDEFINED_WEAK_RESOLVED_TO_ZERO.
352 (elf_x86_64_allocate_dynrelocs): Likewise.
353 (elf_x86_64_relocate_section): Likewise.
354 (elf_x86_64_finish_dynamic_symbol): Likewise.
355 (elf_x86_64_convert_load): Pass TRUE to
356 UNDEFINED_WEAK_RESOLVED_TO_ZERO.
357
358 2016-04-29 H.J. Lu <hongjiu.lu@intel.com>
359
360 * elf32-i386.c (check_relocs_failed): New.
361 (elf_i386_check_relocs): Set check_relocs_failed on error.
362 (elf_i386_relocate_section): Skip if check_relocs failed.
363
364 2016-04-29 H.J. Lu <hongjiu.lu@intel.com>
365
366 * elf64-x86-64.c (elf_x86_64_check_relocs): Set
367 check_relocs_failed on error.
368
369 2016-04-29 Nick Clifton <nickc@redhat.com>
370
371 PR 19938
372 * elf-bfd.h (struct elf_backend_data): Rename
373 elf_backend_set_special_section_info_and_link to
374 elf_backend_copy_special_section_fields.
375 * elfxx-target.h: Likewise.
376 * elf.c (section_match): Ignore the SHF_INFO_LINK flag when
377 comparing section flags.
378 (copy_special_section_fields): New function.
379 (_bfd_elf_copy_private_bfd_data): Copy the EI_ABIVERSION field.
380 Perform two scans over special sections. The first one looks for
381 a direct mapping between the output section and an input section.
382 The second scan looks for a possible match based upon section
383 characteristics.
384 * elf32-arm.c (elf32_arm_copy_special_section_fields): New
385 function. Handle setting the sh_link field of SHT_ARM_EXIDX
386 sections.
387 * elf32-i386.c (elf32_i386_set_special_info_link): Rename to
388 elf32_i386_copy_solaris_special_section_fields.
389 * elf32-sparc.c (elf32_sparc_set_special_section_info_link):
390 Rename to elf32_sparc_copy_solaris_special_section_fields.
391 * elf64-x86-64.c (elf64_x86_64_set_special_info_link): Rename to
392 elf64_x86_64_copy_solaris_special_section_fields.
393
394 2016-04-28 Nick Clifton <nickc@redhat.com>
395
396 * po/zh_CN.po: Updated Chinese (simplified) translation.
397
398 2016-04-27 H.J. Lu <hongjiu.lu@intel.com>
399
400 PR ld/20006
401 * elf64-x86-64.c (elf_x86_64_convert_load): Skip debug sections
402 when estimating distances between output sections.
403
404 2016-04-27 Alan Modra <amodra@gmail.com>
405
406 * elflink.c (_bfd_elf_is_start_stop): New function.
407 (_bfd_elf_gc_mark_rsec): Use it.
408 * elf-bfd.h (_bfd_elf_is_start_stop): Declare.
409
410 2016-04-26 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
411
412 * elf32-rx.c (rx_set_section_contents): Avoid arithmetic on void *.
413 * mmo.c (mmo_get_section_contents): Likewise.
414 (mmo_set_section_contents): Likewise.
415
416 2016-04-26 H.J. Lu <hongjiu.lu@intel.com>
417
418 * elf-bfd.h (elf_link_hash_table): Update comments for
419 dynsymcount.
420 * elflink.c (_bfd_elf_link_renumber_dynsyms): Always count for
421 the unused NULL entry at the head of dynamic symbol table.
422 (bfd_elf_size_dynsym_hash_dynstr): Remove dynsymcount != 0
423 checks.
424
425 2016-04-21 H.J. Lu <hongjiu.lu@intel.com>
426
427 * elflink.c (_bfd_elf_link_create_dynstrtab): Exclude linker
428 created file from dynobj.
429
430 2016-04-21 H.J. Lu <hongjiu.lu@intel.com>
431
432 * elflink.c (_bfd_elf_link_create_dynstrtab): Set dynobj to a
433 normal input file if possible.
434
435 2016-04-21 Nick Clifton <nickc@redhat.com>
436
437 * aout-adobe.c: Use _bfd_generic_link_check_relocs.
438 * aout-target.h: Likewise.
439 * aout-tic30.c: Likewise.
440 * binary.c: Likewise.
441 * bout.c: Likewise.
442 * coff-alpha.c: Likewise.
443 * coff-rs6000.c: Likewise.
444 * coff64-rs6000.c: Likewise.
445 * coffcode.h: Likewise.
446 * i386msdos.c: Likewise.
447 * i386os9k.c: Likewise.
448 * ieee.c: Likewise.
449 * ihex.c: Likewise.
450 * libbfd-in.h: Likewise.
451 * libecoff.h: Likewise.
452 * mach-o-target.c: Likewise.
453 * mmo.c: Likewise.
454 * nlm-target.h: Likewise.
455 * oasys.c: Likewise.
456 * pef.c: Likewise.
457 * plugin.c: Likewise.
458 * ppcboot.c: Likewise.
459 * som.c: Likewise.
460 * srec.c: Likewise.
461 * tekhex.c: Likewise.
462 * versados.c: Likewise.
463 * vms-alpha.c: Likewise.
464 * xsym.c: Likewise.
465 * elfxx-target.h: Use _bfd_elf_link_check_relocs.
466 * linker.c (bfd_link_check_relocs): New function.
467 (_bfd_generic_link_check_relocs): New function.
468 * targets.c (BFD_JUMP_TABLE_LINK): Add initialization of
469 _bfd_link_check_relocs field.
470 (struct bfd_target)L Add _bfd_link_check_relocs field.
471 * bfd-in2.h: Regenerate.
472 * libbfd.h: Regenerate.
473
474 2016-04-20 H.J. Lu <hongjiu.lu@intel.com>
475
476 * elf32-i386.c (elf_i386_gc_sweep_hook): Removed.
477 (elf_backend_gc_sweep_hook): Likewise.
478 * elf64-x86-64.c (elf_x86_64_gc_sweep_hook): Likewise.
479 (elf_backend_gc_sweep_hook): Likewise.
480
481 2016-04-20 H.J. Lu <hongjiu.lu@intel.com>
482
483 * elflink.c (_bfd_elf_link_check_relocs): Don't check relocations
484 in excluded sections
485
486 2016-04-20 H.J. Lu <hongjiu.lu@intel.com>
487
488 PR ld/19969
489 * elf64-x86-64.c (check_relocs_failed): New.
490 (elf_x86_64_need_pic): Moved before elf_x86_64_check_relocs.
491 Support relocation agaist local symbol. Set check_relocs_failed.
492 (elf_x86_64_check_relocs): Use elf_x86_64_need_pic. Check
493 R_X86_64_32 relocation overflow.
494 (elf_x86_64_relocate_section): Skip if check_relocs failed.
495 Update one elf_x86_64_need_pic and remove one elf_x86_64_need_pic.
496
497 2016-04-20 H.J. Lu <hongjiu.lu@intel.com>
498
499 * elf32-i386.c (elf_i386_check_relocs): Call
500 _bfd_elf_create_ifunc_sections only for STT_GNU_IFUNC symbol.
501 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
502
503 2016-04-20 H.J. Lu <hongjiu.lu@intel.com>
504
505 * elf-bfd.h (_bfd_elf_link_check_relocs): New.
506 * elflink.c (_bfd_elf_link_check_relocs): New function.
507 (elf_link_add_object_symbols): Call _bfd_elf_link_check_relocs
508 if check_relocs_after_open_input is FALSE.
509
510 2016-04-20 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
511
512 * cache.c: Update old style function definitions.
513 * elf32-m68k.c: Likewise.
514 * elf64-mmix.c: Likewise.
515 * stab-syms.c: Likewise.
516
517 2016-04-20 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
518
519 * elf32-arm.c (put_thumb2_insn): Change argument type to bfd_byte *.
520
521 2016-04-15 H.J. Lu <hongjiu.lu@intel.com>
522
523 * Makefile.in: Regenerated with automake 1.11.6.
524 * aclocal.m4: Likewise.
525 * doc/Makefile.in: Likewise.
526
527 2016-04-14 Andrew Burgess <andrew.burgess@embecosm.com>
528
529 * reloc.c: Add BFD_RELOC_ARC_NPS_CMEM16 entry.
530 * bfd-in2.h: Regenerate.
531 * libbfd.h: Regenerate.
532 * elf32-arc.c: Add 'opcode/arc.h' include.
533 (struct arc_relocation_data): Add symbol_name.
534 (arc_special_overflow_checks): New function.
535 (arc_do_relocation): Use arc_special_overflow_checks, reindent as
536 required, add an extra comment.
537 (elf_arc_relocate_section): Setup symbol_name in reloc_data.
538
539 2016-04-14 Andrew Burgess <andrew.burgess@embecosm.com>
540
541 * elf32-arc.c (tls_got_entries): Add 'TLS_GOT_' prefix to all
542 entries.
543 (elf_arc_relocate_section): Update enum uses.
544 (elf_arc_check_relocs): Likewise.
545 (elf_arc_finish_dynamic_symbol): Likewise.
546
547 2016-04-14 H.J. Lu <hongjiu.lu@intel.com>
548
549 * elf.c (_bfd_elf_copy_private_bfd_data): Replace "link" with
550 "sh_link".
551
552 2016-04-14 Nick Clifton <nickc@redhat.com>
553
554 PR target/19938
555 * elf-bbfd.h (struct elf_backend_data): New field:
556 elf_strtab_flags.
557 New field: elf_backend_set_special_section_info_and_link
558 * elfxx-target.h (elf_backend_strtab_flags): Define if not already
559 defined.
560 (elf_backend_set_special_section_info_and_link): Define if not
561 already defined.
562 (elfNN_bed): Use elf_backend_set_special_section_info_and_link and
563 elf_backend_strtab_flags macros to initialise fields in structure.
564 * elf.c (_bfd_elf_make_section_from_shdr): Check for SHF_STRINGS
565 being set even if SHF_MERGE is not set.
566 (elf_fake_sections): Likewise.
567 (section_match): New function. Matches two ELF sections based
568 upon fixed characteristics.
569 (find_link): New function. Locates a section in a BFD that
570 matches a section in a different BFD.
571 (_bfd_elf_copy_private_bfd_data): Copy the sh_info and sh_link
572 fields of reserved sections.
573 (bfd_elf_compute_section_file_positions): Set the flags for the
574 .shstrtab section based upon the elf_strtab_flags field in the
575 elf_backend_data structure.
576 (swap_out_syms): Likewise for the .strtab section.
577 * elflink.c (bfd_elf_final_link): Set the flags for the
578 .strtab section based upon the elf_strtab_flags field in the
579 elf_backend_data structure.
580 * elf32-i386.c (elf32_i386_set_special_info_link): New function.
581 (elf_backend_strtab_flags): Set to SHF_STRINGS for Solaris
582 targets.
583 (elf_backend_set_special_section_info_and_link): Define for
584 Solaris targets.
585 * elf32-sparc.c: Likewise.
586 * elf64-x86-64.c: Likewise.
587
588 2016-04-11 H.J. Lu <hongjiu.lu@intel.com>
589
590 PR ld/19939
591 * elf-bfd.h (_bfd_elf_allocate_ifunc_dyn_relocs): Add a pointer
592 to bfd_boolean.
593 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Updated.
594 Set *readonly_dynrelocs_against_ifunc_p to TRUE if dynamic reloc
595 applies to read-only section.
596 * elf32-i386.c (elf_i386_link_hash_table): Add
597 readonly_dynrelocs_against_ifunc.
598 (elf_i386_allocate_dynrelocs): Updated.
599 (elf_i386_size_dynamic_sections): Issue an error for read-only
600 segment with dynamic IFUNC relocations only if
601 readonly_dynrelocs_against_ifunc is TRUE.
602 * elf64-x86-64.c (elf_x86_64_link_hash_table): Add
603 readonly_dynrelocs_against_ifunc.
604 (elf_x86_64_allocate_dynrelocs): Updated.
605 (elf_x86_64_size_dynamic_sections): Issue an error for read-only
606 segment with dynamic IFUNC relocations only if
607 readonly_dynrelocs_against_ifunc is TRUE.
608 * elfnn-aarch64.c (elfNN_aarch64_allocate_ifunc_dynrelocs):
609 Updated.
610
611 2016-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
612
613 * elf32-arm.c (elf32_arm_size_stubs): Move error_ret_free_local to be
614 a fall through from error_ret_free_internal. Free local_syms in
615 error_ret_free_local if allocated from bfd_elf_get_elf_syms ().
616
617 2016-04-05 Cupertino Miranda <cmiranda@synopsys.com>
618
619 * elf32-arc.c (plt_do_relocs_for_symbol): Changed.
620 (relocate_plt_for_entry): Likewise.
621
622 2016-04-05 Cupertino Miranda <cmiranda@synopsys.com>
623
624 * elf32-arc.c (elf_arc_check_relocs): Changed
625
626 2016-04-05 Cupertino Miranda <cmiranda@synopsys.com>
627
628 * elf32-arc.c (name_for_global_symbol): Changed assert.
629 (get_replace_function): Created.:
630 (struct arc_relocation_data): Changed to signed types.
631 (defines S, L, P, PDATA): Casted to signed type.
632 (defines SECTSTART, _SDA_BASE_, TLS_REL): Likewise.
633 (PRINT_DEBUG_RELOC_INFO_BEFORE): Changed.
634 (arc_do_relocation): Changed.
635
636 2016-04-05 Cupertino Miranda <cmiranda@synopsys.com>
637
638 * elf32-arc.c (name_for_global_symbol): Added assert to check for
639 symbol index.
640 (elf_arc_relocate_section): Added and changed asserts, validating
641 the synamic symbol index.
642 (elf_arc_finish_dynamic_symbol): Do not fill the dynamic
643 relocation if symbol has dynindx set to -1.
644
645 2016-04-05 Maciej W. Rozycki <macro@imgtec.com>
646
647 * elflink.c (elf_link_add_object_symbols): Always turn hidden
648 and internal symbols which have a dynamic index into local
649 ones.
650
651 2016-04-04 Nick Clifton <nickc@redhat.com>
652
653 PR 19872
654 * dwarf2.c (parse_comp_unit): Skip warning about unrecognised
655 version number if the version is zero.
656
657 2016-04-01 Alan Modra <amodra@gmail.com>
658
659 PR 19886
660 * elflink.c (on_needed_list): Recursively check needed status.
661 (elf_link_add_object_symbols): Adjust.
662
663 2016-03-30 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
664
665 * elf32-avr.c (avr_elf32_load_records_from_section): Free
666 internal_relocs only if they aren't cached.
667
668 2016-03-29 Nick Clifton <nickc@redhat.com>
669
670 PR 17334
671 * elf32-bfin.c (elf32_bfinfdpic_finish_dynamic_sections): Relax
672 assertion on the size of the got section to allow it to be bigger
673 than the number of relocs.
674
675 2016-03-29 Toni Spets <toni.spets@iki.fi>
676
677 PR 19878
678 * coffcode.h (coff_write_object_contents): Revert accidental
679 2014-11-10 change.
680
681 2016-03-22 Alan Modra <amodra@gmail.com>
682
683 PR 19850
684 * dwarf2.c (read_attribute_value): Skip info_ptr check for
685 DW_FORM_flag_present.
686
687 2016-03-22 Nick Clifton <nickc@redhat.com>
688
689 * cpu-v850_rh850.c (arch_info_struct): Restore v850-rh850 as an
690 architecture name for backwards compatibility.
691
692 * peXXigen.c (_bfd_XXi_write_codeview_record): Fix possible
693 unbounded stack use.
694
695 * warning.m4 (GCC_WARN_CFLAGS): Only add -Wstack-usage if using a
696 sufficiently recent version of GCC.
697 * configure: Regenerate.
698
699 2016-03-22 Alan Modra <amodra@gmail.com>
700
701 PR 19851
702 * plugin.c (try_load_plugin): Avoid -Wstack-usage warning.
703
704 2016-03-21 Andrew Burgess <andrew.burgess@embecosm.com>
705
706 * archures.c (bfd_mach_arc_nps400): Define.
707 * bfd-in2.h: Regenerate.
708 * cpu-arc.c (arch_info_struct): New entry for nps400, renumber
709 some existing entries to make space.
710 * elf32-arc.c (arc_elf_object_p): Add nps400 case.
711 (arc_elf_final_write_processing): Likewise.
712
713 2016-03-21 Andrew Burgess <andrew.burgess@embecosm.com>
714
715 * elf32-arc.c (arc_elf_print_private_bfd_data): Remove use of
716 EF_ARC_CPU_GENERIC.
717 (arc_elf_final_write_processing): Don't bother setting cpu field
718 in e_flags, this will have been set elsewhere.
719
720 2016-03-21 Andrew Burgess <andrew.burgess@embecosm.com>
721
722 * elf32-arc.c (arc_elf_final_write_processing): Switch to using
723 EF_ARC_MACH_MSK.
724
725 2016-03-21 Nick Clifton <nickc@redhat.com>
726
727 * warning.m4 (GCC_WARN_CFLAGS): Add -Wstack-usage=262144
728 * configure: Regenerate.
729 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Replace use of
730 alloca with call to xmalloc.
731 * elf32-nds32.c: Likewise.
732 * elf64-hppa.c: Likewise.
733 * elfxx-mips.c: Likewise.
734 * pef.c: Likewise.
735 * pei-x86_64.c: Likewise.
736 * som.c: Likewise.
737 * xsym.c: Likewise.
738
739 2016-03-15 H.J. Lu <hongjiu.lu@intel.com>
740
741 PR ld/19827
742 * elf32-i386.c (elf_i386_check_relocs): Bind defined symbol
743 locally in PIE.
744 (elf_i386_relocate_section): Likewise.
745 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
746 (elf_x86_64_relocate_section): Likewise.
747
748 2016-03-15 H.J. Lu <hongjiu.lu@intel.com>
749
750 PR ld/19807
751 * elf64-x86-64.c (elf_x86_64_relocate_section): Check
752 no_reloc_overflow_check to diable R_X86_64_32/R_X86_64_32S
753 relocation overflow check.
754
755 2016-03-14 H.J. Lu <hongjiu.lu@intel.com>
756
757 * bfd-in2.h: Regenerated.
758
759 2016-03-11 Dan Gissel <dgisselq@ieee.org>
760
761 PR 19713
762 * elf.c (_bfd_elf_section_offset): Ensure that the returned offset
763 uses bytes not octets.
764 * elflink.c (resolve_section): Likewise.
765 Add a bfd parameter.
766 (eval_section): Pass the input_bfd to resolve_section.
767 (bfd_elf_perform_complex_relocation): Convert byte offset to
768 octets before read and writing values.
769 (elf_link_input_bfd): Add byte to octet conversions.
770 (elf_reloc_link_order): Likewise.
771 (elf_fixup_link_order): Likewise.
772 (bfd_elf_final_link): Likewise.
773 * reloc.c (_bfd_final_link_relocate): Likewise.
774 * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
775
776 2016-03-10 Nick Clifton <nickc@redhat.com>
777
778 * config.bfd: Mark the i370 target as obsolete.
779
780 2016-03-09 Pedro Alves <palves@redhat.com>
781
782 * cpu-v850.c (N): Append ":old-gcc-abi" instead of " (using old
783 gcc ABI)" to printable name.
784 * cpu-v850_rh850.c (bfd_v850_rh850_arch): Use "v850:rh850" instead
785 of "v850-rh850" as printable name.
786
787 2016-03-09 Leon Winter <winter-gcc@bfw-online.de>
788
789 PR ld/19623
790 * cofflink.c (_bfd_coff_generic_relocate_section): Do not apply
791 relocations against absolute symbols.
792
793 2016-03-09 Alan Modra <amodra@gmail.com>
794
795 PR binutils/19775
796 * coff-alpha.c (alpha_ecoff_openr_next_archived_file): Allow zero
797 length elements in the archive.
798
799 2016-03-08 H.J. Lu <hongjiu.lu@intel.com>
800
801 PR ld/19789
802 * elflink.c (elf_link_add_object_symbols): Create dynamic sections
803 for -E/--dynamic-list only when not relocatable.
804
805 2016-03-08 H.J. Lu <hongjiu.lu@intel.com>
806
807 PR ld/19784
808 * elf32-i386.c (elf_i386_check_relocs): Increment PLT reference
809 count for locally defined local IFUNC symbols in shared object.
810 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
811
812 2016-03-08 H.J. Lu <hongjiu.lu@intel.com>
813
814 PR ld/19579
815 * elflink.c (_bfd_elf_merge_symbol): Group common symbol checking
816 together.
817
818 2016-03-08 Cupertino Miranda <Cupertino.Miranda@synopsys.com>
819 Andrew Burgess <andrew.burgess@embecosm.com>
820
821 * elf32-arc.c (arc_bfd_get_32): Becomes an alias for bfd_get_32.
822 (arc_bfd_put_32): Becomes an alias for bfd_put_32.
823 (arc_elf_howto_init): Added assert to validate relocations.
824 (get_middle_endian_relocation): Delete.
825 (middle_endian_convert): New function.
826 (ME): Redefine, now does nothing.
827 (IS_ME): New define.
828 (arc_do_relocation): Extend the attached 'ARC_RELOC_HOWTO'
829 definition to call middle_endian_convert. Add a new local
830 variable and make use of this throughout. Added call to
831 arc_bfd_get_8 and arc_bfd_put_8 for 8 bit relocations.
832
833 2016-03-07 Nick Clifton <nickc@redhat.com>
834
835 PR binutils/19775
836 * archive.c (bfd_generic_openr_next_archived_file): Allow zero
837 length elements in the archive.
838
839 2016-03-07 Jiong Wang <jiong.wang@arm.com>
840
841 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Always create .got
842 section if the symbol "_GLOBAL_OFFSET_TABLE_" is referenced.
843
844 2016-03-04 H.J. Lu <hongjiu.lu@intel.com>
845
846 PR ld/19579
847 * elflink.c (_bfd_elf_merge_symbol): Treat common symbol in
848 executable as definition if the new definition comes from a
849 shared library.
850
851 2016-03-02 Alan Modra <amodra@gmail.com>
852
853 * Makefile.in: Regenerate.
854 * po/SRC-POTFILES.in: Regenerate.
855
856 2016-02-29 Cupertino Miranda <cmiranda@synopsys.com>
857
858 * elf32-arc.c (elf_arc_relocate_section): Added rules to fix the
859 relocation addend when sections get merged.
860
861 2016-02-29 Cupertino Miranda <Cupertino.Miranda@synopsys.com>
862
863 * elf32-arc.c (arc_elf_final_write_processing): Add condition to
864 the flag change.
865 (elf_arc_relocate_section): Fixes and conditions to support PIE.
866 Assert for code sections dynamic relocs.
867
868 2016-02-26 Renlin Li <renlin.li@arm.com>
869
870 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Fix signed overflow
871 check for MOVW_SABS_G0, MOVW_SABS_G1, MOVW_SABS_G2.
872
873 2016-02-26 H.J. Lu <hongjiu.lu@intel.com>
874
875 PR ld/19609
876 * elf32-i386.c (elf_i386_convert_load): Convert to R_386_32 for
877 load with locally bound symbols if PIC is false or there is no
878 base register. Optimize branch to 0 if PIC is false.
879 (elf_i386_relocate_section): Don't generate dynamic relocations
880 against undefined weak symbols if PIC is false.
881 * elf64-x86-64.c (elf_x86_64_convert_load): Disable optimization
882 if we can't estimate relocation overflow with --no-relax.
883 Convert to R_X86_64_32S/R_X86_64_32 for load with locally bound
884 symbols if PIC is false. Optimize branch to 0 if PIC is false.
885 (elf_x86_64_relocate_section): Don't generate dynamic relocations
886 against undefined weak symbols if PIC is false.
887
888 2016-02-26 H.J. Lu <hongjiu.lu@intel.com>
889
890 PR ld/19645
891 * bfd.c (bfd): Change flags to 20 bits.
892 (BFD_CONVERT_ELF_COMMON): New.
893 (BFD_USE_ELF_STT_COMMON): Likewise.
894 (BFD_FLAGS_SAVED): Add BFD_CONVERT_ELF_COMMON and
895 BFD_USE_ELF_STT_COMMON.
896 (BFD_FLAGS_FOR_BFD_USE_MASK): Likewise.
897 * configure.ac: Remove --enable-elf-stt-common.
898 * elf.c (swap_out_syms): Choose STT_COMMON or STT_OBJECT for
899 common symbol depending on BFD_CONVERT_ELF_COMMON and
900 BFD_USE_ELF_STT_COMMON.
901 * elfcode.h (elf_slurp_symbol_table): Set BSF_ELF_COMMON for
902 STT_COMMON.
903 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Also check
904 STT_COMMON.
905 (elf_link_convert_common_type): New function.
906 (elf_link_output_extsym): Choose STT_COMMON or STT_OBJECT for
907 common symbol depending on BFD_CONVERT_ELF_COMMON and
908 BFD_USE_ELF_STT_COMMON. Set sym.st_info after sym.st_shndx.
909 * elfxx-target.h (TARGET_BIG_SYM): Add BFD_CONVERT_ELF_COMMON
910 and BFD_USE_ELF_STT_COMMON to object_flags.
911 (TARGET_LITTLE_SYM): Likewise.
912 * syms.c (BSF_KEEP_G): Renamed to ...
913 (BSF_ELF_COMMON): This.
914 * bfd-in2.h: Regenerated.
915 * config.in: Likewise.
916 * configure: Likewise.
917
918 2016-02-26 H.J. Lu <hongjiu.lu@intel.com>
919
920 PR ld/19636
921 PR ld/19704
922 PR ld/19719
923 * elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
924 (elf_i386_link_hash_entry): Add has_got_reloc and
925 has_non_got_reloc.
926 (elf_i386_link_hash_table): Add interp.
927 (elf_i386_link_hash_newfunc): Initialize has_got_reloc and
928 has_non_got_reloc.
929 (elf_i386_copy_indirect_symbol): Copy has_got_reloc and
930 has_non_got_reloc.
931 (elf_i386_check_relocs): Set has_got_reloc and has_non_got_reloc.
932 (elf_i386_fixup_symbol): New function.
933 (elf_i386_pie_finish_undefweak_symbol): Likewise.
934 (elf_i386_allocate_dynrelocs): Don't allocate space for dynamic
935 relocations and discard relocations against resolved undefined
936 weak symbols in executable. Don't make resolved undefined weak
937 symbols in executable dynamic. Keep dynamic non-GOT/non-PLT
938 relocation against undefined weak symbols in PIE.
939 (elf_i386_size_dynamic_sections): Set interp to .interp section.
940 (elf_i386_relocate_section): Don't generate dynamic relocations
941 against resolved undefined weak symbols in PIE, except for
942 R_386_PC32.
943 (elf_i386_finish_dynamic_symbol): Keep PLT/GOT entries without
944 dynamic PLT/GOT relocations for resolved undefined weak symbols.
945 Don't generate dynamic relocation against resolved undefined weak
946 symbol in executable.
947 (elf_i386_finish_dynamic_sections): Call
948 elf_i386_pie_finish_undefweak_symbol on all symbols in PIE.
949 (elf_backend_fixup_symbol): New.
950 * elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
951 (elf_x86_64_link_hash_entry): Add has_got_reloc and
952 has_non_got_reloc.
953 (elf_x86_64_link_hash_table): Add interp.
954 (elf_x86_64_link_hash_newfunc): Initialize has_got_reloc and
955 has_non_got_reloc.
956 (elf_x86_64_copy_indirect_symbol): Copy has_got_reloc and
957 has_non_got_reloc.
958 (elf_x86_64_check_relocs): Set has_got_reloc and
959 has_non_got_reloc.
960 (elf_x86_64_fixup_symbol): New function.
961 (elf_x86_64_pie_finish_undefweak_symbol): Likewise.
962 (elf_x86_64_allocate_dynrelocs): Don't allocate space for dynamic
963 relocations and discard relocations against resolved undefined
964 weak symbols in executable. Don't make resolved undefined weak
965 symbols in executable dynamic.
966 (elf_x86_64_size_dynamic_sections): Set interp to .interp section.
967 (elf_x86_64_relocate_section): Check relocation overflow for
968 dynamic relocations against unresolved weak undefined symbols.
969 Don't generate dynamic relocations against resolved weak
970 undefined symbols in PIE.
971 (elf_x86_64_finish_dynamic_symbol): Keep PLT/GOT entries without
972 dynamic PLT/GOT relocations for resolved undefined weak symbols.
973 Don't generate dynamic relocation against resolved undefined weak
974 symbol in executable.
975 (elf_x86_64_finish_dynamic_sections): Call
976 elf_x86_64_pie_finish_undefweak_symbol on all symbols in PIE.
977 (elf_backend_fixup_symbol): New.
978
979 2016-02-26 Alan Modra <amodra@gmail.com>
980
981 * elf64-ppc.c (create_linkage_sections): Create sfpr when
982 save_restore_funcs, rest of sections when not relocatable.
983 (ppc64_elf_init_stub_bfd): Always call create_linkage_sections.
984 (sfpr_define): Define all symbols on emitted code.
985 (ppc64_elf_func_desc_adjust): Adjust for sfpr now being created
986 when relocatable. Move sfpr_define loop earlier.
987
988 2016-02-24 H.J. Lu <hongjiu.lu@intel.com>
989
990 * elf64-x86-64.c (elf_x86_64_need_pic): New function.
991 (elf_x86_64_relocate_section): Use it. Replace
992 x86_64_elf_howto_table[r_type] with howto.
993
994 2016-02-24 H.J. Lu <hongjiu.lu@intel.com>
995
996 PR ld/19698
997 * elflink.c (bfd_elf_record_link_assignment): Set versioned if
998 symbol version is unknown.
999
1000 2016-02-24 H.J. Lu <hongjiu.lu@intel.com>
1001
1002 * elf32-i386.c (elf_i386_allocate_dynrelocs): Set plt_got.offset
1003 to (bfd_vma) -1 when setting needs_plt to 0.
1004 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewise.
1005
1006 2016-02-23 H.J. Lu <hongjiu.lu@intel.com>
1007
1008 * elflink.c (bfd_elf_record_link_assignment): Check for shared
1009 library, instead of PIC, and don't check PDE when making linker
1010 assigned symbol dynamic.
1011
1012 2016-02-23 Faraz Shahbazker <faraz.shahbazker@imgtec.com>
1013
1014 * bfd/elfxx-mips.c (_bfd_mips_post_process_headers): Increment
1015 ABIVERSION for non-executable stack.
1016
1017 2016-02-23 Rich Felker <bugdal@aerifal.cx>
1018
1019 PR target/19516
1020 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol):
1021 Always produce a RELATIVE reloc for a local symbol.
1022
1023 2016-02-23 Hans-Peter Nilsson <hp@axis.com>
1024
1025 Fix test-case ld-elf/pr19617b
1026 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
1027 discard unused non-function symbols when --dynamic-list-data.
1028
1029 2016-02-22 H.J. Lu <hongjiu.lu@intel.com>
1030
1031 * elflink.c (_bfd_elf_link_renumber_dynsyms): Always create the
1032 dynsym section, even if it is empty, with dynamic sections.
1033
1034 2016-02-22 H.J. Lu <hongjiu.lu@intel.com>
1035
1036 * syms.c: Remove BSF_COMMON from comments.
1037 * bfd-in2.h: Regenerated.
1038
1039 2016-02-22 Jiong Wang <jiong.wang@arm.com>
1040
1041 * elfnn-aarch64. (aarch64_type_of_stub): Remove redundation calcuation
1042 for destination. Remove useless function parameters.
1043 (elfNN_aarch64_size_stubs): Update parameters for aarch64_type_of_stub.
1044
1045 2016-02-19 Nick Clifton <nickc@redhat.com>
1046
1047 PR ld/19629
1048 * aoutx.h (aout_link_add_symbols): Check for out of range string
1049 table offsets.
1050
1051 PR ld/19628
1052 * reloc.c (bfd_generic_get_relocated_section_contents): Stop
1053 processing if we encounter a reloc without an associated symbol.
1054
1055 2016-02-18 H.J. Lu <hongjiu.lu@intel.com>
1056
1057 PR ld/19617
1058 * elflink.c (elf_link_add_object_symbols): Always create dynamic
1059 sections for -E/--dynamic-list.
1060
1061 2016-02-17 H.J. Lu <hongjiu.lu@intel.com>
1062
1063 * elf64-x86-64.c (elf_backend_omit_section_dynsym): New. Defined
1064 to bfd_true.
1065
1066 2016-02-16 Joseph Myers <joseph@codesourcery.com>
1067
1068 * plugin.c (plugin_vec): Set match priority to 255.
1069 * format.c (bfd_check_format_matches) [BFD_SUPPORTS_PLUGINS]: When
1070 matching against the plugin vector, take priority from there not
1071 from TEMP.
1072
1073 2016-02-15 Nick Clifton <nickc@redhat.com>
1074
1075 * elf-bfd.h (struct bfd_elf_special_section): Use unsigned values
1076 for length and type fields. Use a signed value for the
1077 suffix_length field.
1078
1079 2016-02-10 H.J. Lu <hongjiu.lu@intel.com>
1080
1081 PR ld/19601
1082 * elf32-i386.c (elf_i386_relocate_section): Mask off the least
1083 significant bit in GOT offset for R_386_GOT32X.
1084
1085 2016-02-10 Nick Clifton <nickc@redhat.com>
1086
1087 PR 19405
1088 * elf32-nios2.c (nios2_elf32_install_imm16): Allow for signed
1089 immediate values.
1090 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Limit the
1091 number of messages about FDE encoding preventing .eh_frame_hdr
1092 generation.
1093
1094 2016-02-09 Nick Clifton <nickc@redhat.com>
1095
1096 * oasys.c (oasys_archive_p): Fix indentation.
1097 * elf32-nds32.c (nds32_elf_relax_section): Use an unsigned
1098 constant for left shifting.
1099
1100 * elfnn-aarch64.c (elfNN_aarch64_relocate_section): Add a more
1101 helpful warning message to explain why certain AArch64 relocs
1102 might overflow.
1103
1104 2016-02-05 Simon Marchi <simon.marchi@ericsson.com>
1105
1106 * pe-mips.c (coff_mips_reloc): Fix formatting.
1107
1108 2016-02-05 Cupertino Miranda <Cupertino.Miranda@synopsys.com>
1109
1110 * cpu-arc.c: Change default archure from bfd_mach_arc_arcv2
1111 to bfd_mach_arc_arc600.
1112
1113 2016-02-04 Alan Modra <amodra@gmail.com>
1114
1115 * elf64-ppc.c (ppc64_elf_relocate_section): Adjust last patch
1116 for big-endian.
1117
1118 2016-02-02 H.J. Lu <hongjiu.lu@intel.com>
1119
1120 PR ld/19542
1121 * elf64-x86-64.c (elf_x86_64_convert_load): Store the estimated
1122 distances in the compressed_size field of the output section.
1123
1124 2016-02-02 Alan Modra <amodra@gmail.com>
1125
1126 * elf64-ppc.c (ppc64_elf_relocate_section): Further restrict
1127 ELFv2 entry optimization.
1128
1129 2016-02-02 H.J. Lu <hongjiu.lu@intel.com>
1130
1131 PR binutils/19547
1132 * elf.c (assign_section_numbers): Clear HAS_RELOC if there are
1133 no relocations in relocatable files.
1134
1135 2016-02-01 H.J. Lu <hongjiu.lu@intel.com>
1136
1137 PR ld/19553
1138 * elflink.c (elf_link_add_object_symbols): Don't add DT_NEEDED
1139 if a symbol from a library loaded via DT_NEEDED doesn't match
1140 the symbol referenced by regular object.
1141
1142 2016-02-01 Nathaniel Smith <njs@pobox.com>
1143
1144 * peicode.h (pe_ILF_build_a_bfd): Create an import symbol for both
1145 CODE and DATA.
1146
1147 2016-02-01 Alan Modra <amodra@gmail.com>
1148
1149 * elf64-x86-64.c (elf_x86_64_get_plt_sym_val): Don't abort on
1150 an out of range reloc_index.
1151 * elf32-i386.c (elf_i386_get_plt_sym_val): Likewise.
1152
1153 2016-02-01 Kamil Rytarowski <n54@gmx.com>
1154
1155 * Makefile.am (OPTIONAL_BACKENDS): Add netbsd-core.lo.
1156 (OPTIONAL_BACKENDS_CFILES): Add netbsd-core.c.
1157 * Makefile.in: Regenerated.
1158
1159 2016-02-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1160
1161 * elf64-s390.c (elf_s390_reloc_name_lookup): Fix indentation.
1162
1163 2016-01-31 John David Anglin <danglin@gcc.gnu.org>
1164
1165 PR ld/19526
1166 * elf32-hppa.c (elf32_hppa_final_link): Don't sort non-regular output
1167 files.
1168 * elf64-hppa.c (elf32_hppa_final_link): Likewise. Remove retval.
1169
1170 2016-01-30 H.J. Lu <hongjiu.lu@intel.com>
1171
1172 PR ld/19539
1173 * elf32-i386.c (elf_i386_reloc_type_class): Check relocation
1174 against STT_GNU_IFUNC symbol only with dynamic symbols.
1175 * elf64-x86-64.c (elf_x86_64_reloc_type_class): Likewise.
1176
1177 2016-01-28 H.J. Lu <hongjiu.lu@intel.com>
1178
1179 PR binutils/19523
1180 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Set BFD_DECOMPRESS to
1181 decompress debug sections.
1182
1183 2016-01-25 Maciej W. Rozycki <macro@imgtec.com>
1184
1185 * elf32-arc.c (elf_arc_finish_dynamic_symbol): Rename `index' to
1186 `dynindx'.
1187
1188 2016-01-25 Nick Clifton <nickc@redhat.com>
1189
1190 PR target/19435
1191 * mach-o.c (bfd_mach_o_close_and_cleanup): Suppress code to free
1192 dsym filename buffer.
1193
1194 2016-01-24 Maciej W. Rozycki <macro@imgtec.com>
1195
1196 * elfxx-mips.c (BZ16_REG_FIELD): Simplify calculation.
1197
1198 2016-01-24 Maciej W. Rozycki <macro@imgtec.com>
1199
1200 * elfxx-mips.c (BZ16_REG): Correct calculation.
1201
1202 2016-01-21 Nick Clifton <nickc@redhat.com>
1203
1204 * elf32-arc.c (ADD_RELA): Fix compile time warning errors by
1205 changing the type of _loc to be bfd_byte *.
1206 (elf_arc_finish_dynamic_symbol): Likewise.
1207
1208 2016-01-21 Nick Clifton <nickc@redhat.com>
1209
1210 PR ld/19455
1211 * elf32-arm.c (elf32_arm_create_dynamic_sections): Set the ELF
1212 class of the linker stub bfd.
1213 (elf32_arm_check_relocs): Skip check for pic format after
1214 processing a vxWorks R_ARM_ABS12 reloc.
1215 * elflink.c (bfd_elf_final_link): Check for ELFCLASSNONE when
1216 reporting a class mismatch.
1217
1218 2016-01-21 Jiong Wang <jiong.wang@arm.com>
1219
1220 * elfnn-aarch64.c (aarch64_type_of_stub): Allow insert long branch
1221 veneer for sym_sec != input_sec.
1222 (elfNN_aarch64_size_stub): Support STT_SECTION symbol.
1223 (elfNN_aarch64_final_link_relocate): Take rela addend into account when
1224 calculation destination.
1225
1226 2016-01-21 Alan Modra <amodra@gmail.com>
1227
1228 * elf-linux-core.h (swap_linux_prpsinfo32_out): New function.
1229 (swap_linux_prpsinfo64_out): New function.
1230 (LINUX_PRPSINFO32_SWAP_FIELDS): Delete.
1231 (LINUX_PRPSINFO64_SWAP_FIELDS): Delete.
1232 * elf.c (elfcore_write_linux_prpsinfo32): Adjust. Don't memset.
1233 (elfcore_write_linux_prpsinfo64): Likewise.
1234 * elf32-ppc.c (swap_ppc_linux_prpsinfo32_out): New function.
1235 (PPC_LINUX_PRPSINFO32_SWAP_FIELDS): Delete.
1236 (elfcore_write_ppc_linux_prpsinfo32): Adjust. Don't memset.
1237
1238 2016-01-21 Alan Modra <amodra@gmail.com>
1239
1240 * elf-linux-core.h: Rename from elf-linux-psinfo.h.
1241 * elf.c: Adjust #include.
1242 * elf32-ppc.c: Don't #include elf-linux-psinfo.h
1243 * Makefile.am (SOURCE_HFILES): Update.
1244 * Makefile.in: Regenerate.
1245 * po/SRC-PORFILES.in: Regenerate.
1246
1247 2016-01-21 Alan Modra <amodra@gmail.com>
1248
1249 * configure.ac: Move corefile selection later in file. Move
1250 tdefaults code immediately after other target vector code.
1251 * configure: Regenerate.
1252
1253 2016-01-20 Mickael Guene <mickael.guene@st.com>
1254
1255 * elf32-arm.c (elf32_arm_special_sections): Remove catch of noread
1256 section using '.text.noread' pattern.
1257
1258 2016-01-19 John Baldwin <jhb@FreeBSD.org>
1259
1260 * elf.c (elfcore_grok_note): Recognize NT_FREEBSD_THRMISC notes.
1261
1262 2016-01-18 Miranda Cupertino <Cupertino.Miranda@synopsys.com>
1263 Zissulescu Claudiu <Claudiu.Zissulescu@synopsys.com>
1264
1265 * arc-plt.def: New file.
1266 * arc-plt.h: Likewise.
1267 * elf32-arc.c (elf_arc_abs_plt0_entry, elf_arc_abs_pltn_entry,
1268 elf_arcV2_abs_plt0_entry, elf_arcV2_abs_pltn_entry,
1269 elf_arc_pic_plt0_entry, elf_arc_pic_pltn_entry,
1270 elf_arcV2_pic_plt0_entry, elf_arcV2_pic_pltn_entry): Remove.
1271 (name_for_global_symbol): Added.
1272 (ADD_RELA): Helper to create dynamic relocs.
1273 (new_got_entry_to_list): Create a new got entry in linked list.
1274 (symbol_has_entry_of_type): Search for specific type of entry in
1275 list.
1276 (is_reloc_for_GOT): return FALSE for any TLS related relocs.
1277 (is_reloc_for_TLS, arc_elf_set_private_flags)
1278 (arc_elf_print_private_bfd_data, arc_elf_copy_private_bfd_data)
1279 (arc_elf_merge_private_bfd_data): New functions.
1280 (debug_arc_reloc): Cleaned debug info printing.
1281 (PDATA reloc): Changed not to perform address alignment.
1282 (reverse_me): Added. Fix for ARC_32 relocs.
1283 (arc_do_relocation): Return bfd_reloc_of when no relocation should
1284 occur.
1285 (arc_get_local_got_ents): Renamed from arc_get_local_got_offsets.
1286 Changed function to access an array of list of GOT entries instead
1287 of just an array of offsets.
1288 (elf_arc_relocate_section): Added support for PIC and TLS related relocations.
1289 (elf_arc_check_relocs): Likewise.
1290 (elf_arc_adjust_dynamic_symbol, elf_arc_finish_dynamic_symbol,
1291 (elf_arc_finish_dynamic_sections): Likewise
1292 (arc_create_dynamic_sections): Modified conditions to create
1293 dynamic sections.
1294 (ADD_SYMBOL_REF_SEC_AND_RELOC): New macro.
1295 (plt_do_relocs_for_symbol, relocate_plt_for_symbol)
1296 (relocate_plt_for_entry): Changed to support new way to define PLT
1297 related code.
1298 (add_symbol_to_plt): Likewise.
1299 (arc_elf_link_hash_table_create): New function.
1300
1301 2016-01-18 Nick Clifton <nickc@redhat.com>
1302
1303 PR ld/19440
1304 * coff-rs6000.c (_bfd_xcoff_swap_sym_in): Sign extend external
1305 section number into internal section number.
1306 * coff64-rs6000.c (_bfd_xcoff64_swap_sym_in): Likewise.
1307 * coffswap.h (coff_swap_sym_in): Likewise.
1308 * peXXigen.c (_bfd_XXi_swap_sym_in): Likewise.
1309 * coffcode.h (_coff_bigobj_swap_sym_in): Make sure that internal
1310 section number field is big enough to hold the external value.
1311
1312 2016-01-17 Alan Modra <amodra@gmail.com>
1313
1314 * configure: Regenerate.
1315
1316 2016-01-12 Yury Usishchev <y.usishchev@samsung.com>
1317
1318 * elf32-arm.c (elf32_arm_fix_exidx_coverage): Insert cantunwind
1319 when address in first unwind entry does not match start of
1320 section.
1321
1322 2016-01-08 Richard Sandiford <richard.sandiford@arm.com>
1323 Jiong Wang <jiong.wang@arm.com>
1324
1325 PR ld/19368
1326 * elf32-arm.c (elf32_arm_reloc_type_class): Map R_ARM_IRELATIVE to
1327 reloc_class_ifunc.
1328
1329 2016-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
1330
1331 * elf32-arc.c (reloc_type_to_name): Change ARC_RELOC_HOWTO to
1332 place 'R_' before the reloc name returned.
1333 (elf_arc_howto_table): Change ARC_RELOC_HOWTO to place 'R_' before
1334 the relocation string.
1335
1336 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1337
1338 * elfxx-mips.c (mips_elf_merge_obj_abiflags): New function,
1339 factored out from...
1340 (_bfd_mips_elf_merge_private_bfd_data): ... here.
1341
1342 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1343
1344 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Move
1345 attribute check after ELF file header flag check.
1346
1347 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1348
1349 * elfxx-mips.c (mips_elf_merge_obj_attributes): Propagate the
1350 return status from `_bfd_elf_merge_object_attributes'.
1351
1352 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1353
1354 * elfxx-mips.c (mips_elf_merge_obj_e_flags): New function,
1355 factored out from...
1356 (_bfd_mips_elf_merge_private_bfd_data): ... here.
1357
1358 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1359
1360 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Fold the
1361 handling of input MIPS ABI flags together.
1362
1363 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1364
1365 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Suppress
1366 attribute checks for null input.
1367
1368 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1369
1370 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Use local
1371 pointers to target data.
1372
1373 2016-01-04 Maciej W. Rozycki <macro@imgtec.com>
1374
1375 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Correct
1376 an FP ABI warning.
1377
1378 2016-01-01 Alan Modra <amodra@gmail.com>
1379
1380 Update year range in copyright notice of all files.
1381
1382 For older changes see ChangeLog-2015 and doc/ChangeLog-0415
1383 \f
1384 Copyright (C) 2016 Free Software Foundation, Inc.
1385
1386 Copying and distribution of this file, with or without modification,
1387 are permitted in any medium without royalty provided the copyright
1388 notice and this notice are preserved.
1389
1390 Local Variables:
1391 mode: change-log
1392 left-margin: 8
1393 fill-column: 74
1394 version-control: never
1395 End:
This page took 0.057934 seconds and 4 git commands to generate.