This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Calling functions on x86
- From: <patriciak784-gccmainling at yahoo dot de>
- To: gcc at gcc dot gnu dot org
- Date: Tue, 20 Sep 2005 13:14:45 +0200 (CEST)
- Subject: Calling functions on x86
- Reply-to: patriciak784-gccmainling at yahoo dot de
On x86 and GCC 3.4.2, the resulting asm code when
leaving a stackframe is (in intel_syntax)
mov esp,ebp
pop ebp
.(results in 0x89EC5D or 0x8BE55D)
The AMD optimisation guide for AMD64 tells you not to
use mov esp, ebp - pop ebp but to use "leave"(just
0xC9)!
Perhaps using "enter x(16bit), imm8" is better than
"push ebp - mov ebp, esp - sub esp, x"
I hope you can improve performance with these optimisations.
___________________________________________________________
Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de