#include"stdio.h"
int function(int a,int b)
{
int c=a+b;
if(c>0&&c<10)
{
printf("c>0");
}
else if(c>10&&c<100)
{
printf("c>10&&c<100");
}
else
{
printf("c>10&&c<100");
}
return c;
}
void main()
{
function(1,2);
}
--- c:\users\wangchao\desktop\test\test\main.cpp -------------------------------
#include "stdio.h"
int function(int a,int b)
{
00E12FE0 push ebp
00E12FE1 mov ebp,esp
00E12FE3 sub esp,0CCh
00E12FE9 push ebx
00E12FEA push esi
00E12FEB push edi
00E12FEC lea edi,[ebp-0CCh]
00E12FF2 mov ecx,33h
00E12FF7 mov eax,0CCCCCCCCh
00E12FFC rep stos dword ptr es:[edi]
int c=a+b;
00E12FFE mov eax,dword ptr [a]
00E13001 add eax,dword ptr [b]
00E13004 mov dword ptr [c],eax
if(c>0&&c<10)
00E13007 cmp dword ptr [c],0
00E1300B jle function+4Ch (0E1302Ch)
00E1300D cmp dword ptr [c],0Ah
00E13011 jge function+4Ch (0E1302Ch)
{
printf("c>0");
00E13013 mov esi,esp
00E13015 push offset string "c>0" (0E1573Ch)
00E1301A call dword ptr [__imp__printf (0E182B8h)]
00E13020 add esp,4
00E13023 cmp esi,esp
00E13025 call @ILT+315(__RTC_CheckEsp) (0E11140h)
00E1302A jmp function+88h (0E13068h)
}
else if(c>10&&c<100)
00E1302C cmp dword ptr [c],0Ah
00E13030 jle function+71h (0E13051h)
00E13032 cmp dword ptr [c],64h
00E13036 jge function+71h (0E13051h)
{
printf("c>10&&c<100");
00E13038 mov esi,esp
00E1303A push offset string "c>10&&c<100" (0E157A0h)
00E1303F call dword ptr [__imp__printf (0E182B8h)]
00E13045 add esp,4
00E13048 cmp esi,esp
00E1304A call @ILT+315(__RTC_CheckEsp) (0E11140h)
}
else
00E1304F jmp function+88h (0E13068h)
{
printf("c>10&&c<100");
00E13051 mov esi,esp
00E13053 push offset string "c>10&&c<100" (0E157A0h)
00E13058 call dword ptr [__imp__printf (0E182B8h)]
00E1305E add esp,4
00E13061 cmp esi,esp
00E13063 call @ILT+315(__RTC_CheckEsp) (0E11140h)
}
return c;
00E13068 mov eax,dword ptr [c]
}
00E1306B pop edi
00E1306C pop esi
00E1306D pop ebx
00E1306E add esp,0CCh
00E13074 cmp ebp,esp
00E13076 call @ILT+315(__RTC_CheckEsp) (0E11140h)
00E1307B mov esp,ebp
00E1307D pop ebp
00E1307E ret