Gentoo Optimizations Benchmarked – Part 2

Gentoo is a source based distribution which lets the user decide how to optimize their system in many ways and includes building for a specific CPU architecture. Linux Magazine benchmarks four such options; i486, i686, pentium3, core2, and throws in Ubuntu for good measure.


The results of the tests show that the biggest jump in performance is from i486 to i686 and that there is not much extra to gain from then on. One would have expected to have seen a greater advantage for the more optimised binaries when it came to encoding, however this also comes down to the program itself and whether it can make use of extensions such as MMX and SSE (something which an i486 binary can still do).

The biggest surprise was in Ogg encoding, where the Core2 system was twice as slow as others, including Pentium3! This does not seem right, however the test was repeated several times, all with the same results. This may be an issue with the Ogg encoder itself, when used with the highly optimized Core2 binary.

Yes, we are not comparing even systems here, but it’s interesting to note that Ubuntu faired well in some tests, but fell behind in others. Generally, it performed at or below the Gentoo i486 level. The main benefit that Gentoo has over Ubuntu is the ability to fine tune the system, leaving out what you don’t want and including those components you do. This means the system can be more lean, which results in better performance and less overhead. The systems used in these tests were already very lean, with just X.Org and Xfce4.

So does it pay to optimize your operating system specifically for your CPU? It sure does, but only just. Performance of the Core2 binaries over i686 was marginal and certainly there was a much larger performance gain from i486 to i686. Nevertheless, combining a CPU optimized binary with a specific GCC optimization (such as -Os) to fit your specific requirements may well be a very attractive proposition. Of course, the question will be whether the trade-off between compile time and performance gain is worthwhile, but then, that’s not what Gentoo’s really about.


At its core, Gentoo is about flexibility, not about optimizing code to run the fastest. It’s about being able to make your system whatever you want it to be, through the use of USE flags. While primarily referring to extra GCC optimizations (and not the basic CPU architecture and optimization level), the Gentoo Optimization Guide says the following:

“While CFLAGS and CXXFLAGS can be very effective means of getting source code to produce smaller and/or faster binaries, they can also impair the function of your code, bloat its size, slow down its execution time, or even cause compilation failures.

CFLAGS are not a magic bullet; they will not automatically make your system run any faster or your binaries to take up less space on disk. Adding more and more flags in an attempt to optimize your system is a sure recipe for failure. There is a point at which you will reach diminishing returns.

Despite the bragging you’ll find on the internet, aggressive CFLAGS and CXXFLAGS are far more likely to harm your programs than do them any good. Keep in mind that the reason the flags exist in the first place is because they are designed to be used at specific places for specific purposes. Just because one particular CFLAG is good for one bit of code doesn’t mean that it is suited to compiling everything you will ever install on your machine!”

So there you have it, straight from the horse’s mouth. Despite the reputation it has gathered over time due to a small minority, Gentoo is not about highly optimizing your system to get that “extra 1% performance.” Rather, it’s strength lies in the flexibility provided by its package management system.

Nevertheless, these tests do show that as a result of compiling from source, Gentoo offers some ever-so-slight additional benefits in performance (from i686 to Core2) which can be utilised to the user’s advantage. In reality however, these benefits are so tiny that they simply might not justify it (and will also make the system less portable). The combination of a specific GCC optimization level such as -Os is probably a better reason for building from source.

It’s fair to say that optimizing for a specific CPU architecture over i686 does not result in a sizeable performance increase. It was however, common to see a 20% performance increase over the i486 systems. What does make a huge increase (primarily in encoding and cryptography) is in the use of CPU instructions such as MMX and SSE. This really comes down to the coding of a particular application and whether it includes the ability to use them or not. An application built for i686 can still make use of these, thus being able to take advantage of both worlds – being a low common denominator and still making use of faster, more modern CPUs.

We must also remember that benchmarks are just benchmarks and are not necessarily a true representation of real world environments. There are lots of other factors which come into play, including the amount of other processes running and resources used on the system. This is usually where Gentoo has a major advantage, because users can easily strip out all the extras that their system doesn’t need.

So, while optimizing your computer for a specific CPU may not be everything, if you’re building from source anyway then applying some specific optimizations for your system generally isn’t going to hurt (especially if you can take advantage of CPU instruction sets). And besides, it’s a whole lot of fun!

Comments on "Gentoo Optimizations Benchmarked – Part 2"

Hello mates, how is the whole thing, and what you desire tto say on the topic of this post, in my view
its genuinely awesome in support of me.

My blog post … cheap car insurance in pa

WOW just what I was searching for. Came here by searching for cheap car insurance comparison sites

I just like the valuable information you provide inn your articles.
I will bookmark your weblog and take a look at once more here
regularly. I am reasonably certain I’ll be informed majy new stuff right right here!
Good luck for the next!

Check out my blog :: cheap car insurance in pa

Excellent beat ! I would like to apprentice at
the same time as you amend your web site, hhow coul i subscribe for a weblog site?

The account aided me a applicable deal. I had been a little bitt familiar of this your broadcast offered bright transparent concept

Take a lok at my web blog … cheap car insurance

Your means of explaining the whole thing in this article is in fact pleasant, every one can withouut difficulty understand it,
Thanks a lot.

Chesck out my web page: cheap car insurance in sc

Thhis is a topic that is near tto my heart… Best wishes!
Where are your contact details though?

Check out my webpage :: Cheap car insurance

you’re actually a just right webmaster. The website loading pace is incredible.
It kind of feels that you’re doing any unique trick.
Furthermore, The contents are masterwork. you have done a great job on this subject!

My webpage: cheapest car insurance companies

Very nice post. I just stumbled upon our weblog and wished to say that I have
truly enjoyed surfiing around your blo posts. After all
I will be subscribing too your feed and I
hope youu write again soon!

Feel free to visit my website … Cheap Car Insurance

Because the admin of this site is working, no hesitation very
soon it will be renowned, due to its feature contents.

Here is my page: classic car insurance companies

Ahaa, its pleasant discuussion regarding this
piece of writing at this place at this website, I have read
all that, so now me also commenting here.

My blog: Cheap Car Insurance

Hi i am kavin, its my first occasion tto commenting
anywhere, when i read this piece of writung i thought i could alsso make comment due
to thus good piece of writing.

Feel free to surf to my page cheap car insurance in nj

We’re a group of volunteers and starting a new scheme in our community.
Your site provided us with valuable info to
work on. You’ve done an impressive job and our whole community will be thankful to you.

Here is my webpage – classic car insurance companies

Pretty nice post. I just stumbled upon your weblog and wanted to say
that I have truly enjoyed surfing around your blog posts.
After all I’ll bbe subscribing to yur rss feed and I hope you write again very soon!

my web-site; cheap car insurance near me

Hi, I believe your wsbsite could be having browser compatibility issues.
Whenever I take a llook at your site in Safari, itt loks fine but when opening in Internet
Explorer, it’s got some overlapping issues.
I just wanted to give you a quick heads up! Aside from that, wonderful

Feel free to surf to my weblog :: Cheap Car Insurance

Afer looking intoo a handful of the articles on your site, I honestly appreciate your technique of blogging.
I book-marked it to my bookmark webpage list and will be checking back
soon. Please visit my web sote too and let me know how
you feel.

Review myy web page :: cheap car insurance for teens

You are so awesome! I do not suppose I’ve read through something llike tis before.
So wonderful to find another person with unique thoughts on this
subject matter. Really.. thanks for starting this up.
This website is one thing that is needed on the web, someone with some originality!

Check out my web blog – very cheap car insurance

Hello, Neat post. There is an issue togethedr with your site in web explorer, could
test this? IE nonetheles is the market leader and
a large pportion oof other folks will omt your great writing due to this problem.

Feel free to visit my web page: cheap car insurance

Hi i am kavin, its my first occasio to commentkng anywhere, when i read this article i thought i could also make comment due to this brilliant article.

Have a look at my webpage :: cheap car insurance in michigan

Valuable info. Lucky me I found your website by chance,
and I’m shocked why this twist of fate did nnot took ppace in advance!
I bookmarked it.

My homepage … Cheap Car Insurance

Yes! Finally someone writes about cheap car insurance quotes tthe general.

If you would like too obtain much from this post then you have
to apply these methods to your won web site.

Feeel free to surf to my website: Cheap car insurance

Hello this is kinda of offf topic but I was wondering if blogs use WYSIWYG editors oor if you have to manually code with HTML.

I’m starting a blog soon but have no coding know-how
so I wanted too get advice from someone with experience.
Any help woulkd be enomously appreciated!

Feel free to surf to my blog post – cheap car insurance in michigan

Hmm it looks like your blog ate mmy first comment (it was extremely long) sso I guess I’ll just sum it
up what I submitted and say, I’m thoroughly
enjoying your blog. I too am an aspiring blog blogger but I’m still new to
the wbole thing. Do youu have any recommendations
for beginner blog writers? I’d definitely appreciate it.

My web blog: cheap car insurance in california

Thank you for the auspicious writeup. It inn reality was once a enjoyment account it.

Look advanced to far introduced agreeble from you! By the way, how can wwe be in contact?

Look into my homepage :: Cheap car insurance

I read this article fully regarding the resemblance of newest and previous technologies, it’s awesome

Feel free to surf to myy homepage … cheap car insurance in ma

Keep on working, great job!

Feel free to surf tto my web-site … cheap car insurance in pa

Just desire to say your article is as astonishing.
The clarity in your post is simply nice and i can assume you are an expert on this
subject. Well with your permission allow me to
grab your RSS feed to keep up to date with forthcoming post.

Thanks a million and please keep up the gratifying work.

Here is my weblog cheap car insurance in sc

I value the post. Keep writing.

Great blog article.Really looking forward to read more. Fantastic.

Right here is the perfect web site for anybody who
wishes to understand this topic. You realize a whole lot its
almost tough to argue with you (not that I actually will need to…HaHa).
You definitely put a brand new spin on a subject that’s been written about for years.
Great stuff, just wonderful!

BC?’s CPA in Bangalore Enabnl? Effective Running
of A Business opportunity ?ender. After r?aching my accointant and re?aying my conc?rns, the ne?xt
attribute worth addressing is communication. Studies ?urrentl? have shown which, about average, CPAs eadn 10% more than non-CPA

My web-site; boca raton Wealth management Firms

Please pay a visit to the web-sites we stick to, which includes this a single, as it represents our picks in the web.

Leave a Reply