From: Tom Tromey <tom@tromey.com>
To: "Dmitry Ivanov (A)" <dmitry.ivanov1@huawei.com>
Cc: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
Subject: Re: [PATCH] gdb/python: Handle unnamed frames in caller-matching functions
Date: Wed, 14 Oct 2026 10:04:31 -0600 [thread overview]
Message-ID: <8733u846b4.fsf@tromey.com> (raw)
In-Reply-To: <b6c0fdcc58b0404fac6f31fa40c6156f@huawei.com> (Dmitry Ivanov's message of "Tue, 13 Oct 2026 11:35:16 +0000")
>>>>> Dmitry Ivanov (A) <dmitry.ivanov1@huawei.com> writes:
> This is my first GDB contribution.
Hi. However you sent this, the mail got pretty mangled somewhere.
There are a lot of extra newlines. So it can't be applied as-is.
> + frame_name = frame.name()
> + return frame_name is not None and re.match(name.string(), frame_name) is not None
I wonder if instead the None case should be turned into an empty string
here, so a user of $_caller_matches could match against "^$" to detect
nameless frames.
I think this would be as easy as
frame_name = frame.name() or ""
In this case perhaps the documentation could be updated a bit as well.
> +# Prepend an unnamed frame to the current stack without depending on
> +# missing symbols in the host's runtime libraries.
Cool technique.
Tom
prev parent reply other threads:[~2026-10-14 16:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <b555285517bf4506b85c0421ea062784@huawei.com>
2026-10-13 11:35 ` Dmitry Ivanov (A)
2026-10-14 16:04 ` Tom Tromey [this message]
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=8733u846b4.fsf@tromey.com \
--to=tom@tromey.com \
--cc=dmitry.ivanov1@huawei.com \
--cc=gdb-patches@sourceware.org \
/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