Re: [tip:locking/core] tools/memory-model: Add extra ordering for locks and remove it for ordinary release/acquire
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: Re: [tip:locking/core] tools/memory-model: Add extra ordering for locks and remove it for ordinary release/acquire
- From: Peter Zijlstra <peterz@xxxxxxxxxxxxx>
- Date: Fri, 10 Sep 2021 19:17:43 +0200
- Cc: Boqun Feng <boqun.feng@xxxxxxxxx>, "Paul E. McKenney" <paulmck@xxxxxxxxxx>, Dan Lustig <dlustig@xxxxxxxxxx>, Will Deacon <will@xxxxxxxxxx>, Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>, Alexander Shishkin <alexander.shishkin@xxxxxxxxxxxxxxx>, Peter Anvin <hpa@xxxxxxxxx>, Andrea Parri <parri.andrea@xxxxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx>, Vince Weaver <vincent.weaver@xxxxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Jiri Olsa <jolsa@xxxxxxxxxx>, Arnaldo Carvalho de Melo <acme@xxxxxxxxxx>, Linux Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, Stephane Eranian <eranian@xxxxxxxxxx>, linux-tip-commits@xxxxxxxxxxxxxxx, palmer@xxxxxxxxxxx, paul.walmsley@xxxxxxxxxx, mpe@xxxxxxxxxxxxxx
- In-reply-to: <20210910163632.GC39858@rowland.harvard.edu>
- References: <YTiXyiA92dM9726M@hirez.programming.kicks-ass.net> <YTiiC1mxzHyUJ47F@hirez.programming.kicks-ass.net> <20210908144217.GA603644@rowland.harvard.edu> <CAHk-=wiXJygbW+_1BdSX6M8j6z4w8gRSHVcaD5saihaNJApnoQ@mail.gmail.com> <YTm26u9i3hpjrNpr@hirez.programming.kicks-ass.net> <20210909133535.GA9722@willie-the-truck> <5412ab37-2979-5717-4951-6a61366df0f2@nvidia.com> <20210909180005.GA2230712@paulmck-ThinkPad-P17-Gen-1> <YTtpnZuSId9yDUjB@boqun-archlinux> <20210910163632.GC39858@rowland.harvard.edu>
On Fri, Sep 10, 2021 at 12:36:32PM -0400, Alan Stern wrote:
> --- usb-devel.orig/tools/memory-model/Documentation/explanation.txt
> +++ usb-devel/tools/memory-model/Documentation/explanation.txt
> @@ -1813,15 +1813,16 @@ spin_trylock() -- we can call these thin
> lock-acquires -- have two properties beyond those of ordinary releases
> and acquires.
>
> +First, when a lock-acquire reads from or is po-after a lock-release,
> +the LKMM requires that every instruction po-before the lock-release
> +must execute before any instruction po-after the lock-acquire. This
> +would naturally hold if the release and acquire operations were on
> +different CPUs and accessed the same lock variable, but the LKMM says
> +it also holds when they are on the same CPU, even if they access
> +different lock variables. For example:
Could be I don't understand this right, but the way I'm reading it, it
seems to imply RCsc. Which I don't think we're actually asking at this
time.
[Index of Archives]
[Linux Stable Commits]
[Linux Stable Kernel]
[Linux Kernel]
[Linux USB Devel]
[Linux Video &Media]
[Linux Audio Users]
[Yosemite News]
[Linux SCSI]