Received: by 10.213.65.68 with SMTP id h4csp2952739imn; Mon, 9 Apr 2018 11:45:46 -0700 (PDT) X-Google-Smtp-Source: AIpwx49bJuI9rSU/6apr+iL2rQJvIj3f4UMKMi9cnsT4WB0vRoXEZYPBW26BlVl0SbVDC3myjHRo X-Received: by 10.98.152.17 with SMTP id q17mr92440pfd.67.1523299546131; Mon, 09 Apr 2018 11:45:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523299546; cv=none; d=google.com; s=arc-20160816; b=xACwJT49ZznshyrOATii6iSLpfmXLLh5Xotu9ISkI5PK7NAXav3SrQ221O0w3utteS 91XEUOLtSDaZmtdzCp10S8KRrS8oIE5nf7KDWymyS4JhfKZIfYRmgspJd1Iy6lO+FzTS jB/EtCvVeZ6m0wRZKZDEjeFkOUwoTKpo0EhtBg/qog3l5Oc3yARjGSQPP24w+F/3iDUg dtaJ88W+5QEdAQP/LL77JkIV9x1ELwDCMTRBK04FeUYiFzNED+iS5nRTv1foAOTac5X5 rL6CaHzYXvFrS/3msX9YgoRkhB/H0D0gXxUd4fii+/qYWxlIFmJziJDfKz181BT9pHd4 CaIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:user-agent:in-reply-to :content-disposition:mime-version:references:reply-to:subject:cc:to :from:date:arc-authentication-results; bh=7xzR+82r1Y/9ekFzpe1Tl8jQJUtq9mKBuXRGyqxkEdA=; b=ihywXGmtFOa1ulhgW8xjsTQeKo0IfCN05Z9FKkolIRusSkN2KAPEjLUUTPoZKmxaqt yHAmDQpZQVzLQ9Or+kggoz+KpeMhrSZC36Sr7UfDpRxcYDo6+1f9FzydYJWMNdHVUhxF PyBGIGTl3RBGqHz9gA/BBqfVHJ+ryzzaDZ4+0HyrJaLYopO0lcFYdlRz3PYPT/rn1UWV WEG7RwshrefXqJV4T3+FQt+ix+VH+rVXxQQHj9Lz3oFp1sNZeMpA3VSMopjdILzhNTGd jO2rPIzrej+nQNyRQpRwk29fe5C6XLe6dBXS9P3yhAHXFtDvPLBnQLLVw5saBwgcuajd 7GYQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d9-v6si814045plj.551.2018.04.09.11.45.08; Mon, 09 Apr 2018 11:45:46 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752857AbeDISmD (ORCPT + 99 others); Mon, 9 Apr 2018 14:42:03 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:59138 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751767AbeDISmC (ORCPT ); Mon, 9 Apr 2018 14:42:02 -0400 Received: from pps.filterd (m0098416.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w39IfQqA105303 for ; Mon, 9 Apr 2018 14:42:02 -0400 Received: from e11.ny.us.ibm.com (e11.ny.us.ibm.com [129.33.205.201]) by mx0b-001b2d01.pphosted.com with ESMTP id 2h8amvgs54-1 (version=TLSv1.2 cipher=AES256-SHA256 bits=256 verify=NOT) for ; Mon, 09 Apr 2018 14:42:01 -0400 Received: from localhost by e11.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 9 Apr 2018 14:42:01 -0400 Received: from b01cxnp22036.gho.pok.ibm.com (9.57.198.26) by e11.ny.us.ibm.com (146.89.104.198) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 9 Apr 2018 14:41:56 -0400 Received: from b01ledav003.gho.pok.ibm.com (b01ledav003.gho.pok.ibm.com [9.57.199.108]) by b01cxnp22036.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w39IfuYZ54263978; Mon, 9 Apr 2018 18:41:56 GMT Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2AAC7B204D; Mon, 9 Apr 2018 15:44:02 -0400 (EDT) Received: from paulmck-ThinkPad-W541 (unknown [9.70.82.108]) by b01ledav003.gho.pok.ibm.com (Postfix) with ESMTP id E6C87B204E; Mon, 9 Apr 2018 15:44:01 -0400 (EDT) Received: by paulmck-ThinkPad-W541 (Postfix, from userid 1000) id C7FAF16C3759; Mon, 9 Apr 2018 11:42:58 -0700 (PDT) Date: Mon, 9 Apr 2018 11:42:58 -0700 From: "Paul E. McKenney" To: Paolo Bonzini Cc: linux-kernel@vger.kernel.org, Alan Stern , Andrea Parri , Will Deacon , Peter Zijlstra , Boqun Feng , Nicholas Piggin , David Howells , Jade Alglave , Luc Maranget , Akira Yokosawa Subject: Re: [PATCH] memory-model: fix cheat sheet typo Reply-To: paulmck@linux.vnet.ibm.com References: <1523292618-10207-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1523292618-10207-1-git-send-email-pbonzini@redhat.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-TM-AS-GCONF: 00 x-cbid: 18040918-2213-0000-0000-0000028CD300 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00008825; HX=3.00000241; KW=3.00000007; PH=3.00000004; SC=3.00000256; SDB=6.01015496; UDB=6.00517792; IPR=6.00794747; MB=3.00020488; MTD=3.00000008; XFM=3.00000015; UTC=2018-04-09 18:41:59 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18040918-2214-0000-0000-000059B0FB3B Message-Id: <20180409184258.GP3948@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-04-09_08:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1709140000 definitions=main-1804090189 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 09, 2018 at 06:50:15PM +0200, Paolo Bonzini wrote: > "RWM" should be "RMW", and that's more or less the extent to which I > can claim to change the document. :) In particular, "Self" is not > documented and the difference between "Self" and "SV" is not clear > to me. > > Signed-off-by: Paolo Bonzini Applied, though without the questions. ;-) "Self" is for things like smp_load_acquire() and smp_store_release() that order themselves against later and earlier accesses, respectively. This ordering applies to later/earlier access to all variables, not just the one that smp_load_acquire()/smp_store_release() accessed. In contrast, things like smp_mb() order only other accesses, not themselves. Or at least it is impossible to proves whether or not they order themselves because they are not separately visible to other CPUs. "SV" is "same variable", which applies to pretty much anything that accesses a variable, but not to things like smp_mb() which do not. Does that help? Thanx, Paul > --- > tools/memory-model/Documentation/cheatsheet.txt | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tools/memory-model/Documentation/cheatsheet.txt b/tools/memory-model/Documentation/cheatsheet.txt > index 956b1ae4aafb..c0eafdaddfa4 100644 > --- a/tools/memory-model/Documentation/cheatsheet.txt > +++ b/tools/memory-model/Documentation/cheatsheet.txt > @@ -1,6 +1,6 @@ > Prior Operation Subsequent Operation > --------------- --------------------------- > - C Self R W RWM Self R W DR DW RMW SV > + C Self R W RMW Self R W DR DW RMW SV > -- ---- - - --- ---- - - -- -- --- -- > > Store, e.g., WRITE_ONCE() Y Y > -- > 1.8.3.1 >