[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v2] arm: reduce power use by contented spin locks with WFE/SEV



On Mon, 2015-08-03 at 12:51 +0100, Stefano Stabellini wrote:
> On Mon, 3 Aug 2015, Ian Campbell wrote:
> > From: David Vrabel <david.vrabel@xxxxxxxxxx>
> > 
> > Instead of cpu_relax() while spinning and observing the ticket head,
> > introduce arch_lock_relax() which executes a WFE instruction.  After
> > the ticket head is changed call arch_lock_signal() to execute an SEV
> > instruction (with the required DSB first) to wake any spinners.
> > 
> > This should improve power consumption when locks are contented and
> > spinning.
> > 
> > For consistency also move arch_lock_(acquire|release)_barrier to
> > asm/spinlock.h.
> > 
> > Booted the result on arm32 (Midway) and arm64 (Mustang). Build test
> > only on amd64.
> > 
> > Signed-off-by: David Vrabel <david.vrabel@xxxxxxxxxx>
> > [ijc: add barrier, rename as arch_lock_*, move arch_lock_*_barrier, 
> > test]
> > Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
> > Cc: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
> > Cc: Jan Beulich <jbeulich@xxxxxxxx>
> > Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
> 
> I don't know why you are moving arch_lock_(acquire|release)_barrier to
> spinlock.h as part of this patch,

It's literally explained two paragraphs above... "For consistency", i.e. to
put arch_lock_* in the same place.



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.