public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Nishanth Aravamudan <nacc@us.ibm.com>
To: john stultz <johnstul@us.ibm.com>
Cc: lkml <linux-kernel@vger.kernel.org>,
	Tim Schmielau <tim@physik3.uni-rostock.de>,
	George Anzinger <george@mvista.com>,
	albert@users.sourceforge.net,
	Ulrich Windl <ulrich.windl@rz.uni-regensburg.de>,
	Christoph Lameter <clameter@sgi.com>,
	Dominik Brodowski <linux@dominikbrodowski.de>,
	David Mosberger <davidm@hpl.hp.com>, Andi Kleen <ak@suse.de>,
	paulus@samba.org, schwidefsky@de.ibm.com,
	keith maanthey <kmannth@us.ibm.com>,
	Chris McDermott <lcm@us.ibm.com>, Max Asbock <masbock@us.ibm.com>,
	mahuja@us.ibm.com, Darren Hart <darren@dvhart.com>,
	"Darrick J. Wong" <djwong@us.ibm.com>,
	Anton Blanchard <anton@samba.org>,
	donf@us.ibm.com, mpm@selenic.com, benh@kernel.crashing.org
Subject: [RFC][PATCH 0/4] new timeofday-based soft-timer subsystem
Date: Tue, 17 May 2005 16:33:00 -0700	[thread overview]
Message-ID: <20050517233300.GE2735@us.ibm.com> (raw)
In-Reply-To: <1116029796.26454.2.camel@cog.beaverton.ibm.com>

On 13.05.2005 [17:16:35 -0700], john stultz wrote:
> All,
> 	This patch implements the architecture independent portion of the new
> time of day subsystem. For a brief description on the rework, see here:
> http://lwn.net/Articles/120850/ (Many thanks to the LWN team for that
> easy to understand writeup!)
> 
> 	I intend this to be the last RFC release and to submit this patch to
> Andrew for for testing near the end of this month. So please, if you
> have any complaints, suggestions, or blocking issues, let me know.

I have been working closely with John to re-work the soft-timer subsytem
to use the new timeofday() subsystem. The following patches attempts to
begin this process. I would greatly appreciate any comments.

Some design points:

1) The patch is small but does a lot.
a) Renames timer_jiffies to last_timer_time (now that we are not
	jiffies-based).
b) Converts the soft-timer time-vector's/bucket's entries to
	timerinterval (a new unit) width, instead of jiffy width.
c) Defines timerintervals to be the current time as reported by the new
	timeofday-subsystem shifted down by TIMERINTERVAL_BITS bits.
	Thus, various pseudo-'human time' units can be emulated.
d) Uses do_monotonic_clock() (converted to timerintervals) as the basis
	for addition and expiration of timers instead of jiffies.
e) Adds some new helper functions for dealing with nanosecond values.

2) The patch depends on John's timeofday core rework.  For arches that
will not have the new timeofday (or for which the rework is still in
progress), I can emulate the existing system with a separate patch (Such
a possible patch will follow). The goal of this patch, though, is just
to show how easy the new system can be implemented and the benefits. It
has been tested on x86 and x86_64 archs; there may be some issues with
ppc and ppc64 which I am working on resolving.

3) The reason for the re-work? Many people complain about all of the
adding of 1 jiffy here or there to fix bugs. This new systems is
fundamentally human-time oriented and deals with those issues correctly
and, more importantly, sanely :)

The code is reasonably well commented, but does expect readers to
understand the current soft-timer subsystem.

This is still an early working of this patch, so I expect criticism, and
am happy to make changes.

I will try to get some current benchmark differentials posted tomorrow.
The previous patch I released showed little difference between mainline,
John's timeofday rework and my soft-timer rework in kernbench.

Overview:

1/4: A small interdiff between John's current stack and what is
necessary for my patch to work. Moves timeofday.h architecture-specific
code to asm/timeofday.h. This is necessary for my patch.

2/4: Converts the soft-timer subsystem to use timerinterval as the units
of addition and expiration.

3/4: Converts, as an example, sys_nanosleep() to use the new interfaces
provided by patch 2. For instance, you (albeit somewhat rarely -- maybe
once out of every 100,000 requests) may get only 10 usecs of actual
sleep (instead of 2+ msecs no matter what).

4/4: Enables non-NEWTOD archs to use the same interfaces, with some
performance penalty (am working on a better alternative, this is just
a POC).

Thanks,
Nish

  parent reply	other threads:[~2005-05-17 23:35 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-14  0:16 [RFC][PATCH (1/7)] new timeofday subsystem (v A5) john stultz
2005-05-14  0:17 ` [RFC][PATCH (2/7)] new timeofday i386 arch specific changes " john stultz
2005-05-14  0:19   ` [RFC][PATCH (3/7)] new timeofday x86-64 " john stultz
2005-05-14  0:20     ` [RFC][PATCH (4/7)] new timeofday i386 and x86-64 timesources " john stultz
2005-05-14  0:22       ` [RFC][PATCH (5/7)] new timeofday ia64,ppc32,ppc64 and s390 arch specific hooks " john stultz
2005-05-14  0:23         ` [RFC][PATCH (6/7)] new timeofday ia64,ppc32,ppc64 and s390 timesources " john stultz
2005-05-14  0:27           ` [RFC][PATCH (7/7)] new timeofday i386 vsyscall proof of concept " john stultz
2005-05-16 21:53             ` john stultz
2005-05-14 19:55         ` IA64 implementation of timesource for new time of day subsystem Christoph Lameter
2005-05-15 10:22           ` James Courtier-Dutton
2005-05-15 10:17             ` Andi Kleen
2005-05-16 15:30               ` Chris Friesen
2005-05-16 17:34           ` john stultz
2005-05-16 18:09             ` Christoph Lameter
2005-05-16 18:45               ` john stultz
2005-05-16 18:55                 ` john stultz
2005-05-16 19:24                 ` Christoph Lameter
2005-05-16 19:29                   ` David Mosberger
2005-05-16 19:50                     ` john stultz
2005-05-16 20:27                       ` Christoph Lameter
2005-05-16 20:53                         ` john stultz
2005-05-16 20:58                           ` David Mosberger
2005-05-16 21:35                             ` john stultz
2005-05-16 21:53                               ` Christoph Lameter
2005-05-17  8:05                     ` Ulrich Windl
2005-05-16 18:52     ` [RFC][PATCH (3/7)] new timeofday x86-64 specific changes (v A5) john stultz
2005-05-17 23:33 ` Nishanth Aravamudan [this message]
2005-05-17 23:34   ` [RFC][PATCH 1/4] move arch-specific timeofday core to asm Nishanth Aravamudan
2005-05-17 23:36   ` [RFC][PATCH 2/4] convert soft-timer subsystem to timerintervals Nishanth Aravamudan
2005-05-18  8:21     ` [RFC][UPDATE PATCH " Nishanth Aravamudan
2005-05-18 15:59       ` Jonathan Corbet
2005-05-18 17:00         ` Nishanth Aravamudan
2005-05-17 23:37   ` [RFC][PATCH 3/4] convert sys_nanosleep() to use new soft-timer subsystem Nishanth Aravamudan
2005-05-17 23:38   ` [RFC][PATCH 4/4] support new soft-timer subsystem on non-NEWTOD archs Nishanth Aravamudan
2005-05-19 23:29   ` [RFC][PATCH 0/4] new timeofday-based soft-timer subsystem Nishanth Aravamudan

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=20050517233300.GE2735@us.ibm.com \
    --to=nacc@us.ibm.com \
    --cc=ak@suse.de \
    --cc=albert@users.sourceforge.net \
    --cc=anton@samba.org \
    --cc=benh@kernel.crashing.org \
    --cc=clameter@sgi.com \
    --cc=darren@dvhart.com \
    --cc=davidm@hpl.hp.com \
    --cc=djwong@us.ibm.com \
    --cc=donf@us.ibm.com \
    --cc=george@mvista.com \
    --cc=johnstul@us.ibm.com \
    --cc=kmannth@us.ibm.com \
    --cc=lcm@us.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@dominikbrodowski.de \
    --cc=mahuja@us.ibm.com \
    --cc=masbock@us.ibm.com \
    --cc=mpm@selenic.com \
    --cc=paulus@samba.org \
    --cc=schwidefsky@de.ibm.com \
    --cc=tim@physik3.uni-rostock.de \
    --cc=ulrich.windl@rz.uni-regensburg.de \
    /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