Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp2032521ybk; Mon, 11 May 2020 10:12:26 -0700 (PDT) X-Google-Smtp-Source: APiQypLQIJoyBJiTIse8BMjiP7yb0kkFDOp152uqhC+UUEpbsfIlL4VtooZ5V4jnS/1GaC628MlA X-Received: by 2002:a50:c3c2:: with SMTP id i2mr13862874edf.93.1589217146628; Mon, 11 May 2020 10:12:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589217146; cv=none; d=google.com; s=arc-20160816; b=I+Td8UxauIdtLVHiPkBTUqIklt6SCSdrRg5KB4hw8k9onHMjMoxBbHphxpQUF/uI2s Zc/5VstJGwMEWL+onPo95kc5z8fXaEwPuLqc8ica3L6qnWGgNy20hcIlkzWzyujKQnx/ yPbKIL0h7xzoEQ02/Ty/Fh5h0OiD5atic0Toz1FtjRMbODhLyPVdGp2PVTUQ2qUzzWGG jYiSMOVCtPvTvxwOw3mE9r74hzIhIXc+syXsA/HO6vVgkW00BRDXnwU3Jo+EtNicF4L7 ZY7oTHGI8n7FgxE/SsarGbJkHwLoTvOPB6W5TuJpUVja2Oyp0aDn8IWLf3iHw7xYvsAj OT5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:in-reply-to:cc:references:message-id :date:subject:mime-version:from:content-transfer-encoding :dkim-signature; bh=s3MqmJBPH7DhM0m/q2Mzg7C6aYh+j9doHOTSnhJ6rpU=; b=B11U/PYSgZCeulM7f/SZOeXEIkVNAOJONjwqpxJ+YZwMTaEot8BmXzv+hUgkQMSxcg YG2RXfL4J/jdj46fHY9Yvb/qsu6HqdSmeJdtdEGg6cnu+vFCFktLMh3Fez4ac5lhS/XX LRarjfdeHqmUP1tCNszyJn0nckCA2EnRq5cD+s0ojXor2tg6js16NsOAuPiP8LXuuG1Q kGC8u2OhJnmGM/6LYyWLvb3g5xQIoXW5H6iaTDesgF4mpGhuhoiJU/eC3cxn17vsulqc 9AuNcaOfLBqz8wGJkf7bV8qwjc2Fj6hnCH1NWxclYiqhdkT1/uKvwTYtKsglD51tYZ0W 4boA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lca.pw header.s=google header.b=Q2bpaFQw; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z10si691571ejx.94.2020.05.11.10.12.02; Mon, 11 May 2020 10:12:26 -0700 (PDT) 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=@lca.pw header.s=google header.b=Q2bpaFQw; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730828AbgEKRKa (ORCPT + 99 others); Mon, 11 May 2020 13:10:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36444 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730799AbgEKRKa (ORCPT ); Mon, 11 May 2020 13:10:30 -0400 Received: from mail-qv1-xf41.google.com (mail-qv1-xf41.google.com [IPv6:2607:f8b0:4864:20::f41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 630EFC061A0C for ; Mon, 11 May 2020 10:10:30 -0700 (PDT) Received: by mail-qv1-xf41.google.com with SMTP id fb4so4765573qvb.7 for ; Mon, 11 May 2020 10:10:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lca.pw; s=google; h=content-transfer-encoding:from:mime-version:subject:date:message-id :references:cc:in-reply-to:to; bh=s3MqmJBPH7DhM0m/q2Mzg7C6aYh+j9doHOTSnhJ6rpU=; b=Q2bpaFQwSLabQ46lMjS4T2LDI7Qd+GxFXvBEohZUuNClYtWo4rTAsLLXRwo63GSq6U eGos553fK0vUmynlLWGWmDHsaitdAoNHDiLZNFteh8XeFH677nmIn7hp0nrwHTa+eVuS +F998gEJu82Aoge8UdY7lQRiRnuLV36extqly56wr4U35dg7UwoVTvE0hTpbE4J65gC7 g0exhPLLNqlEeQQGqect1xaVM61WNmZ9WxG7/BZb0EVEh+GmS20SR50ShAU/h6+FJhhh YRYI647Qtm04IAGC3Szt373Yaw5x/v7kETdoPo7udtvAGUFJvOY3BRrPdUjr24g5hu3F /BoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:content-transfer-encoding:from:mime-version :subject:date:message-id:references:cc:in-reply-to:to; bh=s3MqmJBPH7DhM0m/q2Mzg7C6aYh+j9doHOTSnhJ6rpU=; b=iRIG0OE2xtrmZdExNReXZKAxg/P1/KURJKJ1+AeUouHYFubeSo9dFHgUEEp/tJa5tc AK5p52Bc7gEnguCCjHEPr76HnpdHhiI/lylWPdImp2IQsHt5Ba0WvBEA0oBPCCgOjYRu k5ZQG4zMj8zK5jpKWmEKn5iq48eH+yrBITAyXQiGyJ6PeLTgP856LWxsNvDbHoi/thWy AnLyCn7QI2VyqwWRbRR1gnp8rjjp6CABkxjJVtM+9j1kv67wAlVqtG0P3egYCL6F1KcN ms3TPeXvoJPwaZMiYbkEM6wgJhMaV0k2+/zm/99yH0To+nB6mlGOvcBnAz/bb3ol+YvG Bpvg== X-Gm-Message-State: AGi0PuYgYp1+vbVFIVinohnz6XBbD8Yj1IKqGJ3okHHUtV2LmCcQYUEf 63yYxGv+aUPR0fvawcUxx32QfQ== X-Received: by 2002:a05:6214:1427:: with SMTP id o7mr5256344qvx.104.1589217028474; Mon, 11 May 2020 10:10:28 -0700 (PDT) Received: from [192.168.1.183] (pool-71-184-117-43.bstnma.fios.verizon.net. [71.184.117.43]) by smtp.gmail.com with ESMTPSA id u190sm8777818qkb.102.2020.05.11.10.10.27 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 11 May 2020 10:10:27 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: Qian Cai Mime-Version: 1.0 (1.0) Subject: Re: [PATCH -next v2] locking/osq_lock: annotate a data race in osq_lock Date: Mon, 11 May 2020 13:10:27 -0400 Message-Id: References: <20200511165441.GB23081@willie-the-truck> Cc: "Paul E. McKenney" , Elver Marco , LKML , Ingo Molnar , "Peter Zijlstra (Intel)" In-Reply-To: <20200511165441.GB23081@willie-the-truck> To: Will Deacon X-Mailer: iPhone Mail (17D50) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On May 11, 2020, at 12:54 PM, Will Deacon wrote: >=20 > Hmm, I don't see how it can remove the cmpxchg(). Do you have a link to th= at > discussion, please? lore.kernel.org/lkml/20200211124753.GP14914@hirez.programming.kicks-ass.net Correction =E2=80=94 if compilers could prove =E2=80=9Dprev->next !=3D node=E2= =80=9D is always true, that cmpxchg() would not run. cpu_relax() should be s= ufficient to keep that =E2=80=9Cif statement=E2=80=9D been optimized away in= any case.=