diff options
author | Tom Tromey <tom@tromey.com> | 2023-12-02 13:18:13 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2024-01-18 08:20:17 -0700 |
commit | b371f07c47c73d9597f74f87bc6e22ba04db1963 (patch) | |
tree | 9939ee1e8dadc836c5a18fc57e2748613b70ab0a /gdb/python/py-infthread.c | |
parent | 9b63bc4644da4c91bf93a2332f6701250abec7e2 (diff) | |
download | binutils-b371f07c47c73d9597f74f87bc6e22ba04db1963.zip binutils-b371f07c47c73d9597f74f87bc6e22ba04db1963.tar.gz binutils-b371f07c47c73d9597f74f87bc6e22ba04db1963.tar.bz2 |
Rewrite .debug_names reader
This rewrites the .debug_names reader to follow the spec.
Since it was first written, gdb's .debug_names writer has been
incorrect -- while the form of the section has been ok, the contents
have been very gdb-specific.
This patch fixes the reader side of this equation, rewriting the
reader to create a cooked index internally -- an important detail
because it allows for the deletion of a lot of code, and it means the
various readers will agree more often.
This reader checks for a new augmentation string. For the time being,
all other producers are ignored -- the old GDB ones because they are
wrong, and clang because it does not emit DW_IDX_parent. (If there
are any other producers, I'm unaware of them.)
While the new reader mostly runs in a worker thread, it does not try
to distribute its work. This could be done by partitioning the name
table. The parent computations could also be done in parallel after
all names have been read. I haven't attempted this.
Note that this patch temporarily regresses gdb.base/gdb-index-err.exp.
This test writes an index using gdb -- but at this particular stage,
gdb cannot read the indexes it creates. Rather than merge the patches
into a mega-patch, I've chosen to just accept this temporary
regression.
In v1 of this patch, I made the new reader more strict about requiring
.debug_aranges. In v2, I've backed this out and kept the previous
logic. This solved a few test failures, though it's arguably not the
right approach.
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=25950
Diffstat (limited to 'gdb/python/py-infthread.c')
0 files changed, 0 insertions, 0 deletions