Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1843334imm; Mon, 3 Sep 2018 10:54:05 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYL3V0vUG7UvJq6zwE8dAon+0tXHACrwn70YZpkt0zoAU5lQaI9XOCPhW3kQ2BWHq8WFWAF X-Received: by 2002:a17:902:18a:: with SMTP id b10-v6mr29703405plb.62.1535997245633; Mon, 03 Sep 2018 10:54:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535997245; cv=none; d=google.com; s=arc-20160816; b=qX+zoyzFGShVMv2B8MVj0neX8xCUI+qsku/97Xc2QTC1O08Mzk2l+9fDOhTncHHjvC SKdauGF5yDnfCp5JZIiIGq8iPLjuu6OvVLnydx5lYabC1CqJtRdh5xlPJM36FcvW1Gd/ Zx12rLEA0peXQ12/QLR5sJ8VglNlEEJNPxtT7dhj6ewRhOeUkjUFaSTcav10D1/YYFs2 wkJ3g4CGDm4N4MDS9CZne6tu6PxkOS83/sayhmCKL02n/jHcYmuc7AeeA8gtKadSPnBb gYzjTH1cNFGGx71jWyaFHFK6Y2/ONBsDbBE+u4ytMylqJAZ4UdUFaAJ1Pu5M0lATdmbT xCmA== 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:arc-authentication-results; bh=wAuhdUbjhClbA0JUgma8Ktz1wbvCRA/B3CP4MiwGSR8=; b=ieAt3lPywwlUyvyDA48aGZELU0666ae1IbwjCeIKdjKaAN/JnnIvecR+bSGmRi6SG9 RN0uHPCznktrut8lni9HmAuEBCBqFOtw+K3nTt8Ov5sZItaVqtJQ1CrNIv3lsF7ubgg1 JRfUwxHuw0RmQm2sJMoVsrd805Df4/evVk3dee0ErfPKzsIkWCnbXA/5QZtEygajnS6V NDj5Q8gKZFsw7Wey80mChymzHA4hxx3vlmZfSN7h+0OVQxymbyyl/9RY6UE6oKoHzuIn 2cdFpBakcoToBOG2BF+x92WCg0L9ddpooCqQg2++1msymhDM4JyfAigHwepJaFISYM4R poLA== 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 s14-v6si17835123pga.21.2018.09.03.10.53.49; Mon, 03 Sep 2018 10:54:05 -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 S1727799AbeICWNX (ORCPT + 99 others); Mon, 3 Sep 2018 18:13:23 -0400 Received: from netrider.rowland.org ([192.131.102.5]:32785 "HELO netrider.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1727480AbeICWNX (ORCPT ); Mon, 3 Sep 2018 18:13:23 -0400 Received: (qmail 2183 invoked by uid 500); 3 Sep 2018 13:52:07 -0400 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 3 Sep 2018 13:52:07 -0400 Date: Mon, 3 Sep 2018 13:52:07 -0400 (EDT) From: Alan Stern X-X-Sender: stern@netrider.rowland.org To: Andrea Parri cc: Will Deacon , Andrea Parri , "Paul E. McKenney" , , , , , , , , , , Subject: Re: [PATCH RFC LKMM 1/7] tools/memory-model: Add extra ordering for locks and remove it for ordinary release/acquire In-Reply-To: <20180903090153.GA4560@andrea> 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, 3 Sep 2018, Andrea Parri wrote: > In Cat speak, > > diff --git a/tools/memory-model/linux-kernel.cat b/tools/memory-model/linux-kernel.cat > index 59b5cbe6b6240..fd9c0831adf0a 100644 > --- a/tools/memory-model/linux-kernel.cat > +++ b/tools/memory-model/linux-kernel.cat > @@ -38,7 +38,7 @@ let strong-fence = mb | gp > (* Release Acquire *) > let acq-po = [Acquire] ; po ; [M] > let po-rel = [M] ; po ; [Release] > -let rfi-rel-acq = [Release] ; rfi ; [Acquire] > +let po-rel-rf-acq-po = po ; [Release] ; rf ; [Acquire] ; po > > (**********************************) > (* Fundamental coherence ordering *) > @@ -60,13 +60,13 @@ let dep = addr | data > let rwdep = (dep | ctrl) ; [W] > let overwrite = co | fr > let to-w = rwdep | (overwrite & int) > -let to-r = addr | (dep ; rfi) | rfi-rel-acq > +let to-r = addr | (dep ; rfi) > let fence = strong-fence | wmb | po-rel | rmb | acq-po > -let ppo = to-r | to-w | fence > +let ppo = to-r | to-w | fence | (po-rel-rf-acq-po & int) > > (* Propagation: Ordering from release operations and strong fences. *) > let A-cumul(r) = rfe? ; r > -let cumul-fence = A-cumul(strong-fence | po-rel) | wmb > +let cumul-fence = A-cumul(strong-fence | po-rel) | wmb | po-rel-rf-acq-po > let prop = (overwrite & ext)? ; cumul-fence* ; rfe? > > (* I thought the goal you were aiming for was a patch making atomic-acquire/ordinary-release be RCtso (along with lock/unlock), while leaving ordinary-acquire/ordinary-release to remain RCpc. Clearly that is not what this patch does. Alan