From: Luis Machado <luis.machado@arm.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb-patches@sourceware.org, alex.bennee@linaro.org,
richard.henderson@linaro.org, peter.maydell@linaro.org
Subject: Re: [PATCH] [gdb/aarch64] pauth: Create new feature string for pauth to prevent crashing older gdb's
Date: Wed, 12 Apr 2023 10:25:56 +0100 [thread overview]
Message-ID: <9ae7c1bd-64d3-7444-fbc7-e536f8b2f971@arm.com> (raw)
In-Reply-To: <831qkp8nin.fsf@gnu.org>
On 4/12/23 10:20, Eli Zaretskii wrote:
>> Date: Wed, 12 Apr 2023 09:46:31 +0100
>> Cc: gdb-patches@sourceware.org, alex.bennee@linaro.org,
>> richard.henderson@linaro.org, peter.maydell@linaro.org
>> From: Luis Machado <luis.machado@arm.com>
>>
>> How about the following flow?
>>
>> In the future the @samp{org.gnu.gdb.aarch64.pauth} feature string might be
>> deprecated in favor of feature string @samp{org.gnu.gdb.aarch64.pauth_v2}.
>>
>> The @samp{org.gnu.gdb.aarch64.pauth_v2} feature has the exact same contents
>> as feature @samp{org.gnu.gdb.aarch64.pauth}.
>>
>> Targets reporting Pointer Authentication support via the remote protocol
>> should always use the newer feature string
>> @samp{org.gnu.gdb.aarch64.pauth_v2}.
>>
>> The reason for having feature @samp{org.gnu.gdb.aarch64.pauth_v2} is a bug in
>> previous versions of @value{GDBN} (versions 9, 10, 11 and 12). This bug
>> caused @value{GDBN} to crash whenever the target reported support for Pointer
>> Authentication (using feature string @samp{org.gnu.gdb.aarch64.pauth}) and also
>> reported additional system registers that were not accounted for by
>> @value{GDBN}. This is common when using emulators and on bare-metal debugging
>> scenarios.
>
> The flow is OK, but the last paragraph is too long. The main reason
> of this text is to tell people to use the v2 feature, not to explain
> why it exists. So the explanation of the reason should be shorter
> like
Though it is documentation for users, it is also one of the only documents providing guidance for developers of debugging stubs (like QEMU's, openOCD etc).
So I feel like it should include a bit more information rather than the bare minimum.
I don't think this particular section (XML target descriptions) is geared towards the common debugger users.
>
> We recommend always using the @samp{org.gnu.gdb.aarch64.pauth_v2}
> feature because using @samp{org.gnu.gdb.aarch64.pauth} could crash
> older versions of @value{GDBN} due to a known bug in those versions.
I think the above is sane. It just has less detail, which, as explained above, might not be too useful for
developers of debugging stubs.
>
> Is it really important to say that the bug happens only when
> additional system registers are reported?
We could make it shorter by only mentioning this is only an issue when using emulators.
next prev parent reply other threads:[~2023-04-12 9:26 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-11 22:43 Luis Machado
2023-04-12 6:05 ` Eli Zaretskii
2023-04-12 8:46 ` Luis Machado
2023-04-12 9:20 ` Eli Zaretskii
2023-04-12 9:25 ` Luis Machado [this message]
2023-04-12 9:54 ` Eli Zaretskii
2023-04-12 11:48 ` Peter Maydell
2023-04-12 11:57 ` Luis Machado
2023-04-13 13:55 ` Tom Tromey
2023-04-12 12:27 ` [PATCH,v2] " Luis Machado
2023-04-12 12:45 ` Eli Zaretskii
2023-04-13 13:56 ` [PATCH, v2] " Tom Tromey
2023-04-13 14:05 ` Luis Machado
2023-04-13 14:37 ` [PATCH, v3] " Luis Machado
2023-04-13 17:17 ` Tom Tromey
2023-04-14 12:45 ` Luis Machado
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=9ae7c1bd-64d3-7444-fbc7-e536f8b2f971@arm.com \
--to=luis.machado@arm.com \
--cc=alex.bennee@linaro.org \
--cc=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
--cc=peter.maydell@linaro.org \
--cc=richard.henderson@linaro.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).