Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1438877pxb; Thu, 4 Mar 2021 11:16:03 -0800 (PST) X-Google-Smtp-Source: ABdhPJzmyMJ4Q2sOGeCtFnfISJU6c+gzpcRp87qc5YofuY8mU3Kr89wDmwbbt57Nl8W0dtCStFQt X-Received: by 2002:a17:906:a147:: with SMTP id bu7mr5820238ejb.383.1614885363592; Thu, 04 Mar 2021 11:16:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614885363; cv=none; d=google.com; s=arc-20160816; b=AV15y4YW5OkQ3RF5L7oxPXK4FIbYGMb0L+Koh+GF4orw5s3RG8gGUyeJPlfGuTwAsi ZeP/nJDHoLDjnMGFXY5HzNge1gGRBhp7Pm4eRGnV6zwh9+b119LLVmhp5FtAE24zOHMl 1wzQNIczgbKJZgx3/Z7CFCXld83T5ihMWsLr0SGztwlWnM8syVkBSlnX9Hp3i+7Y358Q KUkeQz5Gq6XlI4koZW/LX1sDJTrAx/UpISffaX5r+0j8AB/awih3+DCJX5JivcTNaYlE iR1qQmKfxhC8t9IoLwlc6Ql+QENMxaavvLVk6gQscgzF+fiq7uopxL68oeP6IzD+qAs5 wkBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=O/U+FOw2QoJKv9HP7hxak+YAr+3YGc0Lw6sWN1PLhRw=; b=p1aKZlAcJUYSMeDnAl+3rp4fyLb+YiqBvVmiFrvuq8W7eN/DlF6vLuV3jRU10r2cMf g2v60kaPFTpcxon2PLwZjSt/+zaL9pNlManZdd2GtEDLhHivDJZjmhG+TgWdfmFYyoqm ZHBrDY3Ukctx5kbaoJ+tBzRFuk/NQ5a1ZpBbChjzcKphflAoeoKr9Z2Pg1SMSmdNKfnU 2q4Lq+H77SpsX6us/L/6zchJ3CI4t3L1U/fSL9bKaIGe7nqvfH/f99MQPp33viPx5nmN OLSwxt7kU5PGuxOW2vEyY77F1LDDly0L2Az864QW9xRUbIqJAx9oMjF+GtxjQNgreElG +9Rw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UGRIsbPa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p31si302652edb.114.2021.03.04.11.15.40; Thu, 04 Mar 2021 11:16:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UGRIsbPa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232169AbhCDTG1 (ORCPT + 99 others); Thu, 4 Mar 2021 14:06:27 -0500 Received: from mail.kernel.org ([198.145.29.99]:38636 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229512AbhCDTF4 (ORCPT ); Thu, 4 Mar 2021 14:05:56 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2626C64F62; Thu, 4 Mar 2021 19:05:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1614884716; bh=JDlrgpDqWIhApydlb10ONN+UktROsuzfop0m6TWYfM4=; h=Date:From:To:Cc:Subject:Reply-To:References:In-Reply-To:From; b=UGRIsbPaMRbi4/Oq4c/ZwjLvYOBsqY0kPPyxkAVhRpgQp/lrpZ0IQYXL0aBExBdse vp4BhJq2Ph1a+C8OPami/aZctacVL22bF+CaHEKRaM7spN9qlafJf9g5TGYPyX+A1t APblOpIiBTapm5iUd0J1rtNONfkvJxySZ0sMSyJu6tU3qy1GPPzuxenP8kxzhygXIU oQI7xc4L2zYrQmeEQPOIVchfzmaKVAajyDZLzSkDW9jmb2phoEL9mNumzNfoccRtn1 TldeJxVFzHfpSdyI1d/+O8gYLMzOGlLR4lrlcMWsRhN05xCEzXqo1rSZ060qddQAbq df7OnKEp5MZ2Q== Received: by paulmck-ThinkPad-P72.home (Postfix, from userid 1000) id D0AF43520831; Thu, 4 Mar 2021 11:05:15 -0800 (PST) Date: Thu, 4 Mar 2021 11:05:15 -0800 From: "Paul E. McKenney" To: Alan Stern Cc: =?iso-8859-1?Q?Bj=F6rn_T=F6pel?= , bpf , LKML , parri.andrea@gmail.com, Will Deacon , Peter Zijlstra , boqun.feng@gmail.com, npiggin@gmail.com, dhowells@redhat.com, j.alglave@ucl.ac.uk, luc.maranget@inria.fr, akiyks@gmail.com, dlustig@nvidia.com, joel@joelfernandes.org, Toke =?iso-8859-1?Q?H=F8iland-J=F8rgensen?= , "Karlsson, Magnus" Subject: Re: XDP socket rings, and LKMM litmus tests Message-ID: <20210304190515.GS2696@paulmck-ThinkPad-P72> Reply-To: paulmck@kernel.org References: <20210302211446.GA1541641@rowland.harvard.edu> <20210302235019.GT2696@paulmck-ThinkPad-P72> <20210303171221.GA1574518@rowland.harvard.edu> <20210303174022.GD2696@paulmck-ThinkPad-P72> <20210303202246.GC1582185@rowland.harvard.edu> <20210303220348.GL2696@paulmck-ThinkPad-P72> <20210304032101.GB1594980@rowland.harvard.edu> <20210304050407.GN2696@paulmck-ThinkPad-P72> <20210304153524.GA1612307@rowland.harvard.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210304153524.GA1612307@rowland.harvard.edu> User-Agent: Mutt/1.9.4 (2018-02-28) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 04, 2021 at 10:35:24AM -0500, Alan Stern wrote: > On Wed, Mar 03, 2021 at 09:04:07PM -0800, Paul E. McKenney wrote: > > On Wed, Mar 03, 2021 at 10:21:01PM -0500, Alan Stern wrote: > > > On Wed, Mar 03, 2021 at 02:03:48PM -0800, Paul E. McKenney wrote: > > > > On Wed, Mar 03, 2021 at 03:22:46PM -0500, Alan Stern wrote: > > > > > > > And I cannot immediately think of a situation where > > > > > > this approach would break that would not result in a data race being > > > > > > flagged. Or is this yet another failure of my imagination? > > > > > > > > > > By definition, an access to a local variable cannot participate in a > > > > > data race because all such accesses are confined to a single thread. > > > > > > > > True, but its value might have come from a load from a shared variable. > > > > > > Then that load could have participated in a data race. But the store to > > > the local variable cannot. > > > > Agreed. My thought was that if the ordering from the initial (non-local) > > load mattered, then that initial load must have participated in a > > data race. Is that true, or am I failing to perceive some corner case? > > Ordering can matter even when no data race is involved. Just think > about how much of the memory model is concerned with ordering of > marked accesses, which don't participate in data races unless there is > a conflicting plain access somewhere. Fair point. Should I have instead said "then that initial load must have run concurrently with a store to that same variable"? Thanx, Paul