// File: /workspace/github_c_makefile_star2_O3/nh13[P]ksw/src/parasail/src/sw_diag_sse41_128_32.c
// Function: parasail_sw_rowcol_diag_sse41_128_32
parasail_result_t* FNAME(
        const char * const restrict _s1, const int _s1Len,
        const char * const restrict _s2, const int s2Len,
        const int open, const int gap, const parasail_matrix_t *matrix)
{
    /* declare local variables */
    int32_t N = 0;
    int32_t PAD = 0;
    int32_t PAD2 = 0;
    int32_t s1Len = 0;
    int32_t s1Len_PAD = 0;
    int32_t s2Len_PAD = 0;
    int32_t * restrict s1 = NULL;
    int32_t * restrict s2B = NULL;
    int32_t * restrict _H_pr = NULL;
    int32_t * restrict _F_pr = NULL;
    int32_t * restrict s2 = NULL;
    int32_t * restrict H_pr = NULL;
    int32_t * restrict F_pr = NULL;
    parasail_result_t *result = NULL;
    int32_t i = 0;
    int32_t j = 0;
    int32_t end_query = 0;
    int32_t end_ref = 0;
    int32_t NEG_LIMIT = 0;
    int32_t POS_LIMIT = 0;
    int32_t score = 0;
    __m128i vNegLimit;
    __m128i vPosLimit;
    __m128i vSaturationCheckMin;
    __m128i vSaturationCheckMax;
    __m128i vNegInf;
    __m128i vNegInf0;
    __m128i vOpen;
    __m128i vGap;
    __m128i vZero;
    __m128i vOne;
    __m128i vN;
    __m128i vNegOne;
    __m128i vI;
    __m128i vJreset;
    __m128i vMaxH;
    __m128i vEndI;
    __m128i vEndJ;
    __m128i vILimit;
    __m128i vJLimit;

    /* validate inputs */
    PARASAIL_CHECK_NULL(_s2);
    PARASAIL_CHECK_GT0(s2Len);
    PARASAIL_CHECK_GE0(open);
    PARASAIL_CHECK_GE0(gap);
    PARASAIL_CHECK_NULL(matrix);
    if (matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) {
        PARASAIL_CHECK_NULL(_s1);
        PARASAIL_CHECK_GT0(_s1Len);
    }

    /* initialize stack variables */
    N = 4; /* number of values in vector */
    PAD = N-1;
    PAD2 = PAD*2;
    s1Len = matrix->type == PARASAIL_MATRIX_TYPE_SQUARE ? _s1Len : matrix->length;
    s1Len_PAD = s1Len+PAD;
    s2Len_PAD = s2Len+PAD;
    i = 0;
    j = 0;
    end_query = 0;
    end_ref = 0;
    NEG_LIMIT = (-open < matrix->min ? INT32_MIN + open : INT32_MIN - matrix->min) + 1;
    POS_LIMIT = INT32_MAX - matrix->max - 1;
    score = NEG_LIMIT;
    vNegLimit = _mm_set1_epi32(NEG_LIMIT);
    vPosLimit = _mm_set1_epi32(POS_LIMIT);
    vSaturationCheckMin = vPosLimit;
    vSaturationCheckMax = vNegLimit;
    vNegInf = _mm_set1_epi32(NEG_LIMIT);
    vNegInf0 = _mm_srli_si128(vNegInf, 4); /* shift in a 0 */
    vOpen = _mm_set1_epi32(open);
    vGap  = _mm_set1_epi32(gap);
    vZero = _mm_set1_epi32(0);
    vOne = _mm_set1_epi32(1);
    vN = _mm_set1_epi32(N);
    vNegOne = _mm_set1_epi32(-1);
    vI = _mm_set_epi32(0,1,2,3);
    vJreset = _mm_set_epi32(0,-1,-2,-3);
    vMaxH = vNegInf;
    vEndI = vNegInf;
    vEndJ = vNegInf;
    vILimit = _mm_set1_epi32(s1Len);
    vJLimit = _mm_set1_epi32(s2Len);

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

    /* set known flags */
    result->flag |= PARASAIL_FLAG_SW | PARASAIL_FLAG_DIAG
        | PARASAIL_FLAG_BITS_32 | PARASAIL_FLAG_LANES_4;
#ifdef PARASAIL_TABLE
    result->flag |= PARASAIL_FLAG_TABLE;
#endif
#ifdef PARASAIL_ROWCOL
    result->flag |= PARASAIL_FLAG_ROWCOL;
#endif

    /* initialize heap variables */
    s2B= parasail_memalign_int32_t(16, s2Len+PAD2);
    _H_pr = parasail_memalign_int32_t(16, s2Len+PAD2);
    _F_pr = parasail_memalign_int32_t(16, s2Len+PAD2);
    s2 = s2B+PAD; /* will allow later for negative indices */
    H_pr = _H_pr+PAD;
    F_pr = _F_pr+PAD;

    /* validate heap variables */
    if (!s2B) return NULL;
    if (!_H_pr) return NULL;
    if (!_F_pr) return NULL;

    /* convert _s1 from char to int in range 0-23 */
    if (matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) {
        s1 = parasail_memalign_int32_t(16, s1Len+PAD);
        if (!s1) return NULL;
        for (i=0; i<s1Len; ++i) {
            s1[i] = matrix->mapper[(unsigned char)_s1[i]];
        }
        /* pad back of s1 with dummy values */
        for (i=s1Len; i<s1Len_PAD; ++i) {
            s1[i] = 0; /* point to first matrix row because we don't care */
        }
    }

    /* convert _s2 from char to int in range 0-23 */
    for (j=0; j<s2Len; ++j) {
        s2[j] = matrix->mapper[(unsigned char)_s2[j]];
    }
    /* pad front of s2 with dummy values */
    for (j=-PAD; j<0; ++j) {
        s2[j] = 0; /* point to first matrix row because we don't care */
    }
    /* pad back of s2 with dummy values */
    for (j=s2Len; j<s2Len_PAD; ++j) {
        s2[j] = 0; /* point to first matrix row because we don't care */
    }

    /* set initial values for stored row */
    for (j=0; j<s2Len; ++j) {
        H_pr[j] = 0;
        F_pr[j] = NEG_LIMIT;
    }
    /* pad front of stored row values */
    for (j=-PAD; j<0; ++j) {
        H_pr[j] = NEG_LIMIT;
        F_pr[j] = NEG_LIMIT;
    }
    /* pad back of stored row values */
    for (j=s2Len; j<s2Len+PAD; ++j) {
        H_pr[j] = NEG_LIMIT;
        F_pr[j] = NEG_LIMIT;
    }

    /* iterate over query sequence */
    for (i=0; i<s1Len; i+=N) {
        __m128i vNH = vNegInf0;
        __m128i vWH = vNegInf0;
        __m128i vE = vNegInf;
        __m128i vF = vNegInf;
        __m128i vJ = vJreset;
        const int * const restrict matrow0 = &matrix->matrix[matrix->size * ((matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) ? s1[i+0] : ((i+0 >= s1Len) ? s1Len-1 : i+0))];
        const int * const restrict matrow1 = &matrix->matrix[matrix->size * ((matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) ? s1[i+1] : ((i+1 >= s1Len) ? s1Len-1 : i+1))];
        const int * const restrict matrow2 = &matrix->matrix[matrix->size * ((matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) ? s1[i+2] : ((i+2 >= s1Len) ? s1Len-1 : i+2))];
        const int * const restrict matrow3 = &matrix->matrix[matrix->size * ((matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) ? s1[i+3] : ((i+3 >= s1Len) ? s1Len-1 : i+3))];
        __m128i vIltLimit = _mm_cmplt_epi32(vI, vILimit);
        /* iterate over database sequence */
        for (j=0; j<s2Len+PAD; ++j) {
            __m128i vMat;
            __m128i vNWH = vNH;
            vNH = _mm_srli_si128(vWH, 4);
            vNH = _mm_insert_epi32(vNH, H_pr[j], 3);
            vF = _mm_srli_si128(vF, 4);
            vF = _mm_insert_epi32(vF, F_pr[j], 3);
            vF = _mm_max_epi32(
                    _mm_sub_epi32(vNH, vOpen),
                    _mm_sub_epi32(vF, vGap));
            vE = _mm_max_epi32(
                    _mm_sub_epi32(vWH, vOpen),
                    _mm_sub_epi32(vE, vGap));
            vMat = _mm_set_epi32(
                    matrow0[s2[j-0]],
                    matrow1[s2[j-1]],
                    matrow2[s2[j-2]],
                    matrow3[s2[j-3]]
                    );
            vNWH = _mm_add_epi32(vNWH, vMat);
            vWH = _mm_max_epi32(vNWH, vE);
            vWH = _mm_max_epi32(vWH, vF);
            vWH = _mm_max_epi32(vWH, vZero);
            /* as minor diagonal vector passes across the j=-1 boundary,
             * assign the appropriate boundary conditions */
            {
                __m128i cond = _mm_cmpeq_epi32(vJ,vNegOne);
                vWH = _mm_andnot_si128(cond, vWH);
                vF = _mm_blendv_epi8(vF, vNegInf, cond);
                vE = _mm_blendv_epi8(vE, vNegInf, cond);
            }
            /* cannot start checking sat until after J clears boundary */
            if (j > PAD) {
                vSaturationCheckMin = _mm_min_epi32(vSaturationCheckMin, vWH);
                vSaturationCheckMax = _mm_max_epi32(vSaturationCheckMax, vWH);
            }
#ifdef PARASAIL_TABLE
            arr_store_si128(result->tables->score_table, vWH, i, s1Len, j, s2Len);
#endif
#ifdef PARASAIL_ROWCOL
            arr_store_rowcol(result->rowcols->score_row, result->rowcols->score_col, vWH, i, s1Len, j, s2Len);
#endif
            H_pr[j-3] = (int32_t)_mm_extract_epi32(vWH,0);
            F_pr[j-3] = (int32_t)_mm_extract_epi32(vF,0);
            /* as minor diagonal vector passes across table, extract
             * max values within the i,j bounds */
            {
                __m128i cond_valid_J = _mm_and_si128(
                        _mm_cmpgt_epi32(vJ, vNegOne),
                        _mm_cmplt_epi32(vJ, vJLimit));
                __m128i cond_valid_IJ = _mm_and_si128(cond_valid_J, vIltLimit);
                __m128i cond_eq = _mm_cmpeq_epi32(vWH, vMaxH);
                __m128i cond_max = _mm_cmpgt_epi32(vWH, vMaxH);
                __m128i cond_all = _mm_and_si128(cond_max, cond_valid_IJ);
                __m128i cond_Jlt = _mm_cmplt_epi32(vJ, vEndJ);
                vMaxH = _mm_blendv_epi8(vMaxH, vWH, cond_all);
                vEndI = _mm_blendv_epi8(vEndI, vI, cond_all);
                vEndJ = _mm_blendv_epi8(vEndJ, vJ, cond_all);
                cond_all = _mm_and_si128(cond_Jlt, cond_eq);
                cond_all = _mm_and_si128(cond_all, cond_valid_IJ);
                vEndI = _mm_blendv_epi8(vEndI, vI, cond_all);
                vEndJ = _mm_blendv_epi8(vEndJ, vJ, cond_all);
            }
            vJ = _mm_add_epi32(vJ, vOne);
        }
        vI = _mm_add_epi32(vI, vN);
    }

    /* alignment ending position */
    {
        int32_t *t = (int32_t*)&vMaxH;
        int32_t *i = (int32_t*)&vEndI;
        int32_t *j = (int32_t*)&vEndJ;
        int32_t k;
        for (k=0; k<N; ++k, ++t, ++i, ++j) {
            if (*t > score) {
                score = *t;
                end_query = *i;
                end_ref = *j;
            }
            else if (*t == score) {
                if (*j < end_ref) {
                    end_query = *i;
                    end_ref = *j;
                }
                else if (*j == end_ref && *i < end_query) {
                    end_query = *i;
                    end_ref = *j;
                }
            }
        }
    }

    if (_mm_movemask_epi8(_mm_or_si128(
            _mm_cmplt_epi32(vSaturationCheckMin, vNegLimit),
            _mm_cmpgt_epi32(vSaturationCheckMax, vPosLimit)))) {
        result->flag |= PARASAIL_FLAG_SATURATED;
        score = 0;
        end_query = 0;
        end_ref = 0;
    }

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

    parasail_free(_F_pr);
    parasail_free(_H_pr);
    parasail_free(s2B);
    if (matrix->type == PARASAIL_MATRIX_TYPE_SQUARE) {
        parasail_free(s1);
    }

    return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x138, %rsp            # imm = 0x138
testq %rdx, %rdx
je 0x453c00
movl %ecx, %ebp
testl %ecx, %ecx
jle 0x453c07
movl %r8d, %r13d
testl %r8d, %r8d
js 0x453c0e
movl %r9d, %r12d
testl %r9d, %r9d
js 0x453c15
movl %esi, %r14d
movq 0x170(%rsp), %rsi
testq %rsi, %rsi
je 0x453c1c
cmpl $0x0, 0x30(%rsi)
je 0x453424
movl 0x34(%rsi), %r14d
jmp 0x453436
testq %rdi, %rdi
je 0x453c23
testl %r14d, %r14d
jle 0x453c2a
movq %rdi, 0x30(%rsp)
movq %rdx, 0x38(%rsp)
movl %r13d, %eax
negl %eax
movl 0x20(%rsi), %ecx
movl $0x80000000, %edi       # imm = 0x80000000
movl %r13d, %edx
orl %edi, %edx
subl %ecx, %edi
cmpl %eax, %ecx
cmovgl %edx, %edi
incl %edi
movl $0x7ffffffe, %ebx       # imm = 0x7FFFFFFE
subl 0x1c(%rsi), %ebx
movl %edi, 0x14(%rsp)
movd %edi, %xmm0
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0xd0(%rsp)
movdqa %xmm0, 0x80(%rsp)
movdqa %xmm0, 0x40(%rsp)
movdqa %xmm0, 0xa0(%rsp)
movl %r14d, %edi
movl %ebp, %esi
callq 0x20ac53
testq %rax, %rax
je 0x453c2f
movq %rax, %r15
movl %r13d, 0x50(%rsp)
movl %r12d, 0x60(%rsp)
movq %r14, 0x8(%rsp)
orl $0x4441004, 0xc(%rax)   # imm = 0x4441004
leal 0x6(%rbp), %r12d
movl $0x10, %edi
movq %r12, %rsi
callq 0x20a62d
movq %rax, %r14
movl $0x10, %edi
movq %r12, %rsi
callq 0x20a62d
movq %rax, %r13
movl $0x10, %edi
movq %r12, %rsi
callq 0x20a62d
testq %r14, %r14
sete %dl
movq %r13, 0x20(%rsp)
testq %r13, %r13
sete %cl
orb %dl, %cl
testq %rax, %rax
sete %dl
orb %cl, %dl
jne 0x453c2f
movq 0x170(%rsp), %r12
cmpl $0x0, 0x30(%r12)
movq %rax, 0x18(%rsp)
movq %rbp, (%rsp)
je 0x45353e
movq %r15, 0x28(%rsp)
xorl %eax, %eax
movq 0x20(%rsp), %r15
movq 0x8(%rsp), %r13
jmp 0x4535be
movq 0x8(%rsp), %r13
leal 0x3(%r13), %ebp
movslq %ebp, %rsi
movl $0x10, %edi
callq 0x20a62d
testq %rax, %rax
je 0x453c2f
movq %r15, 0x28(%rsp)
testl %r13d, %r13d
movq 0x30(%rsp), %r8
jle 0x453589
movq 0x10(%r12), %rdi
movl %r13d, %ecx
xorl %edx, %edx
movzbl (%r8,%rdx), %esi
movl (%rdi,%rsi,4), %esi
movl %esi, (%rax,%rdx,4)
incq %rdx
cmpq %rdx, %rcx
jne 0x453576
movslq %r13d, %rcx
movq %rax, %r15
leaq (%rax,%rcx,4), %rdi
leal 0x1(%r13), %eax
cmpl %eax, %ebp
cmovgl %ebp, %eax
movl %r13d, %ecx
notl %ecx
addl %eax, %ecx
leaq 0x4(,%rcx,4), %rdx
xorl %esi, %esi
callq 0x19e090
movq %r15, %rax
movq 0x20(%rsp), %r15
movq (%rsp), %rbp
movq %rax, 0x78(%rsp)
movq %rbp, %rcx
addl $0x3, %ebp
movd %ebx, %xmm0
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0x90(%rsp)
movdqa 0x40(%rsp), %xmm0
psrldq $0x4, %xmm0             # xmm0 = xmm0[4,5,6,7,8,9,10,11,12,13,14,15],zero,zero,zero,zero
movdqa %xmm0, 0xf0(%rsp)
movd 0x50(%rsp), %xmm0
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0x120(%rsp)
movd 0x60(%rsp), %xmm0
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0x110(%rsp)
movd %r13d, %xmm0
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0xe0(%rsp)
movd %ecx, %xmm0
pshufd $0x0, %xmm0, %xmm0      # xmm0 = xmm0[0,0,0,0]
movdqa %xmm0, 0x100(%rsp)
movq 0x10(%r12), %rax
movl %ecx, %r13d
xorl %ecx, %ecx
movq 0x38(%rsp), %rsi
movzbl (%rsi,%rcx), %edx
movl (%rax,%rdx,4), %edx
movl %edx, 0xc(%r14,%rcx,4)
incq %rcx
cmpq %rcx, %r13
jne 0x45364b
movl $0x0, 0x8(%r14)
movq $0x0, (%r14)
leaq 0xc(%r14,%r13,4), %rdi
movq (%rsp), %rcx
leal 0x1(%rcx), %eax
cmpl %eax, %ebp
cmovgl %ebp, %eax
notl %ecx
addl %eax, %ecx
leaq 0x4(,%rcx,4), %rdx
xorl %ebx, %ebx
xorl %esi, %esi
callq 0x19e090
movl 0x14(%rsp), %r8d
movq 0x18(%rsp), %rdi
movl $0x0, 0xc(%r15,%rbx,4)
movl %r8d, 0xc(%rdi,%rbx,4)
incq %rbx
cmpq %rbx, %r13
jne 0x45369e
xorl %eax, %eax
movl %r8d, (%r15,%rax,4)
movl %r8d, (%rdi,%rax,4)
incq %rax
cmpq $0x3, %rax
jne 0x4536b6
leaq 0x3(%r13), %rax
movq (%rsp), %rcx
movl %r8d, (%r15,%rax,4)
movl %r8d, (%rdi,%rax,4)
incq %rax
incl %ecx
cmpl %ecx, %ebp
jg 0x4536cf
movq 0x8(%rsp), %rdx
testl %edx, %edx
jle 0x453b2d
movq 0x8(%r12), %rax
movq %rax, 0xb0(%rsp)
leal -0x1(%rdx), %ecx
movq (%rsp), %rax
decl %eax
movq %rax, (%rsp)
cmpl $0x2, %ebp
movl $0x1, %eax
cmovgel %ebp, %eax
movq %rax, 0xc8(%rsp)
movl %edx, %esi
leaq 0x1(%r13), %rax
movq %rax, 0xc0(%rsp)
leaq 0x2(%r13), %rax
movq %rax, 0xb8(%rsp)
pmovsxbd 0x1d87ad(%rip), %xmm6   # 0x62beea
xorl %edi, %edi
pcmpeqd %xmm7, %xmm7
movdqa 0x40(%rsp), %xmm5
movdqa %xmm5, %xmm9
movdqa %xmm5, %xmm12
movdqa 0x90(%rsp), %xmm0
movdqa %xmm0, 0x50(%rsp)
movdqa %xmm5, 0x60(%rsp)
movq %rdi, %r10
orq $0x3, %r10
cmpl $0x0, 0x30(%r12)
je 0x4537a0
movq %rdi, %rax
orq $0x1, %rax
cmpq %rsi, %rax
cmovael %ecx, %eax
movq %rdi, %rdx
orq $0x2, %rdx
cmpq %rsi, %rdx
cmovael %ecx, %edx
cmpq %rsi, %r10
movl %r10d, %r8d
cmovael %ecx, %r8d
movl %edi, %r9d
jmp 0x4537b7
movq 0x78(%rsp), %r8
movl (%r8,%rdi,4), %r9d
movl 0x4(%r8,%rdi,4), %eax
movl 0x8(%r8,%rdi,4), %edx
movl (%r8,%r10,4), %r8d
movl 0x18(%r12), %r11d
imull %r11d, %eax
cltq
movq 0xb0(%rsp), %rbx
leaq (%rbx,%rax,4), %rax
movq %rax, 0x38(%rsp)
imull %r11d, %r9d
movslq %r9d, %rax
leaq (%rbx,%rax,4), %rax
movq %rax, 0x8(%rsp)
imull %r11d, %edx
movslq %edx, %rdx
leaq (%rbx,%rdx,4), %rax
movq %rax, 0x30(%rsp)
imull %r11d, %r8d
movslq %r8d, %rdx
leaq (%rbx,%rdx,4), %rbp
movq %rdi, %r9
orq $0x1, %r9
movq %rdi, %rdx
orq $0x2, %rdx
movdqa 0xe0(%rsp), %xmm13
pcmpgtd %xmm6, %xmm13
xorl %r8d, %r8d
pmovsxbd 0x1d86c7(%rip), %xmm3   # 0x62beee
movdqa 0x40(%rsp), %xmm11
movdqa %xmm11, %xmm15
movdqa 0xf0(%rsp), %xmm8
movdqa %xmm8, %xmm10
movq 0x18(%rsp), %rbx
cmpq %rcx, %rdi
setne %r12b
movslq 0x8(%r14,%r8,4), %r11
movslq 0x4(%r14,%r8,4), %r15
movslq (%r14,%r8,4), %rax
movd (%rbp,%rax,4), %xmm0
movq 0x30(%rsp), %rax
pinsrd $0x1, (%rax,%r15,4), %xmm0
movq 0x38(%rsp), %rax
pinsrd $0x2, (%rax,%r11,4), %xmm0
movslq 0xc(%r14,%r8,4), %rax
movq 0x8(%rsp), %r11
pinsrd $0x3, (%r11,%rax,4), %xmm0
paddd %xmm8, %xmm0
pshufd $0xf9, %xmm10, %xmm8    # xmm8 = xmm10[1,2,3,3]
movq 0x20(%rsp), %rax
pinsrd $0x3, 0xc(%rax,%r8,4), %xmm8
pshufd $0xf9, %xmm15, %xmm15   # xmm15 = xmm15[1,2,3,3]
pinsrd $0x3, 0xc(%rbx,%r8,4), %xmm15
movdqa %xmm8, %xmm1
movdqa 0x120(%rsp), %xmm2
psubd %xmm2, %xmm1
movdqa 0x110(%rsp), %xmm4
psubd %xmm4, %xmm15
pmaxsd %xmm1, %xmm15
psubd %xmm2, %xmm10
psubd %xmm4, %xmm11
pmaxsd %xmm10, %xmm11
movdqa %xmm11, %xmm2
pmaxsd %xmm15, %xmm2
pmaxsd 0x1d6460(%rip), %xmm2   # 0x629d60
pmaxsd %xmm0, %xmm2
movdqa %xmm3, %xmm0
pcmpeqd %xmm7, %xmm0
movdqa %xmm0, %xmm10
pandn %xmm2, %xmm10
movaps 0x40(%rsp), %xmm1
blendvps %xmm0, %xmm1, %xmm15
blendvps %xmm0, %xmm1, %xmm11
cmpq $0x4, %r8
jb 0x453952
movdqa 0x50(%rsp), %xmm0
pminsd %xmm10, %xmm0
movdqa %xmm0, 0x50(%rsp)
movdqa 0x60(%rsp), %xmm0
pmaxsd %xmm10, %xmm0
movdqa %xmm0, 0x60(%rsp)
movq 0x28(%rsp), %rax
movq 0x10(%rax), %rax
movq (%rax), %r11
movq 0x8(%rax), %r15
cmpq %r13, %r8
setae %al
orb %al, %r12b
jne 0x453975
pextrd $0x3, %xmm10, (%r11,%r8,4)
cmpq %r8, (%rsp)
jne 0x453983
pextrd $0x3, %xmm10, (%r15,%rdi,4)
cmpq %rcx, %r9
setne %al
leaq -0x1(%r8), %r12
cmpq %r13, %r12
setae %r12b
orb %al, %r12b
jne 0x4539a2
pextrd $0x2, %xmm10, -0x4(%r11,%r8,4)
cmpq %rsi, %r9
setae %al
cmpq %r8, %r13
setne %r12b
orb %al, %r12b
jne 0x4539bc
pextrd $0x2, %xmm10, (%r15,%r9,4)
cmpq %rcx, %rdx
jne 0x4539e3
leaq -0x2(%r8), %rax
cmpq $0x2, %r8
setae %r12b
cmpq %r13, %rax
setl %al
andb %r12b, %al
cmpb $0x1, %al
jne 0x4539e3
pextrd $0x1, %xmm10, -0x8(%r11,%r8,4)
cmpq %rsi, %rdx
setae %al
cmpq %r8, 0xc0(%rsp)
setne %r12b
orb %al, %r12b
jne 0x453a02
pextrd $0x1, %xmm10, (%r15,%rdx,4)
cmpq %rcx, %r10
setne %al
cmpq $0x3, %r8
setb %r12b
orb %al, %r12b
jne 0x453a1c
movd %xmm10, -0xc(%r11,%r8,4)
cmpq %rsi, %r10
setae %al
cmpq %r8, 0xb8(%rsp)
setne %r12b
movd %xmm10, %r11d
orb %al, %r12b
jne 0x453a3c
movl %r11d, (%r15,%r10,4)
movq 0x20(%rsp), %r15
movl %r11d, (%r15,%r8,4)
movdqa 0x100(%rsp), %xmm0
pcmpgtd %xmm3, %xmm0
pand %xmm13, %xmm0
movdqa %xmm3, %xmm14
psrad $0x1f, %xmm14
pandn %xmm0, %xmm14
movdqa %xmm10, %xmm7
pcmpeqd %xmm12, %xmm7
movdqa %xmm10, %xmm4
pcmpgtd %xmm12, %xmm4
movdqa %xmm4, %xmm1
pand %xmm14, %xmm1
movdqa %xmm1, %xmm0
blendvps %xmm0, %xmm2, %xmm12
movdqa %xmm9, %xmm2
pcmpgtd %xmm3, %xmm2
pand %xmm7, %xmm2
movdqa %xmm2, %xmm0
blendvps %xmm0, %xmm14, %xmm1
movaps %xmm1, %xmm0
blendvps %xmm0, %xmm6, %xmm5
por %xmm4, %xmm2
pand %xmm14, %xmm2
movdqa %xmm2, %xmm0
blendvps %xmm0, %xmm3, %xmm9
movq 0x18(%rsp), %rbx
movss %xmm15, (%rbx,%r8,4)
pcmpeqd %xmm7, %xmm7
psubd %xmm7, %xmm3
incq %r8
cmpq %r8, 0xc8(%rsp)
jne 0x453847
paddd 0x1d6004(%rip), %xmm6   # 0x629af0
addq $0x4, %rdi
cmpq %rsi, %rdi
movq 0x170(%rsp), %r12
jb 0x453768
movdqa %xmm12, 0xd0(%rsp)
movdqa %xmm9, 0xa0(%rsp)
movl 0x14(%rsp), %r8d
movq 0x18(%rsp), %rdi
movdqa 0x60(%rsp), %xmm1
movdqa 0x50(%rsp), %xmm2
jmp 0x453b44
movdqa 0x40(%rsp), %xmm0
movdqa %xmm0, %xmm5
movdqa %xmm0, %xmm1
movdqa 0x90(%rsp), %xmm2
movdqa %xmm5, 0x80(%rsp)
xorl %edx, %edx
xorl %eax, %eax
xorl %ecx, %ecx
movq 0x28(%rsp), %rbx
movl 0xd0(%rsp,%rdx,4), %esi
cmpl %r8d, %esi
jle 0x453b77
movl 0x80(%rsp,%rdx,4), %eax
movl 0xa0(%rsp,%rdx,4), %ecx
movl %esi, %r8d
jmp 0x453b9d
jne 0x453b9d
movl 0xa0(%rsp,%rdx,4), %esi
cmpl %ecx, %esi
jge 0x453b8f
movl 0x80(%rsp,%rdx,4), %eax
movl %esi, %ecx
jmp 0x453b9d
jne 0x453b9d
movl 0x80(%rsp,%rdx,4), %esi
cmpl %eax, %esi
cmovll %esi, %eax
incq %rdx
cmpl $0x4, %edx
jne 0x453b58
movdqa 0x40(%rsp), %xmm0
pcmpgtd %xmm2, %xmm0
pcmpgtd 0x90(%rsp), %xmm1
por %xmm0, %xmm1
movmskps %xmm1, %edx
testl %edx, %edx
je 0x453bce
orb $0x40, 0xc(%rbx)
xorl %r8d, %r8d
xorl %ecx, %ecx
xorl %eax, %eax
movl %r8d, (%rbx)
movl %eax, 0x4(%rbx)
movl %ecx, 0x8(%rbx)
callq 0x20a60d
movq %r15, %rdi
callq 0x20a60d
movq %r14, %rdi
callq 0x20a60d
cmpl $0x0, 0x30(%r12)
jne 0x453c31
movq 0x78(%rsp), %rdi
callq 0x20a60d
jmp 0x453c31
callq 0x1d325b
jmp 0x453c2f
callq 0x1d3235
jmp 0x453c2f
callq 0x1d320f
jmp 0x453c2f
callq 0x1d31e9
jmp 0x453c2f
callq 0x1d31c3
jmp 0x453c2f
callq 0x1d319d
jmp 0x453c2f
callq 0x1d3177
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x138, %rsp            # imm = 0x138
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop