Complete.Org: Mailing Lists: Archives: freeciv-dev: March 2005:
[Freeciv-Dev] Re: Render speed test with imlib/xrender/sdl/pixbuf/ftwl
Home

[Freeciv-Dev] Re: Render speed test with imlib/xrender/sdl/pixbuf/ftwl

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Per Inge Mathisen <per@xxxxxxxxxxx>
Cc: freeciv development list <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: Render speed test with imlib/xrender/sdl/pixbuf/ftwl
From: Raimar Falke <i-freeciv-lists@xxxxxxxxxxxxx>
Date: Tue, 22 Mar 2005 20:03:53 +0100

On Mon, Mar 21, 2005 at 09:35:38PM +0000, Per Inge Mathisen wrote:
> On Mon, 21 Mar 2005, Raimar Falke wrote:
> > The task is to blit 4096 times a 100x100 png picture with alpha
> > channel to a 320x320 png picture. The position varies based on a
> > PRNG. Afterwards the result is shown to make sure that all produce the
> > same results. This task was previously identified as the main
> > bottleneck (about 80% of the CPU time) in the ftwl client.
> >
> > Results for my computer:
> > Time: 0.310 sec for Imlib2 off-screen.
> > Time: 0.584 sec for FTWL off-screen.
> > Time: 1.169 sec for pixbuf off-screen.
> > Time: 1.875 sec for Xrender on-screen.
> > Time: 1.899 sec for Xrender off-screen.
> > Time: 2.662 sec for SDL off-screen.

> It looks like you forgot to change the SDL surface to the display format.
> This would explain the poor SDL performance, most likely.

Only the output is blitted to the display surface. Once and this is
not included in the timing. Feel free to point out errors/improvements
in the source code.

> > If I disable the MMX support in imlib it produces
> > Time: 1.184 sec for Imlib2 off-screen.
> >
> > Some remarks:
> >
> > It looks like SDL doesn't use MMX. I'm using however the rpm from
> > fedora core 3.
> 
> This is a big problem. Many packages are compiled for the least common
> denominator, and that excludes important optimizations like MMX/SSE/SSE2,
> that make a big difference to things like this. So libraries that you
> compile from source may optimize a lot better for your specific computer,
> but this might be a deception. Once your program is out being distributed
> as everything else, your careful optimizations that depend on CPU-specific
> instructions may also be thrown to the wind.

Maybe I will compile SDL from source. Stay tuned.

        Raimar

-- 
 email: i-freeciv-lists@xxxxxxxxxxxxx
 "If at first you don't succeed... well so much for skydiving."



[Prev in Thread] Current Thread [Next in Thread]