Re: rep instruction without ecx's control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



#define spin_lock_string
\
"\n1:\t" \
"lock  ;  decb  %0\n\t" \
"jns  3f\n" \
"2:\t" \
"rep;nop\n\t" \
"cmpb  $0,%0\n\t" \
"jle  2b\n\t" \
"jmp  1b\n" \
"3:\n\t"

2010/8/20 Parmenides <mobile.parmenides@xxxxxxxxx>:
> Hi,
>
> In the following code, the nop instruction prefixed by rep will
> execute several times. How many times the instruction executes  is
> controlled by ecx register. But, there is no explicit setting of ecx
> register. What's the meaning of this instruction?
>

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ




[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux