[lkml]   [1998]   [Dec]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: NOP instruction
On Wed, Dec 16, 1998 at 11:36:00AM +1030, Mofeed Shahin wrote:

> Ummm, I was under the impression that NOP under the intel was 0x90...


> I am pretty sure the intel does have a real NOP.

don't think so:

[me:1] caffeine:~$ cat nop.S

_start: .globl _start

xchg %eax,%eax

movl $0x01,%eax
movl $0x00,%ebx
int $0x80
[me:1] caffeine:~$ as -Qy -o nop.o nop.S
[me:1] caffeine:~$ objdump -d -S nop.o

nop.o: file format elf32-i386

Disassembly of section .text:

00000000 <_start>:
0: 90 nop
1: 0f a2 cpuid
3: 90 nop
4: b8 01 00 00 00 movl $0x1,%eax
9: bb 00 00 00 00 movl $0x0,%ebx
e: cd 80 int $0x80

As you can see -- gas treats nop as xchg %eax,%eax.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:46    [W:0.070 / U:7.448 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site