// File: /workspace/github_c_makefile_star2_O1/nh13[P]ksw/src/parasail/src/sw_striped_sse2_128_8.c
// Function: parasail_sw_table_striped_profile_sse2_128_8
parasail_result_t* PNAME(
        const parasail_profile_t * const restrict profile,
        const char * const restrict s2, const int s2Len,
        const int open, const int gap)
{
    /* declare local variables */
    int32_t i = 0;
    int32_t j = 0;
    int32_t k = 0;
    int32_t end_query = 0;
    int32_t end_ref = 0;
    int32_t s1Len = 0;
    const parasail_matrix_t *matrix = NULL;
    int32_t segWidth = 0;
    int32_t segLen = 0;
#ifdef PARASAIL_ROWCOL
    int32_t offset = 0;
    int32_t position = 0;
#endif
    __m128i* restrict vProfile = NULL;
    __m128i* restrict pvHStore = NULL;
    __m128i* restrict pvHLoad = NULL;
    __m128i* restrict pvHMax = NULL;
    __m128i* restrict pvE = NULL;
    __m128i vGapO;
    __m128i vGapE;
    __m128i vZero;
    int8_t bias = 0;
    int8_t score = 0;
    __m128i vBias;
    __m128i vMaxH;
    __m128i vMaxHUnit;
    int8_t maxp = 0;
    __m128i insert_mask;
    /*int8_t stop = 0;*/
    parasail_result_t *result = NULL;

    /* validate inputs */
    PARASAIL_CHECK_NULL(profile);
    PARASAIL_CHECK_NULL(profile->profile8.score);
    PARASAIL_CHECK_NULL(profile->matrix);
    PARASAIL_CHECK_GT0(profile->s1Len);
    PARASAIL_CHECK_NULL(s2);
    PARASAIL_CHECK_GT0(s2Len);
    PARASAIL_CHECK_GE0(open);
    PARASAIL_CHECK_GE0(gap);

    /* initialize stack variables */
    i = 0;
    j = 0;
    k = 0;
    end_query = 0;
    end_ref = 0;
    s1Len = profile->s1Len;
    matrix = profile->matrix;
    segWidth = 16; /* number of values in vector unit */
    segLen = (s1Len + segWidth - 1) / segWidth;
#ifdef PARASAIL_ROWCOL
    offset = (s1Len - 1) % segLen;
    position = (segWidth - 1) - (s1Len - 1) / segLen;
#endif
    vProfile = (__m128i*)profile->profile8.score;
    vGapO = _mm_set1_epi8(open);
    vGapE = _mm_set1_epi8(gap);
    vZero = _mm_set1_epi8(0);
    bias = INT8_MIN;
    score = bias;
    vBias = _mm_set1_epi8(bias);
    vMaxH = vBias;
    vMaxHUnit = vBias;
    maxp = INT8_MAX - (int8_t)(matrix->max+1);
    insert_mask = _mm_cmpgt_epi8(
            _mm_set_epi8(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1),
            vZero);
    /*stop = profile->stop == INT32_MAX ?  INT8_MAX : (int8_t)profile->stop-bias;*/

    /* initialize result */
#ifdef PARASAIL_TABLE
    result = parasail_result_new_table1(segLen*segWidth, s2Len);
#else
#ifdef PARASAIL_ROWCOL
    result = parasail_result_new_rowcol1(segLen*segWidth, s2Len);
#else
    result = parasail_result_new();
#endif
#endif
    if (!result) return NULL;

    /* set known flags */
    result->flag |= PARASAIL_FLAG_SW | PARASAIL_FLAG_STRIPED
        | PARASAIL_FLAG_BITS_8 | PARASAIL_FLAG_LANES_16;
#ifdef PARASAIL_TABLE
    result->flag |= PARASAIL_FLAG_TABLE;
#endif
#ifdef PARASAIL_ROWCOL
    result->flag |= PARASAIL_FLAG_ROWCOL;
#endif

    /* initialize heap variables */
    pvHStore = parasail_memalign___m128i(16, segLen);
    pvHLoad = parasail_memalign___m128i(16, segLen);
    pvHMax = parasail_memalign___m128i(16, segLen);
    pvE = parasail_memalign___m128i(16, segLen);

    /* validate heap variables */
    if (!pvHStore) return NULL;
    if (!pvHLoad) return NULL;
    if (!pvHMax) return NULL;
    if (!pvE) return NULL;

    /* initialize H and E */
    parasail_memset___m128i(pvHStore, vBias, segLen);
    parasail_memset___m128i(pvE, vBias, segLen);

    /* outer loop over database sequence */
    for (j=0; j<s2Len; ++j) {
        __m128i vE;
        __m128i vF;
        __m128i vH;
        const __m128i* vP = NULL;
        __m128i* pv = NULL;

        /* Initialize F value to 0.  Any errors to vH values will be
         * corrected in the Lazy_F loop.  */
        vF = vBias;

        /* load final segment of pvHStore and shift left by 1 bytes */
        vH = _mm_slli_si128(pvHStore[segLen - 1], 1);
        vH = _mm_blendv_epi8_rpl(vH, vBias, insert_mask);

        /* Correct part of the vProfile */
        vP = vProfile + matrix->mapper[(unsigned char)s2[j]] * segLen;

        if (end_ref == j-2) {
            /* Swap in the max buffer. */
            pv = pvHMax;
            pvHMax = pvHLoad;
            pvHLoad = pvHStore;
            pvHStore = pv;
        }
        else {
            /* Swap the 2 H buffers. */
            pv = pvHLoad;
            pvHLoad = pvHStore;
            pvHStore = pv;
        }

        /* inner loop to process the query sequence */
        for (i=0; i<segLen; ++i) {
            vH = _mm_adds_epi8(vH, _mm_load_si128(vP + i));
            vE = _mm_load_si128(pvE + i);

            /* Get max from vH, vE and vF. */
            vH = _mm_max_epi8_rpl(vH, vE);
            vH = _mm_max_epi8_rpl(vH, vF);
            /* Save vH values. */
            _mm_store_si128(pvHStore + i, vH);
#ifdef PARASAIL_TABLE
            arr_store_si128(result->tables->score_table, vH, i, segLen, j, s2Len, bias);
#endif
            vMaxH = _mm_max_epi8_rpl(vH, vMaxH);

            /* Update vE value. */
            vH = _mm_subs_epi8(vH, vGapO);
            vE = _mm_subs_epi8(vE, vGapE);
            vE = _mm_max_epi8_rpl(vE, vH);
            _mm_store_si128(pvE + i, vE);

            /* Update vF value. */
            vF = _mm_subs_epi8(vF, vGapE);
            vF = _mm_max_epi8_rpl(vF, vH);

            /* Load the next vH. */
            vH = _mm_load_si128(pvHLoad + i);
        }

        /* Lazy_F loop: has been revised to disallow adjecent insertion and
         * then deletion, so don't update E(i, i), learn from SWPS3 */
        for (k=0; k<segWidth; ++k) {
            vF = _mm_slli_si128(vF, 1);
            vF = _mm_blendv_epi8_rpl(vF, vBias, insert_mask);
            for (i=0; i<segLen; ++i) {
                vH = _mm_load_si128(pvHStore + i);
                vH = _mm_max_epi8_rpl(vH,vF);
                _mm_store_si128(pvHStore + i, vH);
#ifdef PARASAIL_TABLE
                arr_store_si128(result->tables->score_table, vH, i, segLen, j, s2Len, bias);
#endif
                vMaxH = _mm_max_epi8_rpl(vH, vMaxH);
                vH = _mm_subs_epi8(vH, vGapO);
                vF = _mm_subs_epi8(vF, vGapE);
                if (! _mm_movemask_epi8(_mm_cmpgt_epi8(vF, vH))) goto end;
                /*vF = _mm_max_epi8_rpl(vF, vH);*/
            }
        }
end:
        {
        }

#ifdef PARASAIL_ROWCOL
        /* extract last value from the column */
        {
            vH = _mm_load_si128(pvHStore + offset);
            for (k=0; k<position; ++k) {
                vH = _mm_slli_si128(vH, 1);
            }
            result->rowcols->score_row[j] = (int8_t) _mm_extract_epi8_rpl (vH, 15) - bias;
        }
#endif

        {
            __m128i vCompare = _mm_cmpgt_epi8(vMaxH, vMaxHUnit);
            if (_mm_movemask_epi8(vCompare)) {
                score = _mm_hmax_epi8_rpl(vMaxH);
                /* if score has potential to overflow, abort early */
                if (score > maxp) {
                    result->flag |= PARASAIL_FLAG_SATURATED;
                    break;
                }
                vMaxHUnit = _mm_set1_epi8(score);
                end_ref = j;
            }
        }

        /*if (score == stop) break;*/
    }

#ifdef PARASAIL_ROWCOL
    for (i=0; i<segLen; ++i) {
        __m128i vH = _mm_load_si128(pvHStore+i);
        arr_store_col(result->rowcols->score_col, vH, i, segLen, bias);
    }
#endif

    if (score == INT8_MAX) {
        result->flag |= PARASAIL_FLAG_SATURATED;
    }

    if (parasail_result_is_saturated(result)) {
        score = INT8_MAX;
        end_query = 0;
        end_ref = 0;
    }
    else {
        if (end_ref == j-1) {
            /* end_ref was the last store column */
            __m128i *pv = pvHMax;
            pvHMax = pvHStore;
            pvHStore = pv;
        }
        else if (end_ref == j-2) {
            /* end_ref was the last load column */
            __m128i *pv = pvHMax;
            pvHMax = pvHLoad;
            pvHLoad = pv;
        }
        /* Trace the alignment ending position on read. */
        {
            int8_t *t = (int8_t*)pvHMax;
            int32_t column_len = segLen * segWidth;
            end_query = s1Len - 1;
            for (i = 0; i<column_len; ++i, ++t) {
                if (*t == score) {
                    int32_t temp = i / segWidth + i % segWidth * segLen;
                    if (temp < end_query) {
                        end_query = temp;
                    }
                }
            }
        }
    }

    result->score = score - bias;
    result->end_query = end_query;
    result->end_ref = end_ref;

    parasail_free(pvE);
    parasail_free(pvHMax);
    parasail_free(pvHLoad);
    parasail_free(pvHStore);

    return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x188, %rsp            # imm = 0x188
movq %rsi, 0x88(%rsp)
testq %rdi, %rdi
je 0x30535a
movq 0x18(%rdi), %rax
movq %rax, 0x148(%rsp)
testq %rax, %rax
je 0x305361
movq 0x10(%rdi), %rax
movq %rax, 0x80(%rsp)
testq %rax, %rax
je 0x305368
movl 0x8(%rdi), %eax
testl %eax, %eax
jle 0x30536f
cmpq $0x0, 0x88(%rsp)
je 0x305376
testl %edx, %edx
jle 0x30537d
movl %ecx, %ebp
testl %ecx, %ecx
js 0x305384
movl %r8d, %ebx
testl %r8d, %r8d
js 0x30538b
movq %rax, 0x128(%rsp)
leaq 0xf(%rax), %r15
movq 0x80(%rsp), %rax
movl 0x1c(%rax), %r13d
movl %r15d, %r12d
andl $0x7ffffff0, %r12d      # imm = 0x7FFFFFF0
movl %r12d, %edi
movq %rdx, 0x58(%rsp)
movl %edx, %esi
callq 0x20959f
testq %rax, %rax
je 0x305390
movq %rax, %r14
movl %r13d, 0x4(%rsp)
movl %ebp, 0x18(%rsp)
movl %ebx, 0x8(%rsp)
movl %r12d, 0x70(%rsp)
shrq $0x4, %r15
orl $0x10120804, 0xc(%rax)  # imm = 0x10120804
movl $0x10, %edi
movq %r15, %rsi
callq 0x2ea474
movq %rax, %rbp
movl $0x10, %edi
movq %r15, %rsi
callq 0x2ea474
movq %rax, %r12
movl $0x10, %edi
movq %r15, %rsi
callq 0x2ea474
movq %rax, %rbx
movl $0x10, %edi
movq %r15, %rsi
callq 0x2ea474
movq %r12, %r13
movq %rax, %r12
testq %rbp, %rbp
sete %al
testq %r13, %r13
sete %cl
orb %al, %cl
movq %rbx, 0x30(%rsp)
testq %rbx, %rbx
sete %al
testq %r12, %r12
sete %dl
orb %al, %dl
orb %cl, %dl
jne 0x305390
movq %rbp, %rsi
movd 0x18(%rsp), %xmm0
punpcklbw %xmm0, %xmm0    # xmm0 = xmm0[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
pshuflw $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0,4,5,6,7]
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0x160(%rsp)
movd 0x8(%rsp), %xmm0
punpcklbw %xmm0, %xmm0    # xmm0 = xmm0[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
pshuflw $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0,4,5,6,7]
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0x150(%rsp)
movaps 0x2f1400(%rip), %xmm0   # 0x5f5ea0
movq %rbp, %rdi
movq %rsi, 0x38(%rsp)
movq %r13, 0x8(%rsp)
movq %r15, %rsi
callq 0x2ea47d
movq %r12, 0x18(%rsp)
movq %r12, %rdi
movaps 0x2f13dc(%rip), %xmm0   # 0x5f5ea0
movq %r15, %rsi
callq 0x2ea47d
movdqa 0x2f13cb(%rip), %xmm10  # 0x5f5ea0
movdqa 0x150(%rsp), %xmm9
movdqa 0x160(%rsp), %xmm8
leal -0x1(%r15), %edx
movl 0x58(%rsp), %ecx
movb $0x7e, %al
subb 0x4(%rsp), %al
movsbl %al, %eax
movl %eax, 0x74(%rsp)
movq %r15, 0x78(%rsp)
movl %r15d, %esi
movq %rsi, %rax
imulq %rcx, %rax
leaq (,%rax,4), %rdi
movq %rcx, 0x130(%rsp)
leaq (,%rcx,4), %r8
leaq (,%rax,8), %r9
leaq (%rax,%rax,8), %rcx
leaq (%rcx,%rcx,2), %rcx
addq %rax, %rcx
movq %rax, %r10
imulq $0x2c, %rax, %r15
imulq $0x34, %rax, %r13
imulq $0x38, %rax, %r12
imulq $0x3c, %rax, %rbx
movq %rbx, 0xd8(%rsp)
shlq $0x4, %rax
shlq $0x5, %r10
movq %rsi, 0x138(%rsp)
movq %rsi, %rbx
movq %rax, %rsi
shlq $0x4, %rbx
movq %rbx, 0xc8(%rsp)
shlq $0x4, %rdx
movq %rdx, 0x140(%rsp)
movd 0x2f1337(%rip), %xmm0   # 0x5f5ec0
movdqa %xmm10, %xmm2
movdqa %xmm10, %xmm1
leaq (%rdi,%rdi,2), %rax
movq %rax, 0xc0(%rsp)
leaq (%rdi,%rdi,4), %rax
movq %rax, 0xb8(%rsp)
leaq (%r9,%r9,2), %rax
movq %rax, 0xb0(%rsp)
movq %rdi, %r11
leaq (%rdi,%rdi,8), %rax
movq %rax, 0xa8(%rsp)
movq %r9, %rdi
leaq (%r9,%r9,4), %rax
movq %rax, 0xa0(%rsp)
leaq (%rsi,%rsi,2), %rax
movq %rax, 0x98(%rsp)
movb $-0x80, %al
movl %eax, 0x14(%rsp)
xorl %r9d, %r9d
xorl %edx, %edx
xorl %ebx, %ebx
movq 0x38(%rsp), %rax
movq %r14, 0x120(%rsp)
movq %r11, 0x118(%rsp)
movq %r8, 0x110(%rsp)
movq %rdi, 0x108(%rsp)
movq %rcx, 0x100(%rsp)
movq %r10, 0xf8(%rsp)
movq %r15, 0xf0(%rsp)
movq %r13, 0xe8(%rsp)
movq %r12, 0xe0(%rsp)
movq %rsi, 0xd0(%rsp)
movq %rax, %rbp
movq 0x80(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x88(%rsp), %rcx
movzbl (%rcx,%rdx), %ecx
movslq (%rax,%rcx,4), %rax
movq 0x138(%rsp), %rcx
imulq %rax, %rcx
shlq $0x4, %rcx
addq 0x148(%rsp), %rcx
movq %rcx, 0x68(%rsp)
movq %rdx, 0x60(%rsp)
leal -0x2(%rdx), %eax
movq %rbx, 0x90(%rsp)
cmpl %eax, %ebx
movq 0x8(%rsp), %rcx
movq %rcx, %r12
movq 0x30(%rsp), %rax
cmoveq %rax, %r12
cmoveq %rcx, %rax
movq %rax, 0x30(%rsp)
movq 0x140(%rsp), %rax
movq %rbp, 0x50(%rsp)
movdqa (%rbp,%rax), %xmm4
pslldq $0x1, %xmm4             # xmm4 = zero,xmm4[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14]
por %xmm0, %xmm4
movq %r9, 0x48(%rsp)
movq %r9, 0x8(%rsp)
xorl %edx, %edx
movdqa %xmm10, %xmm3
movl $0x80, %ecx
movq 0x68(%rsp), %rax
paddsb (%rax,%rdx), %xmm4
movq 0x18(%rsp), %rax
movdqa (%rax,%rdx), %xmm5
movdqa %xmm4, %xmm6
pcmpgtb %xmm5, %xmm6
pand %xmm6, %xmm4
pandn %xmm5, %xmm6
por %xmm4, %xmm6
movdqa %xmm6, %xmm4
pcmpgtb %xmm3, %xmm4
pand %xmm4, %xmm6
pandn %xmm3, %xmm4
por %xmm6, %xmm4
movdqa %xmm4, (%r12,%rdx)
movq 0x10(%r14), %rax
movq (%rax), %rax
movsbl (%r12,%rdx), %ebp
addl %ecx, %ebp
movsbl 0x1(%r12,%rdx), %r10d
movsbl 0x2(%r12,%rdx), %r11d
movsbl 0x3(%r12,%rdx), %r13d
movsbl 0x4(%r12,%rdx), %esi
movsbl 0x5(%r12,%rdx), %edi
movsbl 0x6(%r12,%rdx), %r8d
movsbl 0x7(%r12,%rdx), %r9d
movsbl 0x8(%r12,%rdx), %ebx
movsbl 0x9(%r12,%rdx), %r14d
movsbl 0xa(%r12,%rdx), %r15d
movsbl 0xb(%r12,%rdx), %ecx
movl %ecx, 0x20(%rsp)
movsbl 0xc(%r12,%rdx), %ecx
movl %ecx, 0x24(%rsp)
movsbl 0xd(%r12,%rdx), %ecx
movl %ecx, 0x28(%rsp)
movsbl 0xe(%r12,%rdx), %ecx
movl %ecx, 0x2c(%rsp)
movsbl 0xf(%r12,%rdx), %ecx
movl %ecx, 0x4(%rsp)
movq 0x8(%rsp), %rcx
movl %ebp, (%rax,%rcx)
addq %rcx, %rax
movl $0x80, %ebp
addl %ebp, %r10d
movq 0x118(%rsp), %rbp
movl %r10d, (%rbp,%rax)
movl $0x80, %r10d
addl %r10d, %r11d
movq 0x108(%rsp), %r10
movl %r11d, (%r10,%rax)
movl $0x80, %r10d
addl %r10d, %r13d
movq 0xc0(%rsp), %r10
movl %r13d, (%r10,%rax)
movl $0x80, %r10d
addl %r10d, %esi
movq 0xd0(%rsp), %r10
movl %esi, (%r10,%rax)
movl $0x80, %ecx
addl %ecx, %edi
movq 0xb8(%rsp), %r10
movl %edi, (%r10,%rax)
addl %ecx, %r8d
movq 0xb0(%rsp), %rsi
movl %r8d, (%rsi,%rax)
addl %ecx, %r9d
movq 0x100(%rsp), %rsi
movl %r9d, (%rsi,%rax)
addl %ecx, %ebx
movq 0xf8(%rsp), %rsi
movl %ebx, (%rsi,%rax)
movq 0x110(%rsp), %r8
addl %ecx, %r14d
movq 0xa8(%rsp), %rsi
movl %r14d, (%rsi,%rax)
addl %ecx, %r15d
movq 0xa0(%rsp), %rsi
movl %r15d, (%rsi,%rax)
movl 0x20(%rsp), %edi
addl %ecx, %edi
movq 0xf0(%rsp), %rsi
movl %edi, (%rsi,%rax)
movq 0x120(%rsp), %r14
movl 0x24(%rsp), %edi
addl %ecx, %edi
movq 0x98(%rsp), %rsi
movl %edi, (%rsi,%rax)
movl 0x28(%rsp), %edi
addl %ecx, %edi
movq 0xe8(%rsp), %rsi
movl %edi, (%rsi,%rax)
movl 0x2c(%rsp), %edi
addl %ecx, %edi
movq 0xe0(%rsp), %rsi
movl %edi, (%rsi,%rax)
movl 0x4(%rsp), %edi
addl %ecx, %edi
movq 0xd8(%rsp), %rsi
movl %edi, (%rsi,%rax)
movdqa %xmm4, %xmm6
pcmpgtb %xmm1, %xmm6
movdqa %xmm4, %xmm7
pand %xmm6, %xmm7
pandn %xmm1, %xmm6
movdqa %xmm6, %xmm1
por %xmm7, %xmm1
psubsb %xmm8, %xmm4
psubsb %xmm9, %xmm5
movdqa %xmm5, %xmm6
pcmpgtb %xmm4, %xmm6
pand %xmm6, %xmm5
pandn %xmm4, %xmm6
por %xmm5, %xmm6
movq 0x18(%rsp), %rax
movdqa %xmm6, (%rax,%rdx)
psubsb %xmm9, %xmm3
movdqa %xmm3, %xmm5
pcmpgtb %xmm4, %xmm3
pand %xmm3, %xmm5
pandn %xmm4, %xmm3
por %xmm5, %xmm3
movq 0x50(%rsp), %rax
movdqa (%rax,%rdx), %xmm4
addq $0x10, %rdx
addq %r8, 0x8(%rsp)
cmpq %rdx, 0xc8(%rsp)
jne 0x304cdd
movq %r12, 0x38(%rsp)
movl $0x0, 0x44(%rsp)
pslldq $0x1, %xmm3             # xmm3 = zero,xmm3[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14]
por %xmm0, %xmm3
movq 0x48(%rsp), %r10
xorl %ebp, %ebp
movq 0x38(%rsp), %rcx
movdqa (%rcx,%rbp), %xmm5
movdqa %xmm5, %xmm4
pcmpgtb %xmm3, %xmm4
pand %xmm4, %xmm5
pandn %xmm3, %xmm4
por %xmm5, %xmm4
movdqa %xmm4, (%rcx,%rbp)
movq 0x10(%r14), %rax
movq (%rax), %rax
movq %rax, 0x68(%rsp)
movq %r10, %rax
movsbl (%rcx,%rbp), %r10d
movl $0x80, %edx
addl %edx, %r10d
movsbl 0x1(%rcx,%rbp), %r13d
movsbl 0x2(%rcx,%rbp), %esi
movsbl 0x3(%rcx,%rbp), %edi
movsbl 0x4(%rcx,%rbp), %r11d
movsbl 0x5(%rcx,%rbp), %r8d
movsbl 0x6(%rcx,%rbp), %r9d
movsbl 0x7(%rcx,%rbp), %ebx
movsbl 0x8(%rcx,%rbp), %r14d
movsbl 0x9(%rcx,%rbp), %r15d
movsbl 0xa(%rcx,%rbp), %r12d
movl %r12d, 0x20(%rsp)
movsbl 0xb(%rcx,%rbp), %r12d
movl %r12d, 0x24(%rsp)
movsbl 0xc(%rcx,%rbp), %r12d
movl %r12d, 0x28(%rsp)
movsbl 0xd(%rcx,%rbp), %r12d
movl %r12d, 0x2c(%rsp)
movsbl 0xe(%rcx,%rbp), %r12d
movl %r12d, 0x4(%rsp)
movsbl 0xf(%rcx,%rbp), %ecx
movl %ecx, 0x8(%rsp)
movq 0x68(%rsp), %rcx
movl %r10d, (%rcx,%rax)
movq %rax, %r10
addq %rcx, %rax
addl %edx, %r13d
movq 0x118(%rsp), %rcx
movl %r13d, (%rcx,%rax)
addl %edx, %esi
movq 0x108(%rsp), %rcx
movl %esi, (%rcx,%rax)
addl %edx, %edi
movq 0xc0(%rsp), %rcx
movl %edi, (%rcx,%rax)
addl %edx, %r11d
movq 0xd0(%rsp), %rcx
movl %r11d, (%rcx,%rax)
addl %edx, %r8d
movq 0xb8(%rsp), %rcx
movl %r8d, (%rcx,%rax)
addl %edx, %r9d
movq 0xb0(%rsp), %rcx
movl %r9d, (%rcx,%rax)
movq 0x110(%rsp), %r8
addl %edx, %ebx
movq 0x100(%rsp), %rcx
movl %ebx, (%rcx,%rax)
addl %edx, %r14d
movq 0xf8(%rsp), %rcx
movl %r14d, (%rcx,%rax)
addl %edx, %r15d
movq 0xa8(%rsp), %rcx
movl %r15d, (%rcx,%rax)
movl 0x20(%rsp), %esi
addl %edx, %esi
movq 0xa0(%rsp), %rcx
movl %esi, (%rcx,%rax)
movl 0x24(%rsp), %esi
addl %edx, %esi
movq 0xf0(%rsp), %rcx
movl %esi, (%rcx,%rax)
movq 0x120(%rsp), %r14
movl 0x28(%rsp), %esi
addl %edx, %esi
movq 0x98(%rsp), %rcx
movl %esi, (%rcx,%rax)
movl 0x2c(%rsp), %esi
addl %edx, %esi
movq 0xe8(%rsp), %rcx
movl %esi, (%rcx,%rax)
movl 0x4(%rsp), %esi
addl %edx, %esi
movq 0xe0(%rsp), %rcx
movl %esi, (%rcx,%rax)
movl 0x8(%rsp), %esi
addl %edx, %esi
movq 0xd8(%rsp), %rcx
movl %esi, (%rcx,%rax)
movdqa %xmm4, %xmm5
pcmpgtb %xmm1, %xmm5
movdqa %xmm4, %xmm6
pand %xmm5, %xmm6
pandn %xmm1, %xmm5
movdqa %xmm5, %xmm1
por %xmm6, %xmm1
psubsb %xmm8, %xmm4
psubsb %xmm9, %xmm3
movdqa %xmm3, %xmm5
pcmpgtb %xmm4, %xmm5
pmovmskb %xmm5, %eax
testl %eax, %eax
movq 0xc8(%rsp), %rax
je 0x30516f
addq $0x10, %rbp
addq %r8, %r10
cmpq %rbp, %rax
jne 0x304f56
movl 0x44(%rsp), %eax
incl %eax
movl %eax, 0x44(%rsp)
cmpl $0x10, %eax
jne 0x304f46
movdqa %xmm1, %xmm3
pcmpgtb %xmm2, %xmm3
pmovmskb %xmm3, %eax
movb $0x1, %cl
testl %eax, %eax
je 0x305229
movdqa %xmm1, %xmm3
psrldq $0x8, %xmm3             # xmm3 = xmm3[8,9,10,11,12,13,14,15],zero,zero,zero,zero,zero,zero,zero,zero
movdqa %xmm1, %xmm4
pcmpgtb %xmm3, %xmm4
movdqa %xmm1, %xmm5
pand %xmm4, %xmm5
pandn %xmm3, %xmm4
por %xmm5, %xmm4
movdqa %xmm4, %xmm3
psrldq $0x4, %xmm3             # xmm3 = xmm3[4,5,6,7,8,9,10,11,12,13,14,15],zero,zero,zero,zero
movdqa %xmm4, %xmm5
pcmpgtb %xmm3, %xmm5
pand %xmm5, %xmm4
pandn %xmm3, %xmm5
por %xmm4, %xmm5
movdqa %xmm5, %xmm3
psrldq $0x2, %xmm3             # xmm3 = xmm3[2,3,4,5,6,7,8,9,10,11,12,13,14,15],zero,zero
movdqa %xmm5, %xmm4
pcmpgtb %xmm3, %xmm4
pand %xmm4, %xmm5
pandn %xmm3, %xmm4
por %xmm5, %xmm4
movdqa %xmm4, %xmm5
psrldq $0x1, %xmm5             # xmm5 = xmm5[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15],zero
movdqa %xmm4, %xmm3
pcmpgtb %xmm5, %xmm3
pand %xmm3, %xmm4
pandn %xmm5, %xmm3
por %xmm4, %xmm3
movdqa %xmm3, 0x170(%rsp)
movsbl 0x170(%rsp), %eax
movl %eax, 0x14(%rsp)
cmpl %eax, 0x74(%rsp)
movq 0x90(%rsp), %rbx
jge 0x305238
orb $0x40, 0xc(%r14)
xorl %ecx, %ecx
jmp 0x30524b
movq 0x30(%rsp), %rdx
movq 0x90(%rsp), %rbx
jmp 0x305250
punpcklbw %xmm3, %xmm3    # xmm3 = xmm3[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
pshuflw $0x0, %xmm3, %xmm2      # xmm2 = xmm3[0,0,0,0,4,5,6,7]
pshufd $0x0, %xmm2, %xmm2      # xmm2 = xmm2[0,0,0,0]
movq 0x60(%rsp), %rbx
movq 0x30(%rsp), %rdx
movq 0x50(%rsp), %rbp
movq 0x48(%rsp), %r9
testb %cl, %cl
je 0x305289
movq 0x60(%rsp), %rdx
incq %rdx
addq $0x4, %r9
movq %rbp, 0x8(%rsp)
cmpq 0x130(%rsp), %rdx
movq 0x38(%rsp), %rax
jne 0x304c43
movq 0x30(%rsp), %r13
jmp 0x305296
movq 0x60(%rsp), %rax
movq %rax, 0x58(%rsp)
movq %rdx, %r13
cmpb $0x7f, 0x14(%rsp)
jne 0x3052a2
orb $0x40, 0xc(%r14)
movq %r14, %rdi
callq 0x20a805
testl %eax, %eax
je 0x3052cd
xorl %ebx, %ebx
movl $0xff, %eax
movq %rbp, %r12
movq %r13, %rbp
xorl %r8d, %r8d
movq 0x18(%rsp), %rdi
movq 0x38(%rsp), %r13
jmp 0x3053b4
movq 0x58(%rsp), %rcx
leal -0x1(%rcx), %eax
addl $-0x2, %ecx
cmpl %ecx, %ebx
movq %rbp, %r12
cmoveq %r13, %r12
movq %rbp, %rcx
movq %r13, %rbp
cmoveq %rcx, %rbp
cmpl %eax, %ebx
movq 0x38(%rsp), %rax
cmovneq %rax, %r13
cmoveq %rcx, %r12
cmoveq %rax, %rbp
movq 0x128(%rsp), %r8
decl %r8d
cmpl $0x0, 0x70(%rsp)
movq 0x18(%rsp), %rdi
je 0x3053a8
movq 0x78(%rsp), %rax
andl $0x7ffffff, %eax        # imm = 0x7FFFFFF
shll $0x4, %eax
xorl %ecx, %ecx
movl 0x14(%rsp), %r9d
cmpb %r9b, (%rbp,%rcx)
jne 0x305351
movl %ecx, %edx
shrl $0x4, %edx
movl %ecx, %esi
andl $0xf, %esi
imull 0x78(%rsp), %esi
addl %edx, %esi
movq 0x18(%rsp), %rdi
cmpl %r8d, %esi
cmovll %esi, %r8d
incq %rcx
cmpl %ecx, %eax
jne 0x30532d
jmp 0x3053ad
callq 0x1af0c3
jmp 0x305390
callq 0x1af09d
jmp 0x305390
callq 0x1af077
jmp 0x305390
callq 0x1af051
jmp 0x305390
callq 0x1af02b
jmp 0x305390
callq 0x1af005
jmp 0x305390
callq 0x1aefdf
jmp 0x305390
callq 0x1aefb9
xorl %r14d, %r14d
movq %r14, %rax
addq $0x188, %rsp            # imm = 0x188
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0x14(%rsp), %r9d
movsbl %r9b, %eax
subl $-0x80, %eax
movl %eax, (%r14)
movl %r8d, 0x4(%r14)
movl %ebx, 0x8(%r14)
callq 0x2094b5
movq %rbp, %rdi
callq 0x2094b5
movq %r12, %rdi
callq 0x2094b5
movq %r13, %rdi
callq 0x2094b5
jmp 0x305393
nop