[Ffmpeg-devel] stdint.h and inttypes.h for non-C99 compilers
Fri Dec 15 04:11:52 CET 2006
On 15. December 2006 04:02, M?ns Rullg?rd wrote:
> Christian Iversen <chrivers at iversen-net.dk> writes:
> > On Wednesday 13 December 2006 12:56, M?ns Rullg?rd wrote:
> >> Alexander Chemeris said:
> >> > Why do you change this?
> >> > Is __cdecl is not enough?
> >> You're both wrong. The __cdecl modifier tells the compiler to use the
> >> standard C calling convention (the alternative being __stdcall for
> >> Pascal calling convention).
> > Just FYI, __stdcall is usually _not_ used in pascal. The calling
> > conventions that sane pascal compilers call "pascal" is a
> > register-based convention, that is much more efficient. The
> > corresponding pascal function attribute is "stdcall;"
> How do these Pascal compilers pass more arguments than will fit in
> registers? Who is responsible for restoring the stack, caller or
Extra arguments are passed on the stack as with stdcall, but since this
removed up to 3 arguments from the stack, it's a much better convention. (we
are talking x86 here, of course)
The stack is callee-cleared, and thus "register" is very much like (perhaps
identical to) Borland C++'s "__fastcall" modifier:
More information about the ffmpeg-devel