Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: <Ezra.Sitorus@arm.com>
To: <gdb-patches@sourceware.org>
Cc: <luis.machado.foss@gmail.com>, Ezra Sitorus <ezra.sitorus@arm.com>
Subject: [PATCH v4 4/6] gdb/aarch64: core file support for FPMR
Date: Fri, 31 Oct 2025 15:16:39 +0000	[thread overview]
Message-ID: <20251031151641.83369-5-Ezra.Sitorus@arm.com> (raw)
In-Reply-To: <20251031151641.83369-1-Ezra.Sitorus@arm.com>

From: Ezra Sitorus <ezra.sitorus@arm.com>

Add support for FPMR dumps/reads for core files.
---
Changes from v1->v2:
* Addressed comments/whitespace/formatting issues.

Changes from v2->v3:
* Removed supply/collect functions for FPMR register set
* Used generic supply/collect functions like MTE register set.

Ezra

 gdb/aarch64-linux-tdep.c | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c
index 5346ae39eda..6966dc1ab0f 100644
--- a/gdb/aarch64-linux-tdep.c
+++ b/gdb/aarch64-linux-tdep.c
@@ -1635,6 +1635,23 @@ aarch64_linux_iterate_over_regset_sections (struct gdbarch *gdbarch,
 	}
     }
 
+  if (tdep->has_fpmr ())
+    {
+      const struct regcache_map_entry fpmr_regmap[] =
+	{
+	  { 1, tdep->fpmr_regnum, sizeof (uint64_t) },
+	  { 0 }
+	};
+
+      const struct regset aarch64_linux_fpmr_regset =
+	{
+	  fpmr_regmap, regcache_supply_regset, regcache_collect_regset
+	};
+
+      cb (".reg-aarch-fpmr", sizeof (uint64_t), sizeof (uint64_t),
+	  &aarch64_linux_fpmr_regset, "FPMR", cb_data);
+    }
+
   if (tdep->has_pauth ())
     {
       /* Create this on the fly in order to handle the variable location.  */
-- 
2.45.2


  parent reply	other threads:[~2025-10-31 15:21 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-31 15:16 [PATCH v4 0/6] gdb/aarch64: Support " Ezra.Sitorus
2025-10-31 15:16 ` [PATCH v4 1/6] gdb/aarch64: Enable FPMR for AArch64 in gdb on Linux Ezra.Sitorus
2025-10-31 15:16 ` [PATCH v4 2/6] gdbserver/aarch64: Enable FPMR for AArch64 in gdbserver " Ezra.Sitorus
2025-10-31 15:16 ` [PATCH v4 3/6] gdb/aarch64: signal frame support for fpmr Ezra.Sitorus
2025-10-31 15:16 ` Ezra.Sitorus [this message]
2025-10-31 15:16 ` [PATCH v4 5/6] gdb/aarch64: Tests " Ezra.Sitorus
2025-11-09 20:11   ` Luis
2025-10-31 15:16 ` [PATCH v4 6/6] gdb/doc: Document AArch64 FPMR support Ezra.Sitorus
2025-10-31 16:57   ` Eli Zaretskii
2025-11-09 20:15   ` Luis
2025-11-10 12:00     ` Eli Zaretskii
2025-11-10 17:28     ` Ezra Sitorus
2025-11-14  7:38       ` Luis

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=20251031151641.83369-5-Ezra.Sitorus@arm.com \
    --to=ezra.sitorus@arm.com \
    --cc=gdb-patches@sourceware.org \
    --cc=luis.machado.foss@gmail.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