void ff_snow_vertical_compose97i_sse2(DWTELEM *b0, DWTELEM *b1, DWTELEM *b2, DWTELEM *b3, DWTELEM *b4, DWTELEM *b5, int width){

    long i = width;



    while(i & 0xF)

    {

        i--;

        b4[i] -= (W_DM*(b3[i] + b5[i])+W_DO)>>W_DS;

        b3[i] -= (W_CM*(b2[i] + b4[i])+W_CO)>>W_CS;

        b2[i] += (W_BM*(b1[i] + b3[i])+4*b2[i]+W_BO)>>W_BS;

        b1[i] += (W_AM*(b0[i] + b2[i])+W_AO)>>W_AS;

    }



         asm volatile (

        "jmp 2f                                      \n\t"

        "1:                                          \n\t"



        "mov %6, %%"REG_a"                           \n\t"

        "mov %4, %%"REG_S"                           \n\t"



        snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_r2r_add("xmm0","xmm2","xmm4","xmm6","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")



        "pcmpeqd %%xmm1, %%xmm1                      \n\t"

        "pslld $31, %%xmm1                           \n\t"

        "psrld $29, %%xmm1                           \n\t"

        "mov %5, %%"REG_a"                           \n\t"



        snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("3","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_load(REG_a,"xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sub("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_store(REG_a,"xmm1","xmm3","xmm5","xmm7")

        "mov %3, %%"REG_c"                           \n\t"

        snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sub("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_S,"xmm0","xmm2","xmm4","xmm6")

        "mov %2, %%"REG_a"                           \n\t"

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")



        "pcmpeqd %%xmm1, %%xmm1                      \n\t"

        "pslld $31, %%xmm1                           \n\t"

        "psrld $30, %%xmm1                           \n\t"

        "mov %1, %%"REG_S"                           \n\t"



        snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_c,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sra("1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_a,"xmm0","xmm2","xmm4","xmm6")



        "2:                                          \n\t"

        "sub $16, %%"REG_d"                          \n\t"

        "jge 1b                                      \n\t"

        :"+d"(i)

        :

        "m"(b0),"m"(b1),"m"(b2),"m"(b3),"m"(b4),"m"(b5):

        "%"REG_a"","%"REG_S"","%"REG_c"");

}

void ff_snow_vertical_compose97i_sse2(DWTELEM *b0, DWTELEM *b1, DWTELEM *b2, DWTELEM *b3, DWTELEM *b4, DWTELEM *b5, int width){

    long i = width;



    while(i & 0xF)

    {

        i--;

        b4[i] -= (W_DM*(b3[i] + b5[i])+W_DO)>>W_DS;

        b3[i] -= (W_CM*(b2[i] + b4[i])+W_CO)>>W_CS;

        b2[i] += (W_BM*(b1[i] + b3[i])+4*b2[i]+W_BO)>>W_BS;

        b1[i] += (W_AM*(b0[i] + b2[i])+W_AO)>>W_AS;

    }



         asm volatile (

        "jmp 2f                                      \n\t"

        "1:                                          \n\t"



        "mov %6, %%"REG_a"                           \n\t"

        "mov %4, %%"REG_S"                           \n\t"



        snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_r2r_add("xmm0","xmm2","xmm4","xmm6","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")



        "pcmpeqd %%xmm1, %%xmm1                      \n\t"

        "pslld $31, %%xmm1                           \n\t"

        "psrld $29, %%xmm1                           \n\t"

        "mov %5, %%"REG_a"                           \n\t"



        snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("3","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_load(REG_a,"xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sub("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_store(REG_a,"xmm1","xmm3","xmm5","xmm7")

        "mov %3, %%"REG_c"                           \n\t"

        snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sub("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_S,"xmm0","xmm2","xmm4","xmm6")

        "mov %2, %%"REG_a"                           \n\t"

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")



        "pcmpeqd %%xmm1, %%xmm1                      \n\t"

        "pslld $31, %%xmm1                           \n\t"

        "psrld $30, %%xmm1                           \n\t"

        "mov %1, %%"REG_S"                           \n\t"



        snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_c,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sra("1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_a,"xmm0","xmm2","xmm4","xmm6")



        "2:                                          \n\t"

        "sub $16, %%"REG_d"                          \n\t"

        "jge 1b                                      \n\t"

        :"+d"(i)

        :

        "m"(b0),"m"(b1),"m"(b2),"m"(b3),"m"(b4),"m"(b5):

        "%"REG_a"","%"REG_S"","%"REG_c"");

}

void ff_snow_vertical_compose97i_sse2(DWTELEM *b0, DWTELEM *b1, DWTELEM *b2, DWTELEM *b3, DWTELEM *b4, DWTELEM *b5, int width){     while(i & 0xF)         "pslld $31, %%xmm1                           \n\t"         "psrld $29, %%xmm1                           \n\t"         "pslld $31, %%xmm1                           \n\t"         "psrld $30, %%xmm1                           \n\t"         "sub $16, %%"REG_d"                          \n\t"
void FUNC_0(DWTELEM *VAR_0, DWTELEM *VAR_1, DWTELEM *VAR_2, DWTELEM *VAR_3, DWTELEM *VAR_4, DWTELEM *VAR_5, int VAR_6){

    long VAR_7 = VAR_6;



    while(VAR_7 & 0xF)

    {

        VAR_7--;

        VAR_4[VAR_7] -= (W_DM*(VAR_3[VAR_7] + VAR_5[VAR_7])+W_DO)>>W_DS;

        VAR_3[VAR_7] -= (W_CM*(VAR_2[VAR_7] + VAR_4[VAR_7])+W_CO)>>W_CS;

        VAR_2[VAR_7] += (W_BM*(VAR_1[VAR_7] + VAR_3[VAR_7])+4*VAR_2[VAR_7]+W_BO)>>W_BS;

        VAR_1[VAR_7] += (W_AM*(VAR_0[VAR_7] + VAR_2[VAR_7])+W_AO)>>W_AS;

    }



         asm volatile (

        "jmp 2f                                      \n\t"

        "1:                                          \n\t"



        "mov %6, %%"REG_a"                           \n\t"

        "mov %4, %%"REG_S"                           \n\t"



        snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_r2r_add("xmm0","xmm2","xmm4","xmm6","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")



        "pcmpeqd %%xmm1, %%xmm1                      \n\t"

        "pslld $31, %%xmm1                           \n\t"

        "psrld $29, %%xmm1                           \n\t"

        "mov %5, %%"REG_a"                           \n\t"



        snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("3","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_load(REG_a,"xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sub("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_store(REG_a,"xmm1","xmm3","xmm5","xmm7")

        "mov %3, %%"REG_c"                           \n\t"

        snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sub("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_S,"xmm0","xmm2","xmm4","xmm6")

        "mov %2, %%"REG_a"                           \n\t"

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")



        "pcmpeqd %%xmm1, %%xmm1                      \n\t"

        "pslld $31, %%xmm1                           \n\t"

        "psrld $30, %%xmm1                           \n\t"

        "mov %1, %%"REG_S"                           \n\t"



        snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_c,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_S,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")

        snow_vertical_compose_sse2_sra("1","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")

        snow_vertical_compose_sse2_store(REG_a,"xmm0","xmm2","xmm4","xmm6")



        "2:                                          \n\t"

        "sub $16, %%"REG_d"                          \n\t"

        "jge 1b                                      \n\t"

        :"+d"(VAR_7)

        :

        "m"(VAR_0),"m"(VAR_1),"m"(VAR_2),"m"(VAR_3),"m"(VAR_4),"m"(VAR_5):

        "%"REG_a"","%"REG_S"","%"REG_c"");

}

void FUNC_0(DWTELEM *VAR_0, DWTELEM *VAR_1, DWTELEM *VAR_2, DWTELEM *VAR_3, DWTELEM *VAR_4, DWTELEM *VAR_5, int VAR_6){ long VAR_7 = VAR_6; while(VAR_7 & 0xF)
{ VAR_7--; VAR_4[VAR_7] -= (W_DM*(VAR_3[VAR_7] + VAR_5[VAR_7])+W_DO)>>W_DS; VAR_3[VAR_7] -= (W_CM*(VAR_2[VAR_7] + VAR_4[VAR_7])+W_CO)>>W_CS; VAR_2[VAR_7] += (W_BM*(VAR_1[VAR_7] + VAR_3[VAR_7])+4*VAR_2[VAR_7]+W_BO)>>W_BS; VAR_1[VAR_7] += (W_AM*(VAR_0[VAR_7] + VAR_2[VAR_7])+W_AO)>>W_AS; } asm volatile (
"jmp 2f                                      \n\t"
"1:                                          \n\t"
"mov %6, %%"REG_a"                           \n\t"
"mov %4, %%"REG_S"                           \n\t"
snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")
snow_vertical_compose_sse2_r2r_add("xmm0","xmm2","xmm4","xmm6","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")
"pcmpeqd %%xmm1, %%xmm1                      \n\t"
"pslld $31, %%xmm1                           \n\t"
"psrld $29, %%xmm1                           \n\t"
"mov %5, %%"REG_a"                           \n\t"
snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_sra("3","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_load(REG_a,"xmm1","xmm3","xmm5","xmm7")
snow_vertical_compose_sse2_sub("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")
snow_vertical_compose_sse2_store(REG_a,"xmm1","xmm3","xmm5","xmm7")
"mov %3, %%"REG_c"                           \n\t"
snow_vertical_compose_sse2_load(REG_S,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_add(REG_c,"xmm1","xmm3","xmm5","xmm7")
snow_vertical_compose_sse2_sub("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_store(REG_S,"xmm0","xmm2","xmm4","xmm6")
"mov %2, %%"REG_a"                           \n\t"
snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")
"pcmpeqd %%xmm1, %%xmm1                      \n\t"
"pslld $31, %%xmm1                           \n\t"
"psrld $30, %%xmm1                           \n\t"
"mov %1, %%"REG_S"                           \n\t"
snow_vertical_compose_sse2_r2r_add("xmm1","xmm1","xmm1","xmm1","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_sra("2","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_add(REG_c,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_store(REG_c,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_add(REG_S,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_move("xmm0","xmm2","xmm4","xmm6","xmm1","xmm3","xmm5","xmm7")
snow_vertical_compose_sse2_sra("1","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_r2r_add("xmm1","xmm3","xmm5","xmm7","xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_add(REG_a,"xmm0","xmm2","xmm4","xmm6")
snow_vertical_compose_sse2_store(REG_a,"xmm0","xmm2","xmm4","xmm6")
"2:                                          \n\t"
"sub $16, %%"REG_d"                          \n\t"
"jge 1b                                      \n\t"
:"+d"(VAR_7)
:
"m"(VAR_0),"m"(VAR_1),"m"(VAR_2),"m"(VAR_3),"m"(VAR_4),"m"(VAR_5):
"%"REG_a"","%"REG_S"","%"REG_c""); }