forked from Imagelibrary/binutils-gdb
* bfd-in.h (bfd_int64_t, bfd_uint64_t): New types.
(BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Don't define here. (bfd_getb64, bfd_getl64, bfd_get_bits): Return bfd_uint64_t. (bfd_getb_signed_64, bfd_getl_signed_64): Return bfd_int64_t. (bfd_putb64, bfd_putl64, bfd_put_bits): Accept bfd_uint64_t. * configure.in (HOST_U_64BIT_TYPE): Set when sizeof long is 8. (BFD_HOST_64_BIT_DEFINED, BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Set when using long. * libbfd.c (EIGHT_GAZILLION, COERCE64): Use bfd_int64_t. (bfd_getb64): Return bfd_uint64_t. Enable when BFD_HOST_64_BIT. (bfd_getl64, bfd_getb_signed_64, bfd_getl_signed_64): Likewise. (bfd_putb64): Accept bfd_uint64_t. Enable when BFD_HOST_64_BIT. (bfd_putl64, bfd_put_bits, bfd_get_bits): Likewise. * dwarf2.c (struct attribute): Use bfd_int64_t and bfd_uint64_t. (read_8_bytes, read_indirect_string, read_address): Likewise. (read_abbrevs, parse_comp_unit): Likewise. * targets.c (struct bfd_target): Likewise. * aix386-core.c (NO_GET64, NO_PUT64, NO_GETS64): Define and use. * hppabsd-core.c: Likewise. Formatting. * hpux-core.c: Likewise. * irix-core.c: Likewise. * netbsd-core.c: Likewise. * osf-core.c: Likewise. * ptrace-core.c: Likewise. * sco5-core.c: Likewise. * trad-core.c: Likewise. * configure: Regenerate. * bfd-in2.h: Regenerate.
This commit is contained in:
14
bfd/dwarf2.c
14
bfd/dwarf2.c
@@ -61,8 +61,8 @@ struct attribute
|
||||
{
|
||||
char *str;
|
||||
struct dwarf_block *blk;
|
||||
bfd_vma val;
|
||||
bfd_signed_vma sval;
|
||||
bfd_uint64_t val;
|
||||
bfd_int64_t sval;
|
||||
}
|
||||
u;
|
||||
};
|
||||
@@ -230,7 +230,7 @@ read_4_bytes (bfd *abfd, char *buf)
|
||||
return bfd_get_32 (abfd, buf);
|
||||
}
|
||||
|
||||
static bfd_vma
|
||||
static bfd_uint64_t
|
||||
read_8_bytes (bfd *abfd, char *buf)
|
||||
{
|
||||
return bfd_get_64 (abfd, buf);
|
||||
@@ -268,7 +268,7 @@ read_indirect_string (struct comp_unit* unit,
|
||||
char *buf,
|
||||
unsigned int *bytes_read_ptr)
|
||||
{
|
||||
bfd_vma offset;
|
||||
bfd_uint64_t offset;
|
||||
struct dwarf2_debug *stash = unit->stash;
|
||||
|
||||
if (unit->offset_size == 4)
|
||||
@@ -378,7 +378,7 @@ read_signed_leb128 (bfd *abfd ATTRIBUTE_UNUSED,
|
||||
|
||||
/* END VERBATIM */
|
||||
|
||||
static bfd_vma
|
||||
static bfd_uint64_t
|
||||
read_address (struct comp_unit *unit, char *buf)
|
||||
{
|
||||
switch (unit->addr_size)
|
||||
@@ -422,7 +422,7 @@ lookup_abbrev (unsigned int number, struct abbrev_info **abbrevs)
|
||||
in a hash table. */
|
||||
|
||||
static struct abbrev_info**
|
||||
read_abbrevs (bfd *abfd, bfd_vma offset, struct dwarf2_debug *stash)
|
||||
read_abbrevs (bfd *abfd, bfd_uint64_t offset, struct dwarf2_debug *stash)
|
||||
{
|
||||
struct abbrev_info **abbrevs;
|
||||
char *abbrev_ptr;
|
||||
@@ -1436,7 +1436,7 @@ parse_comp_unit (bfd *abfd,
|
||||
{
|
||||
struct comp_unit* unit;
|
||||
unsigned int version;
|
||||
bfd_vma abbrev_offset = 0;
|
||||
bfd_uint64_t abbrev_offset = 0;
|
||||
unsigned int addr_size;
|
||||
struct abbrev_info** abbrevs;
|
||||
unsigned int abbrev_number, bytes_read, i;
|
||||
|
||||
Reference in New Issue
Block a user