Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Yao Qi <yao@codesourcery.com>
To: gdb-patches@sourceware.org
Subject: Re: [patch, arm] Consistent display of registers in corefile
Date: Thu, 13 Jan 2011 13:45:00 -0000	[thread overview]
Message-ID: <4D2EF249.6010308@codesourcery.com> (raw)
In-Reply-To: <4D022D1A.7030701@codesourcery.com>

[-- Attachment #1: Type: text/plain, Size: 654 bytes --]

On 12/10/2010 07:37 AM, Yao Qi wrote:
 > gdb/
 > 	* arm-tdep.c (arm_register_reggroup_p): New.
 > 	(arm_gdbarch_init): Set arm_register_reggroup_p for hook
 > 	register_reggroup_p.

> +static int
> +arm_register_reggroup_p (struct gdbarch *gdbarch, int regnum,
> +			  struct reggroup *group)
> +{
> +  /* FPS register's type is INT, but belongs to float_group.  */
> +  if (regnum == ARM_FPS_REGNUM)
> +    return (group == float_reggroup);

FPS belongs to float_reggroup, save_reggroup, and restore_reggroup, 
instead of float_reggroup only.

OK to apply?

> +  else
> +    return default_register_reggroup_p (gdbarch, regnum, group);
> +}

-- 
Yao Qi

[-- Attachment #2: fsp_save_restore_reggroup.patch --]
[-- Type: text/x-patch, Size: 782 bytes --]

gdb/
	* arm-tdep.c (arm_register_reggroup_p): FPS register is in
	save_reggroup and restore_reggroup.

diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index 9ec410d..d32b685 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -7234,9 +7234,12 @@ static int
 arm_register_reggroup_p (struct gdbarch *gdbarch, int regnum,
 			  struct reggroup *group)
 {
-  /* FPS register's type is INT, but belongs to float_group.  */
+  /* FPS register's type is INT, but belongs to float_reggroup,
+     save_regroup, and restore_reggroup.  */
   if (regnum == ARM_FPS_REGNUM)
-    return (group == float_reggroup);
+    return (group == float_reggroup
+	    || group == save_reggroup
+	    || group == restore_reggroup);
   else
     return default_register_reggroup_p (gdbarch, regnum, group);
 }

  parent reply	other threads:[~2011-01-13 12:38 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-10 13:37 Yao Qi
2010-12-10 14:46 ` Mark Kettenis
2010-12-10 15:07   ` Yao Qi
2010-12-13  2:57   ` Daniel Jacobowitz
2010-12-13 10:00     ` Yao Qi
2010-12-19 18:24       ` Daniel Jacobowitz
2010-12-20  2:29         ` Yao Qi
2010-12-20  3:09           ` Daniel Jacobowitz
2011-01-13 13:45 ` Yao Qi [this message]
2011-01-13 16:04   ` Ulrich Weigand
2011-01-13 16:47     ` Yao Qi
2011-01-14 16:52       ` Ulrich Weigand

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=4D2EF249.6010308@codesourcery.com \
    --to=yao@codesourcery.com \
    --cc=gdb-patches@sourceware.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