bfd/
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
bbb0fc04
AM
12009-05-14 Alan Modra <amodra@bigpond.net.au>
2
3 * elf32-spu.c (spu_elf_size_stubs): Split out section placement to..
4 (spu_elf_place_overlay_data): ..here. New function.
5 * elf32-spu.h (spu_elf_place_overlay_data): Declare.
6
6e6718a3
AJ
72009-05-13 Andrew Jenner <andrew@codesourcery.com>
8
9 * elf32-arm.c: Move sysdep.h to start of file.
10
77ae44b0
AM
112009-05-11 Ulrich Weigand <uweigand@de.ibm.com>
12
13 * elf32-spu.c (spu_elf_find_overlays): Don't use .ovl.init lma as
14 start of overlays.
15 (spu_elf_build_stubs): Don't define __icache_tagbase. Define
16 __icache_tag_array and __icache_tag_array_size.
17
51408ec2
AM
182009-05-11 Masaki Muranaka <monaka@monami-software.com>
19
20 * elf32-bfin.c (bfin_bfd_reloc_type_lookup): Remove unnecessary
21 ATTRIBUTE_UNUSED.
22 (bfinfdpic_link_omit_section_dynsym): Likewise.
23 (elf32_bfinfdpic_finish_dynamic_sections): Likewise.
24
2468f9c9
PB
252009-05-05 Paul Brook <paul@codesourcery.com>
26
27 * bfd-in.h (elf32_arm_fix_exidx_coverage): Add prototype.
28 * bfd-in2.h: Regenerate.
29 * elf32-arm.c (arm_unwind_edit_type, arm_unwind_table_edit): Define.
30 (_arm_elf_section_data): Add text and exidx fields.
31 (add_unwind_table_edit, get_arm_elf_section_data, adjust_exidx_size,
32 insert_cantunwind_after, elf32_arm_fix_exidx_coverage, offset_prel31,
33 copy_exidx_entry): New functions.
34 (elf32_arm_write_section): Fixup .ARM.exidx contents.
35
738a79f6
CL
362009-05-05 Christophe lyon <christophe.lyon@st.com>
37
38 * elf32-arm.c (DEF_STUBS): New helper define.
39 (DEF_STUB): Likewise.
40 (stub_def): New type.
41 (stub_definitions): New array, containing stub template pointers
42 and sizes.
43 (arm_size_one_stub): Make use of stub_definitions.
44
09e2aba4
DK
452009-05-04 Dave Korn <dave.korn.cygwin@gmail.com>
46
47 * elflink.c (find_version_for_sym): Remove from here, ...
48 * linker.c (bfd_find_version_for_sym): ... rename, replace
49 here, make public and update all callers.
50 * bfd-in2.h: Regenerate.
51
d8045f23
NC
522009-04-30 Nick Clifton <nickc@redhat.com>
53
54 * elf-bfd.h (struct bfd_elf_section_data): Add indirect_relocs
55 section pointer.
56 (struct elf_obj_data): Add has_ifunc_symbols boolean.
57 * elf.c (swap_out_syms): Convert BSF_GNU_INDIRECT_FUNCTION flags
58 into a STT_GNU_IFUNC symbol type.
59 (_bfd_elf_is_function_type): Accept STT_GNU_IFUNC as a function
60 type.
61 (_bfd_elf_set_osabi): Set the osasbi field to ELFOSABI_LINUX if
62 the binary contains ifunc symbols.
63 * elfcode.h (elf_slurp_symbol_table): Translate the STT_GNU_IFUNC
64 symbol type into a BSF_GNU_INDIRECT_FUNCTION flag.
65 * elf32-i386.c (is_indirect_function): New function.
66 (elf_i386_check_relocs): Create an ifunc output section.
67 (allocate_dynrelocs): Create dynamic relocs in the ifunc output
68 section if necessary.
69 (elf_i386_relocate_section): Emit a reloc against an ifunc symbol
70 if necessary.
71 (elf_i386_add_symbol_hook): New function. Set the
72 has_ifunc_symbols field of the elf_obj_data structure if an ifunc
73 symbol is encountered.
74 (elf_backend_post_process_headers): Define.
75 (elf_backend_add_symbol_hook): Define.
76 (elf_i386_post_process_headers): Rename to
77 elf_i388_fbsd_post_process_headers.
78 * elf64-x86_64.c (IS_X86_64_PCREL_TYPE): New macro.
79 (is_indirect_function): New function.
80 (elf64_x86_64_check_relocs): Create an ifunc output section.
81 (allocate_dynrelocs): Create dynamic relocs in the ifunc output
82 section if necessary.
83 (elf64_x86_64_relocate_section): Emit a reloc against an ifunc
84 symbol if necessary.
85 (elf_i386_add_symbol_hook): Set the has_ifunc_symbols field of the
86 elf_obj_data structure if an ifunc symbol is encountered.
87 (elf_backend_post_process_headers): Define.
88 * elflink.c (_bfd_elf_adjust_dynamic_symbol): Always create a PLT
89 if we have ifunc symbols to handle.
90 (get_ifunc_reloc_section_name): New function. Computes the name
91 for an ifunc section.
92 (_bfd_elf_make_ifunc_reloc_section): New function. Creates a
93 section to hold ifunc relocs.
94 * syms.c (BSF_GNU_INDIRECT_FUNCTION): Define.
95 (bfd_print_symbol_vandf): Handle ifunc symbols.
96 (bfd_decode_symclass): Likewise.
97 * bfd-in2.h: Regenerate.
98
96c23d59
JM
992009-04-30 Joseph Myers <joseph@codesourcery.com>
100
101 * elf32-arm.c (elf32_arm_check_relocs): Give errors for absolute
102 MOVW and MOVT relocations in a shared library link.
103
c067354b
NC
1042009-04-27 Anthony Green <green@moxielogic.com>
105
106 * verilog.c: New file.
107 * Makefile.am (BFD32_LIBS): Add verilog.c.
108 (BFD32_LIBS_CFILES): Add verilog.c.
109 (verilog.lo): New build rule.
110 * Makefile.in: Rebuilt.
111 * targets.c: Add verilog support.
112 * bfd.c (tdata union): Add Verilog private data field.
113 * bfd-in2.h: Regenerate.
114
325c681d
L
1152009-04-27 H.J. Lu <hongjiu.lu@intel.com>
116
117 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Don't
118 copy pe_opthdr.
119
ba775898
DK
1202009-04-23 Matthias Klose <doko@ubuntu.com>
121
2e28a5fc 122 * peXXigen.c (_bfd_XXi_swap_sym_in): Initialize `name'.
ba775898 123
155d87d7
CL
1242009-04-22 Christophe Lyon <christophe.lyon@st.com>
125
126 PR9743
127 * elf32-arm.c (arm_type_of_stub): Handle R_ARM_THM_JUMP24,
128 R_ARM_JUMP24 and R_ARM_PLT32 relocations.
129 (elf32_arm_size_stubs): Likewise.
130 (record_thumb_to_arm_glue): Deleted unused function.
131 (bfd_elf32_arm_process_before_allocation): No longer handle
132 R_ARM_THM_JUMP24, R_ARM_JUMP24 and R_ARM_PLT32 relocations here.
133 (elf32_arm_final_link_relocate): Handle R_ARM_THM_JUMP24,
134 R_ARM_JUMP24 and R_ARM_PLT32 relocations.
135
3e6b1042
DJ
1362009-04-21 Daniel Jacobowitz <dan@codesourcery.com>
137
138 * elf32-arm.c (INTERWORK_FLAG): Check BFD_LINKER_CREATED.
139 (elf32_arm_write_section): Declare early.
140 (elf32_arm_size_stubs): Skip non-stub sections in the stub BFD.
141 (arm_allocate_glue_section_space): Exclude empty sections.
142 (ARM_GLUE_SECTION_FLAGS): Add SEC_LINKER_CREATED.
143 (bfd_elf32_arm_add_glue_sections_to_bfd): Do not skip the stub
144 BFD.
145 (elf32_arm_output_glue_section, elf32_arm_final_link): New.
146 (elf32_arm_merge_eabi_attributes): Skip the stub BFD.
147 (elf32_arm_size_dynamic_sections): Allocate interworking
148 sections here.
149 (bfd_elf32_bfd_final_link): Define.
150
4f360784
L
1512009-04-21 H.J. Lu <hongjiu.lu@intel.com>
152
153 * coff-ia64.c (COFF_PAGE_SIZE): Changed to 8K.
154
155 * coffcode.h (coff_compute_section_file_positions): Clear
156 D_PAGED if PE section alignment is smaller than COFF_PAGE_SIZE.
157
158 * libcoff-in.h (pe_tdata): Remove force_minimum_alignment and
159 force_minimum_alignment.
160
161 * libcoff.h: Regenerated.
162
163 * pei-ia64.c (PEI_TARGET_SUBSYSTEM): Removed.
164 (PEI_FORCE_MINIMUM_ALIGNMENT): Likewise.
165
166 * peicode.h (pe_mkobject): Don't set force_minimum_alignment
167 nor target_subsystem.
168
169 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Don't check
170 force_minimum_alignment nor target_subsystem.
171
e48570bb
DK
1722009-04-21 Kai Tietz <kai.tietz@onevision.com>
173
174 * coff-x86_64.c (PEI_HEADERS): Protect includes.
175 (bfd_pe_print_pdata): Remove #ifdef PE variation.
176 * pei-x86_64.c (PEI_HEADERS): Define to prevent double
177 include in coff-x86_64.c of headers.
178 (PDATA_ROW_SIZE): New define.
179 (pex_regs[]): New static array.
180 (pex64_get_runtime_function): New static function.
181 (pex64_get_unwind_info): Likewise.
182 (pex64_get_scope_entry): Likewise.
183 (pex64_xdata_print_uwd_codes): Likewise.
184 (pex64_get_section_by_rva): Likewise.
185 (pex64_dump_xdata): Likewise.
186 (pex64_bfd_print_pdata): Likewise.
187 (bfd_pe_print_pdata): Define as pex64_bfd_print_pdata.
188 * peXXigen.c (_bfd_pex64_print_pdata): Removed implementation.
189 * libpei.h (_bfd_pex64_print_pdata): Removed declaration.
190
383c383f 1912009-04-19 Peter O'Gorman <binutils@mlists.thewrittenword.com>
4f360784
L
192 Alan Modra <amodra@bigpond.net.au>
193 Dave Korn <dave.korn.cygwin@gmail.com>
383c383f
AM
194
195 * peXXigen.c (_bfd_XXi_swap_sym_in): Fix name handling w.r.t
196 long names and non-NUL-terminated strings.
197
b6b450f1
L
1982009-04-17 H.J. Lu <hongjiu.lu@intel.com>
199
200 * bfd-in2.h: Regenerated.
201
d9118602
L
2022009-04-17 H.J. Lu <hongjiu.lu@intel.com>
203
204 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Replace
205 IMAGE_SUBSYSTEM_EFI_ROM with IMAGE_SUBSYSTEM_SAL_RUNTIME_DRIVER.
206
92dd4511
L
2072009-04-17 H.J. Lu <hongjiu.lu@intel.com>
208
209 PR binutils/10074
210 * coffcode.h (bfd_pei_p): New.
211
212 * config.bfd: Remove bfd_efi_bsdrv_ia32_vec,
213 bfd_efi_rtdrv_ia32_vec, bfd_efi_bsdrv_x86_64_vec,
214 bfd_efi_rtdrv_x86_64_vec, bfd_efi_bsdrv_ia64_vec and
215 bfd_efi_rtdrv_ia64_vec. Replace bfd_efi_app_ia32_vec,
216 bfd_efi_app_x86_64_vec and bfd_efi_app_ia64_vec with
217 i386pei_vec, x86_64pei_vec and bfd_pei_ia64_vec, respectively.
218
219 * configure.in: Remove bfd_efi_bsdrv_ia32_vec,
220 bfd_efi_rtdrv_ia32_vec, bfd_efi_bsdrv_x86_64_vec,
221 bfd_efi_rtdrv_x86_64_vec,
222 bfd_efi_bsdrv_ia64_vec and bfd_efi_rtdrv_ia64_vec. Replace
223 bfd_efi_ia64_vec with bfd_pei_ia64_vec.
224 * targets.c: Likewise.
225
226 * configure: Regenerated.
227 * libcoff.h: Likewise.
228 * Makefile.in: Likewise.
229
230 * efi-app-ia32.c: Removed.
231 * efi-app-x86_64.c: Likewise.
232 * efi-bsdrv-ia32.c: Likewise.
233 * efi-bsdrv-ia64.c: Likewise.
234 * efi-bsdrv-x86_64.c: Likewise.
235 * efi-rtdrv-ia32.c: Likewise.
236 * efi-rtdrv-ia64.c: Likewise.
237 * efi-rtdrv-x86_64.c: Likewise.
238 * efi-rtdrv-ia32.c: Likewise.
239
240 * efi-app-ia64.c: Moved to ...
241 * pei-ia64.c: This.
242 (TARGET_SYM): Set to bfd_pei_ia64_vec.
243 (TARGET_NAME): Set to pei-ia64.
244
245 * libpei.h (bfd_target_pei_p): Removed.
246 (bfd_target_pei_arch): Likewise.
247 (bfd_target_efi_app_p): Likewise.
248 (bfd_target_efi_app_arch): Likewise.
249 (bfd_target_efi_bsdrv_p): Likewise.
250 (bfd_target_efi_bsdrv_arch): Likewise.
251 (bfd_target_efi_rtdrv_p): Likewise.
252 (bfd_target_efi_rtdrv_arch): Likewise.
253 (bfd_pe_executable_p): Likewise.
254
255 * Makefile.am (BFD32_BACKENDS): Remove efi-app-ia32.lo,
256 efi-bsdrv-ia32.lo and efi-rtdrv-ia32.lo.
257 (BFD32_BACKENDS_CFILES): Remove efi-app-ia32.c, efi-bsdrv-ia32.c
258 and efi-rtdrv-ia32.c.
259 (BFD64_BACKENDS): Remove efi-app-ia64.lo, efi-bsdrv-ia64.lo,
260 efi-rtdrv-ia64.lo, efi-app-x86_64.lo, efi-bsdrv-x86_64.lo and
261 efi-rtdrv-x86_64.lo. Add pei-ia64.lo.
262 (BFD64_BACKENDS_CFILES): Remove efi-app-ia64.c, efi-bsdrv-ia64.c,
263 efi-rtdrv-ia64.c, efi-app-x86_64.c, efi-bsdrv-x86_64.c and
264 efi-rtdrv-x86_64.c. Add pei-ia64.c.
265 (efi-app-ia64.lo): Removed.
266 (efi-bsdrv-ia32.lo): Likewise.
267 (efi-rtdrv-ia32.lo): Likewise.
268 (efi-app-ia64.lo): Likewise.
269 (efi-bsdrv-ia64.lo): Likewise.
270 (efi-rtdrv-ia64.lo): Likewise.
271 (efi-app-x86_64.lo): Likewise.
272 (efi-bsdrv-x86_64.lo): Likewise.
273 (efi-rtdrv-x86_64.lo): Likewise.
274 (pei-ia64.lo): New.
275
276 * peicode.h (coff_swap_scnhdr_in): Replace bfd_pe_executable_p
277 with bfd_pei_p.
278 (arch_type): Removed.
279 (pe_arch): Likewise.
280 (pe_bfd_object_p): Just return coff_object_p.
281
282 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Replace
283 bfd_pe_executable_p with bfd_pei_p.
284
69c5861e
CL
2852009-04-17 Christophe Lyon <christophe.lyon@st.com>
286
287 * elf32-arm.c (elf32_arm_size_stubs): Handle long branches through
288 PLT entries to an undefined symbol when generating a shared
289 library.
290
e9cd0660
NC
2912009-04-17 Nick Clifton <nickc@redhat.com>
292
293 PR 9909
294 * coffcode.h (handle_COMDAT): Allow for external COMDAT symbols.
295
3023e3f6
RS
2962009-04-16 Richard Sandiford <r.sandiford@uk.ibm.com>
297
298 * aout-adobe.c (aout_32_bfd_define_common_symbol): Define.
299 * aout-target.h (MY_bfd_define_common_symbol): Likewise.
300 * aout-tic30.c (MY_bfd_define_common_symbol): Likewise.
301 * binary.c (binary_bfd_define_common_symbol): Likewise.
302 * bout.c (b_out_bfd_define_common_symbol): Likewise.
303 * coff-alpha.c (_bfd_ecoff_bfd_define_common_symbol): Likewise.
304 * coff-mips.c (_bfd_ecoff_bfd_define_common_symbol): Likewise.
305 * coffcode.h (coff_bfd_define_common_symbol): Likewise.
306 * elfxx-target.h (bfd_elfNN_bfd_define_common_symbol): Likewise.
307 * i386msdos.c (msdos_bfd_define_common_symbol): Likewise.
308 * i386os9k.c (os9k_bfd_define_common_symbol): Likewise.
309 * ieee.c (ieee_bfd_define_common_symbol): Likewise.
310 * ihex.c (ihex_bfd_define_common_symbol): Likewise.
311 * libbfd-in.h (_bfd_nolink_bfd_define_common_symbol): Likewise.
312 * mach-o.c (bfd_mach_o_bfd_define_common_symbol): Likewise.
313 * mmo.c (mmo_bfd_define_common_symbol): Likewise.
314 * nlm-target.h (nlm_bfd_define_common_symbol): Likewise.
315 * oasys.c (oasys_bfd_define_common_symbol): Likewise.
316 * pef.c (bfd_pef_bfd_define_common_symbol): Likewise.
317 * ppcboot.c (ppcboot_bfd_define_common_symbol): Likewise.
318 * som.c (som_bfd_define_common_symbol): Likewise.
319 * srec.c (srec_bfd_define_common_symbol): Likewise.
320 * tekhex.c (tekhex_bfd_define_common_symbol): Likewise.
321 * versados.c (versados_bfd_define_common_symbol): Likewise.
322 * vms.c (vms_bfd_define_common_symbol): Likewise.
323 * xcoff-target.h (_bfd_xcoff_bfd_define_common_symbol): Likewise.
324 * xsym.c (bfd_sym_bfd_define_common_symbol): Likewise.
325 * coff-rs6000.c (rs6000coff_vec): Add _bfd_xcoff_define_common_symbol.
326 (pmac_xcoff_vec): Likewise.
327 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
328 (aix5coff64_vec): Likewise.
329 * linker.c (bfd_generic_define_common_symbol): New function.
330 * targets.c (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_define_common_symbol.
331 (_bfd_define_common_symbol): New field.
332 * libcoff-in.h (_bfd_xcoff_define_common_symbol): Declare.
333 * xcofflink.c (_bfd_xcoff_define_common_symbol): New function.
334 (xcoff_build_ldsyms): Don't set XCOFF_DEF_REGULAR for common
335 symbols here.
336 * bfd-in2.h: Regenerate.
337 * libbfd.h: Likewise.
338 * libcoff.h: Likewise.
339
20135e4c
NC
3402009-04-15 Anthony Green <green@moxielogic.com>
341
342 * targets.c: Add moxie support.
343 * Makefile.am: Ditto.
344 * Makefile.in: Rebuilt.
345 * cpu-moxie.c, elf32-moxie.c: New files.
346 * archures.c: Add moxie support.
347 * configure.in: Add moxie support.
348 * configure: Rebuilt.
349 * config.bfd, archures.c: Add moxie support.
350 * bfd-in2.h: Rebuilt.
351
82b5c97a
CL
3522009-04-15 Christophe Lyon <christophe.lyon@st.com>
353
354 * elf32-arm.c (elf32_arm_final_link_relocate): Don't convert ARM
355 branch to an undef weak symbol into a jump to next instruction if
356 a PLT entry will be created.
357
0408dee6
DK
3582009-04-14 Dave Korn <dave.korn.cygwin@gmail.com>
359
360 * coffgen.c (make_a_section_from_file): Set the backend long
361 section names enable if long section names found on input.
362 * coffcode.h: Extend long section names documentation to match.
363
a0c402a5
L
3642009-04-08 H.J. Lu <hongjiu.lu@intel.com>
365
366 * elflink.c (elf_link_add_object_symbols): Warn alternate ELF
367 machine code.
368
4d28413b
DD
3692009-04-07 DJ Delorie <dj@redhat.com>
370
371 * archures.c: Add bfd_mach_mep_c5.
372 * bfd-in2.h: Likewise.
373 * cpu-mep.c: Add bfd_c5_arch.
374 * elf32-mep.c: Support it.
375
bb6198d2
L
3762009-04-07 H.J. Lu <hongjiu.lu@intel.com>
377
378 * elflink.c (_bfd_elf_section_already_linked): Add `\n' for
379 info->callbacks->einfo.
380 * linker.c (_bfd_generic_section_already_linked): Likewise.
381
bcb012d3
DD
3822009-04-06 DJ Delorie <dj@redhat.com>
383
384 * elf32-h8300.c (elf32_h8_relax_section): Relax MOVA opcodes.
385
db1fe6e9
L
3862009-04-06 H.J. Lu <hongjiu.lu@intel.com>
387
388 * coff-x86_64.c (bfd_pe_print_pdata): Defined to
389 _bfd_pex64_print_pdata only if PE is defined.
390
391 * libpei.h (_bfd_pep_print_x64_pdata): Renamed to ...
392 (_bfd_pex64_print_pdata): This.
393
394 * peXXigen.c (_bfd_pep_print_x64_pdata): Renamed to ...
395 (_bfd_pex64_print_pdata): This. Defined only if COFF_WITH_pex64
396 is defined.
397
c7c7219d
KT
3982009-04-05 Kai Tietz <kai.tietz@onevision.com>
399
400 * coff-x86_64.c (bfd_pe_print_pdata): Define as
401 _bfd_pep_print_x64_pdata.
402 * libpei.h (_bfd_pep_print_x64_pdata): Add prototype.
403 * peXXigen.c (_bfd_pep_print_x64_pdata): New.
404
3df502ae
SA
4052009-04-02 Sterling Augustine <sterling@jaw.hq.tensilica.com>
406
407 * elf32-xtensa.c (relax_property_section): Always set r_offset
408 to zero.
409
d3626fb0
CL
4102009-04-02 Christophe Lyon <christophe.lyon@st.com>
411
412 * elf32-arm.c (elf32_arm_stub_long_branch_v4t_thumb_thumb,
413 elf32_arm_stub_long_branch_v4t_thumb_thumb_pic): Two new long
414 branch stubs.
415 (elf32_arm_stub_type): New enum values for the two new stubs.
416 (arm_type_of_stub): Make use of the two new stubs.
417 (arm_size_one_stub): Handle the two new stubs.
418
fe723c87
MT
4192009-04-01 Matt Thomas <matt@netbsd.org>
420
421 * elf32-vax.c (elf_vax_check_relocs): Do not put relocations against
422 hidden symbols into the GOT or PLT.GOT.
423 (elf_vax_relocate_section): Do not emit a PCREL reloc
424 into a shared object if it is against a hidden symbol.
425
ee698300
RS
4262009-04-01 Richard Sandiford <r.sandiford@uk.ibm.com>
427
428 * xcofflink.c (xcoff_archive_info): Add contains_shared_object_p
429 and know_contains_shared_object_p.
430 (xcoff_archive_contains_shared_object_p): Add an "info" parameter.
431 Cache the result in the archive_info table.
432 (xcoff_auto_export_p): Add an "info" parameter and update the
433 call to xcoff_archive_contains_shared_object_p.
434 (xcoff_mark_auto_exports): Update accordingly.
435 (xcoff_post_gc_symbol): Likewise.
436
54e2dbe0
RS
4372009-04-01 Richard Sandiford <r.sandiford@uk.ibm.com>
438
439 * xcofflink.c (bfd_link_input_bfd): Treat __rtinit as C_HIDEXT
440 rather than C_EXT.
441
2e470849
RS
4422009-04-01 Richard Sandiford <r.sandiford@uk.ibm.com>
443
444 * coff-rs6000.c (member_layout): New structure.
445 (archive_iterator): Likewise.
446 (member_layout_init): New function.
447 (archive_iterator_begin): Likewise.
448 (archive_iterator_next): Likewise.
449 (xcoff_write_armap_old): Use the new iterator functions.
450 (do_shared_object_padding): Delete.
451 (xcoff_write_armap_big): Use the new iterator functions. Simplify
452 handling of arch_info.
453 (xcoff_write_archive_contents_old): Allocate arelt_data in the
454 first loop rather than the second. Allocate a member header if
455 there isn't one, then work out the stat information and length
456 in the first loop too. Use the new iterators for the second loop.
457 (xcoff_write_archive_contents_big): Likewise.
458
24c611d1
RS
4592009-04-01 Richard Sandiford <r.sandiford@uk.ibm.com>
460
461 * bfd-in.h (bfd_xcoff_split_import_path): Declare.
462 (bfd_xcoff_set_archive_import_path): Likewise.
463 * bfd-in2.h: Regenerate.
464 * xcofflink.c: Include libiberty.h.
465 (xcoff_archive_info): New structure.
466 (xcoff_archive_info_hash): New function.
467 (xcoff_archive_info_eq): Likewise.
468 (xcoff_get_archive_info): Likewise.
469 (_bfd_xcoff_bfd_link_hash_table_create): Initialize archive_info.
470 (bfd_xcoff_split_import_path): New function.
471 (bfd_xcoff_set_archive_import_path): Likewise.
472 (xcoff_set_import_path): Move earlier in file.
473 (xcoff_link_add_dynamic_symbols): Set the import path of a non-archive
474 object to the the directory part of the bfd's filename. Get the
475 import path and filename of an archive object from the archive's
476 xcoff_tdata, initializing it if necessary. Update use of
477 import_file_id.
478 (bfd_link_input_bfd): Update use of import_file_id.
479 (xcoff_write_global_symbol): Likewise.
480
d286971a
RS
4812009-04-01 Richard Sandiford <r.sandiford@uk.ibm.com>
482
483 * xcofflink.c (xcoff_link_hash_table): Moved from include/coff/xcoff.h.
484
4852009-04-01 Richard Sandiford <r.sandiford@uk.ibm.com>
486
487 * xcofflink.c (xcoff_link_create_extra_sections): Don't create
488 a .loader section for relocatable links.
489 (xcoff_need_ldrel_p): New function.
490 (xcoff_mark): Use it.
491 (bfd_xcoff_link_count_reloc): Only count loader relocs if there's
492 a loader section.
493 (xcoff_build_ldsym): New function, split out from...
494 (xcoff_build_ldsyms): ...here. Rename to...
495 (xcoff_post_gc_symbol): ...this. Only export symbols, and only
496 call xcoff_build_ldsym, if there's a loader section.
497 (xcoff_build_loader_section): New function, extracted verbatim from...
498 (bfd_xcoff_size_dynamic_sections): ...here. Only call it if
499 there's a loader section. Only add an __rtinit loader symbol
500 if there's a loader section. Update after above name change.
501 (xcoff_symbol_section, xcoff_create_ldrel): New functions.
502 (bfd_link_input_bfd): Use xcoff_need_ldrel_p, xcoff_symbol_section
503 and xcoff_create_ldrel.
504 (xcoff_write_global_symbol): Use xcoff_create_ldrel.
505 (xcoff_reloc_link_order): Likewise, but only call it if there's
506 a loader section. Use xcoff_symbol_section.
507 (_bfd_xcoff_bfd_final_link): Only use fdinfo.ldrel and fdinfo.ldsym
508 if there's a loader section.
509
8707bb87
RS
5102009-04-01 Richard Sandiford <rdsandiford@googlemail.com>
511
512 * xcofflink.c (bfd_link_input_bfd): Fix buffer overrun.
513
e780aef2
CL
5142009-04-01 Christophe Lyon <christophe.lyon@st.com>
515
516 * elf32-arm.c (group_sections): Rewrite loops for better
517 readability.
518
c301e700
DD
5192009-03-30 DJ Delorie <dj@redhat.com>
520
521 * elflink.c (elf_link_input_bfd): Don't try to resolve complex
522 relocs when doing a relocatable link.
523
3895f852
MM
5242009-03-28 Mark Mitchell <mark@codesourcery.com>
525
526 * coff-arm.c (coff_arm_merge_private_bfd_data): Use "error:", not
527 "ERROR:", in error messages.
528 * cpu-arm.c (bfd_arm_merge_machines): Likewise.
529 * elf-attrs.c (_bfd_elf_merge_object_attributes): Likewise.
530 * elf32-arm.c (tag_cpu_arch_combine): Likewise.
531 (elf32_arm_merge_eabi_attributes): Likewise.
532 (elf32_arm_merge_private_bfd_data): Likewise.
533
ea882e87
NC
5342009-03-27 Nick Clifton <nickc@redhat.com>
535
536 * section.c (bfd_get_section_contents): Detect and handle the case
537 where a section has the SEC_IN_MEMORY flag set but no actual
538 contents allocated.
539
9433b9b1
AM
5402009-03-26 Alan Modra <amodra@bigpond.net.au>
541
542 PR 6494
543 * elf.c (copy_elf_program_header): Do not check that PT_GNU_RELRO
544 p_filesz and p_memsz are equal. Use p_memsz as the segment size.
545 (assign_file_positions_for_non_load_sections): Zap PT_GNU_RELRO
546 if we don't find matching PT_LOAD when copying.
547
dc1aa734
SR
5482009-03-25 M R Swami Reddy <MR.Swami.Reddy@nsc.com>
549
550 * elf32-crx.c (crx_elf_howto_table): Zero the src_mask field of
551 the reloc descriptions.
552
34d3d6b9
HPN
5532009-03-25 Hans-Peter Nilsson <hp@axis.com>
554
555 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GD>
556 <R_CRIS_16_GOT_GD, case R_CRIS_32_GOT_GD>: Handle COMMON symbols.
557 <case R_CRIS_16_TPREL, R_CRIS_32_TPREL>: Ditto.
558
34274ccc
L
5592009-03-24 H.J. Lu <hongjiu.lu@intel.com>
560
561 * cpu-i386.c (bfd_x86_64_arch_intel_syntax): Make it static.
562 (bfd_i386_arch_intel_syntax): Likewise.
563 (i8086_arch): Likewise.
564 (bfd_x86_64_arch): Likewise.
565
019c5a2e
HPN
5662009-03-24 Hans-Peter Nilsson <hp@axis.com>
567
6718f446
HPN
568 * elf32-cris.c (cris_elf_relocate_section): <case
569 R_CRIS_16_DTPREL, R_CRIS_32_DTPREL>: Allow use of non-local
570 symbols for non-allocated sections. Don't check whether to
571 generate R_CRIS_DTPMOD for non-allocated sections.
572 (cris_elf_gc_sweep_hook) <case R_CRIS_32_DTPREL>: Don't
573 handle relocation GC:ing if applied to non-allocated section.
574 (cris_elf_check_relocs): Similar.
575
019c5a2e
HPN
576 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GD>
577 <R_CRIS_16_GOT_GD, R_CRIS_32_GOT_GD>: Don't include the TLS size
578 when emitting a known TP offset in the GOT.
579
ffcfec52
AM
5802009-03-23 Alan Modra <amodra@bigpond.net.au>
581
582 * elf64-ppc.c (synthetic_opd): Delete.
583 (compare_symbols): Look for .opd name rather than section match.
584 (ppc64_elf_get_synthetic_symtab): Likewise.
585
c6dd29ce
AM
5862009-03-21 Alan Modra <amodra@bigpond.net.au>
587
588 * elf32-ppc.c (is_pic_glink_stub): Delete.
589 (is_nonpic_glink_stub): New function.
590 (ppc_elf_get_synthetic_symtab): Check for last non-pic stub rather
591 than first pic one.
592 (struct ppc_elf_link_hash_table <glink_pltresolve>): Comment fix.
593
8c21ca21
AK
5942009-03-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
595 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
596
597 * elf32-s390.c (elf_s390_check_relocs): Use the SYMBOL_*
4f360784 598 macros for visibilty and locality checks.
8c21ca21
AK
599 (elf_s390_adjust_dynamic_symbol): Likewise.
600 (allocate_dynrelocs): Likewise.
601 (elf_s390_relocate_section): Likewise.
602 (elf_s390_finish_dynamic_symbol): Likewise.
603 * elf64-s390.c (elf_s390_check_relocs): Likewise.
604 (elf_s390_adjust_dynamic_symbol): Likewise.
605 (allocate_dynrelocs): Likewise.
606 (elf_s390_relocate_section): Likewise.
607 (elf_s390_finish_dynamic_symbol): Likewise.
608
156621f3
KT
6092009-03-19 Kai Tietz <kai.tietz@onevision.com>
610
611 * bfd-in2.h: Regenerated.
612 * coffcode.h (sec_to_styp_flags): For pe-coff add SEC_READONLY
613 for debugging sections and map memory read/write dependent on
614 SEC_COFF_NOREAD.
615 (styp_to_sec_flags): Set SEC_COFF_NOREAD for sections
616 without memory read flags set.
617 * section.c: Add SEC_COFF_NOREAD to section flags.
618
d1fa68d3
AS
6192009-03-19 Andreas Schwab <schwab@linux-m68k.org>
620
621 * elf32-hppa.c (final_link_relocate): Cast bfd_vma values to long
622 for format string.
623
ad2adbc8
AM
6242009-03-19 Alan Modra <amodra@bigpond.net.au>
625
626 * elf32-spu.c (spu_elf_find_overlays): Separate error return from
627 "no overlays" return. If there are overlays, create overlay
628 manager entry symbols here, so that..
629 (spu_elf_build_stubs): ..we don't need to set them up here.
630 Simplify entry symbol tests.
631 * elf32-spu.h (spu_elf_find_overlays): Update prototype.
632
67cc5033
MK
6332009-03-18 Mark Kettenis <kettenis@gnu.org>
634
d1fa68d3 635 * elf.c (elfcore_grok_openbsd_procinfo)
67cc5033
MK
636 (elfcore_grok_openbsd_note): New functions.
637 (elf_parse_notes): Handle notes from OpenBSD ELF core files.
638
8d25cc3d
AM
6392009-03-18 Alan Modra <amodra@bigpond.net.au>
640
3889c459 641 * vms-hdr.c: Don't include alloca.h.
8d25cc3d
AM
642 * elf32-m68hc1x.c: Include alloca-conf.h.
643 * xsym.c: Likewise.
644 * elf64-hppa.c: Likewise. Remove existing #if's handling alloca.
645 * som.c: Likewise.
646 * Makefile.am: Run "make dep-am".
647 * Makefile.in: Regenerate.
648
a89e6478
DJ
6492009-03-17 Daniel Jacobowitz <dan@codesourcery.com>
650
651 * elf32-arm.c (elf32_arm_check_relocs): Correct symbian_p test.
652
a7e11ee1
AM
6532009-03-17 Alan Modra <amodra@bigpond.net.au>
654
655 * elf32-spu.h (struct spu_elf_params): ovly_flavour now only 1 bit.
656 Add compact_stub.
657 (emum _ovly_flavour): Delete ovly_compact, ovly_none.
658 * elf32-spu.c (struct spu_link_hash_table): Replace ovly_load and
659 ovly_return fields with ovly_entry[2]. Adjust all users.
660 (spu_elf_find_overlays): Set ovly_entry[1] from __icache_call_handler
661 when soft-icache.
662 (spu_elf_build_stubs): Likewise.
663 (ovl_stub_size): Change arg to spu_elf_params pointer. Adjust for
664 ovly_flavour changes. Update all callers.
665 (ovl_stub_size_log2): New function.
666 (build_stub): Handle compact icache stubs. Use different manager
667 entry point for stubs in non-icache area.
668 (spu_elf_size_stubs): Don't allocate space for indirect branch
669 descriptors.
670 (spu_elf_build_stubs): And don't built them.
671
607a83c9
AS
6722009-03-16 Andrew Stubbs <ams@codesourcery.com>
673
674 * dwarf2.c (read_section): Always use rawsize, if available.
675
588f62fc
AM
6762009-03-16 Alan Modra <amodra@bigpond.net.au>
677
678 * simple.c (bfd_simple_get_relocated_section_contents): Use larger
679 of rawsize and size for buffer.
680
a14c90c1
UW
6812009-03-15 Ulrich Weigand <uweigand@de.ibm.com>
682
683 * elf32-spu.c (spu_elf_check_vma): Do not reset auto_overlay
684 parameter just because fixed sections fit into local store.
685 (spu_elf_auto_overlay): Do not declare as "noreturn". Skip
686 generating overlays if fixed sections plus reserved stack
687 and heap space fit into local store.
688
30c665df
AM
6892009-03-15 Alan Modra <amodra@bigpond.net.au>
690
691 * elf32-spu.c (build_stub): Correct icache set_id.
692 (spu_elf_relocate_section): Likewise.
693
f95942a3
RS
6942009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
695
696 * xcofflink.c (xcoff_link_check_archive_element): Only free the
697 symbol table if it was created by the current call.
698
670562e9
RS
6992009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
700
701 * xcofflink.c (xcoff_build_ldsyms): Give imported descriptors
702 class XMC_DS rather than XMC_UA.
703
b64232cc
RS
7042009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
705
706 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Replace the
707 bfd_boolean export_defineds parameter with an unsigned int
708 auto_export_flags parameter.
709 * bfd-in2.h: Regenerate.
710 * xcofflink.c (xcoff_archive_contains_shared_object_p): New function,
711 split out from xcoff_build_ldsyms.
712 (xcoff_covered_by_expall_p): New function.
713 (xcoff_auto_export_p): New function, split out from xcoff_build_ldsyms
714 but with extra code to handle -bexpfull and -bexpall.
715 (xcoff_mark_auto_exports): New function.
716 (xcoff_build_ldsyms): Use xcoff_auto_export_p to decide whether
717 a function should be automatically exported.
718 (bfd_xcoff_size_dynamic_sections): Replace the export_defineds
719 parameter with an auto_export_flags parameter. Update ldinfo
720 accordingly. Use xcoff_mark_auto_exports to mark all automatically-
721 exported symbols.
722
7d504122
RS
7232009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
724
725 * xcofflink.c (xcoff_mark_symbol_by_name): New function.
726 (bfd_xcoff_size_dynamic_sections): Use it to mark the entry,
727 init and fini functions. Do garbage collection for objects
728 without an entry point too.
729
8602d4fe
RS
7302009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
731
732 * coffcode.h (coff_pointerize_aux_hook): Update CSECT_SYM_P to
733 check whether a symbol has csect information.
734 (coff_print_aux): Likewise.
735 * coff-rs6000.c (_bfd_xcoff_swap_aux_in): Handle auxillary csect
736 information for C_AIX_WEAKEXT too.
737 (_bfd_xcoff_swap_aux_out): Likewise.
738 (xcoff_reloc_type_br): Handle defweak symbols too.
739 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Handle auxillary csect
740 information for C_AIX_WEAKEXT too.
741 (_bfd_xcoff64_swap_aux_out): Likewise.
742 (xcoff64_reloc_type_br): Handle defweak symbols too.
743 * coffgen.c (coff_print_symbol): Handle auxillary function
744 information for C_AIX_WEAKEXT too.
745 * xcofflink.c (_bfd_xcoff_canonicalize_dynamic_symtab): Set BSF_WEAK
746 instead of BSF_GLOBAL if the L_WEAK flag is set.
747 (xcoff_dynamic_definition_p): New function.
748 (xcoff_link_add_dynamic_symbols): Use it to decide whether ldsym
749 defines h. Don't change h if ldsym isn't the definition. Otherwise,
750 always take the symbol class from the ldsym. Use weak bfd symbol
751 types for weak ldsyms.
752 (xcoff_link_add_symbols): Use CSECT_SYM_P and EXTERN_SYM_P.
753 Fix the check for whether a definition is from a shared object.
754 Allow redefinitions of weak symbols.
755 (xcoff_link_check_ar_symbols): Use EXTERN_SYM_P.
756 (xcoff_keep_symbol_p): Likewise.
757 (bfd_xcoff_size_dynamic_sections): Use CSECT_SYM_P.
758 (xcoff_link_input_bfd): Use CSECT_SYM_P and EXTERN_SYM_P.
759 Add .loader entries for C_AIX_WEAKEXT as well as C_EXT symbols,
760 but mark them as L_WEAK.
761 (xcoff_write_global_symbol): Treat weak symbols as C_AIX_WEAKEXT
762 instead of C_EXT if C_AIX_WEAKEXT == C_WEAKEXT.
763
5b49f6dc
RS
7642009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
765
766 * xcofflink.c (xcoff_mark): When walking the relocations,
767 only mark the target symbol or the target section, not both.
768 (xcoff_final_definition_p): New function.
769 (xcoff_keep_symbol_p): Use it to check whether an external XCOFF
770 symbol is a valid definition of the associated output symbol.
771 Use XCOFF_ALLOCATED to stop the same hash table entry having
772 two output symbols.
773 (bfd_xcoff_size_dynamic_sections): Set XCOFF_ALLOCATED when
774 keeping a symbol.
775 (xcoff_link_input_bfd): Use xcoff_final_definition_p.
776
c4037431
RS
7772009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
778
779 * xcofflink.c (bfd_xcoff_import_symbol): Treat imported absolute
780 symbols as XMC_XO.
781
3df13c4a
RS
7822009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
783
784 * libcoff-in.h (xcoff_tdata): Add a lineno_counts field.
785 * libcoff.h: Regenerate.
786 * xcofflink.c (xcoff_link_add_symbols): Record per-symbol
787 line-number counts in the bfd's lineno_counts field.
788 Don't keep per-csect line-number counts.
789 (xcoff_sweep): Don't update per-csect line-number counts.
790 (bfd_xcoff_size_dynamic_sections): Count the number of line-number
791 entries in each output section.
792 (xcoff_link_input_bfd): Get the number of line numbers from
793 the bfd's lineno_counts field, rather than recalculating it
794 from scratch. Fix the range check when updating C_BINCL and
795 C_EINCL symbols.
796 (_bfd_xcoff_bfd_final_link): Don't count the output line numbers
797 here. Don't expect csects to have line-number counts.
798
e450936a
RS
7992009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
800
801 * libcoff-in.h (xcoff_tdata): Change debug_indices to a signed long.
802 * libcoff.h: Regenerate.
803 * xcofflink.c (xcoff_keep_symbol_p): New function, using the
804 "skip" logic from xcoff_link_input_bfd.
805 (bfd_xcoff_size_dynamic_sections): Explicitly skip dynamic
806 objects in a dynamic link, rather than checking whether csectpp
807 is null. Always allocate debug_index for other objects,
808 and always go through the loop. Update the type of debug_index
809 after the change above. Read the auxillary csect information
810 and use xcoff_keep_symbol_p to decide whether a symbol should
811 be kept. Set its debug_index to -2 if not.
812 (xcoff_link_input_bfd): Update the type of debug_index after
813 the change above and always expect it to be nonnull. Use it to
814 test whether a symbol should be stripped, rather than making the
815 decision here. Postpone all symbol creation to the second pass.
816
47dfb2ca
RS
8172009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
818
819 * xcofflink.c: (xcoff_mark_symbol): Mark the TOC section when
820 creating a descriptor.
821 (xcoff_sweep): Don't mark toc_section unless it's needed.
822 (bfd_xcoff_size_dynamic_sections): Skip the toc_section
823 when marking every bfd.
824 (xcoff_link_input_bfd): Skip all TOC anchors.
825 (xcoff_toc_section_p, xcoff_find_tc0): New functions.
826 (_bfd_xcoff_bfd_final_link): Don't set the output bfd's TOC anchor
827 to -1; call xcoff_find_tc0 instead.
828
4cc02a02
RS
8292009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
830
831 * libcoff-in.h (xcoff_section_tdata): Update commentary.
832 * libcoff.h: Regenerate.
833 * xcofflink.c (xcoff_link_add_symbols): Set the csect of XTY_ER
834 symbols to bfd_und_section_ptr or bfd_abs_section_ptr, rather than
835 the previous symbol's csect. Treat last_symndx as an inclusive value
836 and simplify its handling.
837 (xcoff_mark): Treat last_symndx as an inclusive value. Only mark
838 symbols with the right csect. Don't mark rsec when processing
d1fa68d3 839 relocations against undefined or absolute sections.
4cc02a02
RS
840 (bfd_xcoff_size_dynamic_sections): Don't check the SEC_MARK flag
841 of bfd_und_section_ptr.
842 (xcoff_link_input_bfd): Likewise.
843
858ef0ce
RS
8442009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
845
846 * coff-rs6000.c (xcoff_ppc_relocate_section): Report relocations
847 against undefined symbols if the symbol's XCOFF_WAS_UNDEFINED
848 flag is set. Assert that all undefined symbols are either
849 imported or defined by a dynamic object.
850 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Likewise.
851 * xcofflink.c (xcoff_link_add_symbols): Extend function-symbol
852 handling to all relocations. Only set XCOFF_CALLED for function
853 symbols.
854 (xcoff_find_function): New function, split out from...
855 (bfd_xcoff_export_symbol) ...here.
856 (xcoff_set_import_path): New function, split out from...
857 (bfd_xcoff_import_symbol): ...here. Remove assertion for old
858 meaning of XCOFF_CALLED.
859 (xcoff_mark_symbol): If we mark an undefined and unimported
860 symbol, find some way of defining it. If the symbol is a function
861 descriptor, fill in its definition automatically. If the symbol
862 is a function, mark its descriptor and allocate room for global
863 linkage code. Otherwise mark the symbol as implicitly imported.
864 Move the code for creating function descriptors from...
d1fa68d3 865 (xcoff_build_ldsyms): ...here. Use XCOFF_WAS_UNDEFINED to
858ef0ce
RS
866 check for symbols that were implicitly defined.
867 (xcoff_mark): Don't count any dynamic relocations against
868 function symbols.
869 (bfd_xcoff_size_dynamic_sections): Save the rtld parameter
870 in the xcoff link info.
871 (xcoff_link_input_bfd): Remove handling of undefined and
872 unexported symbols.
873
12b2cce9
RS
8742009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
875
876 * coff-rs6000.c (xcoff_reloc_type_br): Make the branch absolute
877 if the target is absolute. Fix comment typo.
878 (xcoff_ppc_relocate_section): Remove FIXME.
879 * coff64-rs6000.c (xcoff64_reloc_type_br): Make the branch absolute
880 if the target is absolute.
881
0e3212ad
RS
8822009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
883
884 * xcofflink.c (xcoff_mark, xcoff_link_input_bfd): Don't copy
885 R_POS and R_NEG relocations against absolute symbols to the
886 .loader section.
887
d19d97e9
RS
8882009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
889
890 * coff64-rs6000.c (xcoff64_write_object_contents): Set the cputype
891 to 2 for bfd_mach_ppc_620.
892
e5231592
RS
8932009-03-14 Richard Sandiford <r.sandiford@uk.ibm.com>
894
895 * config.bfd: Treat AIX 6+ in the same way as AIX 5.
896 * configure.in: Likewise.
897 * configure: Regenerate.
898
3516e984
L
8992009-03-13 H.J. Lu <hongjiu.lu@intel.com>
900
901 PR binutils/9945
902 * elf.c (assign_section_numbers): Generate symbol table if there
903 is any relocation in output.
904 (_bfd_elf_compute_section_file_positions): Likewise.
905
ce98a316
NC
9062009-03-13 Nick Clifton <nickc@redhat.com>
907
908 PR 9934
909 * elf-bfd.h (NUM_SHDR_ENTRIES): Cope with an empty section.
910 * elflink.c (elf_link_read_relocs_from_section): Use
911 NUM_SHDR_ENTRIES. Gracefully handle the case where there are
912 relocs but no symbol table.
913 * elf32-arm.c (elf32_arm_check_relocs): Likewise.
914
c4fb387b
L
9152009-03-12 H.J. Lu <hongjiu.lu@intel.com>
916
917 PR ld/9938
918 * elf32-i386.c (elf_i386_check_tls_transition): Use strncmp
919 to check ___tls_get_addr.
920
921 * elf64-x86-64.c (elf64_x86_64_check_tls_transition): Use
922 strncmp to check __tls_get_addr.
923
53638231
AS
9242009-03-12 Andrew Stubbs <ams@codesourcery.com>
925
926 * dwarf2.c (read_section): Always check the offset, even when the
927 section has been read before.
928
09e8c3bf
L
9292009-03-11 H.J. Lu <hongjiu.lu@intel.com>
930
931 * elf32-i386.c (elf_i386_check_tls_transition): Fix a typo in
932 comments.
933
36e4dce6
CD
9342009-03-11 Chris Demetriou <cgd@google.com>
935
936 * bfd.c (BFD_DETERMINISTIC_OUTPUT): New flag.
937 * bfd-in2.h: Regenerate.
938 * archive.c (bfd_ar_hdr_from_filesystem): If BFD_DETERMINISTIC_OUTPUT
939 flag is set, use 0 for uid, gid, and timestamp, and use 0644 for file
940 mode.
941 (bsd_write_armap): Likewise.
942 (_bfd_archive_bsd_update_armap_timestamp): If BFD_DETERMINISTIC_OUTPUT
943 flag is set, do nothing.
944 (coff_write_armap): If BFD_DETERMINISTIC_OUTPUT flag is set, use 0
945 for timestamp.
946
9b175a76
UW
9472009-03-11 Ulrich Weigand <uweigand@de.ibm.com>
948
949 * elf32-spu.c (find_function_stack_adjust): Handle sf instruction
950 used to update stack pointer.
951
f501de17
DA
9522009-03-07 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
953
954 PR binutils/9921
955 * som.c (som_bfd_derive_misc_symbol_info): Set symbol type ST_ABSOLUTE
956 for unknown symbols in absolute section.
957
d11fd249
NC
9582009-03-06 Nick Clifton <nickc@redhat.com>
959
960 * po/es.po: Updated Spanish translation.
961
8cd931b7
CL
9622009-03-05 Christophe Lyon <christophe.lyon@st.com>
963
964 * elf32-arm.c (group_sections): Take next section size into
965 account before accepting to group it.
966
5fa9e92f
CL
9672009-03-05 Christophe Lyon <christophe.lyon@st.com>
968
969 * elf32-arm.c (arm_type_of_stub): Handle long branches targetting
970 PLT entries.
971 (elf32_arm_final_link_relocate): Likewise.
972
b92997d6
AM
9732009-03-05 Moritz Kroll <Moritz.Kroll@gmx.de>
974
975 PR 9923
976 * peXXigen.c (_bfd_XXi_final_link_postscript): Check h->root.type.
977
727fc41e
AM
9782009-03-04 Alan Modra <amodra@bigpond.net.au>
979
980 * reloc.c (BFD_RELOC_PPC_TLSGD, BFD_RELOC_PPC_TLSLD): New.
981 * section.c (struct bfd_section): Add has_tls_get_addr_call.
982 (BFD_FAKE_SECTION): Init new flag.
983 * ecoff.c (bfd_debug_section): Likewise.
984 * bfd-in2.h: Regenerate.
985 * libbfd.h: Regenerate.
986 * elf32-ppc.c (ppc_elf_howto_raw): Add R_PPC_TLSGD and R_PPC_TLSLD.
987 (ppc_elf_reloc_type_lookup): Handle new relocs.
988 (ppc_elf_check_relocs): Set has_tls_get_addr_call on finding such
989 without marker relocs.
990 (ppc_elf_tls_optimize): Allow out-of-order __tls_get_addr relocs
991 if section has no old-style calls.
992 (ppc_elf_relocate_section): Set tls_mask for non-tls relocs too.
993 Don't try to optimize new-style __tls_get_addr call when handling
994 arg setup relocs. Instead do so for R_PPC_TLSGD and R_PPC_TLSLD
995 relocs.
996 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_TLSGD, R_PPC64_TLSLD.
997 (ppc64_elf_reloc_type_lookup): Handle new relocs.
998 (ppc64_elf_check_relocs): Set has_tls_get_addr_call on finding such
999 without marker relocs.
1000 (ppc64_elf_tls_optimize): Allow out-of-order __tls_get_addr relocs
1001 if section has no old-style calls. Set toc_ref for new relocs as
1002 appropriate.
1003 (ppc64_elf_relocate_section): Set tls_mask for non-tls relocs too.
1004 Don't try to optimize new-style __tls_get_addr call when handling
1005 arg setup relocs. Instead do so for R_PPC_TLSGD and R_PPC_TLSLD
1006 relocs.
1007
51dec227
AM
10082009-03-04 Alan Modra <amodra@bigpond.net.au>
1009
1010 PR 6768
1011 * configure.in: Test for ld --as-needed support. Link shared
1012 libbfd against libm.
1013 * configure: Regenerate.
1014
a1f7ca36
AM
10152009-03-03 Alan Modra <amodra@bigpond.net.au>
1016
1017 * Makefile.am: Run "make dep-am".
1018 * Makefile.in: Regenerate.
1019
c3b7224a
NC
10202009-03-02 Qinwei <qinwei@sunnorth.com.cn>
1021
1022 * elf32-score7.c: New file.
1023 * elf32-score.h: New file.
1024 * elf32-score.c: Add code to support score 7. Set score7 as the
1025 default.
1026 * cpu-score.c: Add score7 architecure.
1027 (compatibile): New function.
1028 * Makefile.am: Add rules for building elf32-score7 object.
1029 * Makefile.in: Regenerate.
1030 * configure.in: Add elf32-score7 object to score vectors.
1031 * configure: Regenerate.
1032 * reloc.c: Add score7 relocs.
1033 * archures.c: Add score3 and score7 machine numbers.
1034 * bfd-in2.h: Regenerate.
1035 * libbfd.h: Regenerate.
1036
58e24671
RW
10372009-03-01 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1038
1039 * configure: Regenerate.
1040
5887528b
DA
10412009-03-01 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1042
d45b7d74
DA
1043 * elf32-hppa.c (hppa32_elf_local_refcounts): New function.
1044 (elf32_hppa_check_relocs): Use it.
1045
5887528b
DA
1046 * elf_hppa_add_symbol_hook (elf_hppa_add_symbol_hook): Move to
1047 elf64-hppa.c.
1048 (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
1049 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
1050 (elf_hppa_is_dynamic_loader_symbol): Likewise.
1051 (elf_hppa_record_segment_addrs): Likewise.
1052 (elf_hppa_final_link): Likewise.
1053 (elf_hppa_relocate_insn): Likewise.
1054 (elf_hppa_final_link_relocate): Likewise.
1055 (elf64_hppa_relocate_section): Likewise.
1056 * elf64-hppa.c: Insert above.
1057
a03bd320
DA
10582009-02-28 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1059
1060 * elf-hppa.h (elf_hppa_final_link): Use elf_hppa_final_link.
1061 (elf_hppa_final_link_relocate ): Rewrite eliminating dynamic hash table.
1062 (elf_hppa_relocate_section): Likewise.
1063 * elf64-hppa.c (struct elf64_hppa_link_hash_entry): Change to derive
1064 from struct elf_link_hash_entry. Add count field.
1065 (struct elf64_hppa_dyn_hash_table): Delete.
1066 (struct elf64_hppa_link_hash_table): Delete dyn_hash_table field.
1067 (elf64_hppa_hash_table): Rename to hppa_link_hash_table.
1068 (hppa_elf_hash_entry, eh_name): Define.
1069 (elf64_hppa_new_dyn_hash_entry): Delete.
1070 (elf64_hppa_dyn_hash_lookup): Delete.
1071 (elf64_hppa_dyn_hash_traverse): Delete.
1072 (get_dyn_name): Delete.
1073 (elf64_hppa_finalize_opd): Use struct elf_link_hash_entry * instead
1074 of struct elf64_hppa_dyn_hash_entry *.
1075 (elf64_hppa_finalize_dlt, llocate_global_data_dlt,
1076 allocate_global_data_plt, allocate_global_data_stub,
1077 allocate_global_data_opd, count_dyn_reloc, allocate_dynrel_entries):
1078 Likewise.
1079 (hppa64_link_hash_newfunc): New.
1080 (elf64_hppa_hash_table_create): Rework.
1081 (count_dyn_reloc): Likewise.
1082 (hppa64_elf_local_refcounts): New.
1083 (elf64_hppa_check_relocs): Rework using standard technique for recording
1084 local DLT, PLT and OPD reference counts.
1085 (elf64_hppa_dynamic_symbol_p): Revise using "eh" for struct
1086 elf_link_hash_entry *.
1087 (elf64_hppa_mark_exported_functions, allocate_global_data_dlt,
1088 allocate_global_data_plt, allocate_global_data_stub,
1089 allocate_global_data_opd, allocate_dynrel_entries,
1090 elf64_hppa_adjust_dynamic_symbol,
1091 elf64_hppa_mark_milli_and_exported_functions): Likewise.
1092 (elf64_hppa_create_dynamic_sections, elf64_hppa_size_dynamic_sections):
1093 Use hppa_link_hash_table. Rework.
1094 (elf64_hppa_link_output_symbol_hook): Rework.
1095 (elf64_hppa_finish_dynamic_symbol, elf64_hppa_finalize_opd,
1096 elf64_hppa_finalize_dlt, elf64_hppa_finalize_dynreloc,
1097 elf64_hppa_finish_dynamic_sections): Likewise.
1098
ebe24dd4
CL
10992009-02-26 Christophe Lyon <christophe.lyon@st.com>
1100
1101 * elf32-arm.c (stub_reloc_type): Removed.
1102 (insn_sequence): Renamed reloc_type field to r_type.
1103 (elf32_arm_stub_long_branch_v4t_arm_thumb_pic): New stub.
1104 (elf32_arm_stub_long_branch_v4t_thumb_arm_pic): Likewise.
1105 (elf32_arm_stub_long_branch_thumb_only_pic): Likewise.
1106 (elf32_arm_stub_type): Add new enum entries for the new stubs.
1107 (arm_stub_is_thumb): Catch new stubs.
1108 (arm_type_of_stub): Handle new stubs.
1109 (arm_size_one_stub): Use ARRAY_SIZE. Handle new stubs.
1110 (bfd_elf32_arm_process_before_allocation): Remove useless
1111 condition.
1112
b9d678e0
L
11132009-02-25 H.J. Lu <hongjiu.lu@intel.com>
1114
1115 * elf.c (elf_find_function): Use is_function_type to check
1116 function symbol.
1117
56fb3749
SA
11182009-02-24 Sterling Augustine <sterling@jaw.hq.tensilica.com>
1119
1120 * xtensa-modules.c: Revert to previous version 1.11 due
1121 to inadvertant commit.
1122
658ff993
SA
11232009-02-24 Sterling Augustine <sterling@tensilica.com>
1124
1125 * elf32-xtensa.c (text_action_add): Separate test for action
1126 type. Break if saved action is ta_widen_insn at same offset.
1127
cf3eccff
DJ
11282009-02-24 Daniel Jacobowitz <dan@codesourcery.com>
1129
1130 * elf32-arm.c (elf32_arm_stub_long_branch_any_any_pic): Rename
1131 to elf32_arm_stub_long_branch_any_arm_pic.
1132 (elf32_arm_stub_long_branch_any_thumb_pic): New.
1133 (enum elf32_arm_stub_type, arm_type_of_stub)
1134 (arm_size_one_stub): Handle any to ARM PIC and any to Thumb PIC
1135 separately.
1136
07d72278
DJ
11372009-02-24 Joseph Myers <joseph@codesourcery.com>
1138
1139 * elf32-arm.c (PREV_SEC): Update comment.
1140 (group_sections): Rename argument to stubs_always_after_branch.
1141 Reverse the list and place stubs at the end of input sections.
1142 Undefine NEXT_SEC.
1143 (elf32_arm_size_stubs): Update to use stubs_always_after_branch.
1144
4e31c731
DJ
11452009-02-23 Daniel Jacobowitz <dan@codesourcery.com>
1146
1147 * elf32-arm.c (arm_build_one_stub): Initialize stub_reloc_offset.
1148 Fix formatting.
1149 (arm_size_one_stub): Remove unnecessary break.
1150 (arm_map_one_stub): Fix formatting. Return after BFD_FAIL.
1151
11522009-02-23 Christophe Lyon <christophe.lyon@st.com>
461a49ca
DJ
1153
1154 * elf32-arm.c (stub_insn_type): New type.
1155 (stub_reloc_type): Likewise.
1156 (insn_sequence): Likewise.
1157 (elf32_arm_stub_long_branch_any_any): Encode using insn_sequence.
1158 (elf32_arm_stub_long_branch_v4t_arm_thumb): Likewise.
1159 (elf32_arm_stub_long_branch_thumb_only): Likewise.
1160 (elf32_arm_stub_long_branch_v4t_thumb_arm): Likewise.
1161 (elf32_arm_stub_short_branch_v4t_thumb_arm): Likewise.
1162 (elf32_arm_stub_long_branch_any_any_pic): Likewise.
1163 (elf32_arm_stub_hash_entry): Add new helper fields.
1164 (stub_hash_newfunc): Initialize these new fields.
1165 (arm_build_one_stub): Encode Arm and Thumb instructions separately
1166 to take endianness into account.
1167 (arm_size_one_stub): Compute size of stubs using insn_sequence.
1168 (arm_map_one_stub): Code is now more generic, thanks to
1169 insn_sequence.
1170
c2b4a39d
CL
11712009-02-23 Christophe Lyon <christophe.lyon@st.com>
1172
1173 * elf32-arm.c (elf32_arm_stub_long_branch_thumb_only): Fix stub
1174 code.
1175 (elf32_arm_stub_long_branch_v4t_thumb_arm): Likewise.
1176 (arm_type_of_stub): Use Thumb-only long branch stub (non-PIC) when
1177 BLX is not available. Fix typo in warning message. Add comments
1178 and improve formatting.
1179 (arm_build_one_stub): Adjust to new
1180 elf32_arm_stub_long_branch_v4t_thumb_arm stub.
1181 (arm_map_one_stub): Likewise.
1182
0c376465 11832009-02-23 Tristan Gingold <gingold@adacore.com>
a60a89d6
TG
1184 Eric Botcazou <ebotcazou@adacore.com>
1185 Douglas B Rupp <rupp@gnat.com>
0c376465
TG
1186
1187 * vms.h: Update copyright year, fix comments, reorder declarations.
1188 (_bfd_save_vms_section): Remove the prototype.
1189 (EGPS_S_V_NO_SHIFT): New constant.
1190 (bfd_vms_set_section_flags): New prototype.
1191 (EGPS_S_B_ALIGN, EGPS_S_W_FLAGS, EGPS_S_L_ALLOC, EGPS_S_B_NAMLNG): New
1192 constants.
1193 (EGSY_S_W_FLAGS): Ditto.
1194 (EGSY_S_V_QUAD_VAL): Ditto.
1195 (ESDF_S_L_VALUE, ESDF_S_L_PSINDX, ESDF_S_B_NAMLNG): Ditto.
1196 (EGST_S_W_FLAGS, EGST_S_Q_LP_1, EGST_S_Q_LP_2, EGST_S_L_PSINDX,
1197 EGST_S_B_NAMLNG): Ditto.
1198 (ESRF_S_B_NAMLNG): Ditto.
1199 (ETIR_S_C_HEADER_SIZE): Ditto.
1200 (EGPS_S_V_ALLOC_64BIT): Ditto.
1201 (DST_S_C_EPILOG): Ditto.
1202 (DST_S_C_SRC_SETLNUM_L, DST_S_C_SRC_SETLNUM_W) : Ditto.
1203 (DST_S_C_SRC_INCRLNUM_B): Ditto.
1204 (DST_S_B_PCLINE_UNSBYTE, DST_S_W_PCLINE_UNSWORD): Ditto.
1205 (DST_S_L_PCLINE_UNSLONG): Ditto.
1206 (DST_S_B_MODBEG_NAME, DST_S_L_RTNBEG_ADDRESS) : Ditto
1207 (DST_S_B_RTNBEG_NAME, DST_S_L_RTNEND_SIZE): Ditto
1208 (DST_S_C_SOURCE_HEADER_SIZE): Ditto.
1209 (DST_S_B_SRC_DF_LENGTH, DST_S_W_SRC_DF_FILEID): Ditto.
1210 (DST_S_B_SRC_DF_FILENAME, DST_S_B_SRC_UNSBYTE): Ditto.
1211 (DST_S_B_SRC_UNSBYTE): Ditto.
1212 (DST_S_W_SRC_UNSWORD, DST_S_L_SRC_UNSLONG): Ditto.
1213 Add prototypes.
1214 (vms_section, vms_reloc): Remove types.
1215 (hdr_struc): Replaced by ...
1216 (hdr_struct): ... new type.
1217 (EMH_S_W_HDRTYP, EMH_S_B_STRLVL, EMH_S_L_ARCH1): New constants.
1218 (EMH_S_L_ARCH2, EMH_S_L_RECSIZ, EMH_S_B_NAMLNG): Ditto.
1219 (EMH_DATE_LENGTH): Ditto.
1220 (eom_struc): Replaced by ...
1221 (eom_struct): ... new type.
1222 (EEOM_S_L_TOTAL_LPS, EEOM_S_W_COMCOD, EEOM_S_B_TFRFLG): New constants.
1223 (EEOM_S_L_PSINDX, EEOM_S_L_TFRADR): Ditto.
1224 (EIHD_S_K_MAJORID, EIHD_S_K_MINORID, EIHD_S_K_EXE): Ditto.
1225 (EIHD_S_L_SIZE, EIHD_S_L_ISDOFF, EIHD_S_L_SYMDBGOFF): Ditto.
1226 (EIHD_S_Q_SYMVVA, EIHD_S_L_IMGTYPE): Ditto.
1227 (EISD_S_L_EISDSIZE, EISD_S_L_SECSIZE, EISD_S_Q_VIR_ADDR): Ditto.
1228 (EISD_S_L_FLAGS, EISD_S_L_VBN, EISD_S_R_CONTROL): Ditto.
1229 (EISD_S_L_IDENT, EISD_S_T_GBLNAM): Ditto.
1230 (EISD_S_M_GBL, EISD_S_M_CRF, EISD_S_M_DZRO, EISD_S_M_WRT): Ditto.
1231 (EISD_S_M_INITALCODE, EISD_S_M_BASED, EISD_S_M_FIXUPVEC): Ditto.
1232 (EISD_S_M_RESIDENT, EISD_S_M_VECTOR, EISD_S_M_PROTECT): Ditto.
1233 (EISD_S_M_LASTCLU, EISD_S_M_EXE, EISD_S_M_NONSHRADR): Ditto.
1234 (EISD_S_M_QUAD_LENGTH, EISD_S_M_ALLOC_64BIT): Ditto.
1235 (EIHS_S_L_DSTVBN, EIHS_S_L_DSTSIZE, EIHS_S_L_GSTVBN): Ditto.
1236 (EIHS_S_L_GSTSIZE, EIHS_S_L_DMTVBN, EIHS_S_L_DMTBYTES): Ditto.
1237 (DBG_S_L_DMT_MODBEG, DBG_S_L_DST_SIZE): Ditto.
1238 (DBG_S_W_DMT_PSECT_COUNT, DBG_S_C_DMT_HEADER_SIZE): Ditto.
1239 (DBG_S_L_DMT_PSECT_START, DBG_S_L_DMT_PSECT_LENGTH)
1240 (DBG_S_C_DMT_PSECT_SIZE): Ditto.
1241 (enum file_type_enum): New type.
1242 (struct location_struct): Removed.
1243 (struct fileinfo, struct srecinfo, struct lineinfo): New types.
1244 (struct funcinfo, struct module): Ditto.
1245 (struct vms_private_data_struct): Update fields.
1246 (struct vms_section_data_struct): New type.
1247
1248 * vms.c: Update copyright year, fix comments,
1249 Fix includes for DECC, add prototypes.
1250 (vms_initialize): Use bfd_alloc instead of bfd_zalloc and remove
1251 some initializers.
1252 Use flavour to set is_vax, location_stack is removed.
1253 (struct pair): Declare.
1254 (fill_section_ptr): Initialize variables at declaration.
1255 Add guard to set SECTION_SYM flag, handlde und section.
1256 (vms_fixup_sections): Use struct pair for fill_section_ptr argument.
1257 (_bfd_vms_slurp_object_records): New function, replaces previous
1258 vms_object_p.
1259 (vms_slurp_module): New function.
1260 (vms_slurp_image): Ditto.
1261 (vms_object_p): Complete rewrite.
1262 (vms_mkobject): Use is_vax field to slect architecture.
1263 (free_reloc_stream): New function.
1264 (vms_convert_to_var): Ditto.
1265 (vms_convert_to_var_1): Ditto.
1266 (vms_convert_to_var_unix_filename): Ditto.
1267 (vms_close_and_cleanup): Call free_reloc_stream, convert file to
1268 VAR format on VMS.
1269 (vms_new_section_hook): Set alignment to 0, allocate private data.
1270 (vms_get_section_contents): Load content.
1271 (vms_get_symbol_info): Handle undefined section.
1272 (vms_find_nearest_line): Handle.
1273 (alloc_reloc_stream): New function.
1274 (vms_slurp_reloc_table): Ditto.
1275 (vms_get_reloc_upper_bound): Make it real.
1276 (vms_canonicalize_reloc): Do the real work.
1277 (alpha_howto_table): Add ALPHA_R_NOP, ALPHA_R_BSR, ALPHA_R_LDA,
1278 ALPHA_R_BOH.
1279 (vms_bfd_reloc_type_lookup): Handle NOP, BSR, LDA and BOH.
1280 (vms_set_arch_mach): Check arch.
1281 (vms_set_section_contents): Copy the content after allocation.
1282 (vms_alpha_vec): Update object flags.
1283
1284 * vms-tir.c: Update copyright year, fix comments,
1285 add prototypes for new functions.
1286 (dst_define_location): New function.
1287 (dst_restore_location): New function.
1288 (dst_retrieve_location): New function.
1289 (dst_check_allocation): New function.
1290 (image_dump): Call dst_check_allocation.
1291 (image_write_b): Ditto.
1292 (image_write_w): Ditto.
1293 (image_write_l): Ditto.
1294 (image_write_q): Ditto.
1295 (cmd_name): Handle STA_LW, STA_QW, STO_OFF, STO_IMM, STO_IMMR, STO_LW,
1296 STO_QW, OPR_ADD, CTL_SETRB, STC_LP_PSB, CTL_DFLOC, CTL_STLOC,
1297 CTL_STKDL.
1298 Call error handler instead of abort if name is not known.
1299 (etir_sta): Add quarter_relocs argument and set it.
1300 Fix cast.
1301 (etir_sto): Ditto.
1302 (etir_opr): Ditto, return FALSE in case of error.
1303 (etir_ctl): Add quarter_relocs argument and set it, fix cast.
1304 Fix CTL_DFLOC, CTL_STLOC, CTL_STKDL.
1305 (etir_stc): Add quarter_relocs argument and set it, fix cast.
1306 Fix STC_LP, STC_LP_PSB, STC_GBL and STC_CGA.
1307 Handle STC_LP_PSB, STC_BSR_GBL, STC_LDA_GBL, STC_BOH_GBL.
1308 Move STC_NOP_PS, STC_BSR_PS, STC_LDA_PS, STC_BOH_PS, STC_NBH_PS.
1309 Return FALSE in case of error.
1310 (tir_sta): Change sign of psect.
1311 (tir_ctl): Ditto.
1312 (tir_cmd): Fix cast. Makes tir_table static const.
1313 (etir_cmd): Add quarter_relocs argument, makes etir_table const,
1314 add argument to explain.
1315 (analyze_etir): Initialize maxptr, add quarter_relocs
1316 declaration, move some declarations into inner scopes.
1317 Handle quarter_relocs and STO_IMM.
1318 (_bfd_vms_slurp_tir): Use constant instead of hard-coded values.
1319 (_bfd_vms_slurp_relocs): New function.
1320 (_bfd_vms_decode_relocs): New function.
1321 (sto_imm): Rewritten.
1322 (start_first_etbt_record): New function.
1323 (start_another_etbt_record): Ditto.
1324 (etir_output_check): Ditto.
1325 (defer_reloc_p): Ditto.
1326 (_bfd_vms_write_tir): Remove nextoffset, convert a while-loop to
1327 a for-loop. Correctly deals with contents, deals with .vmsdebug,
1328 rewritte relocations handling.
1329 (_bfd_vms_write_tbt): Removed.
1330 (_bfd_vms_write_dbg): Ditto.
1331
1332 * vms-misc.c: Update copyright year, Fix comments.
1333 (_bfd_vms_get_header_values): Use 'size' instead of 'length'.
1334 (maybe_adjust_record_pointer_for_object): New function.
1335 (_bfd_vms_get_first_record): New function, replaces ...
1336 (_bfd_vms_get_record): .. removed.
1337 (_bfd_vms_get_object_record): New function.
1338 (_bfd_vms_get_object_record): New function.
1339 (vms_get_remaining_object_record): New function, replaces ...
1340 (_bfd_vms_get_next_record): ... removed.
1341 (add_new_contents): Removed.
1342 (_bfd_save_vms_section): Removed.
1343 (_bfd_get_vms_section): Removed.
1344 (_bfd_vms_output_flush): Write in VAR format.
1345 (new_symbol): Don't make UND section.
1346
1347 * vms-hdr.c: Update copyright year, update list of record handled.
1348 (_bfd_vms_slurp_hdr): rec_length renamed to rec_size.
1349 (_bfd_vms_write_hdr): Strip vms and unix patches,
1350 add comments, truncate module name at 31 characters,
1351 use constants instead of hard-coded value,
1352 write BFD version instead of a fixed string.
1353 (_bfd_vms_slurp_ihd): New function.
1354 (_bfd_vms_slurp_isd): Ditto.
1355 (_bfd_vms_slurp_ihs): Ditto.
1356 (new_module): Ditto.
1357 (parse_module): Ditto
1358 (build_module_list): Ditto.
1359 (module_find_nearest_line): Ditto.
1360 (_bfd_vms_find_nearest_dst_line): Ditto.
1361 (vms_slurp_debug): Ditto.
1362 (_bfd_vms_slurp_dbg): Ditto.
1363 (_bfd_vms_slurp_tbt): Ditto.
1364 (_bfd_vms_write_dbg): Ditto.
1365 (_bfd_vms_write_tbt): Ditto.
1366
1367 * vms-gsd.c: Update copyright year, update list of records handled.
1368 (EVAX_LITERALS_NAME): New macro.
1369 (evax_section_flags): Add an entry for EVAX_LITERALS_NAME.
1370 (gpsflagdesc, gsyflagdesc): Moved out of _bfd_vms_slurp_gsd.
1371 (register_universal_symbol): New function and prototype.
1372 (_bfd_vms_slurp_gsd): Fix indentations and casts,
1373 improve debug messages,
1374 use constants instead of hard-coded value,
1375 fix missing endianness conversion,
1376 handle global symbol (SYMG).
1377 (bfd_vms_set_section_flags): New function.
1378 (_bfd_vms_write_gsd): Don't write .vmsdebug section,
1379 handle section literals,
1380 fix indentation,
1381 handle section bfd and vms flags,
1382 don't output LIB$INITIALIZE symbol,
1383 fix handling of weak symbols,
1384 fix evax vs vax procedure descriptor,
1385 handle absolute symbols.
1386
1387 * reloc.c (BFD_RELOC_ALPHA_NOP, BFD_RELOC_ALPHA_BSR,
1388 BFD_RELOC_ALPHA_LDA, BFD_RELOC_ALPHA_BOH): New relocations.
1389
1390 * makefile.vms (DEFS): Fix flags for VMS.
1391
1392 * bfdio.c (real_fopen): Handle multiple VMS fopen attributes.
1393
1394 * bfd-in2.h: Regenerated.
1395 * libbfd.h: Regenerated.
1396
47149254
CC
13972009-02-20 Cary Coutant <ccoutant@google.com>
1398
1399 * vmsutil.c (vms_file_stats_name): Fix incorrect use of st_mtime
1400 in struct stat.
1401
6b1cecf3
DK
14022009-18-02 Dave Korn <dave.korn.cygwin@gmail.com>
1403
1404 PR gas/7059
1405 * coffcode.h (coff_write_object_contents): Don't let the string
1406 table offset overflow the s_name field when using long section names.
1407
88183869
DK
14082009-18-02 Dave Korn <dave.korn.cygwin@gmail.com>
1409
1410 * coff-alpha.c (alpha_ecoff_backend_data): Initialise fields which
1411 control long section name handling with ECOFF_NO_LONG_SECTION_NAMES.
1412 * coff-mips.c (mips_ecoff_backend_data): Likewise.
1413 * coff-rs6000.c (bfd_xcoff_backend_data): Initialise fields which
1414 control long section name handling with XCOFF_NO_LONG_SECTION_NAMES.
1415 (bfd_pmac_xcoff_backend_data): Likewise.
1416 * coff64-rs6000.c (bfd_xcoff_backend_data): Likewise.
1417 (bfd_xcoff_aix5_backend_data): Likewise.
1418 (xcoff64_write_object_contents): Delete unused long_section_names
1419 local variable.
1420 * coff-sh.c (bfd_coff_small_swap_table): Initialise long section
1421 name members using COFF_DEFAULT_LONG_SECTION_NAMES and make entire
1422 struct non-const.
1423 * coffcode.h (documentation): Update to describe long section names.
1424 (COFFLONGSECTIONCATHELPER): New helper macro.
1425 (BLANKOR1TOODD): Likewise.
1426 (COFF_ENABLE_LONG_SECTION_NAMES): Likewise.
1427 (COFF_LONG_SECTION_NAMES_SETTER): Likewise.
1428 (COFF_DEFAULT_LONG_SECTION_NAMES): Likewise.
1429 (bfd_coff_set_long_section_names_allowed): New function.
1430 (bfd_coff_set_long_section_names_disallowed): Likewise.
1431 (struct bfd_coff_backend_data): Add new backend hook function
1432 pointer _bfd_coff_set_long_section_names.
1433 (bfd_coff_set_long_section_names): New backend hook.
1434 (coff_write_object_contents): Only generate long section names if
1435 bfd_coff_long_section_names() indicates they are currently enabled.
1436 (bfd_coff_std_swap_table): Make non-const, and initialise long
1437 section name fields using COFF_DEFAULT_LONG_SECTION_NAMES.
1438 (ticoff0_swap_table): Likewise to both.
1439 (ticoff1_swap_table): Again, likewise to both.
1440 * coffgen.c (make_a_section_from_file): Allow long section names
1441 as inputs even if not currently allowed for outputs.
1442 * ecoff.c (_bfd_ecoff_no_long_sections): New function.
1443 * efi-app-ia32.c (COFF_LONG_SECTION_NAMES): Define to 0, not blank.
1444 * efi-app-ia64.c (COFF_LONG_SECTION_NAMES): Likewise.
1445 * efi-app-x86_64.c (COFF_LONG_SECTION_NAMES): Likewise.
1446 * efi-bsdrv-ia32.c (COFF_LONG_SECTION_NAMES): Likewise.
1447 * efi-bsdrv-ia64.c (COFF_LONG_SECTION_NAMES): Likewise.
1448 * efi-bsdrv-x86_64.c (COFF_LONG_SECTION_NAMES): Likewise.
1449 * efi-rtdrv-ia32.c (COFF_LONG_SECTION_NAMES): Likewise.
1450 * efi-rtdrv-ia64.c (COFF_LONG_SECTION_NAMES): Likewise.
1451 * efi-rtdrv-x86_64.c (COFF_LONG_SECTION_NAMES): Likewise.
1452 * pei-arm.c (COFF_LONG_SECTION_NAMES): Likewise.
1453 * pei-i386.c (COFF_LONG_SECTION_NAMES): Likewise.
1454 * pei-mcore.c (COFF_LONG_SECTION_NAMES): Likewise.
1455 * pei-mips.c (COFF_LONG_SECTION_NAMES): Likewise.
1456 * pei-ppc.c (COFF_LONG_SECTION_NAMES): Likewise.
1457 * pei-sh.c (COFF_LONG_SECTION_NAMES): Likewise.
1458 * pei-x86_64.c (COFF_LONG_SECTION_NAMES): Likewise.
1459 * libcoff-in.h: Update copyright year to cause updated copyright
1460 year in generated libcoff.h, and fix typo.
1461 * libcoff.h: Regenerated.
1462 * libecoff.h (ECOFF_NO_LONG_SECTION_NAMES): New macro.
1463 (_bfd_ecoff_no_long_sections): Add prototype.
1464 * libxcoff.h (XCOFF_NO_LONG_SECTION_NAMES): New macro.
1465 * pe-mips.c (COFF_LONG_SECTION_NAMES): Define empty if not already
1466 defined by an including .c file.
1467 * ticoff.h (ticoff0_swap_table): Make non-const, and initialise
1468 long section name fields using COFF_DEFAULT_LONG_SECTION_NAMES.
1469 (ticoff1_swap_table): Likewise to both.
1470
90d8a22c
CL
14712009-02-18 Christophe Lyon <christophe.lyon@st.com>
1472
1473 * elf32-arm.c (arm_build_one_stub): Fix relocation target for pic
1474 stub. Catch default case error.
1475 (arm_map_one_stub): Add missing Thumb mapping symbol.
1476
12123067
NC
14772009-02-18 Bjoern Haase <bjoern.m.haase@web.de>
1478
1479 PR 9841
1480 * elf32-avr.c: Handle case where no local symbos exist correctly.
1481
fea2b4d6
CL
14822009-02-16 Christophe Lyon <christophe.lyon@st.com>
1483
1484 bfd/
1485 * elf32-arm.c (arm_long_branch_stub,
1486 arm_thumb_v4t_long_branch_stub,
1487 arm_thumb_thumb_long_branch_stub,
1488 arm_thumb_arm_v4t_long_branch_stub,
1489 arm_thumb_arm_v4t_short_branch_stub,
1490 arm_pic_long_branch_stub):
1491 Renamed to elf32_arm_stub_long_branch_any_any,
1492 elf32_arm_stub_long_branch_v4t_arm_thumb,
1493 elf32_arm_stub_long_branch_thumb_only,
1494 elf32_arm_stub_long_branch_v4t_thumb_arm,
1495 elf32_arm_stub_short_branch_v4t_thumb_arm,
1496 elf32_arm_stub_long_branch_any_any_pic.
1497 (arm_stub_long_branch, arm_thumb_v4t_stub_long_branch,
1498 arm_thumb_thumb_stub_long_branch,
1499 arm_thumb_arm_v4t_stub_long_branch,
1500 arm_thumb_arm_v4t_stub_short_branch, arm_stub_pic_long_branch):
1501 Renamed to arm_stub_long_branch_any_any,
1502 arm_stub_long_branch_v4t_arm_thumb,
1503 arm_stub_long_branch_thumb_only,
1504 arm_stub_long_branch_v4t_thumb_arm,
1505 arm_stub_short_branch_v4t_thumb_arm,
1506 arm_stub_long_branch_any_any_pic.
1507
13e0a874
DA
15082009-02-15 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1509
1510 * elf-hppa.h (elf_hppa_final_link_relocate): Correct addend value used
1511 in branch offset check.
1512
3a71aa26
AM
15132009-02-15 Alan Modra <amodra@bigpond.net.au>
1514
1515 * elf64-ppc.c (struct _ppc64_elf_section_data): Delete t_symndx,
1516 add toc.symndx and toc.add.
1517 (ppc64_elf_check_relocs): Don't set htab->tls_get_addr here.
1518 Set up toc.add.
1519 (get_tls_mask): Add toc_addend param, set from toc.add. Adjust all
1520 callers.
1521 (ppc64_elf_tls_setup): Set htab->tls_get_addr and tls_get_addr_fd.
1522 (branch_reloc_hash_match): New function, extracted from..
1523 (ppc64_elf_tls_optimize): ..here.
1524 (ppc64_elf_relocate_section): Properly set addends when optimizing
1525 tls sequences. Avoid unnecessary reading and writing of insns.
1526 Only redo reloc when symbol changed. Bypass symbol checks when
1527 using tlsld_got.
1528 * elf32-ppc.c (ppc_elf_tls_setup): Correct comment.
1529 (branch_reloc_hash_match): New function, extracted from..
1530 (ppc_elf_tls_optimize): ..here.
1531 (ppc_elf_relocate_section): Avoid unnecessary reading of insns.
1532 Don't clear addend on zapped __tls_get_addr reloc.
1533
2c2b4ed4
NC
15342009-02-12 Nick Clifton <nickc@redhat.com>
1535
1536 PR 9827
1537 * elflink.c (bfd_elf_final_link): When counting the relocations,
1538 if the header size has not been set yet then assume that it will
1539 match the output section's reloc type.
1540
453f5985
NS
15412009-02-12 Nathan Sidwell <nathan@codesourcery.com>
1542
1543 * elf32-mips.c (mips_elf_final_gp): Don't add 0x4000 offset for
1544 relocatable link.
1545
3209bffa
AM
15462009-02-09 Alan Modra <amodra@bigpond.net.au>
1547
1548 * elf32-spu.c (spu_elf_find_overlays): Call bfd_set_error on errors.
1549 (find_function): Likewise.
1550 (pasted_function): Don't error if no prior function found.
1551 (discover_functions): Revert 2008-12-10 change. Extend first
1552 function range to start of section.
1553
813c8a3c
DA
15542009-02-08 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1555
1556 * elf64-hppa.c: Remove PARAMS macro. Replace PTR with void *. Convert
1557 functions to C90.
1558 * elf64-hppa.h: Likewise.
1559
2d0f9ad9
JM
15602009-02-06 Joseph Myers <joseph@codesourcery.com>
1561
1562 * elfxx-mips.c (_bfd_mips_elf_section_processing): Remove special
1563 .sbss handling.
1564
50e00962
AM
15652009-02-04 Alan Modra <amodra@bigpond.net.au>
1566
1567 * elf32-spu.c (spu_elf_build_stubs): Define __icache_neg_log2_linesize.
1568 Define __icache_ptr_handler*, not __icache_ptr___icache_bi_handler*.
1569
52b6b6b9
JM
15702009-02-03 Sandip Matte <sandip@rmicorp.com>
1571
1572 * aoutx.h (NAME (aout, machine_type)): Handle bfd_mach_mips_xlr.
1573 * archures.c (bfd_mach_mips_xlr): Define.
1574 * bfd-in2.h: Regenerate.
1575 * cpu-mips.c (I_xlr): Define.
1576 (arch_info_struct): Add XLR entry.
1577 * elfxx-mips.c (_bfd_elf_mips_mach): Handle E_MIPS_MACH_XLR.
1578 (mips_set_isa_flags): Handle bfd_mach_mips_xlr
1579 (mips_mach_extensions): Add XLR entry.
1580
654c3c9f
EW
15812009-02-03 Eric B. Weddington <eric.weddington@atmel.com>
1582
1583 * elf32-avr.c (avr_final_link_relocate): Allow avr25 to wraparound.
1584
31dd3154
JM
15852009-02-03 Carlos O'Donell <carlos@codesourcery.com>
1586
1587 * configure.in: AC_SUBST pdfdir.
d1fa68d3 1588 * Makefile.am: Add install-pdf, install-pdf-am
31dd3154
JM
1589 and install-pdf-recursive targets. Define pdfdir.
1590 * doc/Makefile.am: Define pdf__strip_dir. Add
1591 install-pdf and install-pdf-am targets.
d1fa68d3 1592 * po/Make-in: Add install-pdf target.
31dd3154
JM
1593 * configure: Regenerate.
1594 * Makefile.in: Regenerate
1595 * doc/Makefile.in: Regenerate.
1596
cf869cce
NC
15972009-02-03 Maxim Kuvyrkov <maxim@codesourcery.com>
1598
1599 * bfd-in2.h: Regenerate.
1600 * elf32-m68k.c: Handle 2-slot GOT entries. Rename variables and
1601 fields from n_entries to n_slots where appropriate, update comments.
1602 (HOWTO): Add TLS relocations.
1603 (reloc_map): Map BFD_RELOC_68K_TLS_* to R_68K_TLS_*.
1604 (enum elf_m68k_got_offset_size): New enum.
1605 (struct elf_m68k_got_entry.type): Move field to ...
1606 (struct elf_m68k_got_entry_key): ... here. Update all uses.
1607 (elf_m68k_reloc_got_type, elf_m68k_reloc_got_offset_size): New static
1608 functions.
1609 (elf_m68k_reloc_got_n_entries, elf_m68k_reloc_tls_p): New static
1610 functions.
1611 (struct elf_m68k_got): merge rel_8o_n_entries and rel_8o_16o_n_entries
1612 fields into n_entries array. Update comments.
1613 (elf_m68k_init_got): Simplify, update all uses.
1614 (elf_m68k_init_got_entry_key): Handle R_68K_TLS_LDM32 reloc, update.
1615 (ELF_M68K_REL_8O_MAX_N_ENTRIES_IN_GOT): Adjust to handle 2-slot
1616 GOT entries; update name, update all uses.
1617 (ELF_M68K_REL_8O_16O_MAX_N_ENTRIES_IN_GOT): Ditto.
1618 (elf_m68k_get_got_entry): Update.
1619 (elf_m68k_update_got_entry_type): Rewrite to handle TLS GOT entries,
1620 simplify.
1621 (elf_m68k_remove_got_entry_type): Simplify.
1622 (elf_m68k_add_entry_to_got, elf_m68k_can_merge_gots_1): Update.
1623 (elf_m68k_can_merge_gots): Update.
1624 (elf_m68k_merge_gots_1, elf_m68k_merge_gots): Update.
1625 (struct elf_m68k_finalize_got_offsets_arg): Rewrite to handle 2-slot
1626 GOT entries, simplify.
1627 (elf_m68k_finalize_got_offsets_1, elf_m68k_finalize_got_offsets): Same.
1628 (struct elf_m68k_partition_multi_got_arg): Add slots_relas_diff
1629 field, remove obsoleted local_n_entries field.
1630 (elf_m68k_partition_multi_got_2): New static function.
1631 (elf_m68k_partition_multi_got_1, elf_m68k_partition_multi_got): Use it;
1632 update.
1633 (elf_m68k_remove_got_entry_type): Update.
1634 (elf_m68k_install_rela, dtpoff_base, tpoff): New static functions.
d1fa68d3 1635 (elf_m68k_check_relocs): Handle TLS relocations. Remove unnecessary
cf869cce
NC
1636 update of sgot->size and srelgot->size.
1637 (elf_m68k_gc_sweep_hook): Update.
1638 (elf_m68k_install_rela, dtpoff_base, tpoff): New static functions.
1639 (elf_m68k_relocate_section, elf_m68k_finish_dynamic_symbol): Handle
1640 TLS relocations.
1641 * reloc.c (BFD_RELOC_68K_TLS_*): Declare TLS relocations.
1642 * libbfd.h (bfd_reloc_code_real_names): Add BFD_RELOC_68K_TLS_*.
1643
c1a0a41f
DD
16442009-02-02 DJ Delorie <dj@redhat.com>
1645
1646 * elf32-mep.c (config_names): Regenerate configuration.
1647
72a80a16
AM
16482009-02-02 Alan Modra <amodra@bigpond.net.au>
1649
1650 * elf-bfd.h (bfd_elf_get_str_section): Don't declare.
1651 (bfd_elf_find_section, _sh_elf_set_mach_from_flags): Likewise.
1652 * elf.c (bfd_elf_get_str_section): Make static.
1653 (bfd_elf_find_section): Delete.
1654 * libbfd.h: Regenerate.
1655
273f4430
JK
16562009-02-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1657
1658 * elf-eh-frame.c (REQUIRE_CLEARED_RELOCS) Remove.
1659 (_bfd_elf_parse_eh_frame): Do not check relocations for removed FDEs.
1660
010e5ae2
AM
16612009-01-31 Alan Modra <amodra@bigpond.net.au>
1662
1663 * elflink.c (on_needed_list): New function.
1664 (elf_link_add_object_symbols): Link in --as-needed libs if they
1665 satisfy undefined symbols in other libs.
1666
33a7ffc2
JM
16672009-01-30 Julian Brown <julian@codesourcery.com>
1668
1669 * elf32-arm.c (bfd_elf32_arm_vfp11_erratum_scan): Skip BFDs with
1670 EXEC_P or DYNAMIC flags, and skip sections which are being linked
1671 with --just-symbols (-R).
1672
13d72a14
AN
16732009-01-29 Adam Nemet <anemet@caviumnetworks.com>
1674
1675 * dwarf2.c (read_rangelist): Use read_address to read low_pc and
1676 high_pc in order to properly sign-extend VMAs.
1677
d334575b 16782009-01-29 Daniel Jacobowitz <dan@codesourcery.com>
d1fa68d3
AS
1679 Mark Shinwell <shinwell@codesourcery.com>
1680 Catherine Moore <clm@codesourcery.com>
d334575b
JM
1681
1682 * elf-attrs.c, elflink.c, elfxx-mips.c: Correct typos in comments.
1683
528aeb62
CM
16842009-01-28 Catherine Moore <clm@codesourcery.com>
1685
1686 * elf32-arm.c (elf32_arm_check_relocs): Set SEC_ALLOC and
1687 SEC_LOAD for dynamic relocation sections.
1688
f6f05983
HPN
16892009-01-27 Hans-Peter Nilsson <hp@axis.com>
1690
1691 * elf32-cris.c (cris_elf_relocate_section): Use elf_hash_table
1692 (info)->tls_size, not elf_hash_table (info)->tls_sec->size for
1693 the size of local TLS data.
1694
27cc28f9
AS
16952009-01-27 Andreas Schwab <schwab@suse.de>
1696
1697 * mach-o.c (bfd_mach_o_archive_p): Restrict the number of
1698 architectures in the archive.
1699
b3bf42d8
HPN
17002009-01-27 Hans-Peter Nilsson <hp@axis.com>
1701
f551b6f0
HPN
1702 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_DTPREL>
1703 <R_CRIS_32_DTPREL>: Correct relocation value.
1704
b3bf42d8
HPN
1705 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_8>
1706 <R_CRIS_16, R_CRIS_32>: Don't call BFD_ASSERT for weak undefined
1707 symbols with non-default visibility.
1708
9bc4e62b
NS
17092009-01-26 Nathan Sidwell <nathan@codesourcery.com>
1710
1711 * elf32-ppc.c (ppc_elf_relax_section): Add space for relocs
1712 describing the trampolines.
1713 (ppc_elf_relocate_section): Update relocs to describe the
1714 trampolines.
1715
aeaf6540
DA
17162009-01-25 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1717
1718 * elf-hppa.h (elf_hppa_final_link_relocate): Add check to ensure that
1719 branch targets can be reached for R_PARISC_PCREL22F, R_PARISC_PCREL17F
1720 and R_PARISC_PCREL12F relocations.
1721
1e8fa21e
AM
17222009-01-24 Alan Modra <amodra@bigpond.net.au>
1723
1724 PR 6022
1725 * elflink.c (find_version_for_sym): New function split out from,
1726 but without export_dynamic test, ..
1727 (_bfd_elf_link_assign_sym_version): ..here.
1728 (_bfd_elf_export_symbol): Use it.
1729
28caa186
AM
17302009-01-23 Alan Modra <amodra@bigpond.net.au>
1731
1732 * elf-bfd.h (struct elf_assign_sym_version_info): Delete.
1733 (struct elf_info_failed, struct elf_find_verdep_info): Move to..
1734 * elflink.c: ..here, somewhat modified.
1735 * elf-bfd.h (_bfd_elf_add_default_symbol, _bfd_elf_export_symbol,
1736 _bfd_elf_link_find_version_dependencies,
1737 _bfd_elf_link_assign_sym_version, _bfd_elf_link_size_reloc_section,
1738 _bfd_elf_fix_symbol_flags, _bfd_elf_adjust_dynamic_symbol,
1739 _bfd_elf_link_sec_merge_syms, bfd_elf_link_mark_dynamic_symbol): Don't
1740 declare..
1741 * elflink.c: ..and make static here.
1742 (_bfd_elf_link_find_version_dependencies): Adjust for removal
1743 of output_bfd from struct elf_find_verdep_info.
1744 (_bfd_elf_link_assign_sym_version): Similarly adjust to use
1745 struct elf_info_failed.
1746 (bfd_elf_size_dynamic_sections): Adjust.
1747
be04437d
AM
17482009-01-22 Alan Modra <amodra@bigpond.net.au>
1749
1750 PR 6832
1751 * dwarf2.c (find_line): Don't update stash->sec_info_ptr until
1752 after comp_unit_find_line call.
1753
58f9615c
NC
17542009-01-21 Nick Clifton <nickc@redhat.com>
1755
1756 PR 9769
1757 * vmsutil.c (vms_file_stats_name): Remove use of unsupported
1758 tm_gmtoff field in struct tm.
1759
fb266b8b
AM
17602009-01-21 Alan Modra <amodra@bigpond.net.au>
1761
1762 * elf32-spu.h (struct spu_elf_params): Add non_ia_text.
1763 * elf32-spu.c (mark_overlay_section): Only include .text.ia.*
1764 sections in soft-icache lines unless non_ia_text. Don't add
1765 rodata if doing so would exceed line size.
1766
451ffe63
HPN
17672009-01-19 Hans-Peter Nilsson <hp@axis.com>
1768
1769 * elf32-cris.c (elf_cris_copy_indirect_symbol): For other symbol
1770 types than bfd_link_hash_indirect, before early return, call
1771 _bfd_elf_link_hash_copy_indirect.
1772
5aa6ff7c
AS
17732009-01-19 Andrew Stubbs <ams@codesourcery.com>
1774
1775 * elf-attrs.c (vendor_set_obj_attr_contents): Support tag ordering.
1776 * elf-bfd.h (elf_backend_data): Add obj_attrs_order.
1777 * elf32-arm.c (elf32_arm_obj_attrs_order): New function.
1778 (elf_backend_obj_attrs_order): New define.
1779 * elfxx-target.h (elf_backend_obj_attrs_order): New define.
1780 (elfNN_bed): Add elf_backend_obj_attrs_order.
1781
3483fe2e
AS
17822009-01-19 Andrew Stubbs <ams@codesourcery.com>
1783
1784 * elf-attrs.c (is_default_attr): Substitute magic numbers with macros.
1785 (obj_attr_size): Likewise.
1786 (write_obj_attribute): Likewise.
1787 (_bfd_elf_copy_obj_attributes): Likewise.
1788 (_bfd_elf_parse_attributes): Likewise.
1789 * elf-bfd.h (ATTR_TYPE_FLAG_INT_VAL): New define.
1790 (ATTR_TYPE_FLAG_STR_VAL, ATTR_TYPE_FLAG_NO_DEFAULT): New defines.
1791 (ATTR_TYPE_HAS_INT_VAL, ATTR_TYPE_HAS_STR_VAL): New defines.
1792 (ATTR_TYPE_HAS_NO_DEFAULT): New define.
1793 * elf32-arm.c (elf32_arm_obj_attrs_arg_type): Replace magic numbers
1794 with macros.
1795
2d0bb761
AS
17962009-01-19 Andrew Stubbs <ams@codesourcery.com>
1797
1798 * elf-attrs.c (is_default_attr): Support defaultless attributes.
1799 (bfd_elf_add_obj_attr_int): Get type from _bfd_elf_obj_attrs_arg_type.
1800 (bfd_elf_add_obj_attr_string): Likewise.
1801 (bfd_elf_add_obj_attr_int_string): Likewise.
1802 (_bfd_elf_parse_attributes): Allow for unknown flag bits in type.
1803 * elf-bfd.h (struct obj_attribute): Document new flag bit.
1804 * elf32-arm.c (elf32_arm_obj_attrs_arg_type): Specify that
1805 Tag_nodefaults has no default value.
1806 (elf32_arm_merge_eabi_attributes): Modify the Tag_nodefaults
1807 comment to reflect the new state.
1808
a77e83b7
AM
18092009-01-19 Alan Modra <amodra@bigpond.net.au>
1810
1811 PR 9695
1812 * pdp11.c (N_BADMAG): True for anything but OMAGIC, NMAGIC, ZMAGIC.
1813 (some_aout_object_p): Delete dead code handling QMAGIC and BMAGIC.
1814 (adjust_z_magix): Delete dead code handling QMAGIC.
1815
f6d29e26
KT
18162009-01-16 Kai Tietz <kai.tietz@onevision.com>
1817
1818 * coffcode.h (styp_to_sec_flags): Correct interpretation of
1819 IMAGE_SCN_MEM_DISCARDABLE.
1820
29670fb9
AM
18212009-01-16 Alan Modra <amodra@bigpond.net.au>
1822
1823 * Makefile.am (libbfd_la_LIBADD, libbfd_la_LDFLAGS): Substitute
1824 SHARED_LIBADD and SHARED_LDFLAGS rather than WIN32LIBADD, WIN32LDFLAGS.
1825 * configure.in (commonbfdlib): Delete.
1826 (SHARED_LDFLAGS): Rename from WIN32LDFLAGS/
1827 (SHARED_LIBADD): Rename from WIN32LIBADD. Add pic libiberty if such
1828 is available, not just for linux.
1829 * po/SRC-POTFILES.in: Regenerate.
1830 * Makefile.in: Regenerate.
1831 * configure: Regenerate.
1832
91e22acd
AS
18332009-01-15 Andrew Stubbs <ams@codesourcery.com>
1834 Julian Brown <julian@codesourcery.com>
1835
1836 * elf-bfd.h (NUM_KNOWN_OBJ_ATTRIBUTES): Set to 71 to include all known
1837 ARM attributes in ABI 2.07.
1838 * elf32-arm.c (get_secondary_compatible_arch): New function.
1839 (set_secondary_compatible_arch): New function.
1840 (tag_cpu_arch_combine): New function.
1841 (elf32_arm_copy_one_eabi_other_attribute): Delete function.
1842 (elf32_arm_copy_eabi_other_attribute_list): Delete function.
1843 (elf32_arm_merge_eabi_attributes): Rename order_312 to order_021 to
1844 make it fit with order_01243.
1845 Add support for Tag_also_compatible_with,
1846 Tag_CPU_unaligned_access, Tag_T2EE_use, Tag_Virtualization_use,
1847 Tag_MPextension_use, Tag_nodefaults and Tag_conformance.
1848 Improve/tidy up support for Tag_CPU_raw_name, Tag_CPU_name,
1849 Tag_CPU_arch, Tag_ABI_HardFP_use, Tag_VFP_HP_extension,
1850 Tag_ABI_FP_denormal, Tag_ABI_PCS_GOT_use, Tag_ABI_align8_needed,
1851 Tag_VFP_arch and Tag_ABI_FP_16bit_format.
1852 Rework the way unknown attributes are handled.
1853 Defer errors until all attributes have been processed.
1854
7b86a9fa
AS
18552009-01-15 Andrew Stubbs <ams@codesourcery.com>
1856
1857 * elf-attrs.c (bfd_elf_add_obj_attr_compat): Rename to
1858 bfd_elf_add_obj_attr_int_string.
1859 Read Tag_compatibility from its new location in the attribute array,
1860 rather than the attribute list.
1861 (_bfd_elf_copy_obj_attributes): bfd_elf_add_obj_attr_compat ->
1862 bfd_elf_add_obj_attr_int_string.
1863 (_bfd_elf_parse_attributes): Likewise.
1864 (_bfd_elf_merge_object_attributes): There's now only one
1865 Tag_compatibility, and it's in the array, not the list.
1866 * elf-bfd.h (NUM_KNOWN_OBJ_ATTRIBUTES): Set to 33 to include
1867 Tag_compatibility.
1868 (bfd_elf_add_obj_attr_compat): Rename to
1869 bfd_elf_add_obj_attr_int_string.
1870 (bfd_elf_add_proc_attr_compat): Rename to
1871 bfd_elf_add_proc_attr_int_string.
1872 * elf32-arm.c (elf32_arm_merge_eabi_attributes): Explicitly don't handle
1873 Tag_compatibility.
1874
01e1a5bc
NC
18752009-01-15 Douglas B Rupp <rupp@gnat.com>
1876
1877 * Makefile.am (BFD32_BACKENDS): Add new object vmsutil.lo
1878 (BFD32_BACKENDS_CFILES): Add new file vmsutil.c
1879 (vmsutil.lo): Add dependency rule.
1880 * Makefile.in: Regenerate.
1881 * config.bfd (ia64*-*-*vms*): Add case.
1882 * configure.in (bfd_elf64_ia64_vms_vec): Add case.
1883 * configure: Regenerate.
1884 * vmsutil.c: New file.
1885 * vmsutil.h: New file.
1886 * elf-bfd.h (struct bfd_elf_special_section): Change type of
1887 attr to bfd_vma.
1888 * elfxx-ia64.c (elfNN_vms_post_process_headers,
1889 elfNN_vms_section_processing, elfNN_vms_final_write_processing,
1890 elfNN_vms_close_and_cleanup, elfNN_vms_section_from_shdr,
1891 elfNN_vms_object_p): New functions
1892 * targets.c (bfd_elf64_ia64_vms_vec): New target.
1893
a33dafc3
L
18942009-01-14 H.J. Lu <hongjiu.lu@intel.com>
1895
1896 PR ld/9727
1897 * elflink.c (elf_gc_sweep): Exclude the group section if the
1898 first member of the section group is excluded.
1899
13c0e967
AM
19002009-01-14 Alan Modra <amodra@bigpond.net.au>
1901
1902 PR 9735
1903 * syms.c (_bfd_stab_section_find_nearest_line): Don't free
1904 saved filename, use bfd_alloc rather than bfd_malloc for it.
1905
460e679b
AM
19062009-01-13 Alan Modra <amodra@bigpond.net.au>
1907
1908 * elf32-spu.c (spu_elf_build_stubs): Make __icache_base absolute.
1909
25076afa
AM
19102009-01-13 Alan Modra <amodra@bigpond.net.au>
1911
1912 * elf32-spu.c (remove_cycles): Always set call->max_depth.
1913
37107878
AM
19142009-01-12 Alan Modra <amodra@bigpond.net.au>
1915
1916 * elf32-spu.c (spu_elf_auto_overlay): Correct vma mask.
1917
cd4a7468
AM
19182009-01-12 Alan Modra <amodra@bigpond.net.au>
1919
1920 * elf32-spu.c (struct spu_link_hash_table): Add init, line_size_log2,
1921 num_lines_log2.
1922 (struct got_entry): Add br_addr.
1923 (struct call_info): Add priority.
1924 (struct function_info): Add lr_store and sp_adjust.
1925 (spu_elf_setup): Init line_size_log2 and num_lines_log2.
1926 (spu_elf_find_overlays): For soft-icache, mark any section within cache
1927 area as an overlay, and check that no other overlays exist. Look up
1928 icache overlay manager entry sym.
1929 (BRA_STUBS, BRA, BRASL): Define.
1930 (enum _stub_type): Replace ovl_stub with call_ovl_stub and br*_ovl_stub.
1931 (needs_ovl_stub): Adjust for soft-icache. Return priority encoded
1932 in branch insn.
1933 (count_stub, build_stub): Support soft-icache.
1934 (build_spuear_stubs, process_stubs): Adjust build_stub call.
1935 (spu_elf_size_stubs): Size soft-icache stubs.
1936 (overlay_index): New function.
1937 (spu_elf_build_stubs): Make static. Support soft-icache.
1938 (spu_elf_check_vma): Don't turn off auto_overlay if soft-icache.
1939 (find_function_stack_adjust): Save lr store and stack adjust insn
1940 offsets.
1941 (maybe_insert_function): Adjust find_function_stack_adjust call.
1942 (mark_functions_via_relocs): Retrieve priority.
1943 (remove_cycles): Only warn about pruned arcs when stack_analysis.
1944 (sort_calls): Sort by priority first.
1945 (mark_overlay_section): Ignore .ovl.init.
1946 (sum_stack): Only print when stack_analysis.
1947 (print_one_overlay_section): New function, extracted from..
1948 (spu_elf_auto_overlay): ..here. Support soft-icache overlays.
1949 (spu_elf_stack_analysis): Only print when htab->stack_analysis.
1950 (spu_elf_final_link): Call spu_elf_stack_analysis for lrlive
1951 analysis. Call spu_elf_build_stubs.
1952 (spu_elf_relocate_section): For soft-icache encode overlay index
1953 into addresses.
1954 (spu_elf_output_symbol_hook): Support soft-icache.
1955 (spu_elf_modify_program_headers: Likewise.
37107878 1956
cd4a7468
AM
1957 * elf32-spu.h (struct spu_elf_params): Add lrlive_analysis. Rename
1958 num_regions to num_lines. Add line_size and max_branch.
1959 (enum _ovly_flavour): Add ovly_soft_icache.
1960 (spu_elf_build_stubs): Delete.
1961
80c29487
JK
19622009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
1963
1964 * elflink.c (_bfd_elf_section_already_linked): Handle g++-3.4
1965 relocations in `.gnu.linkonce.r.*' referencing its `.gnu.linkonce.t.*'.
1966
1bc86aea
HPN
19672009-01-07 Hans-Peter Nilsson <hp@axis.com>
1968
1969 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GD>
1970 <case R_CRIS_16_GOT_GD, R_CRIS_32_GOT_GD>: For a symbol defined in
1971 the program, the known offset starts at the negative size of the
1972 TLS section.
1973 <case R_CRIS_32_IE, R_CRIS_32_GOT_TPREL, R_CRIS_16_GOT_TPREL>:
1974 Similar.
1975
3baa454d 19762009-01-05 Joel Sherrill <joel.sherrill@oarcorp.com>
75606e85 1977
3baa454d 1978 * config.bfd: Add lm32-*-rtems*.
75606e85 1979
9dbe8890
L
19802009-01-03 H.J. Lu <hongjiu.lu@intel.com>
1981
1982 * coff-ppc.c: Add 2009 to Copyright.
1983 * elf32-cris.c: Likewise.
1984 * elflink.c: Likewise.
1985
0bdf8d40
HPN
19862009-01-03 Hans-Peter Nilsson <hp@axis.com>
1987
1988 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Rename
1989 gotplt_index to rela_plt_index. Adjust for R_CRIS_DTPMOD entry.
1990
54ac0771
L
19912009-01-02 H.J. Lu <hongjiu.lu@intel.com>
1992
1993 PR ld/9679
1994 * elflink.c (elf_merge_st_other): New.
1995 (_bfd_elf_merge_symbol): Use it on skipped weak definitions and
1996 hide them if needed.
1997 (elf_link_add_object_symbols): Updated.
1998
d8880531
L
19992009-01-02 H.J. Lu <hongjiu.lu@intel.com>
2000
2001 PR ld/9676
2002 * elflink.c (elf_link_add_object_symbols): Update def_dynamic,
2003 ref_dynamic and dynamic_def fields when setting def_regular
2004 to 1.
2005
b70b5c14
NC
20062009-01-02 Curtis Mackie <curtmackevo@gmail.com>
2007
2008 PR 9682
2009 * coff-ppc.c (dump_toc): Fix up calls to fprintf without a string
2010 literal.
2011
d8880531 2012For older changes see ChangeLog-2008
56882138
AM
2013\f
2014Local Variables:
2015mode: change-log
2016left-margin: 8
2017fill-column: 74
2018version-control: never
2019End:
This page took 0.546751 seconds and 4 git commands to generate.