]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Handle DWARF 5 separate debug sections
authorTom Tromey <tom@tromey.com>
Wed, 19 Mar 2025 20:47:29 +0000 (14:47 -0600)
committerTom Tromey <tom@tromey.com>
Tue, 22 Apr 2025 22:06:51 +0000 (16:06 -0600)
commit7b80401da008375af1e7cc154fb8163aa406f13d
tree59af258d6fcc702185f934695644a38e95d4fae2
parent1e1ef933d114b6c144785b4478346d75499c4d3d
Handle DWARF 5 separate debug sections

DWARF 5 standardized the .gnu_debugaltlink section that dwz emits in
multi-file mode.  This is handled via some new forms, and a new
.debug_sup section.

This patch adds support for this to gdb.  It is largely
straightforward, I think, though one oddity is that I chose not to
have this code search the system build-id directories for the
supplementary file.  My feeling was that, while it makes sense for a
distro to unify the build-id concept with the hash stored in the
.debug_sup section, there's no intrinsic need to do so.

This in turn means that a few tests -- for example those that test the
index cache -- will not work in this mode.

Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=32808
Acked-By: Simon Marchi <simon.marchi@efficios.com>
15 files changed:
gdb/dwarf2/attribute.c
gdb/dwarf2/attribute.h
gdb/dwarf2/cooked-indexer.c
gdb/dwarf2/die.c
gdb/dwarf2/dwz.c
gdb/dwarf2/dwz.h
gdb/dwarf2/macro.c
gdb/dwarf2/read.c
gdb/dwarf2/read.h
gdb/testsuite/gdb.dwarf2/dwzbuildid.exp
gdb/testsuite/gdb.dwarf2/dwzbuildid.tcl [new file with mode: 0644]
gdb/testsuite/gdb.dwarf2/dwzbuildid5.exp [new file with mode: 0644]
gdb/testsuite/gdb.dwarf2/dwznolink.exp
gdb/testsuite/gdb.dwarf2/no-gnu-debuglink.exp
gdb/testsuite/lib/dwarf.exp