Passing function arguments in registers
Jeffrey A Law
law@cygnus.com
Tue Oct 14 15:11:00 GMT 1997
In message < 199710142047.JAA17466@ongaonga.chch.cri.nz >you write:
> Jeffrey A Law writes:
> > What exactly are the calling conventions for this target?
>
> The register allocation order is AR2, R2, R3, RC, RS, RE (then stack).
>
> However, the first and second floating point values are always in R2
> and R3 (and all other floats are on the stack). Structs are always
> passed on the stack.
So, say you want to pass int, int, int, float, float, int (A, B, C, D, E, F).
Do you pass them as:
AR2 = A
R2 = D
R3 = E
RC = B
RS = C
RE = F
?
Weird.
How does your target implement varargs & stdarg? I don't really see a
good way to correctly implement them if I understand the calling conventions
correctly.
jeff
More information about the Gcc
mailing list