Lowering Latency in Linux: Introducing a Preemptible Kernel

Whether you seek higher scores in Quake, are an audio enthusiast or want a smoother desktop, lowering latency in the kernel is an important goal.

The Linux community is large and diverse, and Linux is used in embedded systems all the way through large servers. Preemptive kernel technology provides benefits beyond real-time applications. Desktop users, gamers and multimedia developers alike stand to benefit from reduced latency. A solution is needed for both the 2.4 and 2.5 kernel trees; perhaps the same solution for each is not best. With 2.5 under development, however, now is the time to implement a feature that provides an immediate gain, as well as the framework for further improvement. The result will be a better kernel.


Robert Love (rml@tech9.net) is a Mathematics and Computer Science student at the University of Florida. When not hacking Linux, Robert enjoys auto racing, Thai food and punk rock.



Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

AH! I get it now.

Wo_Dao's picture

Hmm, this explains why some distros are slow or fast. Lunar Linux allows a Preemptiblle kernel. And it's just lightning fast without any bloat. Hmm, put this option with other distros...and perhaps...*ZOOM ZOOM ZOOM*

Just a rambling thought...anyways, this article comes in handy while deciding on kernel configuration in the unix console.. :p Keep it around!!


Manjunath MB's picture

Thanks Robert,
nicely explained...

spinlocks in preemptible kernel

San's picture


The information here is very helpful. thanks.

I have one question.

What is the effect of having kmalloc calls in the code that is protected with spinlock in a preemptible kernel.

kernel preemption

Anonymous's picture

Excellent article, explains well. So that's where all kernel preemption stuff in 2.6 come from!

One question I always had was when the process is in kernel execution path (system call execution), doesn't scheduler_tick decrement its timeslice, and if it does when the timeslice is over, doesn't the scheduler preempts the current process, even though it might be in the middle of the kernel exec path?

Re: Lowering Latency in Linux: Introducing a Preemptible Kernel

Anonymous's picture

It's helpful for me to understand the preemptive kernel.


Seminar on your topic

Pavan Boob's picture

I am studying in final year of computer engg at MIT .
I read your extract and you will be glad to know that I have taken the same topic for a technical seminar at our college.I thereby request you to please send me some more technical details and direct me to some inportant links
waiting for your positive reply.