linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Guennadi Liakhovetski <g.liakhovetski@ragingbull.com>
To: Alexander Viro <viro@math.psu.edu>
Cc: Nathan Paul Simons <npsimons@fsmlabs.com>, linux-kernel@vger.kernel.org
Subject: Re: system call for process information?
Date: Tue, 13 Mar 2001 09:55:33 +0000 (GMT)	[thread overview]
Message-ID: <Pine.LNX.4.21.0103130945460.507-100000@erdos.shef.ac.uk> (raw)
In-Reply-To: <Pine.GSO.4.21.0103122202270.28460-100000@weyl.math.psu.edu>

Hi Alexander, Nathan and all!

Thanks for your great answers! First of all - I was not REALLY proposing
to include this system call in the kernel - I just wanted to hear some pro
and contra - so, thanks again for your explanations! I started yesterday
sketching the required functions, will have to retreat to reading top & ps
sources, btw, apart from these 2 obvious sources, what else would you
suggest to look through for a good implementation of CPU-utilization
calculator as well as other process (multithreaded, SMP,...) statistics?
Portable (POSIX), maybe some documentation, not just sources?

Thanks
Guennadi

On Mon, 12 Mar 2001, Alexander Viro wrote:

> On Mon, 12 Mar 2001, Nathan Paul Simons wrote:
> 
> > On Mon, Mar 12, 2001 at 09:21:37PM +0000, Guennadi Liakhovetski wrote:
> > > CPU utilisation. Each new application has to calculate it (ps, top, qps,
> > > kps, various sysmons, procmons, etc.). Wouldn't it be worth it having a
> > > syscall for that? Wouldn't it be more optimal?
> 
> The first rule of optimization: don't. I.e. optimizing something that
> is not a bottleneck is pointless.
> 
> > 	No, it wouldn't be worth it because you're talking about 
> > sacrificing simplicity and kernel speed in favor of functionality.
> 
> Or, in that case, in favour of nothing. It doesn't add any functionality.
> 
> > This has been know to lead to "bloat-ware".  Every new syscall you
> > add takes just a little bit more time and space in the kernel, and
> > when only a small number of programs will be using it, it's really 
> > not worth it.  This time and space may not be large, but once you
> > get _your_ syscall added, why can't everyone else get theirs added 
> > as well?  And so, after making about a thousand specialized syscalls
> > standard in the kernel, you end up with IRIX (from what I've heard).
> 
> 	In that case there is much simpler argument.
> 
> If your program checks the system load so often that converting results
> from ASCII to integers takes noticable time - all you are measuring
> is the load created by that program. In other words, any program that
> would get any speedup from such syscall is absolutely worthless, since
> the load created by measurement will drown the load you are trying
> to measure.
> 
> 	End of story. It's not only unnecessary and tasteless, it's
> useless. 
> 								Cheers,
> 									Al
> 
> 

___

Dr. Guennadi V. Liakhovetski
Department of Applied Mathematics
University of Sheffield, U.K.
email: G.Liakhovetski@sheffield.ac.uk



  reply	other threads:[~2001-03-13  9:52 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-03-12 17:08 system call for process information? Guennadi Liakhovetski
2001-03-12 18:27 ` Alexander Viro
2001-03-12 21:21   ` Guennadi Liakhovetski
2001-03-13  2:56     ` Nathan Paul Simons
2001-03-13  3:20       ` Alexander Viro
2001-03-13  9:55         ` Guennadi Liakhovetski [this message]
2001-03-13 21:05       ` Albert D. Cahalan
2001-03-13 22:02         ` Nathan Paul Simons
2001-03-13 22:50           ` Albert D. Cahalan
2001-03-13 22:52         ` Rik van Riel
2001-03-14  1:53           ` Martin Dalecki
2001-03-14  2:28             ` Rik van Riel
2001-03-14  8:24               ` george anzinger
2001-03-14 19:19                 ` Rik van Riel
2001-03-14 16:27                   ` george anzinger
2001-03-15 12:24                   ` changing mm->mmap_sem (was: Re: system call for process information?) Rik van Riel
2001-03-16  9:49                     ` Stephen C. Tweedie
2001-03-16 11:50                       ` Rik van Riel
2001-03-16 12:53                         ` Stephen C. Tweedie
2001-03-18  7:23                           ` Rik van Riel
2001-03-18  9:56                             ` Mike Galbraith
2001-03-18 10:46                               ` Rik van Riel
2001-03-18 12:33                                 ` Mike Galbraith
2001-03-14  1:59           ` system call for process information? john slee
2001-03-14 19:53   ` Szabolcs Szakacsits
2001-03-14 19:55     ` Alexander Viro
2001-03-14 20:23       ` Szabolcs Szakacsits
2001-03-14 20:21         ` Alexander Viro
2001-03-13 12:17 Rajiv Majumdar

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=Pine.LNX.4.21.0103130945460.507-100000@erdos.shef.ac.uk \
    --to=g.liakhovetski@ragingbull.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=npsimons@fsmlabs.com \
    --cc=viro@math.psu.edu \
    /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;
as well as URLs for NNTP newsgroup(s).