The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Byungchul Park <byungchul.park@lge.com>
To: Daniel Bristot de Oliveira <bristot@redhat.com>
Cc: <peterz@infradead.org>, <mingo@kernel.org>,
	<linux-kernel@vger.kernel.org>, <juri.lelli@gmail.com>,
	<rostedt@goodmis.org>, <kernel-team@lge.com>
Subject: Re: [PATCH v2] sched/deadline: Make find_later_rq() choose a closer cpu in topology
Date: Wed, 22 Mar 2017 11:46:20 +0900	[thread overview]
Message-ID: <20170322024620.GN11100@X58A-UD3R> (raw)
In-Reply-To: <7528b635-4a18-f449-ec70-f040a471c4f1@redhat.com>

On Tue, Mar 21, 2017 at 02:28:50PM +0100, Daniel Bristot de Oliveira wrote:
> On 03/21/2017 08:52 AM, Byungchul Park wrote:
> > When cpudl_find() returns any among free_cpus, the cpu might not be
> > closer than others, considering sched domain. For example:
> > 
> >    this_cpu: 15
> >    free_cpus: 0, 1,..., 14 (== later_mask)
> >    best_cpu: 0
> > 
> >    topology:
> > 
> >    0 --+
> >        +--+
> >    1 --+  |
> >           +-- ... --+
> >    2 --+  |         |
> >        +--+         |
> >    3 --+            |
> > 
> >    ...             ...
> > 
> >    12 --+           |
> >         +--+        |
> >    13 --+  |        |
> >            +-- ... -+
> >    14 --+  |
> >         +--+
> >    15 --+
> > 
> > In this case, it would be best to select 14 since it's a free cpu and
> > closest to 15(this_cpu). However, currently the code select 0(best_cpu)
> > even though that's just any among free_cpus. Fix it.
> 
> That is a nice patch! But I wonder what would be the behavior with your
> patch in the following hw:
> 
> # numactl --hardware
> available: 2 nodes (0-1)
> node 0 cpus: 0 2 4 6 8 10 12 14
> node 0 size: 16159 MB
> node 0 free: 15308 MB
> node 1 cpus: 1 3 5 7 9 11 13 15
> node 1 size: 16384 MB
> node 1 free: 15028 MB
> node distances:
> node   0   1
>   0:  10  21
>   1:  21  10

Hi,

In this case, I guess the topology looks like:

    0 --+
        +--+
    2 --+  |
           +-- ... --+
    4 --+  |         |
        +--+         |
    6 --+            |

    ...             ...

     9 --+           |
         +--+        |
    11 --+  |        |
            +-- ... -+
    13 --+  |
         +--+
    15 --+

And sched_domain would also reflect that. So the dl's push works well.
Do I miss something?

In addition, IMHO, it's not an issue for dl's push but one for building
sched_domains. Wrong?

Thanks,
Byungchul

  reply	other threads:[~2017-03-22  2:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-21  7:52 [PATCH v2] sched/deadline: Make find_later_rq() choose a closer cpu in topology Byungchul Park
2017-03-21 13:28 ` Daniel Bristot de Oliveira
2017-03-22  2:46   ` Byungchul Park [this message]
2017-03-22 12:37 ` Peter Zijlstra
2017-03-22 23:21   ` Byungchul Park

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=20170322024620.GN11100@X58A-UD3R \
    --to=byungchul.park@lge.com \
    --cc=bristot@redhat.com \
    --cc=juri.lelli@gmail.com \
    --cc=kernel-team@lge.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.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