diff options
author | Alan Modra <amodra@gmail.com> | 2021-05-12 17:48:13 +0930 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2021-05-12 21:10:33 +0930 |
commit | af2ddf69ab85add3155cf55f65e6e9f3c9bcb29a (patch) | |
tree | da4e33811d28a4f7cda938183b3d349780b10c8b /binutils/elfcomm.h | |
parent | 0d872fca0293041a5cb7c54a4a04855323563d8e (diff) | |
download | gdb-af2ddf69ab85add3155cf55f65e6e9f3c9bcb29a.zip gdb-af2ddf69ab85add3155cf55f65e6e9f3c9bcb29a.tar.gz gdb-af2ddf69ab85add3155cf55f65e6e9f3c9bcb29a.tar.bz2 |
SAFE_BYTE_GET64
Functions dealing with lack of a 64-bit integer type can disappear now
that we require C99. Printing using dwarf_vmatoa is better too.
binutils/
* dwarf.c (dwarf_vmatoa64, SAFE_BYTE_GET64, add64): Delete.
(skip_attr_bytes): Replace use of SAFE_BYTE_GET64 with
SAFE_BYTE_GET_AND_INC.
(read_and_display_attr_value): Likewise. Print using dwarf_vmatoa.
(process_debug_info, process_cu_tu_index): Likewise.
* elfcomm.c (byte_put, byte_put_little_endian, byte_put_big_endian),
(byte_get, byte_get_little_endian, byte_get_big_endian),
(byte_get_signed): Make size param unsigned. Remove code dealing
with 4-byte elf_vma.
(byte_get_64): Delete.
* elfcomm.h (byte_put, byte_put_little_endian, byte_put_big_endian),
(byte_get, byte_get_little_endian, byte_get_big_endian),
(byte_get_signed): Update prototypes.
(byte_get_64): Delete.
gas/
* testsuite/gas/elf/dwarf-5-file0.d: Update.
* testsuite/gas/i386/dwarf5-line-1.d: Update.
Diffstat (limited to 'binutils/elfcomm.h')
-rw-r--r-- | binutils/elfcomm.h | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/binutils/elfcomm.h b/binutils/elfcomm.h index 921d42c..22abb14 100644 --- a/binutils/elfcomm.h +++ b/binutils/elfcomm.h @@ -31,15 +31,14 @@ extern void warn (const char *, ...) ATTRIBUTE_PRINTF_1; typedef unsigned HOST_WIDEST_INT elf_vma; -extern void (*byte_put) (unsigned char *, elf_vma, int); -extern void byte_put_little_endian (unsigned char *, elf_vma, int); -extern void byte_put_big_endian (unsigned char *, elf_vma, int); - -extern elf_vma (*byte_get) (const unsigned char *, int); -extern elf_vma byte_get_signed (const unsigned char *, int); -extern elf_vma byte_get_little_endian (const unsigned char *, int); -extern elf_vma byte_get_big_endian (const unsigned char *, int); -extern void byte_get_64 (const unsigned char *, elf_vma *, elf_vma *); +extern void (*byte_put) (unsigned char *, elf_vma, unsigned int); +extern void byte_put_little_endian (unsigned char *, elf_vma, unsigned int); +extern void byte_put_big_endian (unsigned char *, elf_vma, unsigned int); + +extern elf_vma (*byte_get) (const unsigned char *, unsigned int); +extern elf_vma byte_get_signed (const unsigned char *, unsigned int); +extern elf_vma byte_get_little_endian (const unsigned char *, unsigned int); +extern elf_vma byte_get_big_endian (const unsigned char *, unsigned int); #define BYTE_PUT(field, val) byte_put (field, val, sizeof (field)) #define BYTE_GET(field) byte_get (field, sizeof (field)) |