Skip to contentSkip to conversation

Timer-wheel bandaids^Wcommits for 3.15

GIT PULL Paul E. McKenney 2 participants 3 messages Feb 28, 2014

lore
Share & tools
lore
#0 lore raw

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(-)
#1 lore raw
Quoted 8 lines · Paul E. McKenney

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

#2 lore raw
Quoted 10 lines · Mike Galbraith
Quoted 8 lines · Paul E. McKenney

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.

Quoted 2 lines

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