Hello,
By using volatile keyword for spin lock defined by in spinlock_t, it seems
Linux choose to always
reload the value of spin locks from cache instead of using the content from
registers. This may be
helpful for synchronization between multithreads in a single CPU.
I use two Xeon cpus wit
Hi Willy,
I think at least I can remove the LOCK instruction when the lock is already
held by someone else and enter the spinning wait directly, right?
0: cmpb $0, slp
jle 2f# lock is not available, then spinning
directly without locking the bus
1: lock; decb slp
2 matches
Mail list logo