// File: /workspace/github_c_makefile_star2_O2/nh13[P]ksw/src/parasail/src/sw_trace_striped_avx2_256_32.c
// Function: parasail_sw_trace_striped_profile_avx2_256_32
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;
    __m256i* restrict vProfile = NULL;
    __m256i* restrict pvHStore = NULL;
    __m256i* restrict pvHLoad = NULL;
    __m256i* restrict pvE = NULL;
    __m256i* restrict pvEaStore = NULL;
    __m256i* restrict pvEaLoad = NULL;
    __m256i* restrict pvHT = NULL;
    __m256i* restrict pvHMax = NULL;
    __m256i vGapO;
    __m256i vGapE;
    __m256i vZero;
    int32_t score = 0;
    __m256i vMaxH;
    __m256i vMaxHUnit;
    int32_t maxp = 0;
    parasail_result_t *result = NULL;
    __m256i vTZero;
    __m256i vTIns;
    __m256i vTDel;
    __m256i vTDiag;
    __m256i vTDiagE;
    __m256i vTInsE;
    __m256i vTDiagF;
    __m256i vTDelF;
    __m256i vTMask;
    __m256i vFTMask;

    /* validate inputs */
    PARASAIL_CHECK_NULL(profile);
    PARASAIL_CHECK_NULL(profile->profile32.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 = 8; /* number of values in vector unit */
    segLen = (s1Len + segWidth - 1) / segWidth;
    vProfile = (__m256i*)profile->profile32.score;
    vGapO = _mm256_set1_epi32(open);
    vGapE = _mm256_set1_epi32(gap);
    vZero = _mm256_setzero_si256();
    score = NEG_INF;
    vMaxH = vZero;
    vMaxHUnit = vZero;
    maxp = INT32_MAX - (int32_t)(matrix->max+1);
    vTZero = _mm256_set1_epi32(PARASAIL_ZERO);
    vTIns  = _mm256_set1_epi32(PARASAIL_INS);
    vTDel  = _mm256_set1_epi32(PARASAIL_DEL);
    vTDiag = _mm256_set1_epi32(PARASAIL_DIAG);
    vTDiagE= _mm256_set1_epi32(PARASAIL_DIAG_E);
    vTInsE = _mm256_set1_epi32(PARASAIL_INS_E);
    vTDiagF= _mm256_set1_epi32(PARASAIL_DIAG_F);
    vTDelF = _mm256_set1_epi32(PARASAIL_DEL_F);
    vTMask = _mm256_set1_epi32(PARASAIL_ZERO_MASK);
    vFTMask= _mm256_set1_epi32(PARASAIL_F_MASK);

    /* initialize result */
    result = parasail_result_new_trace(segLen, s2Len, 32, sizeof(__m256i));
    if (!result) return NULL;

    /* set known flags */
    result->flag |= PARASAIL_FLAG_SW | PARASAIL_FLAG_STRIPED
        | PARASAIL_FLAG_TRACE
        | PARASAIL_FLAG_BITS_32 | PARASAIL_FLAG_LANES_8;

    /* initialize heap variables */
    pvHStore = parasail_memalign___m256i(32, segLen);
    pvHLoad =  parasail_memalign___m256i(32, segLen);
    pvE = parasail_memalign___m256i(32, segLen);
    pvEaStore = parasail_memalign___m256i(32, segLen);
    pvEaLoad = parasail_memalign___m256i(32, segLen);
    pvHT = parasail_memalign___m256i(32, segLen);
    pvHMax = parasail_memalign___m256i(32, segLen);

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

    /* initialize H and E */
    parasail_memset___m256i(pvHStore, vZero, segLen);
    parasail_memset___m256i(pvE, _mm256_set1_epi32(-open), segLen);
    parasail_memset___m256i(pvEaStore, _mm256_set1_epi32(-open), segLen);

    for (i=0; i<segLen; ++i) {
        arr_store(result->trace->trace_table, vTDiagE, i, segLen, 0);
    }

    /* outer loop over database sequence */
    for (j=0; j<s2Len; ++j) {
        __m256i vEF_opn;
        __m256i vE;
        __m256i vE_ext;
        __m256i vF;
        __m256i vF_ext;
        __m256i vFa;
        __m256i vFa_ext;
        __m256i vH;
        __m256i vH_dag;
        const __m256i* vP = NULL;

        /* Initialize F value to 0.  Any errors to vH values will be
         * corrected in the Lazy_F loop. */
        vF = _mm256_sub_epi32(vZero,vGapO);

        /* load final segment of pvHStore and shift left by 4 bytes */
        vH = _mm256_load_si256(&pvHStore[segLen - 1]);
        vH = _mm256_slli_si256_rpl(vH, 4);

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

        if (end_ref == j-2) {
            /* Swap in the max buffer. */
            SWAP3(pvHMax,  pvHLoad,  pvHStore)
            SWAP(pvEaLoad,  pvEaStore)
        }
        else {
            /* Swap the 2 H buffers. */
            SWAP(pvHLoad,  pvHStore)
            SWAP(pvEaLoad,  pvEaStore)
        }

        /* inner loop to process the query sequence */
        for (i=0; i<segLen; ++i) {
            vE = _mm256_load_si256(pvE + i);

            /* Get max from vH, vE and vF. */
            vH_dag = _mm256_add_epi32(vH, _mm256_load_si256(vP + i));
            vH_dag = _mm256_max_epi32(vH_dag, vZero);
            vH = _mm256_max_epi32(vH_dag, vE);
            vH = _mm256_max_epi32(vH, vF);
            /* Save vH values. */
            _mm256_store_si256(pvHStore + i, vH);

            {
                __m256i vTAll = arr_load(result->trace->trace_table, i, segLen, j);
                __m256i cond_zero = _mm256_cmpeq_epi32(vH, vZero);
                __m256i case1 = _mm256_cmpeq_epi32(vH, vH_dag);
                __m256i case2 = _mm256_cmpeq_epi32(vH, vF);
                __m256i vT = _mm256_blendv_epi8(
                        _mm256_blendv_epi8(vTIns, vTDel, case2),
                        _mm256_blendv_epi8(vTDiag, vTZero, cond_zero),
                        case1);
                _mm256_store_si256(pvHT + i, vT);
                vT = _mm256_or_si256(vT, vTAll);
                arr_store(result->trace->trace_table, vT, i, segLen, j);
            }
            vMaxH = _mm256_max_epi32(vH, vMaxH);
            vEF_opn = _mm256_sub_epi32(vH, vGapO);

            /* Update vE value. */
            vE_ext = _mm256_sub_epi32(vE, vGapE);
            vE = _mm256_max_epi32(vEF_opn, vE_ext);
            _mm256_store_si256(pvE + i, vE);
            {
                __m256i vEa = _mm256_load_si256(pvEaLoad + i);
                __m256i vEa_ext = _mm256_sub_epi32(vEa, vGapE);
                vEa = _mm256_max_epi32(vEF_opn, vEa_ext);
                _mm256_store_si256(pvEaStore + i, vEa);
                if (j+1<s2Len) {
                    __m256i cond = _mm256_cmpgt_epi32(vEF_opn, vEa_ext);
                    __m256i vT = _mm256_blendv_epi8(vTInsE, vTDiagE, cond);
                    arr_store(result->trace->trace_table, vT, i, segLen, j+1);
                }
            }

            /* Update vF value. */
            vF_ext = _mm256_sub_epi32(vF, vGapE);
            vF = _mm256_max_epi32(vEF_opn, vF_ext);
            if (i+1<segLen) {
                __m256i vTAll = arr_load(result->trace->trace_table, i+1, segLen, j);
                __m256i cond = _mm256_cmpgt_epi32(vEF_opn, vF_ext);
                __m256i vT = _mm256_blendv_epi8(vTDelF, vTDiagF, cond);
                vT = _mm256_or_si256(vT, vTAll);
                arr_store(result->trace->trace_table, vT, i+1, segLen, j);
            }

            /* Load the next vH. */
            vH = _mm256_load_si256(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 */
        vFa_ext = vF_ext;
        vFa = vF;
        for (k=0; k<segWidth; ++k) {
            __m256i vHp = _mm256_load_si256(&pvHLoad[segLen - 1]);
            vHp = _mm256_slli_si256_rpl(vHp, 4);
            vEF_opn = _mm256_slli_si256_rpl(vEF_opn, 4);
            vEF_opn = _mm256_insert_epi32_rpl(vEF_opn, -open, 0);
            vF_ext = _mm256_slli_si256_rpl(vF_ext, 4);
            vF_ext = _mm256_insert_epi32_rpl(vF_ext, NEG_INF, 0);
            vF = _mm256_slli_si256_rpl(vF, 4);
            vF = _mm256_insert_epi32_rpl(vF, -open, 0);
            vFa_ext = _mm256_slli_si256_rpl(vFa_ext, 4);
            vFa_ext = _mm256_insert_epi32_rpl(vFa_ext, NEG_INF, 0);
            vFa = _mm256_slli_si256_rpl(vFa, 4);
            vFa = _mm256_insert_epi32_rpl(vFa, -open, 0);
            for (i=0; i<segLen; ++i) {
                vH = _mm256_load_si256(pvHStore + i);
                vH = _mm256_max_epi32(vH,vF);
                _mm256_store_si256(pvHStore + i, vH);
                {
                    __m256i vTAll;
                    __m256i vT;
                    __m256i case1;
                    __m256i case2;
                    __m256i cond;
                    vHp = _mm256_add_epi32(vHp, _mm256_load_si256(vP + i));
                    vHp = _mm256_max_epi32(vHp, vZero);
                    case1 = _mm256_cmpeq_epi32(vH, vHp);
                    case2 = _mm256_cmpeq_epi32(vH, vF);
                    cond = _mm256_andnot_si256(case1,case2);
                    vTAll = arr_load(result->trace->trace_table, i, segLen, j);
                    vT = _mm256_load_si256(pvHT + i);
                    vT = _mm256_blendv_epi8(vT, vTDel, cond);
                    _mm256_store_si256(pvHT + i, vT);
                    vTAll = _mm256_and_si256(vTAll, vTMask);
                    vTAll = _mm256_or_si256(vTAll, vT);
                    arr_store(result->trace->trace_table, vTAll, i, segLen, j);
                }
                vMaxH = _mm256_max_epi32(vH, vMaxH);
                /* Update vF value. */
                {
                    __m256i vTAll = arr_load(result->trace->trace_table, i, segLen, j);
                    __m256i cond = _mm256_cmpgt_epi32(vEF_opn, vFa_ext);
                    __m256i vT = _mm256_blendv_epi8(vTDelF, vTDiagF, cond);
                    vTAll = _mm256_and_si256(vTAll, vFTMask);
                    vTAll = _mm256_or_si256(vTAll, vT);
                    arr_store(result->trace->trace_table, vTAll, i, segLen, j);
                }
                vEF_opn = _mm256_sub_epi32(vH, vGapO);
                vF_ext = _mm256_sub_epi32(vF, vGapE);
                {
                    __m256i vEa = _mm256_load_si256(pvEaLoad + i);
                    __m256i vEa_ext = _mm256_sub_epi32(vEa, vGapE);
                    vEa = _mm256_max_epi32(vEF_opn, vEa_ext);
                    _mm256_store_si256(pvEaStore + i, vEa);
                    if (j+1<s2Len) {
                        __m256i cond = _mm256_cmpgt_epi32(vEF_opn, vEa_ext);
                        __m256i vT = _mm256_blendv_epi8(vTInsE, vTDiagE, cond);
                        arr_store(result->trace->trace_table, vT, i, segLen, j+1);
                    }
                }
                if (! _mm256_movemask_epi8(
                            _mm256_or_si256(
                                _mm256_cmpgt_epi32(vF_ext, vEF_opn),
                                _mm256_cmpeq_epi32(vF_ext, vEF_opn))))
                    goto end;
                /*vF = _mm256_max_epi32(vEF_opn, vF_ext);*/
                vF = vF_ext;
                vFa_ext = _mm256_sub_epi32(vFa, vGapE);
                vFa = _mm256_max_epi32(vEF_opn, vFa_ext);
                vHp = _mm256_load_si256(pvHLoad + i);
            }
        }
end:
        {
        }

        {
            __m256i vCompare = _mm256_cmpgt_epi32(vMaxH, vMaxHUnit);
            if (_mm256_movemask_epi8(vCompare)) {
                score = _mm256_hmax_epi32_rpl(vMaxH);
                /* if score has potential to overflow, abort early */
                if (score > maxp) {
                    result->flag |= PARASAIL_FLAG_SATURATED;
                    break;
                }
                vMaxHUnit = _mm256_set1_epi32(score);
                end_ref = j;
            }
        }

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

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

    if (parasail_result_is_saturated(result)) {
        score = 0;
        end_query = 0;
        end_ref = 0;
    }
    else {
        if (end_ref == j-1) {
            /* end_ref was the last store column */
            SWAP(pvHMax,  pvHStore)
        }
        else if (end_ref == j-2) {
            /* end_ref was the last load column */
            SWAP(pvHMax,  pvHLoad)
        }
        /* Trace the alignment ending position on read. */
        {
            int32_t *t = (int32_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;
    result->end_query = end_query;
    result->end_ref = end_ref;

    parasail_free(pvHMax);
    parasail_free(pvHT);
    parasail_free(pvEaLoad);
    parasail_free(pvEaStore);
    parasail_free(pvE);
    parasail_free(pvHLoad);
    parasail_free(pvHStore);

    return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp            # imm = 0x118
movq %rdx, 0x28(%rsp)
movq %rsi, 0x88(%rsp)
testq %rdi, %rdi
je 0x5625b3
movq 0x48(%rdi), %rax
movq %rax, 0xa8(%rsp)
testq %rax, %rax
je 0x5625d7
movq 0x10(%rdi), %rax
movq %rax, 0x80(%rsp)
testq %rax, %rax
je 0x5625fb
movl 0x8(%rdi), %r14d
testl %r14d, %r14d
jle 0x56261f
cmpq $0x0, 0x88(%rsp)
je 0x562643
cmpl $0x0, 0x28(%rsp)
jle 0x562664
movl %ecx, %r12d
testl %ecx, %ecx
js 0x562685
movl %r8d, %r13d
testl %r8d, %r8d
js 0x5626a6
leaq 0x7(%r14), %r15
shrq $0x3, %r15
movl $0x7ffffffe, %ebp       # imm = 0x7FFFFFFE
movq 0x80(%rsp), %rax
subl 0x1c(%rax), %ebp
pushq $0x20
popq %rcx
movl %r15d, %edi
movq 0x28(%rsp), %rsi
movq %rcx, %rdx
callq 0x1abb59
testq %rax, %rax
je 0x5626cc
movq %rax, %rbx
movl %r13d, 0x40(%rsp)
movl %r12d, 0x50(%rsp)
movl %ebp, 0x4c(%rsp)
movq %r14, 0x90(%rsp)
orl $0x8480804, 0xc(%rax)   # imm = 0x8480804
pushq $0x20
popq %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x496aa4
movq %rax, %r13
movq %r12, %rdi
movq %r15, %rsi
callq 0x496aa4
movq %rax, %r14
movq %r12, %rdi
movq %r15, %rsi
callq 0x496aa4
movq %rax, 0x30(%rsp)
movq %r12, %rdi
movq %r15, %rsi
callq 0x496aa4
movq %rax, %rbp
movq %r12, %rdi
movq %r15, %rsi
callq 0x496aa4
movq %r15, 0x10(%rsp)
movq %rax, %r12
pushq $0x20
popq %rdi
movq %r15, %rsi
callq 0x496aa4
movq %rax, %r15
pushq $0x20
popq %rdi
movq 0x10(%rsp), %rsi
callq 0x496aa4
movq %rax, 0x20(%rsp)
xorl %eax, %eax
testq %r13, %r13
je 0x5626ce
testq %r14, %r14
je 0x5626ce
cmpq $0x0, 0x30(%rsp)
je 0x5626ce
testq %rbp, %rbp
je 0x5626ce
testq %r12, %r12
je 0x5626ce
testq %r15, %r15
je 0x5626ce
cmpq $0x0, 0x20(%rsp)
je 0x5626ce
vmovss 0x50(%rsp), %xmm0
vbroadcastss %xmm0, %ymm0
vmovups %ymm0, 0xf0(%rsp)
vmovss 0x40(%rsp), %xmm0
vbroadcastss %xmm0, %ymm0
vmovups %ymm0, 0xd0(%rsp)
vxorps %xmm0, %xmm0, %xmm0
movq %r13, %rdi
movq 0x10(%rsp), %rsi
callq 0x496aad
movl 0x50(%rsp), %eax
negl %eax
vmovd %eax, %xmm0
vmovdqu %ymm0, 0xb0(%rsp)
vpbroadcastd %xmm0, %ymm0
vmovdqu %ymm0, 0x50(%rsp)
movq 0x30(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x496aad
movq %rbp, %rdi
vmovups 0x50(%rsp), %ymm0
movq 0x10(%rsp), %rsi
callq 0x496aad
movq 0x10(%rsp), %rdi
shlq $0x5, %rdi
xorl %eax, %eax
vpbroadcastq 0x6ba19(%rip), %ymm0 # 0x5cda00
cmpq %rax, %rdi
je 0x561ffe
movq 0x10(%rbx), %rcx
movq (%rcx), %rcx
vmovdqa %ymm0, (%rcx,%rax)
addq $0x20, %rax
jmp 0x561fe7
vpxor %xmm0, %xmm0, %xmm0
vmovdqu 0xf0(%rsp), %ymm13
vpsubd %ymm13, %ymm0, %ymm1
movq 0x10(%rsp), %rax
decl %eax
movl 0x28(%rsp), %ecx
movq %rcx, 0xa0(%rsp)
xorl %r8d, %r8d
shlq $0x5, %rax
movq %rax, 0x98(%rsp)
vpmovsxbd 0x6a34d(%rip), %ymm2 # 0x5cc388
vpcmpeqd %ymm3, %ymm3, %ymm3
vpxor %xmm5, %xmm5, %xmm5
vpxor %xmm4, %xmm4, %xmm4
movl $0xc0000000, 0x1c(%rsp) # imm = 0xC0000000
movl $0x0, 0xc(%rsp)
vmovdqu 0xd0(%rsp), %ymm14
vmovdqu 0xb0(%rsp), %ymm15
leaq 0x1(%r8), %rax
imulq %rdi, %rax
movq %rax, 0x50(%rsp)
movq %rdi, %rax
imulq %r8, %rax
movq %r12, %rcx
movq %r14, %r9
movq %r13, %r14
movq %rbp, %r12
movq %rcx, %rbp
cmpq 0xa0(%rsp), %r8
je 0x56249f
movq 0x98(%rsp), %rcx
leaq (%r14,%rcx), %rdx
movq %rdx, 0x40(%rsp)
vmovdqa (%r14,%rcx), %ymm8
vperm2i128 $0x28, %ymm8, %ymm8, %ymm9 # ymm9 = zero,zero,ymm8[0,1]
vpalignr $0xc, %ymm9, %ymm8, %ymm9 # ymm9 = ymm9[12,13,14,15],ymm8[0,1,2,3,4,5,6,7,8,9,10,11],ymm9[28,29,30,31],ymm8[16,17,18,19,20,21,22,23,24,25,26,27]
movq 0x80(%rsp), %rcx
movq 0x10(%rcx), %rcx
movq 0x88(%rsp), %rdx
movzbl (%rdx,%r8), %edx
movl (%rcx,%rdx,4), %ecx
imull 0x10(%rsp), %ecx
movslq %ecx, %rsi
shlq $0x5, %rsi
addq 0xa8(%rsp), %rsi
leal -0x2(%r8), %edx
cmpl %edx, 0xc(%rsp)
movq %r9, 0x38(%rsp)
movq %r9, %r13
cmoveq 0x20(%rsp), %r13
movq %r8, 0x78(%rsp)
incq %r8
pushq $0x1
popq %rcx
xorl %r10d, %r10d
vmovdqa %ymm1, %ymm8
cmpq %r10, %rdi
je 0x562257
vpaddd (%rsi,%r10), %ymm9, %ymm6
movq 0x30(%rsp), %r9
vmovdqa (%r9,%r10), %ymm7
vpmaxsd %ymm0, %ymm6, %ymm6
vpmaxsd %ymm7, %ymm6, %ymm10
vpmaxsd %ymm8, %ymm10, %ymm9
vmovdqa %ymm9, (%r13,%r10)
movq 0x10(%rbx), %r11
movq (%r11), %r11
addq %rax, %r11
vpcmpeqd %ymm6, %ymm9, %ymm6
vpcmpgtd %ymm8, %ymm10, %ymm10
vpbroadcastd 0x6b5f7(%rip), %ymm11 # 0x5cd758
vpaddd %ymm11, %ymm10, %ymm10
vpcmpgtd %ymm0, %ymm9, %ymm11
vpbroadcastd 0x6b5e9(%rip), %ymm12 # 0x5cd75c
vpand %ymm12, %ymm11, %ymm11
vblendvps %ymm6, %ymm11, %ymm10, %ymm6
vorps (%r10,%r11), %ymm6, %ymm10
vmovaps %ymm6, (%r15,%r10)
movq 0x10(%rbx), %r11
movq (%r11), %r11
addq %rax, %r11
vmovaps %ymm10, (%r10,%r11)
vpsubd %ymm13, %ymm9, %ymm6
vpsubd %ymm14, %ymm7, %ymm7
vpmaxsd %ymm7, %ymm6, %ymm7
vmovdqa %ymm7, (%r9,%r10)
vmovdqa (%r12,%r10), %ymm7
vpsubd %ymm14, %ymm7, %ymm7
vpmaxsd %ymm7, %ymm6, %ymm10
vmovdqa %ymm10, (%rbp,%r10)
cmpl 0x28(%rsp), %r8d
jge 0x5621fb
vpcmpgtd %ymm7, %ymm6, %ymm7
vbroadcastss 0x69906(%rip), %ymm10 # 0x5cbae0
vbroadcastss 0x6b569(%rip), %ymm11 # 0x5cd74c
vblendvps %ymm7, %ymm10, %ymm11, %ymm7
movq 0x10(%rbx), %r11
movq (%r11), %r11
addq 0x50(%rsp), %r11
vmovaps %ymm7, (%r10,%r11)
vpsubd %ymm14, %ymm8, %ymm7
cmpq 0x10(%rsp), %rcx
jae 0x56223b
movq 0x10(%rbx), %r11
movq (%r11), %r11
addq %rax, %r11
vpcmpgtd %ymm7, %ymm6, %ymm8
vbroadcastss 0x6b532(%rip), %ymm10 # 0x5cd750
vbroadcastss 0x6b52d(%rip), %ymm11 # 0x5cd754
vblendvps %ymm8, %ymm10, %ymm11, %ymm8
vorps 0x20(%r10,%r11), %ymm8, %ymm8
vmovaps %ymm8, 0x20(%r10,%r11)
vpmaxsd %ymm4, %ymm9, %ymm4
vpmaxsd %ymm7, %ymm6, %ymm8
vmovdqa (%r14,%r10), %ymm9
addq $0x20, %r10
incq %rcx
jmp 0x562115
cmpl %edx, 0xc(%rsp)
movq 0x20(%rsp), %rcx
cmoveq 0x38(%rsp), %rcx
movq %rcx, 0x20(%rsp)
xorl %ecx, %ecx
vmovdqa %ymm7, %ymm10
vmovdqa %ymm8, %ymm9
cmpl $0x8, %ecx
je 0x562429
movl %ecx, 0x38(%rsp)
movq 0x40(%rsp), %rcx
vmovdqa (%rcx), %ymm11
vperm2i128 $0x28, %ymm11, %ymm11, %ymm12 # ymm12 = zero,zero,ymm11[0,1]
vpalignr $0xc, %ymm12, %ymm11, %ymm11 # ymm11 = ymm12[12,13,14,15],ymm11[0,1,2,3,4,5,6,7,8,9,10,11],ymm12[28,29,30,31],ymm11[16,17,18,19,20,21,22,23,24,25,26,27]
vpermd %ymm6, %ymm2, %ymm6
vpblendd $0x1, %ymm15, %ymm6, %ymm6 # ymm6 = ymm15[0],ymm6[1,2,3,4,5,6,7]
vpermd %ymm10, %ymm2, %ymm10
movl $0xc0000000, %ecx       # imm = 0xC0000000
vmovd %ecx, %xmm12
vpblendd $0x1, %ymm12, %ymm10, %ymm10 # ymm10 = ymm12[0],ymm10[1,2,3,4,5,6,7]
vpermd %ymm9, %ymm2, %ymm9
vpblendd $0x1, %ymm15, %ymm9, %ymm9 # ymm9 = ymm15[0],ymm9[1,2,3,4,5,6,7]
vpermd %ymm7, %ymm2, %ymm7
vpblendd $0x1, %ymm12, %ymm7, %ymm7 # ymm7 = ymm12[0],ymm7[1,2,3,4,5,6,7]
vpermd %ymm8, %ymm2, %ymm8
vpblendd $0x1, %ymm15, %ymm8, %ymm8 # ymm8 = ymm15[0],ymm8[1,2,3,4,5,6,7]
xorl %ecx, %ecx
movq %rax, %r11
movq 0x50(%rsp), %r10
movq 0x10(%rsp), %rdx
subq $0x1, %rdx
jb 0x56241e
vmovdqa (%r13,%rcx), %ymm12
vpmaxsd %ymm9, %ymm12, %ymm10
vmovdqa %ymm10, (%r13,%rcx)
vpaddd (%rsi,%rcx), %ymm11, %ymm11
vpmaxsd %ymm0, %ymm11, %ymm11
vpcmpeqd %ymm11, %ymm10, %ymm11
vpcmpgtd %ymm9, %ymm12, %ymm12
vpor %ymm12, %ymm11, %ymm11
movq 0x10(%rbx), %r9
movq (%r9), %r9
vbroadcastss 0x6b42b(%rip), %ymm12 # 0x5cd758
vblendvps %ymm11, (%r15,%rcx), %ymm12, %ymm11
vbroadcastsd 0x6b6cb(%rip), %ymm12 # 0x5cda08
vandps (%r9,%r11), %ymm12, %ymm12
vmovaps %ymm11, (%r15,%rcx)
vorps %ymm11, %ymm12, %ymm11
movq 0x10(%rbx), %r9
movq (%r9), %r9
vmovaps %ymm11, (%r9,%r11)
movq 0x10(%rbx), %r9
vpcmpgtd %ymm7, %ymm6, %ymm6
vbroadcastss 0x6b3e4(%rip), %ymm7 # 0x5cd750
vbroadcastss 0x6b3df(%rip), %ymm11 # 0x5cd754
vblendvps %ymm6, %ymm7, %ymm11, %ymm6
movq (%r9), %r9
vbroadcastsd 0x6b689(%rip), %ymm7 # 0x5cda10
vandps (%r9,%r11), %ymm7, %ymm7
vorps %ymm6, %ymm7, %ymm6
vmovaps %ymm6, (%r9,%r11)
vpsubd %ymm13, %ymm10, %ymm6
vmovdqa (%r12,%rcx), %ymm7
vpsubd %ymm14, %ymm7, %ymm7
vpmaxsd %ymm7, %ymm6, %ymm11
vmovdqa %ymm11, (%rbp,%rcx)
cmpl 0x28(%rsp), %r8d
jge 0x5623e2
vpcmpgtd %ymm7, %ymm6, %ymm7
vbroadcastss 0x6971a(%rip), %ymm11 # 0x5cbae0
vbroadcastss 0x6b37d(%rip), %ymm12 # 0x5cd74c
vblendvps %ymm7, %ymm11, %ymm12, %ymm7
movq 0x10(%rbx), %r9
movq (%r9), %r9
vmovaps %ymm7, (%r9,%r10)
vpmaxsd %ymm4, %ymm10, %ymm4
vpsubd %ymm14, %ymm9, %ymm10
vpcmpgtd %ymm10, %ymm6, %ymm7
vtestps %ymm3, %ymm7
jb 0x562429
vpsubd %ymm14, %ymm8, %ymm7
vpmaxsd %ymm7, %ymm6, %ymm8
vmovdqa (%r14,%rcx), %ymm11
addq $0x20, %r10
addq $0x20, %r11
addq $0x20, %rcx
vmovdqa %ymm10, %ymm9
jmp 0x5622e7
movl 0x38(%rsp), %ecx
incl %ecx
jmp 0x562276
vmovdqa %ymm10, %ymm7
vpcmpgtd %ymm5, %ymm4, %ymm8
addq %rdi, 0x50(%rsp)
addq %rdi, %rax
vtestps %ymm8, %ymm8
movq %r12, %rcx
movq %r14, %r9
je 0x562083
vpermq $0x44, %ymm4, %ymm5     # ymm5 = ymm4[0,1,0,1]
vpmaxsd %ymm5, %ymm4, %ymm5
vpslldq $0x8, %ymm5, %ymm8      # ymm8 = zero,zero,zero,zero,zero,zero,zero,zero,ymm5[0,1,2,3,4,5,6,7],zero,zero,zero,zero,zero,zero,zero,zero,ymm5[16,17,18,19,20,21,22,23]
vpmaxsd %ymm8, %ymm5, %ymm5
vpslldq $0x4, %ymm5, %ymm8      # ymm8 = zero,zero,zero,zero,ymm5[0,1,2,3,4,5,6,7,8,9,10,11],zero,zero,zero,zero,ymm5[16,17,18,19,20,21,22,23,24,25,26,27]
vpmaxsd %ymm8, %ymm5, %ymm5
vextracti128 $0x1, %ymm5, %xmm8
vpextrd $0x3, %xmm8, %eax
movl %eax, 0x1c(%rsp)
cmpl 0x4c(%rsp), %eax
jg 0x5626e0
vpbroadcastd 0x69484(%rip), %ymm8 # 0x5cb910
vpermd %ymm5, %ymm8, %ymm5
movq 0x78(%rsp), %rax
movl %eax, 0xc(%rsp)
jmp 0x562069
movq %rbp, 0x50(%rsp)
movq %r12, %rbp
movq %r14, %r13
movq %r9, %r14
cmpl $0x7fffffff, 0x1c(%rsp) # imm = 0x7FFFFFFF
movq 0x10(%rsp), %r12
jne 0x5624c0
orb $0x40, 0xc(%rbx)
movq %rbx, %rdi
vzeroupper
callq 0x1ace42
xorl %ecx, %ecx
testl %eax, %eax
je 0x5624e0
xorl %r8d, %r8d
movq 0x20(%rsp), %rdi
xorl %eax, %eax
jmp 0x562569
movq 0x28(%rsp), %rcx
leal -0x1(%rcx), %eax
addl $-0x2, %ecx
movl 0xc(%rsp), %edx
cmpl %ecx, %edx
movq 0x20(%rsp), %rcx
movq %rcx, %rdi
movq %r14, %rsi
cmoveq %r14, %rdi
cmoveq %rcx, %r14
cmpl %eax, %edx
cmoveq %r13, %rdi
cmoveq %rsi, %r14
movq 0x90(%rsp), %rcx
decl %ecx
movl %r12d, %edx
andl $0xfffffff, %edx        # imm = 0xFFFFFFF
shll $0x3, %edx
xorl %esi, %esi
movl 0x1c(%rsp), %r8d
cmpl %esi, %edx
je 0x56255b
cmpl %r8d, (%rdi,%rsi,4)
jne 0x562556
movl %esi, %r8d
shrl $0x3, %r8d
movl %esi, %r9d
andl $0x7, %r9d
imull %r12d, %r9d
addl %r8d, %r9d
movl 0x1c(%rsp), %r8d
cmpl %ecx, %r9d
cmovll %r9d, %ecx
incq %rsi
jmp 0x56252b
movl 0xc(%rsp), %edx
cmpl %eax, %edx
movl %edx, %eax
cmoveq 0x20(%rsp), %r13
movl %r8d, (%rbx)
movl %ecx, 0x4(%rbx)
movl %eax, 0x8(%rbx)
callq 0x1ab763
movq %r15, %rdi
callq 0x1ab763
movq 0x50(%rsp), %rdi
callq 0x1ab763
movq %rbp, %rdi
callq 0x1ab763
movq 0x30(%rsp), %rdi
callq 0x1ab763
movq %r14, %rdi
callq 0x1ab763
movq %r13, %rdi
callq 0x1ab763
movq %rbx, %rax
jmp 0x5626ce
movq 0x1d8a1e(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x64a27(%rip), %rsi     # 0x5c6feb
leaq 0x5fda2(%rip), %rdx     # 0x5c236d
leaq 0x3af0b(%rip), %rcx     # 0x59d4dd
jmp 0x5626c5
movq 0x1d89fa(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x64a03(%rip), %rsi     # 0x5c6feb
leaq 0x5fd7e(%rip), %rdx     # 0x5c236d
leaq 0x653b0(%rip), %rcx     # 0x5c79a6
jmp 0x5626c5
movq 0x1d89d6(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x649df(%rip), %rsi     # 0x5c6feb
leaq 0x5fd5a(%rip), %rdx     # 0x5c236d
leaq 0x6531f(%rip), %rcx     # 0x5c7939
jmp 0x5626c5
movq 0x1d89b2(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x650d1(%rip), %rsi     # 0x5c7701
leaq 0x5fd36(%rip), %rdx     # 0x5c236d
leaq 0x6530b(%rip), %rcx     # 0x5c7949
jmp 0x5626c5
movq 0x1d898e(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x64997(%rip), %rsi     # 0x5c6feb
leaq 0x5fd12(%rip), %rdx     # 0x5c236d
leaq 0x6509c(%rip), %rcx     # 0x5c76fe
jmp 0x5626c5
movq 0x1d896d(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x6508c(%rip), %rsi     # 0x5c7701
leaq 0x5fcf1(%rip), %rdx     # 0x5c236d
leaq 0x65092(%rip), %rcx     # 0x5c7715
jmp 0x5626c5
movq 0x1d894c(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x65085(%rip), %rsi     # 0x5c771b
leaq 0x5fcd0(%rip), %rdx     # 0x5c236d
leaq 0x6508c(%rip), %rcx     # 0x5c7730
jmp 0x5626c5
movq 0x1d892b(%rip), %rax    # 0x73afd8
movq (%rax), %rdi
leaq 0x65064(%rip), %rsi     # 0x5c771b
leaq 0x5fcaf(%rip), %rdx     # 0x5c236d
leaq 0x65070(%rip), %rcx     # 0x5c7735
xorl %eax, %eax
callq 0x19e180
xorl %eax, %eax
addq $0x118, %rsp            # imm = 0x118
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
orb $0x40, 0xc(%rbx)
movq 0x78(%rsp), %rax
movq %rax, 0x28(%rsp)
movq %r12, 0x50(%rsp)
movq %r14, %r9
jmp 0x5624aa
nop