Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3841223ybi; Mon, 29 Jul 2019 13:42:25 -0700 (PDT) X-Google-Smtp-Source: APXvYqxJw6mxIw4nKtGsK/uHjz/xVpMSwuNAVeNKcbAmXuKAj9HDFVbCTRg908uASo7WotRjbBIO X-Received: by 2002:a63:8f55:: with SMTP id r21mr104582253pgn.318.1564432945720; Mon, 29 Jul 2019 13:42:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564432945; cv=none; d=google.com; s=arc-20160816; b=Gk3loesQHB7w4aBWUEnEO/yB89Jif7RL6nW7jR2O8EpFbEbrWRtkkfSg0TSqLkaLXh tN4KhJzFAFHomn7QVspQX+hhCnmzZfQJh0FyRiU4uMEZpl1jkPyr5imEM4jEYrQgmtBX j0h4ES5NYUTRfsARz7rExdII1oVtn2MDf+vpNmlqCYUPirz0316SkRv4QMLOOmRkGWqP Lgajiitk9tMfqdbGmVz/B12Te4s1/QCyi3DE8LOHNNouCxaNdiDfbbkPafrX34Or7RnP RRszHzAz/y5UM8vqraaXLM1tFs6ZRYZ9qbqU4A2PTtwNBsFcq03RtUeawKK7oUsrZYY8 +dhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:in-reply-to :subject:cc:to:from:date; bh=J5oNa6Nj6WwApl++mfQvI/1Rz5PHqNXluoJ1lxT5GpY=; b=vMsL/Q6Q6PnP7g8STG9wASepV4N0/XVhuN/8zrUIn/md0a0eQflpPVBswtKAcISePa qLprQLkgtpGmaZ6DSQicvLq/103Yv9YK8qnY06KOoIToXlkxlav6UIK5FWCWYyzqxD7W lgjgUDo31thXlE3cGPmI64V5XMCOycQ66b3WDOzoPK0r7DMCGyn7S7Z+NRNpZdHW19eT R2yYe2R8UaOu5RDsuroMp4jFjpGjEfXgVzqnguYZpaNrpPtWzberFcDv6PhnHouZSHLl 7IkBqXyO1qnyTeD/V7fy0tHyoTALgKoaiC77Kf0OvKqZPGQ4a8RKpyCsPjafDIy0t6Ws BRfQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n1si26996720pgn.77.2019.07.29.13.42.09; Mon, 29 Jul 2019 13:42:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729295AbfG2Ulf (ORCPT + 99 others); Mon, 29 Jul 2019 16:41:35 -0400 Received: from netrider.rowland.org ([192.131.102.5]:60357 "HELO netrider.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1729125AbfG2Ulf (ORCPT ); Mon, 29 Jul 2019 16:41:35 -0400 Received: (qmail 2507 invoked by uid 500); 29 Jul 2019 16:41:34 -0400 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 29 Jul 2019 16:41:34 -0400 Date: Mon, 29 Jul 2019 16:41:34 -0400 (EDT) From: Alan Stern X-X-Sender: stern@netrider.rowland.org To: "Joel Fernandes (Google)" cc: linux-kernel@vger.kernel.org, Akira Yokosawa , Andrea Parri , Boqun Feng , Daniel Lustig , David Howells , Ingo Molnar , Jade Alglave , , Luc Maranget , Nicholas Piggin , "Paul E. McKenney" , Peter Zijlstra , Will Deacon Subject: Re: [PATCH] Use term cumul-fence instead of fence in ->prop ordering example In-Reply-To: <20190729123605.150423-1-joel@joelfernandes.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 29 Jul 2019, Joel Fernandes (Google) wrote: > To reduce ambiguity in the more exotic ->prop ordering example, let us > use the term cumul-fence instead fence for the 2 fences, so that the > implict ->rfe on loads/stores to Y are covered by the description. > > Link: https://lore.kernel.org/lkml/20190729121745.GA140682@google.com > > Suggested-by: Alan Stern > Signed-off-by: Joel Fernandes (Google) > --- > tools/memory-model/Documentation/explanation.txt | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/tools/memory-model/Documentation/explanation.txt b/tools/memory-model/Documentation/explanation.txt > index 68caa9a976d0..634dc6db26c4 100644 > --- a/tools/memory-model/Documentation/explanation.txt > +++ b/tools/memory-model/Documentation/explanation.txt > @@ -1302,7 +1302,7 @@ followed by an arbitrary number of cumul-fence links, ending with an > rfe link. You can concoct more exotic examples, containing more than > one fence, although this quickly leads to diminishing returns in terms > of complexity. For instance, here's an example containing a coe link > -followed by two fences and an rfe link, utilizing the fact that > +followed by two cumul-fences and an rfe link, utilizing the fact that > release fences are A-cumulative: > > int x, y, z; > @@ -1334,10 +1334,10 @@ If x = 2, r0 = 1, and r2 = 1 after this code runs then there is a prop > link from P0's store to its load. This is because P0's store gets > overwritten by P1's store since x = 2 at the end (a coe link), the > smp_wmb() ensures that P1's store to x propagates to P2 before the > -store to y does (the first fence), the store to y propagates to P2 > +store to y does (the first cumul-fence), the store to y propagates to P2 > before P2's load and store execute, P2's smp_store_release() > guarantees that the stores to x and y both propagate to P0 before the > -store to z does (the second fence), and P0's load executes after the > +store to z does (the second cumul-fence), and P0's load executes after the > store to z has propagated to P0 (an rfe link). > > In summary, the fact that the hb relation links memory access events Acked-by: Alan Stern