From: Daniel Jacobowitz <drow@false.org>
To: Andrew Cagney <cagney@gnu.org>
Cc: Chris Zankel <zankel@tensilica.com>, gdb@sources.redhat.com
Subject: Re: Extract the return value in finish_command on Xtensa.
Date: Thu, 15 Jul 2004 14:42:00 -0000 [thread overview]
Message-ID: <20040715143542.GA4966@nevyn.them.org> (raw)
In-Reply-To: <40F692F3.1060302@gnu.org>
On Thu, Jul 15, 2004 at 10:21:39AM -0400, Andrew Cagney wrote:
> >On Wed, Jul 14, 2004 at 03:38:34PM -0400, Andrew Cagney wrote:
> >
> >>>>>I am working on a port of GDB to the Xtensa architecture.
> >>>>>
> >>>>>Unfortunately, it is impossible on Xtensa to extract the return value
> >>>>once >the 'callee' has returned to the 'caller' without analyzing the
> >>>>call >instruction (if there was one). Depending on the call
> >>>>instruction, the >return value can be in register a6, a10, oder a14.
> >>
> >>>
> >>>Puzzled expression. The ABI should specify which return-value
> >>>convention will be used?
> >>>
> >>>I suspect you'll need to explain a little more about your architecture.
> >
> >
> >Xtensa has register windows. The call instruction determines how far
> >the window shifts; the return value is always going to be in some fixed
> >register (a0?) at the end of the function, but the caller has to choose
> >which call instruction to use and expect the return value in the
> >correct location based on that.
>
> Keep going :-) For instance, what logic determines the shift amount
> (the insn just reflects that decision), and how does the mechanism
> compare to ia64 and SPARC?
That I'll have to leave to Chris :-) I don't know. SPARC only has
fixed size windows; I have labored hard and long not to know anything
about ia64.
--
Daniel Jacobowitz
next prev parent reply other threads:[~2004-07-15 14:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-12 23:38 Chris Zankel
2004-07-14 19:40 ` Andrew Cagney
2004-07-14 20:37 ` Daniel Jacobowitz
2004-07-15 14:36 ` Andrew Cagney
2004-07-15 14:42 ` Daniel Jacobowitz [this message]
2004-07-15 17:58 ` Chris Zankel
2004-07-18 21:49 ` 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=20040715143542.GA4966@nevyn.them.org \
--to=drow@false.org \
--cc=cagney@gnu.org \
--cc=gdb@sources.redhat.com \
--cc=zankel@tensilica.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