RE: [AD] minor issues

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


Lines aren't aligned in Allegro. If you have an 8-bpp 7-pixel wide
bitmap, 7 of every 8 lines won't be 8-byte aligned. It would be nice to
add this, but it's likely to break existing code that assumes contiguous
memory for memory bitmaps that aren't subbitmaps.




-----Original Message-----
From: alleg-developers-admin@xxxxxxxxxx
[mailto:alleg-developers-admin@xxxxxxxxxx] On Behalf Of Evert
Glebbeek
Sent: Friday, January 28, 2005 1:51 AM
To: alleg-developers@xxxxxxxxxx
Subject: Re: [AD] minor issues

> if line length is not on 4 or 8 byte boundarys  would MMX be slower
due
> to
> alignment problems ?

I *think* there's code in Allegro that tries to align bitmaps lines on a
4
 byte boundary, but I can be mistaken here. I'd have to look at the
source
to make sure.

> if memory bitmaps are to be made solid (zero extra bytes to make pitch
4
> or
> 8 byte boundarys) than SSE1,2,3  code will be far more difficult.
> As memory usage is hardly an issue anymore.. (even gfx cards have more
> memory on them than the average game uses);  is there any reason to be
> concerned with using a few extra bytes per line to achieve 4 or 8 byte
> boundarys.

Not as far as I'm concerned. Presently, Allegro doesn't use SSE3, what
advantages could be implemented for this now that we have code to detect
it?

> SSE can offer some really cool instructions that would allow lots of
> pixels
> to be processed simultaneously... lets not design the bitmap structure
> so
> we can not take advantage of these.

Agreed. Probably something we can do for 4.3?

> if the tests below are somehow only better on P4 but worse on
> Athlon/P3/non-P4  then it should not be implemented, as your average
> user
> still would not be using a P4.

True, but we could detect at runtime what we're using and use P4
optimized
if we're running on a P4.

Evert


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
-- 
https://lists.sourceforge.net/lists/listinfo/alleg-developers




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