Why ML always use LEAVE but not ENTER?

DISCLAIMER : this joke is not for the non-geek or the faint-hearted. You’ve been warned.

Q: In every proc, the stack frame is created by PUSH EBP and MOV EBP,ESP instead of ENTER. Why is this?

00405910  /.  55            PUSH EBP
00405911  |.  8BEC         MOV EBP,ESP
00405913  |.  56            PUSH ESI
00405914  |.  57            PUSH EDI                                ;  ntdll.7C910738
00405915  |.  5F            POP EDI                                  ;  kernel32.7C816D4F
00405916  |.  5E            POP ESI                                  ;  kernel32.7C816D4F
00405917  |.  C9            LEAVE
00405918  \.  C2 0800     RETN 8

A: The uP is female.  You always enter slowly, leave as quickly as possible.

Whatever that means …:mrgreen:

Link

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s