2014-02-28 01:27:12

by Paul E. McKenney

[permalink] [raw]
Subject: [GIT PULL timers] Timer-wheel bandaids^Wcommits for 3.15

Hello, Thomas and Ingo,

This pull request contains latency bandaids^Woptimizations to the
timer-wheel code that are useful in conjunction with NO_HZ_FULL Kconfig
option. These optimizations reduce the jiffy-by-jiffy looping in cases
where there is either zero or one timers in the timer wheel, which is
a common case for NO_HZ_FULL "worker" CPUs that run almost entirely
in usermode for a single task.

This is of course no substitute for a more extensive reworking of the
timer-wheel code, but it does provide some simple patches that can
provide significant latency improvements for NO_HZ_FULL systems that
have CPUs that very rarely enter the kernel.

Thanx, Paul

These changes since commit 849401b66d305f3feb75b6db7459b95ad190552a:

tick: Fixup more fallout from hrtimer broadcast mode (2014-02-09 15:11:47 +0100)

are available in the git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git timers.2014.02.25a

for you to fetch changes up to aea369b959bef10d235cd0714789cd8b0fe170b8:

timers: Make internal_add_timer() update ->next_timer if ->active_timers == 0 (2014-02-25 12:39:01 -0800)

----------------------------------------------------------------
Oleg Nesterov (1):
timers: Make internal_add_timer() update ->next_timer if ->active_timers == 0

Paul E. McKenney (4):
timers: Track total number of timers in list
timers: Reduce __run_timers() latency for empty list
timers: Reduce future __run_timers() latency for newly emptied list
timers: Reduce future __run_timers() latency for first add to empty list

kernel/timer.c | 30 ++++++++++++++++++++++++++++--
1 file changed, 28 insertions(+), 2 deletions(-)


2014-02-28 05:07:39

by Mike Galbraith

[permalink] [raw]
Subject: Re: [GIT PULL timers] Timer-wheel bandaids^Wcommits for 3.15

On Thu, 2014-02-27 at 17:27 -0800, Paul E. McKenney wrote:
> Hello, Thomas and Ingo,
>
> This pull request contains latency bandaids^Woptimizations to the
> timer-wheel code that are useful in conjunction with NO_HZ_FULL Kconfig
> option. These optimizations reduce the jiffy-by-jiffy looping in cases
> where there is either zero or one timers in the timer wheel, which is
> a common case for NO_HZ_FULL "worker" CPUs that run almost entirely
> in usermode for a single task.

FWIW, these have seen quite a bit of runtime on various boxen, both in
day to day and piddle about -rt kernels, with zero attention grabbers.

-Mike

2014-02-28 16:10:44

by Paul E. McKenney

[permalink] [raw]
Subject: Re: [GIT PULL timers] Timer-wheel bandaids^Wcommits for 3.15

On Fri, Feb 28, 2014 at 06:06:38AM +0100, Mike Galbraith wrote:
> On Thu, 2014-02-27 at 17:27 -0800, Paul E. McKenney wrote:
> > Hello, Thomas and Ingo,
> >
> > This pull request contains latency bandaids^Woptimizations to the
> > timer-wheel code that are useful in conjunction with NO_HZ_FULL Kconfig
> > option. These optimizations reduce the jiffy-by-jiffy looping in cases
> > where there is either zero or one timers in the timer wheel, which is
> > a common case for NO_HZ_FULL "worker" CPUs that run almost entirely
> > in usermode for a single task.
>
> FWIW, these have seen quite a bit of runtime on various boxen, both in
> day to day and piddle about -rt kernels, with zero attention grabbers.

Thank you very much for your testing efforts, Mike!

Thanx, Paul