]> git.sesse.net Git - ffmpeg/commitdiff
x86/dsputil: add emms to ff_scalarproduct_int16_mmxext()
authorJames Almer <jamrial@gmail.com>
Wed, 5 Mar 2014 22:44:36 +0000 (19:44 -0300)
committerMichael Niedermayer <michaelni@gmx.at>
Thu, 6 Mar 2014 17:23:55 +0000 (18:23 +0100)
Also undo the changes to ra144enc.c from previous commits.
Should fix ticket #3429

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/ra144enc.c
libavcodec/x86/dsputil.asm

index 7f7c9f39b7f2c5d6b0f667a4a4f8f567d33b40bc..1f4e5bae45b8a8a249f04c16cd2106b1f628f522 100644 (file)
@@ -34,7 +34,6 @@
 #include "mathops.h"
 #include "put_bits.h"
 #include "ra144.h"
-#include "libavutil/x86/cpu.h"
 
 static av_cold int ra144_encode_close(AVCodecContext *avctx)
 {
@@ -376,8 +375,6 @@ static void ra144_encode_subblock(RA144Context *ractx,
 
         ff_copy_and_dup(ractx->buffer_a, ractx->adapt_cb, cba_idx + BLOCKSIZE / 2 - 1);
         m[0] = (ff_irms(&ractx->dsp, ractx->buffer_a) * rms) >> 12;
-        if (!EXTERNAL_SSE2(av_get_cpu_flags()))
-            emms_c();
     }
     fixed_cb_search(work + LPC_ORDER, coefs, data, cba_idx, &cb1_idx, &cb2_idx);
     for (i = 0; i < BLOCKSIZE; i++) {
index 7162034c67485aba3deae5b66e4fe8a4306fd381..d802368e1a6239b68b6683338368911d3162bbdd 100644 (file)
@@ -61,6 +61,9 @@ cglobal scalarproduct_int16, 3,3,3, v1, v2, order
 %endif
     paddd   m2, m0
     movd   eax, m2
+%if mmsize == 8
+    emms
+%endif
     RET
 
 ; int scalarproduct_and_madd_int16(int16_t *v1, int16_t *v2, int16_t *v3, int order, int mul)