lkml.org 
[lkml]   [2011]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 13/15] x86: add cmpxchg_flag() variant
On 08/24/2011 01:31 PM, H. Peter Anvin wrote:
> The sete is actually more expensive than the compare for the single-word
> case. The double-word case is a different matter.

Hm, setcc has a longer latency but a higher throughput, is that
correct? Still, its recommended where you can use it to avoid a branch.

I was also thinking that using it reduces register pressure, since you
don't need to keep the "old" value around, so it dies sooner.

J


\
 
 \ /
  Last update: 2011-08-25 00:35    [W:0.086 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site