Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S265265AbUAFC3c (ORCPT ); Mon, 5 Jan 2004 21:29:32 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S265273AbUAFC3c (ORCPT ); Mon, 5 Jan 2004 21:29:32 -0500 Received: from smtp7.hy.skanova.net ([195.67.199.140]:56820 "EHLO smtp7.hy.skanova.net") by vger.kernel.org with ESMTP id S265265AbUAFC3a (ORCPT ); Mon, 5 Jan 2004 21:29:30 -0500 To: Nick Piggin Cc: Con Kolivas , Tim Connors , linux-kernel@vger.kernel.org Subject: Re: xterm scrolling speed - scheduling weirdness in 2.6 ?! References: <200401041242.47410.kernel@kolivas.org> <200401041658.57796.kernel@kolivas.org> <3FFA1149.5030009@cyberone.com.au> From: Peter Osterlund Date: 06 Jan 2004 03:28:47 +0100 In-Reply-To: <3FFA1149.5030009@cyberone.com.au> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1737 Lines: 36 Nick Piggin writes: > Peter Osterlund wrote: > > >But the scheduler is also far from fair in this situation. If I run > > snip a good analysis... > > ... but fairness is not about a set of numbers the scheduler gives to > each process, its about the amount of CPU time processes are given. > > In this case I don't know if I find it objectionable that X and xterm > are considered interactive and perl considered a CPU hog. What is the > actual problem? The problem is that if perl would get only slightly more cpu time, it would get ahead of xterm, which would make this test case run something like 10 times faster than it currently does. (Because xterm switches to jump scrolling when it can't keep up.) I guess it would be possible to fix this by introducing a usleep(10000) at some strategic place in the xterm source code, but I still find it strange that two tasks eating 40% cpu time each are considered interactive, while a task eating 4% is considered a cpu hog, especially since the 4% task never got a chance to prove that it didn't want to steal all cpu time. All that was proven was that it wanted more than 4% of the cpu. Also, while my test case runs, other tasks (such as running "ps" from a network login) are very slow, at least until the extra load makes the scheduler realize that the two tasks eating most of the cpu time should not have maximum priority bonus. -- Peter Osterlund - petero2@telia.com http://w1.894.telia.com/~u89404340 - 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/