C语言编译成汇编语言后,放大的两句作用是什么?
C语言编译成汇编语言后,放大的两句作用是什么?1: #include "stdio.h"
2: int main()
3: {
00401010 push ebp
00401011 mov ebp,esp
00401013 sub esp,40h
00401016 push ebx
00401017 push esi
00401018 push edi
00401019 lea edi,
0040101C mov ecx,10h
00401021 mov eax,0CCCCCCCCh
00401026 rep stos dword ptr
4: printf("This is a C program\n");
00401028 push offset string "This is a C program\n" (0042201c)
0040102D call printf (00401060)
00401032 add esp,4
5: return 0;
00401035 xor eax,eax
6: }
00401037 pop edi
00401038 pop esi
00401039 pop ebx
0040103A add esp,40h
0040103D cmp ebp,esp
0040103F call __chkesp (004010e0)
00401044 mov esp,ebp
00401046 pop ebp
00401047 ret 就是进行了一个cmp比较,然后调用了__chkesp()堆栈检查函数。
页:
[1]