[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANRm+Czabiyv2donHAzGw-fqhEgdkcTgpaqSB4AapY0qTQARkQ@mail.gmail.com>
Date: Mon, 22 Aug 2016 10:31:40 +0800
From: Wanpeng Li <kernellwp@...il.com>
To: Morten Rasmussen <morten.rasmussen@....com>
Cc: Steve Muckle <steve.muckle@...aro.org>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Linux PM list <linux-pm@...r.kernel.org>,
"Rafael J . Wysocki" <rafael@...nel.org>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
Juri Lelli <Juri.Lelli@....com>,
Patrick Bellasi <patrick.bellasi@....com>,
Steve Muckle <smuckle@...aro.org>
Subject: Re: [PATCH] sched: fix incorrect PELT values on SMT
2016-08-19 23:30 GMT+08:00 Morten Rasmussen <morten.rasmussen@....com>:
> Hi Steve,
>
> On Thu, Aug 18, 2016 at 06:55:41PM -0700, Steve Muckle wrote:
>> PELT scales its util_sum and util_avg values via
>> arch_scale_cpu_capacity(). If that function is passed the CPU's sched
>> domain then it will reduce the scaling capacity if SD_SHARE_CPUCAPACITY
>> is set. PELT does not pass in the sd however. The other caller of
>> arch_scale_cpu_capacity, update_cpu_capacity(), does. This means
>> util_sum and util_avg scale beyond the CPU capacity on SMT.
>>
>> On an Intel i7-3630QM for example rq->cpu_capacity_orig is 589 but
>> util_avg scales up to 1024.
>
> I can't convince myself whether this is the right thing to do. SMT is a
> bit 'special' and it depends on how you model SMT capacity.
>
> I'm no SMT expert, but the way I understand the current SMT capacity
> model is that capacity_orig represents the capacity of the SMT-thread
> when all its thread-siblings are busy. The true capacity of an
> SMT-thread where all thread-siblings are idle is actually 1024, but we
> don't model this (it would be nightmare to track when the capacity
> should change). The capacity of a core with two or more SMT-threads is
> chosen to be 1024 + smt_gain, where smt_gain is supposed represent the
> additional throughput we gain for the additional SMT-threads. The reason
> why we don't have 1024 per thread is that we would prefer to have only
> one task per core if possible.
Agreed, maybe the capacity of an SMP-thread where all thread-siblings
are idle can be 1024 + smt_gain after latest IA technology.
http://www.intel.com/content/www/us/en/architecture-and-technology/turbo-boost/turbo-boost-max-technology.html
Regards,
Wanpeng Li
Powered by blists - more mailing lists