mmx: prepare pixman-mmx.c to be compiled for ARM/iwmmxt
authorMatt Turner <mattst88@gmail.com>
Sun, 4 Sep 2011 18:11:46 +0000 (14:11 -0400)
committerMatt Turner <mattst88@gmail.com>
Tue, 27 Sep 2011 17:13:07 +0000 (13:13 -0400)
Signed-off-by: Matt Turner <mattst88@gmail.com>
pixman/pixman-mmx.c

index 0317b9a..801ae32 100644 (file)
@@ -33,7 +33,7 @@
 #include <config.h>
 #endif
 
-#ifdef USE_X86_MMX
+#if defined USE_X86_MMX || defined USE_ARM_IWMMXT
 
 #include <mmintrin.h>
 #include "pixman-private.h"
 #define CHECKPOINT()
 #endif
 
+#ifdef USE_ARM_IWMMXT
+/* Empty the multimedia state. For some reason, ARM's mmintrin.h doesn't provide this.  */
+extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__))
+_mm_empty (void)
+{
+
+}
+#endif
+
 /* Notes about writing mmx code
  *
  * give memory operands as the second operand. If you give it as the
@@ -3218,4 +3227,4 @@ _pixman_implementation_create_mmx (pixman_implementation_t *fallback)
     return imp;
 }
 
-#endif /* USE_X86_MMX */
+#endif /* USE_X86_MMX || USE_ARM_IWMMXT */