[GCC 4.x][AMD64 ABI] variadic function

2005-08-23 Thread Matteo Emanuele
Hi to everyone,
 I cannot figure out how variadic function are
practically implemented. In the called (variadic)
function after few 'push's %rsp is suddenly
decremented by N bytes: the red area starts 128 bytes
below the NEW rsp or %rsp-N above?
Is it possible to  find the register save area and the
overflowing arguments within the called function
without using %ebp (that means with
-fomit-frame-pointer set) and knowing nothing of the
caller?
The -so called- spill reg area is placed at fixed
address?
Thanx in advance,
 Matteo




Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 
 


ABI64 and register save area

2008-03-25 Thread Matteo Emanuele
Hi,
 I that hope this is the right place for this kind of
questions!
However my question is rather simple: knowing the
AMD64 ABI, is it possible to implement your own
flavour of the va_xxx macros?
If I compile _without_ -fomit-frame-pointer I'm able
to retrieve the arguments pushed on the stack, but I'm
not able to point correctly the register save area. Is
this area placed at fixed position like the red zone?
If not how I can find it (if possible)?
Thanks for the time spent reading,
 Matteo


  Inviato da Yahoo! Mail. 
Tanti modi per restare in contatto con chi vuoi.
http://it.docs.yahoo.com/mail/overview/index.html