VS中的不稳定行为

时间:2012-07-05 11:03:03

标签: c++ visual-studio-2005 disassembly

if(!base_initialized())return;  

    if(strcmp(fname,name) != 0)
    {
        -->std::string strentry;

        std::stringstream ss;   

当我在 - >行上设置断点时有一个不稳定的行为,当我按下F10时,它不会进入下一行,它只是走出街区..

反汇编对我来说也很奇怪......就像这样。

if(!base_initialized())return;  

    if(strcmp(fname,name) != 0)
    {
        -->>std::string strentry;
004013F0  mov         dword ptr [esp+0Ch],ebx 
004013F4  call        dword ptr [__imp_base_initialized (4071BCh)] 
004013FA  test        eax,eax 
004013FC  je          writetohashset+2C1h (401671h) 
00401402  mov         ecx,ebx 
00401404  mov         eax,esi 
00401406  mov         dl,byte ptr [eax] 
00401408  cmp         dl,byte ptr [ecx] 
0040140A  jne         writetohashset+76h (401426h) 
    if(!base_initialized())return;  

    if(strcmp(fname,name) != 0)
0040140C  test        dl,dl 
0040140E  je          writetohashset+72h (401422h) 
00401410  mov         dl,byte ptr [eax+1] 
00401413  cmp         dl,byte ptr [ecx+1] 
00401416  jne         writetohashset+76h (401426h) 
00401418  add         eax,2 
0040141B  add         ecx,2 
0040141E  test        dl,dl 
00401420  jne         writetohashset+56h (401406h) 
00401422  xor         eax,eax 
00401424  jmp         writetohashset+7Bh (40142Bh) 
00401426  sbb         eax,eax 
00401428  sbb         eax,0FFFFFFFFh 
0040142B  test        eax,eax 
0040142D  je          writetohashset+2C1h (401671h) 
    {
        -->>std::string strentry;
00401433  lea         ecx,[esp+0B4h] 
0040143A  call        dword ptr [__imp_std::basic_string<char,std::char_traits<char>,std::allocator<char> >::basic_string<char,std::char_traits<char>,std::allocator<char> > (407084h)] 

        std::stringstream ss;   

注意带箭头的两行。同一事物有多种定义。

0 个答案:

没有答案