Received: by 2002:ab2:3319:0:b0:1ef:7a0f:c32d with SMTP id i25csp232592lqc; Thu, 7 Mar 2024 16:06:14 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWcNEvzDEUSTALtQ7esI/BDtXOJcLvEbgmgcxolyVIV6FgImA5hNQLCfrc+MfXCZNtpWMRYMSkD3KxQE9LnNOeBGBeICDazQ1IH3LPXBg== X-Google-Smtp-Source: AGHT+IGI72oT+xsbMlZ07AN8PBjZZubETxLsd2FUbcwnAAXAex3HCJDnx8KGxPbHtBfPAV1A9GCO X-Received: by 2002:a05:620a:8c4:b0:788:3051:c09 with SMTP id z4-20020a05620a08c400b0078830510c09mr3874691qkz.21.1709856374739; Thu, 07 Mar 2024 16:06:14 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709856374; cv=pass; d=google.com; s=arc-20160816; b=m7xhG59SsJfcEva3cPiQPAfBpLvN/TaMnxyN7xjMiWRv2Q+Kakiuv4XLAxW6eoV++0 VVayjTT42mNVpqsoah4N74W7REaj4CZJmubETY1F0g2YTcccozaLRB7QUedIfjvWfyNQ B8TqrwSMT/aiyNRzgttosJBDiUa/3diHq674EIz8EbQDvSLjRkvHeWw6pmpYw8dhX5y4 FqcTZyR9VKkXiDiYbU2TYnoLaGAi3FDthjtspE2XYcJUryve+OtarJnOK5FHc5wi3upA /vvBvoHBjiHbyNGfHYUUM08oqCfuDmAVsHuCuxQKFsOvdWBCi/pTJ0CDPF6PUZjUgBT6 ynHw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=6H7dBJWfqdOrzeErRKsMN61MvC2o9DA3lo+0tp8Y5kA=; fh=bKTidXNeR58m6H13+xsasVuMPIpSrKzXPfZC8XBvp6o=; b=kDpPMTmNjH3ydLlAf7fTw8Pw6we8nzlqsgjnfe6665008KGAFqJTZRdY5JYcqRwqCZ bn+GOnjJea6yTYfo9dEPBCobvSuVZTPiCXE0+Sm7md0ks+/fpd/Qu5hUZILzOXkq6Px5 LKXnteNOF5GAlArAOVNfnbOyrbiVViujiET5WPZZyOo9ytRl152rU3SReBBxgCmwbOoL jyMK3p8oEmm7iyjKWQeOftHf9h0TqAtlL6JQ9h6o/Osgx/O9x+o92bGMiPLFNyVeUpw2 o01sQJd6fDV21hZoJw/E82pMHYovqgDXwrfjQwf12gfwMtm9smgiW+UgLDjgrAqBnXn8 qGgA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=mYGuQAF9; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-96375-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-96375-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id j29-20020a05620a0a5d00b0078825434bbfsi10781575qka.674.2024.03.07.16.06.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Mar 2024 16:06:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-96375-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=mYGuQAF9; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-96375-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-96375-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 778461C20E81 for ; Fri, 8 Mar 2024 00:06:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 724CA810; Fri, 8 Mar 2024 00:06:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="mYGuQAF9" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 881BC364; Fri, 8 Mar 2024 00:06:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709856367; cv=none; b=h838OpvpxFEvDCumQtYsdvosY7kLPIxNDohA8CWF1RvhhZ9SmPfOf4RfI1sFV/bqnjlFHF24wGp6Np74a/taTY90R6Bu5fALTZecmJmgW4GYgu6g8YNh1XwGTQrdf1XLT4qFutYduKb2ASlVUzKXn6DnfIxS7DbjRfy56w52i7E= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709856367; c=relaxed/simple; bh=44zl7rfKT4IfdYlB187fgWbtwbHF6PjnpC1W4yMdDIo=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=ktCpDfx7o91xQsWgRnV76vruz0KVXlsSHAu8UEkybP5H9fCbZisyIxBX+6y2X7ImqFqEVisTHobwVwj2DYmLgq60q/rx8YQRD8OcmwydJBIXbRB4uZqvRThr6vbA9lpLypJNkhzDFwG0lVRVfK7K15x4nhCKOyPTBtbjNkwQb/0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=mYGuQAF9; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0C7FDC433C7; Fri, 8 Mar 2024 00:06:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1709856367; bh=44zl7rfKT4IfdYlB187fgWbtwbHF6PjnpC1W4yMdDIo=; h=Date:From:To:Cc:Subject:Reply-To:References:In-Reply-To:From; b=mYGuQAF9LhM6og9CvmxgVC8xHcPsqW774Ij+nj5CqQxJ6/Do8PvIJfkDdjuluPDtX zwEGbATBwQo/l5YDRq6+BQD/1Os6OpjKncJQQoGH+b6P64rdeEGvkFqSKHgATxDrB9 1hcGg1S9+roihyx/2YAofMMOlu548z44+C20dAYPJ/h4eicGWBnSxS6AcGdcDH60WI 4jafaUAybp6JiXmeCa5xu5ww5oXEVySGpyspvq6PdQZJ6BZOvTV4+ltJ5TVavZFcGv vIy2o3lAG4PcSH3sMsjj+JsvP4erEm8mikBrqLtb+TxvsG8tqriUt9tB2xHGVTpjur 0fvFhXODBcK2Q== Received: by paulmck-ThinkPad-P17-Gen-1.home (Postfix, from userid 1000) id AB3B7CE0716; Thu, 7 Mar 2024 16:06:06 -0800 (PST) Date: Thu, 7 Mar 2024 16:06:06 -0800 From: "Paul E. McKenney" To: Joel Fernandes Cc: linux-kernel@vger.kernel.org, frederic@kernel.org, boqun.feng@gmail.com, urezki@gmail.com, neeraj.iitr10@gmail.com, rcu@vger.kernel.org, rostedt@goodmis.org, Neeraj Upadhyay , Josh Triplett , Mathieu Desnoyers , Lai Jiangshan , Zqiang Subject: Re: [PATCH] [RFC] rcu/tree: Reduce wake up for synchronize_rcu() common case Message-ID: Reply-To: paulmck@kernel.org References: <20240307234852.2132637-1-joel@joelfernandes.org> 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=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On Thu, Mar 07, 2024 at 06:52:14PM -0500, Joel Fernandes wrote: > On Thu, Mar 7, 2024 at 6:48 PM Joel Fernandes (Google) > wrote: > > > > In the synchronize_rcu() common case, we will have less than > > SR_MAX_USERS_WAKE_FROM_GP number of users per GP. Waking up the kworker > > is pointless just to free the last injected wait head since at that point, > > all the users have already been awakened. > > > > Introduce a new counter to track this and prevent the wakeup in the > > common case. > > > > Signed-off-by: Joel Fernandes (Google) > > --- > > Forgot to mention, this is based on the latest RCU -dev branch and > passes light rcutorture testing on all configs. Heavier rcutorture > testing (60 minutes) was performed on TREE03. Very good, thank you! Uladzislau, could you please pull this into the next series you send? I can then replace your commits in -rcu with the updated series. Thanx, Paul