Commit Graph

120 Commits

Author SHA1 Message Date
Jakub Jelinek d7b37ebf0a * elf-bfd.h (enum elf_link_info_type): New.
(struct bfd_elf_section_data): Remove stab_info and merge_info
	fields, add sec_info and sec_info_type.
	(struct elf_obj_tdata): Add eh_frame_hdr field.
	(_bfd_elf_discard_section_eh_frame): New prototype.
	(_bfd_elf_discard_section_eh_frame_hdr): Likewise.
	(_bfd_elf_eh_frame_section_offset): Likewise.
	(_bfd_elf_write_section_eh_frame): Likewise.
	(_bfd_elf_write_section_eh_frame_hdr): Likewise.
	* Makefile.am (BFD32_BACKENDS): Add elf-eh-frame.lo.
	(BFD32_BACKENDS_CFILES): Add elf-eh-frame.c.
	(elf-eh-frame.lo): New.
	* Makefile.in: Rebuilt.
	* configure.in (elf): Add elf-eh-frame.lo.
	* configure: Rebuilt.
	* elf.c (_bfd_elf_print_private_bfd_data): Support PT_GNU_EH_FRAME.
	(map_sections_to_segments): Create PT_GNU_EH_FRAME if requested.
	(get_program_header_size): Take into account PT_GNU_EH_FRAME
	segment.
	(_bfd_elf_rela_local_sym): Use sec_info_type and sec_info.
	(_bfd_elf_rel_local_sym): Likewise.
	(_bfd_elf_section_offset): Likewise.  Call
	_bfd_elf_eh_frame_section_offset too.
	* elfxx-ia64.c (elfNN_ia64_relocate_section): Use sec_info_type and
	sec_info.
	* elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
	* elf-eh-frame.c: New file.
	* elflink.h (elf_link_add_object_symbols): Don't optimize SHF_MERGE
	.stab sections.  Set sec_info_type, use sec_info instead
	of merge_info and stab_info.
	(elf_link_create_dynamic_sections): Create .eh_frame_hdr section
	if --eh-frame-hdr.
	(elf_bfd_final_link): Write .eh_frame_hdr section.
	(elf_link_sec_merge_syms): Use sec_info_type and sec_info.
	(elf_link_input_bfd): Likewise.
	Call _bfd_elf_write_section_eh_frame to write .eh_frame sections.
	(elf_bfd_discard_info): Add output_bfd argument.
	Call _bfd_elf_discard_section_eh_frame and
	_bfd_elf_discard_section_eh_frame_hdr.
	(elf_section_ignore_discarded_relocs): Use sec_info_type, not section
	names.
	* bfd-in.h (bfd_elf32_discard_info, bfd_elf64_discard_info): Adjust
	prototypes.
	* bfd-in2.h (bfd_elf32_discard_info, bfd_elf64_discard_info): Likewise.

	* elf/common.h (PT_GNU_EH_FRAME): Define.
	* bfdlink.h (struct bfd_link_info): Add eh_frame_hdr field.

	* emultempl/elf32.em (finish): Supply output_bfd
	to bfd_elf*_discard_info.
	(OPTION_EH_FRAME_HDR): Define.
	(longopts): Add --eh-frame-hdr.
	(parse_args): Handle it.
	(list_options): Add --eh-frame-hdr to help.
	* emultempl/hppaelf.em (finish): Supply output_bfd
	to bfd_elf*_discard_info.
	* scripttempl/elf.sc (.eh_frame_hdr): Add.

	* readelf.c (get_segment_type): Support PT_GNU_EH_FRAME.
2001-12-13 11:09:33 +00:00
Alan Modra 51bc3a7385 * common.h (SHN_XINDEX): Comment typo fix.
* internal.h (Elf_Internal_Ehdr): Change existing "unsigned short"
	size, count and index fields to "unsigned int".
2001-12-11 05:37:33 +00:00
Geoffrey Keating 170f4c4350 Index: bfd/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>
	    Richard Henderson  <rth@redhat.com>
	    Corinna Vinschen  <vinschen@redhat.com>

	* Makefile.am: Add support for xstormy16.
	* archures.c: Add support for xstormy16.
	* config.bfd: Add support for xstormy16.
	* configure.in: Add support for xstormy16.
	* reloc.c: Add support for xstormy16.
	* targets.c: Add support for xstormy16.
	* cpu-xstormy16.c: New file.
	* elf32-xstormy16.c: New file.
	* Makefile.in: Regenerated.
	* bfd-in2.h: Regenerated.
	* configure: Regenerated.
	* libbfd.h: Regenerated.

Index: binutils/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>

	* readelf.c (guess_is_rela): Add support for stormy16.
	(dump_relocations): Likewise.
	(get_machine_name): Likewise.

Index: gas/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>
	    Richard Henderson  <rth@redhat.com>

	* configure.in: Add support for xstormy16.
	* configure: Regenerated.
	* Makefile.am: Add support for xstormy16.
	* Makefile.in: Regenerated.
	* config/tc-xstormy16.c: New file.
	* config/tc-xstormy16.h: New file.

Index: gas/testsuite/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>
	    matthew green  <mrg@redhat.com>

	* gas/xstormy16/allinsn.d: New file.
	* gas/xstormy16/allinsn.exp: New file.
	* gas/xstormy16/allinsn.s: New file.
	* gas/xstormy16/allinsn.sh: New file.
	* gas/xstormy16/gcc.d: New file.
	* gas/xstormy16/gcc.s: New file.
	* gas/xstormy16/gcc.sh: New file.
	* gas/xstormy16/reloc-1.d: New file.
	* gas/xstormy16/reloc-1.s: New file.
	* gas/xstormy16/reloc-2.d: New file.
	* gas/xstormy16/reloc-2.s: New file.

Index: ld/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>
	    Richard Henderson  <rth@redhat.com>

	* Makefile.am: Add support for xstormy16.
	* configure.tgt: Add support for xstormy16.
	* Makefile.in: Regenerate.
	* emulparams/elf32xstormy16.sh: New file.
	* scripttempl/xstormy16.sc: New file.

Index: opcodes/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>

	* Makefile.am: Add support for xstormy16.
	* Makefile.in: Regenerate.
	* configure.in: Add support for xstormy16.
	* configure: Regenerate.
	* disassemble.c: Add support for xstormy16.
	* xstormy16-asm.c: New generated file.
	* xstormy16-desc.c: New generated file.
	* xstormy16-desc.h: New generated file.
	* xstormy16-dis.c: New generated file.
	* xstormy16-ibld.c: New generated file.
	* xstormy16-opc.c: New generated file.
	* xstormy16-opc.h: New generated file.

Index: include/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>

	* dis-asm.h (print_insn_xstormy16): Declare.

Index: include/elf/ChangeLog
2001-12-07  Geoffrey Keating  <geoffk@redhat.com>
	    Richard Henderson  <rth@redhat.com>

	* common.h (EM_XSTORMY16): Define.
	* xstormy16.h: New file.
2001-12-08 03:46:03 +00:00
Alan Modra ed97f12cd3 * common.h (NT_ARCH): Define. Remove incorrect comment. 2001-11-15 13:19:10 +00:00
Geoffrey Keating 7a43fd8be1 Index: bfd/ChangeLog
2001-11-11  Geoffrey Keating  <geoffk@redhat.com>

	* dwarf2.c (decode_line_info): Properly deal with unknown standard
	opcodes.

Index: binutils/ChangeLog
2001-11-11  Geoffrey Keating  <geoffk@redhat.com>

	* readelf.c (display_debug_lines): Deal with unknown standard
	opcodes.  Handle DW_LNS_set_prologue_end, DW_LNS_set_epilogue_begin,
	DW_LNS_set_isa.

Index: include/elf/ChangeLog
2001-11-11  Geoffrey Keating  <geoffk@redhat.com>

	* dwarf2.h (dwarf_line_number_ops): Add DWARF 3 opcodes.
2001-11-13 20:13:30 +00:00
Nick Clifton 39374014e7 Add MMIX support 2001-10-30 15:20:10 +00:00
Alan Modra 7309890a90 * internal.h: White space changes to keep lines under 80 chars. 2001-10-23 04:42:12 +00:00
Jeff Holcomb c4d5c46a4d 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
* internal.h (elf_internal_shdr): Make contents a unsigned char *.
2001-10-17 01:44:50 +00:00
Alan Modra 8b77cd2503 * internal.h (elf_internal_rela): Make r_addend a bfd_vma. 2001-09-18 10:01:41 +00:00
Alexandre Oliva b011df87d1 * common.h (EM_OPENRISC_OLD): Renamed the old EM_OPENRISC entry. 2001-09-13 21:02:21 +00:00
Alexandre Oliva 75fc1764dc * common.h (EM_AVR_OLD): Renamed from...
(EM_AVR): this, redefined as in the current ELF standard.
(EM_PJ_OLD): Renamed from...
(EM_PJ): this, redefined as in the current ELF standard.
(EM_R30, EM_D10V, EM_D30V, EM_V850, EM_M32R, EM_MN10300,
EM_MN10200, EM_OPENRISC, EM_ARC_A5, EM_XTENSA): Defined as in
the current ELF standard.
(EM_CYGNUS_ARC): Removed, unused for a long time.
2001-09-12 23:53:09 +00:00
Richard Henderson 0bcb0f6a0e * alpha.h (R_ALPHA_OP*, R_ALPHA_IMMED*, R_ALPHA_GPVALUE): Remove.
(R_ALPHA_GPREL16): Rename from R_ALPHA_IMMED_GP_16.
2001-09-05 02:54:37 +00:00
Eric Christopher a26a4cdbe0 mips3264 support 2001-08-31 21:21:54 +00:00
Jeff Law 3ab7340b94 * h8.h (EF_H8_MACH): New mask for encoded machine type.
(E_H8_MACH_H8300, E_H8_MACH_H8300H, E_H8_MACH_H8300S): New
        machine types.
2001-08-29 17:23:39 +00:00
Joern Rennecke a06a7fb451 * h8.h: New file. 2001-08-28 22:33:27 +00:00
Alan Modra 435b1d99a9 * ppc.h: Add relocs from the 64-bit PowerPC ELF ABI revision 1.2. 2001-08-27 10:26:34 +00:00
Nick Clifton 518117ea0f Remerge with gcc 2001-06-30 08:58:10 +00:00
Nick Clifton 1e8b3ce280 Add DWARF 2.1 attributes 2001-06-29 14:17:31 +00:00
Per Bothner db77b1b43e * dwarf2.h: Partial merge with gcc version.
(enum dwarf_descrim_list):  Fix typo -> dwarf_discrim_list.
	(DW_LANG_Java):  Use value from dwarf 2.1 draft (also used in gcc).
2001-06-15 19:53:18 +00:00
Alan Modra 51352f8ed0 Fix some entries. 2001-05-28 10:37:50 +00:00
Nick Clifton 75f9ca7b0c Remove definition of EM_MIPS_RS4_BE. The constant was never in active use
and is used otherwise by the ABI.
2001-05-15 12:24:29 +00:00
Jakub Jelinek 0b671586c0 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
sections as well.
	(elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
	to .gnu.linkonce.t.FOO text section.

	* readelf.c (process_unwind): Print all unwind sections, not just
	one.

	* config/tc-ia64.c (special_linkonce_name): New.
	(make_unw_section): Map .gnu.linkonce.t.FOO text section into
	.gnu.linkonce.ia64unw{,i}.FOO.
	(ia64_elf_section_type): Handle .gnu.linkonce.ia64unw{,i}.FOO.
	(dot_endp): Add comment about it.

	* elf/ia64.h (ELF_STRING_ia64_unwind_once): Define.
	(ELF_STRING_ia64_unwind_info_once): Define.

	* emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Put
	.gnu.linkonce.ia64unw{,i} sections into corresponding .IA_64.unwind*
	output sections.
	* emulparams/elf64_aix.sh (OTHER_READONLY_SECTIONS): Likewise.
2001-05-11 12:36:47 +00:00
Alan Modra c9b76619ac * external.h: Fix typo.
* mips.h: Add/Extend many comments with reference to the MIPS ELF64
	spec v. 2.4, available at e.g.
	ftp://oss.sgi.com/pub/linux/mips/doc/ABI/ELF64.ps.
	(EF_MIPS_UCODE): Define.
	(EF_MIPS_OPTIONS_FIRST): Define.
	(EF_MIPS_ARCH_ASE): Define.
	(EF_MIPS_ARCH_ASE_MDMX): Define.
	(EF_MIPS_ARCH_ASE_M16): Define.
	(SHF_MIPS_ADDR): Renamed SHF_MIPS_ADDR32.
	(SHF_MIPS_STRING): Renamed SHF_MIPS_ADDR64.
	(SHF_MIPS_NODUPES): Define.
	(ELF64_MIPS_R_SSYM): New MIPS ELF 64 relocation info access macro.
	(ELF64_MIPS_R_TYPE3): Likewise.
	(ELF64_MIPS_R_TYPE2): Likewise.
	(ELF64_MIPS_R_TYPE): Likewise.
	(OHW_R10KLDL): Define.
2001-05-07 09:18:52 +00:00
DJ Delorie 96d16d1c11 * sparc.h: Fix typo. 2001-04-24 18:32:27 +00:00
Nick Clifton 19a90cfeaf Add OpenRISC support 2001-04-24 15:08:16 +00:00
Andreas Jaeger 4ba81bbab2 2001-04-23 Bo Thorsen <bo@suse.de>
* x86-64.h: Add vtable support.

2001-04-23  Bo Thorsen  <bo@suse.de>

	* elf64-x86-64.c: Add c++ vtable hack.
	Small whitespace and comment changes.
2001-04-23 08:00:14 +00:00
Nick Clifton 5c3393d227 Remove extraneous whitespace 2001-03-24 00:46:00 +00:00
Hans-Peter Nilsson e086534fc6 * cris.h: Add leading comment about PC-relative location.
(R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
	R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
	R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL):
	New relocs.
2001-03-22 13:03:58 +00:00
Nick Clifton c77e3e5481 Fix typos in ChangeLogs; add coff/external.h; fix copyright dates 2001-03-14 02:27:44 +00:00
Phil Blundell cf2fe7531d 2001-02-27 Philip Blundell <pb@futuretv.com>
* arm.h: Add new definitions from ARM document SWS ESPC 0003 B-01.
	(EF_PIC, et al.): Rename to EF_ARM_xx.
2001-02-28 10:11:36 +00:00
Nick Clifton 70bf79a017 Remove annoying entry....:-) 2001-02-10 22:30:07 +00:00
Nick Clifton 1e667f61b7 Add s390 support 2001-02-10 00:58:38 +00:00
Nick Clifton c9bd08bcb2 Updated ARC assembler from arccores.com 2001-01-11 21:20:19 +00:00
Nick Clifton 5092a8140b Fix Formatting. 2000-12-12 19:25:07 +00:00
Jeff Law a7eaccae3a * hppa.h (DT_HP_*): Define relative to OLD_DT_LOOS for hpux
compatibility.
2000-12-11 17:55:58 +00:00
Nick Clifton 294f81d78d Add MIPS SB1 machine 2000-12-02 01:10:33 +00:00
Nick Clifton f9fe8a8ead Add MIPS V and MIPS 64 machine numbers 2000-12-02 00:55:22 +00:00
Nick Clifton 388732e7f6 Add MIPS32 as a seperate MIPS architecture 2000-12-01 21:35:38 +00:00
Nick Clifton f24bad4181 Add x86-64 support files. 2000-11-30 19:05:18 +00:00
Hans-Peter Nilsson 91797c6d8e * common.h (e_machine numbers): Clarify comments to describe how
EM_* constants are assigned.  Move EM_PJ from official section to
	ad-hoc section.
	(EM_CRIS): Correct comment to match official description.
	(EM_MMIX): Ditto.
2000-11-27 21:52:56 +00:00
Nick Clifton 58b9bd9493 Add new ELF ABI defines 2000-11-22 23:19:15 +00:00
H.J. Lu b63f2ed244 2000-11-20 H.J. Lu <hjl@gnu.org>
* common.h (ELFOSABI_MONTEREY): Renamed to ...
	(ELFOSABI_AIX): This.
2000-11-20 23:45:42 +00:00
Richard Henderson c302181722 Update relocations per August psABI docs.
* ia64.h (R_IA64_SEGBASE): Remove.
        (R_IA64_LTV*): Renumber to 0x74 to 0x77.
        (R_IA64_EPLTMSB, R_IA64_EPLTLSB): Remove.
        (R_IA64_TPREL14, R_IA64_TPREL64I): New.
        (R_IA64_DTPMOD*): New.
        (R_IA64_DTPREL*): New.
2000-11-16 22:48:14 +00:00
Hans-Peter Nilsson 2470ae91c3 * cris.h (EF_CRIS_UNDERSCORE): New. 2000-09-29 16:52:42 +00:00
Alan Modra a3bb629e96 .plt stub for lazy linking, --stub-group-size=N ld switch,
import stub fix, extra DIR14F reloc to fix abort in tc_gen_reloc
2000-09-27 17:30:17 +00:00
Alexandre Oliva b162f39709 * sh.h (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): Change
numbers to the range from 160 to 167.
(R_SH_FIRST_INVALID_RELOC): Adjust.
(R_SH_FIRST_INVALID_RELOC_2, R_SH_LAST_INVALID_RELOC_2):
New relocs to fill in the gap.
2000-09-14 04:56:55 +00:00
Nick Clifton 67b0ce5ff0 Add support for the MIPS32 2000-09-14 01:47:37 +00:00
Alan Modra 108952ea1d Add some reloc types. 2000-09-05 02:14:38 +00:00
Alexandre Oliva 6994f0f102 * sh.h (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New relocs.
(R_SH_FIRST_INVALID_RELOC): Adjust.
2000-09-02 02:24:02 +00:00
Jim Wilson 6d529a974b Add support for IA-64 specific elf header flags.
bfd/
2000-08-14  Jim Wilson  <wilson@cygnus.com>
	* elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
	EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
	(elf64_ia64_print_private_bfd_data): Likewise.  Also handle
	EF_IA_64_ABSOLUTE.
gas/
2000-08-14  Jim Wilson  <wilson@cygnus.com>
	* config/tc-ia64.c (md_longopts): Add -mconstant-gp and -mauto-pic.
	(md_parse_option):  Add OPTION_MCONSTANT_GP and OPTION_MAUTO_PIC.
	(md_begin): Change assignment to md.flag to OR in the new bit.
include/elf/
2000-08-14  Jim Wilson  <wilson@cygnus.com>
	* elf/ia64.h (EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP,
	EF_IA_64_NOFUNCDESC_CONS_GP, EF_IA_64_ABSOLUTE): Define.
2000-08-14 20:13:39 +00:00