diff options
Diffstat (limited to 'include/elf')
-rw-r--r-- | include/elf/ChangeLog | 166 | ||||
-rw-r--r-- | include/elf/arm.h | 38 | ||||
-rw-r--r-- | include/elf/avr.h | 5 | ||||
-rw-r--r-- | include/elf/common.h | 16 | ||||
-rw-r--r-- | include/elf/cr16.h | 56 | ||||
-rw-r--r-- | include/elf/dwarf2.h | 1 | ||||
-rw-r--r-- | include/elf/external.h | 6 | ||||
-rw-r--r-- | include/elf/hppa.h | 50 | ||||
-rw-r--r-- | include/elf/internal.h | 58 | ||||
-rw-r--r-- | include/elf/m68k.h | 32 | ||||
-rw-r--r-- | include/elf/mep.h | 84 | ||||
-rw-r--r-- | include/elf/mips.h | 14 | ||||
-rw-r--r-- | include/elf/ppc.h | 11 | ||||
-rw-r--r-- | include/elf/reloc-macros.h | 2 | ||||
-rw-r--r-- | include/elf/score.h | 123 | ||||
-rw-r--r-- | include/elf/spu.h | 60 | ||||
-rw-r--r-- | include/elf/v850.h | 9 | ||||
-rw-r--r-- | include/elf/xtensa.h | 4 |
18 files changed, 653 insertions, 82 deletions
diff --git a/include/elf/ChangeLog b/include/elf/ChangeLog index 48ce81c1354a..ba08331c4c02 100644 --- a/include/elf/ChangeLog +++ b/include/elf/ChangeLog @@ -1,3 +1,169 @@ +2007-06-29 Joseph Myers <joseph@codesourcery.com> + + * ppc.h (Tag_GNU_Power_ABI_FP): Define. + +2007-06-29 Joseph Myers <joseph@codesourcery.com> + + * mips.h (Tag_GNU_MIPS_ABI_FP): Define. + +2007-06-29 Joseph Myers <joseph@codesourcery.com> + + * arm.h (elf32_arm_add_eabi_attr_int, + elf32_arm_add_eabi_attr_string, elf32_arm_add_eabi_attr_compat, + elf32_arm_get_eabi_attr_int, elf32_arm_set_eabi_attr_contents, + elf32_arm_eabi_attr_size, Tag_NULL, Tag_File, Tag_Section, + Tag_Symbol, Tag_compatibility): Remove. + * common.h (SHT_GNU_ATTRIBUTES): Define. + +2007-06-29 M R Swami Reddy <MR.Swami.Reddy@nsc.com> + + * common.h (EM_CR16): New entry for CR16 cpu. + * cr16.h: New file. + +2007-06-11 Sterling Augustine <sterling@tensilica.com> + Bob Wilson <bob.wilson@acm.org> + + * xtensa.h (XTENSA_PROP_INSN_NO_TRANSFORM): Renamed to... + (XTENSA_PROP_NO_TRANSFORM): ...this. + +2007-05-18 Caroline Tice <ctice@apple.com> + + * dwarf2.h: (enum dwarf_location_atom): Add new DW_OP, + DW_OP_GNU_uninit. + +2007-05-12 Alan Modra <amodra@bigpond.net.au> + + * spu.h (R_SPU_ADDR16X): Define. + (R_SPU_PPU32, R_SPU_PPU64): Renumber. + +2007-05-11 Alan Modra <amodra@bigpond.net.au> + + * spu.h (R_SPU_PPU32, R_SPU_PPU64): Define. + +2007-05-02 Alan Modra <amodra@bigpond.net.au> + + * internal.h (ELF_IS_SECTION_IN_SEGMENT): Check both file offset + and vma for appropriate sections. + +2007-04-26 Jan Beulich <jbeulich@novell.com> + + * common.h (DT_ENCODING): Correct value (back to spec mandated + value). + +2007-03-08 Alan Modra <amodra@bigpond.net.au> + + * v850.h (V850_OTHER_TDA_BYTE): Delete. + (V850_OTHER_SDA, V850_OTHER_ZDA, V850_OTHER_TDA): Assign bits + that don't clash with visibility bits. + +2007-03-07 Alan Modra <amodra@bigpond.net.au> + + * common.h (ELF_ST_VISIBILITY): Comment typo fix. + +2007-02-05 Dave Brolley <brolley@redhat.com> + Richard Sandiford <rsandifo@redhat.com> + Richard Henderson <rth@redhat.com> + DJ Delorie <dj@redhat.com> + Ben Elliston <bje@redhat.com> + + * mep.h: New file. + * common.h (EM_CYGNUS_MEP): Define. + +2007-02-15 Dave Brolley <brolley@redhat.com> + + From Graydon Hoare <graydon@redhat.com>: + * common.h (STT_RELC, STT_SRELC, R_RELC): New macros. + +2007-01-08 Kazu Hirata <kazu@codesourcery.com> + + * m68k.h (EF_M68K_FIDO): New. + (EF_M68K_ARCH_MASK): OR EF_M68K_FIDO. + (EF_M68K_CPU32_FIDO_A, EF_M68K_CPU32_MASK): Remove. + +2006-12-25 Kazu Hirata <kazu@codesourcery.com> + + * m68k.h (EF_M68K_CPU32_FIDO_A, EF_M68K_CPU32_MASK): New. + +2006-12-19 Kazu Hirata <kazu@codesourcery.com> + + * m68k.h (EF_M68K_ARCH_MASK): New. + +2006-12-19 Nathan Sidwell <nathan@codesourcery.com> + + * internal.h (struct elf_segment_map): Add p_vaddr_offset field. + +2006-12-07 Kazu Hirata <kazu@codesourcery.com> + + * m68k.h (EF_M68K_ISA_MASK, EF_M68K_ISA_A_NODIV, + EF_M68K_ISA_A, EF_M68K_ISA_A_PLUS, EF_M68K_ISA_B_NOUSP, + EF_M68K_ISA_B, EF_M68K_ISA_C, EF_M68K_MAC_MASK, EF_M68K_MAC, + EF_M68K_EMAC, EF_M68K_EMAC_B, EF_M68K_FLOAT): Rename to + EF_M68K_CF_ISA_MASK, EF_M68K_CF_ISA_A_NODIV, EF_M68K_CF_ISA_A, + EF_M68K_CF_ISA_A_PLUS, EF_M68K_CF_ISA_B_NOUSP, + EF_M68K_CF_ISA_B, EF_M68K_CF_ISA_C, EF_M68K_CF_MAC_MASK, + EF_M68K_CF_MAC, EF_M68K_CF_EMAC, EF_M68K_CF_EMAC_B, + EF_M68K_CF_FLOAT, respectively. + +2006-12-05 Michael Tautschnig <tautschn@model.in.tum.de> + Nick Clifton <nickc@redhat.com> + + * external.h (struct Elf_External_Versym): Use ATTRIBUTE_PACKED. + +2006-10-28 Richard Sandiford <richard@codesourcery.com> + + * mips.h (R_MIPS_GLOB_DAT): Define + (R_MIPS_max): Bump by 1. + +2006-10-25 Trevor Smigiel <Trevor_Smigiel@playstation.sony.com> + Yukishige Shibata <shibata@rd.scei.sony.co.jp> + Nobuhisa Fujinami <fnami@rd.scei.sony.co.jp> + Takeaki Fukuoka <fukuoka@rd.scei.sony.co.jp> + Alan Modra <amodra@bigpond.net.au> + + * common.h (EM_SPU): Define. + * spu.h: New file. + +2006-10-19 Mei Ligang <ligang@sunnorth.com.cn> + + * score.h (EF_SCORE_PIC): Redefine EF_SCORE_PIC as 0x80000000. + (EF_SCORE_FIXDEP): Redefine EF_SCORE_FIXDEP as 0x40000000. + (EF_SCORE_HASENTRY): Delete. + +2006-09-17 Mei Ligang <ligang@sunnorth.com.cn> + + * score.h: New file. + * common.h: Add Score machine number. + +2006-07-10 Jakub Jelinek <jakub@redhat.com> + + * common.h (SHT_GNU_HASH, DT_GNU_HASH): Define. + +2006-05-31 H.J. Lu <hongjiu.lu@intel.com> + + * internal.h (ELF_SECTION_SIZE): New. + (ELF_IS_SECTION_IN_SEGMENT): Likewise. + (ELF_IS_SECTION_IN_SEGMENT_FILE): Updated. + (ELF_IS_SECTION_IN_SEGMENT_MEMORY): Likewise. + +2006-05-27 H.J. Lu <hongjiu.lu@intel.com> + + * internal.h (struct elf_segment_map): Add p_align and p_align_valid. + +2006-05-24 Carlos O'Donell <carlos@systemhalted.org> + Randolph Chung <randolph@tausq.org> + * hppa.h (R_PARISC_TLS_GD21L, R_PARISC_TLS_GD14R, R_PARISC_TLS_GDCALL, + R_PARISC_TLS_LDM21L, R_PARISC_TLS_LDM14R, R_PARISC_TLS_LDMCALL, + R_PARISC_TLS_LDO21L, R_PARISC_TLS_LDO14R, R_PARISC_TLS_DTPMOD32, + R_PARISC_TLS_DTPMOD64, R_PARISC_TLS_DTPOFF32, R_PARISC_TLS_DTPOFF64): + New TLS relocs. + (R_PARISC_TLS_LE21L, R_PARISC_TLS_LE14R, R_PARISC_TLS_IE21L, + R_PARISC_TLS_IE14R, R_PARISC_TLS_TPREL32, R_PARISC_TLS_TPREL64): + Define TLS relocs using existing equivalents. + +2006-05-24 Bjoern Haase <bjoern.m.haase@web.de> + + * avr.h: Add E_AVR_MACH_AVR6, R_AVR_LO8_LDI_GS and R_AVR_HI8_LDI_GS. + 2006-03-22 Richard Sandiford <richard@codesourcery.com> Daniel Jacobowitz <dan@codesourcery.com> Phil Edwards <phil@codesourcery.com> diff --git a/include/elf/arm.h b/include/elf/arm.h index 8311c131c99c..e70188338786 100644 --- a/include/elf/arm.h +++ b/include/elf/arm.h @@ -84,6 +84,19 @@ #define PF_ARM_PI 0x20000000 /* Segment is position-independent. */ #define PF_ARM_ABS 0x40000000 /* Segment must be loaded at its base address. */ +/* Values for the Tag_CPU_arch EABI attribute. */ +#define TAG_CPU_ARCH_PRE_V4 0 +#define TAG_CPU_ARCH_V4 1 +#define TAG_CPU_ARCH_V4T 2 +#define TAG_CPU_ARCH_V5T 3 +#define TAG_CPU_ARCH_V5TE 4 +#define TAG_CPU_ARCH_V5TEJ 5 +#define TAG_CPU_ARCH_V6 6 +#define TAG_CPU_ARCH_V6KZ 7 +#define TAG_CPU_ARCH_V6T2 8 +#define TAG_CPU_ARCH_V6K 9 +#define TAG_CPU_ARCH_V7 10 + /* Relocation types. */ START_RELOC_NUMBERS (elf_arm_reloc_type) @@ -169,9 +182,9 @@ START_RELOC_NUMBERS (elf_arm_reloc_type) RELOC_NUMBER (R_ARM_LDRS_SB_G0, 78) RELOC_NUMBER (R_ARM_LDRS_SB_G1, 79) RELOC_NUMBER (R_ARM_LDRS_SB_G2, 80) - RELOC_NUMBER (R_ARM_LDC_G0, 81) - RELOC_NUMBER (R_ARM_LDC_G1, 82) - RELOC_NUMBER (R_ARM_LDC_G2, 83) + RELOC_NUMBER (R_ARM_LDC_SB_G0, 81) + RELOC_NUMBER (R_ARM_LDC_SB_G1, 82) + RELOC_NUMBER (R_ARM_LDC_SB_G2, 83) RELOC_NUMBER (R_ARM_MOVW_BREL_NC, 84) RELOC_NUMBER (R_ARM_MOVT_BREL, 85) RELOC_NUMBER (R_ARM_MOVW_BREL, 86) @@ -221,26 +234,15 @@ START_RELOC_NUMBERS (elf_arm_reloc_type) FAKE_RELOC (R_ARM_GOT32, R_ARM_GOT_BREL) /* 32 bit GOT entry. */ FAKE_RELOC (R_ARM_ROSEGREL32, R_ARM_SBREL31) /* ??? */ FAKE_RELOC (R_ARM_AMP_VCALL9, R_ARM_BREL_ADJ) /* Thumb-something. Not used. */ - FAKE_RELOC (R_ARM_PC13, R_ARM_LDR_PC_G0) /* Unclear whether meaning is different. */ END_RELOC_NUMBERS (R_ARM_max) #ifdef BFD_ARCH_SIZE -/* Routines for manipulating EABI object attributes. */ -void elf32_arm_add_eabi_attr_int (bfd *, int, unsigned int); -void elf32_arm_add_eabi_attr_string (bfd *, int, const char *); -void elf32_arm_add_eabi_attr_compat (bfd *, unsigned int, const char *); -int elf32_arm_get_eabi_attr_int (bfd *, int); - -void elf32_arm_set_eabi_attr_contents (bfd *, bfd_byte *, bfd_vma); -bfd_vma elf32_arm_eabi_attr_size (bfd *); +/* EABI object attributes. */ enum { - Tag_NULL, - Tag_File, - Tag_Section, - Tag_Symbol, - Tag_CPU_raw_name, + /* 0-3 are generic. */ + Tag_CPU_raw_name = 4, Tag_CPU_name, Tag_CPU_arch, Tag_CPU_arch_profile, @@ -268,7 +270,7 @@ enum Tag_ABI_WMMX_args, Tag_ABI_optimization_goals, Tag_ABI_FP_optimization_goals, - Tag_compatibility, + /* 32 is generic. */ }; #endif diff --git a/include/elf/avr.h b/include/elf/avr.h index f16043805eb6..d2ffbe07f622 100644 --- a/include/elf/avr.h +++ b/include/elf/avr.h @@ -1,5 +1,5 @@ /* AVR ELF support for BFD. - Copyright 1999, 2000, 2004 Free Software Foundation, Inc. + Copyright 1999, 2000, 2004, 2006 Free Software Foundation, Inc. Contributed by Denis Chertykov <denisc@overta.ru> This file is part of BFD, the Binary File Descriptor library. @@ -35,6 +35,7 @@ #define E_AVR_MACH_AVR3 3 #define E_AVR_MACH_AVR4 4 #define E_AVR_MACH_AVR5 5 +#define E_AVR_MACH_AVR6 6 /* Relocations. */ START_RELOC_NUMBERS (elf_avr_reloc_type) @@ -62,6 +63,8 @@ START_RELOC_NUMBERS (elf_avr_reloc_type) RELOC_NUMBER (R_AVR_6_ADIW, 21) RELOC_NUMBER (R_AVR_MS8_LDI, 22) RELOC_NUMBER (R_AVR_MS8_LDI_NEG, 23) + RELOC_NUMBER (R_AVR_LO8_LDI_GS, 24) + RELOC_NUMBER (R_AVR_HI8_LDI_GS, 25) END_RELOC_NUMBERS (R_AVR_max) #endif /* _ELF_AVR_H */ diff --git a/include/elf/common.h b/include/elf/common.h index b11171b56b40..2eb6853e6669 100644 --- a/include/elf/common.h +++ b/include/elf/common.h @@ -1,6 +1,6 @@ /* ELF support for BFD. Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, - 2001, 2002, 2003, 2004, 2005, 2006 + 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. Written by Fred Fish @ Cygnus Support, from information published @@ -118,6 +118,7 @@ #define EM_PPC 20 /* PowerPC */ #define EM_PPC64 21 /* 64-bit PowerPC */ #define EM_S390 22 /* IBM S/390 */ +#define EM_SPU 23 /* Sony/Toshiba/IBM SPU */ #define EM_V800 36 /* NEC V800 series */ #define EM_FR20 37 /* Fujitsu FR20 */ @@ -185,6 +186,8 @@ #define EM_BLACKFIN 106 /* ADI Blackfin */ #define EM_ALTERA_NIOS2 113 /* Altera Nios II soft-core processor */ #define EM_CRX 114 /* National Semiconductor CRX */ +#define EM_CR16 115 /* National Semiconductor CompactRISC - CR16 */ +#define EM_SCORE 135 /* Sunplus Score */ /* If it is necessary to assign new unofficial EM_* values, please pick large random numbers (0x8523, 0xa7f2, etc.) to minimize the chances of collision @@ -278,6 +281,8 @@ /* NIOS magic number - no EABI available. */ #define EM_NIOS32 0xFEBB +#define EM_CYGNUS_MEP 0xF00D /* Toshiba MeP */ + /* See the above comment before you add a new EM_* value here. */ /* Values for e_version. */ @@ -338,6 +343,8 @@ #define SHT_LOOS 0x60000000 /* First of OS specific semantics */ #define SHT_HIOS 0x6fffffff /* Last of OS specific semantics */ +#define SHT_GNU_ATTRIBUTES 0x6ffffff5 /* Object attributes */ +#define SHT_GNU_HASH 0x6ffffff6 /* GNU style symbol hash table */ #define SHT_GNU_LIBLIST 0x6ffffff7 /* List of prelink dependencies */ /* The next three section types are defined by Solaris, and are named @@ -445,7 +452,7 @@ #define ELF64_ST_INFO ELF_ST_INFO /* This macro disassembles and assembles a symbol's visibility into - the st_other field. The STV_ defines specificy the actual visibility. */ + the st_other field. The STV_ defines specify the actual visibility. */ #define ELF_ST_VISIBILITY(v) ((v) & 0x3) /* The remaining bits in the st_other field are not currently used. @@ -472,6 +479,8 @@ #define STT_FILE 4 /* Symbol gives a file name */ #define STT_COMMON 5 /* An uninitialised common block */ #define STT_TLS 6 /* Thread local data object */ +#define STT_RELC 8 /* Complex relocation expression */ +#define STT_SRELC 9 /* Signed Complex relocation expression */ #define STT_LOOS 10 /* OS-specific semantics */ #define STT_HIOS 12 /* OS-specific semantics */ #define STT_LOPROC 13 /* Application-specific semantics */ @@ -543,7 +552,7 @@ #define DT_FINI_ARRAYSZ 28 #define DT_RUNPATH 29 #define DT_FLAGS 30 -#define DT_ENCODING 31 +#define DT_ENCODING 32 #define DT_PREINIT_ARRAY 32 #define DT_PREINIT_ARRAYSZ 33 @@ -577,6 +586,7 @@ #define DT_VALRNGHI 0x6ffffdff #define DT_ADDRRNGLO 0x6ffffe00 +#define DT_GNU_HASH 0x6ffffef5 #define DT_TLSDESC_PLT 0x6ffffef6 #define DT_TLSDESC_GOT 0x6ffffef7 #define DT_GNU_CONFLICT 0x6ffffef8 diff --git a/include/elf/cr16.h b/include/elf/cr16.h new file mode 100644 index 000000000000..e3f6c50b1260 --- /dev/null +++ b/include/elf/cr16.h @@ -0,0 +1,56 @@ +/* CR16 ELF support for BFD. + Copyright 2007 Free Software Foundation, Inc. + Contributed by M R Swami Reddy. + + This file is part of BFD, the Binary File Descriptor library. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software Foundation, + Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ + +#ifndef _ELF_CR16_H +#define _ELF_CR16_H + +#include "elf/reloc-macros.h" + +/* Creating indices for reloc_map_index array. */ +START_RELOC_NUMBERS(elf_cr16_reloc_type) + RELOC_NUMBER (R_CR16_NONE, 0) + RELOC_NUMBER (R_CR16_NUM8, 1) + RELOC_NUMBER (R_CR16_NUM16, 2) + RELOC_NUMBER (R_CR16_NUM32, 3) + RELOC_NUMBER (R_CR16_NUM32a, 4) + RELOC_NUMBER (R_CR16_REGREL4, 5) + RELOC_NUMBER (R_CR16_REGREL4a, 6) + RELOC_NUMBER (R_CR16_REGREL14, 7) + RELOC_NUMBER (R_CR16_REGREL14a, 8) + RELOC_NUMBER (R_CR16_REGREL16, 9) + RELOC_NUMBER (R_CR16_REGREL20, 10) + RELOC_NUMBER (R_CR16_REGREL20a, 11) + RELOC_NUMBER (R_CR16_ABS20, 12) + RELOC_NUMBER (R_CR16_ABS24, 13) + RELOC_NUMBER (R_CR16_IMM4, 14) + RELOC_NUMBER (R_CR16_IMM8, 15) + RELOC_NUMBER (R_CR16_IMM16, 16) + RELOC_NUMBER (R_CR16_IMM20, 17) + RELOC_NUMBER (R_CR16_IMM24, 18) + RELOC_NUMBER (R_CR16_IMM32, 19) + RELOC_NUMBER (R_CR16_IMM32a, 20) + RELOC_NUMBER (R_CR16_DISP4, 21) + RELOC_NUMBER (R_CR16_DISP8, 22) + RELOC_NUMBER (R_CR16_DISP16, 23) + RELOC_NUMBER (R_CR16_DISP24, 24) + RELOC_NUMBER (R_CR16_DISP24a, 25) +END_RELOC_NUMBERS(R_CR16_MAX) + +#endif /* _ELF_CR16_H */ diff --git a/include/elf/dwarf2.h b/include/elf/dwarf2.h index 264952af1394..2683f5131c74 100644 --- a/include/elf/dwarf2.h +++ b/include/elf/dwarf2.h @@ -540,6 +540,7 @@ enum dwarf_location_atom DW_OP_bit_piece = 0x9d, /* GNU extensions. */ DW_OP_GNU_push_tls_address = 0xe0, + DW_OP_GNU_uninit = 0xf0, /* HP extensions. */ DW_OP_HP_unknown = 0xe0, /* Ouch, the same as GNU_push_tls_address. */ DW_OP_HP_is_value = 0xe1, diff --git a/include/elf/external.h b/include/elf/external.h index 5985e94b0226..21450f00595c 100644 --- a/include/elf/external.h +++ b/include/elf/external.h @@ -245,11 +245,7 @@ typedef struct { typedef struct { unsigned char vs_vers[2]; -} -#ifdef __GNUC__ - __attribute__ ((packed)) -#endif - Elf_External_Versym; +} ATTRIBUTE_PACKED Elf_External_Versym; /* Structure for syminfo section. */ typedef struct diff --git a/include/elf/hppa.h b/include/elf/hppa.h index 15be2d5655a3..c9b3200ac9e0 100644 --- a/include/elf/hppa.h +++ b/include/elf/hppa.h @@ -1,22 +1,22 @@ /* HPPA ELF support for BFD. - Copyright 1993, 1994, 1995, 1998, 1999, 2000, 2005 + Copyright 1993, 1994, 1995, 1998, 1999, 2000, 2005, 2006 Free Software Foundation, Inc. -This file is part of BFD, the Binary File Descriptor library. + This file is part of BFD, the Binary File Descriptor library. -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ /* This file holds definitions specific to the HPPA ELF ABI. Note that most of this is not actually implemented by BFD. */ @@ -80,10 +80,10 @@ Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. /* These are strictly for compatibility with the older elf32-hppa implementation. Hopefully we can eliminate them in the future. */ /* Optional section holding argument location/relocation info. */ -#define SHT_PARISC_SYMEXTN SHT_LOPROC+8 +#define SHT_PARISC_SYMEXTN SHT_LOPROC + 8 /* Option section for linker stubs. */ -#define SHT_PARISC_STUBS SHT_LOPROC+9 +#define SHT_PARISC_STUBS SHT_LOPROC + 9 /* Processor specific section flags. */ @@ -480,8 +480,28 @@ RELOC_NUMBER (R_PARISC_LTOFF_TP16DF, 231) RELOC_NUMBER (R_PARISC_GNU_VTENTRY, 232) RELOC_NUMBER (R_PARISC_GNU_VTINHERIT, 233) +RELOC_NUMBER (R_PARISC_TLS_GD21L, 234) +RELOC_NUMBER (R_PARISC_TLS_GD14R, 235) +RELOC_NUMBER (R_PARISC_TLS_GDCALL, 236) +RELOC_NUMBER (R_PARISC_TLS_LDM21L, 237) +RELOC_NUMBER (R_PARISC_TLS_LDM14R, 238) +RELOC_NUMBER (R_PARISC_TLS_LDMCALL, 239) +RELOC_NUMBER (R_PARISC_TLS_LDO21L, 240) +RELOC_NUMBER (R_PARISC_TLS_LDO14R, 241) +RELOC_NUMBER (R_PARISC_TLS_DTPMOD32, 242) +RELOC_NUMBER (R_PARISC_TLS_DTPMOD64, 243) +RELOC_NUMBER (R_PARISC_TLS_DTPOFF32, 244) +RELOC_NUMBER (R_PARISC_TLS_DTPOFF64, 245) + END_RELOC_NUMBERS (R_PARISC_UNIMPLEMENTED) +#define R_PARISC_TLS_LE21L R_PARISC_TPREL21L +#define R_PARISC_TLS_LE14R R_PARISC_TPREL14R +#define R_PARISC_TLS_IE21L R_PARISC_LTOFF_TP21L +#define R_PARISC_TLS_IE14R R_PARISC_LTOFF_TP14R +#define R_PARISC_TLS_TPREL32 R_PARISC_TPREL32 +#define R_PARISC_TLS_TPREL64 R_PARISC_TPREL64 + #ifndef RELOC_MACROS_GEN_FUNC typedef enum elf_hppa_reloc_type elf_hppa_reloc_type; #endif diff --git a/include/elf/internal.h b/include/elf/internal.h index e4eba7d6cb34..152171136c19 100644 --- a/include/elf/internal.h +++ b/include/elf/internal.h @@ -1,6 +1,6 @@ /* ELF support for BFD. Copyright 1991, 1992, 1993, 1994, 1995, 1997, 1998, 2000, 2001, 2002, - 2003 Free Software Foundation, Inc. + 2003, 2006, 2007 Free Software Foundation, Inc. Written by Fred Fish @ Cygnus Support, from information published in "UNIX System V Release 4, Programmers Guide: ANSI C and @@ -235,12 +235,19 @@ struct elf_segment_map unsigned long p_flags; /* Program segment physical address. */ bfd_vma p_paddr; + /* Program segment virtual address offset from section vma. */ + bfd_vma p_vaddr_offset; + /* Program segment alignment. */ + bfd_vma p_align; /* Whether the p_flags field is valid; if not, the flags are based on the section flags. */ unsigned int p_flags_valid : 1; /* Whether the p_paddr field is valid; if not, the physical address is based on the section lma values. */ unsigned int p_paddr_valid : 1; + /* Whether the p_align field is valid; if not, PT_LOAD segment + alignment is based on the default maximum page size. */ + unsigned int p_align_valid : 1; /* Whether this segment includes the file header. */ unsigned int includes_filehdr : 1; /* Whether this segment includes the program headers. */ @@ -251,29 +258,42 @@ struct elf_segment_map asection *sections[1]; }; +/* .tbss is special. It doesn't contribute memory space to normal + segments and it doesn't take file space in normal segments. */ +#define ELF_SECTION_SIZE(sec_hdr, segment) \ + (((sec_hdr->sh_flags & SHF_TLS) == 0 \ + || sec_hdr->sh_type != SHT_NOBITS \ + || segment->p_type == PT_TLS) ? sec_hdr->sh_size : 0) + +/* Decide if the given sec_hdr is in the given segment. PT_TLS segment + contains only SHF_TLS sections. Only PT_LOAD and PT_TLS segments + can contain SHF_TLS sections. */ +#define ELF_IS_SECTION_IN_SEGMENT(sec_hdr, segment) \ + (((((sec_hdr->sh_flags & SHF_TLS) != 0) \ + && (segment->p_type == PT_TLS \ + || segment->p_type == PT_LOAD)) \ + || ((sec_hdr->sh_flags & SHF_TLS) == 0 \ + && segment->p_type != PT_TLS)) \ + /* Any section besides one of type SHT_NOBITS must have a file \ + offset within the segment. */ \ + && (sec_hdr->sh_type == SHT_NOBITS \ + || ((bfd_vma) sec_hdr->sh_offset >= segment->p_offset \ + && (sec_hdr->sh_offset + ELF_SECTION_SIZE(sec_hdr, segment) \ + <= segment->p_offset + segment->p_filesz))) \ + /* SHF_ALLOC sections must have VMAs within the segment. */ \ + && ((sec_hdr->sh_flags & SHF_ALLOC) == 0 \ + || (sec_hdr->sh_addr >= segment->p_vaddr \ + && (sec_hdr->sh_addr + ELF_SECTION_SIZE(sec_hdr, segment) \ + <= segment->p_vaddr + segment->p_memsz)))) + /* Decide if the given sec_hdr is in the given segment in file. */ #define ELF_IS_SECTION_IN_SEGMENT_FILE(sec_hdr, segment) \ (sec_hdr->sh_size > 0 \ - /* PT_TLS segment contains only SHF_TLS sections. */ \ - && (segment->p_type != PT_TLS \ - || (sec_hdr->sh_flags & SHF_TLS) != 0) \ - /* Compare allocated sec_hdrs by VMA, unallocated sec_hdrs \ - by file offset. */ \ - && (sec_hdr->sh_flags & SHF_ALLOC \ - ? (sec_hdr->sh_addr >= segment->p_vaddr \ - && sec_hdr->sh_addr + sec_hdr->sh_size \ - <= segment->p_vaddr + segment->p_memsz) \ - : ((bfd_vma) sec_hdr->sh_offset >= segment->p_offset \ - && (sec_hdr->sh_offset + sec_hdr->sh_size \ - <= segment->p_offset + segment->p_filesz)))) + && ELF_IS_SECTION_IN_SEGMENT (sec_hdr, segment)) /* Decide if the given sec_hdr is in the given segment in memory. */ #define ELF_IS_SECTION_IN_SEGMENT_MEMORY(sec_hdr, segment) \ - (ELF_IS_SECTION_IN_SEGMENT_FILE (sec_hdr, segment) \ - /* .tbss is special. It doesn't contribute memory space to \ - normal segments. */ \ - && (!((sec_hdr->sh_flags & SHF_TLS) != 0 \ - && sec_hdr->sh_type == SHT_NOBITS) \ - || segment->p_type == PT_TLS)) + (ELF_SECTION_SIZE(sec_hdr, segment) > 0 \ + && ELF_IS_SECTION_IN_SEGMENT (sec_hdr, segment)) #endif /* _ELF_INTERNAL_H */ diff --git a/include/elf/m68k.h b/include/elf/m68k.h index 08d0c441988b..a9f2203a6884 100644 --- a/include/elf/m68k.h +++ b/include/elf/m68k.h @@ -52,24 +52,30 @@ START_RELOC_NUMBERS (elf_m68k_reloc_type) RELOC_NUMBER (R_68K_GNU_VTENTRY, 24) END_RELOC_NUMBERS (R_68K_max) +/* We use the top 24 bits to encode information about the + architecture variant. */ #define EF_M68K_CPU32 0x00810000 #define EF_M68K_M68000 0x01000000 #define EF_M68K_CFV4E 0x00008000 +#define EF_M68K_FIDO 0x02000000 +#define EF_M68K_ARCH_MASK \ + (EF_M68K_M68000 | EF_M68K_CPU32 | EF_M68K_CFV4E | EF_M68K_FIDO) /* We use the bottom 8 bits to encode information about the - coldfire variant. */ -#define EF_M68K_ISA_MASK 0x0F /* Which ISA */ -#define EF_M68K_ISA_A_NODIV 0x01 /* ISA A except for div */ -#define EF_M68K_ISA_A 0x02 -#define EF_M68K_ISA_A_PLUS 0x03 -#define EF_M68K_ISA_B_NOUSP 0x04 /* ISA_B except for USP */ -#define EF_M68K_ISA_B 0x05 -#define EF_M68K_ISA_C 0x06 -#define EF_M68K_MAC_MASK 0x30 -#define EF_M68K_MAC 0x10 /* MAC */ -#define EF_M68K_EMAC 0x20 /* EMAC */ -#define EF_M68K_EMAC_B 0x30 /* EMAC_B */ -#define EF_M68K_FLOAT 0x40 /* Has float insns */ + coldfire variant. If we use any of these bits, the top 24 bits are + either 0 or EF_M68K_CFV4E. */ +#define EF_M68K_CF_ISA_MASK 0x0F /* Which ISA */ +#define EF_M68K_CF_ISA_A_NODIV 0x01 /* ISA A except for div */ +#define EF_M68K_CF_ISA_A 0x02 +#define EF_M68K_CF_ISA_A_PLUS 0x03 +#define EF_M68K_CF_ISA_B_NOUSP 0x04 /* ISA_B except for USP */ +#define EF_M68K_CF_ISA_B 0x05 +#define EF_M68K_CF_ISA_C 0x06 +#define EF_M68K_CF_MAC_MASK 0x30 +#define EF_M68K_CF_MAC 0x10 /* MAC */ +#define EF_M68K_CF_EMAC 0x20 /* EMAC */ +#define EF_M68K_CF_EMAC_B 0x30 /* EMAC_B */ +#define EF_M68K_CF_FLOAT 0x40 /* Has float insns */ #define EF_M68K_CF_MASK 0xFF #endif diff --git a/include/elf/mep.h b/include/elf/mep.h new file mode 100644 index 000000000000..51eb8d06bc69 --- /dev/null +++ b/include/elf/mep.h @@ -0,0 +1,84 @@ +/* Toshiba MeP ELF support for BFD. + Copyright (C) 2001, 2004, 2005 Free Software Foundation, Inc. + + This file is part of BFD, the Binary File Descriptor library. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software Foundation, Inc., + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ + +#ifndef _ELF_MEP_H +#define _ELF_MEP_H + +/* Bits in the sh_flags field of Elf32_Shdr: */ + +#define SHF_MEP_VLIW 0x10000000 /* contains vliw code */ + +/* This bit is reserved by BFD for processor specific stuff. Name + it properly so that we can easily stay consistent elsewhere. */ +#define SEC_MEP_VLIW SEC_TIC54X_BLOCK + +#include "elf/reloc-macros.h" + +/* Note: The comments in this file are used by bfd/mep-relocs.pl to + build parts of bfd/elf32-mep.c. */ + +/* Relocations. */ +START_RELOC_NUMBERS (elf_mep_reloc_type) + + /* These two must appear first so that they are not processed by bfd/mep-relocs.pl. */ + RELOC_NUMBER (R_MEP_NONE, 0) + RELOC_NUMBER (R_RELC, 1) + + RELOC_NUMBER (R_MEP_8, 2) /* 7654 3210 U */ + RELOC_NUMBER (R_MEP_16, 3) /* fedc ba98 7654 3210 U */ + RELOC_NUMBER (R_MEP_32, 4) /* vuts rqpo nmlk jihg fedc ba98 7654 3210 U */ + + RELOC_NUMBER (R_MEP_PCREL8A2, 5) /* ---- ---- 7654 321- S PC-REL */ + RELOC_NUMBER (R_MEP_PCREL12A2, 6) /* ---- ba98 7654 321- S PC-REL */ + RELOC_NUMBER (R_MEP_PCREL17A2, 7) /* ---- ---- ---- ---- gfed cba9 8765 4321 S PC-REL */ + RELOC_NUMBER (R_MEP_PCREL24A2, 8) /* ---- -765 4321 ---- nmlk jihg fedc ba98 S PC-REL */ + RELOC_NUMBER (R_MEP_PCABS24A2, 9) /* ---- -765 4321 ---- nmlk jihg fedc ba98 U */ + + RELOC_NUMBER (R_MEP_LOW16, 10) /* ---- ---- ---- ---- fedc ba98 7654 3210 U no-overflow */ + RELOC_NUMBER (R_MEP_HI16U, 11) /* ---- ---- ---- ---- vuts rqpo nmlk jihg U no-overflow */ + RELOC_NUMBER (R_MEP_HI16S, 12) /* ---- ---- ---- ---- vuts rqpo nmlk jihg S no-overflow */ + RELOC_NUMBER (R_MEP_GPREL, 13) /* ---- ---- ---- ---- fedc ba98 7654 3210 S GP-REL*/ + RELOC_NUMBER (R_MEP_TPREL, 14) /* ---- ---- ---- ---- fedc ba98 7654 3210 S TP-REL*/ + + RELOC_NUMBER (R_MEP_TPREL7, 15) /* ---- ---- -654 3210 U TP-REL */ + RELOC_NUMBER (R_MEP_TPREL7A2, 16) /* ---- ---- -654 321- U TP-REL */ + RELOC_NUMBER (R_MEP_TPREL7A4, 17) /* ---- ---- -654 32-- U TP-REL */ + + RELOC_NUMBER (R_MEP_UIMM24, 18) /* ---- ---- 7654 3210 nmlk jihg fedc ba98 U */ + RELOC_NUMBER (R_MEP_ADDR24A4, 19) /* ---- ---- 7654 32-- nmlk jihg fedc ba98 U */ + + RELOC_NUMBER (R_MEP_GNU_VTINHERIT, 20) /* ---- ---- ---- ---- U no-overflow */ + RELOC_NUMBER (R_MEP_GNU_VTENTRY, 21) /* ---- ---- ---- ---- U no-overflow */ + +END_RELOC_NUMBERS(R_MEP_max) + +#define EF_MEP_CPU_MASK 0xff000000 /* specific cpu bits */ +#define EF_MEP_CPU_MEP 0x00000000 /* generic MEP */ +#define EF_MEP_CPU_C2 0x01000000 /* MEP c2 */ +#define EF_MEP_CPU_C3 0x02000000 /* MEP c3 */ +#define EF_MEP_CPU_C4 0x04000000 /* MEP c4 */ +#define EF_MEP_CPU_H1 0x10000000 /* MEP h1 */ + +#define EF_MEP_LIBRARY 0x00000100 /* Built as a library */ + +#define EF_MEP_INDEX_MASK 0x000000ff /* Configuration index */ + +#define EF_MEP_ALL_FLAGS 0xff0001ff + +#endif /* _ELF_MEP_H */ diff --git a/include/elf/mips.h b/include/elf/mips.h index f22bd4d4213a..4f6067575186 100644 --- a/include/elf/mips.h +++ b/include/elf/mips.h @@ -87,7 +87,8 @@ START_RELOC_NUMBERS (elf_mips_reloc_type) RELOC_NUMBER (R_MIPS_TLS_TPREL64, 48) RELOC_NUMBER (R_MIPS_TLS_TPREL_HI16, 49) RELOC_NUMBER (R_MIPS_TLS_TPREL_LO16, 50) - FAKE_RELOC (R_MIPS_max, 51) + RELOC_NUMBER (R_MIPS_GLOB_DAT, 51) + FAKE_RELOC (R_MIPS_max, 52) /* These relocs are used for the mips16. */ FAKE_RELOC (R_MIPS16_min, 100) RELOC_NUMBER (R_MIPS16_26, 100) @@ -1005,4 +1006,15 @@ extern void bfd_mips_elf64_swap_reginfo_out #define OHWA0_R4KEOP_CLEAN 0x00000002 +/* Object attribute tags. */ +enum +{ + /* 0-3 are generic. */ + Tag_GNU_MIPS_ABI_FP = 4, /* Value 1 for hard-float -mdouble-float, 2 + for hard-float -msingle-float, 3 for + soft-float; 0 for not tagged or not + using any ABIs affected by the + differences. */ +}; + #endif /* _ELF_MIPS_H */ diff --git a/include/elf/ppc.h b/include/elf/ppc.h index ca5035274d9a..fe48814d86f2 100644 --- a/include/elf/ppc.h +++ b/include/elf/ppc.h @@ -171,4 +171,15 @@ END_RELOC_NUMBERS (R_PPC_max) builds when those objects \ are not to be furhter \ relocated. */ + +/* Object attribute tags. */ +enum +{ + /* 0-3 are generic. */ + Tag_GNU_Power_ABI_FP = 4, /* Value 1 for hard-float, 2 for + soft-float; 0 for not tagged or not + using any ABIs affected by the + differences. */ +}; + #endif /* _ELF_PPC_H */ diff --git a/include/elf/reloc-macros.h b/include/elf/reloc-macros.h index 51e86b5af151..a67419d220ca 100644 --- a/include/elf/reloc-macros.h +++ b/include/elf/reloc-macros.h @@ -98,4 +98,4 @@ name (unsigned long rtype) \ #endif -#endif /* RELOC_MACROS_H */ +#endif /* _RELOC_MACROS_H */ diff --git a/include/elf/score.h b/include/elf/score.h new file mode 100644 index 000000000000..ec3b32f16c46 --- /dev/null +++ b/include/elf/score.h @@ -0,0 +1,123 @@ +/* Score ELF support for BFD. + Copyright 2006 Free Software Foundation, Inc. + Contributed by + Mei Ligang (ligang@sunnorth.com.cn) + Pei-Lin Tsai (pltsai@sunplus.com) + + This file is part of BFD, the Binary File Descriptor library. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software Foundation, + Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ + +#ifndef _ELF_SCORE_H +#define _ELF_SCORE_H + +#include "elf/reloc-macros.h" + +#define SCORE_SIMULATOR_ACTIVE 1 +#define OPC_PTMASK 0xc0000000 /* Parity-bit Mask. */ +#define OPC16_PTMASK 0x00008000 +/* The parity-bit denotes. */ +#define OPC_32 0xc0000000 /* Denotes 32b instruction, (default). */ +#define OPC_16 0x00000000 /* Denotes 16b instruction. */ +#define OPC_PE 0x8000 /* Denotes parallel-execution instructions. */ +#define GP_DISP_LABEL "_gp_disp" + +/* Processor specific flags for the ELF header e_flags field: */ + +/* File contains position independent code. */ +#define EF_SCORE_PIC 0x80000000 + +/* Fix data dependency. */ +#define EF_SCORE_FIXDEP 0x40000000 + +/* Defined and allocated common symbol. Value is virtual address. If + relocated, alignment must be preserved. */ +#define SHN_SCORE_TEXT 0xff01 +#define SHN_SCORE_DATA 0xff02 +/* Small common symbol. */ +#define SHN_SCORE_SCOMMON 0xff03 + +/* Processor specific section flags. */ + +/* This section must be in the global data area. */ +#define SHF_SCORE_GPREL 0x10000000 + +/* This section should be merged. */ +#define SHF_SCORE_MERGE 0x20000000 + +/* This section contains address data of size implied by section + element size. */ +#define SHF_SCORE_ADDR 0x40000000 + +/* This section contains string data. */ +#define SHF_SCORE_STRING 0x80000000 + +/* This section may not be stripped. */ +#define SHF_SCORE_NOSTRIP 0x08000000 + +/* This section is local to threads. */ +#define SHF_SCORE_LOCAL 0x04000000 + +/* Linker should generate implicit weak names for this section. */ +#define SHF_SCORE_NAMES 0x02000000 + +/* Section contais text/data which may be replicated in other sections. + Linker should retain only one copy. */ +#define SHF_SCORE_NODUPES 0x01000000 + +/* Processor specific dynamic array tags. */ + +/* Base address of the segment. */ +#define DT_SCORE_BASE_ADDRESS 0x70000001 +/* Number of local global offset table entries. */ +#define DT_SCORE_LOCAL_GOTNO 0x70000002 +/* Number of entries in the .dynsym section. */ +#define DT_SCORE_SYMTABNO 0x70000003 +/* Index of first dynamic symbol in global offset table. */ +#define DT_SCORE_GOTSYM 0x70000004 +/* Index of first external dynamic symbol not referenced locally. */ +#define DT_SCORE_UNREFEXTNO 0x70000005 +/* Number of page table entries in global offset table. */ +#define DT_SCORE_HIPAGENO 0x70000006 + + +/* Processor specific section types. */ + + +/* Relocation types. */ +START_RELOC_NUMBERS (elf_score_reloc_type) + RELOC_NUMBER (R_SCORE_NONE, 0) + RELOC_NUMBER (R_SCORE_HI16, 1) + RELOC_NUMBER (R_SCORE_LO16, 2) + RELOC_NUMBER (R_SCORE_DUMMY1, 3) + RELOC_NUMBER (R_SCORE_24, 4) + RELOC_NUMBER (R_SCORE_PC19, 5) + RELOC_NUMBER (R_SCORE16_11, 6) + RELOC_NUMBER (R_SCORE16_PC8, 7) + RELOC_NUMBER (R_SCORE_ABS32, 8) + RELOC_NUMBER (R_SCORE_ABS16, 9) + RELOC_NUMBER (R_SCORE_DUMMY2, 10) + RELOC_NUMBER (R_SCORE_GP15, 11) + RELOC_NUMBER (R_SCORE_GNU_VTINHERIT, 12) + RELOC_NUMBER (R_SCORE_GNU_VTENTRY, 13) + RELOC_NUMBER (R_SCORE_GOT15, 14) + RELOC_NUMBER (R_SCORE_GOT_LO16, 15) + RELOC_NUMBER (R_SCORE_CALL15, 16) + RELOC_NUMBER (R_SCORE_GPREL32, 17) + RELOC_NUMBER (R_SCORE_REL32, 18) + RELOC_NUMBER (R_SCORE_DUMMY_HI16, 19) +END_RELOC_NUMBERS (R_SCORE_max) + +#endif /* _ELF_SCORE_H */ diff --git a/include/elf/spu.h b/include/elf/spu.h new file mode 100644 index 000000000000..ef949804e78e --- /dev/null +++ b/include/elf/spu.h @@ -0,0 +1,60 @@ +/* SPU ELF support for BFD. + + Copyright 2006, 2007 Free Software Foundation, Inc. + + This file is part of BFD, the Binary File Descriptor library. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software Foundation, + Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ + +#ifndef _ELF_SPU_H +#define _ELF_SPU_H + +#include "elf/reloc-macros.h" + +/* elf32-spu.c depends on these being consecutive. */ +START_RELOC_NUMBERS (elf_spu_reloc_type) + RELOC_NUMBER (R_SPU_NONE, 0) + RELOC_NUMBER (R_SPU_ADDR10, 1) + RELOC_NUMBER (R_SPU_ADDR16, 2) + RELOC_NUMBER (R_SPU_ADDR16_HI, 3) + RELOC_NUMBER (R_SPU_ADDR16_LO, 4) + RELOC_NUMBER (R_SPU_ADDR18, 5) + RELOC_NUMBER (R_SPU_ADDR32, 6) + RELOC_NUMBER (R_SPU_REL16, 7) + RELOC_NUMBER (R_SPU_ADDR7, 8) + RELOC_NUMBER (R_SPU_REL9, 9) + RELOC_NUMBER (R_SPU_REL9I, 10) + RELOC_NUMBER (R_SPU_ADDR10I, 11) + RELOC_NUMBER (R_SPU_ADDR16I, 12) + RELOC_NUMBER (R_SPU_REL32, 13) + RELOC_NUMBER (R_SPU_ADDR16X, 14) + RELOC_NUMBER (R_SPU_PPU32, 15) + RELOC_NUMBER (R_SPU_PPU64, 16) +END_RELOC_NUMBERS (R_SPU_max) + +/* Program header extensions */ + +/* Mark a PT_LOAD segment as containing an overlay which should not + initially be loaded. */ +#define PF_OVERLAY (1 << 27) + +/* SPU Dynamic Object Information. */ +#define PT_SPU_INFO 0x70000000 + +/* SPU plugin information */ +#define SPU_PLUGIN_NAME "SPUNAME" +#define SPU_PTNOTE_SPUNAME ".note.spu_name" + +#endif /* _ELF_SPU_H */ diff --git a/include/elf/v850.h b/include/elf/v850.h index 95dab49b67d2..a88969d9159c 100644 --- a/include/elf/v850.h +++ b/include/elf/v850.h @@ -1,5 +1,5 @@ /* V850 ELF support for BFD. - Copyright 1997, 1998, 2000, 2002, 2003, 2004 + Copyright 1997, 1998, 2000, 2002, 2003, 2004, 2007 Free Software Foundation, Inc. Created by Michael Meissner, Cygnus Support <meissner@cygnus.com> @@ -41,10 +41,9 @@ /* Flags for the st_other field. */ -#define V850_OTHER_SDA 0x01 /* Symbol had SDA relocations. */ -#define V850_OTHER_ZDA 0x02 /* Symbol had ZDA relocations. */ -#define V850_OTHER_TDA 0x04 /* Symbol had TDA relocations. */ -#define V850_OTHER_TDA_BYTE 0x08 /* Symbol had TDA byte relocations. */ +#define V850_OTHER_SDA 0x10 /* Symbol had SDA relocations. */ +#define V850_OTHER_ZDA 0x20 /* Symbol had ZDA relocations. */ +#define V850_OTHER_TDA 0x40 /* Symbol had TDA relocations. */ #define V850_OTHER_ERROR 0x80 /* Symbol had an error reported. */ /* V850 relocations. */ diff --git a/include/elf/xtensa.h b/include/elf/xtensa.h index 0de9741b6d1c..bd83a140b2e8 100644 --- a/include/elf/xtensa.h +++ b/include/elf/xtensa.h @@ -140,7 +140,9 @@ typedef struct property_table_entry_t /* Instruction-only properties about code. */ #define XTENSA_PROP_INSN_NO_DENSITY 0x00000040 #define XTENSA_PROP_INSN_NO_REORDER 0x00000080 -#define XTENSA_PROP_INSN_NO_TRANSFORM 0x00000100 +/* Historically, NO_TRANSFORM was a property of instructions, + but it should apply to literals under certain circumstances. */ +#define XTENSA_PROP_NO_TRANSFORM 0x00000100 /* Branch target alignment information. This transmits information to the linker optimization about the priority of aligning a |