lkml.org 
[lkml]   [2011]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 00/18] x86: Ticket lock + cmpxchg cleanup
On 08/24/2011 04:05 PM, H. Peter Anvin wrote:
> On 08/24/2011 03:59 PM, Jeremy Fitzhardinge wrote:
>> On 08/24/2011 03:53 PM, Linus Torvalds wrote:
>>> On Wed, Aug 24, 2011 at 1:10 PM, Jeremy Fitzhardinge <jeremy@goop.org> wrote:
>>>> Could we just kill SMP support for OOSTORE machines now? That would be
>>>> the cleanest possible fix...
>>> No it wouldn't. The asm version would *still* be cleaner than the "C
>>> plus random barriers".
>>>
>>> It's not like the C version is "portable" in any case.
>> If there's no need to have a locked instruction, then it could simply be:
>>
>> barrier();
>> lock->head++;
>> barrier();
>>
>> with no need for asm at all.
>>
> That's not guaranteed in any way to generate a locally atomic instruction.

Doesn't need to be. The final write needs to be locally atomic, but we
assume that a lot.

J


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