<div dir="ltr">please ignore this patch.Need to rename the macro, will resend the patch.</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, May 20, 2015 at 12:04 PM,  <span dir="ltr"><<a href="mailto:rajesh@multicorewareinc.com" target="_blank">rajesh@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"># HG changeset patch<br>
# User Rajesh Paulraj<<a href="mailto:rajesh@multicorewareinc.com">rajesh@multicorewareinc.com</a>><br>
# Date 1432102514 -19800<br>
#      Wed May 20 11:45:14 2015 +0530<br>
# Node ID 0fce0242d05d385afa69c003fbade0477fda43a2<br>
# Parent  9b31a8a7bd57efededcc3884ee7777c09f649394<br>
asm: avx2 10bit code for luma_hpp[4xN]<br>
<br>
avx2:<br>
luma_hpp[  4x4]         4.59x    423.90          1944.66<br>
luma_hpp[  4x8]         4.74x    803.53          3806.63<br>
luma_hpp[ 4x16]         4.73x    1574.01         7442.57<br>
<br>
sse4:<br>
luma_hpp[  4x4]         3.69x    527.97          1946.47<br>
luma_hpp[  4x8]         3.93x    961.48          3780.20<br>
luma_hpp[ 4x16]         4.06x    1833.63         7445.62<br>
<br>
diff -r 9b31a8a7bd57 -r 0fce0242d05d source/common/x86/asm-primitives.cpp<br>
--- a/source/common/x86/asm-primitives.cpp      Tue May 19 19:51:56 2015 -0500<br>
+++ b/source/common/x86/asm-primitives.cpp      Wed May 20 11:45:14 2015 +0530<br>
@@ -1407,6 +1407,9 @@<br>
         p.pu[LUMA_4x8].luma_hps = x265_interp_8tap_horiz_ps_4x8_avx2;<br>
         p.pu[LUMA_4x16].luma_hps = x265_interp_8tap_horiz_ps_4x16_avx2;<br>
<br>
+        p.pu[LUMA_4x4].luma_hpp = x265_interp_8tap_horiz_pp_4x4_avx2;<br>
+        p.pu[LUMA_4x8].luma_hpp = x265_interp_8tap_horiz_pp_4x8_avx2;<br>
+        p.pu[LUMA_4x16].luma_hpp = x265_interp_8tap_horiz_pp_4x16_avx2;<br>
         p.pu[LUMA_8x4].luma_hpp = x265_interp_8tap_horiz_pp_8x4_avx2;<br>
         p.pu[LUMA_8x8].luma_hpp = x265_interp_8tap_horiz_pp_8x8_avx2;<br>
         p.pu[LUMA_8x16].luma_hpp = x265_interp_8tap_horiz_pp_8x16_avx2;<br>
diff -r 9b31a8a7bd57 -r 0fce0242d05d source/common/x86/ipfilter16.asm<br>
--- a/source/common/x86/ipfilter16.asm  Tue May 19 19:51:56 2015 -0500<br>
+++ b/source/common/x86/ipfilter16.asm  Wed May 20 11:45:14 2015 +0530<br>
@@ -862,6 +862,84 @@<br>
     movhps      [r2 + r3],  m3<br>
 %endmacro<br>
<br>
+;-------------------------------------------------------------------------------------------------------------<br>
+; void interp_8tap_horiz_pp(pixel *src, intptr_t srcStride, pixel *dst, intptr_t dstStride, int coeffIdx<br>
+;-------------------------------------------------------------------------------------------------------------<br>
+%macro FILTER_HOR_LUMA_W8 1<br>
+INIT_YMM avx2<br>
+cglobal interp_8tap_horiz_pp_4x%1, 4,7,7<br>
+    add              r1d, r1d<br>
+    add              r3d, r3d<br>
+    sub              r0, 6<br>
+    mov              r4d, r4m<br>
+    shl              r4d, 4<br>
+%ifdef PIC<br>
+    lea              r5, [tab_LumaCoeff]<br>
+    vpbroadcastq     m0, [r5 + r4]<br>
+    vpbroadcastq     m1, [r5 + r4 + 8]<br>
+%else<br>
+    vpbroadcastq     m0, [tab_LumaCoeff + r4]<br>
+    vpbroadcastq     m1, [tab_LumaCoeff + r4 + 8]<br>
+%endif<br>
+    lea              r6, [pw_pixel_max]<br>
+    mova             m3, [interp8_hpp_shuf]<br>
+    mova             m6, [pd_32]<br>
+    pxor             m2, m2<br>
+<br>
+    ; register map<br>
+    ; m0 , m1 interpolate coeff<br>
+<br>
+    mov              r4d, %1/2<br>
+<br>
+.loop:<br>
+    vbroadcasti128   m4, [r0]<br>
+    vbroadcasti128   m5, [r0 + 8]<br>
+    pshufb           m4, m3<br>
+    pshufb           m5, m3<br>
+<br>
+    pmaddwd          m4, m0<br>
+    pmaddwd          m5, m1<br>
+    paddd            m4, m5<br>
+<br>
+    phaddd           m4, m4<br>
+    vpermq           m4, m4, q3120<br>
+    paddd            m4, m6<br>
+    psrad            m4, 6<br>
+<br>
+    packusdw         m4, m4<br>
+    vpermq           m4, m4, q2020<br>
+    CLIPW            m4, m2, [r6]<br>
+    movq             [r2], xm4<br>
+<br>
+    vbroadcasti128   m4, [r0 + r1]<br>
+    vbroadcasti128   m5, [r0 + r1 + 8]<br>
+    pshufb           m4, m3<br>
+    pshufb           m5, m3<br>
+<br>
+    pmaddwd          m4, m0<br>
+    pmaddwd          m5, m1<br>
+    paddd            m4, m5<br>
+<br>
+    phaddd           m4, m4<br>
+    vpermq           m4, m4, q3120<br>
+    paddd            m4, m6<br>
+    psrad            m4, 6<br>
+<br>
+    packusdw         m4, m4<br>
+    vpermq           m4, m4, q2020<br>
+    CLIPW            m4, m2, [r6]<br>
+    movq             [r2 + r3], xm4<br>
+<br>
+    lea              r2, [r2 + 2 * r3]<br>
+    lea              r0, [r0 + 2 * r1]<br>
+    dec              r4d<br>
+    jnz              .loop<br>
+    RET<br>
+%endmacro<br>
+FILTER_HOR_LUMA_W8 4<br>
+FILTER_HOR_LUMA_W8 8<br>
+FILTER_HOR_LUMA_W8 16<br>
+<br>
 ;-------------------------------------------------------------------------------------------------------------<br>
 ; void interp_8tap_horiz_pp(pixel *src, intptr_t srcStride, pixel *dst, intptr_t dstStride, int coeffIdx<br>
 ;-------------------------------------------------------------------------------------------------------------<br>
</blockquote></div><br></div>