// File: chhylp123[P]hifiasm/Assembly.cpp
// Function: worker_ov_utg(void*, long, int)
static void worker_ov_utg(void *data, long i, int tid)
{
	ha_ovec_buf_t *b = ((ha_ovec_buf_t**)data)[tid];
    if(b->ua->a[i].len == 0) return;

    ha_get_ug_candidates(b->ab, i, &(b->ua->a[i]), b->ua, &b->olist, &b->clist, 
    0.3, asm_opt.polyploidy*5, 0, &(b->k_flag), &b->r_buf, ha_flt_tab, ha_idx,
    &(b->tmp_region), NULL, /**0.3**/0);
    
	overlap_region_sort_y_id(b->olist.list, b->olist.length);
	ma_hit_sort_tn(R_INF.paf[i].buffer, R_INF.paf[i].length);
	ma_hit_sort_tn(R_INF.reverse_paf[i].buffer, R_INF.reverse_paf[i].length);

	update_overlaps(&b->olist, &(R_INF.paf[i]), &b->self_read, &b->ovlp_read, 1, 1);
	update_overlaps(&b->olist, &(R_INF.reverse_paf[i]), &b->self_read, &b->ovlp_read, 2, 0);
	///recover missing exact overlaps
	update_exact_overlaps(&b->olist, &b->self_read, &b->ovlp_read);

	///Final_phasing(&overlap_list, &cigarline, &g_read, &overlap_read, c2n);
	push_final_overlaps(&(R_INF.paf[i]), R_INF.reverse_paf, &b->olist, 1);
	push_final_overlaps(&(R_INF.reverse_paf[i]), R_INF.reverse_paf, &b->olist, 2);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdi, -0x28(%rbp)
movq %rsi, -0x30(%rbp)
movl %edx, -0x34(%rbp)
movq -0x28(%rbp), %rax
movslq -0x34(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq 0x12248(%rax), %rax
movq 0x10(%rax), %rax
imulq $0x28, -0x30(%rbp), %rcx
addq %rcx, %rax
movl (%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpl $0x0, %eax
jne 0x1b032
jmp 0x1b254
movq -0x40(%rbp), %rax
movq 0xe0(%rax), %rdi
movq -0x30(%rbp), %rsi
movq -0x40(%rbp), %rax
movq 0x12248(%rax), %rax
movq 0x10(%rax), %rdx
imulq $0x28, -0x30(%rbp), %rax
addq %rax, %rdx
movq -0x40(%rbp), %rax
movq 0x12248(%rax), %rcx
movq -0x40(%rbp), %r8
addq $0xa0, %r8
movq -0x40(%rbp), %r9
addq $0x48, %r9
leaq 0x3a977b(%rip), %rax    # 0x3c47f8
imull $0x5, 0x1bc(%rax), %r15d
movq -0x40(%rbp), %r14
addq $0x12180, %r14          # imm = 0x12180
movq -0x40(%rbp), %rbx
addq $0x12160, %rbx          # imm = 0x12160
leaq 0x3aa42e(%rip), %rax    # 0x3c54d0
movq (%rax), %r11
leaq 0x3aa42c(%rip), %rax    # 0x3c54d8
movq (%rax), %r10
movq -0x40(%rbp), %rax
addq $0x121a0, %rax          # imm = 0x121A0
movsd 0x366887(%rip), %xmm0   # 0x381948
xorl %r12d, %r12d
xorl %r12d, %r12d
xorps %xmm1, %xmm1
movl %r15d, (%rsp)
movl $0x0, 0x8(%rsp)
movq %r14, 0x10(%rsp)
movq %rbx, 0x18(%rsp)
movq %r11, 0x20(%rsp)
movq %r10, 0x28(%rsp)
movq %rax, 0x30(%rsp)
movq $0x0, 0x38(%rsp)
callq 0x1a2a80
movq -0x40(%rbp), %rax
movq 0xa0(%rax), %rdi
movq -0x40(%rbp), %rax
movq 0xb0(%rax), %rsi
callq 0x1dfd0
movq 0x3aa229(%rip), %rax    # 0x3c5348
imulq $0x18, -0x30(%rbp), %rcx
addq %rcx, %rax
movq (%rax), %rdi
movq 0x3aa217(%rip), %rax    # 0x3c5348
imulq $0x18, -0x30(%rbp), %rcx
addq %rcx, %rax
movl 0xc(%rax), %eax
movl %eax, %esi
callq 0xcd020
movq 0x3aa206(%rip), %rax    # 0x3c5350
imulq $0x18, -0x30(%rbp), %rcx
addq %rcx, %rax
movq (%rax), %rdi
movq 0x3aa1f4(%rip), %rax    # 0x3c5350
imulq $0x18, -0x30(%rbp), %rcx
addq %rcx, %rax
movl 0xc(%rax), %eax
movl %eax, %esi
callq 0xcd020
movq -0x40(%rbp), %rdi
addq $0xa0, %rdi
movq 0x3aa1c8(%rip), %rsi    # 0x3c5348
imulq $0x18, -0x30(%rbp), %rax
addq %rax, %rsi
movq -0x40(%rbp), %rdx
addq $0x8, %rdx
movq -0x40(%rbp), %rcx
addq $0x28, %rcx
movl $0x1, %r9d
movl %r9d, %r8d
callq 0x17dd0
movq -0x40(%rbp), %rdi
addq $0xa0, %rdi
movq 0x3aa198(%rip), %rsi    # 0x3c5350
imulq $0x18, -0x30(%rbp), %rax
addq %rax, %rsi
movq -0x40(%rbp), %rdx
addq $0x8, %rdx
movq -0x40(%rbp), %rcx
addq $0x28, %rcx
movl $0x2, %r8d
xorl %r9d, %r9d
callq 0x17dd0
movq -0x40(%rbp), %rdi
addq $0xa0, %rdi
movq -0x40(%rbp), %rsi
addq $0x8, %rsi
movq -0x40(%rbp), %rdx
addq $0x28, %rdx
callq 0x18d50
movq 0x3aa143(%rip), %rdi    # 0x3c5348
imulq $0x18, -0x30(%rbp), %rax
addq %rax, %rdi
movq 0x3aa13c(%rip), %rsi    # 0x3c5350
movq -0x40(%rbp), %rdx
addq $0xa0, %rdx
movl $0x1, %ecx
callq 0x14520
movq 0x3aa120(%rip), %rdi    # 0x3c5350
imulq $0x18, -0x30(%rbp), %rax
addq %rax, %rdi
movq 0x3aa111(%rip), %rsi    # 0x3c5350
movq -0x40(%rbp), %rdx
addq $0xa0, %rdx
movl $0x2, %ecx
callq 0x14520
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nopw %cs:(%rax,%rax)