x/debug: speed up various DWARF information queries.
Builds auxiliary tables from the DWARF data to speed up requests for:
- Entries with a given name or matching a regexp (using a map from
symbol name to a linked list of *Entry)
- Mapping a PC to a function (using a slice of function bounds, sorted
- Mapping a PC to a source line (using a slice of structs containing
(PC, file, line), sorted by PC).
- Mapping a source line to breakpoint addresses (using a slice
containing, for each file, a slice of (line, PC) pairs sorted by line.)
Renames some functions to better reflect their return values
Uses more specific lookups for entries that must be variables
Reviewed-by: Dave Day <firstname.lastname@example.org>
8 files changed