Re: [RFC PATCH-tip v2 2/6] locking/rwsem: Stop active read lock ASAP

2016-06-16 Thread Waiman Long
On 06/15/2016 10:14 PM, Davidlohr Bueso wrote: On Wed, 15 Jun 2016, Waiman Long wrote: I think there will be a little bit of performance impact for a workload that produce just the right amount of rwsem contentions. I'm not saying the change doesn't make sense, but this is the sort of thing

Re: [RFC PATCH-tip v2 2/6] locking/rwsem: Stop active read lock ASAP

2016-06-15 Thread Davidlohr Bueso
On Wed, 15 Jun 2016, Waiman Long wrote: I think there will be a little bit of performance impact for a workload that produce just the right amount of rwsem contentions. I'm not saying the change doesn't make sense, but this is the sort of thing that will show nice numbers in one workload and

Re: [RFC PATCH-tip v2 2/6] locking/rwsem: Stop active read lock ASAP

2016-06-15 Thread Waiman Long
On 06/15/2016 01:22 PM, Peter Zijlstra wrote: On Tue, Jun 14, 2016 at 06:48:05PM -0400, Waiman Long wrote: Currently, when down_read() fails, the active read locking isn't undone until the rwsem_down_read_failed() function grabs the wait_lock. If the wait_lock is contended, it may takes a while

Re: [RFC PATCH-tip v2 2/6] locking/rwsem: Stop active read lock ASAP

2016-06-15 Thread Peter Zijlstra
On Tue, Jun 14, 2016 at 06:48:05PM -0400, Waiman Long wrote: > Currently, when down_read() fails, the active read locking isn't undone > until the rwsem_down_read_failed() function grabs the wait_lock. If the > wait_lock is contended, it may takes a while to get the lock. During > that period, writ

[RFC PATCH-tip v2 2/6] locking/rwsem: Stop active read lock ASAP

2016-06-14 Thread Waiman Long
Currently, when down_read() fails, the active read locking isn't undone until the rwsem_down_read_failed() function grabs the wait_lock. If the wait_lock is contended, it may takes a while to get the lock. During that period, writer lock stealing will be disabled because of the active read lock. T