2012-01-31 Paul Brook <paul@codesourcery.com>
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2012-01-27 Michael Eager <eager@eagercon.com>
2
3 * bfd/elf32-microblaze.c (create_got_section):
4 Reuse existing .rela.got section.
5
6 2012-01-23 Alan Modra <amodra@gmail.com>
7
8 * elf-bfd.h: Formatting.
9 (struct elf_backend_data): Add "maybe_function_sym".
10 (_bfd_elf_maybe_function_sym): Declare.
11 * elfxx-target.h (elf_backend_maybe_function_sym): Define.
12 (elfNN_bed): Init new field.
13 * elf.c (elf_find_function): Use maybe_function_sym.
14 (_bfd_elf_maybe_function_sym): New function.
15 * elf64-ppc.c (elf_backend_maybe_function_sym): Define.
16 (ppc64_elf_maybe_function_sym): New function.
17
18 2012-01-20 Francois Gouget <fgouget@codeweavers.com>
19
20 PR binutils/13534
21 * archive.c (_bfd_ar_sizepad): New function. Correctly install and
22 pad the size field in an archive header.
23 (_bfd_generic_read_ar_hdr_mag): Use the correct type and scan
24 function for the archive size field.
25 (bfd_generic_openr_next_archived_file): Likewise.
26 (do_slurp_coff_armap): Likewise.
27 (_bfd_write_archive_contents): Likewise.
28 (_bfd_bsd44_write_ar_hdr): Use the new function.
29 (bfd_ar_hdr_from_filesystem): Likewise.
30 (_bfd_write_archive_contents): Likewise.
31 (bsd_write_armap): Likewise.
32 (coff_write_armap): Likewise.
33 * archive64.c (bfd_elf64_archive_write_armap): Likewise.
34 * bfdio.c (bfd_bread): Use correct type for archive element
35 sizes.
36 * ar.c (open_inarch): Likewise.
37 (extract_file): Likewise.
38 * libbfd-in.h (struct areltdata): Use correct types for
39 parsed_size and extra_size fields.
40 Prototype _bfd_ar_sizepad function.
41 * libbfd.h: Regenerate.
42
43 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
44
45 * elf.c (elfcore_write_prpsinfo): Provide unconditionally.
46 Return NULL if core file generation is unsupported.
47 (elfcore_write_prstatus): Likewise.
48 * elf32-arm.c (elf32_arm_nabi_write_core_note): New function.
49 (elf_backend_write_core_note): Define.
50
51 2012-01-19 Tristan Gingold <gingold@adacore.com>
52
53 * pef.c: Add a comment.
54 * xsym.c: Likewise.
55
56 2012-01-17 Alan Modra <amodra@gmail.com>
57
58 * elf32-ppc.c (ppc_elf_write_core_note <NT_PRPSINFO>): Don't leave
59 trailing garbage in the note.
60 * elf64-ppc.c (ppc64_elf_write_core_note <NT_PRPSINFO>): Likewise.
61
62 2012-01-16 Daniel Green <venix1@gmail.com>
63
64 PR ld/13491
65 * coff-i386.c (coff_i386_rtype_to_howto <R_SECREL32>): Test
66 h->root.type not h->type.
67 * coff-x86_64.c (coff_amd64_rtype_to_howto <R_AMD64_SECREL>): Likewise.
68
69 2012-01-13 Iain Sandoe <idsandoe@googlemail.com>
70
71 * mach-o.c (bfd_mach_o_build_dysymtab_command): Handle absolute
72 indirect symbols.
73
74 2012-01-13 Iain Sandoe <idsandoe@googlemail.com>
75
76 * mach-o.c (bfd_mach_o_write_relocs): Move computation of relocs file
77 position from here... to (bfd_mach_o_build_seg_command): Here.
78
79 2012-01-12 Iain Sandoe <idsandoe@googlemail.com>
80
81 * mach-o.c (bfd_mach_o_count_indirect_symbols): New.
82 (bfd_mach_o_build_dysymtab_command): Populate indirect symbol table.
83 * mach-o.h (bfd_mach_o_asymbol): Move declaration to start of the
84 file. (bfd_mach_o_section): Add indirect_syms field.
85
86 2012-01-11 Iain Sandoe <idsandoe@googlemail.com>
87
88 * mach-o.c (bfd_mach_o_build_seg_command): Separate computation of
89 vmsize from filesize. Don't compute offsets or file sizes for
90 zerofill sections.
91
92 2012-01-11 Iain Sandoe <idsandoe@googlemail.com>
93
94 * mach-o.c (bfd_mach_o_build_commands): Make the building of each
95 command type independent.
96
97 2012-01-11 Alan Modra <amodra@gmail.com>
98
99 * elf64-ppc.c: Define more insns used in plt call stubs.
100 (ppc64_elf_brtaken_reloc): Assume isa version 2 or above.
101 (ppc64_elf_relocate_section): Likewise.
102 (enum ppc_stub_type): Add ppc_stub_plt_call_r2save.
103 (struct ppc_link_hash_table): Increase size of stub_count array.
104 Add plt_stub_align and plt_thread_safe.
105 (ALWAYS_USE_FAKE_DEP, ALWAYS_EMIT_R2SAVE): Define.
106 (plt_stub_size, plt_stub_pad): New functions.
107 (build_plt_stub): Emit barriers for power7 thread safety. Don't
108 emit needless save of r2.
109 (build_tls_get_addr_stub): Adjust params.
110 (ppc_build_one_stub): Handle ppc_stub_plt_call_r2save and aligning
111 plt stubs. Adjust build_*plt_stub calls.
112 (ppc_size_one_stub): Similarly.
113 (ppc64_elf_size_stubs): Accept plt_thread_safe and plt_stub_align
114 params. Choose default for plt_thread_safe based on existence of
115 calls to thread creation functions. Modify plt_call to
116 plt_call_r2save when no tocsave reloc found. Align tail of stub
117 sections.
118 (ppc64_elf_build_stubs): Align tail of stub sections. Adjust
119 output of stub statistics.
120 (ppc64_elf_relocate_section): Handle ppc_stub_plt_call_r2save.
121 * elf64-ppc.h (ppc64_elf_size_stubs): Update prototype.
122
123 2012-01-10 H.J. Lu <hongjiu.lu@intel.com>
124
125 PR ld/13581
126 * elf64-x86-64.c (elf_x86_64_relocate_section): Remove ABI_64_P
127 check on R_X86_64_PCXX.
128
129 2012-01-10 Tristan Gingold <gingold@adacore.com>
130
131 * mach-o.c (bfd_mach_o_build_commands): Avoid uninitialized false
132 warning.
133
134 2012-01-10 Tristan Gingold <gingold@adacore.com>
135
136 * bfdio.c (bfd_tell): Handle nested archives.
137 (bfd_seek): Ditto.
138 * cache.c (bfd_cache_lookup_worker): Ditto.
139 * archive.c (_bfd_get_elt_at_filepos): Remove code dealing with
140 nested archives.
141 (bfd_generic_openr_next_archived_file): Likewise.
142
143 2012-01-09 Iain Sandoe <idsandoe@googlemail.com>
144
145 * mach-o.c (bfd_mach_o_bfd_copy_private_symbol_data): Implement.
146 (bfd_mach_o_write_symtab): Remove handling for indirect syms.
147 (bfd_mach_o_primary_symbol_sort_key): Likewise.
148 (bfd_mach_o_cf_symbols): Likewise.
149 (bfd_mach_o_sort_symbol_table): Remove.
150 (bfd_mach_o_mangle_symbols): Adjust arguments, remove handling
151 for indirect and dysymtab counts. Do the symbol sorting here.
152 (bfd_mach_o_build_dysymtab_command): Count the symbol types here.
153 Make the indirect symbols a TODO.
154 (bfd_mach_o_build_commands): Adjust call to bfd_mach_o_mangle_symbols.
155 (bfd_mach_o_make_empty_symbol): Specifically flag unset symbols with
156 a non-zero value.
157 (bfd_mach_o_read_symtab_symbol): Record the symbol index.
158 (bfd_mach_o_read_symtab_symbol): Adjust recording of global status.
159 * mach-o.h (mach_o_data_struct): Remove indirect and dysymtab entries.
160 (IS_MACHO_INDIRECT): Remove.
161 (SYM_MACHO_FIELDS_UNSET, SYM_MACHO_FIELDS_NOT_VALIDATED): New.
162
163 2012-01-06 Nick Clifton <nickc@redhat.com>
164
165 PR binutils/13121
166 * reloc.c (bfd_generic_lookup_section_flags): Rename 'finfo' to
167 'flaginfo' to avoid conflicts with AIX system headers.
168
169 2012-01-06 Tristan Gingold <gingold@adacore.com>
170
171 * bfdio.c (bfd_bread): Use arelt_size macro.
172
173 2012-01-06 Tristan Gingold <gingold@adacore.com>
174
175 * config.bfd (i[3-7]86-*-darwin*): Define targ64_selvecs.
176
177 2012-01-05 Nick Clifton <nickc@redhat.com>
178
179 PR ld/12161
180 * elf32-avr.c (elf32_avr_relax_delete_bytes): Read in relocs if
181 necessary.
182
183 2012-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
184
185 Fix zero registers core files when built by gcc-4.7.
186 * elf64-x86-64.c (elf_x86_64_write_core_note): Remove variables p and
187 size. Call elfcore_write_note for the local variables. Remove the
188 final elfcore_write_note call. Add NOTREACHED comments.
189
190 2012-01-04 Tristan Gingold <gingold@adacore.com>
191
192 * mach-o.c (bfd_mach_o_fat_stat_arch_elt): New function.
193 (bfd_mach_o_generic_stat_arch_elt): Adjust.
194
195 2012-01-04 Tristan Gingold <gingold@adacore.com>
196
197 * mach-o.c (bfd_mach_o_fat_member_init): New function.
198 (bfd_mach_o_openr_next_archived_file): Reindent.
199 Adjust to call bfd_mach_o_fat_member_init.
200 (bfd_mach_o_fat_extract): Adjust to call bfd_mach_o_fat_member_init.
201
202 2012-01-04 Tristan Gingold <gingold@adacore.com>
203
204 * mach-o-x86-64.c (bfd_mach_o_x86_64_swap_reloc_out): Handle
205 BFD_RELOC_32, BFD_RELOC_MACH_O_X86_64_PCREL32_1,
206 BFD_RELOC_MACH_O_X86_64_PCREL32_2,
207 BFD_RELOC_MACH_O_X86_64_PCREL32_4,
208 BFD_RELOC_MACH_O_X86_64_BRANCH32,
209 BFD_RELOC_MACH_O_X86_64_SUBTRACTOR32,
210 BFD_RELOC_MACH_O_X86_64_GOT.
211
212 2012-01-04 Tristan Gingold <gingold@adacore.com>
213
214 * mach-o.h (bfd_mach_o_fvmlib_command): New structure.
215 (bfd_mach_o_load_command): Add fvmlib field.
216
217 * mach-o.c (bfd_mach_o_read_fvmlib): New function.
218 (bfd_mach_o_read_command): Handle fvmlib.
219
220 2012-01-04 Tristan Gingold <gingold@adacore.com>
221
222 * mach-o.c (bfd_mach_o_convert_architecture): Reindent.
223 Decode msubtype for ARM.
224
225 2012-01-04 Tristan Gingold <gingold@adacore.com>
226
227 * mach-o.c (bfd_mach_o_get_synthetic_symtab): Add comments.
228
229 2012-01-04 Tristan Gingold <gingold@adacore.com>
230
231 * mach-o.h: Reindent header.
232 (bfd_mach_o_encryption_info_command): New structure.
233 (bfd_mach_o_load_command): Add encryption_info field.
234
235 * mach-o.c (bfd_mach_o_read_encryption_info): New function.
236 (bfd_mach_o_read_command): Handle BFD_MACH_O_LC_ENCRYPTION_INFO.
237 (bfd_mach_o_read_command): Adjust error message.
238
239 2012-01-04 Shinichiro Hamaji <shinichiro.hamaji@gmail.com>
240
241 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Factor out the part
242 which reads DWARF2 and stores in stash from find_line.
243 (find_line) Call _bfd_dwarf2_slurp_debug_info.
244 * libbfd-in.h (_bfd_dwarf2_slurp_debug_info): Add declaration.
245 * libbfd.h (_bfd_dwarf2_slurp_debug_info): Regenerate.
246 * mach-o.c (dsym_subdir): The name of subdir where debug
247 information may be stored.
248 (bfd_mach_o_lookup_uuid_command): New. Lookup a load command whose
249 type is UUID.
250 (bfd_mach_o_dsym_for_uuid_p): New. Check if the specified BFD is
251 corresponding to the executable.
252 (bfd_mach_o_find_dsym): New. Find a debug information BFD in the
253 specified binary file.
254 (bfd_mach_o_follow_dsym): New. Find a debug information BFD for
255 the original BFD.
256 (bfd_mach_o_find_nearest_line): Check dSYM files for Mach-O
257 executables, dylibs, and bundles.
258 (bfd_mach_o_close_and_cleanup): Clean up BFDs for the dSYM file.
259 * mach-o.h (dsym_bfd): The BFD of the dSYM file.
260
261 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
262
263 * mach-o.c (bfd_mach_o_mangle_symbols): Put in the section index
264 for stabd symbols.
265 (bfd_mach_o_primary_symbol_sort_key): Adjust for stabs.
266 (bfd_mach_o_cf_symbols): Likewise.
267
268 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
269
270 * mach-o.c (bfd_mach_o_mangle_symbols): Correct typo.
271
272 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
273
274 * mach-o.c (bfd_mach_o_write_symtab): Fill in the string table index
275 as the value of an indirect symbol. Keep the string table index in
276 non-indirect syms for reference.
277 (bfd_mach_o_write_dysymtab): New.
278 (bfd_mach_o_primary_symbol_sort_key): New.
279 (bfd_mach_o_cf_symbols): New.
280 (bfd_mach_o_sort_symbol_table): New.
281 (bfd_mach_o_mangle_symbols): Return early if no symbols. Sort symbols.
282 If we are emitting a dysymtab, process indirect symbols and count the
283 number of each other kind.
284 (bfd_mach_o_mangle_sections): New.
285 (bfd_mach_o_write_contents): Split out some pre-requisite code into
286 the command builder. Write dysymtab if the command is present.
287 (bfd_mach_o_count_sections_for_seg): New.
288 (bfd_mach_o_build_seg_command): New.
289 (bfd_mach_o_build_dysymtab_command): New.
290 (bfd_mach_o_build_commands): Reorganize to support the fact that some
291 commands are optional and should not be emitted if there are no
292 sections or symbols.
293 (bfd_mach_o_set_section_contents): Amend comment.
294 * mach-o.h: Amend and add to comments.
295 (mach_o_data_struct): Add fields for dysymtab symbols counts and a
296 pointer to the indirects, when present.
297 (bfd_mach_o_should_emit_dysymtab): New macro.
298 (IS_MACHO_INDIRECT): Likewise.
299
300 For older changes see ChangeLog-2011
301 \f
302 Local Variables:
303 mode: change-log
304 left-margin: 8
305 fill-column: 74
306 version-control: never
307 End:
This page took 0.037172 seconds and 4 git commands to generate.