This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Coldfire __lll_lock fails under heavy system stress


On Thu, 1 Nov 2012, Ed Slas wrote:

> Thanks for your time. I understand the kernel's atomic_cmpxchg_32() is 
> most likely the issue, but note that most of the other platforms use a 
> atomic lock in user space, then resort to the kernel to arbitrate 
> contentions. The Coldfire port makes the?atomic_cmpxchg_32 kernel call 
> first, when there is a user space atomic lock available (TAS 
> instruction).

I don't believe TAS is sufficient to implement a general 
compare-and-exchange operation, such as is expected by NPTL.  The syscall 
is used because the ColdFire architecture has neither an atomic 
compare-and-exchange instruction, nor load-locked / store-conditional that 
are used on some other architectures to implement compare-and-exchange in 
userspace.

-- 
Joseph S. Myers
joseph@codesourcery.com

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]