All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vincent Guittot <vincent.guittot@linaro.org>
To: mingo@redhat.com, peterz@infradead.org, juri.lelli@redhat.com,
	dietmar.eggemann@arm.com, rostedt@goodmis.org,
	bsegall@google.com, mgorman@suse.de, bristot@redhat.com,
	linux-kernel@vger.kernel.org, joel@joelfernandes.org,
	valentin.schneider@arm.com
Cc: fweisbec@gmail.com, tglx@linutronix.de, qais.yousef@arm.com,
	Vincent Guittot <vincent.guittot@linaro.org>
Subject: [PATCH 0/7 v2] move update blocked load outside newidle_balance
Date: Fri, 12 Feb 2021 14:28:42 +0100	[thread overview]
Message-ID: <20210212132849.32515-1-vincent.guittot@linaro.org> (raw)

Joel reported long preempt and irq off sequence in newidle_balance because
of a large number of CPU cgroups in use and having to be updated. This
patchset moves the update outside newidle_imblance. This enables to early
abort during the updates in case of pending irq as an example.

Instead of kicking a normal ILB that will wakes up CPU which is already
idle, patch 6 triggers the update of statistics in the idle thread of
the CPU before selecting and entering an idle state.

change on v2:
- Fixed some typos and updated some comments
- Added more cleanup
- Changed to way to trigger ILB in idle thread context to remove a possible
  race condition between the normal softirq ILB and this new mecanism. The
  cpu can already be set in idle_cpus_mask because even if the cpu is added
  later when entering idle, it might not have been removed yet from previous
  idle phase.
  
Vincent Guittot (7):
  sched/fair: remove update of blocked load from newidle_balance
  sched/fair: remove unused return of _nohz_idle_balance
  sched/fair: remove unused parameter of update_nohz_stats
  sched/fair: merge for each idle cpu loop of ILB
  sched/fair: reorder newidle_balance pulled_task tests
  sched/fair: trigger the update of blocked load on newly idle cpu
  sched/fair: reduce the window for duplicated update

 kernel/sched/fair.c  | 114 ++++++++++++++++---------------------------
 kernel/sched/idle.c  |   6 +++
 kernel/sched/sched.h |   3 ++
 3 files changed, 51 insertions(+), 72 deletions(-)

-- 
2.17.1


             reply	other threads:[~2021-02-12 13:30 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-12 13:28 Vincent Guittot [this message]
2021-02-12 13:28 ` [PATCH 1/7 v2] sched/fair: remove update of blocked load from newidle_balance Vincent Guittot
2021-02-12 13:28 ` [PATCH 2/7 v2] sched/fair: remove unused return of _nohz_idle_balance Vincent Guittot
2021-02-12 13:28 ` [PATCH 3/7 v2] sched/fair: remove unused parameter of update_nohz_stats Vincent Guittot
2021-02-12 13:28 ` [PATCH 4/7 v2] sched/fair: merge for each idle cpu loop of ILB Vincent Guittot
2021-02-12 13:28 ` [PATCH 5/7 v2] sched/fair: reorder newidle_balance pulled_task tests Vincent Guittot
2021-02-12 13:28 ` [PATCH 6/7 v2] sched/fair: trigger the update of blocked load on newly idle cpu Vincent Guittot
2021-02-12 13:28 ` [PATCH 7/7 v2] sched/fair: reduce the window for duplicated update Vincent Guittot

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=20210212132849.32515-1-vincent.guittot@linaro.org \
    --to=vincent.guittot@linaro.org \
    --cc=bristot@redhat.com \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=fweisbec@gmail.com \
    --cc=joel@joelfernandes.org \
    --cc=juri.lelli@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=qais.yousef@arm.com \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    --cc=valentin.schneider@arm.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.