[x265] [PATCH] asm: assembly code for pixel_sad_64x48 and pixel_sad_64x64
dnyaneshwar at multicorewareinc.com
dnyaneshwar at multicorewareinc.com
Wed Oct 30 09:42:34 CET 2013
# HG changeset patch
# User Dnyaneshwar Gorade <dnyaneshwar at multicorewareinc.com>
# Date 1383122501 -19800
# Wed Oct 30 14:11:41 2013 +0530
# Node ID 1f32144338f3399a962fddbaf2f261242128425c
# Parent c08f78ad73bf677164f3ffec707a1fb22de21d59
asm: assembly code for pixel_sad_64x48 and pixel_sad_64x64
diff -r c08f78ad73bf -r 1f32144338f3 source/common/x86/asm-primitives.cpp
--- a/source/common/x86/asm-primitives.cpp Wed Oct 30 13:45:38 2013 +0530
+++ b/source/common/x86/asm-primitives.cpp Wed Oct 30 14:11:41 2013 +0530
@@ -248,6 +248,8 @@
p.sad[LUMA_64x16] = x265_pixel_sad_64x16_sse2;
p.sad[LUMA_64x32] = x265_pixel_sad_64x32_sse2;
+ p.sad[LUMA_64x48] = x265_pixel_sad_64x48_sse2;
+ p.sad[LUMA_64x64] = x265_pixel_sad_64x64_sse2;
ASSGN_SSE(sse2);
INIT2(sad, _sse2);
diff -r c08f78ad73bf -r 1f32144338f3 source/common/x86/sad-a.asm
--- a/source/common/x86/sad-a.asm Wed Oct 30 13:45:38 2013 +0530
+++ b/source/common/x86/sad-a.asm Wed Oct 30 14:11:41 2013 +0530
@@ -804,6 +804,66 @@
movd eax, m0
RET
+;-----------------------------------------------------------------------------
+; int pixel_sad_64x48( uint8_t *, intptr_t, uint8_t *, intptr_t )
+;-----------------------------------------------------------------------------
+cglobal pixel_sad_64x48, 4,4,5
+ pxor m0, m0
+ mov r4, 48
+
+.loop
+ PROCESS_SAD_64x4
+ lea r2, [r2 + r3]
+ lea r0, [r0 + r1]
+
+ PROCESS_SAD_64x4
+ lea r2, [r2 + r3]
+ lea r0, [r0 + r1]
+
+ sub r4, 8
+ cmp r4, 8
+
+jnz .loop
+ PROCESS_SAD_64x4
+ lea r2, [r2 + r3]
+ lea r0, [r0 + r1]
+ PROCESS_SAD_64x4
+
+ movhlps m1, m0
+ paddd m0, m1
+ movd eax, m0
+ RET
+
+;-----------------------------------------------------------------------------
+; int pixel_sad_64x64( uint8_t *, intptr_t, uint8_t *, intptr_t )
+;-----------------------------------------------------------------------------
+cglobal pixel_sad_64x64, 4,4,5
+ pxor m0, m0
+ mov r4, 64
+
+.loop
+ PROCESS_SAD_64x4
+ lea r2, [r2 + r3]
+ lea r0, [r0 + r1]
+
+ PROCESS_SAD_64x4
+ lea r2, [r2 + r3]
+ lea r0, [r0 + r1]
+
+ sub r4, 8
+ cmp r4, 8
+
+jnz .loop
+ PROCESS_SAD_64x4
+ lea r2, [r2 + r3]
+ lea r0, [r0 + r1]
+ PROCESS_SAD_64x4
+
+ movhlps m1, m0
+ paddd m0, m1
+ movd eax, m0
+ RET
+
%endmacro
INIT_XMM sse2
More information about the x265-devel
mailing list