* elflink.c (_bfd_elf_merge_symbol): Use local var holding value
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
6c9b78e6
AM
12013-03-25 Alan Modra <amodra@gmail.com>
2
3 * elflink.c (_bfd_elf_merge_symbol): Use local var holding value
4 of *sym_hash.
5
191c0c42
AM
62013-03-25 Alan Modra <amodra@gmail.com>
7
8 * elflink.c (_bfd_elf_merge_symbol): Don't discard TLS symbols here.
9 Wrap long lines.
10 (elf_link_add_object_symbols): Discard TLS symbols for --just-syms
11 early in symbol loop.
12
5d13b3b3
AM
132013-03-25 Alan Modra <amodra@gmail.com>
14
15 * elf-bfd.h (struct elf_backend_data <merge_symbol>): Update proto.
16 (_bfd_elf_init_reloc_shdr): Delete.
17 * elf.c (_bfd_elf_init_reloc_shdr): Make static.
18 * elf64-x86-64.c (elf_x86_64_merge_symbol): Trim parameters to
19 just what is needed.
20 * elflink.c (_bfd_elf_merge_symbol): Update bed->merge_symbol call.
21
8a56bd02
AM
222013-03-23 Alan Modra <amodra@gmail.com>
23
24 * elf-bfd.h (_bfd_elf_merge_symbol): Delete declaration.
25 * elflink.c (_bfd_elf_merge_symbol): Make static.
26 * elf32-sh-symbian.c (sh_symbian_relocate_section): Don't call
27 _bfd_elf_merge_symbol, call _bfd_generic_link_add_one_symbol.
28
96f29d96
AM
292013-03-23 Alan Modra <amodra@gmail.com>
30
31 PR ld/15270
32 * elflink.c (elf_link_add_object_symbols): Don't set def_regular
33 or ref_regular for BFD_PLUGIN owned syms, or have them affect
34 def_dynamic/ref_dynamic.
35 (_bfd_elf_fix_symbol_flags): Don't set def_regular for BFD_PLUGIN
36 owned syms.
37
209be8d2
DM
382013-03-22 David S. Miller <davem@davemloft.net>
39
40 * elfxx-sparc.c (_bfd_sparc_elf_merge_private_bfd_data): Set type of
41 hwcaps attribute.
42
5c0df484
NC
432013-03-22 Achille Fouilleul <achille.fouilleul+binutils@gadz.org>
44
45 PR ld/14902
46 * elf32-h8300.c (elf32_h8_relax_delete_bytes): Fix off by one
47 errors adjusting relocs and symbols.
48
81f5558e
NC
492013-03-21 Michael Schewe <michael.schewe@gmx.net>
50
51 * elf32-h8300 (h8_relax_section): Add new relaxation of mov
52 @(disp:32,ERx) to mov @(disp:16,ERx).
53 (R_H8_DISP32A16): New reloc.
54 Comments added and corrected.
55 * reloc.c (BFD_RELOC_H8_DISP32A16): New reloc.
56 * bfd-in2.h: Regenerate.
57 * libbfd.h: Regenerate.
58
ce63b7b3
KT
592013-03-21 Kai Tietz <ktietz@redhat.com>
60
61 * coffgen.c (coff_real_object_p): Make global.
62 * peicode.h (coff_real_object_p): Add prototype.
63 (FILHDR): Defined for COFF_IMAGE_WITH_PE as
64 external_PEI_IMAGE_hdr structure.
65 (coff_swap_filehdr_in): Handle variable header-size.
66 * peXXigen.c (_bfd_XXi_swap_aouthdr_in): Just handle amount
67 of directory-entiries as specified in pe-header.
68
088ca6c1
NC
692013-03-21 Nick Clifton <nickc@redhat.com>
70
71 PR sim/15286
72 * elf32-arm.c (bfd_arm_get_mach_from_attributes): Identify XScale,
73 iWMMXt and iWMMXt2 processors from attributes.
74
8877b5e5
AM
752013-03-20 Alan Modra <amodra@gmail.com>
76
77 * elflink.c (_bfd_elf_make_dynamic_reloc_section): Override
78 sh_type according to is_rela.
79
ffa9430d
AM
802013-03-18 Alan Modra <amodra@gmail.com>
81
82 PR ld/12549
83 * elflink.c (elf_link_add_object_symbols): Exclude weak refs when
84 considering whether an --as-needed library is needed.
85
cc0ea93c
TT
862013-03-14 Tom Tromey <tromey@redhat.com>
87
88 * opncls.c (bfd_get_debug_link_info): Rename from
89 get_debug_link_info. Export. Update comment.
90 (find_separate_debug_file): Update.
91 * bfd-in2.h: Rebuild.
92
59c108f7
NC
932013-03-08 Venkataramanan Kumar <venkataramanan.kumar@linaro.org>
94
95 * elf64-aarch64.c (elf_backend_can_gc_sections): Enable gc-section
96 support.
97 (elf64_aarch64_gc_sweep_hook): Handle GOT, TLS and PLT related
98 relocs.
99
abb3f6cc
NC
1002013-03-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
101
102 * elf-bfd.h (elfcore_write_s390_tdb): Add prototype.
103 * elf.c (elfcore_write_s390_tdb): New function.
104 (elfcore_write_register_note): Call it.
105 (elfcore_grok_s390_tdb): New function.
106 (elfcore_grok_note): Call it.
107
af924177
MR
1082013-03-08 Maciej W. Rozycki <macro@codesourcery.com>
109
110 * elfxx-mips.c (mips_elf_allocate_lazy_stub): Correct data type.
111
48385e38
CV
1122013-03-05 Corinna Vinschen <vinschen@redhat.com>
113
114 * config.bfd: Add x86_64-*-cygwin to list of supported targets.
115
f75e0e33
AM
1162013-03-04 Alan Modra <amodra@gmail.com>
117
118 * elf32-ppc.c (ppc_elf_relocate_section <R_PPC_PLTREL24>): Adjust
119 non-zero addends when relocatable, rather than addends >= 32768.
120 Always zero "addend" before applying relocation.
121
17e3916e
NC
1222013-03-04 Nick Clifton <nickc@redhat.com>
123
124 * archive64.c (bfd_elf64_archive_write_armap): Fix calculation of
125 file pointer offsets for thin archives.
126
3064e1ff
JB
1272013-02-28 Nathan Sidwell <nathan@codesourcery.com>
128
129 * elf32-arm.c (elf32_arm_size_dynamic_sections): Don't call
130 elf32_arm_allocate_dynrelocs for source reloc for non-dynamic link.
131
4107ae22
DD
1322013-02-27 DJ Delorie <dj@redhat.com>
133
134 * reloc.c (BFD_RELOC_RL78_CODE): Add.
135 * libbfd.h: Regenerate.
136 * bfd-in2.h: Regenerate.
137 * elf32-rl78.c (rl78_elf_relocate_section): Handle weak code
138 references in compuated relocs.
139
730fbaf8
AG
1402013-02-26 Anthony Green <green@moxielogic.com>
141
142 * config.bfd: Extend moxie-rtems target triplet name support.
143
35399224
L
1442013-02-21 H.J. Lu <hongjiu.lu@intel.com>
145
146 PR ld/15167
147 * elf64-ia64-vms.c (elf64_vms_link_add_object_symbols): Set
148 unique_global only for definition.
149 * elflink.c (_bfd_elf_merge_symbol): Don't set unique_global
150 here.
151 (elf_link_add_object_symbols): Set unique_global only
152 for definition.
153
c0355132
AM
1542013-02-21 Alan Modra <amodra@gmail.com>
155
156 * elf-bfd.h (struct elf_build_id): Extracted from..
157 (struct elf_build_id_info): ..here. Delete.
158 (struct output_elf_obj_tdata): New, extracted from..
159 (struct elf_obj_tdata): ..here. Reorganize for better packing.
160 Add "o" field.
161 (elf_program_header_size): Reference tdata->o.
162 (elf_seg_map, elf_next_file_pos, elf_eh_frame_hdr, elf_linker,
163 elf_stack_flags, elf_shstrtab, elf_strtab_sec, elf_shstrtab_sec,
164 elf_section_syms, elf_num_section_syms, elf_flags_init): Likewise.
165 * elf.c (bfd_elf_allocate_object): Allocate output_elf_obj_tdata
166 when opening bfd in any mode that might write.
167 (_bfd_elf_write_object_contents): Use build_id field in
168 output_elf_obj_tdata.
169 (_bfd_elf_close_and_cleanup): Tweak elf_shstrtab test.
170 (elfobj_grok_gnu_build_id): Adjust for elf_tdata changes.
171
228e534f
AM
1722013-02-21 Alan Modra <amodra@gmail.com>
173
174 * elf-bfd.h (struct core_elf_obj_tdata): New.
175 (struct elf_obj_tdata): Delete core_signal, core_pid, core_lwpid,
176 core_program, and core_command. Add "core".
177 * elf.c (bfd_elf_mkcorefile): Allocate "core" struct.
178 Update all refs to tdata core fields.
179 * elf32-am33lin.c, * elf32-arm.c, * elf32-cris.c, * elf32-frv.c,
180 * elf32-hppa.c, * elf32-i386.c, * elf32-m68k.c, * elf32-mips.c,
181 * elf32-nios2.c, * elf32-ppc.c, * elf32-s390.c, * elf32-score.c,
182 * elf32-score7.c, * elf32-sh.c, * elf32-sparc.c, * elf32-tilegx.c,
183 * elf32-tilepro.c, * elf32-xtensa.c, * elf64-aarch64.c,
184 * elf64-hppa.c, * elf64-mips.c, * elf64-ppc.c, * elf64-tilegx.c,
185 * elf64-x86-64.c, * elfcore.h, * elfn32-mips.c: Update all refs
186 to tdata core fields.
187
12bd6957
AM
1882013-02-21 Alan Modra <amodra@gmail.com>
189
190 * elf-bfd.h (struct elf_obj_tdata): Rename segment_map to seg_map.
191 Delete num_locals and num_globals.
192 (elf_num_locals, elf_num_globals): Don't define.
193 (elf_seg_map, elf_next_file_pos, elf_eh_frame_hdr, elf_linker,
194 elf_stack_flags, elf_strtab_sec, elf_shstrtab_sec): Define.
195 * bfd.c, * elf-eh-frame.c, * elf-nacl.c, * elf-vxworks.c, * elf.c,
196 * elf32-arm.c, * elf32-lm32.c, * elf32-ppc.c, * elf32-rx.c,
197 * elf32-spu.c, * elf64-hppa.c, * elfcode.h, * elflink.c,
198 * elfnn-ia64.c, * elfxx-mips.c: Use newly defined elf_obj_tdata
199 accessor macros.
200 * elf.c (elf_map_symbols): Add pnum_locals param. Return
201 number of locals syms via new param.
202 (swap_out_syms): Adjust to suit elf_map_symbols change.
203
cbf8d970
MR
2042013-02-19 Maciej W. Rozycki <macro@codesourcery.com>
205
206 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Also clear
207 STO_MICROMIPS annotation.
208
30e8ee25
AM
2092013-02-19 Alan Modra <amodra@gmail.com>
210
211 * configure.in: Bump version to 2.23.52.
212 * elf-bfd.h (struct elf_build_id_info): New.
213 (struct elf_obj_tdata): Delete after_write_object_contents,
214 after_write_object_contents_info and build_id_size. Make build_id
215 a pointer to struct elf_build_id_info.
216 * elf.c (_bfd_elf_write_object_contents): Style. Update
217 after_write_ibject_contents invocation.
218 (elfobj_grok_gnu_build_id): Update for new build_id struct. Don't
219 allow zero size notes.
220 * configure: Regenerate.
221
5b175e56
MR
2222013-02-18 Maciej W. Rozycki <macro@codesourcery.com>
223
224 * elf64-mips.c (micromips_elf64_howto_table_rel): Add
225 R_MICROMIPS_SCN_DISP and R_MICROMIPS_JALR.
226 (micromips_elf64_howto_table_rela): Likewise.
227 (micromips_reloc_map): Add BFD_RELOC_MICROMIPS_JALR.
228 * elfn32-mips.c (elf_micromips_howto_table_rel): Add
229 R_MICROMIPS_SCN_DISP and R_MICROMIPS_JALR.
230 (elf_micromips_howto_table_rela): Likewise.
231 (micromips_reloc_map): Add BFD_RELOC_MICROMIPS_JALR.
232
e8faf7d1
MR
2332013-02-18 Paul Brook <paul@codesourcery.com>
234
235 * elfxx-mips.c (MICROMIPS_P): New macro.
236 (_bfd_mips_elf_symbol_processing): Use it.
237
c164a95d
MR
2382013-02-18 Maciej W. Rozycki <macro@codesourcery.com>
239
240 * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Clarify
241 comment on _PROCEDURE_LINKAGE_TABLE_ creation.
242
d45f8bda
AM
2432013-02-18 Alan Modra <amodra@gmail.com>
244
245 PR ld/12549
246 * elf-bfd.h (_bfd_elf_strtab_clear_refs): Delete.
247 (_bfd_elf_strtab_clear_all_refs): Declare.
248 (_bfd_elf_strtab_resize): Declare.
249 * elf-strtab.c (_bfd_elf_strtab_clear_refs): Delete.
250 (_bfd_elf_strtab_clear_all_refs): New function.
251 (_bfd_elf_strtab_resize): Likewise.
252 * elflink.c (elf_link_add_object_symbols): Use _bfd_elf_strtab_resize.
253
698600e4
AM
2542013-02-18 Alan Modra <amodra@gmail.com>
255
256 * elf-bfd.h (struct elf_obj_tdata): Move find_line_info, local_stubs,
257 local_call_stubs, elf_data_symbol, elf_text_symbol, elf_data_section,
258 and elf_text_section to..
259 * elfxx-mips.c (struct mips_elf_obj_tdata): ..here. Update all refs.
260 * elf64-alpha.c (struct mips_elf_find_line): Rename to..
261 (struct alpha_elf_find_line): ..this.
262 (struct alpha_elf_obj_tdata): Add find_line_info, update refs.
263
3d5bef4c
L
2642013-02-16 H.J. Lu <hongjiu.lu@intel.com>
265
266 PR ld/15146
267 * elflink.c (elf_link_add_object_symbols): Don't add DT_NEEDED
268 for references from the dummy bfd.
269
313ed4a9
L
2702013-02-16 H.J. Lu <hongjiu.lu@intel.com>
271
272 PR ld/15149
273 * elflink.c (elf_link_add_object_symbols): Also track weak
274 references.
275
989fbeff
L
2762013-02-15 H.J. Lu <hongjiu.lu@intel.com>
277
278 PR binutils/15151
279 * archive.c (_bfd_find_nested_archive): Don't allow a nested
280 archive pointing to itself.
281 (_bfd_get_elt_at_filepos): Revert the last 2 changes.
282
a043396b
NC
2832013-02-15 Nick Clifton <nickc@redhat.com>
284
285 PR binutils/15140
286 * archive.c (_bfd_get_elt_at_filepos): Prevent an infinite loop
287 accessing a corrupt nested archive.
288
13db6b44
RS
2892013-02-13 Richard Sandiford <rdsandiford@googlemail.com>
290
291 * elfxx-mips.c (mips_got_page_ref): New structure.
292 (mips_got_page_entry): Use a section rather than a (bfd, symndx)
293 pair to represent the anchor point.
294 (mips_got_info): Add a got_page_refs field.
295 (mips_elf_link_hash_table): Add a sym_cache field.
296 (mips_got_page_ref_hash, mips_got_page_ref_eq): New functions.
297 (mips_got_page_entry_hash, mips_got_page_entry_eq): Update for
298 new anchor representation.
299 (mips_elf_create_got_info): Create got_page_refs rather than
300 got_page_entries.
301 (mips_elf_record_got_page_ref): New function.
302 (mips_elf_pages_for_range): Move further down file.
303 (mips_elf_record_got_page_entry): Likewise. Take a got as argument.
304 Use a section rather than a (bfd, symndx) pair to represent the
305 anchor point.
306 (mips_elf_resolve_got_page_ref): New function.
307 (mips_elf_resolve_final_got_entries): Use it to populate
308 got_page_entries.
309 (_bfd_mips_elf_check_relocs): Call mips_elf_record_got_page_ref
310 rather than mips_elf_record_got_page_entry. Only nullify h
311 afterwards.
312 (mips_elf_lay_out_got): Call mips_elf_resolve_final_got_entries
313 earlier.
314
57093f5e
RS
3152013-02-12 Richard Sandiford <rdsandiford@googlemail.com>
316
317 * elfxx-mips.c (mips_elf_lay_out_got): Count VxWorks GOT relocs
318 in g->relocs.
319
9c3f90c4
AM
3202013-02-12 Alan Modra <amodra@gmail.com>
321
322 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Provide
323 suitable definition when using generic linker hash table.
324
476366af
RS
3252013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
326
327 * elfxx-mips.c (mips_elf_count_got_entries): Delete.
328 (mips_elf_check_recreate_got, mips_elf_recreate_got): Take a
329 mips_elf_traverse_got_arg. Count GOT entries.
330 (mips_elf_resolve_final_got_entries): Take the bfd_link_info
331 as argument. Update after above changes.
332 (mips_elf_merge_got, mips_elf_lay_out_got): Don't call
333 mips_elf_count_got_entries. Update the calls to
334 mips_elf_resolve_final_got_entries.
335
9ab066b4
RS
3362013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
337
338 * elfxx-mips.c (mips_got_tls_type): New enum.
339 (mips_got_entry): Add tls_initialized.
340 (mips_elf_got_entry_hash, mips_elf_got_entry_eq, mips_tls_got_relocs)
341 (mips_elf_count_got_entry, mips_elf_initialize_tls_index): Remove
342 GOT_TLS_TYPE masks.
343 (mips_elf_reloc_tls_type, mips_tls_got_entries)
344 (mips_elf_record_global_got_symbol, mips_elf_initialize_tls_index)
345 (_bfd_mips_elf_finish_dynamic_symbol): Use GOT_TLS_NONE rather
346 than GOT_NORMAL.
347 (mips_elf_initialize_tls_slots): Replace got_offset and tls_type_p
348 arguments with a GOT entry. Remove GOT_TLS_TYPE masks. Use
349 tls_initialized rather than GOT_TLS_DONE.
350 (mips_tls_got_index): Delete.
351 (mips_elf_local_got_index, mips_elf_global_got_index): Use
352 mips_elf_initialize_tls_slots rather than mips_tls_got_index.
353 (mips_elf_record_got_entry): Initialize tls_initialized.
354
6c42ddb9
RS
3552013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
356
357 * elfxx-mips.c (mips_got_entry): Remove tls_ldm_offset.
358 (mips_elf_link_hash_entry): Remove tls_ie_type, tls_gd_type,
359 tls_ie_got_offset and tls_gd_got_offset.
360 (mips_elf_link_hash_newfunc): Remove initialization.
361 (mips_elf_create_got_info): Likewise.
362 (mips_elf_count_local_got_entries, mips_elf_count_global_tls_entries)
363 (mips_tls_single_got_index): Delete.
364 (mips_elf_local_got_index): Always use the GOT entry to track
365 GOT indices.
366 (mips_elf_global_got_index): Likewise.
367 (mips_elf_create_local_got_entry): Assert that TLS entries have
368 already been allocated.
369 (mips_elf_record_global_got_symbol): Don't initialize
370 tls_ie_type or tls_gd_type.
371 (mips_elf_count_got_symbols): Only count reloc-only GOT entries here.
372 (mips_elf_initialize_tls_index): Allocate a GOT index for every TLS
373 entry.
374 (mips_elf_lay_out_got): Use mips_elf_count_got_entries to count
375 the GOT entries.
376 (_bfd_mips_elf_finish_dynamic_symbol): Assert that TLS GOT offsets
377 have been allocated.
378 (_bfd_mips_elf_copy_indirect_symbol): Remove handling of
379 tls_ie_type and tls_gd_type.
380
ebc53538
RS
3812013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
382
383 * elfxx-mips.c (mips_elf_create_local_got_entry): Tidy. Avoid
384 aliasing violation. Check for htab allocation failures.
385
13fbec83
RS
3862013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
387
388 * elfxx-mips.c (mips_elf_primary_global_got_index): New function,
389 split out from...
390 (mips_elf_global_got_index): ...here. Reorder arguments so that
391 the output bfd and info come first.
392 (mips_elf_calculate_relocation): Update the call to
393 mips_elf_global_got_index accordingly.
394 (_bfd_mips_elf_finish_dynamic_symbol): Use
395 mips_elf_primary_global_got_index rather than
396 mips_elf_global_got_index.
397 (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
398
3dff0dd1
RS
3992013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
400
401 * elfxx-mips.c (mips_got_entry): Update comments.
402 (mips_elf_multi_got_entry_eq): Rename to...
403 (mips_elf_got_entry_eq): ...this, deleting the old definition.
404 (mips_elf_create_got_info): Remove master_got_p argument.
405 Always use mips_elf_got_entry_eq.
406 (mips_elf_bfd_got, mips_elf_multi_got, mips_elf_create_got_section):
407 Update calls accordingly.
408
d7206569
RS
4092013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
410
411 * elfxx-mips.c (mips_got_info): Remove bfd2got.
412 (mips_elf_bfd2got_hash): Delete.
413 (mips_elf_got_per_bfd_arg): Remove bfd2got.
414 (mips_elf_replace_bfd_got, mips_elf_count_got_entries): New functions.
415 (mips_elf_global_got_index, mips_elf_create_local_got_entry): Use
416 g->next to test for the multigot case. Use mips_elf_bfd_got rather
417 than mips_elf_got_for_ibfd.
418 (mips_elf_bfd2got_entry_hash, mips_elf_bfd2got_entry_eq)
419 (mips_elf_got_for_ibfd, mips_elf_get_got_for_bfd): Delete.
420 (mips_elf_make_got_per_bfd): Replace with...
421 (mips_elf_add_got_entry): ...this new function.
422 (mips_elf_make_got_pages_per_bfd): Replace with...
423 (mips_elf_add_got_page_entry): ...this new function.
424 (mips_elf_merge_got_with): Replace bfd2got argument with separate
425 bfd and GOT arguments. Use mips_elf_add_got_entry and
426 mips_elf_add_got_page_entry instead of mips_elf_make_got_per_bfd
427 and mips_elf_make_got_pages_per_bfd. Use mips_elf_replace_bfd_got
428 to set the BFD's GOT and free the old table.
429 (mips_elf_merge_got): Replace bfd2got argument with separate
430 bfd and GOT arguments. Apply mips_elf_resolve_final_got_entries.
431 Use mips_elf_count_got_entries to count the number of entries in
432 each GOT. Update the calls to mips_elf_merge_got_with.
433 (mips_elf_adjust_gp): Use g->next to test for the multigot case.
434 Use mips_elf_bfd_got rather than mips_elf_got_for_ibfd.
435 (mips_elf_multi_got): Don't create the bfd2got hash table.
436 Replace hash table traversal with a walk over the input bfds,
437 updating the call to mips_elf_merge_got. Use mips_elf_replace_bfd_got
438 to set the output bfd's GOT.
439 (mips_elf_lay_out_got): Rename "sub" to "ibfd". Record that all
440 bfds use the master GOT in the single-GOT case.
441 (_bfd_mips_elf_finish_dynamic_sections): Use mips_elf_bfd_got
442 rather than mips_elf_got_for_ibfd.
443
ee227692
RS
4442013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
445
446 * elfxx-mips.c (mips_elf_obj_tdata): Add a got field.
447 (mips_elf_bfd_got, mips_elf_record_got_entry): New functions.
448 (mips_elf_record_global_got_symbol): Update the hash entry before
449 adding the mips_got_entry. Use mips_elf_record_got_entry to do
450 the latter.
451 (mips_elf_record_local_got_symbol): Use mips_elf_record_got_entry.
452 (mips_elf_record_got_page_entry): Record the entry in both the
453 master and bfd GOTs.
454
72e7511a
RS
4552013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
456
457 * elfxx-mips.c (mips_elf_recreate_got): Don't change the entry;
458 create another one if necessary.
459 (mips_elf_set_gotidx): New function.
460 (mips_elf_set_global_gotidx): Use it.
461 (mips_elf_initialize_tls_index): Likewise. Take a
462 mips_elf_traverse_got_arg as argument.
463 (mips_elf_lay_out_got): Update use of mips_elf_initialize_tls_index.
464 (mips_elf_multi_got): Likewise. Cope with error returns from
465 mips_elf_set_global_gotidx.
466
ab361d49
RS
4672013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
468
469 * elfxx-mips.c (mips_got_info): Add relocs field.
470 (mips_elf_set_global_got_offset_arg, mips_elf_count_tls_arg): Replace
471 with...
472 (mips_elf_traverse_got_arg): ...this new structure.
473 (mips_elf_count_local_tls_relocs): Delete.
474 (mips_elf_count_global_tls_relocs): Likewise.
475 (mips_elf_count_got_entry): New function.
476 (mips_elf_count_local_got_entries): Likewise.
477 (mips_elf_count_global_tls_entries): Take a mips_elf_traverse_got_arg
478 rather than a mips_elf_count_tls_arg. Count both relocs and entries.
479 (mips_elf_record_local_got_symbol): Don't count got entries here.
480 (mips_elf_make_got_per_bfd): Use mips_elf_count_got_entry.
481 (mips_elf_set_global_got_offset): Split into...
482 (mips_elf_set_global_got_area, mips_elf_set_global_gotidx): ...these
483 new functions. Take a mips_elf_traverse_got_arg rather than a
484 mips_elf_set_global_got_offset_arg. Don't count TLS relocs here.
485 Use g->relocs to record the number of relocs needed for global GOT
486 entries.
487 (mips_elf_multi_got): Use mips_elf_traverse_got_arg rather than
488 mips_elf_set_global_got_offset_arg. Use the relocs field to count
489 relocations. Update for above function split.
490 (mips_elf_lay_out_got): Use mips_elf_count_local_got_entries
491 to count both the number of GOT entries and the number of TLS
492 relocs required by local entries. Likewise
493 mips_elf_count_global_tls_entries and global entries.
494 Remove uses of mips_elf_count_local_tls_relocs and
495 mips_elf_count_global_tls_relocs.
496
e641e783
RS
4972013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
498
499 * elfxx-mips.c (mips_got_entry): Update comment above tls_type entry
500 to say that each structure represents only one type of TLS reference.
501 (GOT_TLS_TYPE): New define.
502 (mips_elf_link_hash_entry): Temporarily split tls_type and
503 tls_got_offset into two variables each.
504 (mips_elf_link_hash_newfunc): Update accordingly.
505 (mips_elf_got_entry_eq, mips_elf_got_entry_hash)
506 (mips_elf_multi_got_entry_eq): Require the tls_type to be the same.
507 (mips_elf_reloc_tls_type, mips_tls_got_entries): New functions.
508 (mips_tls_got_relocs): Use a switch statement.
509 (mips_elf_count_global_tls_entries): Handle the new hash entry fields.
510 (mips_elf_initialize_tls_slots): Use a switch statement. Avoid
511 local "offset" variable.
512 (mips_tls_got_index): Remove r_type argument and assert. Remove
513 code that handled entries with two TLS types; always use the
514 original got_index instead.
515 (mips_tls_single_got_index): New function.
516 (mips_elf_local_got_index): Use entry->tls_type to check for
517 TLS entries. Use mips_tls_single_got_index. Update call to
518 mips_tls_got_index.
519 (mips_elf_global_got_index): Use mips_elf_reloc_tls_type.
520 Use p->tls_type to check for TLS entries. Update call to
521 mips_tls_got_index. Use mips_tls_single_got_index.
522 (mips_elf_create_local_got_entry): Use mips_elf_reloc_tls_type.
523 Use entry.tls_type to check for TLS entries.
524 (mips_elf_record_global_got_symbol): Replace tls_flag argument
525 with r_type argument. Use mips_elf_reloc_tls_type.
526 Set up the new hash entry fields.
527 (mips_elf_record_local_got_symbol): Replace tls_flag argument
528 with r_type argument. Use mips_elf_reloc_tls_type and
529 mips_tls_got_entries. Remove code that handled entries
530 with multiple TLS types.
531 (mips_elf_make_got_per_bfd): Use mips_tls_got_entries.
532 (mips_elf_initialize_tls_index): Handle new hash entry fields.
533 Use equality rather than masks when checking for specific TLS types.
534 Use mips_tls_got_entries. Remove code that handled entries
535 with multiple TLS types.
536 (mips_elf_calculate_relocation): Use TLS_RELOC_P instead of
537 testing the hash table entry.
538 (_bfd_mips_elf_check_relocs): Update calls to
539 mips_elf_record_global_got_symbol and mips_elf_record_local_got_symbol.
540 (_bfd_mips_elf_finish_dynamic_symbol): Don't check h->type.
541 (_bfd_mips_elf_copy_indirect_symbol): Handle new hash entry fields.
542
d9bf376d
RS
5432013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
544
545 * elfxx-mips.c (mips_elf_multi_got_entry_hash): Rename to...
546 (mips_elf_got_entry_hash): ...this, deleting the old version.
547 (mips_elf_create_got_info): Use mips_elf_got_entry_hash for
548 both types of GOT.
549
5334aa52
RS
5502013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
551
552 * elfxx-mips.c (mips_elf_create_got_info): New function.
553 (mips_elf_get_got_for_bfd, mips_elf_multi_got): Use it.
554 (mips_elf_create_got_section): Likewise.
555
946c668d
RS
5562013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
557
558 * elfxx-mips.c (mips_elf_record_local_got_symbol): Always set
559 gotidx to -1.
560
59b08994
RS
5612013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
562
563 * elfxx-mips.c (mips_elf_multi_got): Simplify size calculation.
564
d222d210
RS
5652013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
566
567 * elfxx-mips.c (mips_got_info): Move global_gotsym to...
568 (mips_elf_link_hash_table): ...here. Update rest of file accordingly.
569
1fd20d70
RS
5702013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
571
572 * elfxx-mips.c (mips_elf_count_global_tls_entries)
573 (mips_elf_count_global_tls_relocs): Don't count indirect or
574 warning symbols.
575 (mips_elf_multi_got, mips_elf_lay_out_got): Assert that the right
576 number of TLS entries were allocated.
577
7d94b319
RS
5782013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
579
580 * elfxx-mips.c (mips_elf_sort_hash_table_f): Remove asserts.
581
17214937
RS
5822013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
583
584 * elfxx-mips.c (mips_elf_merge_got_with): Only use arg->global_count
585 if there are TLS relocations.
586
9efeb38d
RS
5872013-02-11 Richard Sandiford <rdsandiford@googlemail.com>
588
589 * elfxx-mips.c (mips_elf_recreate_got): Remove free.
590 (mips_elf_resolve_final_got_entries): Remove bogus comment.
591
9c3f90c4
AM
5922013-02-11 Alan Modra <amodra@gmail.com>
593
594 * elfcode.h (elf_checksum_contents): Free contents.
595 * elf-bfd.h (_bfd_elf_link_hash_table_free): Declare.
596 * elflink.c (_bfd_elf_link_hash_table_free): New function.
597 (elf_final_link_free): New function, extracted from..
598 (bfd_elf_final_link): ..here. Always call
599 _bfd_elf_write_section_eh_frame_hdr.
600 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Default to
601 _bfd_elf_link_hash_table_free.
602 * libbfd-in.h (_bfd_merge_sections_free): Declare.
603 * libbfd.h: Regenerate.
604 * merge.c (_bfd_merge_sections_free): New function.
605 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame_hdr): Free
606 hdr_info->array.
607 * elf-m10300.c (elf32_mn10300_link_hash_table_free): Call
608 _bfd_elf_link_hash_table_free.
609 * elf32-arm.c (elf32_arm_link_hash_table_free): Likewise.
610 * elf32-avr.c (elf32_avr_link_hash_table_free): Likewise.
611 * elf32-hppa.c (elf32_hppa_link_hash_table_free): Likewise.
612 * elf32-i386.c (elf_i386_link_hash_table_free): Likewise.
613 * elf32-m68hc1x.c (m68hc11_elf_hash_table_free): Likewise.
614 * elf32-m68k.c (elf_m68k_link_hash_table_free): Likewise.
615 * elf32-metag.c (elf_metag_link_hash_table_free): Likewise.
616 * elf32-xgate.c (xgate_elf_bfd_link_hash_table_free): Likewise.
617 * elf64-aarch64.c (elf64_aarch64_link_hash_table_free): Likewise.
618 * elf64-ia64-vms.c (elf64_ia64_hash_table_free): Likewise.
619 * elf64-ppc.c (ppc64_elf_link_hash_table_free): Likewise.
620 * elf64-x86-64.c (elf_x86_64_link_hash_table_free): Likewise.
621 * elfnn-ia64.c (elfNN_ia64_hash_table_free): Likewise.
622 * elf32-cr16.c (elf32_cr16_link_hash_table_free): Delete.
623 (bfd_elf32_bfd_link_hash_table_free): Don't define.
624 * elf32-tic6x.c (elf32_tic6x_link_hash_table_free): Delete.
625 (bfd_elf32_bfd_link_hash_table_free): Dont' define.
626
7bf52ea2
AM
6272013-02-10 Alan Modra <amodra@gmail.com>
628
629 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_zmalloc.
630 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
631 * m68klinux.c (linux_link_hash_table_create): Likewise.
632 * sparclinux.c (linux_link_hash_table_create): Likewise.
633 * sunos.c (sunos_link_hash_table_create): Likewise.
634 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
635 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
636 * elf32-arm.c (elf32_arm_link_hash_table_create): Likewise.
637 * elf32-avr.c (elf32_avr_link_hash_table_create): Likewise.
638 * elf32-cr16.c (elf32_cr16_link_hash_table_create): Likewise.
639 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
640 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
641 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
642 * elf32-lm32.c (lm32_elf_link_hash_table_create): Likewise.
643 * elf32-m32r.c (m32r_elf_link_hash_table_create): Likewise.
644 * elf32-m68hc1x.c (m68hc11_elf_hash_table_create): Likewise.
645 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
646 * elf32-metag.c (elf_metag_link_hash_table_create): Likewise.
647 * elf32-nios2.c (nios2_elf32_link_hash_table_create): Likewise.
648 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
649 * elf32-score.c (elf32_score_link_hash_table_create): Likewise.
650 * elf32-spu.c (spu_elf_link_hash_table_create): Likewise.
651 * elf32-tic6x.c (elf32_tic6x_link_hash_table_create): Likewise.
652 * elf32-vax.c (elf_vax_link_hash_table_create): Likewise.
653 * elf32-xgate.c (xgate_elf_bfd_link_hash_table_create): Likewise.
654 * elf32-xtensa.c (elf_xtensa_link_hash_table_create): Likewise.
655 * elf64-aarch64.c (elf64_aarch64_link_hash_table_create): Likewise.
656 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
657 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
658 * elf64-x86-64.c (elf_x86_64_link_hash_table_create): Likewise.
659 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
660 * elflink.c (_bfd_elf_link_hash_table_create): Likewise.
661 (_bfd_elf_link_hash_table_init): Assume zero fill table on entry.
662
22cdc249
AM
6632013-02-10 Alan Modra <amodra@gmail.com>
664
665 * i386linux.c (linux_link_hash_table_create): Allocate table
666 with bfd_zmalloc, not bfd_alloc.
667 * pdp11.c (link_hash_table_create): Allocate table with
668 bfd_malloc, not bfd_alloc.
669 * elf32-bfin.c (bfinfdpic_elf_link_hash_table_create): Allocate table
670 with bfd_zmalloc, not bfd_zalloc.
671 (bfin_link_hash_table_create): Likewise.
672 * elf32-frv.c (frvfdpic_elf_link_hash_table_create): Likewise.
673 * elf64-hppa.c (elf64_hppa_hash_table_create): Likewise.
674
0e5de31a
AM
6752013-02-10 Alan Modra <amodra@gmail.com>
676
677 PR ld/15113
678 * elf32-sh.c (sh_elf_link_hash_table_create): Use bfd_zmalloc.
679
ad1fc92a
NC
6802013-02-08 Markos Chandras <markos.chandras@imgtec.com>
681
682 * elf32-metag.c: Use bfd_get_linker_section to get SEC_LINKER_CREATED
683 sections.
34c67f14
NC
684 (elf_metag_adjust_dynamic_symbol): Don't error on zero size dynbss
685 symbol.
ad1fc92a 686
170a8295
YZ
6872013-02-08 Yufeng Zhang <yufeng.zhang@arm.com>
688
689 * elf64-aarch64.c (elf64_aarch64_grok_prstatus): Change 'size' from
690 288 to 272.
691
619a703e
AM
6922013-02-08 Alan Modra <amodra@gmail.com>
693
694 PR binutils/15106
695 * elf-bfd.h (struct elf_obj_tdata): Add elf_find_function_cache.
696 * elf.c (elf_find_function): Revert last change. Use new
697 tdata field rather than static vars for cache.
698
02acbe22
L
6992013-02-07 H.J. Lu <hongjiu.lu@intel.com>
700
701 PR ld/15107
702 * elflink.c (elf_link_output_extsym): Set STB_GNU_UNIQUE only if
703 symbol is defined in regular object.
704
1965d5f2
AM
7052013-02-07 Roberto Agostino Vitillo <ra.vitillo@gmail.com>
706
707 PR binutils/15106
708 * elf.c (elf_find_function): Don't cache if symbols change.
709
dafbc74d
AM
7102013-02-07 Alan Modra <amodra@gmail.com>
711
712 PR binutils/14873
713 * elf-attrs.c (_bfd_elf_copy_obj_attributes): Don't attempt to
714 copy attributes from or to non-ELF.
715
20e52bd2
L
7162013-02-06 H.J. Lu <hongjiu.lu@intel.com>
717
718 * elf32-i386.c (elf_i386_allocate_dynrelocs): Don't clear pc_count
719 for non-zero TLS symbol.
720 (elf_i386_relocate_section): Don't resolve size relocation against
721 non-zero TLS symbol.
722 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Don't clear
723 pc_count for non-zero TLS symbol.
724 (elf_x86_64_relocate_section): Don't resolve size relocation
725 against non-zero TLS symbol.
726
36591ba1 7272013-02-06 Sandra Loosemore <sandra@codesourcery.com>
20e52bd2 728 Andrew Jenner <andrew@codesourcery.com>
36591ba1
SL
729
730 Based on patches from Altera Corporation.
731
732 * Makefile.am (ALL_MACHINES): Add cpu-nios2.lo.
733 (ALL_MACHINES_CFILES): Add cpu-nios2.c.
734 (BFD_BACKENDS): Add elf32-nios2.lo.
735 (BFD32_BACKENDS_CFILES): Add elf32-nios2.c.
736 * Makefile.in: Regenerated.
737 * configure.in: Add entries for bfd_elf32_bignios2_vec and
738 bfd_elf32_littlenios2_vec.
739 * configure: Regenerated.
740 * config.bfd: Add cases for nios2.
741 * archures.c (enum bfd_architecture): Add bfd_arch_nios2.
742 (bfd_mach_nios2): Define.
743 (bfd_nios2_arch): Declare.
744 (bfd_archures_list): Add bfd_nios2_arch.
745 * targets.c (bfd_elf32_bignios2_vec): Declare.
746 (bfd_elf32_littlenios2_vec): Declare.
747 (_bfd_target_vector): Add entries for bfd_elf32_bignios2_vec and
748 bfd_elf32_littlenios2_vec.
749 * elf-bfd.h (enum elf_target_id): Add NIOS2_ELF_DATA.
750 * reloc.c (enum bfd_reloc_code_real): Add Nios II relocations.
751 * bfd-in2.h: Regenerated.
752 * libbfd.h: Regenerated.
753 * cpu-nios2.c: New file.
754 * elf32-nios2.c: New file.
755
ca6b5f82
AM
7562013-02-06 Alan Modra <amodra@gmail.com>
757
758 * elf32-arm.c (elf32_arm_final_link_relocate): Only test for
759 stubs in stub_bfd.
760
37ba9f93
AM
7612013-02-06 Alan Modra <amodra@gmail.com>
762
763 * Makefile.am (SOURCE_HFILES): Add `elf-linux-psinfo.h'.
764 * Makefile.in: Regenerate.
765
70a38d42
SDJ
7662013-02-04 Sergio Durigan Junior <sergiodj@redhat.com>
767 Pedro Alves <palves@redhat.com>
768
769 * Makefile.in (SOURCE_HFILES): Add `elf-linux-psinfo.h'.
770 * elf-bfd.h (elf_internal_linux_prpsinfo): New structure
771 declaration.
772 (elfcore_write_linux_prpsinfo32, elfcore_write_linux_prpsinfo64)
773 (elfcore_write_ppc32_linux_prpsinfo32): New declarations.
774 * elf-linux-psinfo.h: New file.
775 * elf.c: Include elf-linux-psinfo.h.
776 (elfcore_write_linux_prpsinfo32, elfcore_write_linux_prpsinfo64):
777 New functions.
778 * elf32-ppc.c: Include `elf-linux-psinfo.h'.
779 (elf_external_ppc_linux_prpsinfo32): New structure declaration.
780 (PPC_LINUX_PRPSINFO32_SWAP_FIELDS): New macro.
781 (elfcore_write_ppc_linux_prpsinfo32): New function.
782
5ee43bc4
TG
7832013-02-04 Tristan Gingold <gingold@adacore.com>
784
785 * mach-o.c (bfd_mach_o_scan_start_address): Do not fail if no
786 start address.
787
0cadb185
AM
7882013-02-04 Alan Modra <amodra@gmail.com>
789
790 * Makefile.am (BFD64_BACKENDS): Remove elf-nacl.lo.
791 (BFD64_BACKENDS_CFILES): Remove elf-nacl.c.
792 * Makefile.in: Regenerate.
793 * po/SRC-POTFILES.in: Regenerate.
794
5d42dfb5
AM
7952013-02-04 Alan Modra <amodra@gmail.com>
796
797 * coff-tic54x.c (SWAP_OUT_RELOC_EXTRA): Delete.
798 * coff-tic80.c (SWAP_OUT_RELOC_EXTRA): Delete.
799
c57da1a7
AM
8002013-02-01 Alan Modra <amodra@gmail.com>
801
802 * elf64-ppc.c (dec_dynrel_count): Don't error when elf_gc_sweep_symbol
803 clears def_regular.
804
c0fd7846
TG
8052013-01-31 Tristan Gingold <gingold@adacore.com>
806
807 * mach-o.c (bfd_mach_o_scan): Call bfd_mach_o_flatten_sections
808 earlier. Fix status checking of bfd_mach_o_scan_start_address.
809 (bfd_mach_o_scan_start_address): Handle LC_MAIN.
810
b45b6908
AM
8112013-01-31 Alan Modra <amodra@gmail.com>
812 David S. Miller <davem@davemloft.net>
813
814 PR ld/15056
815 * elfxx-sparc.c (_bfd_sparc_elf_gc_mark_hook): Handle implicit
816 references to __tls_get_addr.
817 * elf32-tilpro.c (tilepro_elf_gc_mark_hook): Likewise. Correct
818 vtinherit and vtentry reloc handling too.
819 * elfxx-tilegx.c (tilegx_elf_gc_mark_hook): As for tilepro.
820
bcaa2f82
AM
8212013-01-31 Alan Modra <amodra@gmail.com>
822
823 * elf64-ppc.c (ppc_stub_name): Trim off trailing "+0".
824
22aa0c7e
AM
8252013-01-31 Alan Modra <amodra@gmail.com>
826
827 * elf64-ppc.c (build_plt_stub): Correct plt stub branch to glink.
828
bc30df16
AM
8292013-01-28 Alan Modra <amodra@gmail.com>
830
831 * elf64-ppc.c: Use %T to print symbols names and remove redundant
832 "relocation" in error messages throughout file.
833 (ppc64_elf_relocate_section): Remove sibling call error message,
834 replace with "call lacks nop". Specially report errors for
835 branches to function entry points via OPD lookup and branches
836 to stubs. Remove NULL symbol handling now done by %T.
837
89d7b8aa
AM
8382013-01-28 Alan Modra <amodra@gmail.com>
839
840 * archive.c (bfd_generic_archive_p): Return target and keep
841 ardata on partial matches.
842 * format.c (bfd_check_format_matches): Adjust for above
843 change. Remove bfd_error_file_ambiguously_recognized dead
844 code.
845
c9ba0c87
AM
8462013-01-26 Alan Modra <amodra@gmail.com>
847
848 * bfd.c (struct bfd_preserve, bfd_preserve_save, bfd_preserve_restore,
849 bfd_preserve_finish): Move to..
850 * format.c: ..here, splitting out..
851 (bfd_reinit): ..this. New function.
852 (bfd_check_format_matches): Use bfd_preserve_save/restore to
853 keep bfd state for a match.
854 * elfcode.h (elf_object_p): Don't use bfd_preserve_save/restore.
855 * elfcore.h (elf_core_file_p): Likewise.
856 * mach-o.c (bfd_mach_o_header_p): Likewise.
857 * pef.c (bfd_pef_object_p, bfd_pef_xlib_object_p): Likewise.
858 * xsym.c (bfd_sym_object_p): Likewise.
859 * mmo.c (mmo_scan): Clear abfd->symcount.
860 * opncls.c (_bfd_new_bfd): Use a smaller section hash table.
861 * section.c (bfd_section_list_clear): Clear section_htab.count.
862 * bfd-in2.h: Regenerate.
863
d79dcc73
NC
8642013-01-25 Michael Schewe <michael.schewe@gmx.net>
865
866 * elf32-h8300.c (elf32_h8_relax_section): When checking for a
867 second reloc, make sure that the reloc potentially exists first.
868
78c8d46c
NC
8692013-01-24 Nick Clifton <nickc@redhat.com>
870
871 * archures.c: Add bfd_mach_v850e3v5.
872 * bfd-in2.h: Regenerate.
873 * cpu-v850.c: Add entries for v850e2v5 and v850e3v5.
874 * cpu-v850_rh850.c: Likewise.
875 * elf32-v850.c: Add support for v850e3v5 architecture.
876
1a18f0ae
NC
8772013-01-23 Markos Chandras <markos.chandras@imgtec.com>
878
879 * elf32-metag.c: Error on HIADDR16/LOADDR16 in shared link.
880
f65a9e53
AM
8812013-01-23 Leif Ekblad <leif@rdos.net>
882
883 * config.bfd (x86_64-*-rdos*): Remove targ_selvecs.
884
3bea1fcb
L
8852013-01-18 H.J. Lu <hongjiu.lu@intel.com>
886
887 * elf32-i386.c (elf_i386_allocate_dynrelocs): Clear pc_count for
888 non-zero TLS symbol.
889 (elf_i386_relocate_section): Resolve size relocation against
890 non-zero TLS symbol.
891 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Clear pc_count
892 for non-zero TLS symbol.
893 (elf_x86_64_relocate_section): Resolve size relocation against
894 non-zero TLS symbol.
895
b1b00fcc
MF
8962013-01-18 Mike Frysinger <vapier@gentoo.org>
897
898 * elflink.c (bfd_elf_size_dynamic_sections): Only add DT_RPATH
899 when new_dtags is false. Only add DT_RUNPATH when new_dtags is
900 true.
901
06a6a421
L
9022013-01-17 H.J. Lu <hongjiu.lu@intel.com>
903
904 * elf32-i386.c (elf_i386_check_relocs): Count size relocation as
905 PC-relative relocation.
906 * elf64-x86-64.c (elf_x86_64_check_relocs): Count size relocation
907 as PC-relative relocation.
908
6a3e1bae
L
9092013-01-16 H.J. Lu <hongjiu.lu@intel.com>
910
911 * elf32-i386.c (elf_i386_check_relocs): Update R_386_SIZE32
912 check.
913 (elf_i386_relocate_section): Don't check TLS for R_386_SIZE32.
914
915 * elf64-x86-64.c (elf_x86_64_check_relocs): Update R_X86_64_SIZE32
916 and R_X86_64_SIZE64 check.
917 (elf_x86_64_relocate_section): Don't check TLS for R_X86_64_SIZE32
918 nor R_X86_64_SIZE64.
919
1788fc08
L
9202013-01-16 H.J. Lu <hongjiu.lu@intel.com>
921
922 * bfd-in2.h: Regenerated.
923 * libbfd.h: Likewise.
924
925 * elf32-i386.c (elf_howto_table): Fill R_386_SIZE32 entry.
926 (elf_i386_reloc_type_lookup): Support BFD_RELOC_SIZE32.
927 (elf_i386_check_relocs): Handle R_386_SIZE32.
928 (elf_i386_gc_sweep_hook): Likewise.
929 (elf_i386_relocate_section): Likewise.
930
931 * elf64-x86-64.c (x86_64_elf_howto_table): Fill R_X86_64_SIZE32
932 and R_X86_64_SIZE64 entries.
933 (x86_64_reloc_map): Add BFD_RELOC_SIZE32 and BFD_RELOC_SIZE64,
934 (elf_x86_64_rtype_to_howto): Handle R_X86_64_SIZE32 for x32.
935 (elf_x86_64_reloc_name_lookup): Likewise.
936 (elf_x86_64_check_relocs): Handle R_X86_64_SIZE32 and
937 R_X86_64_SIZE64.
938 (elf_x86_64_gc_sweep_hook): Likewise.
939 (elf_x86_64_relocate_section): Likewise.
940
941 * reloc.c (bfd_reloc_code_type): Add BFD_RELOC_SIZE32 and
942 BFD_RELOC_SIZE64.
943
1e536451
L
9442013-01-15 H.J. Lu <hongjiu.lu@intel.com>
945
946 * elf64-x86-64.c (R_X86_64_standard): Replace R_X86_64_IRELATIVE
947 with R_X86_64_RELATIVE64.
948
77bf820f
NC
9492013-01-15 Nick Clifton <nickc@redhat.com>
950
951 * elf32-msp430.c: Fix spelling typo.
952
e2458743
AM
9532013-01-15 Alan Modra <amodra@gmail.com>
954
955 * elf64-ppc.c (ppc64_elf_size_stubs): Default shared libs to
956 plt-thread-safe.
957
405bf443
AM
9582013-01-14 Alan Modra <amodra@gmail.com>
959
960 PR binutils/14813
961 * bfdio.c (struct bfd_iovec <bclose>): Revert 2012-11-06.
962 (memory_bclose): Likewise. Return 0 on success.
963 * cache.c (cache_bclose): Likewise.
964 * opncls.c (opncls_bclose, bfd_close): Likewise.
965 * vms-lib.c (vms_lib_bclose): Likewise.
966 * libbfd.h: Regenerate.
967
ee659f1f
AM
9682013-01-13 Alan Modra <amodra@gmail.com>
969
970 * elf-bfd.h (struct elf_link_hash_entry): Delete dynamic_weak.
971 Add ref_dynamic_nonweak.
972 * elflink.c (_bfd_elf_mark_dynamic_def_weak): Delete.
973 (_bfd_elf_merge_symbol): Don't call above function. Move
974 setting of ref_dynamic_nonweak and dynamic_def earlier. Don't
975 clear dynamic_def.
976 (elf_link_add_object_symbols): Delete redundant "override" test.
977 Don't set dynamic_def here.
978 (elf_link_output_extsym): Update.
979
68c4a57e
L
9802013-01-12 H.J. Lu <hongjiu.lu@intel.com>
981
982 * elf32-i386.c (elf_i386_check_relocs): Set bfd errror for
983 normal and TLS symbol access.
984 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
985
02be4619
AM
9862013-01-12 Alan Modra <amodra@gmail.com>
987
988 * elf-bfd.h (_bfd_elf_strtab_refcount): Declare.
989 * elf-strtab.c (_bfd_elf_strtab_refcount): New function.
990 * elflink.c (elf_add_dt_needed_tag): Use _bfd_elf_strtab_refcount.
991
a4542f1b
AM
9922013-01-12 Alan Modra <amodra@gmail.com>
993
994 PR ld/12549
995 * elf-bfd.h (_bfd_elf_strtab_clear_refs): Declare.
996 (_bfd_elf_strtab_clear_all_refs): Define.
997 * elf-strtab.c (_bfd_elf_strtab_clear_refs): New function.
998 (_bfd_elf_strtab_clear_all_refs): Delete.
999 * elflink.c (elf_link_add_object_symbols): Clear out added
1000 strtab refs. Correct handling of warning common symbols.
1001
68ffbac6
L
10022013-01-10 H.J. Lu <hongjiu.lu@intel.com>
1003
1004 * aout0.c: Remove trailing white spaces.
1005 * archive.c: Likewise.
1006 * archures.c: Likewise.
1007 * bfd-in.h: Likewise.
1008 * bfd-in2.h: Likewise.
1009 * coff-alpha.c: Likewise.
1010 * coff-i860.c: Likewise.
1011 * coff-mips.c: Likewise.
1012 * coff-ppc.c: Likewise.
1013 * coff-tic80.c: Likewise.
1014 * coff-x86_64.c: Likewise.
1015 * coff-z80.c: Likewise.
1016 * coffcode.h: Likewise.
1017 * coffgen.c: Likewise.
1018 * cofflink.c: Likewise.
1019 * compress.c: Likewise.
1020 * corefile.c: Likewise.
1021 * cpu-arm.c: Likewise.
1022 * cpu-avr.c: Likewise.
1023 * cpu-bfin.c: Likewise.
1024 * cpu-cr16.c: Likewise.
1025 * cpu-cr16c.c: Likewise.
1026 * cpu-crx.c: Likewise.
1027 * cpu-h8300.c: Likewise.
1028 * cpu-i386.c: Likewise.
1029 * cpu-lm32.c: Likewise.
1030 * cpu-m68k.c: Likewise.
1031 * cpu-moxie.c: Likewise.
1032 * cpu-msp430.c: Likewise.
1033 * cpu-sh.c: Likewise.
1034 * cpu-xc16x.c: Likewise.
1035 * dwarf2.c: Likewise.
1036 * ecofflink.c: Likewise.
1037 * ecoffswap.h: Likewise.
1038 * elf-ifunc.c: Likewise.
1039 * elf-m10300.c: Likewise.
1040 * elf-vxworks.c: Likewise.
1041 * elf32-avr.c: Likewise.
1042 * elf32-avr.h: Likewise.
1043 * elf32-cr16.c: Likewise.
1044 * elf32-cr16c.c: Likewise.
1045 * elf32-cris.c: Likewise.
1046 * elf32-crx.c: Likewise.
1047 * elf32-frv.c: Likewise.
1048 * elf32-hppa.c: Likewise.
1049 * elf32-i860.c: Likewise.
1050 * elf32-ip2k.c: Likewise.
1051 * elf32-iq2000.c: Likewise.
1052 * elf32-m32c.c: Likewise.
1053 * elf32-m68hc1x.c: Likewise.
1054 * elf32-msp430.c: Likewise.
1055 * elf32-mt.c: Likewise.
1056 * elf32-ppc.c: Likewise.
1057 * elf32-rl78.c: Likewise.
1058 * elf32-s390.c: Likewise.
1059 * elf32-score.h: Likewise.
1060 * elf32-sh-symbian.c: Likewise.
1061 * elf32-sh.c: Likewise.
1062 * elf32-spu.c: Likewise.
1063 * elf32-tic6x.c: Likewise.
1064 * elf32-v850.c: Likewise.
1065 * elf32-xc16x.c: Likewise.
1066 * elf32-xtensa.c: Likewise.
1067 * elf64-alpha.c: Likewise.
1068 * elf64-hppa.c: Likewise.
1069 * elf64-ppc.c: Likewise.
1070 * elf64-s390.c: Likewise.
1071 * elfcore.h: Likewise.
1072 * elflink.c: Likewise.
1073 * elfxx-mips.c: Likewise.
1074 * elfxx-sparc.c: Likewise.
1075 * elfxx-tilegx.c: Likewise.
1076 * ieee.c: Likewise.
1077 * libcoff.h: Likewise.
1078 * libpei.h: Likewise.
1079 * libxcoff.h: Likewise.
1080 * linker.c: Likewise.
1081 * mach-o-i386.c: Likewise.
1082 * mach-o-target.c: Likewise.
1083 * mach-o.c: Likewise.
1084 * mach-o.h: Likewise.
1085 * mmo.c: Likewise.
1086 * opncls.c: Likewise.
1087 * pdp11.c: Likewise.
1088 * pe-x86_64.c: Likewise.
1089 * peXXigen.c: Likewise.
1090 * pef-traceback.h: Likewise.
1091 * pei-x86_64.c: Likewise.
1092 * peicode.h: Likewise.
1093 * plugin.c: Likewise.
1094 * reloc.c: Likewise.
1095 * riscix.c: Likewise.
1096 * section.c: Likewise.
1097 * som.c: Likewise.
1098 * syms.c: Likewise.
1099 * tekhex.c: Likewise.
1100 * ticoff.h: Likewise.
1101 * vaxbsd.c: Likewise.
1102 * xcofflink.c: Likewise.
1103 * xtensa-isa.c: Likewise.
1104
a3c62988
NC
11052013-01-10 Will Newton <will.newton@imgtec.com>
1106
1107 * Makefile.am: Add Meta.
1108 * Makefile.in: Regenerate.
1109 * archures.c (bfd_mach_metag): New.
1110 * bfd-in2.h: Regenerate.
1111 * config.bfd: Add Meta.
1112 * configure: Regenerate.
1113 * configure.in: Add Meta.
1114 * cpu-metag.c: New file.
1115 * elf-bfd.h: Add Meta.
1116 * elf32-metag.c: New file.
1117 * elf32-metag.h: New file.
1118 * libbfd.h: Regenerate.
1119 * reloc.c: Add Meta relocations.
1120 * targets.c: Add Meta.
1121
652451f8
YZ
11222013-01-08 Yufeng Zhang <yufeng.zhang@arm.com>
1123
1124 * elf-bfd.h (elfcore_write_aarch_tls): Add prototype.
1125 (elfcore_write_aarch_hw_break): Likewise.
1126 (elfcore_write_aarch_hw_watch): Likewise.
1127 * elf.c (elfcore_grok_aarch_tls): New function.
1128 (elfcore_grok_aarch_hw_break): Likewise.
1129 (elfcore_grok_aarch_hw_watch): Likewise.
1130 (elfcore_grok_note): Call the new functions to handle the
1131 corresponding notes.
1132 (elfcore_write_aarch_tls): New function.
1133 (elfcore_write_aarch_hw_break): Likewise.
1134 (elfcore_write_aarch_hw_watch): Likewise.
1135 (elfcore_write_register_note): Call the new functions to handle the
1136 corresponding pseudo sections.
1137
45a466b5
TT
11382013-01-07 Tom Tromey <tromey@redhat.com>
1139
1140 * section.c (_bfd_std_section): Rename from std_section.
f75e0e33
AM
1141 (bfd_com_section_ptr, bfd_und_section_ptr, bfd_abs_section_ptr)
1142 (STD_SECTION): Update.
45a466b5
TT
1143 * bfd-in2.h: Rebuild.
1144
e407c74b
NC
11452013-01-04 Juergen Urban <JuergenUrban@gmx.de>
1146
1147 * archures.c (bfd_mach_mips5900): Define.
1148 * bfd-in2.h: Regenerate.
1149 * config.bfd: Add mips64-ps2-elf and mips-ps2-elf targets.
1150 * cpu-mips.c: Add support for MIPS r5900.
1151 * elfxx-mips.c: Add support for MIPS r5900 (extension of r4000).
1152
9b239e0e
NC
11532013-01-03 Nickolai Zeldovich <nickolai@csail.mit.edu>
1154 Nick Clifton <nickc@redhat.com>
1155
1156 * elflink.c (get_value): Prevent the use of an undefined shift
1157 operation. Add sanity checks.
1158
bab4becb 11592013-01-02 Kaushik Phatak <kaushik.phatak@kpitcummins.com>
884f2a8d 1160
bab4becb 1161 * config.bfd (cr16*-*-uclinux*): New target support.
884f2a8d 1162
9911c0fc 1163
bab4becb 1164For older changes see ChangeLog-2012
56882138 1165\f
bab4becb 1166Copyright (C) 2013 Free Software Foundation, Inc.
752937aa
NC
1167
1168Copying and distribution of this file, with or without modification,
1169are permitted in any medium without royalty provided the copyright
1170notice and this notice are preserved.
1171
56882138
AM
1172Local Variables:
1173mode: change-log
1174left-margin: 8
1175fill-column: 74
1176version-control: never
1177End:
This page took 0.727514 seconds and 4 git commands to generate.