linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Gary Thomas <gdt@linuxppc.org>
To: VALETTE Eric <valette@crf.canon.fr>
Cc: linuxppc-dev@lists.linuxppc.org, alois_fertl@muenchen.europe.mcd.mot.com
Subject: Re: PPC Compiler Problem?
Date: Wed, 01 Dec 1999 10:50:13 -0700 (MST)	[thread overview]
Message-ID: <XFMail.991201105013.gdt@linuxppc.org> (raw)
In-Reply-To: <m11tCut-0000WVC@tri-yann.crf.canon.fr>



On 01-Dec-99 VALETTE Eric wrote:
> 
>>>>>> "Alois" == Alois Fertl <alois_fertl@muenchen.europe.mcd.mot.com> writes:
> 
> Alois> Given the following lines of C, I'd expect that the 4th argument
> Alois> is placed into register 6 and 7. As the assembler listing tells,
> Alois> register 6 is omitted and the argument goes into r7/r8.
> 
> I indeed checked the "PowerPC Processor ABI Supplement" dated September 95
> (SVR4 PowerPC ABI) and on 3-18 I see :
> 
> For PowerPC, up to eight words are passed in general purpose registers, loaded
> sequentially into general purpose registers r3 through r10.
> 
> It is clear that this breaks the SVR4 ABI... So you can probably open a bug
> report...
> 

If you read carefully, on page 3-18 of the SYSV ABI report, for a long long
argument being placed in register 'gr':
  " if gr is even, set gr to gr+1.  Load the lower addressed word into gr and
    the higher addressed word into gr+1."

Thus, the implementation _is_ correct.  long long arguments always occupy
an odd/even pair of registers.


------------------------------------------------------------------------
Gary Thomas                              |
email: gdt@linuxppc.org                  | "Fine wine is a necessity of
   ... opinions expressed here are mine  |        life for me"
       and no one else would claim them! |
                                         |      Thomas Jefferson
------------------------------------------------------------------------


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

  reply	other threads:[~1999-12-01 17:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-01 16:11 PPC Compiler Problem? Alois Fertl
1999-12-01 16:27 ` Kevin Hendricks
1999-12-01 16:32 ` Gabriel Paubert
1999-12-01 16:47 ` VALETTE Eric
1999-12-01 17:50   ` Gary Thomas [this message]
1999-12-01 17:56     ` VALETTE Eric
1999-12-01 21:59       ` Tony Mantler

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=XFMail.991201105013.gdt@linuxppc.org \
    --to=gdt@linuxppc.org \
    --cc=alois_fertl@muenchen.europe.mcd.mot.com \
    --cc=linuxppc-dev@lists.linuxppc.org \
    --cc=valette@crf.canon.fr \
    /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;
as well as URLs for NNTP newsgroup(s).