From: Andrew Burgess <aburgess@redhat.com>
To: Simon Marchi <simark@simark.ca>, Tom Tromey <tom@tromey.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCHv3] gdb: resolve class name via DW_AT_signature in cooked index
Date: Wed, 16 Sep 2026 12:40:44 +0100 [thread overview]
Message-ID: <87zexhbf0j.fsf@redhat.com> (raw)
In-Reply-To: <20947682-a728-4eaa-b914-5bcc3be11897@simark.ca>
Simon Marchi <simark@simark.ca> writes:
> On 2026-09-15 11:55, Simon Marchi wrote:
>> Having a bad parent is rare, that would only happen when some
>> (nameless) type has a DW_AT_signature and the matching type unit can't
>> be found. That would be a buggy producer that "forgets" to add the
>> necessary type units.
>>
>> But the basic case where the name fixup is needed isn't an error case,
>> it's just what happens when using clang with -fdebug-types-section,
>> since structures/classes are nameless:
>>
>> 0x0000099e: DW_TAG_structure_type
>> DW_AT_declaration [DW_FORM_flag_present] (true)
>> DW_AT_signature [DW_FORM_ref_sig8] (0xdf1329ababfff8ca)
>>
>> So I suppose you'll get one fixup to do per structure/class type.
>>
>> Doing the fixups in parallel is easy, since it's just looking up the
>> signature -> maps, and the "finalize" step already exists, so why not.
>
> I tested this patch on a big program (Blender). I moved the deferred
> name computation to set_contents (done serially). It takes 0.014
> seconds to do it for 820602 names. So yeah, I'm fine if you want to
> move it to set_contents (done serially) for simplicity.
I'd already written v4 before I read this reply. In v4 I do have the
cleanup performed in parallel, though this does add a little more
complexity into cooked_index::set_contents. You'll have to let me know
what you think, I can always go back to the approach you're proposing
here if you don't like v4.
Thanks,
Andrew
next prev parent reply other threads:[~2026-09-16 11:41 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-19 10:03 [PATCH] [GDB 18] " Andrew Burgess
2026-08-21 17:07 ` Tom Tromey
2026-08-28 21:30 ` [PATCHv2] " Andrew Burgess
2026-09-01 13:31 ` [PATCHv3] " Andrew Burgess
2026-09-10 16:11 ` Simon Marchi
2026-09-11 19:18 ` Tom Tromey
2026-09-12 2:06 ` Simon Marchi
2026-09-14 13:23 ` Andrew Burgess
2026-09-14 14:57 ` Simon Marchi
2026-09-14 15:38 ` Tom Tromey
2026-09-15 10:25 ` Andrew Burgess
2026-09-15 15:01 ` Tom Tromey
2026-09-15 15:55 ` Simon Marchi
2026-09-15 17:21 ` Simon Marchi
2026-09-16 11:40 ` Andrew Burgess [this message]
2026-09-16 11:45 ` Andrew Burgess
2026-09-16 11:48 ` Andrew Burgess
2026-09-14 15:36 ` Tom Tromey
2026-09-10 16:18 ` Simon Marchi
2026-09-16 11:38 ` [PATCHv4] " Andrew Burgess
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87zexhbf0j.fsf@redhat.com \
--to=aburgess@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=simark@simark.ca \
--cc=tom@tromey.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox