X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=bfd%2Fbfd-in2.h;h=7c13bc8c91abf291f0206b6608b31955c5ea70d8;hb=7ef412cf72a197d68e532604cc1fa21351adc858;hp=a00dfa35150528dbbe3e411b71c93d457c4cdda7;hpb=9aea1e31371a883452e80bd96e8818289c3e6b6e;p=deliverable%2Fbinutils-gdb.git diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h index a00dfa3515..7c13bc8c91 100644 --- a/bfd/bfd-in2.h +++ b/bfd/bfd-in2.h @@ -7,7 +7,7 @@ /* Main header file for the bfd library -- portable access to object files. - Copyright (C) 1990-2019 Free Software Foundation, Inc. + Copyright (C) 1990-2020 Free Software Foundation, Inc. Contributed by Cygnus Support. @@ -654,9 +654,9 @@ void bfd_set_filename (bfd *abfd, char *filename); #define bfd_put_signed_8 \ bfd_put_8 #define bfd_get_8(abfd, ptr) \ - (*(const unsigned char *) (ptr) & 0xff) + ((bfd_vma) *(const unsigned char *) (ptr) & 0xff) #define bfd_get_signed_8(abfd, ptr) \ - (((*(const unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80) + ((((bfd_signed_vma) *(const unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80) #define bfd_put_16(abfd, val, ptr) \ BFD_SEND (abfd, bfd_putx16, ((val),(ptr))) @@ -700,7 +700,7 @@ bfd_vma bfd_getl24 (const void *p); BFD_SEND (abfd, bfd_getx_signed_64, (ptr)) #define bfd_get(bits, abfd, ptr) \ - ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \ + ((bits) == 8 ? bfd_get_8 (abfd, ptr) \ : (bits) == 16 ? bfd_get_16 (abfd, ptr) \ : (bits) == 32 ? bfd_get_32 (abfd, ptr) \ : (bits) == 64 ? bfd_get_64 (abfd, ptr) \ @@ -992,6 +992,11 @@ typedef struct bfd_section /* This section contains vliw code. This is for Toshiba MeP only. */ #define SEC_MEP_VLIW 0x20000000 + /* All symbols, sizes and relocations in this section are octets + instead of bytes. Required for DWARF debug sections as DWARF + information is organized in octets, not bytes. */ +#define SEC_ELF_OCTETS 0x40000000 + /* Indicate that section has the no read flag set. This happens when memory read flag isn't set. */ #define SEC_COFF_NOREAD 0x40000000 @@ -1733,7 +1738,6 @@ enum bfd_architecture #define bfd_mach_tic4x 40 bfd_arch_tic54x, /* Texas Instruments TMS320C54X. */ bfd_arch_tic6x, /* Texas Instruments TMS320C6X. */ - bfd_arch_tic80, /* TI TMS320c80 (MVP). */ bfd_arch_v850, /* NEC V850. */ bfd_arch_v850_rh850,/* NEC V850 (using RH850 ABI). */ #define bfd_mach_v850 1 @@ -1884,9 +1888,13 @@ enum bfd_architecture bfd_arch_xtensa, /* Tensilica's Xtensa cores. */ #define bfd_mach_xtensa 1 bfd_arch_z80, -#define bfd_mach_z80strict 1 /* No undocumented opcodes. */ -#define bfd_mach_z80 3 /* With ixl, ixh, iyl, and iyh. */ -#define bfd_mach_z80full 7 /* All undocumented instructions. */ +#define bfd_mach_gbz80 0 /* GameBoy Z80 (reduced instruction set) */ +#define bfd_mach_z80strict 1 /* Z80 without undocumented opcodes. */ +#define bfd_mach_z180 2 /* Z180: successor with additional instructions, but without halves of ix and iy */ +#define bfd_mach_z80 3 /* Z80 with ixl, ixh, iyl, and iyh. */ +#define bfd_mach_ez80_z80 4 /* eZ80 (successor of Z80 & Z180) in Z80 (16-bit address) mode */ +#define bfd_mach_ez80_adl 5 /* eZ80 (successor of Z80 & Z180) in ADL (24-bit address) mode */ +#define bfd_mach_z80full 7 /* Z80 with all undocumented instructions. */ #define bfd_mach_r800 11 /* R800: successor with multiplication. */ bfd_arch_lm32, /* Lattice Mico32. */ #define bfd_mach_lm32 1 @@ -1993,7 +2001,8 @@ const bfd_arch_info_type *bfd_lookup_arch const char *bfd_printable_arch_mach (enum bfd_architecture arch, unsigned long machine); -unsigned int bfd_octets_per_byte (const bfd *abfd); +unsigned int bfd_octets_per_byte (const bfd *abfd, + const asection *sec); unsigned int bfd_arch_mach_octets_per_byte (enum bfd_architecture arch, unsigned long machine); @@ -5265,6 +5274,24 @@ BFD_RELOC_XTENSA_ASM_EXPAND. */ /* 8 bit signed offset in (ix+d) or (iy+d). */ BFD_RELOC_Z80_DISP8, +/* First 8 bits of multibyte (32, 24 or 16 bit) value. */ + BFD_RELOC_Z80_BYTE0, + +/* Second 8 bits of multibyte (32, 24 or 16 bit) value. */ + BFD_RELOC_Z80_BYTE1, + +/* Third 8 bits of multibyte (32 or 24 bit) value. */ + BFD_RELOC_Z80_BYTE2, + +/* Fourth 8 bits of multibyte (32 bit) value. */ + BFD_RELOC_Z80_BYTE3, + +/* Lowest 16 bits of multibyte (32 or 24 bit) value. */ + BFD_RELOC_Z80_WORD0, + +/* Highest 16 bits of multibyte (32 or 24 bit) value. */ + BFD_RELOC_Z80_WORD1, + /* DJNZ offset. */ BFD_RELOC_Z8K_DISP7, @@ -6854,7 +6881,8 @@ bfd_get_section_limit_octets (const bfd *abfd, const asection *sec) static inline bfd_size_type bfd_get_section_limit (const bfd *abfd, const asection *sec) { - return bfd_get_section_limit_octets (abfd, sec) / bfd_octets_per_byte (abfd); + return (bfd_get_section_limit_octets (abfd, sec) + / bfd_octets_per_byte (abfd, sec)); } /* Functions to handle insertion and deletion of a bfd's sections. These