This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: stack pointer adjustment problem
- To: Mark Probst <schani at mips dot complang dot tuwien dot ac dot at>
- Subject: Re: stack pointer adjustment problem
- From: Geert Bosch <bosch at gnat dot com>
- Date: Sun, 25 Feb 2001 21:43:57 -0500 (EST)
- Cc: gcc at gcc dot gnu dot org
On Mon, 26 Feb 2001, Mark Probst wrote:
|the reason i want to do such a thing is this: i've been working on
|implementing proper tail calls. to this end i had to implement a new
|calling convention in which the callee pops the arguments. on most
|risc machines, like the alpha, space for outgoing arguments is
|allocated in the prologue of the caller. now, if a function with the
|new calling convention is called (without the call being a proper tail
|call), the stack pointer is modified when the function returns. this
|modification (the popping of the arguments by the callee) has to be
|reverted.
I'm not quite sure what you want, but you might want to look at
what is done for TYPE_RETURNS_STACK_DEPRESSED, which is needed
for implementing alloca-like calls that need to leave variable-sized
arguments on that stack while returning.
-Geert