From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933700AbcA0Q2w (ORCPT ); Wed, 27 Jan 2016 11:28:52 -0500 Received: from resqmta-ch2-09v.sys.comcast.net ([69.252.207.41]:41488 "EHLO resqmta-ch2-09v.sys.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932900AbcA0Q2t (ORCPT ); Wed, 27 Jan 2016 11:28:49 -0500 Date: Wed, 27 Jan 2016 10:28:48 -0600 (CST) From: Christoph Lameter X-X-Sender: cl@east.gentwo.org To: Frederic Weisbecker cc: Michal Hocko , Mike Galbraith , Peter Zijlstra , LKML Subject: Re: fast path cycle muncher (vmstat: make vmstat_updater deferrable again and shut down on idle) In-Reply-To: <1453864347.3622.10.camel@gmail.com> Message-ID: References: <20160121165148.GF29520@dhcp22.suse.cz> <20160122140418.GB19465@dhcp22.suse.cz> <20160122161201.GC19465@dhcp22.suse.cz> <1453566115.3529.8.camel@gmail.com> <20160125174224.GH23934@dhcp22.suse.cz> <20160125201319.GA19020@dhcp22.suse.cz> <1453833078.3534.59.camel@gmail.com> <1453833939.3534.68.camel@gmail.com> <1453864347.3622.10.camel@gmail.com> Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 27 Jan 2016, Mike Galbraith wrote: > > Since we (the NOHZ people) care mostly about NOHZ then lets restrict > > that to the NOHZ mode. Then it should not affect your load. > > Tons of folks do have NO_HZ enabled (including me). Isn't there a spot > somewhere in NO_HZ_FULL code where it can take up residence? (one with > a tad lower maximum call frequency would be good, a nohz_full cpu isn't > necessarily being used for pure compute exclusively) Frederic, any idea on where to put quiet_vmstat()? > > Subject: Move quiet_vmstat() to NOHZ code > > > > quiet_vmstat() seems to cause regressions for some load because > > the cpu going idle is a "fastpath". Mind boogling. Strange claim. > > If the system goes idle then it has nothing to do after all > > > > But anyways if we shift the quiet_vmstat() into the NOHZ logic > > when it stops the tick then it will only affect those cores that > > are setup for NOHZ mode. That is where we want this processing > > after all to ensure that the OS keeps itself off those cores. > > > > Signed-off-by: Christoph Lameter > > > > > > Index: linux/kernel/sched/idle.c > > =================================================================== > > --- linux.orig/kernel/sched/idle.c > > +++ linux/kernel/sched/idle.c > > @@ -213,7 +213,6 @@ static void cpu_idle_loop(void) > > */ > > > > __current_set_polling(); > > - quiet_vmstat(); > > tick_nohz_idle_enter(); > > > > while (!need_resched()) { > > Index: linux/kernel/time/tick-sched.c > > =================================================================== > > --- linux.orig/kernel/time/tick-sched.c > > +++ linux/kernel/time/tick-sched.c > > @@ -811,6 +811,7 @@ static void __tick_nohz_idle_enter(struc > > ts->idle_calls++; > > > > expires = tick_nohz_stop_sched_tick(ts, now, cpu); > > + quiet_vmstat(); > > if (expires.tv64 > 0LL) { > > ts->idle_sleeps++; > > ts->idle_expires = expires; >