X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavutil%2Fx86%2Fx86util.asm;h=1064e9a25cac9f1fce11b5175b4f4804de8ccb75;hb=6e8e9f1e517ee52fe439f3e8ca762f09d235f21e;hp=67d7905132837d97e9f99b639c44d709d43c3337;hpb=43c57dbe14545d13dbfd8aae341b45514e8bcfbb;p=ffmpeg diff --git a/libavutil/x86/x86util.asm b/libavutil/x86/x86util.asm index 67d79051328..1064e9a25ca 100644 --- a/libavutil/x86/x86util.asm +++ b/libavutil/x86/x86util.asm @@ -288,7 +288,12 @@ paddd %1, %2 %endif %if notcpuflag(xop) || sizeof%1 != 16 +%if cpuflag(mmxext) PSHUFLW %2, %1, q0032 +%else ; mmx + mova %2, %1 + psrlq %2, 32 +%endif paddd %1, %2 %endif %undef %1 @@ -335,11 +340,19 @@ %endif %endmacro -%macro PAVGB 2 +%macro PAVGB 2-4 %if cpuflag(mmxext) pavgb %1, %2 %elif cpuflag(3dnow) pavgusb %1, %2 +%elif cpuflag(mmx) + movu %3, %2 + por %3, %1 + pxor %1, %2 + pand %1, %4 + psrlq %1, 1 + psubb %3, %1 + SWAP %1, %3 %endif %endmacro