Date: Tue, 9 Mar 2004 11:41:12 -0500 (EST) From: Robert Watson <rwatson@freebsd.org> To: Bin Ren <br260@cam.ac.uk> Cc: freebsd-current@freebsd.org Subject: Re: a serious error in sched_ule.c? Message-ID: <Pine.NEB.3.96L.1040309113959.26895J-100000@fledge.watson.org> In-Reply-To: <E1B0gU0-0004ly-9M.--1c41a3d54c4fc50bd9d924e41c4ca767a2f5dfd9@maroon.csi.cam.ac.uk>
next in thread | previous in thread | raw e-mail | index | archive | help
On 9 Mar 2004, Bin Ren wrote: > Hi, all: > > I've been reading sched_ule.c and seem to find a serious error: > > in 'sched_slice()': > > * Rationale: > * KSEs in interactive ksegs get the minimum slice so that we > * quickly notice if it abuses its advantage. > > Then, there is: > > if (!SCHED_INTERACTIVE(kg)) { > ..... > ..... > } else > ke->ke_slice = SCHED_SLICE_INTERACTIVE; > > Then, at the beginning of the file, there is: > > #define SCHED_SLICE_INTERACTIVE (slice_max) > > > (slice_max) for interactive KSEs???? Either this is a serious mistake or > I'm seriously missing sth here. I believe this is a synchronization error in the comment and the code. The code was changed to provide a maximum slice to interactive applications because non-CPU intensive X11 applications will be marked as interactive, but redraws get interrupted in a short slice. When the change went in to increase the time slice I saw an observable improvement in the redraws of X11 apps under load. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Senior Research Scientist, McAfee Research
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NEB.3.96L.1040309113959.26895J-100000>