From: Valentin Schneider <valentin.schneider@arm.com>
To: Peter Zijlstra <peterz@infradead.org>, Juri Lelli <juri.lelli@gmail.com>
Cc: Morten Rasmussen <morten.rasmussen@arm.com>,
mingo@redhat.com, dietmar.eggemann@arm.com,
vincent.guittot@linaro.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 6/7] sched: Rename root_domain->overload to should_idle_balance
Date: Fri, 16 Feb 2018 11:59:10 +0000 [thread overview]
Message-ID: <8d38ed15-9de2-4fe4-a95e-fe4ec1bee59c@arm.com> (raw)
In-Reply-To: <20180216094922.GY25201@hirez.programming.kicks-ass.net>
On 02/16/2018 09:49 AM, Peter Zijlstra wrote:
> On Fri, Feb 16, 2018 at 10:14:02AM +0100, Juri Lelli wrote:
>>> diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h
>>> index 7d324b706e67..4215438667e5 100644
>>> --- a/kernel/sched/sched.h
>>> +++ b/kernel/sched/sched.h
>>> @@ -650,8 +650,12 @@ struct root_domain {
>>> cpumask_var_t span;
>>> cpumask_var_t online;
>>>
>>> - /* Indicate more than one runnable task for any CPU */
>>> - bool overload;
>>> + /*
>>> + * Indicate whether the idle balance can be used to solve
>>> + * imbalance within the root domain.
>>> + * e.g. There is more than one runnable task for any CPU
>>> + */
>>> + bool should_idle_balance;
>>
>> Current name is however consistent with RT/DL's naming convention
I saw that it was already used elsewhere in fair but didn't know about
RT/DL, thanks for pointing that out.
>
> Yeah, not a fan either. We've consistently used the term to mean
> nr_running>1. The thing to fix there is the stupid bool, not the name.
>
So yeah the other thing that doesn't help here is that we're cramming
several meanings into rq->rd->overload:
- is there an overloaded group
- is there a group with misfit task(s)
So it didn't make sense to keep it named "overload". Perhaps a better way of
handling this would be to keep exposing which is which instead of merging it
all in a bool. Something along those lines:
@update_sg_lb_stats():
[...]
nr_running = rq->nr_running;
if (nr_running > 1)
- *overload = true;
+ sds->balance_status |= LB_STATUS_OVERLOAD
[...]
if (env->sd->flags & SD_ASYM_CPUCAPACITY &&
!sgs->group_misfit_task_load && rq->misfit_task_load) {
sgs->group_misfit_task_load = rq->misfit_task_load;
- *should_idle_balance = true;
+ sds->balance_status |= LB_STATUS_MISFIT
}
@update_sd_lb_stats():
[...]
if (!env->sd->parent) {
/* update overload indicator if we are at root domain */
- if (env->dst_rq->rd->overload != overload)
- env->dst_rq->rd->overload = overload;
+ if (env->dst_rq->rd->balance_status != sds->balance_status)
+ env->dst_rq->rd->balance_status = sds->balance_status
}
next prev parent reply other threads:[~2018-02-16 11:59 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-15 16:20 [PATCH 0/7] sched/fair: Migrate 'misfit' tasks on asymmetric capacity systems Morten Rasmussen
2018-02-15 16:20 ` [PATCH 1/7] sched: Add static_key for asymmetric cpu capacity optimizations Morten Rasmussen
2018-02-16 13:47 ` Peter Zijlstra
2018-02-16 15:41 ` Morten Rasmussen
2018-02-16 16:51 ` Peter Zijlstra
2018-02-19 11:49 ` Morten Rasmussen
2018-02-16 17:39 ` Quentin Perret
2018-02-16 17:43 ` Peter Zijlstra
2018-02-15 16:20 ` [PATCH 2/7] sched/fair: Add group_misfit_task load-balance type Morten Rasmussen
2018-02-19 13:56 ` Peter Zijlstra
2018-02-19 13:58 ` Peter Zijlstra
2018-02-20 16:01 ` Morten Rasmussen
2018-02-15 16:20 ` [PATCH 3/7] sched/fair: Consider misfit tasks when load-balancing Morten Rasmussen
2018-02-15 16:20 ` [PATCH 4/7] sched/fair: Avoid unnecessary balancing of asymmetric capacity groups Morten Rasmussen
2018-02-19 14:50 ` Peter Zijlstra
2018-02-19 14:53 ` Peter Zijlstra
2018-02-20 16:22 ` Morten Rasmussen
2018-02-19 15:10 ` Peter Zijlstra
2018-02-20 16:33 ` Morten Rasmussen
2018-02-20 18:26 ` Peter Zijlstra
2018-02-23 16:38 ` Morten Rasmussen
2018-02-23 16:47 ` Peter Zijlstra
2018-02-26 15:06 ` Morten Rasmussen
2018-02-15 16:20 ` [PATCH 5/7] sched/fair: Kick nohz balance if rq->misfit_task Morten Rasmussen
2018-02-15 16:20 ` [PATCH 6/7] sched: Rename root_domain->overload to should_idle_balance Morten Rasmussen
2018-02-16 9:14 ` Juri Lelli
2018-02-16 9:49 ` Peter Zijlstra
2018-02-16 11:59 ` Valentin Schneider [this message]
2018-02-15 16:20 ` [PATCH 7/7] sched/fair: Set sd->should_idle_balance when misfit Morten Rasmussen
2018-02-28 7:46 ` [PATCH 0/7] sched/fair: Migrate 'misfit' tasks on asymmetric capacity systems Gaku Inami
2018-03-01 11:59 ` Valentin Schneider
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=8d38ed15-9de2-4fe4-a95e-fe4ec1bee59c@arm.com \
--to=valentin.schneider@arm.com \
--cc=dietmar.eggemann@arm.com \
--cc=juri.lelli@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=morten.rasmussen@arm.com \
--cc=peterz@infradead.org \
--cc=vincent.guittot@linaro.org \
/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