diff i386/dsputil_mmx.c @ 1565:1a9a63f59849 libavcodec

minor mmx2 optimization if the dct
author michael
date Thu, 23 Oct 2003 13:22:20 +0000
parents 3b31998fe22f
children 396e8526e82c
line wrap: on
line diff
--- a/i386/dsputil_mmx.c	Thu Oct 23 12:59:21 2003 +0000
+++ b/i386/dsputil_mmx.c	Thu Oct 23 13:22:20 2003 +0000
@@ -1603,8 +1603,13 @@
         const int idct_algo= avctx->idct_algo;
 
 #ifdef CONFIG_ENCODERS
-        if(dct_algo==FF_DCT_AUTO || dct_algo==FF_DCT_MMX)
-            c->fdct = ff_fdct_mmx;
+        if(dct_algo==FF_DCT_AUTO || dct_algo==FF_DCT_MMX){
+            if(mm_flags & MM_MMXEXT){
+                c->fdct = ff_fdct_mmx2;
+            }else{
+                c->fdct = ff_fdct_mmx;
+            }
+        }
 #endif //CONFIG_ENCODERS
 
         if(idct_algo==FF_IDCT_AUTO || idct_algo==FF_IDCT_SIMPLEMMX){