> As a NOP instruction is supposed to do nothing, would this then be wrong?
> (Nothing meaning not setting any flags?)
>
> Hmmm... Where's the time from the good ol' Z80 when you HAD a real NOP
> instruction? *Sigh* :-)
The x86 has a real nop instruction. The point of using other
NOP forms is that the x86 NOP is one byte, and takes a fixed
time to execute. Now, if we happen to need 6 byte of filling
then 6 NOP's take 6 times the time to execute. Putting a
single 6-byte do-nothing instruction there instead will be faster.
A good compiler will use the fastest NOP form available
for the gap to be filled. x86 instructions have sizes
varying from 1 to 15 bytes.
Helge Hafting
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/