ppc405gp and GCC register usage

Wolfgang Denk wd at denx.de
Tue Jul 15 20:40:54 EST 2003


In message <200307151224.04020.jbeisert at eurodsn.de> you wrote:
>
> does someone know, which register I can use in my own assembler routines
> without disturbing code generated by gcc (in kernel space)? I did not found
> any spec which registers gcc use, yet. Is such a document available?

See the (E)ABI specifications for the PowerPC architecture,  and  GCC
source code.

For PowerPC, the following registers have specific use:

	R1:	stack pointer
	R2:	TOC pointer
	R3-R4:	parameter passing and return values
	R5-R10:	parameter passing
	R13:	small data area pointer
	R30:	GOT pointer
	R31:	frame pointer



Best regards,

Wolfgang Denk

--
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Life would be so much easier if we could  just  look  at  the  source
code.                                                   -- Dave Olson

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





More information about the Linuxppc-embedded mailing list