Re: [RFC PATCH 1/3] x86,smp: move waiting on contended lock out of line

2012-12-23 Thread Rafael Aquini
On Fri, Dec 21, 2012 at 06:50:38PM -0500, Rik van Riel wrote: > Subject: x86,smp: move waiting on contended ticket lock out of line > > Moving the wait loop for congested loops to its own function allows > us to add things to that wait loop, without growing the size of the > kernel text appreciabl

Re: [RFC PATCH 1/3] x86,smp: move waiting on contended lock out of line

2012-12-21 Thread Rik van Riel
On 12/21/2012 11:40 PM, Michel Lespinasse wrote: On Fri, Dec 21, 2012 at 3:50 PM, Rik van Riel wrote: @@ -53,12 +55,11 @@ static __always_inline void __ticket_spin_lock(arch_spinlock_t *lock) inc = xadd(&lock->tickets, inc); + if (inc.head == inc.tail) + goto

Re: [RFC PATCH 1/3] x86,smp: move waiting on contended lock out of line

2012-12-21 Thread Michel Lespinasse
On Fri, Dec 21, 2012 at 3:50 PM, Rik van Riel wrote: > diff --git a/arch/x86/include/asm/spinlock.h b/arch/x86/include/asm/spinlock.h > index 33692ea..2a45eb0 100644 > --- a/arch/x86/include/asm/spinlock.h > +++ b/arch/x86/include/asm/spinlock.h > @@ -34,6 +34,8 @@ > # define UNLOCK_LOCK_PREFIX >

Re: [RFC PATCH 1/3] x86,smp: move waiting on contended lock out of line

2012-12-21 Thread Steven Rostedt
On Fri, Dec 21, 2012 at 06:50:38PM -0500, Rik van Riel wrote: > Subject: x86,smp: move waiting on contended ticket lock out of line > > Moving the wait loop for congested loops to its own function allows > us to add things to that wait loop, without growing the size of the > kernel text appreciabl