public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Hua Zhong" <hzhong@cisco.com>
To: <ddade@digitalstatecraft.com>, "Alan Cox" <alan@lxorguk.ukuu.org.uk>
Cc: <linux-kernel@vger.kernel.org>
Subject: Re: Is it bad to have lots of sleeping tasks?
Date: Fri, 24 Aug 2001 13:13:04 -0700	[thread overview]
Message-ID: <005a01c12cd9$2f153950$103147ab@cisco.com> (raw)
In-Reply-To: <E15aNCX-0006PH-00@the-village.bc.nu>

> Linus scheduler is pretty dire beyond about 8 runnable threads, but very
> good below that. It also has a refresh loop that is O(n) tasks, which is
> strange, and actually looks easily to eliminate.

So why not do it?  Or implement a nicer scheduler?  There are many good
ones.  There are o(1) schedulers that provide much better proportional
sharing.  They scale and also perform well even in "few running processes"
case.  They are also not hard to implement (I once implemented such a
scheduler with 100 lines of patch, and that fitted in the existing Linux
runqueue framework).  What's the resistence to scheduler changes?

> The critical bit is threads runnable at any given time. When that is low
as
> it is in almost all normal workloads the performance of the scheduler is
> very good indeed.
>
> > 2) If I have 1000 threads, and each calls sleep(), I assume that my
> ...
> > difference in the system's responsiveness?
>
> Read kernel/timer.c.
>
> Alan
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/


  reply	other threads:[~2001-08-24 20:14 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-08-24 19:39 Is it bad to have lots of sleeping tasks? Donald Dade
2001-08-24 20:05 ` Alan Cox
2001-08-24 20:13   ` Hua Zhong [this message]
2001-08-24 20:32     ` Kurt Garloff
2001-08-24 21:19       ` Alan Cox
2001-08-24 21:15     ` Alan Cox
     [not found] <3B8A88B0.FDCC5ACE@watson.ibm.com>
2001-08-27 19:18 ` Alan Cox

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='005a01c12cd9$2f153950$103147ab@cisco.com' \
    --to=hzhong@cisco.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=ddade@digitalstatecraft.com \
    --cc=linux-kernel@vger.kernel.org \
    /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