Beta

×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

The Completely Fair Scheduler's Impact On Games

Zonk posted about 7 years ago | from the penguins-without-joysticks-part-deux dept.

Programming 315

eldavojohn writes "We've heard a bit about the completely fair scheduler previously, but now Kernel Trap looks at the implications this new scheduler has for 3D games in Linux. Linus Torvalds noted, 'I don't think any scheduler is perfect, and almost all of the time, the RightAnswer(tm) ends up being not one or the other, but somewhere in between. But at the same time, no technical decision is ever written in stone. It's all a balancing act. I've replaced the scheduler before, I'm 100% sure we'll replace it again. Schedulers are actually not at all that important in the end: they are a very very small detail in the kernel.' The posts that follow the brief article, reveal that Linus seems quite confident that he made the right choice in his decision to merge CFS with the Linux kernel. One thing's for certain, gaming on Linux can't suffer any more setbacks or it may be many years before we see FOSS games rival the commercial world."

cancel ×

315 comments

Sorry! There are no comments related to the filter you selected.

1. Cock weapon (0, Troll)

Anonymous Coward | about 7 years ago | (#20058821)

2. Point at foot
3. Pull Trigger
4. Repeat as necessary

Hmm (-1, Troll)

Anonymous Coward | about 7 years ago | (#20058847)

Is the scheduler going to bring the year of linux on the desktop any closer?

Re:Hmm (4, Funny)

Anonymous Coward | about 7 years ago | (#20059025)

The CFS (Completely Fair Scheduler) won't, but maybe the new FCS (Flux Capacitance Scheduler) might. Or already did.

Re:Hmm (1)

monoqlith (610041) | about 7 years ago | (#20059421)

I think he needs more CSF (Cerebrospinal fluid) to nourish his brain cells and alter their troll-like behavior.

Um (-1, Troll)

Anonymous Coward | about 7 years ago | (#20058851)

"it may be many years before we see FOSS games rival the commercial world."

Ya think?

Strange, I've been gaming in Linux for years. (5, Interesting)

DaedalusHKX (660194) | about 7 years ago | (#20059105)

I have Windows XP and Gentoo Linux running side by side, and strangely, Gentoo scores 10 to 12 FPS faster in World of Warcraft, Warcraft III and even Doom 3. Granted they are commercial games, but if they can run in WINE that fast, I wonder what a direct Linux implementation would do. I just love seeing folks buying the headlines instead of blazing their own paths.

That's why the world is in the shape its in... the majority is always waiting for someone to save the day. You want desktop Linux? Then make it your desktop. Otherwise stop bitching and post some valid comments.

Re:Strange, I've been gaming in Linux for years. (1)

ben there... (946946) | about 7 years ago | (#20059541)

Gentoo scores 10 to 12 FPS faster in World of Warcraft, Warcraft III and even Doom 3. Granted they are commercial games, but if they can run in WINE that fast, I wonder what a direct Linux implementation would do. I just love seeing folks buying the headlines instead of blazing their own paths.
Doom 3 is a native Linux game, as are most, if not all, id Software games.

I get a few FPS more in RTCW: Enemy Territory in Linux (natively), though I generally have fewer background apps/services running than in Windows. But that's just an old game that I still like to play. I'll have to see how the much higher spec'd ET: Quake Wars handles when it comes out.

Article is misleading (5, Insightful)

RailGunner (554645) | about 7 years ago | (#20058893)

Funny, in the article those framerates for Quake III show CFS beating the pants off of SD.

Besides, the biggest barrier to 3d games in Linux is video card drivers (ATI, I'm looking at you!) as 3D drivers in Linux, even the proprietary ones, have tended to be unstable.

Linus is right one this one, the scheduler is a small part.

Re:Article is misleading (4, Insightful)

Aladrin (926209) | about 7 years ago | (#20058917)

Yeah, I was just gonna post 'Long story short: CFS is better. -yawn-'

Why not just say that, instead of trying to get a bunch of ./ers to RTFA?

Re:Article is misleading (2, Insightful)

Azarael (896715) | about 7 years ago | (#20059063)

Neither the summary nor the FA did a great job of summarizing the issues. I have a vague idea what the schedulers do, but how many readers know what the differences between SD and CFS are? I don't.

It's nice to see the commentary from the mailing list, but without a decent explanation of the situation, the posting isn't informative to many people.

Re:Article is misleading (4, Informative)

ThosLives (686517) | about 7 years ago | (#20059297)

Neither the summary nor the FA did a great job of summarizing the issues.

I agree to some extent. Notably the test specified in the article is "open a game and then sit there without hitting the keyboard." In my mind, this means the game isn't responding to any I/O, so gets pushed to the background, so adding more tasks just means it gets 1/tasks timeslices. Seems reasonable. I'm not sure why the CFS would keep the game running more often than SD if there was no I/O. An interesting comparison would be to see not only the FPS/CPU usage for the game but also for the "loop" tasks. (Those tasks also are not I/O bound.)

Fundamentally I think the name CFS is a little bit odd - how does one define "fair"? In fact, I probably don't want my scheduler to be fair at all - I want it to run the stuff I want fast, and the other stuff it can run slow. That's not very fair.

So, I would say there is not enough information given in the article to tell exactly why the systems had different FPS performance for different schedulers - just looking at that number doesn't tell how it's splitting the time among all the processes.

Re:Article is misleading (4, Informative)

ultranova (717540) | about 7 years ago | (#20059581)

Fundamentally I think the name CFS is a little bit odd - how does one define "fair"?

Fair, in this context, means that the scheduler will give all the running tasks CPU time in proportion to their priority (nice level). It follows from this that all the tasks in a given nice level are given equal amount of CPU time, and a higher-priority task (lower nice level) is given more CPU time than a lower-priority one.

SD scheduler (but not CFK, AFAIK) also had idle priority, which means a task that only runs if nothing else at any nice level wants to run. Very useful for running FoldingAtHome.

In fact, I probably don't want my scheduler to be fair at all - I want it to run the stuff I want fast, and the other stuff it can run slow. That's not very fair.

That's what "nice" is for. A fair scheduler respects nice levels, as stated above.

Re:Article is misleading (1)

harrkev (623093) | about 7 years ago | (#20059587)

In fact, I probably don't want my scheduler to be fair at all - I want it to run the stuff I want fast, and the other stuff it can run slow. That's not very fair.
Isn't that what "nice" is for?
Me too confused.

Re:Article is misleading (1)

hurfy (735314) | about 7 years ago | (#20059231)

"Why not just say that, instead of trying to get a bunch of ./ers to RTFA?"

I'm gonna guess it worked tho...

hehe, 9 users and 2243 guests online

Re:Article is misleading (3, Funny)

Anonymous Coward | about 7 years ago | (#20058989)

So what you're saying is, the headline isn't completely fair?

*bad-dum* *crash!*

Re:Article is misleading (3, Insightful)

complexmath (449417) | about 7 years ago | (#20059041)

The performance of the "patched SD" mentioned near the bottom show SD to be slightly better than CFS on the test system. However, a few FPS one way or the another really amounts to testing "noise" -- it doesn't mean anything. If there are any problems with 3D, it obviously isn't common to all systems, which suggests to me that the scheduler isn't the problem. Not unless the problem systems have some background job running that the others don't, which is messing up CFS in some way (and this seems unlikely).

Re:Article is misleading (1)

mulvane (692631) | about 7 years ago | (#20059843)

Why not actually write a schedule that has a performance option tunable. Basically, pass a real time instruction to it to optimize how its working so it can switch between SD and CFS on the fly. Seems very possible.

Re:Article is misleading (5, Insightful)

Omnifarious (11933) | about 7 years ago | (#20059117)

FPS is a poor measure of the feel of a game. I know it's what all the graphics card benchmarks use, and it does do a good job of measuring the total processor and video card throughput, but that's not the most important thing.

The most important thing is the time between you pressing a key and the changed game state being reflected on your screen and how consistent that delay is.

One of the arguments that CK has made about kernel development is that kernel developers have become obsessed with throughput to the exclusion of all else and that this leads to very poor desktop performance because throughput is a poor measure of 'interactivity'. Someone posting 3D game framerates as evidence of one scheduler being better than another is exhibiting exactly this bias.

IMHO latency is a better measure, but still not perfect and it can be hard to measure in some cases.

I don't know enough about the scheduler to know which one is better or which one exhibits particular properties. But I can see that the throughput bias is evidenced in force in the thread the article points to.

And CK is also right that big iron shops care more about overall throughput than any measure of 'interactivity'. IMHO there ought to be some kind of pluggable scheduler system that allows you to completely change the algorithm to reflect the preferred behavior of the computer you're using.

Re:Article is misleading (4, Insightful)

sumdumass (711423) | about 7 years ago | (#20059331)

I believe that you can swap the scheduler out. I might require you to rebuild the kernel but there is nothing stopping a distro, you or anyone else from using a different scheduler.

And actually, If people think this is a problem, Distro's already heavily customize the kernels so switching this out in their particular kernel shouldn't be much of a problem.

Re:Article is misleading (2, Informative)

piojo (995934) | about 7 years ago | (#20059669)

I believe that you can swap the scheduler out. I might require you to rebuild the kernel but there is nothing stopping a distro, you or anyone else from using a different scheduler.

I think you're thinking of the IO scheduler, which you can select at compile time. The CPU scheduler is not a choice--you must apply a patch and change the kernel's source for that. And while distros do extensively customize compilation options, the patches that they apply are generally small (besides Gentoo, which is very proud of the patchset it applies to its kernels). For almost any distro, it would be too much work to support multiple kernels (where one is based on unmaintained code).

Re:Article is misleading (1)

DigiShaman (671371) | about 7 years ago | (#20060081)

What about user selectable scheduler profiles? Would it be possible?

You could switch to one that's optimized for networking (realtime), gaming, server, and desktop.

Re:Article is misleading (4, Insightful)

Bob-taro (996889) | about 7 years ago | (#20059713)

FPS is a poor measure of the feel of a game. I know it's what all the graphics card benchmarks use, and it does do a good job of measuring the total processor and video card throughput, but that's not the most important thing.
I disagree. Responsiveness is important, but I've never encountered a situation where the frame rate was good and the machine couldn't read my keyboard clicks fast enough.

Re:Article is misleading (5, Interesting)

Anonymous Coward | about 7 years ago | (#20059731)

You are on to something here. CK uses arrays and has a lower context switch time whereas CFS uses red-black trees. What this means is that doing a bunch of "while :; do done" loops that always use their full timeslice is a test that favors CFS as much as possible really.

As an aside, what kind of retard benchmarks a scheduler using a game that is doing nothing and 100% cpu tasks? Put some disk access in there, maybe a set of folders that will easily fit in cache and then find . them. Have some fixed-seed random busy / sleeps of different ratios. Have the game play a demo reel on repeat and record avg *and* min/max fps. Come on Ingo must be somewhat familiar with CK so he must know that these tests where CK is roughly the same are biased toward CFS to begin with. If you are going to say 'look I did these benchmarks and it's a wash' and use that as a justification then at least do good benchmarks.

I think this more than anything else confirms my impression than Ingo is just hacking shit until it kinda works ok. Note that this is exactly the same kind of rationale Linus gave for diss'ing Con so flame off.

Re:Article is misleading (-1, Troll)

Anonymous Coward | about 7 years ago | (#20059561)

CowboyNeal loves ass to mouth. He loves taking it in the ass. So does Richard Stallman and all other opensource/Linux advocates.

Re:Article is misleading (4, Interesting)

garett_spencley (193892) | about 7 years ago | (#20059865)

Besides, the biggest barrier to 3d games in Linux is video card drivers (ATI, I'm looking at you!) as 3D drivers in Linux, even the proprietary ones, have tended to be unstable.

I would think that the biggest barrier to 3d games in Linux would be the inherent paradox concerning the lack of 3d games.

No gamers = No profit for game companies = No games being produced.
No games = No gamers = No profit for game companies.

The one thing that I would agree on is that video card support brings game developers and gamers closer to a certain extent. Having better drivers might get both gamers and developers to consider Linux a *little* more. However, even if Linux had terrific video card drivers that were just as good or better than the Windows drivers I still wouldn't consider Linux for games just because there's very few good games available.

Better drivers can only help. But I can't consider that the "biggest" problem. The biggest problem is that there are too few people who use Linux. So video card manufacturers don't care about Linux. Game developers don't care about Linux and lastly (most) gamers don't care about Linux.

I realize there was a lot of bad management decisions involved, but look at what happened to the last company that tried to make a business out of porting titles to Linux (*cough* Loki *cough). I have just about every Loki title that was developed and I really wish they had stayed afloat. Maybe it was bad business decisions and maybe it was just that there was no profit in porting titles to Linux. The situation might be different today and I hope that someone has the desire, balls and money to step up and try what Loki tried 7 or 8 years ago. But Loki's fate did send a clear message. There's no profit in Linux games. John Carmack also said back then that releasing Q3A for Linux saw no profit.

Hopefully as more desktop companies, like Dell, jump on board and push Linux then maybe both the game developers and video card manufacturers will start to see the potential for profit and a result gamers will jump on board. But even Mac has suffered from the same problem for 20 years, and there's way more profit in developing for Mac than Linux. And it shows. There are more commercial Mac games than there are Linux. But both Linux and Mac have next to no games at all when you compare to the titles available for Windows.

FOSS games (3, Informative)

Joe Tie. (567096) | about 7 years ago | (#20058919)

Aren't going to happen until artists in the medium, 'good' artists rather, decide to start working for free the same way coders do. Some artists will work for publicity alone, bu they seem to be by far in the minority. On a technical level, I've not seen much problem with linux. Ogre, for example, runs quite smoothly for me.

Re:FOSS games (0, Offtopic)

Anonymous Coward | about 7 years ago | (#20058969)

that's the most ridiculous comment I've heard. enjoy your solitaire knock-offs

Re:FOSS games (1)

TodMinuit (1026042) | about 7 years ago | (#20059023)

I'm no artist -- In fact, I can barely sign my name -- but I do think 3D artists work for free, just not on games. Instead, they tend to focus on high-polygon renders of things, like cars. They want something that is fun and challenging, just like open source programmers. Low-polygon video game characters aren't going to cut it.

Re:FOSS games (1)

Broken scope (973885) | about 7 years ago | (#20059233)

Maybe I'm wrong but aren't many of the low poly characters in games just simplified from original high poly models. Doesn't normal mapping take that high poly high quality render, the simplify it, then using lighting tricks give it the appearance of the high poly model, while being significantly similar?

Maybe I'm wrong again, but making those high poly models isn't easy either.

Re:FOSS games (0)

Anonymous Coward | about 7 years ago | (#20059739)

Low-poly models are bump-mapped (usually with normal mapping) from the high-poly models. They effectively turn the extra polygons into a texture. [wikipedia.org]

Any schmuck with hobby experience can make a high-poly model. When game development studios hire modelers, they look for people who can do the best work with as few polys as possible.

Re:FOSS games (1)

Opportunist (166417) | about 7 years ago | (#20060093)

Actually, creating a low polygon count model that looks good is quite a challenge. With today's tools, it's almost getting trivial to make something look good, provided nobody cares if you use billions of polys.

Re:FOSS games (1)

slackmaster2000 (820067) | about 7 years ago | (#20059255)

Right. And then artists can make money the FOSS way, with technical support.

Re:FOSS games (1)

Opportunist (166417) | about 7 years ago | (#20060139)

Maybe not, but with the FOSS way of becoming known and hired by companies.

The first thing you get asked when trying to apply for a position as an artist is to show them some of your work. Which is kinda hard if you never participated in any project. And to get a project, they first of all want to see some of your work...

Re:FOSS games (1)

CaffeineAddict2001 (518485) | about 7 years ago | (#20059343)

Art is not modular like code. You can mash-up code from 20 different coders and still get something that works well. If you did that with art it would look terrible because you would not have a consistent style.

Re:FOSS games (3, Insightful)

sqlrob (173498) | about 7 years ago | (#20059547)

It depends on the artist.

Are you saying all of "Snow White" was drawn by one person? All 24 fps, 83 minutes worth?

Re:FOSS games (1)

mwlewis (794711) | about 7 years ago | (#20059677)

No, he's saying that they didn't use any of the "Snow White" art in "Sleeping Beauty" or "Cinderella".

Re:FOSS games (1)

nuzak (959558) | about 7 years ago | (#20059985)

> Are you saying all of "Snow White" was drawn by one person? All 24 fps, 83 minutes worth?

Bad example. The team of animators on Snow White and the Seven Dwarves was managed to an unprecedented degree, with an obsession for consistency and quality control. This is not the sort of thing you get from hobbyist contributions.

Coders are a dime a dozen, minus the dime. Modelers, sketch artists, musicians, and actors are the fellas you're just not going to easily get on a FOSS project.

Re:FOSS games (1)

CaffeineAddict2001 (518485) | about 7 years ago | (#20060167)

Snow White could not have been made over the internet for free because you could not maintain stylistic control.

Also, Art has a very specific purpose in mind. It can't be reused easily. Where else are the 7 dwarves going to be used other than Snow White?

Software algorithms can be reused for all sorts of things.

Re:FOSS games (1)

CuteAlien (415982) | about 7 years ago | (#20060117)

I disagree. Usually a lot more artists work on a game than coders. Also exchanging artists in a project will cause less trouble than exchanging coders. A good artist can adapt his style so it's consistent with the style delivered by others. Integrating additional coders is usually very difficult. And lastly: programming is an art anyway :-)

Re:FOSS games (3, Interesting)

OldeTimeGeek (725417) | about 7 years ago | (#20059515)

Aren't going to happen until artists in the medium, 'good' artists rather, decide to start working for free the same way coders do. Some artists will work for publicity alone, bu they seem to be by far in the minority.

Of course they're in the minority. For them, there's nothing to be gained in providing their services for free.

The publicity for working on games is almost nonexistent. For example, can you, name any artist that worked on any one of the most popular games? I can, but I know a bunch of artists that work in the games industry.

Besides, artwork doesn't work as FOSS. Unlike code, artwork for games isn't inherently "sharable" - it's designed for the purposes of that game and that game only. Game engines can be used for multiple different kinds of game. Artwork almost always can't. It may be used for sequels (but generally isn't as the requirements change from game to game) but it can't be used across different types of games.

Re:FOSS games (1)

Jeff DeMaagd (2015) | about 7 years ago | (#20059819)

Aren't going to happen until artists in the medium, 'good' artists rather, decide to start working for free the same way coders do. Some artists will work for publicity alone, bu they seem to be by far in the minority.

I really don't think that's fair or accurate for either programming or art. A lot of artists give away at least some of their work on the Internet, and a lot of programmers don't do that. Whether it's more prevalent in one field or another, that's a question that can't be definitively answered.

Re:FOSS games (1)

Kjella (173770) | about 7 years ago | (#20059999)

I'm sure they do - in a shape where they create what they want to create.

Creating free for a game means:
a) It needs to be a set, often of considerable size
b) It's usually set by the developers what you need to create
c) You have to create it with the game's restrictions
d) They all need to be consistent in style

In short, it's not free experimentation or creativity. I imagine the average art designer-inspiring-to-be-artist would rather create art than designing up a large set of resonably similar graphics - too much like work. And while I've heard of paid coders, I haven't heard of any paid OSS designers - at best there's a prize in a logo contest.

not a big issue (-1, Flamebait)

SolusSD (680489) | about 7 years ago | (#20058921)

the performance hit on 3d rendering will be minimal as most of the time the transform and lighting work is offloaded to the gpu in chunks. i'm willing to bet you cant tell the difference on any system fast enough to be worth playing 3d games on in the first place.

You won't get good games until you get marketshare (5, Insightful)

nweaver (113078) | about 7 years ago | (#20058945)

This is irrelevant to the gaming front.

The limit to games on Linux is market share. Its not (much) easier to develop a good 3D game for linux as it is Windows, so why code for 2% of the market when you can code for 92% of the market?

Thus you will only get games where the developer has gone out of their way to ensure complete portibility and provides a port mostly out of courtousy.

The scheduler details are irrelevant for this: what Linux Games need is 10%+ marketshare on the desktop.

Re:You won't get good games until you get marketsh (3, Insightful)

Zironic (1112127) | about 7 years ago | (#20059021)

Sounds like an evil circle.

To get Market Share you need games.
To get Games you need Market Share.

Re:You won't get good games until you get marketsh (1)

TodMinuit (1026042) | about 7 years ago | (#20059077)

The limit to games on Linux is market share.
Is this really true? Most major games are written using pre-made engines like Unreal, which typically are cross-platform. If they're hand-rolling an engine, making it cross-platform is rather easy compared to, say, a UI application. Games don't exactly use a lot of platform-specific coding technicals.

Re:You won't get good games until you get marketsh (1)

delire (809063) | about 7 years ago | (#20059643)

Is this really true? Most major games are written using pre-made engines like Unreal, which typically are cross-platform.
They might be cross-platform but they still cost 100's of 1000's of dollars to license. Game Engines top some of the most expensive proprietary software out there.

Moreso it is false to say "most major games" (my emphasis) are built from these engines. Quite a few are yes, but sometimes the technical baggage of the engine is so great - in that steers design directions - that it's cheaper in the long term for a game development shop to author their own engine in-house.

Furthermore you can't beat the freedom of being the legal author of what you use.

Even if you can afford to license an existing engine - or use a FOSS engine like QuakeIII - it's still an expensive and time consuming task to make the actual game. A good example is Half-Life 1: it was a direct architectural relative of Quake2 yet it still took years and costed millions in labour to make.

Programming and game-design aside, don't underestimate also just how long it takes to make the art.

Re:You won't get good games until you get marketsh (1)

blincoln (592401) | about 7 years ago | (#20059893)

There is also typically a lot of customization done to licensed engines by the licensees, at least according to my game dev friends. Even if the engine is more or less cross-platform out of the box, it seems unlikely that it will remain that way for long unless it's a specific goal of the developers working for the licensee.
Given how many complaints I've heard about the Unreal engine in general, I'd have to imagine that with the apparent headaches of getting licensed games to run right just on Windows and the 360, only a really dedicated game developer is going to target Linux as well.

Re:You won't get good games until you get marketsh (1)

TheCRAIGGERS (909877) | about 7 years ago | (#20059783)

Ever heard of DirectX? While some of the engines that you mentioned may have the option of using OpenGL or DirectX, I don't think many hand-rolled engines do.

Re:You won't get good games until you get marketsh (1)

Xtravar (725372) | about 7 years ago | (#20059883)

1. Linux machines
2. Development setup
3. QA
4. Support
5. Platform-specific APIs added to, say, make shortcuts or turn off screensavers or whatnot

Part of this can be solved by rogue developers, but not all. And believe me, once a developer is accustomed to the system, he'll realize his effort is in vain because no management would let him release untested and unsupported code, nor would management want to test or support something with so little ROI (return on investment). You could invest that money and time into something that will get you $, or you could invest that on something that will get you $$$$$ - it's just smart economics to work on the next Windows thing than the Linux thing.

If you start working as a developer, you will come to realize these realities someday.

Re:You won't get good games until you get marketsh (1)

nyctopterus (717502) | about 7 years ago | (#20059133)

One reason (probably why you can find games for macs): you'll have far less competition. Having 50% of 2% of the market is better than 0.5% of 100%. While the Linux gaming market is small, it's pretty unsaturated. There's got to be other reasons for lack of gaming on Linux.

No, it isn't (1)

everphilski (877346) | about 7 years ago | (#20059251)

Because the 0.5% of 100% has a much greater potential for growth ... pump up the advertizing, work up some new expansions/tie-ins/etc. and build your market share. The 50% of 2% has stagnated.

Re:You won't get good games until you get marketsh (1)

plague3106 (71849) | about 7 years ago | (#20059533)

For your theory to work, people would have to buy whatever crap game is put out. Put out a crappy game, and you'll not likely even get 50% of the 2% market.

Re:You won't get good games until you get marketsh (-1, Troll)

Anonymous Coward | about 7 years ago | (#20059161)

What the fuck are you talking about? How will marketshare impact game performance? Oh, right, you're not talking about performance. Funny, that, because that's the topic right now. I guess that what's really irrelevant here is your comment.

We're all bored of you people with your TOP TEN REASONS WHY UBANTU IS MORE WORSE THAN WISTER'S VISPA. We have our Linux desktop. We have our Linux games. We care much more about what we have than about lubing up, bending over backwards, and taking six cocks at once in the hope of someday being able to pay $40 for a closed-source game OH GOD WON'T SOMEBODY PLEASE GIVE US SOME FUCKING CLOSED-SOURCE SOFTWARE

Re:You won't get good games until you get marketsh (1)

ucblockhead (63650) | about 7 years ago | (#20059379)

People seem to forget that someone actually tried to build a company [wikipedia.org] on Linux games. It was a disaster. The trouble wasn't the OS. The games ran great. The trouble was that no one (but me, I guess) bought them.

Re:You won't get good games until you get marketsh (0)

Anonymous Coward | about 7 years ago | (#20059559)

People seem to forget that someone actually tried to build a company on Linux games. It was a disaster. The trouble wasn't the OS. The games ran great. The trouble was that no one (but me, I guess) bought them.

Huh, I thought it was because the CEO was embezzling the money?

Re:You won't get good games until you get marketsh (1)

Chandon Seldon (43083) | about 7 years ago | (#20059791)

From what I've heard, Loki didn't die due to a lack of customers. They died because of personnel problems, and because their profit margin wasn't good enough to make up for their other shortcomings.

Re:You won't get good games until you get marketsh (1)

dvice_null (981029) | about 7 years ago | (#20059859)

Why not just write a cross platform game instead of a Linux or Windows game? It is actually easier than writing a DirectX game, because of the advanced libraries. Try writing a game with Irrlicht-library for example. You can even select whether to use DirectX or OpenGL as a rendering engine for the same code you write and it takes only about 20 lines of code to write a working program that will load a 3D-object from file and display it.

http://irrlicht.sourceforge.net/tut012.html [sourceforge.net]

If you don't like Irrlicht, you can always use Ogre 3D or Crystal Space or even SDL with OpenGL.

Should it matter? (2, Insightful)

Jeremi (14640) | about 7 years ago | (#20058977)

I would think that 3D games would be considered a 'real time task' (i.e. you must draw the next frame within 1/30th of a second or else it won't look right), and therefore you would want to run them using the real time scheduler (SCHED_FIFO or SCHED_RR). Given that, it wouldn't much matter what fancy scheduling algorithms the non-real-time tasks were using.... your game would always get the cycles it needs when it needs them (up to to the CPU's capacity, of course).


Perhaps people just don't want to run their games as root though....

Re:Should it matter? (-1, Flamebait)

Anonymous Coward | about 7 years ago | (#20059257)

Thanks for that completely uninformed and gut-feeling type post, it has made us all better off! Your complete lack of actual knowledge about the subject really helped me understand the issues at play here.

Re:Should it matter? (1)

Compholio (770966) | about 7 years ago | (#20059715)

I would think that 3D games would be considered a 'real time task' (i.e. you must draw the next frame within 1/30th of a second or else it won't look right), and therefore you would want to run them using the real time scheduler (SCHED_FIFO or SCHED_RR).
Absolutely not, you want your games to have a high priority but not that high of a priority. Real time tasks have a high potential for locking up the system, if there's a bad loop in a normal priority application then you can stop it - if there's one in a real time priority application then you have no way to spawn a task to stop it. In a perfect world this would obviously not be a problem, but play a few games and you'll see that it is a problem. I have found many games that lock up Windows will do Bad Things(tm) in Linux but at least you can still stop them without rebooting.

Re:Should it matter? (1)

Kjella (173770) | about 7 years ago | (#20059723)

I think the difference between hard and soft real-time has been discussed countless times. My impression at least was that the penalty for making the guarantee is so great, you normally only want to use it if you REALLY need it, like say a capture application that must capture or the frame is lost. In any case, I think IO priority is more important these days. With multi-core I've found myself also multi-tasking a lot more, but having some background IO task running is usually devastating to real-time IO. Yes, I know about ionice but...

Modular Kernel (1)

jshriverWVU (810740) | about 7 years ago | (#20059031)

One of the reasons I like the linux kernel is because it's very modular. Why can't both schedulers be included in the kernel, and the person compiling the kernel set which one they want? Kinda like how you could select between Alsa or OSS, or a myriad of other feature that are different but serve a similiar purpose?

Re:Modular Kernel (1)

TodMinuit (1026042) | about 7 years ago | (#20059121)

There's no reason you can't go to the mans website, download the code, and then compile it into the kernel. However, including it in the kernel by default, even as an option, means that it must be maintained and cared for.

Re:Modular Kernel (2)

intx13 (808988) | about 7 years ago | (#20059265)

Linux is like a car... :) A tail light or the license plate might be mostly modular, but the drive train isn't. The scheduler is very fundamental to the kernel, and must be running at all times. No doubt a system could be devised to make it work, but the pointer that Linus and others have been trying to make is that the most important reason for selecting one scheduler other another at this time is the dedication of the scheduler's maintainer and developer, not whether 3D games experience a slight decrease in performance. Even if they *could* both be used, Linus would still stick to his guns, because he believes that the developer behind the project is more important than the project itself.

I tend to agree - open source is driven by developers (developers developers developers!) - if the selected scheduler happens to be a bit slow for 3D games, someone will patch it, and the maintainer will integrate the patch. However if there aren't many active developers working on the project, and the maintainer doesn't seem dedicated, then it doesn't matter how great the code is right now; some time down the road work will be needed, and then the project runs into trouble.

In the open source world it's easier to patch up a slower design in a well-supported project than have to fork or reorganize an entire project because of lacking support.

Re:Modular Kernel GREAT QUESTION jshriverWVU (0)

Anonymous Coward | about 7 years ago | (#20059329)

"One of the reasons I like the linux kernel is because it's very modular. Why can't both schedulers be included in the kernel, and the person compiling the kernel set which one they want?" - by jshriverWVU (810740) on Tuesday July 31, @12:28PM (#20059031)

Great question, jshriverWVU!

( & though I am MOSTLY a "Win32 kind of guy", I am curious myself on this note you bring up, also!)

Hey, Penguins? Since this OS comes with source? Why not allow users this choice for Linux OS installs @ setup time (the ability to choose between SD scheduler (Con) & Completely Fair Scheduler (Ingo))...??

APK

P.S.=> I am personally SURPRISED that Linus Torvalds did NOT include this as an optional build you could install (a "gamer's & multimedia person's core/kernel" in essence) @ setup time for Linux, because it IS doable (kind of like how NT-based OS can install a singlecpucore build, vs. a multicpucore build)...

Maybe, JUST MAYBE? This does point to some "egomania" & personal like/dislike stuff on the part of Mr. Torvalds (favoring Ingo OVER Con etc. et al)... who knows, except those 3 people, & L.T. most of all! apk

Re:Modular Kernel GREAT QUESTION jshriverWVU (1)

McNihil (612243) | about 7 years ago | (#20059391)

Its typical in Zonk's topics that something like this gets 0 as mod point.

As you said choosing scheduler can be done in kernel building so all this mud flinging is assanine IMHO and just shows how little so called gamers know what Linux is capable of.

Re:Modular Kernel GREAT QUESTION jshriverWVU (3, Informative)

SirTalon42 (751509) | about 7 years ago | (#20059519)

Actually the quote from the in the summary from Linus is part of a larger email where hes dismissing the idea of using the plugscheduler (I can't seem to recall the exact name) that would make the CPU scheduler plugin based like the IO scheduler currently is. His reasoning against it were largely BECAUSE what they learned from having the IO scheduler plugin based and its something Linus as well as the subsystem maintainers DON'T want to repeat.

Anyways, you can still just apply Con's patch to the kernel to use his scheduler instead of the old scheduler (and if he keeps maintaining it, you'll be able to use SD instead of CFS). Don't forget that we haven't even had a kernel released using CFS!

Re:Modular Kernel GREAT QUESTION jshriverWVU (1)

Ash Vince (602485) | about 7 years ago | (#20059637)

Con has already said he will no longer develop it or any other kernel development because his scheduler was not chosen.

Re:Modular Kernel GREAT QUESTION jshriverWVU (1)

dave562 (969951) | about 7 years ago | (#20059959)

Screw you guys, I'm going home!

Games.. only thing keeping me from linux full-time (0, Redundant)

brxndxn (461473) | about 7 years ago | (#20059057)

I've used linux quite a bit before.. but it is always stuck on a 2nd or 3rd box I have around. I love the new Ubuntu...

except.. gaming support on linux is shitty. The games I have run on linux worked okay - but it took hours to set them up properly. Unreal Tournament 2003 is the last one I played on linux that had a linux port available..

I play games about 10% of the time I use my computer.. nonetheless, bad gaming support is what keeps me from using Ubuntu 100% of the time. I do not feel like having 2 operating systems intalled on my computers.

I'm not a 'gamer' by any means.. but games are important enough to me to keep me using Windows.. I would love to switch.. but I'll switch when the linux coders decide to push for a more compatible gaming system.

Games and VS (1)

everphilski (877346) | about 7 years ago | (#20059285)

Games and Visual Studio (10%, 75% respectively). Even the freebie versions beat the crap out of any IDE I've seen for linux. Yes, I've used Eclipse and the other major players...

Re:Games.. only thing keeping me from linux full-t (2, Insightful)

Stringer Bell (989985) | about 7 years ago | (#20059305)

I'm not a gamer at all, but for years I've said that Quicken was the only thing keeping me from switching Linux full-time. (Yes, I know there are FOSS bookkeeping packages out there. Quicken is excellent, though, so any switch is a step down in my mind.)

Then I realized it doesn't matter which operating system I run as long as I can do what I need to do. I was only trying to switch to Linux for ideological reasons, not for any practical reason. The act of switching over was going to involve a lot of time, effort, and possibly expense, and if there was no "business reason" to go through all that, it would largely be for nought. If I had a mission-critical app I needed to run that only ran on Mac or Linux or whatever, then I'd switch, but I'd have to jump over with both feet. I don't want my music, pictures, documents, finances, etc., spread all over multiple machines (or multiple partitions of different types.) My mission-critical app is Quicken...so I continue to run Windows.

So don't look at it as "I'd switch over completely, but..." Instead, look at it as "Apps drive the OS I use. I need the following app(s): ________, which is/are well supported on _______, so my OS is ________."

Re:Games.. only thing keeping me from linux full-t (1)

fishbowl (7759) | about 7 years ago | (#20059969)

"I'm not a gamer at all, but for years I've said that Quicken was the only thing keeping me from switching Linux full-time."

I actually prefer to run Quicken in a VM. I can backup the whole VM partition. I can run a version of Windows that's fully tuned to the application. It has a very small footprint. I've been doing this for almost ten years already.

I *greatly* prefer it to running it on a native Windows boot. I'd almost go as far as to say, if I had to run Windows, I'd probably start doing finances on paper.

Pluggable (4, Insightful)

cerelib (903469) | about 7 years ago | (#20059143)

That is why Linus should have listened to Con Kolivas when he tried to introduce a pluggable scheduler system. With a modular system we could have CFS and the staircase scheduler and both problems solved.

You didnt read TFA (1)

everphilski (877346) | about 7 years ago | (#20059333)

CFS actually beat out the outcast scheduler ...

Re:You didnt read TFA (1)

Chandon Seldon (43083) | about 7 years ago | (#20059505)

Beat out at *framerate*, which isn't the same thing as responsiveness, although those two things are generally positively correlated.

The numbers that would really help in this argument are things like "standard deviation of inter-frame delay". If you can come up with a good way of measuring that, that'd be great.

Re:Pluggable (5, Informative)

andrewd18 (989408) | about 7 years ago | (#20059923)

Linus has already explained why he doesn't like the idea of a pluggable scheduler system. See http://kerneltrap.org/node/14019 [kerneltrap.org]

Multiple choice schedulers (2, Informative)

davidwr (791652) | about 7 years ago | (#20059207)

Personally, I'd like things like schedulers to be pluggable. But that's just me. Or maybe not [kerneltrap.org] .

Re:Multiple choice schedulers (0)

Anonymous Coward | about 7 years ago | (#20059449)

Try again [kerneltrap.org] .

Scheduler Nanokernel (2, Interesting)

Doc Ruby (173196) | about 7 years ago | (#20059259)

Schedulers are actually not at all that important in the end: they are a very very small detail in the kernel - Torvalds
Actually, I'd like to see the OS kernel consist entirely of only the scheduler and the thinnest APIs to secure drivers granting access to the HW. Everything else, including IPC, could be in userspace.

That would make distributing the OS a lot easier. And the simplicity could be a lot easier to secure, to develop for, to customize a deployment for minimum HW (like eg. a "self-winding" 10mW Bluetooth ring with "accessory" features). Practically every device could run the same "OS", with modules bolted on for increased functionality on heavier HW.

Re:Scheduler Nanokernel (1)

intx13 (808988) | about 7 years ago | (#20059353)

Well, at a certain level, that's what the kernel is. The problem is that providing the bare minimum of hardware access to userspace means that anybody can do naughty things to the hardware. Remember drivers in Windows 98? Linux has the "best" of both worlds. For the desktop, the kernel can contain lots of APIs and kernel-land drivers, providing fast hardware access and high level interfacing with security from crashes... and for embedded systems you just compile your own kernel and link in whatever you want. Distributing Linux is pretty easy as is. Most of the time you don't want the ability to load and unload core kernel components on the fly, just like you wouldn't want to swap out the ALU from the silicon inside your processor while your computer is running. And if you wanted to customize at that level, just download the source and compile away!

Re:Scheduler Nanokernel (1)

Doc Ruby (173196) | about 7 years ago | (#20059607)

That's what a kernel is, but not the Linux kernel. Linux is a monolithic kernel, including all kinds of stuff that isn't the scheduler, isn't the driver API (or just the drivers too). That's why Torvalds correctly said that the scheduler is a tiny part of the kernel.

If customizing Linux to the specs I mentioned were so easy as downloading source and compiling (you skipped the hard part, factoring and looping back the extra codepaths), then all the distros that try it (probably starting with the "Linux on a - 1.44MB - floppy" ones in the mid 1990s) would be trivial. But they're not.

FWIW, while I don't want to swap out my ALU HW, many recent advances in CPU take exactly that approach, like the Cell sacrificing CLU die space for extra ALUs and parallelizing HW. In point of fact, one reason I'd like a nanokernel would be to run on something like the Cell with embedded (or just Tbps-bus-bridged) FPGA. Linux's current architecture is far from serving that architecture.

What you describe is called... (1)

AlXtreme (223728) | about 7 years ago | (#20060057)

Minix!

Re:Scheduler Nanokernel (1)

nuzak (959558) | about 7 years ago | (#20060099)

That's called a nanokernel. And you don't even need the scheduler in kernel space either -- the whole notion of "processes" is not something the OS necessarily has to concern itself with. All a nanokernel has to do is make hardware available on demand.

You can more or less engineer the kernel concept out of existence until it's nothing but an interrupt handler and a call gate. However, since the reality of commodity CPUs is that they're designed with hardware contexts and even C stacks (or perhaps I should say Pascal) built-in, there's really not much reason to keep it completely out of kernel space on such hardware. This doesn't argue for Linux's extremely monolithic nature (it doesn't even have a proper VFS layer) but it does mean that at some point, further reductionism is just absurd.

Making the scheduler pluggable would just make sense though.

Re:Scheduler Nanokernel (1)

nuzak (959558) | about 7 years ago | (#20060165)

> That's called a nanokernel.

Eh-heh... I suppose since the subject of the post contained the word "nanokernel", that that was kind of redundant. :P

Setbacks? (4, Insightful)

ichigo 2.0 (900288) | about 7 years ago | (#20059269)

One thing's for certain, gaming on Linux can't suffer any more setbacks or it may be many years before we see FOSS games rival the commercial world.
Linus mentioned somewhere that CFS and SD are both superior to the old scheduler, so in what way can choosing CFS be considered a setback?

Seems like Linux / FOSS should be focusing on... (1)

MeditationSensation (1121241) | about 7 years ago | (#20059277)

...something more probable, like making GIMP a killer Photoshop clone or something. Games is just such a competitive and tricky market, and I wonder if there would really be that many Linux people willing to pay for them. Seems like many Linux people in the desktop space are high school and college kids.

Linux and Games (4, Insightful)

CopaceticOpus (965603) | about 7 years ago | (#20059371)

I've figured out how to get games running with Linux!

1. Set up your Linux system. Use onboard video and don't overspend on your processor.
2. Buy a PS2, a Wii, or a 360.
3. Play games on your game console and do everything else on Linux.

Be glad they chose CFS over SD then. (4, Insightful)

delire (809063) | about 7 years ago | (#20059393)

Sayeth Kenneth.

Alright, Just got done with some testing of UT2004 between 2.6.23-rc1 CFS and 2.6.22-ck1 SD. This series of tests was run by spawning in a map while not moving at all and always facing the same direction, while slowing increasing the number of loops.

CFS generally seemed a lot smoother as the load increased, while SD broke down to a highly unstable fps count that fluctuated massively around the third loop. Seems like I will stick to CFS for gaming now.

--
Kenneth Prugh
Sayeth Matthew

My experience was quite similar. I noticed after launching the second loop that the FPS stuck down to 15 for about 20 seconds, then climbed back up to 48. After that it went rapidly downhill. This is similar to other benchmarks I've done of SD versus CFS in the past. At a "normal" load they're fairly similar but SD breaks down under pressure.

The only other thing of interest is that the -ck kernel had the WM menus appear in about 3 seconds rather than 5-8 under the other two.
The only chap that says otherwise doesn't post his results.

From TFA [kerneltrap.org]

This was already a known issue (1, Interesting)

Anonymous Coward | about 7 years ago | (#20059427)

Con's SD scheduler is light years ahead in terms of desktop computing and gaming. The "Completely Fair" Scheduler is not. Linus made a poor political decision that once again favors the multi-CPU, gobs of memory, server architecture that normal people don't give two shits about.

Vague generalizations on OS suitability (1)

MSTCrow5429 (642744) | about 7 years ago | (#20059633)

Windows is for games and office work.

OS X is for artists and people really into style.

Linux is for hackers and various niche environments.

Linux does not need to support gaming. Windows does that quite well. Anyone that wants to game can dual-boot with Windows, or buy a console. Linux will not support gaming, for the same reasons AIX or Solaris are not chock full of gaming goodness. It isn't required or desired, and the OS is far more suitable for other, often more "serious," applications.

Re:Vague generalizations on OS suitability (1)

garett_spencley (193892) | about 7 years ago | (#20060005)

Linux is for hackers and various niche environments.

While I agree that what I am about to describe can very much be considered a "niche environment", pretty much every single kernel developer develops Linux for his own desktop. Linus created Linux in the beginning so that he could have a full Unix-like OS on a 386.

So Linux' entire existence is for the desktop. It has proven to be a very great server OS as well. And a lot of people develop it for that purpose. But Linus himself, when responding to Con's claims of big money pushing server development away from desktop development was something along the lines of (paraphrased): "every single developer that I have trusted to maintain parts of the kernel run Linux on the desktop, care primarily about the desktop and I wouldn't want anyone who didn't run Linux on their desktop to ever touch the kernel".

Of course there is still the paradox. No games = no gamers. No gamers = no money for game developers = no games = no gamers and so on. But every one who has worked to made Linux what it is today wants to see it thrive on the desktop. So while your opinion is certainly valid and you're entitled to it. I don't believe that it is shared by the very people who develop Linux.

Re:Vague generalizations on OS suitability (1)

dave562 (969951) | about 7 years ago | (#20060053)

I completely agree. Every OS has it's strengths and weaknesses. I see a lot of ego among Linux users and developers. They want their OS to do EVERYTHING under the sun. I'm a Windows guy primarily, but anything that I do that relates to computer security I do on Linux (Snort, nmap, etc). It's all about flexability and choosing the right tool for the job.

any *more* setcbacks?!?!?! (0, Troll)

Bastard of Subhumani (827601) | about 7 years ago | (#20059753)

gaming on Linux can't suffer any more setbacks
In the same way that the pope can't get cervical cancer?

The past is the map to the future (1)

Danathar (267989) | about 7 years ago | (#20059795)

When there was more than one OS that ran on different HARDWARE, games could be differentiated and selling points could be made for buying an Amiga, or an Atari over the Mac and PC of the time.

Other than Security, to the average user who is using Windows there just is'nt the "Whoahh" that people used to get when somebody back then saw the Amiga or Atari. Compelling reasons just don't exist for the average user to switch from windows to LINUX except maybe fear of viruses and malware.

For games to take off on LINUX there needs to be a game done on LINUX for LINUX ONLY that everybody wants and does something on LINUX that CAN'T BE DONE on windows. When I saw what the Amiga could do commpared to the PC I KNEW why I wanted one.

Granted the Amiga was as much a hardware advancement as OS, but the point was the average user could understand why they needed it.

The X Factor (5, Interesting)

mcelrath (8027) | about 7 years ago | (#20059897)

I keep wondering...X is a single threaded server, communicating with a (generally) single threaded game. Worse, wine inserts the wineserver process, so I have three single threaded things trying to synchronize to get interactivity. A low latency event like a keypress might require all three processes to be scheduled in succession, to get a response on the screen. A poor man's way to do this is with the kernel's scheduler, but a far superior way to do it is to have multiple threads in the X server. Scheduling an interactive event isn't hard. Getting crap on the screen in the same scheduling timeslice is hard (impossible?) since it requires a second scheduling point. As I understand, this is how BeOS achieved substantial interactivity in the presence of load -- my having a multi-threaded graphics server *and* kernel.

So, how much can be gained by rewriting X, or going to a different graphics server? Or do I completely misunderstand the effect of X?

-- Bob

The Scheduler That Lived will live (1)

microbee (682094) | about 7 years ago | (#20059991)

Both SD and CFS are superior to the old one. Between the two, the one that gets merged into mainline will be the best eventually.

There were a lot of testers when SD came out, because it clearly beat the pants off the old one, and that was exactly why Ingo went ahead to throw his own version of a fair scheduler - otherwise his code would not survive.

Which one is better, SD or CFS? Technically, it was hard to say, but it's not about technology - it's like the browser war, the one with the bigger market share wins. CFS has been merged into mainline and gets the biggest exposure, so there are hell a lot of more testers and developers attention, and with a genius like Ingo, it's only a matter of time that CFS will perform better than SD - the latter has been simply ignored since CFS was out.

So arguing which one is technically better is not the point. It's like people kept arguing Netscape was better than IE. But the fact is IE eventually outperformed Netscape even technically.

A lot of people who watched the whole thing on LKML consider the decision of merging CFS was unfair, but few really worried that we'd have a worse scheduler in the long run. Get your Cause and Consequence right.

Jitter is important (4, Interesting)

dybdahl (80720) | about 7 years ago | (#20060107)

Usability research has shown, that variation in waiting time is actually a bigger irritation for users than waiting time itself.

I have seen several projects, where user interface response time problems have been "improved" by making adding a minimum response time. The average response time increases, but variation decreases, and the user often reports the program as having become faster... the logic to this seems to be, that the user wants the user interface to have a predictable response.

I think the reference for this is Søren Lauesens books about usability programming, but I cannot remember for sure right now.
Load More Comments
Slashdot Login

Need an Account?

Forgot your password?
or Connect with...

Don't worry, we never post anything without your permission.

Submission Text Formatting Tips

We support a small subset of HTML, namely these tags:

  • b
  • i
  • p
  • br
  • a
  • ol
  • ul
  • li
  • dl
  • dt
  • dd
  • em
  • strong
  • tt
  • blockquote
  • div
  • quote
  • ecode

"ecode" can be used for code snippets, for example:

<ecode>    while(1) { do_something(); } </ecode>