Re: [AD] minor issues

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On Thu, 2005-01-27 at 12:16 +0100, Milan Mimica wrote:
> Elias Pschernig wrote:
> > 
> > Hm, I guess, memset() makes use of special asm instructions which
> > allegro's clear does not, or something. Can you post a simple test
> > program which compares the two, and if possible, a patch which does the
> > change - so the old vs. new clear_bitmap could be directly compared.
> 
> Attached patch and the test progam.
> Here are my test results on linux, P4:
> 

Thanks! I'll try later.

> patched:
> 15-bit: 2000 calls, 1.105000 ms per call
> 16-bit: 2000 calls, 1.115000 ms per call
> 24-bit: 2000 calls, 1.870000 ms per call
> 32-bit: 2000 calls, 2.650000 ms per call
> 
> vanilla:
> 15-bit: 2000 calls, 1.475000 ms per call
> 16-bit: 2000 calls, 1.465000 ms per call
> 24-bit: 2000 calls, 2.225000 ms per call
> 32-bit: 2000 calls, 2.655000 ms per call
> 

Definitely looks like an improvement. I guess Bob's MMX clear is
optimized for non-memory bitmaps.

> I was wondering, is it OK to clear the 16th bit when in 15-bit mode?
> 

Yes, the current 15-bit vtable simply uses the 16-bit clear as well.

-- 
Elias Pschernig





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/