From: Michael Snyder <msnyder@cygnus.com>
To: gdb-patches@sources.redhat.com
Cc: cagney@redhat.com, kevinb@redhat.com
Subject: [RFA] mips_register_virtual_type
Date: Tue, 20 Aug 2002 17:13:00 -0000 [thread overview]
Message-ID: <200208202355.g7KNtsv00654@reddwarf.sfbay.redhat.com> (raw)
Andrew, Kevin,
I think with this change, mips_virtual_register_type is robust enough
to use with all mips configurations. What do you think? Can we
blow away the remaining definitions of REGISTER_VIRTUAL_TYPE?
Michael
2002-08-20 Michael Snyder <msnyder@redhat.com>
* mips-tdep.c (mips_register_virtual_type): Account for
FP_REGISTER_DOUBLE.
Index: mips-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/mips-tdep.c,v
retrieving revision 1.115
diff -p -r1.115 mips-tdep.c
*** mips-tdep.c 20 Aug 2002 23:07:42 -0000 1.115
--- mips-tdep.c 21 Aug 2002 00:10:08 -0000
*************** if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG
*** 571,577 ****
definitions found in config/mips/tm-*.h. I'm concerned about
the ``FCRCS_REGNUM <= reg && reg <= LAST_EMBED_REGNUM'' clause
though. In some cases FP_REGNUM is in this range, and I doubt
! that this code is correct for the 64-bit case. */
static struct type *
mips_register_virtual_type (int reg)
--- 571,581 ----
definitions found in config/mips/tm-*.h. I'm concerned about
the ``FCRCS_REGNUM <= reg && reg <= LAST_EMBED_REGNUM'' clause
though. In some cases FP_REGNUM is in this range, and I doubt
! that this code is correct for the 64-bit case.
!
! MVS: FCRCS_REGNUM will not overlap with the FP registers.
! On Irix, the FP registers run from 32 to 63 and FCRCS is 69.
! Everywhere else, they run from 38 to 69 and FCRCS is 70. */
static struct type *
mips_register_virtual_type (int reg)
*************** mips_register_virtual_type (int reg)
*** 580,588 ****
{
/* Floating point registers... */
if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
! return builtin_type_ieee_double_big;
else
! return builtin_type_ieee_double_little;
}
else if (reg == PS_REGNUM /* CR */)
return builtin_type_uint32;
--- 584,594 ----
{
/* Floating point registers... */
if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
! return FP_REGISTER_DOUBLE ?
! builtin_type_ieee_double_big : builtin_type_ieee_single_big;
else
! return FP_REGISTER_DOUBLE ?
! builtin_type_ieee_double_little : builtin_type_ieee_single_little;
}
else if (reg == PS_REGNUM /* CR */)
return builtin_type_uint32;
next reply other threads:[~2002-08-21 0:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-08-20 17:13 Michael Snyder [this message]
2002-08-20 19:08 ` Andrew Cagney
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=200208202355.g7KNtsv00654@reddwarf.sfbay.redhat.com \
--to=msnyder@cygnus.com \
--cc=cagney@redhat.com \
--cc=gdb-patches@sources.redhat.com \
--cc=kevinb@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