GCC Optimization

Roger Merchberger zmerch-lfs at 30below.com
Mon Feb 12 09:36:35 PST 2007

Rumor has it that Randy McMurchy may have mentioned these words:
>Athena P wrote these words on 02/10/07 13:04 CST:
> > And, finally, in terms of pure performance (speed) is all this
> > optimization really worth the effort?
>IMHO, a definite no. Not only will you not see the performance
>gain in day-to-day use of the system, you'll end up having issues
>that you will have trouble diagnosing.

You've _obviously_ never run Linux (let alone built LFS) on a Crusoe-based 
system... ;-)

A highly optimized LFS is the *only* way I can play any type of video on my 
933Mhz Crusoe (Fujitsu Lifebook P2120) - With every linux distro & Win2K & 
XP I've tried, I get fudged audio and more dropped frames than you can 
shake a stick at, at 100% CPU utilization. With a non-optimized LFS (but 
highly optimized mplayer app), I get *some* dropped frames, but audio is 
usually OK, and 100% CPU utilization. Swap is also a necessary evil (with a 
4200RPM drive, it's evil... ;-) with all of the above.

With a highly optimized LFS, ("-Os and a bajangle of other stuff I'd 
glommed from the 'net - don't remember now as it's been a couple of years) 
- but GCC wasn't optimized, and glibc was "1/2 optimized" - I went with -O2 
and pared about 1/2 of the extra flags out if they caused `make check` to 
fail - and I can play DVDs full screen with about 55-60% CPU utilization, 
no dropped frames, audio, I can browse the InterWeb at the same time, and I 
have yet to need to turn swap on...

I have several other examples, but that one was the most dramatic. ;-)

Roger "Merch" Merchberger

Roger "Merch" Merchberger  --  SysAdmin, Iceberg Computers
zmerch at 30below.com

Hi! I am a .signature virus.  Copy me into your .signature to join in!

More information about the lfs-support mailing list