LINUXGAMES

Kernel Scheduling and Game Performance

July 30th, 2007 by Crusader

There’s been some Linux kernel developmentdrama over the past few weeks: the Completely Fair Scheduler is slated tobe introduced in Linux 2.6.23 over Con Kolivas’ Staircase Deadline scheduler,much to Kolivas’chagrin. The ensuing debate caused Linux creator Linus Torvalds to weigh in:

On Sat, 28 Jul 2007, Kasper Sandberg wrote:
> Im still not so keen about this, Ingo never did get CFS to match SD in
> smoothness for 3d applications, where my test subjects are quake(s),
> world of warcraft via wine, unreal tournament 2004. And this is despite
> many patches he sent me to try and tweak it.

You realize that different people get different behaviour, don’t you?Maybe not.

People who think SD was “perfect” were simply ignoring reality. Sadly,that seemed to include Con too, which was one of the main reasons that Inever ended entertaining the notion of merging SD for very long at all:Con ended up arguing against people who reported problems, rather thantrying to work with them.

[...]

On Sat, 28 Jul 2007, Jonathan Jessup wrote:
>
> Linus, there is a complaint about the Linux kernel, this complaint is that
> the Linux kernel isn’t giving priorities to desktop interactivity and
> experience. The response on osnews.com etc have shown that there is public
> demand for it too.

No, the response on osnews.com only shows that there are a lot of armchaircomplainers around.

People are suggesting that you’d have a separate “desktop kernel”. That’sinsane. It also shows total ignorance of maintainership, and reality. AndI bet most of the people there haven’t tested _either_ scheduler, theyjust like making statements.

The fact is, I’ve _always_ considered the desktop to be the most importantpart. And I suspect that that actually is true for most kernel developers,because quite frankly, that’s what 99% of them ends up using. If a kerneldeveloper uses Windows for his day-to-day work, I sure as hell wouldn’twant to have him developing Linux. That has nothing to do with anythinganti-windows: but the whole “eat your own dogfood” is a very fundamentalthing, and somebody who doesn’t do that shouldn’t be allowed to be even_close_ to a compiler!

So the whole argument about how kernel developers think that the desktopisn’t important is totally made-up crap by Con, and then parrotted byosnews and other places.

The fact is, most kernel developers realize that Linux is used indifferent places, on different machines, and with different loads. Youcannot make _everybody_ happy, but you can try to do as good a job aspossible. And doing “as good a job as possible” very much includes notfocusing on any particular load.

And btw, “the desktop” isn’t actually one single load. It’s in fact a lotof very different loads, and different people want different things. Whatmakes the desktop so interesting is in fact that it shows more variedusage than any other niche – and no, 3D gaming isn’t “it”.

At any rate, CFS should perform better than the stock scheduler has; feel freeto share your experiences with either in the comments below!

2 Responses to “Kernel Scheduling and Game Performance”

  1. Anonymous Says:

    This is probably the best quote of linus I’ve seen without going to the source. I hate the reactionary crap of other news sites, quoting out of context too.

    The bottom line is that Linus trusts Ingo, and not Con. This is why Ingos version went in a matter of days and Con’s has fork existed for years before giving up.

    Con running away in a huff, saying Linux on the desktop is not working, but then ignoring the fact that CFS does work and his idea was good to begin with. He can do more good, he just needs to learn how to apply his skills better, and also not to try to jump to the top so quickly. I’ve made several important contributions to Linux, but I was careful at researching it all out myself, and even listening to everything Linus asked for when he stepped in. And I’m not a kernel regular either. Some people may think I’m not a programmer too, just like Con thinks of himself. The important thing whatever you have to offer is to participate!! Con failed it, proved by his leaving.

    That said, CFS is plenty adequate for me, as I have tried it and it has improved performance immensely in TripleA under java 1.6. It’s lag in graphics drawing is totally gone.

  2. Logy Says:

    But SD made a big difference on the desktop.

    I was never really sure if I was experiencing a “placebo effect” during gaming, because I had no way to objectively measure responsiveness, however an easy objective test I could do on the desktop was run a flash video in Opera in one window while scrolling another. With the old scheduler, it would skip every time. I figured that it was just because either Opera or Flash were crummy (they may be, anyway), but when using SD, I couldn’t *make* it skip when I tried. The difference was night and day.

    I hope CFS can deliver this kind of performance.

Leave a Reply

You must be logged in to post a comment.