From: george anzinger <george@mvista.com>
To: mbs <mbs@mc.com>
Cc: dank@kegel.com,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: Periodic clock tick considered harmful (was: Re: HZ, preferably as small as possible)
Date: Thu, 11 Jul 2002 13:25:22 -0700 [thread overview]
Message-ID: <3D2DE9B2.70A21F7E@mvista.com> (raw)
In-Reply-To: 200207111916.PAA08197@mc.com
mbs wrote:
>
> george,
>
> with the HRT is there any reason to have 10 timer interrupts per process
> quantum anymore? (10 ms ticks, 100 ms proc quantum)
First blush is HELL YES! The issue is accounting. When you
ask how long a program ran, you are looking at the
accounting that happens on a tick. This is where one of two
counters gets bumped (one for system, the other for user,
depending on what was interrupted). This information could,
of course, be gathered every system call/ exit and every
context switch, BUT, there are FAR more system calls and
context switches than 1/HZ ticks. Thus collecting
accounting info this way adds overhead as the system load
increases, a VERY BAD thing IMHO.
A second point is that tasks only run for a quantum IF they
never block or get preempted. Most tasks will have some
fraction of a quantum remaining when they are scheduled.
-g
>
> On Thursday 11 July 2002 15:06, george anzinger wrote:
> > Ah, but you haven't looked at all that happens on a 1/HZ
> > tick. The high-res-timers patch does NOT eliminate the 1/HZ
> > tick. That tick is used to do a LOT of accounting activity
> > which IMHO is best done by a periodic tick. In particular,
> > the time slice and execution time management depend on the
> > periodic tick. As a test we put together a tickless system,
> > much as suggested above, and put enough stuff in it to see
> > what the overhead was and how it changed. The conclusion
> > was that the timer over head increased far beyond the
> > current overhead as soon as the system load (actually the
> > number of context switches per second) increased beyond what
> > a moderately busy system experiences. In other words, the
> > system was overload prone. The current accounting activity
> > is flat WRT to context switching which is IMHO just what it
> > should be. For those who want to know, a patch to put that
> > test system together is still on the HRT sourceforge site.
> >
> > -g
> >
> > > OK, so I'm just an ignorant member of the peanut gallery, but
> > > I'd like to hear a real kernel hacker explain why this isn't
> > > the way to go.
> > >
> > > - Dan
>
> --
> /**************************************************
> ** Mark Salisbury || mbs@mc.com **
> ** If you would like to sponsor me for the **
> ** Mass Getaway, a 150 mile bicycle ride to for **
> ** MS, contact me to donate by cash or check or **
> ** click the link below to donate by credit card **
> **************************************************/
> https://www.nationalmssociety.org/pledge/pledge.asp?participantid=86736
--
George Anzinger george@mvista.com
High-res-timers:
http://sourceforge.net/projects/high-res-timers/
Real time sched: http://sourceforge.net/projects/rtsched/
Preemption patch:
http://www.kernel.org/pub/linux/kernel/people/rml
next prev parent reply other threads:[~2002-07-11 20:23 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-11 16:44 Periodic clock tick considered harmful (was: Re: HZ, preferably as small as possible) dank
2002-07-11 16:59 ` Thunder from the hill
2002-07-11 19:45 ` Arnd Bergmann
2002-07-11 17:05 ` Hubertus Franke
2002-07-11 19:06 ` george anzinger
2002-07-11 19:19 ` mbs
2002-07-11 20:25 ` george anzinger [this message]
2002-07-11 21:29 ` Periodic clock tick considered harmful (was: Re: HZ, preferably as Alan Cox
2002-07-11 21:43 ` george anzinger
2002-07-11 22:32 ` Periodic clock tick considered harmful (was: Re: HZ, preferably as small as possible) Karim Yaghmour
2002-07-15 5:21 ` Linus Torvalds
2002-07-15 5:43 ` Linus Torvalds
-- strict thread matches above, loose matches on Subject: below --
2002-07-11 21:28 Per Jessen
2002-07-16 9:10 Martin Schwidefsky
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=3D2DE9B2.70A21F7E@mvista.com \
--to=george@mvista.com \
--cc=dank@kegel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mbs@mc.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox