mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Zhaoxiu Zeng <zhaoxiu.zeng@gmail.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Ingo Molnar <mingo@redhat.com>,
	juri.lelli@redhat.com, vincent.guittot@linaro.org,
	dietmar.eggemann@arm.com, rostedt@goodmis.org,
	Benjamin Segall <bsegall@google.com>,
	mgorman@suse.de, bristot@redhat.com,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] schedule: SCHED_RR: Give a fresh time-slice to the task after after it suspends or relinquishes
Date: Fri, 24 Dec 2021 09:58:21 +0800	[thread overview]
Message-ID: <CAHb_TOmEE8Wu-Be3iPbL-FMkDeQf-2o_2B2Xt4tAwPyc7vNtmA@mail.gmail.com> (raw)
In-Reply-To: <YcMAuSFQazD4lBTC@hirez.programming.kicks-ass.net>

Peter Zijlstra <peterz@infradead.org> 于2021年12月22日周三 18:41写道:
>
> On Wed, Dec 22, 2021 at 05:15:26PM +0800, zhaoxiu.zeng wrote:
> > Assuming the sched_rr_timeslice is 100ms, there are several tasks with the
> > same priority t1, t2, t3, ..., and t1 sleeps every 80ms, the scheduling
> > timing may be:
> >     t1  t2   t3        t1  t2   t3        t1  t2   t3        t1  t2   t3
> >     80, 100, 100, ..., 20, 100, 100, ..., 60, 100, 100, ..., 40, 100, 100
> >
> > After applying this patch, the scheduling timing may be:
> >     t1  t2   t3        t1  t2   t3        t1  t2   t3        t1  t2   t3
> >     80, 100, 100, ..., 80, 100, 100, ..., 80, 100, 100, ..., 80, 100, 100
> >
>
> Is this what POSIX mandates or why are you sending this to me ?

Thanks for your reply!

I don't see a definition of this in POSIX.
Give a fresh time-slice may decreases context switches, and be more
fairly to the tasks which suspended then resumed.

  reply	other threads:[~2021-12-24  2:02 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-22  9:15 zhaoxiu.zeng
2021-12-22 10:40 ` Peter Zijlstra
2021-12-24  1:58   ` Zhaoxiu Zeng [this message]
2021-12-22 18:41 ` kernel test robot

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=CAHb_TOmEE8Wu-Be3iPbL-FMkDeQf-2o_2B2Xt4tAwPyc7vNtmA@mail.gmail.com \
    --to=zhaoxiu.zeng@gmail.com \
    --cc=bristot@redhat.com \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=juri.lelli@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.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

all inboxes | Powered by JetHome®