--- portab.h 2002/03/16 14:15:10 1.2 +++ portab.h 2002/03/20 14:02:48 1.4 @@ -31,6 +31,9 @@ #define EMMS() __asm {emms} +#define CACHE_LINE 16 +#define CACHE_ALIGN __declspec(align(CACHE_LINE)) + // needed for bitstream.h #define BSWAP(a) __asm mov eax,a __asm bswap eax __asm mov a, eax @@ -52,6 +55,9 @@ #elif defined(LINUX) || defined(DJGPP) + +#ifdef _DEBUG + #include #define DEBUG_WHERE stdout #define DEBUG(S) fprintf(DEBUG_WHERE, "%s\n", (S)); @@ -59,6 +65,16 @@ #define DEBUG2(S,A,B) fprintf(DEBUG_WHERE, "%s%i=%i\n", (S), (A), (B)) #define DEBUG3(S,A,B,C) fprintf(DEBUG_WHERE, "%s %i %x %x\n", (S), (A), (B), (C)) #define DEBUG8(S,A,B,C,D,E,F,G,H) +#else +#define DEBUG(S) +#define DEBUG1(S,I) +#define DEBUG2(X,A,B) +#define DEBUG3(X,A,B,C) +#define DEBUG8(X,A,B,C,D,E,F,G,H) +#endif + +#define CACHE_LINE 16 +#define CACHE_ALIGN #if defined(LINUX) @@ -116,6 +132,9 @@ return 0; } +#define CACHE_LINE 16 +#define CACHE_ALIGN + #endif #endif // _PORTAB_H_