Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2952427imm; Thu, 24 May 2018 19:46:45 -0700 (PDT) X-Google-Smtp-Source: AB8JxZovJsTjndlz1eOoZ7wVauMyKL7/a4U0u59ajCAtf6qgL/rRXasYCiu9jWpDpQbxRXhEP963 X-Received: by 2002:a63:82c7:: with SMTP id w190-v6mr491596pgd.172.1527216405318; Thu, 24 May 2018 19:46:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527216405; cv=none; d=google.com; s=arc-20160816; b=fx+3sIJnWjN3hz2i1DRdH+NrCEEfpNkM4FxycWq/bR11Rt8I10ZQUtXNs1DtxkqHpx iraxQ82JQR2cEYja1XoW/SnOfECbB38hKniXz3zZG6XP2ffZsRg+iNJVJVDxWO5ochL8 2xiOmy6q1ffoXU73IVGm4WkKYSP/nUsJsZ3bRGmaxovRvUG9zOgYsKxkYiFzTCh+zo6X eydqRok3IS7xlZ4dULB0AX4/BbaxvNi9QkKxU/0wKsNtrLD0qMvLezAWw2e4/gGRZDCM zymkXkuiHKzMLrC+32kPh+25lRB3OW/9I52JCrLWfz0rI7zIhkRVeWZifi/VlpLcgGOU cVkg== 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:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :arc-authentication-results; bh=QaM2DDR/QmuOUuXQpyuQd7zSbtDtn24zYFM4EqzcbJ0=; b=ewehWAsZY+FjE6HCgctuiYlPFo/Az6Uel1U1ygYv0E3RQ3Mg/joWCQKHlD7/JNEsEd ENYkgL8rQMhQtOvQcTPIIJfXR6K/Lq+1hYACrs46bgdS9JIG2kjDgj3edHMbg24vINiL Ro0C1NyrD7DB7FWGSQBE+haC5mK/9AWuCj/0gXSlRDEaBZil2XsAJbDZwTtUq+OfyveQ D4pNu0VmuBHQwmxTFJGfITAfjbNQsXZY3gq+/6KsEACHEZu9VoN5wE5lEOBE5v/I9UCR vLsJgEOcR0fT7UiVpZOx83NQUD6BbJ8aNl6lrX293Wsfj59/JXU5UyIYWKOWC9xk5WB2 Yt2Q== ARC-Authentication-Results: i=1; mx.google.com; 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 o23-v6si448681pfi.302.2018.05.24.19.46.30; Thu, 24 May 2018 19:46:45 -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; 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 S1754986AbeEXXWy (ORCPT + 99 others); Thu, 24 May 2018 19:22:54 -0400 Received: from mail.kernel.org ([198.145.29.99]:38436 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751796AbeEXXWv (ORCPT ); Thu, 24 May 2018 19:22:51 -0400 Received: from gandalf.local.home (cpe-66-24-56-78.stny.res.rr.com [66.24.56.78]) (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 89C3E20870; Thu, 24 May 2018 23:22:49 +0000 (UTC) Date: Thu, 24 May 2018 19:22:47 -0400 From: Steven Rostedt To: 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 Subject: Re: [PATCH v4] rcu: Speed up calling of RCU tasks callbacks Message-ID: <20180524192247.759f7572@gandalf.local.home> In-Reply-To: <20180524231918.GA98334@joelaf.mtv.corp.google.com> References: <20180524184946.5fa82d19@gandalf.local.home> <20180524231918.GA98334@joelaf.mtv.corp.google.com> X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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. :-) > Other than minor change log change, looks good to me: > > Reviewed-by: Joel Fernandes (Google) Awesome, thanks! -- Steve