From: Dietmar Eggemann <dietmar.eggemann@arm.com>
To: Juri Lelli <juri.lelli@arm.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
linux-kernel@vger.kernel.org,
Vincent Guittot <vincent.guittot@linaro.org>,
Ben Segall <bsegall@google.com>,
Morten Rasmussen <morten.rasmussen@arm.com>,
Yuyang Du <yuyang.du@intel.com>
Subject: Re: [RFC PATCH 3/3] sched/fair: Change @running of __update_load_avg() to @update_util
Date: Thu, 2 Jun 2016 18:27:39 +0100 [thread overview]
Message-ID: <57506C8B.4050407@arm.com> (raw)
In-Reply-To: <20160602092539.GD9340@e106622-lin>
On 02/06/16 10:25, Juri Lelli wrote:
[...]
>> @@ -2757,7 +2754,7 @@ __update_load_avg(u64 now, int cpu, struct sched_avg *sa,
>> weight * scaled_delta_w;
>> }
>> }
>> - if (update_util && running)
>> + if (update_util == 0x3)
>
> How about a define for these masks?
Something like this?
+#define UTIL_RUNNING 1
+#define UTIL_UPDATE 2
+
/*
* We can represent the historical contribution to runnable average as the
* coefficients of a geometric series. To do this we sub-divide our runnable
@@ -2724,7 +2727,7 @@ static u32 __compute_runnable_contrib(u64 n)
*/
static __always_inline int
__update_load_avg(u64 now, int cpu, struct sched_avg *sa,
- unsigned long weight, int update_util, struct cfs_rq *cfs_rq)
+ unsigned long weight, int util_flags, struct cfs_rq *cfs_rq)
{
u64 delta, scaled_delta, periods;
u32 contrib;
@@ -2775,7 +2778,7 @@ __update_load_avg(u64 now, int cpu, struct sched_avg *sa,
weight * scaled_delta_w;
}
}
- if (update_util == 0x3)
+ if (util_flags == (UTIL_UPDATE | UTIL_RUNNING))
sa->util_sum += scaled_delta_w * scale_cpu;
...
next prev parent reply other threads:[~2016-06-02 17:27 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-01 19:39 [RFC PATCH 0/3] Aggregate task utilization only on root cfs_rq Dietmar Eggemann
2016-06-01 19:39 ` [RFC PATCH 1/3] sched/fair: " Dietmar Eggemann
2016-06-02 9:23 ` Juri Lelli
2016-06-02 15:53 ` Dietmar Eggemann
2016-06-02 16:11 ` Juri Lelli
2016-06-01 19:39 ` [RFC PATCH 2/3] sched/fair: Sync se with " Dietmar Eggemann
2016-06-06 2:59 ` Leo Yan
2016-06-06 8:45 ` Dietmar Eggemann
2016-06-06 12:11 ` Vincent Guittot
2016-06-01 19:39 ` [RFC PATCH 3/3] sched/fair: Change @running of __update_load_avg() to @update_util Dietmar Eggemann
2016-06-01 20:11 ` Peter Zijlstra
2016-06-02 15:59 ` Dietmar Eggemann
2016-06-02 9:25 ` Juri Lelli
2016-06-02 17:27 ` Dietmar Eggemann [this message]
2016-06-03 10:56 ` Juri Lelli
2016-06-01 20:10 ` [RFC PATCH 0/3] Aggregate task utilization only on root cfs_rq Peter Zijlstra
2016-06-02 15:40 ` Dietmar Eggemann
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=57506C8B.4050407@arm.com \
--to=dietmar.eggemann@arm.com \
--cc=bsegall@google.com \
--cc=juri.lelli@arm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=morten.rasmussen@arm.com \
--cc=peterz@infradead.org \
--cc=vincent.guittot@linaro.org \
--cc=yuyang.du@intel.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
Powered by JetHome