NASM - The Netwide Assembler
NASM Forum => Using NASM => Topic started by: nobody on April 05, 2008, 03:31:41 AM
-
Dear list,
I have a newbie question. When I deassembled a executable file under MAC intel, I encountered following jmp instruction:
00003118 7453 je 0x0000316d
Here, the opcode 74 seems correspond to je, and 53 is a relative address. Then I tried to assemble "je 0x53" using nasm, which produced a output like:
0f 84 4f 00
which is not 74 53 any more.
So my question is where these two instructions are not the same. Thanks!
-
> So my question is where these two instructions are not the same.
SHORT vs NEAR jump ;-)
74 53 -> je short $ + $53 , 8086 compatible
0f 84 4f 00 -> je near $ + $4F - requires 80386 , inefficient encoding !!!
You should care about your "org" and jump target ;-)
> Then I tried to assemble "je 0x53"
Bad idea to specify an absolute address :-(