Re: [PATCH] locking/qspinlock: Use this_cpu_ptr instead of this_cpu_dec
From: Peter Zijlstra
Date: Fri Jun 03 2016 - 07:37:15 EST
On Fri, Jun 03, 2016 at 05:48:50PM +0800, Pan Xinhui wrote:
> queued_spin_lock_slowpath should not worry about interrupt change
> node->count by accident because ->count is inc and dec when we
> enter/leave queued_spin_lock_slowpath.
> So this_cpu_dec() does some no point things here, lets use this_cpu_ptr
> for a small optimization.
Uhm, have you actually looked at what that does on x86?