On Thu, 2005-03-24 at 23:56 -0600, Joseph Wagner wrote: > Hello Linux Naysayers! > > You may remember about two months ago I started a flame war asking why RPM > packages were still optimized for 386. The best answer I heard said that > the powers-that-be do not believe there would be a noticeable improvement, > and if I wanted to affect real change I would need to prove them wrong. I heard something somewhat different ;-) The compiler folks at Red Hat benchmark this *all the time*. Basically for every new spin of the compiler. The *compiler* has one difference in the code it generates with the current fedora settings and an "i686" setting as you would call it, and that is the use of the cmov instruction. Our benchmarks (which are unfortunately not publishable due to restrictions imposed by the benchmark) show that cmov is a small gain for some processors, but is actually a small loss for the current generation pIV processors. For most processors (including all AMD ones) it just doesn't make any measurable difference at all. (with "small" you should think of in the order of 5% in a cpu bound setup; if you're not cpu bound all this doesn't matter anyway) Now, if you want to actually build a distro with different compiler flags that actually are really different in a more significant way, I would suggest that you experiment with the -Os flag, eg optimize for code size. The effects of optimizing for size are less well known, because in a compiler output microbenchmark (as mentioned above) you will see some stuff getting somewhat worse, but there is a macro effect that can compensate because code takes less space, eg you can save cache and even disk IOs potentially. (note for cmov there is no such macro effect) I don't want to tell you that you shouldn't do what you're going to do, I just want to suggest to read the posts again about why the fedora flags are what they are (and those decisions are made based on measurements and based on information provided by the people who wrote the compiler, eg who know what those flags actually do), and that if you still want to do an experiment, that you do one which actually has a chance of making a real difference...
Description: This is a digitally signed message part