From: Jason Low <jason.low2@hp.com>
To: Will Deacon <will.deacon@arm.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"mingo@redhat.com" <mingo@redhat.com>,
"paulmck@linux.vnet.ibm.com" <paulmck@linux.vnet.ibm.com>,
"Rudd, Terry (HP Cloud Systems Linux R&D)" <terry.rudd@hpe.com>,
"Long, Wai Man" <waiman.long@hpe.com>,
"boqun.feng@gmail.com" <boqun.feng@gmail.com>,
"dave@stgolabs.net" <dave@stgolabs.net>,
kbuild test robot <lkp@intel.com>,
"kbuild-all@01.org" <kbuild-all@01.org>,
jason.low2@hpe.com
Subject: Re: [PATCH v2] MCS spinlock: Use smp_cond_load_acquire()
Date: Wed, 13 Apr 2016 13:49:04 -0700 [thread overview]
Message-ID: <1460580544.2709.31.camel@j-VirtualBox> (raw)
In-Reply-To: <20160413174302.GC21722@arm.com>
On Wed, 2016-04-13 at 10:43 -0700, Will Deacon wrote:
> On Tue, Apr 12, 2016 at 08:02:17PM -0700, Jason Low wrote:
> > For qspinlocks on ARM64, we would like to use WFE instead
> > of purely spinning. Qspinlocks internally have lock
> > contenders spin on an MCS lock.
> >
> > Update arch_mcs_spin_lock_contended() such that it uses
> > the new smp_cond_load_acquire() so that ARM64 can also
> > override this spin loop with its own implementation using WFE.
> >
> > On x86, it can also cheaper to use this than spinning on
> > smp_load_acquire().
> >
> > Signed-off-by: Jason Low <jason.low2@hp.com>
>
> FWIW, we just override arch_mcs_spin_lock_contended entirely for arch/arm/
> and use wfe there so we could do the same for arm64 in mainline already.
Right, I was also thinking about that, although when we use
smp_cond_load_acquire() in the generic implementation, would we just end
up overriding it for the arch/arm64 version with the same thing? :)
Jason
next prev parent reply other threads:[~2016-04-13 20:54 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-13 3:02 [PATCH v2] MCS spinlock: Use smp_cond_load_acquire() Jason Low
2016-04-13 17:43 ` Will Deacon
2016-04-13 20:49 ` Jason Low [this message]
2016-04-14 8:53 ` Will Deacon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1460580544.2709.31.camel@j-VirtualBox \
--to=jason.low2@hp.com \
--cc=boqun.feng@gmail.com \
--cc=dave@stgolabs.net \
--cc=jason.low2@hpe.com \
--cc=kbuild-all@01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
--cc=mingo@redhat.com \
--cc=paulmck@linux.vnet.ibm.com \
--cc=peterz@infradead.org \
--cc=terry.rudd@hpe.com \
--cc=torvalds@linux-foundation.org \
--cc=waiman.long@hpe.com \
--cc=will.deacon@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox