Re: x86 - cpu_relax - why nop vs. pause?

Artur Skawina
2010-02-08T13:33:13Z

Michael Breuer wrote:
> Just to move away from this... totally perplexed, I retested a bit.
> Seems something else had gone wrong causing me to try 'rep;pause' vs.
> 'pause'. The resulting opcode is f3 f3 90, as noted above.
>
> I do see what seems to be a small but noticeable performance improvement
> - no idea if there's a downside, and also no idea what f3 f3 90 does vs.
> f3 90. Might be something interesting, or maybe not.

Alignment? IOW what happens if you use eg "nop; rep; nop;" or "rep; nop; nop;"?