On 06/15/2018 06:46 PM, Peter Zijlstra wrote:
On Fri, Jun 15, 2018 at 02:08:27PM +0200, Thomas Hellstrom wrote:
@@ -772,6 +856,25 @@ __ww_mutex_add_waiter(struct mutex_waiter *waiter,
}
list_add_tail(&waiter->list, pos);
+ if (__mutex_waiter_is_first(lock, waiter))
+
On Fri, Jun 15, 2018 at 02:08:27PM +0200, Thomas Hellstrom wrote:
> @@ -772,6 +856,25 @@ __ww_mutex_add_waiter(struct mutex_waiter *waiter,
> }
>
> list_add_tail(&waiter->list, pos);
> + if (__mutex_waiter_is_first(lock, waiter))
> + __mutex_set_flag(lock, MUTEX_FLAG_
The current Wound-Wait mutex algorithm is actually not Wound-Wait but
Wait-Die. Implement also Wound-Wait as a per-ww-class choice. Wound-Wait
is, contrary to Wait-Die a preemptive algorithm and is known to generate
fewer backoffs. Testing reveals that this is true if the
number of simultaneous con