[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180704115331.GA26941@arm.com>
Date: Wed, 4 Jul 2018 12:53:31 +0100
From: Will Deacon <will.deacon@....com>
To: Alan Stern <stern@...land.harvard.edu>
Cc: LKMM Maintainers -- Akira Yokosawa <akiyks@...il.com>,
Andrea Parri <andrea.parri@...rulasolutions.com>,
Boqun Feng <boqun.feng@...il.com>,
David Howells <dhowells@...hat.com>,
Jade Alglave <j.alglave@....ac.uk>,
Luc Maranget <luc.maranget@...ia.fr>,
Nicholas Piggin <npiggin@...il.com>,
"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
Peter Zijlstra <peterz@...radead.org>,
Kernel development list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/2] tools/memory-model: Add write ordering by
release-acquire and by locks
Hi Alan,
On Fri, Jun 22, 2018 at 03:11:37PM -0400, Alan Stern wrote:
> On Fri, 22 Jun 2018, Will Deacon wrote:
> > On Fri, Jun 22, 2018 at 02:09:04PM -0400, Alan Stern wrote:
> > > On Fri, 22 Jun 2018, Will Deacon wrote:
> > > > Could we drop the acquire/release stuff from the patch and limit this change
> > > > to locking instead?
> > >
> > > The LKMM uses the same CAT code for acquire/release and lock/unlock.
> > > (In essence, it considers a lock to be an acquire and an unlock to be a
> > > release; everything else follows from that.) Treating one differently
> > > from the other in these tests would require some significant changes.
> > > It wouldn't be easy.
> >
> > It would be boring if it was easy ;) I think this is a case of the tail
> > wagging the dog.
> >
> > Paul -- please can you drop this patch until we've resolved this discussion?
>
> Agreed. It sounds like we'll need two versions of the Rel and Acq sets
> in the memory model; one for RCpc and one for RCsc. smp_load_acquire
> and smp_store_release will use the former, and locking will use the
> latter.
>
> Would it suffice to have this duplication just for release, using a
> single version of acquire? What would happen on ARMv8 or RISC-V if an
> RCsc release was read by an RCpc acquire? Or vice versa?
On Arm, RCsc release can forward to an RCpc acquire. We don't have an RCpc
release instruction.
Will
Powered by blists - more mailing lists