changeset 3136:b196b915fdc4

oops
author michael
date Mon, 26 Nov 2001 02:20:51 +0000
parents 168b7ed7ec55
children b9ee2d8d7279
files postproc/swscale.c postproc/swscale_template.c
diffstat 2 files changed, 28 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/postproc/swscale.c	Mon Nov 26 02:16:01 2001 +0000
+++ b/postproc/swscale.c	Mon Nov 26 02:20:51 2001 +0000
@@ -9,7 +9,6 @@
 #include <string.h>
 #include "../config.h"
 #include "swscale.h"
-#include "../mmx_defs.h"
 #include "../cpudetect.h"
 #undef MOVNTQ
 #undef PAVGB
--- a/postproc/swscale_template.c	Mon Nov 26 02:16:01 2001 +0000
+++ b/postproc/swscale_template.c	Mon Nov 26 02:20:51 2001 +0000
@@ -7,6 +7,34 @@
 
 #undef MOVNTQ
 #undef PAVGB
+#undef PREFETCH
+#undef PREFETCHW
+#undef EMMS
+#undef SFENCE
+
+#ifdef HAVE_3DNOW
+/* On K6 femms is faster of emms. On K7 femms is directly mapped on emms. */
+#define EMMS     "femms"
+#else
+#define EMMS     "emms"
+#endif
+
+#ifdef HAVE_3DNOW
+#define PREFETCH  "prefetch"
+#define PREFETCHW "prefetchw"
+#elif defined ( HAVE_MMX2 )
+#define PREFETCH "prefetchnta"
+#define PREFETCHW "prefetcht0"
+#else
+#define PREFETCH "/nop"
+#define PREFETCHW "/nop"
+#endif
+
+#ifdef HAVE_MMX2
+#define SFENCE "sfence"
+#else
+#define SFENCE "/nop"
+#endif
 
 #ifdef HAVE_MMX2
 #define PAVGB(a,b) "pavgb " #a ", " #b " \n\t"