public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Suresh Siddha <suresh.b.siddha@intel.com>
Cc: Venkatesh Pallipadi <venki@google.com>,
	LKML <linux-kernel@vger.kernel.org>,
	Gautham R Shenoy <ego@in.ibm.com>,
	Joel Schopp <jschopp@austin.ibm.com>,
	Michael Neuling <mikey@neuling.org>
Subject: Re: [PATCH] sched: Call update_group_power only for local_group
Date: Thu, 08 Jul 2010 19:55:55 +0200	[thread overview]
Message-ID: <1278611755.1900.169.camel@laptop> (raw)
In-Reply-To: <1278611416.2834.12.camel@sbs-t61.sc.intel.com>

On Thu, 2010-07-08 at 10:50 -0700, Suresh Siddha wrote:
> On Thu, 2010-07-08 at 10:49 -0700, Peter Zijlstra wrote:
> > On Thu, 2010-07-08 at 10:45 -0700, Suresh Siddha wrote:
> > >  
> > > @@ -2456,6 +2454,9 @@ static inline void update_sd_lb_stats(struct sched_domain *sd, int this_cpu,
> > >  	init_sd_power_savings_stats(sd, sds, idle);
> > >  	load_idx = get_sd_load_idx(sd, idle);
> > >  
> > > +	if (this_cpu == smp_processor_id())
> > > +		update_group_power(sd, this_cpu);
> > > +
> > >  	do {
> > >  		int local_group;
> > 
> > Which will break for nohz_idle_balance..
> 
> Then the logic is broken somewhere because update_group_power() reads
> APERF/MPERF MSR's which doesn't make sense when this_cpu !=
> smp_processor_id(). What am I missing?

The APERF/MPERF code is utterly broken.. (and currently disabled by
default) but yeah, that's one aspect of its brokenness I only realized
after your email.

The problem is that it measures current throughput, not current
capacity. So for an idle thread/core it would return 0, instead of the
potential.

I've been meaning to revisit this.. maybe I should simply rip that out
until I get it working.

I was thinking of measuring temporal maxima to approximate capacity
instead of throughput.

  reply	other threads:[~2010-07-08 17:56 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-01 23:12 [PATCH] sched: Call update_group_power only for local_group Venkatesh Pallipadi
2010-07-02  8:05 ` Peter Zijlstra
2010-07-02 16:20   ` Venkatesh Pallipadi
2010-07-02 16:40     ` Peter Zijlstra
2010-07-02 16:56       ` Venkatesh Pallipadi
2010-07-02 17:31         ` Peter Zijlstra
2010-07-08 14:12         ` Peter Zijlstra
2010-07-08 17:45           ` Suresh Siddha
2010-07-08 17:49             ` Peter Zijlstra
2010-07-08 17:50               ` Suresh Siddha
2010-07-08 17:55                 ` Peter Zijlstra [this message]
2010-07-08 18:16             ` Peter Zijlstra
2010-07-08 21:53               ` Suresh Siddha
2010-07-09 13:17                 ` Peter Zijlstra
2010-07-17 11:12                 ` [tip:sched/core] sched: Update rq->clock for nohz balanced cpus tip-bot for Suresh Siddha
2010-07-12 17:11               ` [PATCH] sched: Call update_group_power only for local_group Venkatesh Pallipadi
2010-07-17 11:12               ` [tip:sched/core] sched: Reduce update_group_power() calls tip-bot for Peter Zijlstra

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1278611755.1900.169.camel@laptop \
    --to=peterz@infradead.org \
    --cc=ego@in.ibm.com \
    --cc=jschopp@austin.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mikey@neuling.org \
    --cc=suresh.b.siddha@intel.com \
    --cc=venki@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox