What is faster: JMP or string of NOPs?
I'm implementing binary translation and have to deal with sequences of NOPs (0x90) with length about 16 opcodes. Is it better for performance to place JMP (to the end) at start of such sequences? The Intel Architecture Software developer's guide, volume 2B (instructions N-Z) contains the following table (pg 4-12) about NOP : Table 4-9. Recommended Multi-Byte Sequence of NOP Instruction Length Assembly Byte Sequence ================================================================================= 2 bytes 66 NOP 66 90H 3 bytes NOP DWORD ptr [EAX] 0F 1F 00H 4 bytes NOP DWORD ptr [EAX + 00H] 0F 1F