--- programs/Xserver/fb/fbmmx.c.orig 2005-04-03 21:33:40.000000000 +0200 +++ programs/Xserver/fb/fbmmx.c 2005-04-03 22:28:20.000000000 +0200 @@ -33,10 +33,18 @@ #include "mipict.h" #include "fbpict.h" +#if __GNUC__ >= 4 +#include +typedef __m64 Vector1x64; +typedef int Vector2x32 __attribute__ ((vector_size (8))); +typedef short Vector4x16 __attribute__ ((vector_size (8))); +typedef char Vector8x8 __attribute__ ((vector_size (8))); +#else typedef int Vector1x64 __attribute__ ((mode(DI))); typedef int Vector2x32 __attribute__ ((mode(V2SI))); typedef int Vector4x16 __attribute__ ((mode(V4HI))); typedef int Vector8x8 __attribute__ ((mode(V8QI))); +#endif typedef unsigned long long ullong; @@ -92,9 +100,9 @@ shift (Vector1x64 v, int s) { if (s > 0) - return __builtin_ia32_psllq (v, s); + return (Vector1x64) __builtin_ia32_psllq ((long long) v, s); else if (s < 0) - return __builtin_ia32_psrlq (v, -s); + return (Vector1x64) __builtin_ia32_psrlq ((long long) v, -s); else return v; }