Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp2682007ybh; Mon, 16 Mar 2020 07:47:20 -0700 (PDT) X-Google-Smtp-Source: ADFU+vvkAlFivwY3f8lliXB3I5MUFsoiEVCQ5myGHYhE0WV8zKHRYwWwGcGSgv/wJfbrukVxWG0K X-Received: by 2002:a9d:7a7:: with SMTP id 36mr18266244oto.283.1584370040662; Mon, 16 Mar 2020 07:47:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584370040; cv=none; d=google.com; s=arc-20160816; b=NIyFlTKIDuONqloIngnAhMY805wOjV+IFgeO7ExFh6mBwSZHU3RoJI3cUXrR8iEno+ QSBHcfE5kYRiRsqCDE6Rautt2Bo3lzYrqHu7S0JFDPBV72HvbIABBw51pAEC9UfsV8Bg uDcsF2pyaUmBIX7ZDLqz8muTmlqYBYavQ3SHx2v8XG1xJ/tf9PBkTmLRUBSagpStekEH DbWzfvUt2M5PpRWSZCFzy1hSSWLKUyjufjSvlJ1hnVkxW6Jv6QWxc0cM8XxYLDJTzb61 B+yjjxxUu4AV2LJiixMKSVm28+GK2FPsFuocI5rH5xIh8FCeESE2ssW2YvoI5RvmhD9u LBhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=q0gIoM/AmdaxTbXXV4Lc9WryMa7QIFG9hsPKXA8CnUM=; b=RYan7RkEU4O7TDmk4lDHpSRpKGCetO/uoyFGvNCgGekKiirDzB2+29jQo3fE4IVmTl LHDvvGgXXFJM3X50LT/UIObNcvdy7zb0clbbf4/BXmpj8JXAc4O7eavRDXkvd/rYe5uE F/4pZ45ndIweY5d3tJ0MW9B537NfVI8IEDUEYU5NwcD6Tc4AVlXs9c5SXun3Wm2noSnt h1u886P4aIK59cFQEQlQshovhUlKWRHP1tbPpB5S+1VGouuNLjPbezMmWVvN9qrC77Iw CVhw5C5T1idZpeZxd9jX5gDhdaentcHu+TNU5J730l4YdrJ4i2ZXkLFDn2TRoMWxgdAY 0BLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i7S4vgbz; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id w21si83605oih.145.2020.03.16.07.47.02; Mon, 16 Mar 2020 07:47:20 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i7S4vgbz; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1731597AbgCPOpk (ORCPT + 99 others); Mon, 16 Mar 2020 10:45:40 -0400 Received: from mail.kernel.org ([198.145.29.99]:49796 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731555AbgCPOpj (ORCPT ); Mon, 16 Mar 2020 10:45:39 -0400 Received: from localhost (lfbn-ncy-1-985-231.w90-101.abo.wanadoo.fr [90.101.63.231]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D8B7020679; Mon, 16 Mar 2020 14:45:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1584369939; bh=ZSbltSbSiUmq6xIxQWgW2sb4hHSYglWKFRNFnwZUai0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=i7S4vgbzI3Wd7TMTGENsRPOoUnHYKDC8Hbu0QB8jAlv/ezS2LEnLbp9spR+6coyfZ hMq6E2ISggw/9ERyMFMWXW2T6yaYNhtQogAW7tFoSsc/1NBxx+YQgzx4v0vf5V9B/0 mzc47/PkO06kfQluyVnrKOpaoJ3oc+4TVXebvuLY= Date: Mon, 16 Mar 2020 15:45:36 +0100 From: Frederic Weisbecker To: "Paul E. McKenney" Cc: mutt@paulmck-ThinkPad-P72, rcu@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@fb.com, mingo@kernel.org, jiangshanlai@gmail.com, dipankar@in.ibm.com, akpm@linux-foundation.org, mathieu.desnoyers@efficios.com, josh@joshtriplett.org, tglx@linutronix.de, peterz@infradead.org, rostedt@goodmis.org, dhowells@redhat.com, edumazet@google.com, fweisbec@gmail.com, oleg@redhat.com, joel@joelfernandes.org Subject: Re: [PATCH RFC tip/core/rcu 0/16] Prototype RCU usable from idle, exception, offline Message-ID: <20200316144535.GA501@lenoir> References: <20200312181618.GA21271@paulmck-ThinkPad-P72> <20200313144145.GA31604@lenoir> <20200313154243.GU3199@paulmck-ThinkPad-P72> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200313154243.GU3199@paulmck-ThinkPad-P72> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 13, 2020 at 08:42:43AM -0700, Paul E. McKenney wrote: > On Fri, Mar 13, 2020 at 03:41:46PM +0100, Frederic Weisbecker wrote: > > On Thu, Mar 12, 2020 at 11:16:18AM -0700, Paul E. McKenney wrote: > > > Hello! > > > > > > This series provides two variants of Tasks RCU, a rude variant inspired > > > by Steven Rostedt's use of schedule_on_each_cpu(), and a tracing variant > > > requested by the BPF folks and perhaps also of use for other tracing > > > use cases. > > > > > > The tracing variant has explicit read-side markers to permit finite grace > > > periods even given in-kernel loops in PREEMPT=n builds It also protects > > > code in the idle loop, on exception entry/exit paths, and on the various > > > CPU-hotplug online/offline code paths, thus having protection properties > > > similar to SRCU. However, unlike SRCU, this variant avoids expensive > > > instructions in the read-side primitives, thus having read-side overhead > > > similar to that of preemptible RCU. > > > > > > There are of course downsides. The grace-period code can send IPIs to > > > CPUs, even when those CPUs are in the idle loop or in nohz_full userspace. > > > It is necessary to scan the full tasklist, much as for Tasks RCU. There > > > is a single callback queue guarded by a single lock, again, much as for > > > Tasks RCU. If needed, these downsides can be at least partially remedied > > > > So what we trade to fix the issues we are having with tracing against extended > > grace periods, we lose in CPU isolation. That worries me a bit as tracing can > > be thoroughly used with nohz_full and CPU isolation. > > First, disturbing nohz_full CPUs can be avoided by the sysadm simply > refusing to remove tracepoints while sensitive applications are running > on nohz_full CPUs. So, in that case we'll need to modify the tools such as perf tools to avoid releasing the related buffers until we are ready to do so. That's possible but it's kindof an ABI breakage. Also what if there is a long running service on that nohz full CPU polling on the networking card... Thanks.