1 /* $Id: bitmap.h,v 1.3 2002-07-17 21:55:19 bradleyb Exp $ */
7 void decode_data_asm(ubyte *data, int num_pixels, ubyte * colormap, int * count );
8 #pragma aux decode_data_asm parm [esi] [ecx] [edi] [ebx] modify exact [esi edi eax ebx ecx] = \
12 "inc dword ptr [ebx+eax*4]" \
18 #elif defined __GNUC__
19 static inline void decode_data_asm(ubyte *data, int num_pixels, ubyte * colormap, int * count ) {
21 __asm__ __volatile__ (
25 "incl (%%ebx, %%eax, 4);"
26 "movb (%%edi, %%eax), %%al;"
31 : "=S" (dummy[0]), "=c" (dummy[1]), "=D" (dummy[2]), "=b" (dummy[3])
32 : "0" (data), "1" (num_pixels), "2" (colormap), "3" (count)
35 #elif defined _MSC_VER
36 __inline void decode_data_asm(ubyte *data, int num_pixels, ubyte * colormap, int * count )
46 inc dword ptr [ebx+eax*4]
55 #define NO_ASM 1 // We really do want no assembler...
60 static void decode_data_asm(ubyte *data, int num_pixels, ubyte *colormap, int *count)
65 for (i = 0; i < num_pixels; i++) {
68 *data = colormap[mapped];