Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@mvista.com>
To: Michael Snyder <msnyder@redhat.com>
Cc: Andrew Cagney <ac131313@ges.redhat.com>,
	Michael Snyder <msnyder@cygnus.com>,
	gdb-patches@sources.redhat.com
Subject: Re: [PATCH] mips_extract_struct_return_value: use saved regcache
Date: Tue, 10 Sep 2002 13:43:00 -0000	[thread overview]
Message-ID: <20020910204402.GA4450@nevyn.them.org> (raw)
In-Reply-To: <3D7E5141.61481190@redhat.com>

On Tue, Sep 10, 2002 at 01:08:33PM -0700, Michael Snyder wrote:
> Andrew Cagney wrote:
> > 
> > > ! mips_extract_struct_value_address (struct regcache *regcache)
> > >   {
> > >     /* FIXME: This will only work at random.  The caller passes the
> > >        struct_return address in V0, but it is not preserved.  It may
> > >        still be there, or this may be a random value.  */
> > > !   CORE_ADDR val;
> > > !   regcache_cooked_read_unsigned (regcache, V0_REGNUM, &val);
> > > !   return val;
> > >   }
> > 
> > FYI,
> > 
> > This should be regcache_cooked_read_signed() so that the address is sign
> > extended. 
> 
> Are you sure?  Arm, i386, and cris all use unsigned. 
> I just copied them.

Yes, Andrew's right - this is a quirk of MIPS.

> > I think val should also be a LONGEST.
> 
> OK, will change.
> 

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


  reply	other threads:[~2002-09-10 20:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-09-05 11:30 Michael Snyder
2002-09-09 21:11 ` Andrew Cagney
2002-09-10 13:08   ` Michael Snyder
2002-09-10 13:43     ` Daniel Jacobowitz [this message]
2002-09-10 14:26       ` Michael Snyder

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=20020910204402.GA4450@nevyn.them.org \
    --to=drow@mvista.com \
    --cc=ac131313@ges.redhat.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=msnyder@cygnus.com \
    --cc=msnyder@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