72a2e2ffa49c229861e5fc0761350576c33d43f0
[binutils-gdb.git] / bfd / ChangeLog
1 2004-01-30 H.J. Lu <hongjiu.lu@intel.com>
2
3 * elfxx-ia64.c (elfNN_ia64_relax_brl): New function.
4 (elfNN_ia64_relax_section): Optimize brl to br during the relax
5 finalize pass.
6
7 2004-01-30 Alexandre Oliva <aoliva@redhat.com>
8
9 * elf32-frv.c (elf32_frv_always_size_sections): Initialize pointer
10 to bfd_link_hash_entry passed by reference to
11 _bfd_generic_link_add_one_symbol.
12
13 2004-01-25 H.J. Lu <hongjiu.lu@intel.com>
14
15 * elfxx-ia64.c (elfNN_ia64_relocate_section): Disallow imm
16 relocations against dynamic symbols.
17
18 2004-01-23 Daniel Jacobowitz <drow@mvista.com>
19
20 * elf32-arm.h (elf32_arm_check_relocs): Revert part of 2004-01-13
21 change.
22
23 2004-01-21 Tom Rix <tcrix@worldnet.att.net>
24
25 * reloc.c: New 5 bit reloc, BFD_RELOC_M68HC12_5B, for m68hc12 movb/movw.
26 * bfd-in2.h, libbfd.h: Rebuilt.
27
28 2004-01-20 Danny Smith <dannysmith@users.sourceforge.net>
29
30 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Don't remove
31 IMAGE_SCN_MEM_WRITE flag from .text section if WP_TEXT
32 flag has been cleared.
33
34 2004-01-19 Kazu Hirata <kazu@cs.umass.edu>
35
36 * coff-h8300.c: Add and adjust comments about relaxation.
37 * elf32-h8300.c: Likewise.
38
39 2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
40
41 * coff-h8300.c: Fix comment typos.
42 * elf32-h8300.c: Likewise.
43
44 2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
45
46 * coff-h8300.c: Add comments about relaxation.
47 * elf32-h8300.c: Likewise.
48
49 2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
50
51 * acinclude.m4: Quote names of macros to be defined by AC_DEFUN
52 throughout.
53 * aclocal.m4: Regenerate.
54 * configure: Regenerate.
55
56 2004-01-13 Ian Lance Taylor <ian@wasabisystems.com>
57
58 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Call
59 mips_elf64_rtype_to_howto instead of using howto_table.
60
61 2004-01-13 Daniel Jacobowitz <drow@mvista.com>
62
63 * elf32-arm.h (elf32_arm_final_link_relocate): Check that we created
64 the .plt section.
65 (elf32_arm_check_relocs): Don't increment the PLT refcount for
66 relocs which would not use the PLT.
67
68 2004-01-13 Alan Modra <amodra@bigpond.net.au>
69
70 * elf64-ppc.c (ppc64_elf_check_relocs): Ignore !SEC_ALLOC relocs.
71 (ppc64_elf_gc_sweep_hook): Likewise.
72 (ppc64_elf_size_dynamic_sections): Test for .plt directly.
73
74 2004-01-12 Anil Paranjpe <anilp1@KPITCummins.com>
75
76 Adds linker relaxation support for bit manipulation insns like
77 band, bclr, biand, bild, bior, bist, bixor, bld, bnot, bor, bset,
78 bst, btst, bxor.
79 * elf32-h8300.c: Opcode for bit manipulation insn is checked in
80 elf32_h8_relax_section function while relxation for aa:16 and aa:32.
81 * coff-h8300.c: Opcode for bit manipulation insn is checked in
82 h8300_reloc16_extra_cases function while relxation for aa:16 and aa:32.
83
84 2004-01-12 Alan Modra <amodra@bigpond.net.au>
85
86 * dwarf2.c: Convert to C90, remove unneeded casts and prototypes.
87
88 2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
89
90 * elf32-h8300.c: Fix formatting.
91
92 2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
93
94 * elf32-cris.c (cris_elf_gc_sweep_hook): Return early if no
95 dynamic object is present. Declare r_symndx and h in an inner
96 scope.
97 * elf32-vax.c (elf_vax_gc_sweep_hook): Likewise.
98
99 2004-01-09 Daniel Jacobowitz <drow@mvista.com>
100
101 * elf32-arm.h (struct elf32_arm_relocs_copied): Remove pc_count.
102 (elf32_arm_copy_indirect_symbol): Don't copy pc_count.
103 (elf32_arm_final_link_relocate): Handle PLT32 and PC24 relocs
104 identically. Do not emit PC24 relocations for shared libraries.
105 (elf32_arm_gc_sweep_hook): Handle PLT32 and PC24 relocs
106 identically. Don't adjust pc_count.
107 (elf32_arm_check_relocs): Handle PLT32 and PC24 relocs identically.
108 Set ELF_LINK_HASH_NEEDS_PLT for both. Don't adjust pc_count; don't
109 adjust count for branch relocations.
110 (allocate_dynrelocs): Correct typo in call to
111 WILL_CALL_FINISH_DYNAMIC_SYMBOL. Never allocate space for
112 PC24 or PLT32 relocs when linking.
113
114 2004-01-09 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
115
116 * coff-arm.c (aoutarm_std_reloc_howto): [ARM_WINCE] Synchronize ARM_26D
117 relocation howto with ARM_26 one for consistency.
118 (coff_arm_relocate_section): Set partial_inplace for ARM_26 relocations
119 that will be converted to ARM_26D ones, since we always want 'done'
120 relocations to be reflected in section's data.
121 (coff_arm_relocate_section): [ARM_WINCE] Quick fix for BL instruction
122 offset.
123 (_bfd_final_link_relocate): Do not modify "inplace" data, if not
124 requested.
125
126 2004-01-08 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
127
128 * coff-arm.c (coff_arm_relocate_section): Do not alter relocs that
129 are not partial_inplace during a relocatable link.
130
131 2004-01-08 Kazu Hirata <kazu@cs.umass.edu>
132
133 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return early
134 if no dynamic object is present. Declare r_symndx and h in an
135 inner scope.
136
137 2004-01-07 H.J. Lu <hongjiu.lu@intel.com>
138
139 * elfxx-ia64.c (elfNN_ia64_relax_section): Don't install
140 trampoline if it is known out of range.
141
142 2004-01-06 Alexandre Oliva <aoliva@redhat.com>
143
144 2003-12-17 Alexandre Oliva <aoliva@redhat.com>
145 * elf32-frv.c (_frv_osec_readonly_p): New.
146 (_frv_emit_got_relocs_plt_entries): Don't emit rofixup for
147 undefweak symbol.
148 (_frv_count_got_plt_entries): Adjust expected count accordingly.
149 (elf32_frv_relocate_section): Likewise. Error out if attempting
150 to emit rofixups or dynamic relocs in read-only segments. Use
151 _bfd_elf_section_offset to adjust r_offsets in rofixups and
152 dynamic relocations.
153 2003-12-12 Alexandre Oliva <aoliva@redhat.com>
154 * elf32-frv.c (elf32_frv_relocate_section): Compute dynamic
155 relocations or fixups involving merged sections correctly. Avoid
156 crash when undefined symbol is referenced by R_FRV_32 or
157 R_FRV_FUNCDESC_VALUE.
158 2003-12-02 Alexandre Oliva <aoliva@redhat.com>
159 * elf32-frv.c (elf32_frv_relocate_section): Add output_offset of
160 input section holding local symbol to addend of R_FRV_32 or
161 R_FRV_FUNCDESC_VALUE dynamic relocation.
162 2003-11-27 Alexandre Oliva <aoliva@redhat.com>
163 * elf32-frv.c (elf32_frv_modify_segment_map): Add link info arg.
164 (elf32_frv_always_size_sections): Don't store pointer to
165 __stacksize symbol in sec_info.
166 (elf32_frv_modify_segment_map): Look it up here.
167 2003-11-26 Alexandre Oliva <aoliva@redhat.com>
168 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Emit the address
169 of the lazy PLT entry, not only its offset, as the low word of a
170 function descriptor.
171 2003-11-10 Alexandre Oliva <aoliva@redhat.com>
172 * elf32-frv.c (elf32_frv_always_size_sections): Define __stacksize
173 if a hash table entry already exists but is not a definition.
174 2003-11-05 Alexandre Oliva <aoliva@redhat.com>
175 * elf32-frv.c (frv_elf_link_hash_table_create): Use bfd_zalloc.
176 (_frv_add_rofixup): Don't inline.
177 (_frv_emit_got_relocs_plt_entries): Use NULL as funcdesc address
178 for undefweak symbols.
179 (elf32_frv_relocate_section): Avoid crash while computing
180 relocation when linking with shared library. Only emit rofixups
181 and dynamic relocations for alloc&load sections. Mark binaries
182 with inter-segment relocations for relocation as a unit.
183 (_frv_create_got_section): Rename .rofixup.got to .rofixup.
184 (DEFAULT_STACK_SIZE): New.
185 (_frv_count_got_plt_entries): Fix thinko in deciding whether to
186 emit rofixups or dynamic relocs when linking dynamic non-PIE
187 executables.
188 (elf32_frv_size_dynamic_sections): Generate rofixup on PIEs and
189 shared libs too. Reserve the last entry for the GOT pointer.
190 (elf32_frv_finish_dynamic_sections): Emit it.
191 (elf32_frv_always_size_sections): New.
192 (elf32_frv_modify_segment_map): New.
193 (elf32_frv_check_relocs): Reserve relocs32 space only in ALLOC
194 sections.
195 (frv_elf_merge_private_bfd_data): Clear PIC bit if FDPIC is set.
196 (frv_elf_print_private_bfd_data): Handle FDPIC and LIBPIC.
197 (elf_backend_always_size_sections): New.
198 (elf_backend_modify_segment_map): New.
199 2003-10-31 Alexandre Oliva <aoliva@redhat.com>
200 * config.bfd: Added frv-*-*linux*.
201 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Use idx 0 for
202 ABS section, instead of crashing.
203 (elf32_frv_relocate_section): Don't crash before warning about
204 different segments in non-PIC relocation.
205 2003-10-17 Alexandre Oliva <aoliva@redhat.com>
206 * elf32-frv.c (elf32_frv_relocate_section): Don't warn on LABEL24
207 relocs to undefweak symbols.
208 (elf32_frv_relocate_section): Ditto for undefined symbols.
209 2003-10-06 Alexandre Oliva <aoliva@redhat.com>
210 * elf32-frv.c (elf32_frv_create_dynamic_sections): Make sure
211 gotfixup section was created.
212 2003-09-30 Alexandre Oliva <aoliva@redhat.com>
213 * elf32-frv.c (elf32_frv_howto_table): Change GOT12,
214 FUNCDESC_GOT12, GOTOFF12 and FUNCDESC_GOTOFF12 to
215 complain_overflow_signed.
216 * elf32-frv.c (_frv_add_rofixup): Do not error out if contents
217 have not been allocated.
218 (_frv_emit_got_relocs_plt_entries): Return non-void. Assert
219 privfd only if dynamic sections were created.
220 (elf32_frv_relocate_section): Compute gprel_segment, and use it
221 for GPREL relocs. When linking relocatable FDPIC executables,
222 emit warnings for relocations that would be illegal on PIE or
223 shared libraries. Emit rofixup for R_FRV_32 only if input object
224 is not FDPIC.
225 (_frv_create_got_section): Define _gp symbol in the rofixup
226 section.
227 (elf32_frv_finish_dynamic_sections): If rofixups needed but
228 dynamic sections missing, error out requesting -melf32frvfd.
229 2003-09-19 Alexandre Oliva <aoliva@redhat.com>
230 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Rearrange
231 computation of addends from section and global or local symbol
232 value. Change return type to bfd_boolean, and return a failure if
233 a dynamic FUNCDESC or FUNCDESC_VALUE relocation that requires a
234 nonzero addend is required.
235 (elf32_frv_relocate_section): Likewise. Print error for
236 unsupported nonzero addends.
237 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
238 * elf32-frv.c (FRV_SYM_LOCAL): In the absence of dynamic sections,
239 force everything local.
240 (_frv_emit_got_relocs_plt_entries): Cope with NULL sec.
241 * elf32-frv.c (struct frv_elf_link_hash_table): Added sgotfixup.
242 (frv_gotfixup_section): New.
243 (FRV_SYM_LOCAL): Accept undefweak and local common symbols.
244 (struct frv_pic_relocs_info): Split relocs into relocs32, relocsfd
245 and relocsfdv.
246 (_frv_add_rofixup): New.
247 (_frv_emit_got_relocs_plt_entries): Generate fixups for non-PIE
248 fdpic executables. Use FRV_SYM_LOCAL more widely to simplify and
249 improve some ugly conditions.
250 (elf32_frv_relocate_section): Likewise. Reject inter-segment
251 relocations in fdpic.
252 (_frv_create_got_section): Create .rofixup.got section.
253 (struct _frv_dynamic_got_info): Added fixups.
254 (_frv_count_got_plt_entries): Account in-GOT relocations into
255 relocs32, relocsfd and relocsfdv. Account them into relocs or
256 fixups, as appropriate.
257 (elf32_frv_size_dynamic_sections): Size rofixup section. Simplify
258 sizing of gotrel.
259 (elf32_frv_finish_dynamic_sections): Verify that the right number
260 of relocations and fixups was generated.
261 (elf32_frv_check_relocs): Compute relocs32, relocsfd and
262 relocsfdv.
263 * elf32-frv.c (FRV_SYM_LOCAL): New macro, used instead of
264 SYMBOL_CALLS_LOCAL and SYMBOL_REFERENCES_LOCAL.
265 (FRV_FUNCDESC_LOCAL): New macro, used to decide whether a function
266 descriptor of a (formerly-)global symbol is local.
267 (struct frv_pic_relocs_info): Adjust comments.
268 (_frv_emit_got_relocs_plt_entries): Adjust.
269 (elf32_frv_relocate_section): Likewise.
270 (_frv_count_got_plt_entries): Likewise.
271 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Don't add global
272 symbol's value to addend in the common preamble. Decay dynamic
273 symbols to section+offset if they bind or call locally, for GOT
274 and FUNCDESC_VALUE, respectively.
275 (elf32_frv_relocate_section): Likewise.
276 (elf32_frv_check_relocs): Don't register as dynamic symbols of
277 internal or hidden visibility.
278 2003-09-17 Alexandre Oliva <aoliva@redhat.com>
279 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Get addend as
280 argument, so as to not call _bfd_elf_rel_local_sym to compute it.
281 (elf32_frv_relocate_section): Pass relocation addend in. Use
282 original relocation addend to look up the got relocs/plt entries
283 table. Do not call _bfd_elf_rel_local_sym. Don't error out when
284 processing relocations that reference .scommon symbols.
285 2003-09-15 Alexandre Oliva <aoliva@redhat.com>
286 Introduce support for dynamic linking.
287 * elf32-frv.c (R_FRV_FUNCDESC_VALUE): Mark it as 64 bits.
288 (elf32_frv_rel_32_howto, elf32_frv_rel_funcdesc_howto,
289 elf32_frv_rel_funcdesc_value_howto): New REL descriptors.
290 (frv_reloc_type_lookup): Return REL howtos for executables and
291 dynamic libraries.
292 (frv_info_to_howto_rel): New.
293 (struct frv_elf_link_hash_table): New.
294 (frv_hash_table, frv_got_section, frv_gotrel_section,
295 frv_plt_section, frv_pltrel_section, frv_relocs_info,
296 frv_got_initial_offset, frv_plt_initial_offset): New macros.
297 (frv_elf_link_hash_table_create): New.
298 (struct frv_pic_relocs_info): New.
299 (frv_pic_relocs_info_hash, frv_pic_relocs_info_eq): New.
300 (frv_pic_relocs_info_find): New.
301 (frv_pic_relocs_info_for_global, frv_pic_relocs_info_for_local):
302 New.
303 (FRV_LZPLT_BLOCK_SIZE, FRV_LZPLT_RESOLVE_LOC): New.
304 (_frv_add_dyn_reloc, _frv_osec_to_segment): New.
305 (_frv_emit_got_relocs_plt_entries): New.
306 (elf32_frv_relocate_section): Add support for dynamic linking.
307 Handle new relocations.
308 (_frv_create_got_section): New.
309 (elf32_frv_create_dynamic_sections): New.
310 (ELF_DYNAMIC_INTERPRETER): New.
311 (struct _frv_dynamic_got_info): New.
312 (_frv_count_got_plt_entries): New.
313 (struct _frv_dynamic_got_plt_info): New.
314 (_frv_compute_got_alloc_data): New.
315 (_frv_get_got_entry, _frv_get_fd_entry): New.
316 (_frv_assign_got_entries, _frv_assign_plt_entries): New.
317 (_frv_resolve_final_relocs_info): New.
318 (elf32_frv_size_dynamic_sections): New.
319 (elf32_frv_finish_dynamic_sections): New.
320 (elf32_frv_adjust_dynamic_symbol): New.
321 (elf32_frv_finish_dynamic_symbol): New.
322 (elf32_frv_check_relocs): Handle new relocs. Explain how the
323 whole thing works.
324 (elf_info_to_howto_rel): Define.
325 (bfd_elf32_bfd_link_hash_table_create): Define.
326 (elf_backend_create_dynamic_sections): Define.
327 (elf_backend_adjust_dynamic_symbol): Define.
328 (elf_backend_size_dynamic_sections): Define.
329 (elf_backend_finish_dynamic_symbol): Define.
330 (elf_backend_finish_dynamic_sections): Define.
331 (elf_backend_want_got_sym): Define.
332 (elf_backend_got_header_size): Define.
333 (elf_backend_want_got_plt): Define.
334 (elf_backend_plt_readonly): Define.
335 (elf_backend_want_plt_sym): Define.
336 (elf_backend_plt_header_size): Define.
337 (elf_backend_may_use_rel_p): Define.
338 (elf_backend_may_use_rela_p): Define.
339 (elf_backend_default_use_rela_p): Define.
340 2003-08-08 Alexandre Oliva <aoliva@redhat.com>
341 * elf32-frv.c (R_FRV_FUNCDESC_VALUE, R_FRV_FUNCDESC_GOTOFF12,
342 R_FRV_FUNCDESC_GOTOFFHI, R_FRV_FUNCDESC_GOTOFFLO, R_FRV_GOTOFF12,
343 R_FRV_GOTOFFHI, R_FRV_GOTOFFLO): New.
344 (frv_reloc_map): Map the corresponding BFD relocs to them.
345 (frv_reloc_type_lookup): ... and back to BFD relocs.
346 * reloc.c: New relocs.
347 * bfd-in2.h, libbfd.h: Rebuilt.
348 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
349 * elf32-frv.c (R_FRV_GOT12, R_FRV_GOTHI, R_FRV_GOTLO,
350 R_FRV_FUNCDESC, R_FRV_FUNCDESC_GOT12, R_FRV_FUNCDESC_GOTHI,
351 R_FRV_FUNCDESC_GOTLO): New.
352 (frv_reloc_map): Map the corresponding BFD relocs to them.
353 (frv_reloc_type_lookup): ... and back to BFD relocs.
354 * reloc.c: New relocs.
355 * bfd-in2.h, libbfd.h: Rebuilt.
356
357 2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
358
359 * elf32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
360 targets to support pages of up to 64kB.
361 (elf32_bed): Redefine to get a separate backend data structure for
362 traditional targets.
363 * elf64-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
364 targets to support pages of up to 64kB.
365 (elf64_bed): Redefine to get a separate backend data structure for
366 traditional targets.
367 * elfn32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
368 targets to support pages of up to 64kB.
369 (elf32_bed): Redefine to get a separate backend data structure for
370 traditional targets.
371
372 2004-01-04 Mark Kettenis <kettenis@gnu.org>
373
374 * elf32-sparc.c (elf32_sparc_grok_psinfo): New function.
375
376 2004-01-02 Mark Kettenis <kettenis@gnu.org>
377
378 * elf32-i386.c (elf_i386_grok_prstatus): Add support for FreeBSD.
379 (elf_i386_grok_psinfo): Likewise.
380
381 2004-01-02 Bernardo Innocenti <bernie@develer.com>
382
383 * config.bfd: Add m68k-uClinux target.
384
385 2004-01-01 Grant Edwards <grante@visi.com>
386
387 * elflink.h (elf_gc_sections): Warn when gc-sections option is ignored.
388 * elf32-h8300.c (elf32_h8_gc_mark_hook): New function.
389 (elf32_h8_gc_sweep_hook): New function.
390 (elf_backend_gc_mark_hook): Define.
391 (elf_backend_gc_sweep_hook): Define.
392 (elf_backend_can_gc_sections): Define.
393
394 For older changes see ChangeLog-0203
395 \f
396 Local Variables:
397 mode: change-log
398 left-margin: 8
399 fill-column: 74
400 version-control: never
401 End: