From: Eli Zaretskii <eliz@gnu.org>
To: Christina Schimpe <christina.schimpe@intel.com>
Cc: gdb-patches@sourceware.org, hjl.tools@gmail.com, keiths@redhat.com
Subject: Re: [PATCH 1/2] gdb: add maintenance set/show gcore xml-target-description command
Date: Tue, 02 Jun 2026 15:22:26 +0300 [thread overview]
Message-ID: <867bohw2rh.fsf@gnu.org> (raw)
In-Reply-To: <20260602111122.3187712-2-christina.schimpe@intel.com> (message from Christina Schimpe on Tue, 2 Jun 2026 11:11:21 +0000)
> From: Christina Schimpe <christina.schimpe@intel.com>
> Cc: hjl.tools@gmail.com,
> keiths@redhat.com
> Date: Tue, 2 Jun 2026 11:11:21 +0000
>
> From: Felix Willgerodt <felix.willgerodt@intel.com>
>
> This command will allow to enable/disable creating the NT_GDB_TDESC note
> in corefiles. While GDB writes and reads this node, there aren't really many
> other pieces of software that create this node (e.g. the Linux kernel doesn't).
> To be able to test the code path in GDB that is used when NT_GDB_TDESC is not
> there, add a maintenance command which tests can use to test both cases.
>
> Co-authored-by: Christina Schimpe <christina.schimpe@intel.com>
> ---
> gdb/NEWS | 6 ++++++
> gdb/doc/gdb.texinfo | 7 +++++++
> gdb/elf-none-tdep.c | 16 +++++++++-------
> gdb/fbsd-tdep.c | 15 +++++++++------
> gdb/gcore.c | 40 ++++++++++++++++++++++++++++++++++++++++
> gdb/gcore.h | 3 +++
> gdb/linux-tdep.c | 15 +++++++++------
> 7 files changed, 83 insertions(+), 19 deletions(-)
Thanks.
> diff --git a/gdb/NEWS b/gdb/NEWS
> index 7c8cf9af4c2..eef1924c9f0 100644
> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -97,6 +97,12 @@ AArch64 MinGW aarch64-*-mingw*
>
> * New commands
>
> +maintenance set/show gcore xml-target-description
> + With this command you can control whether or not the generate-core-file
> + command emits the NT_GDB_TDESC note. This is mainly useful for testing
> + how GDB handles corefiles without this note, as not all software that
> + creates corefiles generates it.
> +
If this command controls the emission of NT_GDB_TDESC note, then why
its name mentions a more general XML target description? Am I right
in assuming that NT_GDB_TDESC is just part of the target description?
If so, perhaps the xml-target-description part should be renamed, or
maybe the NEWS text should be modified to say that the entire target
description is emitted as XML?
> --- a/gdb/doc/gdb.texinfo
> +++ b/gdb/doc/gdb.texinfo
> @@ -42077,6 +42077,13 @@ buffer.
> Control whether @value{GDBN} will skip PAD packets when computing the
> packet history.
>
> +@kindex maint set gcore xml-target-description
> +@item maint set gcore xml-target-description
> +@kindex maint show gcore xml-target-description
> +@item maint show gcore xml-target-description
> +Control whether @value{GDBN} will create the NT_GDB_TDESC note when using
> +the @samp{generate-core-file} command.
NT_GDB_TDESC should be in @code or @samp.
> + add_setshow_boolean_cmd ("xml-target-description", class_obscure,
> + &maint_gcore_emit_xml_tdesc, _("\
> +Set whether gcore emits a xml-target-description."), _("\
> +Show whether gore emits a xml-target-description."), _("\
> +By default, gcore emits the note NT_GDB_TDESC.\n\
> +Disabling this setting will cause gcore to no longer emit this note."),
This doc string has the same issue: it say GDB will emit the XML
target description, but then goes on to say that NT_GDB_TDESC note is
emitted.
Reviewed-By: Eli Zaretskii <eliz@gnu.org>
next prev parent reply other threads:[~2026-06-02 12:22 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-02 11:11 [PATCH 0/2] Add Intel APX support Christina Schimpe
2026-06-02 11:11 ` [PATCH 1/2] gdb: add maintenance set/show gcore xml-target-description command Christina Schimpe
2026-06-02 12:22 ` Eli Zaretskii [this message]
2026-06-09 21:02 ` Schimpe, Christina
2026-06-10 11:43 ` Eli Zaretskii
2026-06-15 7:54 ` Schimpe, Christina
2026-06-18 17:31 ` Keith Seitz
2026-07-07 17:07 ` Schimpe, Christina
2026-07-10 11:57 ` Schimpe, Christina
2026-06-02 11:11 ` [PATCH 2/2] gdb, gdbserver: Add Intel APX register support Christina Schimpe
2026-06-02 12:25 ` Eli Zaretskii
2026-06-18 17:33 ` Keith Seitz
2026-07-07 17:15 ` Schimpe, Christina
2026-07-07 17:53 ` Keith Seitz
2026-07-07 17:15 ` Schimpe, Christina
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=867bohw2rh.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=christina.schimpe@intel.com \
--cc=gdb-patches@sourceware.org \
--cc=hjl.tools@gmail.com \
--cc=keiths@redhat.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