diff mbox series

[FFmpeg-devel,14/14,inline,assembly] add mmx clobbers to cavsdsp

Message ID 20200422174918.7290-14-frederic.recoules@univ-grenoble-alpes.fr
State New
Headers show
Series [FFmpeg-devel,1/5,inline,assembly] prepares for contiguous assembly statements merging
Related show

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

FRÉDÉRIC RECOULES April 26, 2020, 7:44 p.m. UTC
From: Frédéric Recoules <frederic.recoules@orange.fr>

---
 libavcodec/x86/cavsdsp.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/libavcodec/x86/cavsdsp.c b/libavcodec/x86/cavsdsp.c
index becb3a4808..b1b2c7b069 100644
--- a/libavcodec/x86/cavsdsp.c
+++ b/libavcodec/x86/cavsdsp.c
@@ -166,7 +166,8 @@  static void cavs_idct8_add_sse2(uint8_t *dst, int16_t *block, ptrdiff_t stride)
         : "+a"(src), "+c"(dst)\
         : "S"((x86_reg)srcStride), "r"((x86_reg)dstStride)\
           NAMED_CONSTRAINTS_ADD(ADD,MUL1,MUL2)\
-        : "memory"\
+        : "memory" MMX_CLOBBERS(, "mm0", "mm1", "mm2", "mm3",\
+				"mm4", "mm5", "mm6", "mm7")  \
      );\
      if(h==16){\
         __asm__ volatile(\
@@ -182,7 +183,8 @@  static void cavs_idct8_add_sse2(uint8_t *dst, int16_t *block, ptrdiff_t stride)
            : "+a"(src), "+c"(dst)\
            : "S"((x86_reg)srcStride), "r"((x86_reg)dstStride)\
              NAMED_CONSTRAINTS_ADD(ADD,MUL1,MUL2)\
-           : "memory"\
+           : "memory" MMX_CLOBBERS(, "mm0", "mm1", "mm2", "mm3",\
+				   "mm4", "mm5", "mm6", "mm7")	\
         );\
      }\
      src += 4-(h+5)*srcStride;\
@@ -235,7 +237,8 @@  static void OPNAME ## cavs_qpel8_h_ ## MMX(uint8_t *dst, const uint8_t *src, ptr
         : "+a"(src), "+c"(dst), "+m"(h)\
         : "d"((x86_reg)srcStride), "S"((x86_reg)dstStride)\
           NAMED_CONSTRAINTS_ADD(ff_pw_4,ff_pw_5)\
-        : "memory"\
+        : "memory" MMX_CLOBBERS(, "mm0", "mm1", "mm2", "mm3",\
+				"mm4", "mm5", "mm6", "mm7")\
     );\
 }\
 \