From: "Martin J. Bligh" <mbligh@aracnet.com>
To: Maciej Soltysiak <solt@dns.toxicfilms.tv>
Cc: Andrew Morton <akpm@digeo.com>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: 2.5.70-mm6
Date: Mon, 09 Jun 2003 11:51:30 -0700 [thread overview]
Message-ID: <51250000.1055184690@flay> (raw)
In-Reply-To: <Pine.LNX.4.51.0306092017390.25458@dns.toxicfilms.tv>
>> If you don't nice the hell out of X, does it work OK?
> No.
>
> The way I reproduce the sound skips:
> run xmms, run evolution, compose a mail with gpg.
> on mm6 the gpg part stops the sound for a few seconds. (with X -10 and 0)
> on mm5 xmms plays without stops. (with X -10)
Does this (from Ingo?) do anything useful to it?
diff -urpN -X /home/fletch/.diff.exclude 400-reiserfs_dio/kernel/sched.c 420-sched_interactive/kernel/sched.c
--- 400-reiserfs_dio/kernel/sched.c Fri May 30 19:26:34 2003
+++ 420-sched_interactive/kernel/sched.c Fri May 30 19:28:06 2003
@@ -89,6 +89,8 @@ int node_threshold = 125;
#define STARVATION_LIMIT (starvation_limit)
#define NODE_THRESHOLD (node_threshold)
+#define TIMESLICE_GRANULARITY (HZ/20 ?: 1)
+
/*
* If a task is 'interactive' then we reinsert it in the active
* array after it has expired its current timeslice. (it will not
@@ -1365,6 +1367,27 @@ void scheduler_tick(int user_ticks, int
enqueue_task(p, rq->expired);
} else
enqueue_task(p, rq->active);
+ } else {
+ /*
+ * Prevent a too long timeslice allowing a task to monopolize
+ * the CPU. We do this by splitting up the timeslice into
+ * smaller pieces.
+ *
+ * Note: this does not mean the task's timeslices expire or
+ * get lost in any way, they just might be preempted by
+ * another task of equal priority. (one with higher
+ * priority would have preempted this task already.) We
+ * requeue this task to the end of the list on this priority
+ * level, which is in essence a round-robin of tasks with
+ * equal priority.
+ */
+ if (!(p->time_slice % TIMESLICE_GRANULARITY) &&
+ (p->array == rq->active)) {
+ dequeue_task(p, rq->active);
+ set_tsk_need_resched(p);
+ p->prio = effective_prio(p);
+ enqueue_task(p, rq->active);
+ }
}
out_unlock:
spin_unlock(&rq->lock);
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
next prev parent reply other threads:[~2003-06-09 18:51 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-06-07 22:14 2.5.70-mm6 Andrew Morton
2003-06-08 0:37 ` 2.5.70-mm6 Alexander Hoogerhuis
2003-06-08 0:56 ` 2.5.70-mm6 Andrew Morton
2003-06-08 1:13 ` 2.5.70-mm6 Alexander Hoogerhuis
2003-06-08 12:25 ` 2.5.70-mm6 Christoph Hellwig
2003-06-08 12:09 ` 2.5.70-mm6 Felipe Alfaro Solana
2003-06-08 22:52 ` 2.5.70-mm6 Pasi Savolainen
2003-06-09 17:45 ` 2.5.70-mm6 Maciej Soltysiak
2003-06-09 17:39 ` 2.5.70-mm6 Martin J. Bligh
2003-06-09 18:19 ` 2.5.70-mm6 Maciej Soltysiak
2003-06-09 18:51 ` Martin J. Bligh [this message]
2003-06-09 19:42 ` 2.5.70-mm6 Maciej Soltysiak
2003-06-09 20:04 ` 2.5.70-mm6 William Lee Irwin III
2003-06-10 8:54 ` 2.5.70-mm6 Maciej Soltysiak
2003-06-10 9:20 ` 2.5.70-mm6 William Lee Irwin III
2003-06-10 11:31 ` 2.5.70-mm6 Mike Galbraith
2003-06-10 11:41 ` 2.5.70-mm6 William Lee Irwin III
2003-06-10 11:51 ` Sharing Boottime allocated memory with user-space processes ZCane, Ed (Test Purposes)
2003-06-10 18:53 ` 2.5.70-mm6 Mike Galbraith
2003-06-10 19:11 ` 2.5.70-mm6 William Lee Irwin III
2003-06-10 11:52 ` 2.5.70-mm6 Maciej Soltysiak
2003-06-09 20:08 ` 2.5.70-mm6 Felipe Alfaro Solana
2003-06-09 20:14 ` 2.5.70-mm6 Martin J. Bligh
2003-06-09 21:09 ` 2.5.70-mm6 Felipe Alfaro Solana
2003-06-10 9:56 ` 2.5.70-mm6 Felipe Alfaro Solana
2003-06-09 18:39 ` 2.5.70-mm6 Felipe Alfaro Solana
2003-06-09 18:06 ` 2.5.70-mm6 Alistair J Strachan
2003-06-09 18:36 ` 2.5.70-mm6 Felipe Alfaro Solana
2003-06-09 19:07 ` 2.5.70-mm6 Pasi Savolainen
2003-06-11 2:15 ` 2.5.70-mm6 Mingming Cao
2003-06-11 3:12 ` 2.5.70-mm6 Andrew Morton
2003-06-11 22:15 ` 2.5.70-mm6 Mingming Cao
2003-06-12 16:37 ` 2.5.70-mm6 Mingming Cao
2003-06-12 17:50 ` 2.5.70-mm6 Andrew Morton
2003-06-12 18:43 ` 2.5.70-mm6 Mingming Cao
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=51250000.1055184690@flay \
--to=mbligh@aracnet.com \
--cc=akpm@digeo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=solt@dns.toxicfilms.tv \
/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