[MPlayer-dev-eng] [RFD] Something...

Gábor Lénárt lgb at lgb.hu
Sun Apr 13 13:29:34 CEST 2003


On Sun, Apr 13, 2003 at 01:22:52PM +0200, Daniel Egger wrote:
> Am Son, 2003-04-13 um 09.04 schrieb Gábor Lénárt:
> 
> > It's NOT that simple. For most cases maybe you're right. But not always.
> > First of all, optimizing for memory usage and optimizing for speed are somewhat
> > different things and cannot be done easily for these two goals at the same
> > time!
> 
> Wrong. It's all about cache, the speed of the CPU vs. RAM accesses is diverging *so*
> rapidly that anything showing cache trashing behaviour will be automatically slow.

Not at all, because maybe you're rich enough to get FAST machines, but
for example I have AMD K6/2 400MHz at my home city. Optimizing for speed
may result in unrolled loops and so, therefore BIGGER code. But for getting
SMALL code, you may loose speed.
 
> This is a major paradigm change because formerly it was only the
> conditionals that slowed code down which was tackled doing heavy loop
> unrolling but on modern CPUs unrolled loops tend to be slower than
> straight forward (and predictable) small code.

Yes, but as I've said not the whole world can buy recent machines ...

> 
> For kicks (on a modern CPU like an Athlon XP, Hammer, Pentium IV) try compiling mplayer
> with loop unrolling off and -Os instead of -O > 1.
> 
> -- 
> Servus,
>        Daniel



> _______________________________________________
> MPlayer-dev-eng mailing list
> MPlayer-dev-eng at mplayerhq.hu
> http://mplayerhq.hu/mailman/listinfo/mplayer-dev-eng


-- 
- Gábor (larta'H)



More information about the MPlayer-dev-eng mailing list