Received: by 2002:ab2:6309:0:b0:1fb:d597:ff75 with SMTP id s9csp582695lqt; Thu, 6 Jun 2024 11:52:11 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX4t/z3JnY+VnsJvIZsejOR+a/vlbFB+iq00ceDiIMFxHYWz2+Fq1atGuV2R1TW4XHG5/C/2R3lw/2twlyJcP6GgnYE95udg4BZykuwiQ== X-Google-Smtp-Source: AGHT+IF+7DDNZa2C3icfGE+mL61x2hDUc/AiqYX5uzCpuRzGtY7ZPelHBq/SE7D1pWCjkqvcUjhd X-Received: by 2002:a05:622a:15c6:b0:440:279c:f9e8 with SMTP id d75a77b69052e-44041c81d88mr5250661cf.40.1717699931141; Thu, 06 Jun 2024 11:52:11 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717699931; cv=pass; d=google.com; s=arc-20160816; b=WCLNx9SVH4Nw8lszYsE6x8hStKXACA2UVGSGvFd0Y0dzzV1CvEfEc2K+ReSdNlK0Bx NiNRxZL16v1E56gh6wKLGi5uh6QMvTQqALIt2Na7D3GOIOYnafg4RM9YvUBePaS5CaJf 7el01X/Tw/SiytigPaEJUij/+SJAK56oi7fu2oxjOXxOvuDY6B67L8+yroNE7gWni+OF vE5u+4SMnoVO5VvbrfKoIWS4pK29SH/b5KTxepgUwsi8qfl/bo9eBGeroju5ICDCVNfn nhDIyuNj6mfyWXcGC6GksWzkfnNK9F3W0bfwRWdHF4/BrlULrZan7sBx6GT8nm1ykCDt 9ZDA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date; bh=yIAZZBdUu/UoXk7VStEBiFwbwGxSmwSh47y3G88ok6c=; fh=0zCIpKUUfXNR4vgEGKRVdryXrgfIVE1T7Yen7VUJyhA=; b=BS+Y8g94Sueir8wiEkUfACIpulr4msCNYTgEjXy+vrc4zsSAYm9r9hDxd2Ry8ZHGJM iexsBsRNpxMezXthQif3jsrEjQmVVVMFFZkKwlDVEb2soN/zw6dqgi5XiF/I9TB3PdCi KUWnP4JnE0VxA3hDgWAEtgnDX36ikU/cQNQkwTXWmnwdtWWd1W0ja5gc3ExFkoCSeBjl ynZnN1gn6NX04D/c5yBwfG9uemiZaz/jxffB/qXLJ3StID60zfzDr9EFsEYXdbRv7o31 pRa0xcAw6eY0AcVzPBrSiRX0/M21y4mX7jIQX+ZCN61TQ26lrL64zCT6OJvpKeJ+W/cf QPQQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=netrider.rowland.org); spf=pass (google.com: domain of linux-kernel+bounces-204919-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-204919-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=harvard.edu Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id d75a77b69052e-44038b170fbsi12368231cf.233.2024.06.06.11.52.10 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Jun 2024 11:52:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-204919-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=netrider.rowland.org); spf=pass (google.com: domain of linux-kernel+bounces-204919-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-204919-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=harvard.edu Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id D71B01C21841 for ; Thu, 6 Jun 2024 18:52:10 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 395BC4F615; Thu, 6 Jun 2024 18:52:06 +0000 (UTC) Received: from netrider.rowland.org (netrider.rowland.org [192.131.102.5]) by smtp.subspace.kernel.org (Postfix) with SMTP id B7C204DA0F for ; Thu, 6 Jun 2024 18:52:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.131.102.5 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717699925; cv=none; b=eTKY2gqFQJgWnqRotj2c7KOruQleaf8rQq+qX9Sxmf71ZErPBdg4JLgSIWc9X/4yvlornk/ehzDrDBLSh2/e1iusX91MkSTWcRvmYnHF7SOmEQrHXW+AP0s2+NII5oSPtJk4Leaj12W/bBkTxTo1YN060JuAkt8c3pGifsXvt/o= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717699925; c=relaxed/simple; bh=tT1S45dFo3TnMqFOJNXtbpzOZ2RqSOmznvA+HJXmivk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=HPbmJTh+nUdRGU38uaBAI9Zsm0Uh/p5lvLq0Sn/QTq8+DAOilU9B8GhEsmaZsRYEQQdquT6R36FnVx4FgwAqMNdDTJia2Eu+TSqvAWaLjbug1cKh0c6IB1JhgltKxmvdL6wI7w5ey9N/D+2zL8UqBrXObR0/v4weDq91aqzH3fo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=rowland.harvard.edu; spf=pass smtp.mailfrom=netrider.rowland.org; arc=none smtp.client-ip=192.131.102.5 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=rowland.harvard.edu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=netrider.rowland.org Received: (qmail 16315 invoked by uid 1000); 6 Jun 2024 14:52:02 -0400 Date: Thu, 6 Jun 2024 14:52:02 -0400 From: Alan Stern To: "Paul E. McKenney" Cc: Andrea Parri , will@kernel.org, peterz@infradead.org, 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, linux-kernel@vger.kernel.org, hernan.poncedeleon@huaweicloud.com, jonas.oberhauser@huaweicloud.com Subject: Re: New locking test for the paulmckrcu/litmus github archive Message-ID: <51b94313-ed74-4507-a354-eb418389fdaf@rowland.harvard.edu> References: <1d175b42-84b4-4a48-b1fb-ab6fd3566f75@rowland.harvard.edu> <64d944ff-b609-4977-a491-91ffc199a4cd@paulmck-laptop> <26aa2333-5e54-4dcd-b6df-f8f8545b2672@rowland.harvard.edu> <47fe55b3-81af-4397-9769-bda25209e980@paulmck-laptop> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <47fe55b3-81af-4397-9769-bda25209e980@paulmck-laptop> On Thu, Jun 06, 2024 at 10:57:42AM -0700, Paul E. McKenney wrote: > On Thu, Jun 06, 2024 at 01:21:28PM -0400, Alan Stern wrote: > > Okay. Don't we already have a litmus test in the archive that really > > does create a deadlock? Something like: Lock Lock Unlock Unlock, all > > using the same lock variable? > > We do have these guys: > > auto/C-RR-GR+RR-R+RR-R.litmus > auto/C-RR-GR+RR-R.litmus > auto/C-RW-GR+RW-R+RW-R.litmus > auto/C-RW-GR+RW-R.litmus > auto/C-WR-GR+WR-R+WR-R.litmus > auto/C-WR-GR+WR-R.litmus > auto/C-WW-GR+WW-R+WW-R.litmus > auto/C-WW-GR+WW-R.litmus > A synchronize_rcu() in an RCU read-side critical section. > > I added a manual/locked/self-deadlock.litmus, which is shown at the > end of this email. Omitting the nested self-deadlocking acquisition > and release gives one state with blank line. ;-) Hah, because there is no "exists" clause and no variables other than the spinlock itself. > Or should I add a spin_is_locked() in order to get a non-empty > state line? It's fine the way it is. Alan