home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.asm.x86      Ahh, the lost art of x86 assembly      4,675 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 3,787 of 4,675   
   src153 to nowhere@nospicedham.never.at   
   Re: inc ax, MASM 5.1   
   15 Feb 19 22:33:24   
   
   From: src153@nospicedham.protocol.invalid   
      
   On Fri, 15 Feb 2019 22:57:04 +0100, wolfgang kern   
    wrote:   
      
   >On 15.02.2019 18:25, src153 wrote:   
   >> I have a disassembly where   
   >>   
   >>      FF C0 --> inc ax   
   >>   
   >> but when I reassemble the source I get   
   >>   
   >>      inc ax --> 40   
   >>   
   >> Is there a reason to prefer the two byte translation? Can MASM 5.1 do   
   >> that, without forcing DB in the middle of code?   
   >   
   >the '40' become a REX-prefix within 64-bit long-mode, so the two byte   
   >variant is the only choice, while 16 and 32-bit modes can use single   
   >byte inc/dec.   
      
   The object code is from a 1993 DOS program. No 64 bit. I just wondered   
   if there is a way to make MASM 5.1 produce that code, or if they forced   
   it in with DB.   
      
   And why? For anti reverse engineering? Or was it maybe a compiler other   
   than MASM 5.1 used for an out-of-tree object build?   
      
   Not a big problem, I worked around it. Just wondering.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca