Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Stephan Rohr <stephan.rohr@intel.com>
To: gdb-patches@sourceware.org
Cc: pedro@palves.net, jhb@FreeBSD.org, luis.machado@arm.com,
	christina.joos@intel.com
Subject: [PATCH v4 4/5] gdb: add a "matrix" register group
Date: Tue, 10 Nov 2026 15:57:28 +0000	[thread overview]
Message-ID: <20261110155729.436474-5-stephan.rohr@intel.com> (raw)
In-Reply-To: <20261110155729.436474-1-stephan.rohr@intel.com>

From: "Rohr, Stephan" <stephan.rohr@intel.com>

Add "matrix" as a new standard register group, next to the "vector"
register group.  Architectures can use it for registers that hold
matrices, which can then be listed with "info registers matrix".

By default, no register is part of the group.

This is in preparation to add Intel AMX registers as user registers.

Reviewed-By: Eli Zaretskii <eliz@gnu.org>
---
 gdb/NEWS            | 3 +++
 gdb/doc/gdb.texinfo | 6 ++++--
 gdb/reggroups.c     | 3 +++
 gdb/reggroups.h     | 1 +
 4 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/gdb/NEWS b/gdb/NEWS
index 86446c36722..0a0d3edc624 100644
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -45,6 +45,9 @@
   source is modified.  Source tracking can be enabled with 'set
   breakpoint source-tracking enabled on'.
 
+* A new standard register group "matrix" has been added.  Its registers can
+  be printed with "info registers matrix".
+
 * New targets
 
 i386 Windows/MSVC               i[34567]86-*-windows-msvc
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 5b11c7b30ac..7f0c8d24c42 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -42789,6 +42789,7 @@ The register groups info looks like this:
  float      user
  all        user
  vector     user
+ matrix     user
  system     user
  save       internal
  restore    internal
@@ -49869,8 +49870,9 @@ architecture's normal floating point format) of the correct size for
 
 @item group
 The register group to which this register belongs.  It can be one of the
-standard register groups @code{general}, @code{float}, @code{vector} or an
-arbitrary string.  Group names should be limited to alphanumeric characters.
+standard register groups @code{general}, @code{float}, @code{vector},
+@code{matrix} or an arbitrary string.  Group names should be limited to
+alphanumeric characters.
 If a group name is made up of multiple words the words may be separated by
 hyphens; e.g.@: @code{special-group} or @code{ultra-special-group}.  If no
 @var{group} is specified, @value{GDBN} will not display the register in
diff --git a/gdb/reggroups.c b/gdb/reggroups.c
index b0d3fd82185..a0f86baa5ac 100644
--- a/gdb/reggroups.c
+++ b/gdb/reggroups.c
@@ -58,6 +58,7 @@ struct reggroups
     add (float_reggroup);
     add (system_reggroup);
     add (vector_reggroup);
+    add (matrix_reggroup);
     add (all_reggroup);
     add (save_reggroup);
     add (restore_reggroup);
@@ -240,6 +241,7 @@ static const reggroup general_group = { "general", USER_REGGROUP };
 static const reggroup float_group = { "float", USER_REGGROUP };
 static const reggroup system_group = { "system", USER_REGGROUP };
 static const reggroup vector_group = { "vector", USER_REGGROUP };
+static const reggroup matrix_group = { "matrix", USER_REGGROUP };
 static const reggroup all_group = { "all", USER_REGGROUP };
 static const reggroup save_group = { "save", INTERNAL_REGGROUP };
 static const reggroup restore_group = { "restore", INTERNAL_REGGROUP };
@@ -248,6 +250,7 @@ const reggroup *const general_reggroup = &general_group;
 const reggroup *const float_reggroup = &float_group;
 const reggroup *const system_reggroup = &system_group;
 const reggroup *const vector_reggroup = &vector_group;
+const reggroup *const matrix_reggroup = &matrix_group;
 const reggroup *const all_reggroup = &all_group;
 const reggroup *const save_reggroup = &save_group;
 const reggroup *const restore_reggroup = &restore_group;
diff --git a/gdb/reggroups.h b/gdb/reggroups.h
index 47824d5427e..a827c775992 100644
--- a/gdb/reggroups.h
+++ b/gdb/reggroups.h
@@ -68,6 +68,7 @@ extern const reggroup *const general_reggroup;
 extern const reggroup *const float_reggroup;
 extern const reggroup *const system_reggroup;
 extern const reggroup *const vector_reggroup;
+extern const reggroup *const matrix_reggroup;
 extern const reggroup *const all_reggroup;
 
 /* Pre-defined, internal, register groups.  */
-- 
2.43.0

________________________________________
Intel Deutschland GmbH 

Registered Address: Dornacher Strasse 1, 85622 Feldkirchen, Germany 

Tel: +49 (89) 99143-0 

www.intel.de 

Managing Directors: Candice Moore, Jeffrey Schneiderman, Ramachandran Sitaraman

Chairperson of the Supervisory Board: Sonja Pierer

Registered Seat: Munich Commercial Register B: Amtsgericht Munich HRB 186928

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


  parent reply	other threads:[~2026-11-10 15:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-10 15:57 [PATCH v4 0/5] Add Intel AMX support Stephan Rohr
2026-11-10 15:57 ` [PATCH v4 1/5] gdb: define additional integer built-in types Stephan Rohr
2026-11-10 15:57 ` [PATCH v4 2/5] gdb, gdbserver: Add Intel AMX registers Stephan Rohr
2026-11-10 15:57 ` [PATCH v4 3/5] gdb: support register groups for user registers Stephan Rohr
2026-11-10 15:57 ` Stephan Rohr [this message]
2026-11-10 15:57 ` [PATCH v4 5/5] gdb: add Intel AMX tile registers as " Stephan Rohr
2026-11-24 14:01 ` [PING][PATCH v4 0/5] Add Intel AMX support Rohr, Stephan

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=20261110155729.436474-5-stephan.rohr@intel.com \
    --to=stephan.rohr@intel.com \
    --cc=christina.joos@intel.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jhb@FreeBSD.org \
    --cc=luis.machado@arm.com \
    --cc=pedro@palves.net \
    /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