Best ABI for stdarg/varargs ??
dewar@gnat.com
dewar@gnat.com
Fri Apr 6 17:14:00 GMT 2001
<<BTW, an out-of-the-ordinary thing I plan to do in this ABI is to grow
the stack from low to high addresses. The rationale is to keep
stack-saved frame chain and procedure linkage at lower addresses than
the current function's automatic variables, so that buffer overruns
can't clobber them.
>>
It is better to grow the stack up.
For most purposes it makes no difference
The one difference is that you can have one dynamic array whose base address
is at a fixed frame offset if you build up, which is not possible if you
build down (I never saw anyone note this interesting fact :-)
More information about the Gcc
mailing list