This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: What happens on the stack when calling a function? (gcc-3.4.3)


> Hi folks!
> 
> I stumbled across some strange stuff on the stack when calling a
> function with gcc-3.4.3.

There was similar discusion maybe month ago.
GCC just tries to align everything to 16 bytes boundary(this
optimization is very "cheap" by the way), but if you need exact
behavior then you should use -mpreferred-stack-boundary, more info
you'll find:
http://gcc.gnu.org/onlinedocs/gcc-3.4.3/gcc/i386-and-x86_002d64-Options.html
(-mpreferred-stack-boundary)


Arturas Moskvinas


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]