[x265] [PATCH] avx2: integral_init4h -> added 'INTEGRAL_FOUR_HORIZONTAL_4' macro to reduce data movement for '4' element case
Ashok Kumar Mishra
ashok at multicorewareinc.com
Thu Jun 15 15:06:41 CEST 2017
pushed
On Wed, Jun 14, 2017 at 12:03 PM, <praveen at multicorewareinc.com> wrote:
> # HG changeset patch
> # User Praveen Tiwari <praveen at multicorewareinc.com>
> # Date 1497422024 -19800
> # Wed Jun 14 12:03:44 2017 +0530
> # Node ID 65e038ecbbf63a2f449ccf52358c5fbbec408b27
> # Parent 28bbc349d17035a3c1fcdfbdca3b8e21ae6b669b
> avx2: integral_init4h -> added 'INTEGRAL_FOUR_HORIZONTAL_4' macro to
> reduce data movement for '4' element case
>
> diff -r 28bbc349d170 -r 65e038ecbbf6 source/common/x86/seaintegral.asm
> --- a/source/common/x86/seaintegral.asm Wed Jun 07 17:06:57 2017 +0530
> +++ b/source/common/x86/seaintegral.asm Wed Jun 14 12:03:44 2017 +0530
> @@ -148,11 +148,6 @@
> jnz .loop
> RET
>
> -;----------------------------------------------------------
> -------------------
> -;static void integral_init4h_c(uint32_t *sum, pixel *pix, intptr_t stride)
> -;----------------------------------------------------------
> -------------------
> -INIT_YMM avx2
> -
> %macro INTEGRAL_FOUR_HORIZONTAL_16 0
> pmovzxbw m0, [r1]
> pmovzxbw m1, [r1 + 1]
> @@ -163,6 +158,24 @@
> paddw m0, m1
> %endmacro
>
> +%macro INTEGRAL_FOUR_HORIZONTAL_4 0
> + movd xm0, [r1]
> + movd xm1, [r1 + 1]
> + pmovzxbw xm0, xm0
> + pmovzxbw xm1, xm1
> + paddw xm0, xm1
> + movd xm1, [r1 + 2]
> + pmovzxbw xm1, xm1
> + paddw xm0, xm1
> + movd xm1, [r1 + 3]
> + pmovzxbw xm1, xm1
> + paddw xm0, xm1
> +%endmacro
> +
> +;----------------------------------------------------------
> -------------------
> +;static void integral_init4h(uint32_t *sum, pixel *pix, intptr_t stride)
> +;----------------------------------------------------------
> -------------------
> +INIT_YMM avx2
> cglobal integral4h, 3, 5, 3
> lea r3, [4 * r2]
> sub r0, r3
> @@ -205,7 +218,7 @@
> jmp .end
>
> .loop_4:
> - INTEGRAL_FOUR_HORIZONTAL_16
> + INTEGRAL_FOUR_HORIZONTAL_4
> pmovzxwd xm0, xm0
> movu xm1, [r0]
> paddd xm0, xm1
> _______________________________________________
> x265-devel mailing list
> x265-devel at videolan.org
> https://mailman.videolan.org/listinfo/x265-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20170615/0781ee0b/attachment.html>
More information about the x265-devel
mailing list