aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarf2/leb.h
AgeCommit message (Collapse)AuthorFilesLines
2021-01-01Update copyright year range in all GDB filesJoel Brobecker1-1/+1
This commits the result of running gdb/copyright.py as per our Start of New Year procedure... gdb/ChangeLog Update copyright year range in copyright header of all GDB files.
2020-11-04Rewrite leb.h:read_3_bytesTom Tromey1-8/+1
read_3_bytes assumes little-endian data, but in fact it depends on the BFD. This patch rewrites this function to use bfd_get_24 instead. 2020-11-04 Tom Tromey <tromey@adacore.com> * dwarf2/leb.h (read_3_bytes): Use bfd_get_24.
2020-02-08Move two more functions to dwarf2/leb.hTom Tromey1-0/+27
This moves read_n_bytes and read_direct_string to be with the the low-level value-reading code. 2020-02-08 Tom Tromey <tom@tromey.com> * dwarf2/read.c (read_n_bytes, read_direct_string): Move to read.c. * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from read.c. Change-Id: Id07bfa13d93c0ac1f47a385749a8f01f4755b818
2020-02-08Move read_offset_1 to leb.cTom Tromey1-0/+4
This moves read_offset_1 to leb.c, as it is a low-level data-reading function. It is also renamed to remove the "_1", because gdb can use overloading now, and this is clearer. 2020-02-08 Tom Tromey <tom@tromey.com> * dwarf2/read.c (read_offset_1): Move to leb.c. (read_abbrev_offset, read_offset, dwarf_decode_line_header) (dwarf_decode_macro_bytes): Update. * dwarf2/leb.c (read_offset): Rename; move from read.c. * dwarf2/leb.h (read_offset): Declare. Change-Id: I048140598acfa76eade2cc529ab7933d4b9ca0b3
2020-02-08Unify read_initial_length implementationsTom Tromey1-0/+41
There are two implementations of read_initial_length in gdb. This merges them and moves the resulting function to leb.c. 2020-02-08 Tom Tromey <tom@tromey.com> * dwarf2/read.c (read_initial_length): Move to leb.c. * dwarf2/leb.h (read_initial_length): Declare. * dwarf2/leb.c (read_initial_length): Move from read.c. Add handle_nonstd parameter. * dwarf2/frame.c (read_initial_length): Remove. (decode_frame_entry_1): Update. Change-Id: I34d37bad0f8a584bfa781432cba25e05e1bd5750
2020-02-08Create dwarf2/leb.[ch]Tom Tromey1-0/+92
This moves some scalar-unpacking code into a couple of new files, dwarf2/leb.h and dwarf2/leb.c. gdb/ChangeLog 2020-02-08 Tom Tromey <tom@tromey.com> * dwarf2read.h (read_unsigned_leb128): Don't declare. * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes) (read_2_signed_bytes, read_3_bytes, read_4_bytes) (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h. (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c. * dwarf2/leb.h: New file, from dwarf2read.c. * dwarf2/leb.c: New file, from dwarf2read.c. * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes): Remove. * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2. (COMMON_SFILES): Add dwarf2/leb.c. Change-Id: Idd19647686c8f959d226a95fdfca4db47c6e96d0