Todd Lyons wrote: > Bryan Whitehead wrote on Mon, Jul 29, 2002 at 11:51:27AM -0700 : > >>>You do realize that using this patch pretty much prevents the machine >> >>>from being used as a high capacity server. It allow the kernel to be >>This is totally untrue. In fact the preemptive kernel has been added to >>the 2.5 series and will be in 2.6 because it results in better >>preformance and lower latency. Much of userspace is spent in kernel >>space getting IO done. A preemptive kernel allows any process to be >>interrupted even while in the kernel. For example, when X needs to draw >>some stuff to the video card, that is done at a lower level in the >>kernel. A non-premptive kernel would not be able to interupt the process >>while it was in kernel space. The preeptive kernel can. > > > How is interrupting I/O to redraw the desktop a benefit in performacne?
The thing is, the IO your interrupting IS the desktop redrawing itself, when a higher priority task needs the CPU, like nfs, apache, or a database, the IO from the desktop can be interupted to handle something else at a higher priority. When any userspace program, wether it's X, xmms, apache, oracle, or <anything> makes a call to a kernel level routine, the CPU that the routine is running on is tied up till the routine is done. Even if it's just doing nothing - or it's doing something that will take a long time. As the plain vanilla kernel is now, it's only prempting a process when it's running in userspace. So when a process is running in kernel space it has exclusive rights to the entire machine - it cannot be interupted. Even when a high priority task needs todo something. The side effect of course is everything feels smooth and snappy because IO that is 100times slower than RAM and the CPU gets interupted todo something else instead of just waiting for data. So overall the system will be faster for all processes combined. If your desktop apps are running at the same priority as your services (such as apache or nfs) then your desktop apps will be able to intrupt your services more offen than before - as before they'd only be able to interupt in userspace. But if your services have a higher priority than your desktop then you should have better preformance. > In "perceived" performance, yes. In raw I/O? I don't see it. I do > trust your opinion though Bryan, I would just like a little > clarification. I will go read those URL's. > Raw IO does increase. It's just your desktop (actually the schedular) is allowed to interupt more offen. Setting priorities on processes is very important in a preemptive kernel to make sure low priority process don't get to interupt. The schedular will not interupt a process for a lower priority task in kernel, or userspace! (before a premptive kernel - interupting in kernel space was just a dream) The best explination is the links tho... the best being on http://www.tech9.net/rml/linux/ Of couse searching on goolge is good also. ;) >>Some more stuff to read: >>http://www.linuxjournal.com/article.php?sid=5833 <- kernel locking >>http://vig.pearsoned.com/samplechapter/0130224960.pdf <- Sample chapter >> on Solaris Kernel internals >>http://www.tech9.net/rml/linux/ <- more links of how linux preemptive >> kernel works > > > Looks like interesting reading. > > Blue skies... Todd -- Bryan Whitehead SysAdmin - JPL - Interferometry Systems and Technology Phone: 818 354 2903 [EMAIL PROTECTED]
Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com
