readdwarf3.c (parse_inl_DIE) inlined_subroutine can appear in namespaces
commit542447d4708d4418a08e678dcf467af92b90b7ad
authorMark Wielaard <mark@klomp.org>
Mon, 22 Nov 2021 12:07:59 +0000 (22 13:07 +0100)
committerMark Wielaard <mark@klomp.org>
Mon, 22 Nov 2021 12:15:36 +0000 (22 13:15 +0100)
tree6546556cc84a4cb12ffb5c14dff4eb9ae551ad63
parente484eee0bdf0a77fc260b69ac7495352e1a972e3
readdwarf3.c (parse_inl_DIE) inlined_subroutine can appear in namespaces

This was broken by commit 75e3ef0f3 "readdwarf3: Skip units without
addresses when looking for inlined functions". Specifically by this
part: "Also use skip_DIE instead of read_DIE when not parsing
(skipping) children"

rustc puts concrete function instances in namespaces (which is
allowed in DWARF since there is no strict separation between type
declarations and program scope entries in a DIE tree), the inline
parser didn't expect this and so skipped any DIE under a namespace
entry. This wasn't an issue before because "skipping" a DIE tree was
done by reading it, so it wasn't actually skipped. But now that we
really skip the DIE (sub)tree (which is faster than actually parsing
it) some entries were missed in the rustc case.

https://bugs.kde.org/show_bug.cgi?id=445668
NEWS
coregrind/m_debuginfo/readdwarf3.c