LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/ecovlp.cpp
// Function: worker_hap_dc_ec_chemical_r(void*, long, int)
static void worker_hap_dc_ec_chemical_r(void *data, long i, int tid)
{
    ec_ovec_buf_t0 *b = &(((ec_ovec_buf_t*)data)->a[tid]);
    ma_hit_t_alloc *paf = &(R_INF.paf[i]); uint64_t k, m;

    // if (memcmp("3ed80bc4-1169-4948-a9ff-9c2463b7f7a2", Get_NAME((R_INF), i), Get_NAME_LENGTH((R_INF),i)) == 0) {
    //     fprintf(stderr, "-a-[M::%s-beg] rid->%ld, b->rr->%lu\n", __func__, i, b->rr);
    // } 
    if(b->cnt[1] == 0) {
        // if(i == 6204620) prt_dbg_rid_paf(&(R_INF.paf[i]), &(b->self_read), &(b->v8q));
        // if(is_chemical_r(&(R_INF.paf[i]), &b->v64, Get_READ_LENGTH((R_INF), i), 3, 16)) {
        if(is_chemical_r_adv(&(R_INF.paf[i]), &b->v64, Get_READ_LENGTH((R_INF), i), asm_opt.chemical_cov, asm_opt.chemical_flank, 0.02, 0)) {
            // fprintf(stderr, "-um-[M::%s]\tqn::%u::%.*s\n\n", __func__, (uint32_t)(i), (int)Get_NAME_LENGTH(R_INF, i), Get_NAME((R_INF), i));
            R_INF.paf[i].length = 0; b->cnt[0]++;
        } 
    } else if(b->cnt[1] == 1) {
        for (k = 0; k < paf->length; k++) {
            if(R_INF.paf[paf->buffer[k].tn].length == 0) {
                paf->buffer[k].tn = (uint32_t)-1; b->cnt[0]++;
            }
        }
    } else {
        for (k = m = 0; k < paf->length; k++) {
            if(paf->buffer[k].tn == ((uint32_t)-1)) continue;
            paf->buffer[m++] = paf->buffer[k];
        }
        paf->length = m;
    }

   refresh_ec_ovec_buf_t0(b, REFRESH_N);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq (%rdi), %rcx
movslq %edx, %rax
imulq $0x5c0, %rax, %rdx      # imm = 0x5C0
leaq (%rcx,%rdx), %rbx
leaq 0x100cad(%rip), %r14    # 0x296230
movq 0x78(%r14), %rax
leaq (%rsi,%rsi,2), %r15
leaq (%rax,%r15,8), %rdi
movq 0xc8(%rcx,%rdx), %rcx
testq %rcx, %rcx
je 0x1955eb
cmpq $0x1, %rcx
jne 0x19563c
movl 0xc(%rdi), %edx
testq %rdx, %rdx
je 0x195693
movq (%rdi), %rcx
shlq $0x3, %rdx
leaq (%rdx,%rdx,4), %rdx
xorl %esi, %esi
movl 0xc(%rcx,%rsi), %edi
leaq (%rdi,%rdi,2), %rdi
cmpl $0x0, 0xc(%rax,%rdi,8)
jne 0x1955dd
movl $0xffffffff, 0xc(%rcx,%rsi) # imm = 0xFFFFFFFF
incq 0xc0(%rbx)
addq $0x28, %rsi
cmpq %rsi, %rdx
jne 0x1955bf
jmp 0x195693
leaq 0x4d0(%rbx), %rax
movq 0x18(%r14), %rcx
movq (%rcx,%rsi,8), %rdx
leaq 0x100157(%rip), %rsi    # 0x295758
movq 0x2b8(%rsi), %rcx
movq 0x2c0(%rsi), %r8
movsd 0x98a01(%rip), %xmm0    # 0x22e018
movq %rax, %rsi
xorl %r9d, %r9d
callq 0x18a85d
testl %eax, %eax
je 0x195693
movq 0x78(%r14), %rax
movl $0x0, 0xc(%rax,%r15,8)
incq 0xc0(%rbx)
jmp 0x195693
movl 0xc(%rdi), %esi
testl %esi, %esi
je 0x19568e
xorl %ecx, %ecx
xorl %eax, %eax
xorl %edx, %edx
movq (%rdi), %r8
cmpl $-0x1, 0xc(%r8,%rcx)
je 0x19567d
leaq (%r8,%rcx), %rsi
leaq (%rax,%rax,4), %r9
incq %rax
movq 0x20(%rsi), %r10
movq %r10, 0x20(%r8,%r9,8)
movups (%rsi), %xmm0
movups 0x10(%rsi), %xmm1
movups %xmm1, 0x10(%r8,%r9,8)
movups %xmm0, (%r8,%r9,8)
movl 0xc(%rdi), %esi
incq %rdx
movl %esi, %r8d
addq $0x28, %rcx
cmpq %r8, %rdx
jb 0x195649
jmp 0x195690
xorl %eax, %eax
movl %eax, 0xc(%rdi)
movl $0x80, %esi
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x19698b
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/ecovlp.cpp
// Function: worker_hap_dc_ec_chemical_arc(void*, long, int)
static void worker_hap_dc_ec_chemical_arc(void *data, long i, int tid)
{
    ec_ovec_buf_t0 *b = &(((ec_ovec_buf_t*)data)->a[tid]);
    ma_hit_t_alloc *paf = &(R_INF.paf[i]), *rev; uint64_t k, z;

    if(b->cnt[1] == 0) {
        if(is_chemical_r_adv(&(R_INF.paf[i]), &b->v64, Get_READ_LENGTH((R_INF), i), asm_opt.chemical_cov, asm_opt.chemical_flank, 0.02, 1)) {
            // fprintf(stderr, "-um-[M::%s]\tqn::%u::%.*s\n\n", __func__, (uint32_t)(i), (int)Get_NAME_LENGTH(R_INF, i), Get_NAME((R_INF), i));   
            for (k = 0; k < paf->length; k++) paf->buffer[k].del = 1; b->cnt[0]++;
        }
    } else if(b->cnt[1] == 1) {
        for (k = 0; k < paf->length; k++) {
            if((Get_qn(paf->buffer[k])) > (Get_tn(paf->buffer[k]))) continue;
            rev = &(R_INF.paf[paf->buffer[k].tn]);
            for (z = 0; z < rev->length; z++) {
                if((rev->buffer[z].tn == (Get_qn(paf->buffer[k])))) {
                    if(paf->buffer[k].del != rev->buffer[z].del) {
                        paf->buffer[k].del = rev->buffer[z].del = 1;
                    }
                }
            }
        }
    }

   refresh_ec_ovec_buf_t0(b, REFRESH_N);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq (%rdi), %rax
movslq %edx, %rcx
imulq $0x5c0, %rcx, %rdx      # imm = 0x5C0
leaq (%rax,%rdx), %rbx
leaq 0x100b6b(%rip), %rcx    # 0x296230
leaq (%rsi,%rsi,2), %r14
shlq $0x3, %r14
addq 0x78(%rcx), %r14
movq 0xc8(%rax,%rdx), %rax
testq %rax, %rax
je 0x195790
cmpq $0x1, %rax
jne 0x195807
movl 0xc(%r14), %edi
testl %edi, %edi
je 0x195807
movabsq $-0x8000000000000000, %rax # imm = 0x8000000000000000
xorl %edx, %edx
movq (%r14), %r9
leaq (%rdx,%rdx,4), %rsi
movl 0xc(%r9,%rsi,8), %r8d
cmpl 0x4(%r9,%rsi,8), %r8d
jb 0x195780
movq 0x78(%rcx), %r9
leaq (%r8,%r8,2), %r10
movl 0xc(%r9,%r10,8), %r8d
testl %r8d, %r8d
je 0x195780
leaq (%r9,%r10,8), %rdi
movl $0x18, %r9d
xorl %r10d, %r10d
movq (%rdi), %r11
movl -0xc(%r11,%r9), %ebp
movq (%r14), %r15
cmpl 0x4(%r15,%rsi,8), %ebp
jne 0x19576d
leaq (%r15,%rsi,8), %r12
movq (%r11,%r9), %r15
movq 0x18(%r12), %r12
xorq %r15, %r12
jns 0x19576d
orq %rax, %r15
movq %r15, (%r11,%r9)
movq (%r14), %r8
orq %rax, 0x18(%r8,%rsi,8)
movl 0xc(%rdi), %r8d
incq %r10
movl %r8d, %r11d
addq $0x28, %r9
cmpq %r11, %r10
jb 0x195736
movl 0xc(%r14), %edi
incq %rdx
movl %edi, %esi
cmpq %rsi, %rdx
jb 0x195704
jmp 0x195807
leaq 0x4d0(%rbx), %rax
movq 0x18(%rcx), %rcx
movq (%rcx,%rsi,8), %rdx
leaq 0xfffb2(%rip), %rsi     # 0x295758
movq 0x2b8(%rsi), %rcx
movq 0x2c0(%rsi), %r8
movsd 0x9885c(%rip), %xmm0    # 0x22e018
movl $0x1, %r9d
movq %r14, %rdi
movq %rax, %rsi
callq 0x18a85d
testl %eax, %eax
je 0x195807
cmpl $0x0, 0xc(%r14)
je 0x195800
movl $0x18, %eax
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
xorl %edx, %edx
movq (%r14), %rsi
orq %rcx, (%rsi,%rax)
incq %rdx
movl 0xc(%r14), %esi
addq $0x28, %rax
cmpq %rsi, %rdx
jb 0x1957e9
incq 0xc0(%rbx)
movl $0x80, %esi
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x19698b
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/ecovlp.cpp
// Function: gen_hc_polish(unsigned long, ma_ug_t*)
void gen_hc_polish(uint64_t n_thre, ma_ug_t *ug)
{
    ec_polish_buf_t b; memset(&b, 0, sizeof(b)); b.ug = ug;
    uint64_t k, z, zn;
    for (k = b.idx.n = 0; k < ug->u.n; k++) {
        b.idx.n += ug->u.a[k].n;
    }
    MALLOC(b.idx.a, b.idx.n);
    for (k = zn = 0; k < ug->u.n; k++) {
        for (z = 0; z < ug->u.a[k].n; z++, zn++) {
            b.idx.a[zn] = (k<<32)|z;
        }
    }
    b.p = gen_ec_ovec_buf_t(n_thre);

    kt_for(n_thre, worker_ec_polish, &b, b.idx.n);

    destroy_ec_ovec_buf_t(b.p); free(b.idx.a);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r15
movq %rdi, %rbx
movq $0x0, 0x10(%rsp)
movq %rsi, 0x20(%rsp)
movq (%rsi), %r12
testq %r12, %r12
je 0x195a20
movq 0x10(%r15), %rax
addq $0x10, %rax
xorl %r14d, %r14d
movq %r12, %rcx
movl (%rax), %edx
addq %rdx, %r14
addq $0x28, %rax
decq %rcx
jne 0x195a10
jmp 0x195a23
xorl %r14d, %r14d
movq %r14, 0x8(%rsp)
leaq (,%r14,8), %rdi
callq 0x2280
movq %rax, 0x18(%rsp)
testq %r12, %r12
je 0x195a7f
movq 0x10(%r15), %rcx
xorl %edx, %edx
xorl %esi, %esi
leaq (%rsi,%rsi,4), %rdi
movl 0x10(%rcx,%rdi,8), %edi
testq %rdi, %rdi
je 0x195a77
movq %rsi, %r8
shlq $0x20, %r8
leaq (%rax,%rdx,8), %r10
xorl %r9d, %r9d
movq %r9, %r11
orq %r8, %r11
movq %r11, (%r10,%r9,8)
incq %r9
cmpq %r9, %rdi
jne 0x195a62
addq %r9, %rdx
incq %rsi
cmpq %r12, %rsi
jne 0x195a47
movl %ebx, %edi
callq 0x17fcf7
movq %rsp, %r15
movq %rax, (%r15)
leaq 0x2a(%rip), %rsi        # 0x195abd
movl %ebx, %edi
movq %r15, %rdx
movq %r14, %rcx
callq 0x108f2c
movq (%r15), %rdi
callq 0x18002d
movq 0x18(%r15), %rdi
callq 0x2220
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/ecovlp.cpp
// Function: insert_cns_arc(cns_gfa*, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int)
inline void insert_cns_arc(cns_gfa *cns, uint32_t src, uint32_t des, uint32_t is_ou, uint32_t plus0, uint32_t rid)
{
    if(src >= cns->n) {
        fprintf(stderr, "[M::%s] rid::%u, src::%u, des::%u, (*cns).n::%u\n", __func__, rid, src, des, (uint32_t)(*cns).n);
        exit(1);
    }
    cns_arc *p, t; kv_pushp(cns_arc, (*cns).a[src].arc, &p);
    p->f = 0; p->sc = plus0; p->v = des;
    if(is_ou) {
        (*cns).a[src].arc.nou++;
        if((*cns).a[src].arc.nou < (*cns).a[src].arc.n) {
            t = (*cns).a[src].arc.a[(*cns).a[src].arc.nou-1]; 
            (*cns).a[src].arc.a[(*cns).a[src].arc.nou-1] = *p;
            *p = t;
        }
    } 
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %edx
movq (%rdi), %rax
cmpq %rdx, %rax
jbe 0x196067
movl %r8d, %r15d
movl %ecx, %ebp
movq %rdi, %r14
movq 0x10(%rdi), %rcx
leaq (%rdx,%rdx,4), %r12
movq 0x8(%rcx,%r12,8), %rax
cmpq 0x10(%rcx,%r12,8), %rax
jne 0x196003
leaq (%rcx,%r12,8), %rdi
addq $0x8, %rdi
leaq (%rax,%rax), %r8
testq %rax, %rax
movl $0x2, %esi
cmovneq %r8, %rsi
shlq $0x3, %rdx
leaq (%rdx,%rdx,4), %r13
movq %rsi, 0x10(%rcx,%r13)
movq 0x18(%rdi), %rdi
shlq $0x3, %rsi
callq 0x2370
movq 0x10(%r14), %rcx
movq %rax, 0x20(%rcx,%r13)
movq 0x8(%rcx,%r13), %rax
movq 0x20(%rcx,%r12,8), %rdx
leaq 0x1(%rax), %rsi
movq %rsi, 0x8(%rcx,%r12,8)
movl %r15d, 0x4(%rdx,%rax,8)
andl $0x7fffffff, %ebx       # imm = 0x7FFFFFFF
movl %ebx, (%rdx,%rax,8)
testl %ebp, %ebp
je 0x196058
movq 0x10(%r14), %rsi
movq 0x18(%rsi,%r12,8), %rcx
leaq 0x1(%rcx), %rdi
movq %rdi, 0x18(%rsi,%r12,8)
cmpq 0x8(%rsi,%r12,8), %rdi
jae 0x196058
leaq (%rsi,%r12,8), %rsi
addq $0x8, %rsi
movq 0x18(%rsi), %rsi
movq (%rsi,%rcx,8), %rdi
movq (%rdx,%rax,8), %r8
movq %r8, (%rsi,%rcx,8)
movq %rdi, (%rdx,%rax,8)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %esi, %r8d
movq 0xfef6f(%rip), %rcx     # 0x294fe0
movq (%rcx), %rdi
movl %eax, (%rsp)
leaq 0xa97c2(%rip), %rsi     # 0x23f840
leaq 0xa97ec(%rip), %rdx     # 0x23f871
movl %r9d, %ecx
movl %ebx, %r9d
xorl %eax, %eax
callq 0x22b0
movl $0x1, %edi
callq 0x2250
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/./Levenshtein_distance.h
// Function: push_trace_bp(asg16_v*, unsigned short, unsigned short, unsigned int, unsigned int)
inline void push_trace_bp(asg16_v *res, uint16_t c, uint16_t b, uint32_t len, uint32_t is_append)
{
    uint16_t p, c0, b0, len0, mm; 
	if((is_append) && (res->n)) {
		b0 = b;
		pop_trac_bpc(res->a[res->n-1], c0, b0, len0);
		if((c == c0) && (b == b0)) {
			res->n--; len += len0;
		}
	}
	
	mm = (0x3fff); c0 = c; c <<= 14;
	if(c0 == 1 || c0 == 2) {
		mm = (0xfff); c += ((b&3) << 12);
	}

	
	while (len >= mm) {
		p = (c + mm); kv_push(uint16_t, *res, p); len -= mm;
	}
	// fprintf(stderr, "[M::%s] c::%u, len::%u\n", __func__, c, len);
	if(len) {
		p = (c + len); kv_push(uint16_t, *res, p);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %ebp
movq %rdi, %rbx
testl %r8d, %r8d
je 0x19670b
movq (%rbx), %rax
testq %rax, %rax
je 0x19670b
movq 0x10(%rbx), %rcx
movzwl -0x2(%rcx,%rax,2), %ecx
movl %ecx, %r10d
shrl $0xe, %r10d
movl %r10d, %edi
addl $-0x3, %edi
cmpw $-0x2, %di
setb %r8b
movl %ecx, %r9d
shrl $0xc, %r9d
andl $0x3, %r9d
cmpw %dx, %r9w
sete %r9b
cmpw %si, %r10w
jne 0x19670b
orb %r9b, %r8b
je 0x19670b
cmpw $-0x2, %di
movl $0x3fff, %edi           # imm = 0x3FFF
movl $0xfff, %r8d            # imm = 0xFFF
cmovbl %edi, %r8d
andl %r8d, %ecx
decq %rax
movq %rax, (%rbx)
addl %ecx, %ebp
movl %esi, %eax
shll $0xe, %eax
decl %esi
andl $0x3, %edx
shll $0xc, %edx
xorl %r14d, %r14d
cmpw $0x2, %si
cmovbl %edx, %r14d
movl $0xfff, %ecx            # imm = 0xFFF
movl $0x3fff, %r15d          # imm = 0x3FFF
cmovbl %ecx, %r15d
orl %eax, %r14d
cmpl %r15d, %ebp
jb 0x196789
leal (%r14,%r15), %r12d
movq (%rbx), %rcx
movq 0x10(%rbx), %rax
movl $0x2, %r13d
cmpq 0x8(%rbx), %rcx
jne 0x196772
leaq (%rcx,%rcx), %rsi
testq %rcx, %rcx
cmoveq %r13, %rsi
movq %rsi, 0x8(%rbx)
addq %rsi, %rsi
movq %rax, %rdi
callq 0x2370
movq %rax, 0x10(%rbx)
movq (%rbx), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, (%rbx)
movw %r12w, (%rax,%rcx,2)
subl %r15d, %ebp
movq %rdx, %rcx
cmpl %r15d, %ebp
jae 0x19674b
testl %ebp, %ebp
je 0x1967d2
addl %ebp, %r14d
movq (%rbx), %rcx
cmpq 0x8(%rbx), %rcx
jne 0x1967c2
leaq (%rcx,%rcx), %rax
testq %rcx, %rcx
movl $0x2, %esi
cmovneq %rax, %rsi
movq %rsi, 0x8(%rbx)
movq 0x10(%rbx), %rdi
addq %rsi, %rsi
callq 0x2370
movq %rax, 0x10(%rbx)
movq (%rbx), %rcx
jmp 0x1967c6
movq 0x10(%rbx), %rax
leaq 0x1(%rcx), %rdx
movq %rdx, (%rbx)
movw %r14w, (%rax,%rcx,2)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: init_clean_mul_t(asg_t*, ma_ug_t*, unsigned long, unsigned char, unsigned char)
clean_mul_t *init_clean_mul_t(asg_t *g, ma_ug_t *ug, uint64_t n_threads, uint8_t fp, uint8_t fa)
{
    uint32_t i;
    clean_t *kt = NULL;
    clean_mul_t *p = NULL; CALLOC(p, 1);
    p->g = g; p->ug = ug;
    CALLOC(p->bs_flag, p->g->n_seq<<1);
    p->n = p->m = n_threads;
    CALLOC(p->a, p->n);
    for (i = 0, kt = NULL; i < p->n; i++)
    {
        kt = &(p->a[i]);
        kv_init(kt->tt.a); kv_init(kt->stack.a);
        CALLOC(kt->vis, p->g->n_seq<<1);
        init_pdq(&kt->pq_p, p->g->n_seq<<1);
        init_pdq(&kt->pq_a, p->g->n_seq<<1);
        memset(&kt->b, 0, sizeof(kt->b));
        kt->b.a = (binfo_t*)calloc(p->g->n_seq<<1, sizeof(binfo_t));
    }
    p->max_dist = get_bub_pop_max_dist_advance(g, &kt->b);
    p->fp = fp; p->fa = fa;
    return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %r8d, 0x4(%rsp)
movl %ecx, (%rsp)
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %r14
movl $0x1, %edi
movl $0x40, %esi
callq 0x2120
movq %rax, %r15
movq %r14, 0x30(%rax)
movq %r13, 0x38(%rax)
movl 0x14(%r14), %ebx
leal (%rbx,%rbx), %eax
movslq %eax, %rdi
movl $0x1, %esi
callq 0x2120
movq %rax, 0x20(%r15)
movq %r12, 0x10(%r15)
movq %r12, 0x8(%r15)
movl $0x1a0, %esi            # imm = 0x1A0
movq %r12, 0x10(%rsp)
movq %r12, %rdi
callq 0x2120
movq %rax, %r13
movq %r15, 0x8(%rsp)
movq %rax, (%r15)
movl $0x1, %ebp
xorl %r15d, %r15d
xorl %eax, %eax
imulq $0x1a0, %rax, %r12      # imm = 0x1A0
addl %ebx, %ebx
movslq %ebx, %rbx
movl $0x1, %esi
movq %rbx, %rdi
callq 0x2120
xorps %xmm0, %xmm0
movups %xmm0, (%r13,%r12)
movq %r15, 0x10(%r13,%r12)
movups %xmm0, 0x20(%r13,%r12)
movq %r15, 0x30(%r13,%r12)
movq %rax, 0x40(%r13,%r12)
leaq (%r12,%r13), %rdi
addq $0x48, %rdi
movq %rbx, %rsi
callq 0x14198e
leaq (%r12,%r13), %rdi
addq $0xb0, %rdi
movl 0x14(%r14), %eax
addl %eax, %eax
movslq %eax, %rsi
callq 0x14198e
xorps %xmm0, %xmm0
movups %xmm0, 0x170(%r13,%r12)
movups %xmm0, 0x160(%r13,%r12)
movups %xmm0, 0x150(%r13,%r12)
movups %xmm0, 0x140(%r13,%r12)
movups %xmm0, 0x130(%r13,%r12)
movups %xmm0, 0x120(%r13,%r12)
movl 0x14(%r14), %ebx
leal (%rbx,%rbx), %eax
movslq %eax, %rdi
movl $0x1c, %esi
callq 0x2120
movq %rax, 0x118(%r13,%r12)
movl %ebp, %eax
incl %ebp
cmpq 0x10(%rsp), %rax
jb 0x196df0
addq %r12, %r13
addq $0x118, %r13            # imm = 0x118
movq %r14, %rdi
movq %r13, %rsi
callq 0xc0162
movq 0x8(%rsp), %rcx
movq %rax, 0x18(%rcx)
movl (%rsp), %eax
movb %al, 0x28(%rcx)
movl 0x4(%rsp), %eax
movb %al, 0x29(%rcx)
movq %rcx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: destroy_clean_mul_t(clean_mul_t**)
void destroy_clean_mul_t(clean_mul_t **p)
{
    uint32_t i;
    clean_t *kt = NULL;
    free((*p)->bs_flag);
    for (i = 0; i < (*p)->n; i++)
    {
        kt = &((*p)->a[i]);
        kv_destroy(kt->tt.a);
        kv_destroy(kt->stack.a);
        free(kt->vis);
        destory_pdq(&kt->pq_p);
        destory_pdq(&kt->pq_a);
        free(kt->b.a); free(kt->b.S.a); free(kt->b.T.a); free(kt->b.b.a); free(kt->b.e.a);
    }
    free((*p)->a);
    free((*p));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
movq 0x20(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
cmpq $0x0, 0x8(%rax)
je 0x196faf
movl $0x1, %ebp
xorl %ecx, %ecx
movq (%rax), %r15
imulq $0x1a0, %rcx, %r12      # imm = 0x1A0
leaq (%r15,%r12), %r14
addq $0x48, %r14
movq -0x38(%r14), %rdi
callq 0x2220
movq -0x18(%r14), %rdi
callq 0x2220
movq -0x8(%r14), %rdi
callq 0x2220
movq %r14, %rdi
callq 0x141a1d
leaq (%r15,%r12), %r14
addq $0xb0, %r14
movq %r14, %rdi
callq 0x141a1d
movq 0x68(%r14), %rdi
callq 0x2220
movq 0x80(%r14), %rdi
callq 0x2220
movq 0x98(%r14), %rdi
callq 0x2220
movq 0xb0(%r14), %rdi
callq 0x2220
movq 0xc8(%r14), %rdi
callq 0x2220
movl %ebp, %ecx
movq (%rbx), %rax
incl %ebp
cmpq %rcx, 0x8(%rax)
ja 0x196f1d
movq (%rax), %rdi
callq 0x2220
movq (%rbx), %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: get_utg_chain_length(ma_ug_t*, unsigned int*, unsigned int)
uint64_t get_utg_chain_length(ma_ug_t *ug, uint32_t *a, uint32_t a_n)
{
    uint64_t i, k, l, qn, v, w, nv, offset;
    asg_arc_t *av  = NULL;
    for (i = 0, offset = 0; i < a_n; i++)
    {
        qn = a[i]>>1;
        l = ug->g->seq[qn].len;
        if(i + 1 < a_n)
        {
            v = a[i]; w = a[i+1];
            av = asg_arc_a(ug->g, v);
            nv = asg_arc_n(ug->g, v);
            for (k = 0; k < nv; k++)
            {
                if(av[k].del) continue;
                if(av[k].v == w) 
                {
                    l = asg_arc_len(av[k]);
                    break;
                }
            }
            if(k >= nv) fprintf(stderr, "ERROR-mc\n");
        }
        offset += l;
    }
    return offset;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testl %edx, %edx
je 0x197128
movq %rsi, %rbx
movq %rdi, %r14
movl %edx, %r12d
xorl %r15d, %r15d
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
xorl %ebp, %ebp
movl (%rbx,%rbp,4), %ecx
movl %ecx, %edx
shrl %edx
movq 0x18(%r14), %rax
movq 0x20(%rax), %rsi
movl (%rsi,%rdx,8), %r13d
andl $0x7fffffff, %r13d      # imm = 0x7FFFFFFF
incq %rbp
cmpq %r12, %rbp
jae 0x19711a
movq 0x28(%rax), %rdx
movq (%rdx,%rcx,8), %rdx
movq %rdx, %rsi
andq %r9, %rsi
je 0x197105
movl (%rbx,%rbp,4), %ecx
movq 0x8(%rax), %rax
shrq $0x20, %rdx
shlq $0x3, %rsi
leaq (%rsi,%rsi,2), %rsi
leaq (%rdx,%rdx,2), %rdx
leaq (%rax,%rdx,8), %r8
addq $0xc, %r8
xorl %edi, %edi
cmpl $0x0, (%r8,%rdi)
js 0x1970fc
cmpl %ecx, -0x4(%r8,%rdi)
je 0x197112
addq $0x18, %rdi
cmpq %rdi, %rsi
jne 0x1970ee
callq 0x237a1
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
jmp 0x19711a
leaq (%rax,%rdx,8), %rax
movl (%rdi,%rax), %r13d
addq %r13, %r15
cmpq %r12, %rbp
jne 0x19709b
jmp 0x19712b
xorl %r15d, %r15d
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: collect_trans_ovlp(char const*, buf_t*, unsigned long, buf_t*, unsigned long, ma_ug_t*, utg_trans_t*)
void collect_trans_ovlp(const char* cmd, buf_t* pri, uint64_t pri_offset, buf_t* aux, uint64_t aux_offset,
ma_ug_t *ug, utg_trans_t *o)
{
    uint32_t thre_pri;
    uint64_t len_aux;
    if(pri->b.n == 0 || aux->b.n == 0) return;

    len_aux = set_utg_offset(aux->b.a, aux->b.n, ug, o->read_g, o->pos_idx, 0, 0);
    chain_trans_ovlp(NULL, o, ug, o->read_g, pri, len_aux, &thre_pri);

    
    if(thre_pri > 0)
    {
        chain_trans_d(o, pri->b.a, pri->b.n, pri_offset, NULL, aux->b.a, aux->b.n, aux_offset, &len_aux, 
        ug, RC_1, -1024, __func__);
        // fprintf(stderr, "\n%s, thre_pri: %u, len_aux: %lu\n", cmd, thre_pri, len_aux);
        // print_buf_t(ug, pri, "pri");
        // print_buf_t(ug, aux, "aux");
    }
    set_utg_offset(aux->b.a, aux->b.n, ug, o->read_g, o->pos_idx, 1, 0);
}

// Assembly:
cmpq $0x0, 0x38(%rsi)
je 0x1991ba
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r14
movq %rsi, %rbp
movq 0x38(%rcx), %rsi
testq %rsi, %rsi
je 0x1991ac
movq %r9, %rbx
movq %rdx, %r13
movq %r8, (%rsp)
movq 0x50(%rsp), %r12
movq 0x48(%r14), %rdi
movq 0x18(%r12), %rcx
movq 0xe0(%r12), %r8
subq $0x8, %rsp
movq %r9, %rdx
xorl %r9d, %r9d
pushq $0x0
callq 0xbc79b
addq $0x10, %rsp
movl %eax, %ecx
movq %rcx, 0x8(%rsp)
movq 0x18(%r12), %rcx
subq $0x8, %rsp
leaq 0x1c(%rsp), %r15
xorl %edi, %edi
movq %r12, %rsi
movq %rbx, %rdx
movq %rbp, %r8
movl %eax, %r9d
pushq %r15
callq 0x10cd5c
addq $0x10, %rsp
cmpl $0x0, (%r15)
je 0x19917f
movq 0x48(%rbp), %rsi
movl 0x38(%rbp), %edx
movq 0x48(%r14), %r9
movl 0x38(%r14), %eax
subq $0x8, %rsp
leaq 0x10(%rsp), %r10
movsd 0x9cbf5(%rip), %xmm0    # 0x235d58
movq %r12, %rdi
movl %r13d, %ecx
xorl %r8d, %r8d
pushq $0x1
pushq %rbx
pushq %r10
pushq 0x20(%rsp)
pushq %rax
callq 0x197845
addq $0x30, %rsp
movq 0x48(%r14), %rdi
movl 0x38(%r14), %esi
movq 0x18(%r12), %rcx
movq 0xe0(%r12), %r8
subq $0x8, %rsp
movq %rbx, %rdx
movl $0x1, %r9d
pushq $0x0
callq 0xbc79b
addq $0x10, %rsp
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: is_pop_bub(unsigned int, asg_t*, ma_ug_t*, buf_t*, unsigned long, unsigned char*)
int is_pop_bub(uint32_t v, asg_t *g, ma_ug_t *ug, buf_t *b, uint64_t max_dist, uint8_t *bs_flag)
{
    bs_flag[v] = 4;
    asg_arc_t *av = NULL;
    uint32_t nv, i, n_arc;
    int occ = 0;
    nv = asg_arc_n(g, v);
    av = asg_arc_a(g, v);
    ///some node could be deleted
    if (nv < 2 || g->seq[v>>1].del || g->seq[v>>1].c == ALTER_LABLE) return occ;
    ///some edges could be deleted
    for (i = n_arc = 0; i < nv; ++i) // asg_bub_pop1() may delete some edges/arcs
        if (!av[i].del) ++n_arc;
    if (n_arc < 2) return occ;
    if(asg_bub_pop1_primary_trio(ug->g, NULL, v, max_dist, b, (uint32_t)-1, (uint32_t)-1, 0, NULL, NULL, NULL, 0, 0, NULL))
    {
        //beg is v, end is b.S.a[0]
        //note b.b include end, does not include beg
        bs_flag[v] = 0;
        occ = 1;
    }
    return occ;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rcx, %rax
movl %edi, %ecx
movl %edi, %r15d
movb $0x4, (%r9,%r15)
movq 0x28(%rsi), %rdi
movq (%rdi,%r15,8), %rdi
xorl %r14d, %r14d
testl $0xfffffffe, %edi       # imm = 0xFFFFFFFE
je 0x199db0
movq %r9, %rbx
movq 0x20(%rsi), %r9
movl %ecx, %r10d
shrl %r10d
cmpl $0x0, (%r9,%r10,8)
js 0x199db0
cmpb $0x1, 0x4(%r9,%r10,8)
je 0x199db0
movq 0x8(%rsi), %r9
movq %rdi, %r10
shrq $0x20, %r10
movl %edi, %esi
leaq (%r10,%r10,2), %rdi
leaq (%r9,%rdi,8), %r9
addq $0xc, %r9
xorl %edi, %edi
movl (%r9), %r10d
notl %r10d
shrl $0x1f, %r10d
addl %r10d, %edi
addq $0x18, %r9
decq %rsi
jne 0x199d3e
xorl %r14d, %r14d
cmpl $0x2, %edi
jb 0x199db0
movq 0x18(%rdx), %rdi
xorl %r14d, %r14d
movq %r14, 0x38(%rsp)
movl %r14d, 0x30(%rsp)
movl %r14d, 0x28(%rsp)
movq %r14, 0x20(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rsp)
movl %r14d, 0x8(%rsp)
movl $0xffffffff, (%rsp)     # imm = 0xFFFFFFFF
xorl %esi, %esi
movl %ecx, %edx
movq %r8, %rcx
movq %rax, %r8
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
callq 0xc02d6
testq %rax, %rax
je 0x199db0
movb $0x0, (%rbx,%r15)
movl $0x1, %r14d
movl %r14d, %eax
addq $0x40, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: unitig_iden_worker(void*, long, int)
static void unitig_iden_worker(void *_data, long eid, int tid)
{
    long long d;
    clean_mul_t *buf = (clean_mul_t*)_data;
    clean_t *b = &(buf->a[tid]);
    if(is_pop_unitig(eid, buf->g, buf->ug, &(b->tt), &(b->stack), b->vis, &(b->pq_p), &(b->pq_a), buf->fp, buf->fa, &d))
    {
        if(b->min_v == (uint32_t)-1 || (b->min_d > d) || 
        (b->min_d == d && buf->g->seq[b->min_v>>1].len > buf->g->seq[eid>>1].len) ||
        (b->min_d == d && buf->g->seq[b->min_v>>1].len == buf->g->seq[eid>>1].len && b->min_v > eid))
        {
            b->min_v = eid; b->min_d = d;
        }
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r15
movslq %edx, %rax
imulq $0x1a0, %rax, %rax      # imm = 0x1A0
movq (%rdi), %rcx
movq 0x30(%rdi), %rsi
leaq (%rcx,%rax), %r14
movq 0x38(%rdi), %rdx
leaq 0x20(%rcx,%rax), %r8
movq 0x20(%r8), %r9
leaq 0x48(%rcx,%rax), %r10
addq %rcx, %rax
addq $0xb0, %rax
movzbl 0x28(%rdi), %r11d
movzbl 0x29(%rdi), %r12d
subq $0x8, %rsp
leaq 0x10(%rsp), %r13
movl %ebx, %edi
movq %r14, %rcx
pushq %r13
pushq %r12
pushq %r11
pushq %rax
pushq %r10
callq 0x1998a7
addq $0x30, %rsp
testl %eax, %eax
je 0x19a2e0
movl 0x180(%r14), %ecx
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movq 0x8(%rsp), %rax
cmpq %rdx, %rcx
je 0x19a2d2
cmpq %rax, 0x190(%r14)
jle 0x19a2ee
movl %ebx, 0x180(%r14)
movq %rax, 0x190(%r14)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jne 0x19a2e0
movq 0x30(%r15), %rdx
movq 0x20(%rdx), %rsi
movl %ecx, %edx
shrl %edx
movl (%rsi,%rdx,8), %edx
movl $0x7fffffff, %edi       # imm = 0x7FFFFFFF
movl %edx, %r8d
andl %edi, %r8d
movq %rbx, %r9
andq $-0x2, %r9
movl (%rsi,%r9,4), %esi
andl %esi, %edi
cmpl %edi, %r8d
ja 0x19a2d2
cmpq %rbx, %rcx
jle 0x19a2e0
xorl %edx, %esi
andl $0x7fffffff, %esi       # imm = 0x7FFFFFFF
je 0x19a2d2
jmp 0x19a2e0
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: rs_sort_tb64(unsigned long*, unsigned long*, int, int)
KRADIX_SORT_INIT(tb64, uint64_t, generic_key, 8)

typedef struct { uint32_t n, m; pt128_t *a; } pt128_v;
typedef struct { uint32_t n, m; pt_mz1_t *a; } pt_mz1_v;

static inline int mzcmp(const pt_mz1_t *a, const pt_mz1_t *b)
{
	return (a->x > b->x) - (a->x < b->x);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %ebx
movl %edx, %r14d
movl $0x1, %eax
movl %r14d, %ecx
shll %cl, %eax
leal -0x1(%rax), %edx
movq %rax, %rcx
shlq $0x4, %rcx
movq %rsp, %r15
subq %rcx, %r15
movq %r15, %rsp
cltq
shlq $0x4, %rax
leaq (%r15,%rax), %r12
xorl %ecx, %ecx
movq %rdi, 0x8(%r15,%rcx)
movq %rdi, (%r15,%rcx)
addq $0x10, %rcx
cmpq %rcx, %rax
jne 0x19b2b1
movl %ebx, %ecx
movslq %edx, %rdx
cmpq %rsi, %rdi
je 0x19b2ec
movq %rdi, %r8
movq (%r8), %r9
shrq %cl, %r9
andq %rdx, %r9
shlq $0x4, %r9
addq $0x8, 0x8(%r15,%r9)
addq $0x8, %r8
cmpq %rsi, %r8
jne 0x19b2d0
testl %r14d, %r14d
je 0x19b313
movl $0x10, %esi
movq -0x8(%r15,%rsi), %r8
movq %r8, %r9
subq %rdi, %r9
addq %r9, 0x8(%r15,%rsi)
movq %r8, (%r15,%rsi)
addq $0x10, %rsi
cmpq %rsi, %rax
jne 0x19b2f6
movq %r15, %rsi
movq (%rsi), %r10
cmpq 0x8(%rsi), %r10
je 0x19b36e
movq (%r10), %r8
movq %r8, %r9
shrq %cl, %r9
andq %rdx, %r9
shlq $0x4, %r9
addq %r15, %r9
cmpq %rsi, %r9
je 0x19b374
movq %r8, %r10
movq (%r9), %r11
movq (%r11), %r8
leaq 0x8(%r11), %r13
movq %r13, (%r9)
movq %r10, (%r11)
movq %r8, %r9
shrq %cl, %r9
andq %rdx, %r9
shlq $0x4, %r9
addq %r15, %r9
cmpq %rsi, %r9
jne 0x19b337
movq (%rsi), %r9
leaq 0x8(%r9), %r10
movq %r10, (%rsi)
movq %r8, (%r9)
jmp 0x19b37b
addq $0x10, %rsi
jmp 0x19b37b
addq $0x8, %r10
movq %r10, (%rsi)
cmpq %r12, %rsi
jne 0x19b316
movq %rdi, (%r15)
testl %r14d, %r14d
je 0x19b39f
movl $0x10, %ecx
movq -0x8(%r15,%rcx), %rdx
movq %rdx, (%r15,%rcx)
addq $0x10, %rcx
cmpq %rcx, %rax
jne 0x19b38d
testl %ebx, %ebx
je 0x19b428
xorl %eax, %eax
subl %r14d, %ebx
cmovlel %eax, %ebx
movq (%r15), %rdi
movq 0x8(%r15), %rsi
movq %rsi, %rax
subq %rdi, %rax
sarq $0x3, %rax
cmpq $0x41, %rax
jl 0x19b3d2
movl %r14d, %edx
movl %ebx, %ecx
callq 0x19b275
jmp 0x19b41f
cmpq $0x2, %rax
jl 0x19b41f
leaq 0x8(%rdi), %rdx
cmpq %rsi, %rdx
jae 0x19b41f
movq %rdi, %rax
movq %rax, %r8
movq 0x8(%rax), %rcx
movq %rdx, %rax
cmpq (%r8), %rcx
jae 0x19b416
movq %rax, %rdx
cmpq %rdi, %rax
jbe 0x19b413
movq %rax, %rdx
movq -0x8(%rdx), %r8
cmpq %r8, %rcx
jae 0x19b413
movq %r8, (%rdx)
addq $-0x8, %rdx
cmpq %rdi, %rdx
ja 0x19b3fe
movq %rcx, (%rdx)
leaq 0x8(%rax), %rdx
cmpq %rsi, %rdx
jb 0x19b3e4
addq $0x10, %r15
cmpq %r12, %r15
jne 0x19b3af
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: pt_collect_minimizers(ma_ug_t*, asg_t*, ma_sub_t*, ma_hit_t_alloc*, kvec_asg_arc_t_warp*, int, int)
pt_mz1_v *pt_collect_minimizers(ma_ug_t *ug, asg_t *read_g, ma_sub_t *coverage_cut, ma_hit_t_alloc* sources, 
kvec_asg_arc_t_warp* edge, int max_hang, int min_ovlp)
{
    uint32_t i;
    pt_mz1_v *mz = NULL; CALLOC(mz, 1);
    
    for (i = 0; i < ug->u.n; i++)
    {
        if(!ug->u.a[i].len) continue;
        pt_sketch(ug->u.a[i].s, ug->u.a[i].len, asm_opt.mz_win, asm_opt.k_mer_length, i, 0, mz);
    }

    radix_sort_mz(mz->a, mz->a + mz->n);
    return mz;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r15
movl $0x1, %edi
movl $0x10, %esi
callq 0x2120
movq %rax, %rbx
movq (%r15), %rax
xorl %r14d, %r14d
testq %rax, %rax
je 0x19bfff
movl $0x7fffffff, %ebp       # imm = 0x7FFFFFFF
leaq 0xf97a3(%rip), %r12     # 0x295758
movq 0x10(%r15), %rcx
leaq (%r14,%r14,4), %rdx
movl (%rcx,%rdx,8), %esi
andl %ebp, %esi
je 0x19bfee
leaq (%rcx,%rdx,8), %rax
movq 0x20(%rax), %rdi
movl 0x80(%r12), %ecx
movl 0x94(%r12), %edx
movq %rbx, (%rsp)
movl %r14d, %r8d
xorl %r9d, %r9d
callq 0x19b49c
movq (%r15), %rax
incl %r14d
cmpq %r14, %rax
ja 0x19bfb5
movq 0x8(%rbx), %rdi
movl (%rbx), %r14d
jmp 0x19c001
xorl %edi, %edi
leaq (%r14,%r14,2), %rax
leaq (%rdi,%rax,8), %rsi
callq 0x19aff3
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: pt_lis_64(int, unsigned long const*, int*, int*)
int32_t pt_lis_64(int32_t n, const uint64_t *a_idx, int32_t *b, int32_t *M)
{
	int32_t i, k, L = 0, *P = b;
	// MALLOC(M, n+1);
	for (i = 0; i < n; ++i) {
		int32_t lo = 1, hi = L, newL;
		while (lo <= hi) {
			int32_t mid = (lo + hi + 1) >> 1;
			if ((uint32_t)a_idx[M[mid]] < (uint32_t)a_idx[i]) lo = mid + 1;
			else hi = mid - 1;
		}
		newL = lo, P[i] = M[newL - 1], M[newL] = i;
		if (newL > L) L = newL;
	}
	k = M[L];
	memcpy(M, P, n * sizeof(int32_t));
	for (i = L - 1; i >= 0; --i) b[i] = k, k = M[k];
	// free(M);
	return L;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r14
testl %edi, %edi
jle 0x19c4de
movl %edi, %eax
xorl %ecx, %ecx
xorl %ebp, %ebp
testl %ebp, %ebp
jle 0x19c4bb
movl (%rsi,%rcx,8), %r8d
movl $0x1, %edx
movl %ebp, %r9d
leal (%rdx,%r9), %r10d
incl %r10d
sarl %r10d
movslq %r10d, %r11
movslq (%rbx,%r11,4), %r11
cmpl %r8d, (%rsi,%r11,8)
jb 0x19c4ae
decl %r10d
movl %r10d, %r9d
jmp 0x19c4b4
incl %r10d
movl %r10d, %edx
cmpl %r9d, %edx
jle 0x19c48f
jmp 0x19c4c0
movl $0x1, %edx
movslq %edx, %rdx
movl -0x4(%rbx,%rdx,4), %r8d
movl %r8d, (%r14,%rcx,4)
movl %ecx, (%rbx,%rdx,4)
cmpl %ebp, %edx
cmovgl %edx, %ebp
incq %rcx
cmpq %rax, %rcx
jne 0x19c47f
jmp 0x19c4e0
xorl %ebp, %ebp
movslq %ebp, %r12
movl (%rbx,%r12,4), %r15d
movslq %edi, %rdx
shlq $0x2, %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2160
testl %r12d, %r12d
jle 0x19c518
movl %ebp, %eax
incq %rax
movl %r15d, -0x8(%r14,%rax,4)
movslq %r15d, %rcx
movl (%rbx,%rcx,4), %r15d
decq %rax
cmpq $0x1, %rax
ja 0x19c503
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: debug_lis_64(unsigned long const*, int*, unsigned long)
uint32_t debug_lis_64(const uint64_t *a, int32_t *b, uint64_t n)
{
    uint32_t i;
    if(n <= 1) return 1;
    for (i = 0; i+1 < n; i++)
    {
        if(((a[b[i]]>>32) > (a[b[i+1]]>>32)) || (((uint32_t)a[b[i]]) > ((uint32_t)a[b[i+1]])))
        {
            i = (uint32_t)-1;
            break;
        }
    } 
    if(i == (uint32_t)-1)
    {
        fprintf(stderr, "\nERROR-chain\n");   
        for (i = 0; i < n; i++)
        {
            fprintf(stderr, "x-%lu, y-%lu\n", (a[b[i]]>>32), (uint64_t)((uint32_t)a[b[i]]));
        }
    }
    return 1;
}

// Assembly:
cmpq $0x2, %rdx
jb 0x19c574
movq %rdi, %rax
movl $0x1, %r9d
movl %r9d, %ecx
cmpq %rdx, %rcx
jae 0x19c56f
decl %r9d
movl %r9d, %edi
movslq (%rsi,%rdi,4), %rdi
movq (%rax,%rdi,8), %rdi
movq %rdi, %r9
shrq $0x20, %r9
movslq (%rsi,%rcx,4), %r8
movq (%rax,%r8,8), %r8
movq %r8, %r10
shrq $0x20, %r10
cmpl %r10d, %r9d
ja 0x19c57a
incl %ecx
movl %ecx, %r9d
cmpl %r8d, %edi
jbe 0x19c532
jmp 0x19c57a
testq %rcx, %rcx
je 0x19c57a
movl $0x1, %eax
retq
pushq %rax
movq %rsi, %rdi
movq %rax, %rsi
callq 0x2382d
addq $0x8, %rsp
jmp 0x19c574
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: get_insert_pos(unsigned long*, long, long)
int64_t get_insert_pos(uint64_t *a, int64_t n, int64_t target)
{
    int64_t left, right, ans, mid;
    left = 0; right = n - 1; ans = n;
    while (left <= right) {
        mid = ((right - left) >> 1) + left;
        if (target <= (uint32_t)a[mid]) {
            ans = mid;
            right = mid - 1;
        } else {
            left = mid + 1;
        }
    }
    return ans;
}

// Assembly:
movq %rsi, %rax
testq %rsi, %rsi
jle 0x19c63f
leaq -0x1(%rax), %rsi
xorl %ecx, %ecx
movq %rsi, %r8
subq %rcx, %r8
sarq %r8
leaq (%r8,%rcx), %r9
movl (%rdi,%r9,8), %r10d
cmpq %rdx, %r10
jl 0x19c634
leaq (%r8,%rcx), %rsi
decq %rsi
movq %r9, %rax
jmp 0x19c63a
addq %r8, %rcx
incq %rcx
cmpq %rsi, %rcx
jle 0x19c612
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: get_mz_occ(mz_ds_t*, unsigned long, unsigned long, unsigned long)
uint32_t get_mz_occ(mz_ds_t *mz_idx, uint64_t uid, uint64_t s, uint64_t e)
{
    uint64_t *a = mz_idx->pos.a + (mz_idx->idx[uid]>>32), n = (uint32_t)(mz_idx->idx[uid]);
    if(n == 0) return 0;
    int64_t sid, eid;
    sid = get_insert_pos(a, n, s);
    eid = get_insert_pos(a, n, e);
    return eid + 1 - sid;
}

// Assembly:
movq (%rdi), %rax
movq (%rax,%rsi,8), %rsi
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
andq %rsi, %rax
je 0x19c6d6
pushq %r14
pushq %rbx
shrq $0x1d, %rsi
andq $-0x8, %rsi
addq 0x18(%rdi), %rsi
leaq -0x1(%rax), %rdi
xorl %r9d, %r9d
movq %rax, %r8
movq %rdi, %r10
movq %r10, %r11
subq %r9, %r11
sarq %r11
leaq (%r11,%r9), %rbx
movl (%rsi,%rbx,8), %r14d
cmpq %rdx, %r14
jl 0x19c693
leaq (%r11,%r9), %r10
decq %r10
movq %rbx, %r8
jmp 0x19c699
addq %r11, %r9
incq %r9
cmpq %r10, %r9
jle 0x19c671
xorl %edx, %edx
movq %rdi, %r9
subq %rdx, %r9
sarq %r9
leaq (%r9,%rdx), %r10
movl (%rsi,%r10,8), %r11d
cmpq %rcx, %r11
jl 0x19c6c2
leaq (%r9,%rdx), %rdi
decq %rdi
movq %r10, %rax
jmp 0x19c6c8
addq %r9, %rdx
incq %rdx
cmpq %rdi, %rdx
jle 0x19c6a0
subl %r8d, %eax
incl %eax
popq %rbx
popq %r14
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/tovlp.cpp
// Function: pt_pdist(ma_ug_t*, asg_t*, ma_sub_t*, ma_hit_t_alloc*, kvec_asg_arc_t_warp*, int, int, unsigned int)
kv_u_trans_t *pt_pdist(ma_ug_t *ug, asg_t *read_g, ma_sub_t *coverage_cut, ma_hit_t_alloc* sources, 
kvec_asg_arc_t_warp* edge, int max_hang, int min_ovlp, uint32_t min_chain_cnt)
{
    pt_mz1_v *mz = NULL;
    mz_ds_t mz_idx; memset(&mz_idx, 0, sizeof(mz_idx));
    pt128_v *an = NULL;
    kv_u_trans_t *ma = NULL; CALLOC(ma, 1);
    mz = pt_collect_minimizers(ug, read_g, coverage_cut, sources, edge, max_hang, min_ovlp);
    an = pt_collect_anchors(ug, mz, &mz_idx, asm_opt.polyploidy*10);
    kv_destroy(*mz); free(mz);

    ma = pt_cal_sim(an, &mz_idx, ug, min_chain_cnt, asm_opt.purge_simi_thres);
    kv_destroy(*an); free(an); 
    kv_destroy(mz_idx.pos); free(mz_idx.idx);
    
    kt_u_trans_t_idx(ma, ug->g->n_seq);
    kt_u_trans_t_simple_symm(ma, ug->g->n_seq, 1);
    clean_mz_ovlp(ma, ug);
    // print_u_trans(ma);
    // exit(1);
    return ma;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movl 0x78(%rsp), %ebp
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %r14
movaps %xmm0, 0x10(%r14)
movaps %xmm0, (%r14)
callq 0x19bf7d
movq %rax, %r15
leaq 0xf879a(%rip), %r13     # 0x295758
movl 0x1bc(%r13), %eax
addl %eax, %eax
leal (%rax,%rax,4), %ecx
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x19c01e
movq %rax, %r12
movq 0x8(%r15), %rdi
callq 0x2220
movq %r15, %rdi
callq 0x2220
xorps %xmm0, %xmm0
cvtss2sd 0x16c(%r13), %xmm0
movq %r12, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movl %ebp, %ecx
callq 0x19c6d9
movq %rax, %r15
movq 0x8(%r12), %rdi
callq 0x2220
movq %r12, %rdi
callq 0x2220
movq 0x18(%r14), %rdi
callq 0x2220
movq (%r14), %rdi
callq 0x2220
movq 0x18(%rbx), %rax
movl $0x7fffffff, %ebp       # imm = 0x7FFFFFFF
movl 0x14(%rax), %esi
andl %ebp, %esi
movq %r15, %rdi
callq 0xc4edd
movq 0x18(%rbx), %rax
andl 0x14(%rax), %ebp
movq %r15, %rdi
movl %ebp, %esi
movl $0x1, %edx
callq 0xcc893
movq %r15, %rdi
movq %rbx, %rsi
callq 0x19cbe0
movq %r15, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/inter.cpp
// Function: mg_gres_a_des(mg_gres_a*)
void mg_gres_a_des(mg_gres_a *p)
{
	uint64_t i = 0;
	for (i = 0; i < p->n; i++){
		free(p->a[i].lc); free(p->a[i].gc);
	}
	free(p->a);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpq $0x0, (%rdi)
je 0x1a1f8f
xorl %r14d, %r14d
xorl %r15d, %r15d
movq 0x10(%rbx), %rax
movq 0x10(%rax,%r14), %rdi
callq 0x2220
movq 0x10(%rbx), %rax
movq 0x8(%rax,%r14), %rdi
callq 0x2220
incq %r15
addq $0x28, %r14
cmpq (%rbx), %r15
jb 0x1a1f67
movq 0x10(%rbx), %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/inter.cpp
// Function: flt_anchors(long, mg128_t*, int)
int64_t flt_anchors(int64_t n_a, mg128_t *a, int32_t r)
{
	int64_t i, j;
	for (i = 0; i < n_a; ++i) {
		for (j = i - 1; j >= 0; --j) {
			/**
			 * a is sorted by x
			 * a[].x: ref_id(31)rev(1)r_pos(32)
			 * a[].y: weight(8)query_id(8)flag(8)span(8)q_pos(32)
			 **/
			int32_t dq;
			int64_t dr = a[i].x - a[j].x;///a is sorted by x
			if (dr > r) break;///if two candidates coming from differnt unitigs, dr would be extremly large
			dq = (int32_t)a[i].y - (int32_t)a[j].y;
			if (dq > r || dq < 0) continue;
			a[j].y |= MG_SEED_KEPT;
			a[i].y |= MG_SEED_KEPT;
			break;
		}
	}
	for (i = n_a - 1; i >= 0; --i) {
		if (a[i].y & MG_SEED_KEPT) continue;
		for (j = i + 1; j < n_a; ++j) {
			int32_t dq;
			int64_t dr = a[j].x - a[i].x;
			if (dr > r) break;
			dq = (int32_t)a[j].y - (int32_t)a[i].y;
			if (dq > r || dq < 0) continue;
			a[j].y |= MG_SEED_KEPT;
			a[i].y |= MG_SEED_KEPT;
			break;
		}
	}
	for (i = j = 0; i < n_a; ++i)
		if (a[i].y & MG_SEED_KEPT)
			a[j++] = a[i];
	return j;
}

// Assembly:
testq %rdi, %rdi
jle 0x1a24a7
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movabsq $0x80000000000, %r13    # imm = 0x80000000000
movslq %edx, %rax
leaq 0x8(%rsi), %r8
movl $0x1, %r9d
xorl %r10d, %r10d
movq %r10, %r11
shlq $0x4, %r11
addq %rsi, %r11
movq %r8, %rbx
movq %r9, %r14
decq %r14
jle 0x1a2395
movq (%r11), %r15
subq -0x18(%rbx), %r15
cmpq %rax, %r15
jg 0x1a2395
movl 0x8(%r11), %ebp
movq -0x10(%rbx), %r15
addq $-0x10, %rbx
subl %r15d, %ebp
sets %r12b
cmpl %edx, %ebp
setg %bpl
orb %r12b, %bpl
jne 0x1a235c
orq %r13, %r15
movq %r15, (%rbx)
orq %r13, 0x8(%r11)
incq %r10
incq %r9
addq $0x10, %r8
cmpq %rdi, %r10
jne 0x1a234c
testq %rdi, %rdi
jle 0x1a249a
movq %rdi, %r8
shlq $0x4, %r8
addq %rsi, %r8
addq $0x8, %r8
xorl %r9d, %r9d
movq %rdi, %r11
movq %rsi, -0x18(%rsp)
movq %rdi, -0x10(%rsp)
leaq -0x1(%r11), %rbx
movq %rbx, -0x8(%rsp)
shlq $0x4, %rbx
movq 0x8(%rsi,%rbx), %r14
testq %r13, %r14
setne %bpl
cmpq %rdi, %r11
setge %r15b
orb %bpl, %r15b
jne 0x1a243f
addq -0x18(%rsp), %rbx
movq (%rbx), %r12
movq %r8, %r15
movq %r9, %r13
movq -0x8(%r15), %rbp
subq %r12, %rbp
cmpq %rax, %rbp
jg 0x1a243f
movq (%r15), %rbp
movl %ebp, %ecx
subl %r14d, %ecx
sets %r10b
cmpl %edx, %ecx
setg %cl
orb %r10b, %cl
je 0x1a242b
addq $0x10, %r15
decq %r13
jne 0x1a23fe
jmp 0x1a243f
movabsq $0x80000000000, %rcx    # imm = 0x80000000000
orq %rcx, %rbp
movq %rbp, (%r15)
orq %rcx, 0x8(%rbx)
incq %r9
addq $-0x10, %r8
cmpq $0x1, %r11
movq -0x18(%rsp), %rsi
movq -0x10(%rsp), %rdi
movabsq $0x80000000000, %r13    # imm = 0x80000000000
movq -0x8(%rsp), %r11
jg 0x1a23cb
testq %rdi, %rdi
jle 0x1a249a
leaq 0x8(%rsi), %rdx
xorl %eax, %eax
testq %r13, (%rdx)
je 0x1a248f
leaq -0x8(%rdx), %rcx
leaq 0x1(%rax), %r8
shlq $0x4, %rax
movups (%rcx), %xmm0
movups %xmm0, (%rsi,%rax)
movq %r8, %rax
addq $0x10, %rdx
decq %rdi
jne 0x1a2474
jmp 0x1a249c
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/inter.cpp
// Function: mg_update_anchors(int, mg128_t*, int, int const*)
void mg_update_anchors(int32_t n_a, mg128_t *a, int32_t n, const int32_t *mini_pos)
{
	int32_t st, j, k;
	if (n_a <= 0) return;
	st = get_mini_idx(&a[0], n, mini_pos);
	assert(st >= 0);
	for (k = 0, j = st; j < n && k < n_a; ++j)
		if ((int32_t)a[k].y == mini_pos[j])
			a[k].x = (uint64_t)j << 32 | (a[k].x & 0xffffffffU), ++k;
	assert(k == n_a);
}

// Assembly:
pushq %rbx
testl %edi, %edi
jle 0x1a329b
testl %edx, %edx
jle 0x1a3224
movl 0x8(%rsi), %r8d
leal -0x1(%rdx), %r10d
xorl %r9d, %r9d
movslq %r9d, %r11
movslq %r10d, %rax
addq %r11, %rax
shrq %rax
cmpl %r8d, (%rcx,%rax,4)
jge 0x1a3219
leal 0x1(%rax), %r9d
jmp 0x1a321f
jle 0x1a3243
leal -0x1(%rax), %r10d
cmpl %r10d, %r9d
jle 0x1a3201
leaq 0x9cad1(%rip), %rdi     # 0x23fcfc
leaq 0x9ca29(%rip), %rsi     # 0x23fc5b
leaq 0x9cacb(%rip), %rcx     # 0x23fd04
movl $0x3dc, %edx            # imm = 0x3DC
callq 0x2110
testl %eax, %eax
js 0x1a3224
xorl %r8d, %r8d
cmpl %edx, %eax
jge 0x1a3296
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %rax, %r9
shlq $0x20, %r9
xorl %r8d, %r8d
movabsq $0x100000000, %r10      # imm = 0x100000000
movslq %r8d, %r11
shlq $0x4, %r11
movl (%rcx,%rax,4), %ebx
cmpl 0x8(%rsi,%r11), %ebx
jne 0x1a3287
addq %rsi, %r11
movl (%r11), %ebx
addq %r9, %rbx
movq %rbx, (%r11)
incl %r8d
incq %rax
cmpl %edx, %eax
jge 0x1a3296
addq %r10, %r9
cmpl %edi, %r8d
jl 0x1a3267
cmpl %edi, %r8d
jne 0x1a329d
popq %rbx
retq
leaq 0x9caa5(%rip), %rdi     # 0x23fd49
leaq 0x9c9b0(%rip), %rsi     # 0x23fc5b
leaq 0x9ca52(%rip), %rcx     # 0x23fd04
movl $0x3e0, %edx            # imm = 0x3E0
callq 0x2110
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/inter.cpp
// Function: transfor_icoord(long, long, long, long, unsigned char, long, long, int*, int*, int*, int*)
void transfor_icoord(const int64_t iqs, const int64_t iqe, const int64_t irs, const int64_t ire, const uint8_t rev, 
const int64_t qlen, const int64_t rlen, int32_t *r_qs, int32_t *r_qe, int32_t *r_rs, int32_t *r_re)
{
    int64_t qs, qe, rs, re, qtail, rtail;
    qs = iqs; qe = iqe - 1; rs = irs; re = ire - 1;
    if(rev) {
        rs = rlen - ire; re = rlen - irs - 1;
    }
    
    if(qs <= rs) {
        rs -= qs; qs = 0;
    } else {
        qs -= rs; rs = 0;
    }

    qtail = qlen - qe - 1; rtail = rlen - re - 1;
    if(qtail <= rtail) {
        qe = qlen - 1; re += qtail;
    }
    else
    {
        re = rlen - 1; qe += rtail; 
    }

	if(r_qs) (*r_qs) = qs; if(r_qe) (*r_qe) = qe + 1;
	if(r_rs) (*r_rs) = rs; if(r_re) (*r_re) = re + 1;
    if(rev) {
        if(r_rs) (*r_rs) = rlen - re - 1; 
		if(r_re) (*r_re) = rlen - rs;
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq 0x28(%rsp), %rax
movq %rax, %r10
subq %rcx, %r10
decq %rcx
movq %rdx, %r14
notq %r14
addq %rax, %r14
testl %r8d, %r8d
cmoveq %rdx, %r10
cmoveq %rcx, %r14
xorl %ebx, %ebx
movq %r10, %rdx
subq %rdi, %rdx
movl $0x0, %ecx
cmovgeq %rdx, %rcx
movq 0x38(%rsp), %r11
movq %r9, %r15
subq %rsi, %r15
movq %r14, %r12
notq %r12
addq %rax, %r12
addq %r15, %r14
leaq -0x1(%rax), %rdx
addq %r12, %rsi
cmpq %r12, %r15
cmovleq %r14, %rdx
movq 0x30(%rsp), %r14
cmovleq %r9, %rsi
testq %r14, %r14
je 0x1a4830
movl %edi, %r9d
subl %r10d, %r9d
cmpq %rdi, %r10
cmovll %r9d, %ebx
movl %ebx, (%r14)
movq 0x40(%rsp), %rdi
testq %r11, %r11
je 0x1a483d
movl %esi, (%r11)
movq 0x48(%rsp), %rsi
testq %rdi, %rdi
je 0x1a4849
movl %ecx, (%rdi)
testq %rsi, %rsi
je 0x1a4855
leal 0x1(%rdx), %r9d
movl %r9d, (%rsi)
testb %r8b, %r8b
je 0x1a486e
testq %rdi, %rdi
je 0x1a4865
notl %edx
addl %eax, %edx
movl %edx, (%rdi)
testq %rsi, %rsi
je 0x1a486e
subl %ecx, %eax
movl %eax, (%rsi)
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/inter.cpp
// Function: transfor_coord(mg_lchain_t*, long, long, int*, int*, int*, int*)
void transfor_coord(mg_lchain_t *ri, const int64_t qlen, const int64_t rlen, 
int32_t *r_qs, int32_t *r_qe, int32_t *r_rs, int32_t *r_re)
{
    int64_t qs, qe, rs, re, qtail, rtail;
    qs = ri->qs; qe = ri->qe - 1; rs = ri->rs; re = ri->re - 1;
    if(ri->v&1) {
        rs = rlen - ri->re; re = rlen - ri->rs - 1;
    }
    
    if(qs <= rs) {
        rs -= qs; qs = 0;
    } else {
        qs -= rs; rs = 0;
    }

    qtail = qlen - qe - 1; rtail = rlen - re - 1;
    if(qtail <= rtail) {
        qe = qlen - 1; re += qtail;
    }
    else
    {
        re = rlen - 1; qe += rtail; 
    }

	if(r_qs) (*r_qs) = qs; if(r_qe) (*r_qe) = qe + 1;
	if(r_rs) (*r_rs) = rs; if(r_re) (*r_re) = re + 1;
    if(ri->v&1) {
        if(r_rs) (*r_rs) = rlen - re - 1; 
		if(r_re) (*r_re) = rlen - rs;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movslq 0xc(%rdi), %rax
movslq 0x10(%rdi), %r10
movq %rdx, %r11
subq %r10, %r11
decq %r10
movq %rax, %r15
notq %r15
addq %rdx, %r15
testb $0x1, 0x8(%rdi)
cmoveq %rax, %r11
movslq 0x14(%rdi), %rbx
cmoveq %r10, %r15
movq %r15, %r12
notq %r12
addq %rdx, %r12
xorl %r14d, %r14d
movq %r11, %r10
subq %rbx, %r10
movl $0x0, %eax
cmovgeq %r10, %rax
movslq 0x18(%rdi), %r13
movq %rsi, %rbp
subq %r13, %rbp
addq %rbp, %r15
leaq -0x1(%rdx), %r10
cmpq %r12, %rbp
cmovleq %r15, %r10
leaq (%r13,%r12), %r15
cmovleq %rsi, %r15
testq %rcx, %rcx
je 0x1a48fa
movl %ebx, %esi
subl %r11d, %esi
cmpq %rbx, %r11
cmovll %esi, %r14d
movl %r14d, (%rcx)
testq %r8, %r8
je 0x1a4902
movl %r15d, (%r8)
movq 0x38(%rsp), %rcx
testq %r9, %r9
je 0x1a490f
movl %eax, (%r9)
testq %rcx, %rcx
je 0x1a491a
leal 0x1(%r10), %esi
movl %esi, (%rcx)
testb $0x1, 0x8(%rdi)
je 0x1a4938
testq %r9, %r9
je 0x1a492f
notl %r10d
leal (%rdx,%r10), %esi
movl %esi, (%r9)
testq %rcx, %rcx
je 0x1a4938
subl %eax, %edx
movl %edx, (%rcx)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/inter.cpp
// Function: get_nn_ov(unsigned int, unsigned int, asg_t const*)
int64_t get_nn_ov(const uint32_t v, const uint32_t w, const asg_t *g)
{
	uint32_t i;
	uint32_t nv = asg_arc_n(g, v);
    asg_arc_t *av = asg_arc_a(g, v), *p = NULL;
	for (i = 0; i < nv; i++) {
		if(av[i].del) continue;
		if(av[i].v == w) {
			// o -= av[i].ol;
			p = &(av[i]);
			break;
		}
	}
	return p?p->ol:0;
}

// Assembly:
movq 0x28(%rdx), %rax
movl %edi, %ecx
movq (%rax,%rcx,8), %rax
testl %eax, %eax
je 0x1a498c
movq 0x8(%rdx), %rcx
movq %rax, %rdx
shrq $0x20, %rdx
movl %eax, %eax
leaq (%rdx,%rdx,2), %rdx
leaq (%rcx,%rdx,8), %rcx
addq $0xc, %rcx
shlq $0x3, %rax
leaq (%rax,%rax,2), %rdx
xorl %edi, %edi
movslq (%rcx,%rdi), %rax
testq %rax, %rax
js 0x1a4983
cmpl %esi, -0x4(%rcx,%rdi)
je 0x1a498e
addq $0x18, %rdi
cmpq %rdi, %rdx
jne 0x1a4974
xorl %eax, %eax
retq