[PATCH] ARM: Add SWP/SWPB emulation for ARMv7 processors

Jamie Lokier jamie at shareable.org
Fri Dec 18 15:31:54 EST 2009


Woodruff, Richard wrote:
> 
> > From: Jamie Lokier [mailto:jamie at shareable.org]
> > Sent: Thursday, December 17, 2009 1:16 PM
> 
> > Woodruff, Richard wrote:
> > > Exclusive operations are more certainly more efficient than the full
> > > bus lock behavior of SWP.  Finding and killing SWP where possible
> > > seems positive.
> >
> > Are they really more efficient for cached accesses in L1?  In
> > principle, external bus lock is not needed when doing an
> > read-modify-write on words in MESI cache, just the ability to
> > internally block it's eviction during the sequence.
> 
> Performance point was mainly about coordination with non-coherent
> external masters (outside of cluster).  Blocking all external people
> for a small range is not optimal.

Sure, but doesn't your patch break any program which tries to do
that, due to the lack of LDREX/STREX global monitor reaching to
external masters, so that case isn't relevant?

So (correct me if I'm wrong) the interesting case is only about
accesses within the cluster.  Is that really slower with SWP/SWPB?

-- Jamie



More information about the linux-arm-kernel mailing list