[x265] [PATCH Review Only] asm-avx2: intra_pred_ang8_4
praveen at multicorewareinc.com
praveen at multicorewareinc.com
Wed Feb 25 11:59:05 CET 2015
# HG changeset patch
# User Praveen Tiwari <praveen at multicorewareinc.com>
# Date 1424861743 -19800
# Node ID e1b7ddbe1ecb1b1b9058e81c85bbe874fe1d581d
# Parent e2bd981f1ea8e484d6875ca3e06c9a820e6ea4e5
asm-avx2: intra_pred_ang8_4
diff -r e2bd981f1ea8 -r e1b7ddbe1ecb source/common/x86/asm-primitives.cpp
--- a/source/common/x86/asm-primitives.cpp Wed Feb 25 16:02:10 2015 +0530
+++ b/source/common/x86/asm-primitives.cpp Wed Feb 25 16:25:43 2015 +0530
@@ -1814,6 +1814,7 @@
// intra_pred functions
p.cu[BLOCK_8x8].intra_pred[3] = x265_intra_pred_ang8_3_avx2;
p.cu[BLOCK_8x8].intra_pred[33] = x265_intra_pred_ang8_33_avx2;
+ p.cu[BLOCK_8x8].intra_pred[4] = x265_intra_pred_ang8_4_avx2;
p.cu[BLOCK_8x8].intra_pred[32] = x265_intra_pred_ang8_32_avx2;
}
}
diff -r e2bd981f1ea8 -r e1b7ddbe1ecb source/common/x86/intrapred.h
--- a/source/common/x86/intrapred.h Wed Feb 25 16:02:10 2015 +0530
+++ b/source/common/x86/intrapred.h Wed Feb 25 16:25:43 2015 +0530
@@ -159,6 +159,7 @@
#undef DECL_ANG
void x265_intra_pred_ang8_3_avx2(pixel* dst, intptr_t dstStride, const pixel* srcPix, int dirMode, int bFilter);
void x265_intra_pred_ang8_33_avx2(pixel* dst, intptr_t dstStride, const pixel* srcPix, int dirMode, int bFilter);
+void x265_intra_pred_ang8_4_avx2(pixel* dst, intptr_t dstStride, const pixel* srcPix, int dirMode, int bFilter);
void x265_intra_pred_ang8_32_avx2(pixel* dst, intptr_t dstStride, const pixel* srcPix, int dirMode, int bFilter);
void x265_all_angs_pred_4x4_sse4(pixel *dest, pixel *refPix, pixel *filtPix, int bLuma);
void x265_all_angs_pred_8x8_sse4(pixel *dest, pixel *refPix, pixel *filtPix, int bLuma);
diff -r e2bd981f1ea8 -r e1b7ddbe1ecb source/common/x86/intrapred8.asm
--- a/source/common/x86/intrapred8.asm Wed Feb 25 16:02:10 2015 +0530
+++ b/source/common/x86/intrapred8.asm Wed Feb 25 16:25:43 2015 +0530
@@ -32130,6 +32130,52 @@
movhps [r0 + r3], xm2
RET
+
+INIT_YMM avx2
+cglobal intra_pred_ang8_4, 3,4,5
+ movu m3, [pw_1024]
+ vbroadcasti128 m0, [r2 + 17]
+
+ pshufb m1, m0, [c_ang8_src1_9_2_10]
+ pshufb m2, m0, [c_ang8_src2_10_3_11]
+ pshufb m4, m0, [c_ang8_src4_12_4_12]
+ pshufb m0, [c_ang8_src5_13_6_14]
+
+ pmaddubsw m1, [c_ang8_21_10]
+ pmulhrsw m1, m3
+ pmaddubsw m2, [c_ang8_31_20]
+ pmulhrsw m2, m3
+ pmaddubsw m4, [c_ang8_9_30]
+ pmulhrsw m4, m3
+ pmaddubsw m0, [c_ang8_19_8]
+ pmulhrsw m0, m3
+ packuswb m1, m2
+ packuswb m4, m0
+
+ vperm2i128 m2, m1, m4, 00100000b
+ vperm2i128 m1, m1, m4, 00110001b
+ punpcklbw m4, m2, m1
+ punpckhbw m2, m1
+ punpcklwd m1, m4, m2
+ punpckhwd m4, m2
+ mova m0, [trans8_shuf]
+ vpermd m1, m0, m1
+ vpermd m4, m0, m4
+
+ lea r3, [3 * r1]
+ movq [r0], xm1
+ movhps [r0 + r1], xm1
+ vextracti128 xm2, m1, 1
+ movq [r0 + 2 * r1], xm2
+ movhps [r0 + r3], xm2
+ lea r0, [r0 + 4 * r1]
+ movq [r0], xm4
+ movhps [r0 + r1], xm4
+ vextracti128 xm2, m4, 1
+ movq [r0 + 2 * r1], xm2
+ movhps [r0 + r3], xm2
+ RET
+
INIT_YMM avx2
cglobal intra_pred_ang8_32, 3,4,5
movu m3, [pw_1024]
More information about the x265-devel
mailing list