From: Peter Zijlstra <peterz@infradead.org>
To: Paul Jackson <pj@sgi.com>
Cc: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>,
linux-kernel@vger.kernel.org, Ingo Molnar <mingo@elte.hu>
Subject: Re: [PATCH 1/2] Customize sched domain via cpuset
Date: Tue, 01 Apr 2008 13:59:10 +0200 [thread overview]
Message-ID: <1207051150.8514.723.camel@twins> (raw)
In-Reply-To: <20080401065534.a6267b96.pj@sgi.com>
On Tue, 2008-04-01 at 06:55 -0500, Paul Jackson wrote:
> Interesting ...
>
> So, we have two flags here. One flag "sched_wake_idle_far" that will
> cause the current task to search farther for an idle CPU when it wakes
> up another task that needs a CPU on which to run, and the other flag
> "sched_balance_newidle_far" that will cause a soon-to-idle CPU to search
> farther for a task it might pull over and run, instead of going idle.
>
> I am tempted to ask if we should not elaborate this in one dimension,
> and simplify it in another dimension.
>
> First the simplification side: do we need both flags? Yes, they are
> two distinct cases in the code, but perhaps practical uses will always
> end up setting both flags the same way. If that's the case, then we
> are just burdening the user of these flags with understanding a detail
> that didn't matter to them: did a waking task or an idle CPU provoke
> the search? Do you have or know of a situation where you actually
> desire to enable one flag while disabling the other?
>
> For the elaboration side: your proposal has just two-level's of
> distance, near and far. Perhaps, as architectures become more
> elaborate and hierarchies deeper, we would want N-level's of distance,
> and the ability to request such load balancing for all levels "n"
> for our choice of "n" <= N.
>
> If we did both the above, then we might have a single per-cpuset file
> that took an integer value ... this "n". If (n == 0), that might mean
> no such balancing at all. If (n == 1), that might mean just the
> nearest balancing, for example, to the hyperthread within the same core,
> on some current Intel architectures. If (n == 2), then that might mean,
> on the same architectures, that balancing could occur across cores
> within the same package. If (n == 3) then that might mean, again on
> that architecture, that balancing could occur across packages on the
> same node board. As architectures evolve over time, the exact details
> of what each value of "n" mean would evolve, but always higher "n"
> would enable balancing across a wider portion of the system.
>
> Please understand I am just brain storming here. I don't know that
> the alternatives I considered above are preferrable or not to what
> your patch presents.
FWIW I like your suggestions.
next prev parent reply other threads:[~2008-04-01 11:59 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-01 11:26 [PATCH 1/2] Customize sched domain via cpuset Hidetoshi Seto
2008-04-01 11:40 ` Andi Kleen
2008-04-01 11:56 ` Peter Zijlstra
2008-04-01 13:29 ` Andi Kleen
2008-04-01 13:38 ` Peter Zijlstra
2008-04-01 11:48 ` Peter Zijlstra
2008-04-01 11:55 ` Paul Jackson
2008-04-01 11:59 ` Peter Zijlstra [this message]
2008-04-02 8:39 ` Hidetoshi Seto
2008-04-02 11:14 ` Paul Jackson
2008-04-03 3:21 ` Hidetoshi Seto
2008-04-03 10:46 ` Peter Zijlstra
2008-04-03 12:56 ` Paul Jackson
2008-04-03 13:14 ` Paul Jackson
2008-04-04 9:10 ` [PATCH 1/2] Customize sched domain via cpuset (v2) Hidetoshi Seto
2008-04-04 9:11 ` [PATCH 2/2] " Hidetoshi Seto
2008-04-10 14:53 ` Peter Zijlstra
2008-04-14 1:45 ` Hidetoshi Seto
2008-04-14 15:38 ` Paul Jackson
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=1207051150.8514.723.camel@twins \
--to=peterz@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=pj@sgi.com \
--cc=seto.hidetoshi@jp.fujitsu.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.