[x265] [PATCH] blockcopy_sp_8x2, optimized asm code

praveen at multicorewareinc.com praveen at multicorewareinc.com
Fri Nov 8 11:55:54 CET 2013


# HG changeset patch
# User Praveen Tiwari
# Date 1383908145 -19800
# Node ID ca406614f803412b3a8bd6e2eac1774e6d9615fc
# Parent  eee937070b03167e1f2055620b641957c47a0a5c
blockcopy_sp_8x2, optimized asm code

diff -r eee937070b03 -r ca406614f803 source/common/x86/blockcopy8.asm
--- a/source/common/x86/blockcopy8.asm	Fri Nov 08 15:34:19 2013 +0530
+++ b/source/common/x86/blockcopy8.asm	Fri Nov 08 16:25:45 2013 +0530
@@ -1100,20 +1100,17 @@
 ; void blockcopy_sp_8x2(pixel *dest, intptr_t destStride, int16_t *src, intptr_t srcStride)
 ;-----------------------------------------------------------------------------
 INIT_XMM sse2
-cglobal blockcopy_sp_8x2, 4, 4, 3, dest, destStride, src, srcStride
+cglobal blockcopy_sp_8x2, 4, 4, 2, dest, destStride, src, srcStride
 
-add        r3,        r3
+add        r3,         r3
 
-mova       m0,        [tab_Vm]
+movu       m0,         [r2]
+movu       m1,         [r2 + r3]
 
-movu       m1,        [r2]
-movu       m2,        [r2 + r3]
+packuswb   m0,         m1
 
-pshufb     m1,        m0
-pshufb     m2,        m0
-
-movh       [r0],      m1
-movh       [r0 + r1], m2
+movh       [r0],       m0
+movhps     [r0 + r1],  m0
 
 RET
 


More information about the x265-devel mailing list