Re: [RFC][PATCH 31/31] locking,qrwlock: Employ atomic_fetch_add_acquire()

2016-04-22 Thread Waiman Long
On 04/22/2016 05:04 AM, Peter Zijlstra wrote: The only reason for the current code is to make GCC emit only the "LOCK XADD" instruction on x86 (and not do a pointless extra ADD on the result), do so nicer. Signed-off-by: Peter Zijlstra (Intel) --- kernel/locking/qrwlock.c |2 +- 1 file ch

[RFC][PATCH 31/31] locking,qrwlock: Employ atomic_fetch_add_acquire()

2016-04-22 Thread Peter Zijlstra
The only reason for the current code is to make GCC emit only the "LOCK XADD" instruction on x86 (and not do a pointless extra ADD on the result), do so nicer. Signed-off-by: Peter Zijlstra (Intel) --- kernel/locking/qrwlock.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/kerne