<div dir="ltr">Please ignore this patch. I will clean and resend it.<div><br></div><div>Regards,</div><div>Divya</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Nov 20, 2014 at 3:19 PM, Praveen Tiwari <span dir="ltr"><<a href="mailto:praveen@multicorewareinc.com" target="_blank">praveen@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">tab_LumaCoeffVer_32 table of this name is already in file, redefining here will cause build error. Please, verify and update patch. <br></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Thu, Nov 20, 2014 at 2:49 PM, Divya Manivannan <span dir="ltr"><<a href="mailto:divya@multicorewareinc.com" target="_blank">divya@multicorewareinc.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"># HG changeset patch<br>
# User Divya Manivannan <<a href="mailto:divya@multicorewareinc.com" target="_blank">divya@multicorewareinc.com</a>><br>
# Date 1416475133 -19800<br>
# Thu Nov 20 14:48:53 2014 +0530<br>
# Node ID 49c99a85531358e1b0624edd8082b6945d4e187e<br>
# Parent 3649fabf90d348c51d7e155989d1bf629ec27f6e<br>
asm: luma_vpp[16x32, 16x64] in avx2: improve 3875c->2488c, 7499c->4915c<br>
<br>
diff -r 3649fabf90d3 -r 49c99a855313 source/common/x86/asm-primitives.cpp<br>
--- a/source/common/x86/asm-primitives.cpp Thu Nov 20 14:27:53 2014 +0530<br>
+++ b/source/common/x86/asm-primitives.cpp Thu Nov 20 14:48:53 2014 +0530<br>
@@ -1798,6 +1798,8 @@<br>
p.transpose[BLOCK_16x16] = x265_transpose16_avx2;<br>
p.transpose[BLOCK_32x32] = x265_transpose32_avx2;<br>
p.transpose[BLOCK_64x64] = x265_transpose64_avx2;<br>
+ p.luma_vpp[LUMA_16x32] = x265_interp_8tap_vert_pp_16x32_avx2;<br>
+ p.luma_vpp[LUMA_16x64] = x265_interp_8tap_vert_pp_16x64_avx2;<br>
#endif<br>
p.luma_hpp[LUMA_4x4] = x265_interp_8tap_horiz_pp_4x4_avx2;<br>
p.luma_vpp[LUMA_4x4] = x265_interp_8tap_vert_pp_4x4_avx2;<br>
diff -r 3649fabf90d3 -r 49c99a855313 source/common/x86/ipfilter8.asm<br>
--- a/source/common/x86/ipfilter8.asm Thu Nov 20 14:27:53 2014 +0530<br>
+++ b/source/common/x86/ipfilter8.asm Thu Nov 20 14:48:53 2014 +0530<br>
@@ -122,6 +122,27 @@<br>
times 8 db 58, -10<br>
times 8 db 4, -1<br>
<br>
+ALIGN 32<br>
+tab_LumaCoeffVer_32: times 16 db 0, 0<br>
+ times 16 db 0, 64<br>
+ times 16 db 0, 0<br>
+ times 16 db 0, 0<br>
+<br>
+ times 16 db -1, 4<br>
+ times 16 db -10, 58<br>
+ times 16 db 17, -5<br>
+ times 16 db 1, 0<br>
+<br>
+ times 16 db -1, 4<br>
+ times 16 db -11, 40<br>
+ times 16 db 40, -11<br>
+ times 16 db 4, -1<br>
+<br>
+ times 16 db 0, 1<br>
+ times 16 db -5, 17<br>
+ times 16 db 58, -10<br>
+ times 16 db 4, -1<br>
+<br>
tab_c_64_n64: times 8 db 64, -64<br>
<br>
const interp4_shuf, times 2 db 0, 1, 8, 9, 4, 5, 12, 13, 2, 3, 10, 11, 6, 7, 14, 15<br>
@@ -3755,6 +3776,312 @@<br>
;-------------------------------------------------------------------------------------------------------------<br>
FILTER_VER_LUMA_12xN 12, 16, ps<br>
<br>
+%macro FILTER_VER_LUMA_AVX2_16xN 2<br>
+INIT_YMM avx2<br>
+%if ARCH_X86_64 == 1<br>
+cglobal interp_8tap_vert_pp_%1x%2, 4, 7, 15<br>
+ mov r4d, r4m<br>
+ shl r4d, 7<br>
+<br>
+%ifdef PIC<br>
+ lea r5, [tab_LumaCoeffVer_32]<br>
+ add r5, r4<br>
+%else<br>
+ lea r5, [tab_LumaCoeffVer_32 + r4]<br>
+%endif<br>
+<br>
+ lea r4, [r1 * 3]<br>
+ sub r0, r4<br>
+ lea r6, [r1 * 4]<br>
+ mova m14, [pw_512]<br>
+ mov word [rsp], %2 / 16<br>
+<br>
+.loop:<br>
+ movu xm0, [r0] ; m0 = row 0<br>
+ movu xm1, [r0 + r1] ; m1 = row 1<br>
+ punpckhbw xm2, xm0, xm1<br>
+ punpcklbw xm0, xm1<br>
+ vinserti128 m0, m0, xm2, 1<br>
+ pmaddubsw m0, [r5]<br>
+ movu xm2, [r0 + r1 * 2] ; m2 = row 2<br>
+ punpckhbw xm3, xm1, xm2<br>
+ punpcklbw xm1, xm2<br>
+ vinserti128 m1, m1, xm3, 1<br>
+ pmaddubsw m1, [r5]<br>
+ movu xm3, [r0 + r4] ; m3 = row 3<br>
+ punpckhbw xm4, xm2, xm3<br>
+ punpcklbw xm2, xm3<br>
+ vinserti128 m2, m2, xm4, 1<br>
+ pmaddubsw m4, m2, [r5 + 1 * mmsize]<br>
+ paddw m0, m4<br>
+ pmaddubsw m2, [r5]<br>
+ lea r0, [r0 + r1 * 4]<br>
+ movu xm4, [r0] ; m4 = row 4<br>
+ punpckhbw xm5, xm3, xm4<br>
+ punpcklbw xm3, xm4<br>
+ vinserti128 m3, m3, xm5, 1<br>
+ pmaddubsw m5, m3, [r5 + 1 * mmsize]<br>
+ paddw m1, m5<br>
+ pmaddubsw m3, [r5]<br>
+ movu xm5, [r0 + r1] ; m5 = row 5<br>
+ punpckhbw xm6, xm4, xm5<br>
+ punpcklbw xm4, xm5<br>
+ vinserti128 m4, m4, xm6, 1<br>
+ pmaddubsw m6, m4, [r5 + 2 * mmsize]<br>
+ paddw m0, m6<br>
+ pmaddubsw m6, m4, [r5 + 1 * mmsize]<br>
+ paddw m2, m6<br>
+ pmaddubsw m4, [r5]<br>
+ movu xm6, [r0 + r1 * 2] ; m6 = row 6<br>
+ punpckhbw xm7, xm5, xm6<br>
+ punpcklbw xm5, xm6<br>
+ vinserti128 m5, m5, xm7, 1<br>
+ pmaddubsw m7, m5, [r5 + 2 * mmsize]<br>
+ paddw m1, m7<br>
+ pmaddubsw m7, m5, [r5 + 1 * mmsize]<br>
+ paddw m3, m7<br>
+ pmaddubsw m5, [r5]<br>
+ movu xm7, [r0 + r4] ; m7 = row 7<br>
+ punpckhbw xm8, xm6, xm7<br>
+ punpcklbw xm6, xm7<br>
+ vinserti128 m6, m6, xm8, 1<br>
+ pmaddubsw m8, m6, [r5 + 3 * mmsize]<br>
+ paddw m0, m8<br>
+ pmaddubsw m8, m6, [r5 + 2 * mmsize]<br>
+ paddw m2, m8<br>
+ pmaddubsw m8, m6, [r5 + 1 * mmsize]<br>
+ paddw m4, m8<br>
+ pmaddubsw m6, [r5]<br>
+ lea r0, [r0 + r1 * 4]<br>
+ movu xm8, [r0] ; m8 = row 8<br>
+ punpckhbw xm9, xm7, xm8<br>
+ punpcklbw xm7, xm8<br>
+ vinserti128 m7, m7, xm9, 1<br>
+ pmaddubsw m9, m7, [r5 + 3 * mmsize]<br>
+ paddw m1, m9<br>
+ pmaddubsw m9, m7, [r5 + 2 * mmsize]<br>
+ paddw m3, m9<br>
+ pmaddubsw m9, m7, [r5 + 1 * mmsize]<br>
+ paddw m5, m9<br>
+ pmaddubsw m7, [r5]<br>
+ movu xm9, [r0 + r1] ; m9 = row 9<br>
+ punpckhbw xm10, xm8, xm9<br>
+ punpcklbw xm8, xm9<br>
+ vinserti128 m8, m8, xm10, 1<br>
+ pmaddubsw m10, m8, [r5 + 3 * mmsize]<br>
+ paddw m2, m10<br>
+ pmaddubsw m10, m8, [r5 + 2 * mmsize]<br>
+ paddw m4, m10<br>
+ pmaddubsw m10, m8, [r5 + 1 * mmsize]<br>
+ paddw m6, m10<br>
+ pmaddubsw m8, [r5]<br>
+ movu xm10, [r0 + r1 * 2] ; m10 = row 10<br>
+ punpckhbw xm11, xm9, xm10<br>
+ punpcklbw xm9, xm10<br>
+ vinserti128 m9, m9, xm11, 1<br>
+ pmaddubsw m11, m9, [r5 + 3 * mmsize]<br>
+ paddw m3, m11<br>
+ pmaddubsw m11, m9, [r5 + 2 * mmsize]<br>
+ paddw m5, m11<br>
+ pmaddubsw m11, m9, [r5 + 1 * mmsize]<br>
+ paddw m7, m11<br>
+ pmaddubsw m9, [r5]<br>
+ movu xm11, [r0 + r4] ; m11 = row 11<br>
+ punpckhbw xm12, xm10, xm11<br>
+ punpcklbw xm10, xm11<br>
+ vinserti128 m10, m10, xm12, 1<br>
+ pmaddubsw m12, m10, [r5 + 3 * mmsize]<br>
+ paddw m4, m12<br>
+ pmaddubsw m12, m10, [r5 + 2 * mmsize]<br>
+ paddw m6, m12<br>
+ pmaddubsw m12, m10, [r5 + 1 * mmsize]<br>
+ paddw m8, m12<br>
+ pmaddubsw m10, [r5]<br>
+ lea r0, [r0 + r1 * 4]<br>
+ movu xm12, [r0] ; m12 = row 12<br>
+ punpckhbw xm13, xm11, xm12<br>
+ punpcklbw xm11, xm12<br>
+ vinserti128 m11, m11, xm13, 1<br>
+ pmaddubsw m13, m11, [r5 + 3 * mmsize]<br>
+ paddw m5, m13<br>
+ pmaddubsw m13, m11, [r5 + 2 * mmsize]<br>
+ paddw m7, m13<br>
+ pmaddubsw m13, m11, [r5 + 1 * mmsize]<br>
+ paddw m9, m13<br>
+ pmaddubsw m11, [r5]<br>
+<br>
+ pmulhrsw m0, m14 ; m0 = word: row 0<br>
+ pmulhrsw m1, m14 ; m1 = word: row 1<br>
+ pmulhrsw m2, m14 ; m2 = word: row 2<br>
+ pmulhrsw m3, m14 ; m3 = word: row 3<br>
+ pmulhrsw m4, m14 ; m4 = word: row 4<br>
+ pmulhrsw m5, m14 ; m5 = word: row 5<br>
+ packuswb m0, m1<br>
+ packuswb m2, m3<br>
+ packuswb m4, m5<br>
+ vpermq m0, m0, 11011000b<br>
+ vpermq m2, m2, 11011000b<br>
+ vpermq m4, m4, 11011000b<br>
+ vextracti128 xm1, m0, 1<br>
+ vextracti128 xm3, m2, 1<br>
+ vextracti128 xm5, m4, 1<br>
+ movu [r2], xm0<br>
+ movu [r2 + r3], xm1<br>
+ lea r2, [r2 + r3 * 2]<br>
+ movu [r2], xm2<br>
+ movu [r2 + r3], xm3<br>
+ lea r2, [r2 + r3 * 2]<br>
+ movu [r2], xm4<br>
+ movu [r2 + r3], xm5<br>
+ lea r2, [r2 + r3 * 2]<br>
+<br>
+ movu xm13, [r0 + r1] ; m13 = row 13<br>
+ punpckhbw xm0, xm12, xm13<br>
+ punpcklbw xm12, xm13<br>
+ vinserti128 m12, m12, xm0, 1<br>
+ pmaddubsw m0, m12, [r5 + 3 * mmsize]<br>
+ paddw m6, m0<br>
+ pmaddubsw m0, m12, [r5 + 2 * mmsize]<br>
+ paddw m8, m0<br>
+ pmaddubsw m0, m12, [r5 + 1 * mmsize]<br>
+ paddw m10, m0<br>
+ pmaddubsw m12, [r5]<br>
+ movu xm0, [r0 + r1 * 2] ; m0 = row 14<br>
+ punpckhbw xm1, xm13, xm0<br>
+ punpcklbw xm13, xm0<br>
+ vinserti128 m13, m13, xm1, 1<br>
+ pmaddubsw m1, m13, [r5 + 3 * mmsize]<br>
+ paddw m7, m1<br>
+ pmaddubsw m1, m13, [r5 + 2 * mmsize]<br>
+ paddw m9, m1<br>
+ pmaddubsw m1, m13, [r5 + 1 * mmsize]<br>
+ paddw m11, m1<br>
+ pmaddubsw m13, [r5]<br>
+<br>
+ pmulhrsw m6, m14 ; m6 = word: row 6<br>
+ pmulhrsw m7, m14 ; m7 = word: row 7<br>
+ packuswb m6, m7<br>
+ vpermq m6, m6, 11011000b<br>
+ vextracti128 xm7, m6, 1<br>
+ movu [r2], xm6<br>
+ movu [r2 + r3], xm7<br>
+ lea r2, [r2 + r3 * 2]<br>
+<br>
+ movu xm1, [r0 + r4] ; m1 = row 15<br>
+ punpckhbw xm2, xm0, xm1<br>
+ punpcklbw xm0, xm1<br>
+ vinserti128 m0, m0, xm2, 1<br>
+ pmaddubsw m2, m0, [r5 + 3 * mmsize]<br>
+ paddw m8, m2<br>
+ pmaddubsw m2, m0, [r5 + 2 * mmsize]<br>
+ paddw m10, m2<br>
+ pmaddubsw m2, m0, [r5 + 1 * mmsize]<br>
+ paddw m12, m2<br>
+ pmaddubsw m0, [r5]<br>
+ lea r0, [r0 + r1 * 4]<br>
+ movu xm2, [r0] ; m2 = row 16<br>
+ punpckhbw xm3, xm1, xm2<br>
+ punpcklbw xm1, xm2<br>
+ vinserti128 m1, m1, xm3, 1<br>
+ pmaddubsw m3, m1, [r5 + 3 * mmsize]<br>
+ paddw m9, m3<br>
+ pmaddubsw m3, m1, [r5 + 2 * mmsize]<br>
+ paddw m11, m3<br>
+ pmaddubsw m3, m1, [r5 + 1 * mmsize]<br>
+ paddw m13, m3<br>
+ pmaddubsw m1, [r5]<br>
+ movu xm3, [r0 + r1] ; m3 = row 17<br>
+ punpckhbw xm4, xm2, xm3<br>
+ punpcklbw xm2, xm3<br>
+ vinserti128 m2, m2, xm4, 1<br>
+ pmaddubsw m4, m2, [r5 + 3 * mmsize]<br>
+ paddw m10, m4<br>
+ pmaddubsw m4, m2, [r5 + 2 * mmsize]<br>
+ paddw m12, m4<br>
+ pmaddubsw m2, [r5 + 1 * mmsize]<br>
+ paddw m0, m2<br>
+ movu xm4, [r0 + r1 * 2] ; m4 = row 18<br>
+ punpckhbw xm5, xm3, xm4<br>
+ punpcklbw xm3, xm4<br>
+ vinserti128 m3, m3, xm5, 1<br>
+ pmaddubsw m5, m3, [r5 + 3 * mmsize]<br>
+ paddw m11, m5<br>
+ pmaddubsw m5, m3, [r5 + 2 * mmsize]<br>
+ paddw m13, m5<br>
+ pmaddubsw m3, [r5 + 1 * mmsize]<br>
+ paddw m1, m3<br>
+ movu xm5, [r0 + r4] ; m5 = row 19<br>
+ punpckhbw xm6, xm4, xm5<br>
+ punpcklbw xm4, xm5<br>
+ vinserti128 m4, m4, xm6, 1<br>
+ pmaddubsw m6, m4, [r5 + 3 * mmsize]<br>
+ paddw m12, m6<br>
+ pmaddubsw m4, [r5 + 2 * mmsize]<br>
+ paddw m0, m4<br>
+ lea r0, [r0 + r1 * 4]<br>
+ movu xm6, [r0] ; m6 = row 20<br>
+ punpckhbw xm7, xm5, xm6<br>
+ punpcklbw xm5, xm6<br>
+ vinserti128 m5, m5, xm7, 1<br>
+ pmaddubsw m7, m5, [r5 + 3 * mmsize]<br>
+ paddw m13, m7<br>
+ pmaddubsw m5, [r5 + 2 * mmsize]<br>
+ paddw m1, m5<br>
+ movu xm7, [r0 + r1] ; m7 = row 21<br>
+ punpckhbw xm2, xm6, xm7<br>
+ punpcklbw xm6, xm7<br>
+ vinserti128 m6, m6, xm2, 1<br>
+ pmaddubsw m6, [r5 + 3 * mmsize]<br>
+ paddw m0, m6<br>
+ movu xm2, [r0 + r1 * 2] ; m2 = row 22<br>
+ punpckhbw xm3, xm7, xm2<br>
+ punpcklbw xm7, xm2<br>
+ vinserti128 m7, m7, xm3, 1<br>
+ pmaddubsw m7, [r5 + 3 * mmsize]<br>
+ paddw m1, m7<br>
+<br>
+ pmulhrsw m8, m14 ; m8 = word: row 8<br>
+ pmulhrsw m9, m14 ; m9 = word: row 9<br>
+ pmulhrsw m10, m14 ; m10 = word: row 10<br>
+ pmulhrsw m11, m14 ; m11 = word: row 11<br>
+ pmulhrsw m12, m14 ; m12 = word: row 12<br>
+ pmulhrsw m13, m14 ; m13 = word: row 13<br>
+ pmulhrsw m0, m14 ; m0 = word: row 14<br>
+ pmulhrsw m1, m14 ; m1 = word: row 15<br>
+ packuswb m8, m9<br>
+ packuswb m10, m11<br>
+ packuswb m12, m13<br>
+ packuswb m0, m1<br>
+ vpermq m8, m8, 11011000b<br>
+ vpermq m10, m10, 11011000b<br>
+ vpermq m12, m12, 11011000b<br>
+ vpermq m0, m0, 11011000b<br>
+ vextracti128 xm9, m8, 1<br>
+ vextracti128 xm11, m10, 1<br>
+ vextracti128 xm13, m12, 1<br>
+ vextracti128 xm1, m0, 1<br>
+ movu [r2], xm8<br>
+ movu [r2 + r3], xm9<br>
+ lea r2, [r2 + r3 * 2]<br>
+ movu [r2], xm10<br>
+ movu [r2 + r3], xm11<br>
+ lea r2, [r2 + r3 * 2]<br>
+ movu [r2], xm12<br>
+ movu [r2 + r3], xm13<br>
+ lea r2, [r2 + r3 * 2]<br>
+ movu [r2], xm0<br>
+ movu [r2 + r3], xm1<br>
+ lea r2, [r2 + r3 * 2]<br>
+ sub r0, r6<br>
+ dec word [rsp]<br>
+ jnz .loop<br>
+ RET<br>
+%endif<br>
+%endmacro<br>
+<br>
+FILTER_VER_LUMA_AVX2_16xN 16, 32<br>
+FILTER_VER_LUMA_AVX2_16xN 16, 64<br>
+<br>
;-------------------------------------------------------------------------------------------------------------<br>
; void interp_8tap_vert_%3_%1x%2(pixel *src, intptr_t srcStride, pixel *dst, intptr_t dstStride, int coeffIdx)<br>
;-------------------------------------------------------------------------------------------------------------<br></div></div>
_______________________________________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org" target="_blank">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" target="_blank">https://mailman.videolan.org/listinfo/x265-devel</a><br>
</blockquote></div><br></div>
<br>_______________________________________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" target="_blank">https://mailman.videolan.org/listinfo/x265-devel</a><br>
<br></blockquote></div><br></div>