Received: by 2002:ab2:3319:0:b0:1ef:7a0f:c32d with SMTP id i25csp716599lqc; Fri, 8 Mar 2024 09:34:26 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVryPEJsuJMO8YcyTVXbSmY9Nytnh+38ZNnHuXvMHwz54QWrwzcQuPNNSVdCyUIJmI650DH/plizm88PvJx637ONl3gntaYC9AC727k5g== X-Google-Smtp-Source: AGHT+IEVtbp+cJUZL3H75/uYPylz4pq+YSvS4Wp5dsFRFRkhqxx/J0kYSv4rtjxUWVY1j13CH3hv X-Received: by 2002:a2e:a26e:0:b0:2d3:7697:1ff5 with SMTP id k14-20020a2ea26e000000b002d376971ff5mr3827466ljm.34.1709919266418; Fri, 08 Mar 2024 09:34:26 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709919266; cv=pass; d=google.com; s=arc-20160816; b=VMVphmn972+HHNe9zNJalt5XDMwKsNOeFB6xi51+24vxklXWd6Tv1p/UV9njY3NU5M OKdUYcSSLIfDWYw079rUG744K3iNxUiMx2C3HQqBSXbb0lUuDBB5CyU7h8oM2uBB6lo2 Ts7oUpTqixhWtPsD1kjy4LZmg7nnWyw/0T0mKhPwxfgblzspx8qU/s4g0nO3DrfmKqw/ iP2ZywwoYMnyu4o5wUdEORW7S8C0Y16QY74Lpf3l3icFPrkhiAdntJyCFVwD1wRvZaFP eyfsg9A404B3ZA8S7v+DBHY3CSZfWgF1hoMPms1I33fFpLAiqmHsWBjj0gN9G7KrCWr4 2QYg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=YLEgHytLvHaZwqeMHCqC8Ki/7/3bQNN2P4aJjeTSI1o=; fh=8Ak/Znos/tkut7SLmN2Opsy7QwmljLO7oN0ZSbTfnZ8=; b=J+lz0LNQ+WRANx6SPp4KRmHE4FxmuCrbTljntvusi6U15rf/TUaTaOQ523tzqNdc20 uTRcKselYr7KDm4hJb6Qsclq7/gyKFt6YT/2uimJUXlMIS+xsDenVjTj93uwqTIPFmam /RIqH4gJF179n+J4jp5CdXXSrYeLAwPKC74G1NIRZIOfE6psx8gss7RH34RusYi1MEbI OFY7YV+cCdjO1DWlaQFSRVoNa2Ya4CYk/Mt1YRYMZNcs8yGUjniAFx+wA1kd+rZDln86 qrIg6HS950hM71e0cCe30PFFFNKTA+VSthxGZJC8ksGGU5YuzPb8xWMPZsv9+LVZV5Qq AlKw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=jzrr+Z75; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-97393-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-97393-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id h21-20020a170906591500b00a3ec1463a12si3931ejq.348.2024.03.08.09.34.26 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Mar 2024 09:34:26 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-97393-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=jzrr+Z75; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-97393-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-97393-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com 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 am.mirrors.kernel.org (Postfix) with ESMTPS id F0BC61F21AC0 for ; Fri, 8 Mar 2024 17:34:25 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 26C4F3BBE3; Fri, 8 Mar 2024 17:34:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="jzrr+Z75" Received: from mail-lf1-f53.google.com (mail-lf1-f53.google.com [209.85.167.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A94BF36D; Fri, 8 Mar 2024 17:34:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.53 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709919256; cv=none; b=jCqL7uB2iiRR/Yz1+5EMr2JrmE8DRZfUkm68LEuzmhiHlwYRgHHuk/3GSOEEqXuUrCbQFmzaYfaYgTU18NuZ8sYCtAiz5TQhkV3AnTl5JgocXBZr+irbAytZdWIyObmBanL++wiRhkQC6FsdB0rvFGf47753crqGF1dJsohafrs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709919256; c=relaxed/simple; bh=WoFOscuDpyEDpIlN2yM8YrqGAhCm1K6ezIayPoX8JFg=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=tCX1c1JXhazCnzGIfIV0/brJs4XqDz7ZZM4ThveHoWUTKNKhYa7BSWVK/AvJrtX+zcc9wOcF5QFIAoa8nWjKXXaSG8HDnA+jOL2hMquFsMq9Exqb4KVKXCzYnZz49r7wXwnCdGKPnOkWlmdRrU8Lg/vW4dDJu7/Wa4q4e4XD8Ww= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=jzrr+Z75; arc=none smtp.client-ip=209.85.167.53 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lf1-f53.google.com with SMTP id 2adb3069b0e04-512ed314881so2269500e87.2; Fri, 08 Mar 2024 09:34:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709919253; x=1710524053; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=YLEgHytLvHaZwqeMHCqC8Ki/7/3bQNN2P4aJjeTSI1o=; b=jzrr+Z75Ek4cVAc5DJ8tWgPVxBjVXOGXvDLuuYLza3+bjT0Xg5fkjL48d+sEJfOLtK JZzX7m4M86tzSPDMohnK6eTt+NRlyk7I8sBlgBpTNEbDN7ZXKF3nShJL+unvqfu7qTyX spNp7bkncq7O6VCML7dbZ+FsIrPB2GpBkcSzpG7F7O5915d9LKxms3JjC1N7PAAvCWRe FlXfYxBTKJKCMEMtc685buQ3e9rdGb3IA1JY2rRofcF6DNDTA7JwpbW05y0IysDW0nrL 04dS48zkb5VpY3YiVY7/ubZZ1ecT642JJ1/kc5LBWVyCDb6svD3UNY5BwUKMOrWVFCfU Ky+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709919253; x=1710524053; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=YLEgHytLvHaZwqeMHCqC8Ki/7/3bQNN2P4aJjeTSI1o=; b=gzdKR7n/5I/GXACNjkh0xs78fgvEwyvUAx1ceIpTcGaDkZwB7jYYfriNRiyZwCu3O1 HI8K2eKjTqAvtWabOrT8Sq/pN2lKBGKgj5ozqcQPDuZiagQ0yQWw1/kL+6YLZVVR1a7O bqVOwdaI9podVd9t4PwNqAS699NuM6oFsI1bFeZGsMv2rWWrxPQ4KzDbOx7FvtWYtdkV U6Suhzgq+k6lUZcjh8ojKQRKEpygw7x0JJ7eA72jf36UH2cgnHflgRGRAHgz6QVqrbJm 4ZjtkceW6R5S1DBdgEfm9Fr6hTF+EJdS+Y7U+SIRRsIUJ6VXho/gt1ozUzP7v9wZgFDC WiDQ== X-Forwarded-Encrypted: i=1; AJvYcCW56jLlVjyrHMII2OJCN52mf81QuzM+JPQ8fBCpiAEeorQPYLhstpq7lkqS82ZX2N5rZGsLAliIHyCR350XiU2u8tpWPwnbUIekfHOT X-Gm-Message-State: AOJu0YwCyoy211wfGYo9SoZa1QWbnPXn4HOW03GIh/aI8j8K2LHDKPFy 7M3h8gkLLA5/BXfoDhmgD/+CfKAoptGZGbukw7+lxXNwZHo/RhMW X-Received: by 2002:a05:6512:ac8:b0:513:8266:f5d7 with SMTP id n8-20020a0565120ac800b005138266f5d7mr4060066lfu.3.1709919252470; Fri, 08 Mar 2024 09:34:12 -0800 (PST) Received: from pc638.lan (host-185-121-47-193.sydskane.nu. [185.121.47.193]) by smtp.gmail.com with ESMTPSA id a23-20020a195f57000000b0051333e2f55dsm3150504lfj.159.2024.03.08.09.34.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Mar 2024 09:34:12 -0800 (PST) From: "Uladzislau Rezki (Sony)" To: "Paul E . McKenney" Cc: RCU , Neeraj upadhyay , Boqun Feng , Hillf Danton , Joel Fernandes , LKML , Uladzislau Rezki , Oleksiy Avramchenko , Frederic Weisbecker Subject: [PATCH v6 0/6] Reduce synchronize_rcu() latency(v6) Date: Fri, 8 Mar 2024 18:34:03 +0100 Message-Id: <20240308173409.335345-1-urezki@gmail.com> X-Mailer: git-send-email 2.39.2 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit This is v6. It is based on the Paul's "dev" branch: HEAD: f1bfe538c7970283040a7188a291aca9f18f0c42 please note, that patches should be applied from scratch, i.e. the v5 has to be dropped from the "dev". v5 -> v6: - Fix a race due to realising a wait-head from the gp-kthread; - Use our own private workqueue with WQ_MEM_RECLAIM to have at least one execution context. v5: https://lore.kernel.org/lkml/20240220183115.74124-1-urezki@gmail.com/ v4: https://lore.kernel.org/lkml/ZZ2bi5iPwXLgjB-f@google.com/T/ v3: https://lore.kernel.org/lkml/cd45b0b5-f86b-43fb-a5f3-47d340cd4f9f@paulmck-laptop/T/ v2: https://lore.kernel.org/all/20231030131254.488186-1-urezki@gmail.com/T/ v1: https://lore.kernel.org/lkml/20231025140915.590390-1-urezki@gmail.com/T/ Uladzislau Rezki (Sony) (6): rcu: Add data structures for synchronize_rcu() rcu: Reduce synchronize_rcu() latency rcu: Add a trace event for synchronize_rcu_normal() rcu: Support direct wake-up of synchronize_rcu() users rcu: Do not release a wait-head from a GP kthread rcu: Allocate WQ with WQ_MEM_RECLAIM bit set .../admin-guide/kernel-parameters.txt | 14 + include/trace/events/rcu.h | 27 ++ kernel/rcu/tree.c | 361 +++++++++++++++++- kernel/rcu/tree.h | 20 + kernel/rcu/tree_exp.h | 2 +- 5 files changed, 422 insertions(+), 2 deletions(-) -- 2.39.2