Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2953281imm; Thu, 24 May 2018 19:47:57 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpYd5VEgJIYmrK/pnUpj4zjZfT/fjTwHqGLZvIJ2vyO0HynQ8LH3HbNQ549KyZtCiwmnYnF X-Received: by 2002:a63:9843:: with SMTP id l3-v6mr497114pgo.208.1527216476973; Thu, 24 May 2018 19:47:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527216476; cv=none; d=google.com; s=arc-20160816; b=j8isv2//rfQFYmNFcuz67CnJAQVzfcgxvVl1LMB7MfJXOuMYq0Uf1IBZAH3G1mCSZJ 3LRgJr8JHyctCuX6KP5HzVwsB28azbbpzqTRO8C2LEgHCm8q1058QhqF4lrtHhLSLuy9 OVyPv9YMYQN5fam6Dq6vJHU7Ot6TQwLhxewjzRoyjTWS9E38sd0iAHbKHICQfwlqCoMl oXISgIVKWdVneWA5kYxzk2MeNNTeFdLO9COCX+XjTdMTH/ylzeleLs76yx7JwXWFQmvK hk/wJ0a1h+93xDoUS8Ux+wCu7hDhhcqsS6349lQZJwxmveG6tiyTnvJeudfduia5MVBx baCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=hDat/aGNI6YidjPR5b81DlSnS2CW2Koz6/muCoAsKyE=; b=CzXcwa5iN4a8JUVJiQ3iOgYw0RswHaMaU3M/orK28Zchl7I/7DfoLmu1g9c625lrIH lpHtJOaEy1dDbjH/NAjPLByl8AXz2C1GmW+JYYobUsimM4MO+W0i9VdlcKbfliOsUncZ k9vPtI03R0IeFvypho63bQrTf4fuS4EB0/1tSUJceohEbDmz31KcHhk/N5FfT3DTdAGO Lu8WHn/EF0r2RWFpRd50vabgDLHNgS4K6hSXaqWtP95bnxDasIc1b4Xn5+nklAMTQsmg woh1ZU/P69iwoH57DCXYGo6LXBqFQA1zdvGCI5HEfTqSzcIqoUH15pGWDnANnw0oCvTb BoKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=I6t9KhGI; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e11-v6si5922573pgq.191.2018.05.24.19.47.42; Thu, 24 May 2018 19:47:56 -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=fail header.i=@infradead.org header.s=merlin.20170209 header.b=I6t9KhGI; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755278AbeEXX1L (ORCPT + 99 others); Thu, 24 May 2018 19:27:11 -0400 Received: from merlin.infradead.org ([205.233.59.134]:58808 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755048AbeEXX1K (ORCPT ); Thu, 24 May 2018 19:27:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=hDat/aGNI6YidjPR5b81DlSnS2CW2Koz6/muCoAsKyE=; b=I6t9KhGIQTRc1/XRpv24hlw40K SmYFVHEqpBWRKnPr0p2/A4hQsG0QC4zPuzw0Og7Vb1RNuNk3YPndigBLk1dUL3cGHAqfOKiXYEFw7 OSyTXVrLbI7FJYUBCPzefJwdIelfkvYeXhfzOezV2UmX1TFrrzQ+PA99OgTkQqYgPGHiSKeSAWtrL th8WRBMzt0WgUlqVGew+t2OPSbgNOj3SzIW3eZ8rTCQCwNoy1ov1PPn58LYVxdQY/3Hn2rckhmCRh OVOJtEkdN3kKVc/bPrxag2cIiMhof5FeJt5vMd4JEqM4pZQlAUgLIsR9L+RXekD5GXo8BFoWHM1kH +jRFKBBA==; Received: from static-50-53-52-16.bvtn.or.frontiernet.net ([50.53.52.16] helo=midway.dunlab) by merlin.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1fLzd7-0002WW-63; Thu, 24 May 2018 23:26:45 +0000 Subject: Re: [PATCH v4] rcu: Speed up calling of RCU tasks callbacks To: Steven Rostedt , Joel Fernandes Cc: LKML , "Paul E. McKenney" , Peter Zilstra , Ingo Molnar , Boqun Feng , byungchul.park@lge.com, kernel-team@android.com, Josh Triplett , Lai Jiangshan , Mathieu Desnoyers References: <20180524184946.5fa82d19@gandalf.local.home> <20180524231918.GA98334@joelaf.mtv.corp.google.com> <20180524192247.759f7572@gandalf.local.home> From: Randy Dunlap Message-ID: <076566f7-43ff-5cc8-03ba-ebde9c19418c@infradead.org> Date: Thu, 24 May 2018 16:26:38 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <20180524192247.759f7572@gandalf.local.home> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05/24/2018 04:22 PM, Steven Rostedt wrote: > On Thu, 24 May 2018 16:19:18 -0700 > Joel Fernandes wrote: > >> On Thu, May 24, 2018 at 06:49:46PM -0400, Steven Rostedt wrote: >>> >>> From: Steven Rostedt (VMware) >>> >>> Joel Fernandes found that the synchronize_rcu_tasks() was taking a >>> significant amount of time. He demonstrated it with the following test: >>> >>> # cd /sys/kernel/tracing >>> # while [ 1 ]; do x=1; done & >>> # echo '__schedule_bug:traceon' > set_ftrace_filter >>> # time echo '!__schedule_bug:traceon' > set_ftrace_filter; >>> >>> real 0m1.064s >>> user 0m0.000s >>> sys 0m0.004s >>> >>> Where it takes a little over a second to perform the synchronize, >>> because there's a loop that waits 1 second at a time for tasks to get >>> through their quiescent points when there's a task that must be waited >>> for. >>> >>> After discussion we came up with a simple way to wait for holdouts but >>> increase the time for each iteration of the loop but no more than a >>> full second. >>> >>> With the new patch we have: >>> >>> # time echo '!__schedule_bug:traceon' > set_ftrace_filter; >>> >>> real 0m0.131s >>> user 0m0.000s >>> sys 0m0.004s >>> >>> Which drops it down to 13% of what the original wait time was. >> >> Should be 90% of original? > > That would be if I said "drops it down X" but I said "drops it down to > X of what the original wait time was". And 0.131 is 13% of 1.064. :-) I think that you are confusing "drops it down to" with "drops it down by". You said the former. You should say the latter. IOW, I agree with Joel. >> Other than minor change log change, looks good to me: >> >> Reviewed-by: Joel Fernandes (Google) > > Awesome, thanks! > > -- Steve > -- ~Randy