Image Image Image ImageImage
Creative Services for
Roughly Drafted
Daniel Eran

Image Image

Unraveling The Mac OS X Linux Kernel Myth: Part 2
According to proponents of this myth, Apple will, could, or should shortly replace Mac OS X's kernel with Linux. They're wrong; here's why.

Page 1 | 2 | 3 | 4

Part 1 introduced the myth and looked at the buzz behind Linux. Here in Part 2, I'll take apart a second argument given for moving Mac OS X to a Linux kernel:

Linux' Performance
Performance comes through optimization. The fastest cars on the road have specialized tires, huge engines, and throw out every unnecessary pound of weight to make them light, fast and zippy. They're optimized, but only for speed. If you've ever driven a super elite sports car, you'll probably remember how uncomfortably cramped they are, how few kids you can cram in the back seat, and how there's no real stereo system or air conditioning.

One of Linux' primary advantages is its flexibility in optimization. You can build a tiny Linux or a supercomputer monster Linux. You can tailor Linux to serving webpages or database requests, or to run a PVR, PBX, or a PDA.

The only thing Linux has had real trouble with is capturing the consumer desktop market. No major hardware vendors are currently pushing Linux as a real Windows replacement; few even offer a token product. At least for now, Linux' strengths have been applied elsewhere.

That makes it difficult to make clear and substantial comparisons between Mac OS X, which is sold almost exclusively as a friendly desktop, and Linux, which has been profitable, popular, and optimized for nearly everything but use a friendly desktop. So what's the basis for saying that Linux has a much faster kernel than Mac OS X's?

According to Mark Stephens (writing as Robert X Cringely):

"Why would Apple want a new kernel? Speed. Quite simply, a monolithic kernel like the one used in Linux or most of the other Open Source Unix clones is inherently two to three times faster for integer calculations than the Mach microkernel presently used in OS X 10.4. That's why the world hasn't embraced xServes, for example, because for simple web or database service they are slower and serve fewer users."

His sweeping generalization is wrong on many counts: he's been duped by the Mac OS X Microkernel Myth, he makes a wild stab into fiction by referring to integer calculations, and he mismingles speculation about the Xserve's mindshare with his unsupported assumptions about performance.

He does prove a great point however: speaking confidently from your gut can make what you say sound convincing even if you don't have any facts. It's called truthiness. Where did Cringely get his gut feeling that a different kernel would be, not just potentially somewhat faster, but "inherently" several times faster?

No doubt from a couple of highly publicized benchmark tests comparing Mac OS X systems with Linux servers. In each case, those doing the benchmarks had little understanding of how Mac OS X works or how to optimize its performance, but did use optimizations for Linux. Sound suspicious?

Lies, Damn Lies, and Statistics
The problem with publishing statistics, such as benchmarks, is that it is very challenging to correctly present unbiased, accurate information, yet very easy to publish grossly misleading results that seem to prove fictions in very convincing ways. To prove a hypothesis, scientific testing has to control the variables involved and include enough data points to draw real conclusions.

For example, if you wanted to accurately compare the performance of two brands of hard drives, you'd control variables by using the same capacity drives, performing the same tasks on them in the same ways, and operating them in the same environment. To include enough data points, you'd use a range of different tests that compared both reading vs. writing; continuous sustained activity vs. short burst access; and moving around a few very large files vs. many small files. You might even test several different drive units.

If you didn't control variables or do sufficient testing, you would get information that has little correlation with reality. Plugging that into a fancy chart might look nice and be convincing, but it would be misinformation, regardless of whether you were being deviously malicious or just sloppy and incompetent.

How well do the Linux vs. Mac OS X benchmarks do in this regard? Consider two recent examples: Anandtech and UCB's Sekhon.

Continued: Anandtech's 'No More Mysteries' Server Benchmarks


More Journal Entries | More Tech Articles | Get Tech Support | My Resume | Links | Contact RoughlyDrafted

Articles Copyright © 2006 Daniel Eran. All rights reserved.
Suggestions and comments welcome. Contact RoughlyDrafted.

Read more about:
Click one of the links above to display related articles on this page.