https://bugs.kde.org/show_bug.cgi?id=445668

--- Comment #6 from Mark Wielaard <m...@klomp.org> ---
I think I found it. 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.
The following patch fixes it:

diff --git a/coregrind/m_debuginfo/readdwarf3.c
b/coregrind/m_debuginfo/readdwarf3.c
index 18eecea9f..5489f8d13 100644
--- a/coregrind/m_debuginfo/readdwarf3.c
+++ b/coregrind/m_debuginfo/readdwarf3.c
@@ -3358,7 +3358,7 @@ static Bool parse_inl_DIE (
    // might maybe contain a DW_TAG_inlined_subroutine:
    Bool ret = (unit_has_addrs
                || dtag == DW_TAG_lexical_block || dtag == DW_TAG_subprogram
-               || dtag == DW_TAG_inlined_subroutine);
+               || dtag == DW_TAG_inlined_subroutine || dtag ==
DW_TAG_namespace);
    return ret;

   bad_DIE:

Does that also work for your larger example?

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to