[AD] some questions

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


1. Why unwrite_bank is in GFX_VTABLE, while read_bank and write_bank
are in GFX_DRIVER?

2. In version 3.9.26, could configure find that MMX is supported?
Just I noticed that dummy constant is gone from the list of input
operands.  AFAIK, when there are no inputs and outputs, gcc does not
understand %%reg notation for registers and requires %reg notation.
I find it inconsistent, so in such cases I add dummy input operand to
force %%reg notation.  For MMX test look in aclocal.m4.

3. Mouse driver for Linux uses large buffer for getting data from
device driver.  But all device drivers only fill 3 first bytes in the
read call and zero out the rest of supplied buffer.  Is large buffer
used for getting gpm data (I have not looked in gpm sources)?  Or was
it just overlooked?

4. I had to use standalone asm for making bank switching routines
with conventions used when ALLEGRO_GCC and ALLEGRO_I386 are defined
(bitmap in %edx, line in %eax).  But on some other platform this
convention is not used, so these routines should be left out of
compilation.  I don't know how to do that.  It must be included only
when this convention is used, but __GNUC__ is not defined in asm with
preprocessing, so I can not test for that same condition which is used
for including this convention.  I can modify asmdef utility to output
ALLEGRO_GCC and ALLEGRO_I386 if they are defined, but it does not
smell good.  Or I can change conditions when this convention about
passing values in registers is used, for example when configure tests
for asm support, it can add define which tells if asm functions are
supported or not and later this define can be used to select
convention for calling bank switching routines and in graphics drivers
this define can be used to select whether to use asm routines or C
routines for bank switchers.  But it will be necessary to write C bank
switching routines if one wants to use C functions for graphics
primitives in GFX_VTABLE even when asm routines can be used.

BTW, X-Windows version works already (at least, exhello).

-- 
Michael Bukin



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