Date: Tue, 7 Jul 2009 13:07:00 -0400 From: Justin Hibbits <jrh29@alumni.cwru.edu> To: Rafal Jaworowski <raj@semihalf.com> Cc: FreeBSD PowerPC ML <freebsd-ppc@freebsd.org> Subject: Re: FreeBSD/ppc ABI Message-ID: <fd9cd3450907071007l5501ea85y81bcb1ee8f4b8bdc@mail.gmail.com> In-Reply-To: <A07805D6-CAD5-4721-86AC-DE1751831D3C@semihalf.com> References: <fd9cd3450907070641l45223e72p5f7147b97fc5755f@mail.gmail.com> <A07805D6-CAD5-4721-86AC-DE1751831D3C@semihalf.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Thanks. The trick is only needed in user space, as a shim between two functions, so I just need any volatile registers that I can use but aren't function arguments. The target is G4/G5. I only need 3 or 4 volatile registers, but the more the better. - Justin On Tue, Jul 7, 2009 at 11:56 AM, Rafal Jaworowski<raj@semihalf.com> wrote: > > On 2009-07-07, at 15:41, Justin Hibbits wrote: > >> What's the current FreeBSD/ppc ABI register usage? =A0I'm writing a >> proxy function that messes with some arguments before making the >> target function call, and need to know which registers are free for me >> to use without having to save argument registers. =A0From reading the >> gcc source it looks like it's a strict SysV R4 ABI, leaving r0, r11, >> and r12 available for me to use. =A0Is this the case, and are there any >> others available? > > We use the plain SVR4 ABI. My understanding is R0, R11 and R12 are among > volatile group, so you should be careful. Can you use one of the SPRGs (w= hat > CPU is this, do you need to do the trick in user or supervisor mode)? > > Rafal > >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?fd9cd3450907071007l5501ea85y81bcb1ee8f4b8bdc>