From 2dc621f3fdb585f23013aa3e220f2148f9405538 Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Thu, 11 Dec 2003 16:25:36 +0000 Subject: Updates to tnl_dd_dmatmp.h - Allocate vertices explicitly, rather than trying to talk about dma buffers. - Clean up the various Flush() operations. - Don't allow fallbacks any longer. Provide a support function to detect them ahead o ftime Updates to tnl_dd_vbtmp.h - Get rid of power-of-two vertex strides. Pack all vertices tightly. - Get texunit 2,3 emit working coorrectly. Other stuff: - Get rid of lingering Ubyte color support. - Fix a few compiler warnings. --- src/mesa/drivers/dri/r200/r200_maos_arrays.c | 52 +++++++++++++++------------- 1 file changed, 27 insertions(+), 25 deletions(-) (limited to 'src/mesa/drivers/dri/r200/r200_maos_arrays.c') diff --git a/src/mesa/drivers/dri/r200/r200_maos_arrays.c b/src/mesa/drivers/dri/r200/r200_maos_arrays.c index 6c6013054a..9d1724db7e 100644 --- a/src/mesa/drivers/dri/r200/r200_maos_arrays.c +++ b/src/mesa/drivers/dri/r200/r200_maos_arrays.c @@ -50,6 +50,8 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "r200_swtcl.h" #include "r200_maos.h" + +#if 0 /* Usage: * - from r200_tcl_render * - call r200EmitArrays to ensure uptodate arrays in dma @@ -81,29 +83,6 @@ static void emit_ubyte_rgba3( GLcontext *ctx, } } - -#if defined(USE_X86_ASM) -#define COPY_DWORDS( dst, src, nr ) \ -do { \ - int __tmp; \ - __asm__ __volatile__( "rep ; movsl" \ - : "=%c" (__tmp), "=D" (dst), "=S" (__tmp) \ - : "0" (nr), \ - "D" ((long)dst), \ - "S" ((long)src) ); \ -} while (0) -#else -#define COPY_DWORDS( dst, src, nr ) \ -do { \ - int j; \ - for ( j = 0 ; j < nr ; j++ ) \ - dst[j] = ((int *)src)[j]; \ - dst += nr; \ -} while (0) -#endif - - - static void emit_ubyte_rgba4( GLcontext *ctx, struct r200_dma_region *rvb, char *data, @@ -129,7 +108,6 @@ static void emit_ubyte_rgba4( GLcontext *ctx, } -#if 0 static void emit_ubyte_rgba( GLcontext *ctx, struct r200_dma_region *rvb, char *data, @@ -176,6 +154,30 @@ static void emit_ubyte_rgba( GLcontext *ctx, #endif +#if defined(USE_X86_ASM) +#define COPY_DWORDS( dst, src, nr ) \ +do { \ + int __tmp; \ + __asm__ __volatile__( "rep ; movsl" \ + : "=%c" (__tmp), "=D" (dst), "=S" (__tmp) \ + : "0" (nr), \ + "D" ((long)dst), \ + "S" ((long)src) ); \ +} while (0) +#else +#define COPY_DWORDS( dst, src, nr ) \ +do { \ + int j; \ + for ( j = 0 ; j < nr ; j++ ) \ + dst[j] = ((int *)src)[j]; \ + dst += nr; \ +} while (0) +#endif + + + + + static void emit_vec4( GLcontext *ctx, struct r200_dma_region *rvb, char *data, @@ -235,7 +237,7 @@ static void emit_vec12( GLcontext *ctx, if (R200_DEBUG & DEBUG_VERTS) fprintf(stderr, "%s count %d stride %d out %p data %p\n", - __FUNCTION__, count, stride, out, (void *)data); + __FUNCTION__, count, stride, (void *)out, (void *)data); if (stride == 12) COPY_DWORDS( out, data, count*3 ); -- cgit v1.2.3