site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com On 03 Nov 2006, at 21:19, Uli Kusterer wrote: _main: pushl %ebp movl %esp, %ebp subl $40, %esp ### HERE movl $7, 4(%esp) movl $5, (%esp) call _addNumbers movl %eax, -12(%ebp) movl -12(%ebp), %eax leave ret .subsections_via_symbols Jonas _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... I would have expected that to be maybe 8 bytes for the parameters, and since the stack according to all docs I could find is 4-byte aligned, You found the wrong docs, it's 16 byte aligned. See http://developer.apple.com/documentation/DeveloperTools/Conceptual/ LowLevelABI/Articles/IA32.html It also contains all information regarding how parameters are passed and how function results are returned. that would be 8. Instead it's 40. Without the corresponding C code, it's hard to say why exactly the compiler is doing that. This email sent to site_archiver@lists.apple.com
participants (1)
-
Jonas Maebe