[x265] [PATCH 18 of 18] asm: intra_pred_ang4_18_sse2 16-bit

dtyx265 at gmail.com dtyx265 at gmail.com
Fri Apr 3 18:24:49 CEST 2015


# HG changeset patch
# User David T Yuen <dtyx265 at gmail.com>
# Date 1428078167 25200
# Node ID bb771744a75d4493a35ec5e9d76aaee1fa039f28
# Parent  e4b343abfa73af9b68f26283a9e75e161860d7b2
asm: intra_pred_ang4_18_sse2 16-bit

This is backported from sse4 code and replaces c code.

./test/TestBench --testbench intrapred | grep "intra_ang_4x4\[18\]"
intra_ang_4x4[18]	8.54x 	 127.48   	 1088.34

diff -r e4b343abfa73 -r bb771744a75d source/common/x86/asm-primitives.cpp
--- a/source/common/x86/asm-primitives.cpp	Fri Apr 03 09:20:42 2015 -0700
+++ b/source/common/x86/asm-primitives.cpp	Fri Apr 03 09:22:47 2015 -0700
@@ -898,6 +898,7 @@
         p.cu[BLOCK_4x4].intra_pred[15] = x265_intra_pred_ang4_15_sse2;
         p.cu[BLOCK_4x4].intra_pred[16] = x265_intra_pred_ang4_16_sse2;
         p.cu[BLOCK_4x4].intra_pred[17] = x265_intra_pred_ang4_17_sse2;
+        p.cu[BLOCK_4x4].intra_pred[18] = x265_intra_pred_ang4_18_sse2;
         p.cu[BLOCK_4x4].intra_pred[19] = x265_intra_pred_ang4_17_sse2;
         p.cu[BLOCK_4x4].intra_pred[20] = x265_intra_pred_ang4_16_sse2;
         p.cu[BLOCK_4x4].intra_pred[21] = x265_intra_pred_ang4_15_sse2;
diff -r e4b343abfa73 -r bb771744a75d source/common/x86/intrapred16.asm
--- a/source/common/x86/intrapred16.asm	Fri Apr 03 09:20:42 2015 -0700
+++ b/source/common/x86/intrapred16.asm	Fri Apr 03 09:22:47 2015 -0700
@@ -1175,6 +1175,22 @@
     mova        m7, [r3 + 10 * 16]  ; [24]
     jmp         mangle(private_prefix %+ _ %+ intra_pred_ang4_3 %+ SUFFIX %+ .do_filter4x4)
 
+cglobal intra_pred_ang4_18, 3,3,1
+    movh        m0, [r2 + 16]
+    pinsrw      m0, [r2], 0
+    pshuflw     m0, m0, 0x1B
+    movhps      m0, [r2 + 2]
+    add         r1, r1
+    lea         r2, [r1 * 3]
+    movh        [r0 + r2], m0
+    psrldq      m0, 2
+    movh        [r0 + r1 * 2], m0
+    psrldq      m0, 2
+    movh        [r0 + r1], m0
+    psrldq      m0, 2
+    movh        [r0], m0
+    RET
+
 ;-----------------------------------------------------------------------------------
 ; void intra_pred_dc(pixel* dst, intptr_t dstStride, pixel* above, int, int filter)
 ;-----------------------------------------------------------------------------------


More information about the x265-devel mailing list