Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Eli Zaretskii via Gdb-patches <gdb-patches@sourceware.org>
To: Luis Machado <luis.machado@arm.com>
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 12:20:48 +0300	[thread overview]
Message-ID: <831qkp8nin.fsf@gnu.org> (raw)
In-Reply-To: <63c2cf2c-692c-7737-d0ee-b8cb30439b4c@arm.com> (message from Luis Machado on Wed, 12 Apr 2023 09:46:31 +0100)

> 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

  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.

Is it really important to say that the bug happens only when
additional system registers are reported?

  reply	other threads:[~2023-04-12  9:20 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-11 22:43 Luis Machado via Gdb-patches
2023-04-12  6:05 ` Eli Zaretskii via Gdb-patches
2023-04-12  8:46   ` Luis Machado via Gdb-patches
2023-04-12  9:20     ` Eli Zaretskii via Gdb-patches [this message]
2023-04-12  9:25       ` Luis Machado via Gdb-patches
2023-04-12  9:54         ` Eli Zaretskii via Gdb-patches
2023-04-12 11:48         ` Peter Maydell via Gdb-patches
2023-04-12 11:57           ` Luis Machado via Gdb-patches
2023-04-13 13:55         ` Tom Tromey
2023-04-12 12:27 ` [PATCH, v2] " Luis Machado via Gdb-patches
2023-04-12 12:45   ` Eli Zaretskii via Gdb-patches
2023-04-13 13:56   ` Tom Tromey
2023-04-13 14:05     ` Luis Machado via Gdb-patches
2023-04-13 14:37   ` [PATCH, v3] " Luis Machado via Gdb-patches
2023-04-13 17:17     ` Tom Tromey
2023-04-14 12:45       ` Luis Machado via Gdb-patches

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=831qkp8nin.fsf@gnu.org \
    --to=gdb-patches@sourceware.org \
    --cc=alex.bennee@linaro.org \
    --cc=eliz@gnu.org \
    --cc=luis.machado@arm.com \
    --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