// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/inter.cpp
// Function: cal_exact_batch(overlap_region*, ul_ov_t*, unsigned long, long, unsigned long*, unsigned long*, unsigned long*, unsigned long*, unsigned long*, unsigned long*, ma_ug_t*)
int64_t cal_exact_batch(overlap_region *z, ul_ov_t *sa, uint64_t sn, int64_t ylen, uint64_t *q0l, uint64_t *t0l, uint64_t *e0l, uint64_t *q1l, uint64_t *t1l, uint64_t *e1l, ma_ug_t *ug)
{
	int64_t wn = z->w_list.n, wk, xk, yk, is_t, is_f, err0, err1, tot, mask_win = 0; window_list *m; bit_extz_t ez; 
    int64_t qs, qe, ts, te, rev = !!(z->y_pos_strand), qoff, toff, elen, sube;
	tot = z->non_homopolymer_errors;
	if(!tot) {
		(*q0l) = (*q1l) = z->x_pos_e+1-z->x_pos_s;
		(*t0l) = (*t1l) = z->y_pos_e+1-z->y_pos_s;
		(*e0l) = (*e1l) = z->x_pos_e+1-z->x_pos_s;
		return 0;
	}
	(*q0l) = (*t0l) = (*e0l) = (*q1l) = (*t1l) = (*e1l) = (uint64_t)-1;
	wk = xk = yk = -1; if(!wn) return INT32_MAX;

	///forward
	(*q0l) = (*t0l) = (*e0l) = err0 = 0;
	wk = 0; xk = z->w_list.a[wk].x_start; yk = z->w_list.a[wk].y_start; is_t = 0;
	if((xk == z->x_pos_s) && (yk == z->y_pos_s)) is_t = 1;
	if((!is_t) && (sn > 0)) {///if the flanking unmapped regions could be masked
		qs = z->x_pos_s; qe = xk; 
		if(!rev) {
			ts = z->y_pos_s; te = yk;
		} else {
			ts = ylen - yk; te = ylen - z->y_pos_s; 
		}
		is_t = is_mask_err_full(sa, sn, qs, qe, ts, te);
		if(is_t) {
			(*q0l) += qe - qs; (*t0l) += te - ts; (*e0l) = 0;
		}
	}
	if(is_t) {
		for (; wk < wn; wk++) {		
			m = &(z->w_list.a[wk]); 
			qs = m->x_start; qe = m->x_end+1;
			if(!rev) {
				ts = m->y_start; te = m->y_end+1;
			} else {
				ts = ylen-(m->y_end+1); te = ylen-m->y_start;
			}

			if((is_ualn_win((*m))) || ((is_est_aln((*m))) && (m->error > 0))) {///unmapped 				
				if(is_mask_err_full(sa, sn, qs, qe, ts, te)) {
					(*q0l) += qe - qs; (*t0l) += te - ts; (*e0l) = 0; mask_win = 1;
					continue;
				}
				break;
			} 
			if(m->error == 0) {///an exactly matched window
				(*q0l) += qe - qs; (*t0l) += te - ts; (*e0l) += qe - qs;
				continue;
			}
			set_bit_extz_t(ez, (*z), wk); 
			is_f = cal_exact_len(&ez, rev, sa, sn, ylen, &qoff, &toff, &elen, &sube, 0);
			(*q0l) += qoff; (*t0l) += toff; err0 += sube;
			///exactly match
			if(elen == qoff && elen == toff) (*e0l) += elen;
			else (*e0l) = elen;
			if(!is_f) break;
		}
	}


	///backward
	(*q1l) = (*t1l) = (*e1l) = err1 = 0;
	wk = wn-1; xk = z->w_list.a[wk].x_end+1; yk = z->w_list.a[wk].y_end+1; is_t = 0;
	if((xk == (z->x_pos_e+1)) && (yk == (z->y_pos_e+1))) is_t = 1;
	if((!is_t) && (sn > 0)) {///if the flanking unmapped regions could be masked
		qs = xk; qe = z->x_pos_e+1;
		if(!rev) {
			ts = yk; te = z->y_pos_e+1;
		} else {
			ts = ylen-(z->y_pos_e+1); te = ylen-yk;
		}
		is_t = is_mask_err_full(sa, sn, qs, qe, ts, te);
        if(is_t) {
            (*q1l) += qe - qs; (*t1l) += te - ts; (*e1l) = 0;
        }
	}
	if(is_t) {
		for (; wk >= 0; wk--) {
			m = &(z->w_list.a[wk]); 
			qs = m->x_start; qe = m->x_end+1;
			if(!rev) {
				ts = m->y_start; te = m->y_end+1;
			} else {
				ts = ylen-(m->y_end+1); te = ylen-m->y_start;
			}

			if((is_ualn_win((*m))) || ((is_est_aln((*m))) && (m->error > 0))) {///unmapped 				
				if(is_mask_err_full(sa, sn, qs, qe, ts, te)) {
					(*q1l) += qe - qs; (*t1l) += te - ts; (*e1l) = 0; mask_win = 1;
					continue;
				}
				break;
			} 
			if(m->error == 0) {///an exactly matched window
				(*q1l) += qe - qs; (*t1l) += te - ts; (*e1l) += qe - qs;
				continue;
			}
			set_bit_extz_t(ez, (*z), wk); 
			is_f = cal_exact_len(&ez, rev, sa, sn, ylen, &qoff, &toff, &elen, &sube, 1);
			(*q1l) += qoff; (*t1l) += toff; err1 += sube;
			///exactly match
			if(elen == qoff && elen == toff) (*e1l) += elen;
			else (*e1l) = elen;
			if(!is_f) break;
		}
	}

	if((*q0l) >= (z->x_pos_e+1-z->x_pos_s) && (*t0l) >= (z->y_pos_e+1-z->y_pos_s)) {
		// if((!(((*q0l) == (*q1l)) && ((*t0l) == (*t1l)) && (err0 == err1)))/** || (!(err0 == tot))**/) {
		// 	fprintf(stderr, "[M::%s]\tutg%.6u%c\txl::%u\tx::[%u,\t%u)\t%c\tutg%.6u%c\tyl::%u\ty::[%u,\t%u)\terr::%u\twn::%u\n", 
        //     __func__, 
		// 	z->x_id+1, "lc"[ug->u.a[z->x_id].circ], ug->u.a[z->x_id].len, z->x_pos_s, z->x_pos_e+1,
		// 	"+-"[z->y_pos_strand],
		// 	z->y_id+1, "lc"[ug->u.a[z->y_id].circ], ug->u.a[z->y_id].len, z->y_pos_s, z->y_pos_e+1,
		// 	z->non_homopolymer_errors, (uint32_t)z->w_list.n);
		// 	uint64_t k;
		// 	for (k = 0; k < z->w_list.n; k++) {
		// 		m = &(z->w_list.a[k]);
		// 		fprintf(stderr, "k::%ld[M::%s]\tutg%.6u%c\twx::[%u,\t%u)\t%c\tutg%.6u%c\twy::[%u,\t%u)\terr::%d\tualn::%u\test::%u\n", k, __func__, 
		// 		z->x_id+1, "lc"[ug->u.a[z->x_id].circ], m->x_start, m->x_end+1,
		// 		"+-"[z->y_pos_strand], 
		// 		z->y_id+1, "lc"[ug->u.a[z->y_id].circ], m->y_start, m->y_end+1, m->error, 
		// 		(is_ualn_win((*m))), (is_est_aln((*m))));
		// 	}
		// 	fprintf(stderr, "[M::%s]\tutg%.6ul\tutg%.6ul\terr0::%ld\terr1::%ld\ttot::%ld\n", __func__, 
		// 	z->x_id+1, z->y_id+1, err0, err1, tot);
		// 	fprintf(stderr, "[M::%s]\tutg%.6ul\tq0l::%lu\tt0l::%lu\te0l::%lu\tutg%.6ul\tq1l::%lu\tt1l::%lu\te1l::%lu\n", __func__, 
		// 		z->x_id+1, *q0l, *t0l, *e0l, z->y_id+1, *q1l, *t1l, *e1l);
		// }
		assert(((*q0l) == (*q1l)) && ((*t0l) == (*t1l)) && (err0 == err1));
		assert((mask_win) || (err0 == tot));
		return 0;
	}

	// if(!(err0+err1 < tot)) {
	// 	fprintf(stderr, "[M::%s]\tutg%.6ul\tutg%.6ul\terr0::%ld\terr1::%ld\ttot::%ld\n", __func__, 
	// 	z->x_id+1, z->y_id+1, err0, err1, tot);
	// 	fprintf(stderr, "[M::%s]\tutg%.6ul\tq0l::%lu\tt0l::%lu\te0l::%lu\tutg%.6ul\tq1l::%lu\tt1l::%lu\te1l::%lu\n", __func__, 
	// 		z->x_id+1, *q0l, *t0l, *e0l, z->y_id+1, *q1l, *t1l, *e1l);
	// }
	
	assert(err0+err1 < tot);
	return tot-(err0+err1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x158, %rsp            # imm = 0x158
movq %rcx, %r12
movq %rdx, %rbp
movq %rsi, 0x18(%rsp)
movq 0x1a8(%rsp), %r11
movq 0x1a0(%rsp), %rdx
movq 0x198(%rsp), %rsi
movq 0x190(%rsp), %r14
movl 0x1c(%rdi), %eax
movq $0x0, 0x40(%rsp)
movl %eax, 0x4(%rsp)
testl %eax, %eax
setne %r10b
movl 0x30(%rdi), %ecx
testq %rcx, %rcx
je 0x1c118e
movq 0x48(%rdi), %rbx
movq $-0x1, %rax
movq %rax, (%r11)
movq %rax, (%rdx)
movq %rax, (%rsi)
movq %rax, (%r14)
movq %rax, (%r9)
movq %rax, (%r8)
movq %rbx, 0x20(%rsp)
testq %rbx, %rbx
je 0x1c11b7
movq %rcx, 0x68(%rsp)
xorl %esi, %esi
movq %rsi, (%r14)
movq %rsi, (%r9)
movq %rsi, (%r8)
movq 0x58(%rdi), %r15
movslq (%r15), %rdx
movslq 0x8(%r15), %rax
movl 0x4(%rdi), %ebx
movb $0x1, %r11b
movq %rdx, %rcx
movq %rbx, 0x78(%rsp)
subq %rbx, %rcx
jne 0x1c1149
movl 0x14(%rdi), %r11d
xorl %esi, %esi
cmpq %r11, %rax
setne %r11b
sete %sil
movq 0x40(%rsp), %rbx
movb %r10b, %bl
movq %rbx, 0x40(%rsp)
testq %rbp, %rbp
setne 0x3(%rsp)
je 0x1c1241
testb %r11b, %r11b
movq 0x190(%rsp), %r11
je 0x1c1249
cmpl $0x0, 0x4(%rsp)
je 0x1c11c1
movq %r12, %rsi
subq %rax, %rsi
movl 0x14(%rdi), %r10d
movq %r12, %rax
subq %r10, %rax
jmp 0x1c11c4
movl 0x8(%rdi), %eax
subl 0x4(%rdi), %eax
incl %eax
movq %rax, (%rsi)
movq %rax, (%r8)
movl 0x18(%rdi), %ecx
subl 0x14(%rdi), %ecx
incl %ecx
movq %rcx, (%rdx)
movq %rcx, (%r9)
movq %rax, (%r11)
movq %rax, (%r14)
xorl %eax, %eax
jmp 0x1c18e3
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
jmp 0x1c18e3
movl 0x14(%rdi), %esi
movq %rbp, %r14
negq %r14
movq 0x18(%rsp), %r10
leaq 0x14(%r10), %r13
movb $0x1, %bl
movl $0x1, %r10d
movq 0x78(%rsp), %r11
cmpl %r11d, -0x10(%r13)
ja 0x1c1201
movl -0xc(%r13), %r11d
cmpq %rdx, %r11
jb 0x1c1201
movl -0x4(%r13), %r11d
cmpq %r11, %rsi
jb 0x1c1201
movl (%r13), %r11d
cmpq %r11, %rax
jbe 0x1c121b
cmpq %rbp, %r10
setb %bl
leaq (%r14,%r10), %r11
incq %r11
incq %r10
addq $0x1c, %r13
cmpq $0x1, %r11
jne 0x1c11db
testb $0x1, %bl
je 0x1c123f
movq %rcx, (%r8)
subq %rsi, %rax
addq %rax, (%r9)
movq 0x190(%rsp), %r11
movq $0x0, (%r11)
movl $0x1, %esi
jmp 0x1c1249
xorl %esi, %esi
movq 0x190(%rsp), %r11
movq %r8, 0x38(%rsp)
movq %rdi, 0x10(%rsp)
movq %r9, 0x30(%rsp)
cmpq $0x0, 0x20(%rsp)
setg %al
andb %sil, %al
cmpb $0x1, %al
jne 0x1c14e5
movq %rbp, %rbx
negq %rbx
movq 0x18(%rsp), %rax
leaq 0x14(%rax), %r14
movq $0x0, 0x28(%rsp)
xorl %r13d, %r13d
movq $0x0, 0x8(%rsp)
movq %r13, %rdi
shlq $0x5, %rdi
leaq (%r15,%rdi), %r8
cmpl $0x0, 0x4(%rsp)
je 0x1c12b8
movslq 0xc(%r8), %rax
notq %rax
addq %r12, %rax
movslq 0x8(%r8), %rdx
movq %r12, %rcx
subq %rdx, %rcx
jmp 0x1c12c3
movslq 0x8(%r8), %rax
movslq 0xc(%r8), %rcx
incq %rcx
movslq 0x4(%r15,%rdi), %rdx
incq %rdx
movl (%r15,%rdi), %r9d
movslq %r9d, %rsi
movzwl 0x14(%r8), %r10d
cmpl $0x7fff, %r10d          # imm = 0x7FFF
jne 0x1c1308
cmpl $0x0, 0x1c(%r8)
jne 0x1c12ef
cmpw $0x0, 0x12(%r8)
js 0x1c131d
movzwl %r10w, %r11d
cmpl $0x7fff, %r11d          # imm = 0x7FFF
movq 0x190(%rsp), %r11
je 0x1c13a4
testw %r10w, %r10w
jle 0x1c13a4
cmpl $0x0, 0x1c(%r8)
jne 0x1c13a4
movb 0x3(%rsp), %dil
testq %rbp, %rbp
je 0x1c1373
movl $0x1, %r8d
movq %r14, %r9
movb 0x3(%rsp), %dil
movl -0x10(%r9), %r10d
cmpq %rsi, %r10
ja 0x1c1358
movl -0xc(%r9), %r10d
cmpq %rdx, %r10
jb 0x1c1358
movl -0x4(%r9), %r10d
cmpq %r10, %rax
jb 0x1c1358
movl (%r9), %r10d
cmpq %r10, %rcx
jbe 0x1c1373
cmpq %rbp, %r8
setb %dil
leaq (%rbx,%r8), %r10
incq %r10
incq %r8
addq $0x1c, %r9
cmpq $0x1, %r10
jne 0x1c1335
testb $0x1, %dil
je 0x1c14f7
subq %rsi, %rdx
movq 0x38(%rsp), %rsi
addq %rdx, (%rsi)
subq %rax, %rcx
movq 0x30(%rsp), %rax
addq %rcx, (%rax)
movl $0x1, %eax
movq %rax, 0x28(%rsp)
xorl %edx, %edx
jmp 0x1c14b1
testw %r10w, %r10w
je 0x1c1498
movl 0x18(%r15,%rdi), %eax
addq %rax, %rax
movq 0x10(%rsp), %rcx
addq 0x70(%rcx), %rax
movq %rax, 0x138(%rsp)
movl 0x1c(%r15,%rdi), %eax
movq %rax, 0x130(%rsp)
movq %rax, 0x128(%rsp)
movl %r9d, 0x9c(%rsp)
movl 0x4(%r15,%rdi), %eax
movl %eax, 0xa0(%rsp)
movl 0x8(%r15,%rdi), %eax
movl %eax, 0x90(%rsp)
movl 0xc(%r15,%rdi), %eax
movl %eax, 0x94(%rsp)
movswl 0x14(%r15,%rdi), %eax
movl %eax, 0xac(%rsp)
movl %eax, 0xa8(%rsp)
leaq 0x80(%rsp), %rdi
movq 0x40(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq %rbp, %rcx
movq %r12, %r8
leaq 0x60(%rsp), %r9
pushq $0x0
leaq 0x50(%rsp), %rax
pushq %rax
leaq 0x60(%rsp), %rax
pushq %rax
leaq 0x70(%rsp), %rax
pushq %rax
callq 0x1c0d6c
addq $0x20, %rsp
movq 0x60(%rsp), %rdx
movq 0x38(%rsp), %rcx
addq %rdx, (%rcx)
movq 0x58(%rsp), %rsi
movq 0x30(%rsp), %rcx
addq %rsi, (%rcx)
movq 0x50(%rsp), %rcx
xorq %rcx, %rdx
movq %rcx, %rdi
xorq %rsi, %rdi
orq %rdx, %rdi
jne 0x1c14b6
movq 0x190(%rsp), %r11
movq (%r11), %rdx
addq %rdx, %rcx
movq 0x8(%rsp), %rdx
jmp 0x1c14c3
subq %rsi, %rdx
movq 0x38(%rsp), %rsi
addq %rdx, (%rsi)
subq %rax, %rcx
movq 0x30(%rsp), %rax
addq %rcx, (%rax)
addq (%r11), %rdx
movq %rdx, (%r11)
jmp 0x1c14d5
movq 0x8(%rsp), %rdx
movq 0x190(%rsp), %r11
addq 0x48(%rsp), %rdx
movq %rdx, 0x8(%rsp)
movq %rcx, (%r11)
testq %rax, %rax
je 0x1c14f7
incq %r13
cmpq 0x20(%rsp), %r13
jne 0x1c1290
jmp 0x1c14f7
movq $0x0, 0x8(%rsp)
movq $0x0, 0x28(%rsp)
xorl %edx, %edx
movq 0x1a8(%rsp), %rax
movq %rdx, (%rax)
movq 0x1a0(%rsp), %rbx
movq %rdx, (%rbx)
movq 0x198(%rsp), %r13
movq %rdx, (%r13)
movq 0x20(%rsp), %rax
leaq -0x1(%rax), %r14
movq %r14, %rcx
shlq $0x5, %rcx
movslq 0x4(%r15,%rcx), %rax
incq %rax
movslq 0xc(%r15,%rcx), %rdi
incq %rdi
movq 0x10(%rsp), %rcx
movl 0x8(%rcx), %ecx
incl %ecx
movb $0x1, %sil
movq %rcx, 0x70(%rsp)
subq %rax, %rcx
jne 0x1c1568
movq 0x10(%rsp), %rdx
movl 0x18(%rdx), %esi
incl %esi
xorl %edx, %edx
cmpq %rsi, %rdi
setne %sil
sete %dl
testq %rbp, %rbp
je 0x1c161f
testb %sil, %sil
je 0x1c161f
movq 0x10(%rsp), %rdx
movl 0x18(%rdx), %r8d
incl %r8d
movq %r12, %rdx
subq %r8, %rdx
movq %r12, %rsi
subq %rdi, %rsi
cmpl $0x0, 0x4(%rsp)
cmoveq %rdi, %rdx
cmoveq %r8, %rsi
movq %rbp, %rdi
negq %rdi
movq 0x18(%rsp), %r8
addq $0x14, %r8
movb $0x1, %r9b
movl $0x1, %r10d
movl -0x10(%r8), %r11d
cmpq %rax, %r11
ja 0x1c15dc
movq 0x70(%rsp), %r11
cmpl %r11d, -0xc(%r8)
jb 0x1c15dc
movl -0x4(%r8), %r11d
cmpq %r11, %rdx
jb 0x1c15dc
movl (%r8), %r11d
cmpq %r11, %rsi
jbe 0x1c15f7
cmpq %rbp, %r10
setb %r9b
leaq (%rdi,%r10), %r11
incq %r11
incq %r10
addq $0x1c, %r8
cmpq $0x1, %r11
jne 0x1c15b7
testb $0x1, %r9b
je 0x1c161d
movq %rcx, (%r13)
subq %rdx, %rsi
addq %rsi, (%rbx)
movq 0x1a8(%rsp), %rax
movq $0x0, (%rax)
movl $0x1, %edx
jmp 0x1c161f
xorl %edx, %edx
cmpq $0x0, 0x20(%rsp)
setg %al
andb %dl, %al
cmpb $0x1, %al
jne 0x1c18a2
movq %rbp, %r13
negq %r13
movq 0x18(%rsp), %rax
addq $0x14, %rax
movq %rax, 0x20(%rsp)
xorl %ebx, %ebx
movq %r14, %rdi
shlq $0x5, %rdi
leaq (%r15,%rdi), %r8
cmpl $0x0, 0x4(%rsp)
je 0x1c1670
movslq 0xc(%r8), %rax
notq %rax
addq %r12, %rax
movslq 0x8(%r8), %rdx
movq %r12, %rcx
subq %rdx, %rcx
jmp 0x1c167b
movslq 0x8(%r8), %rax
movslq 0xc(%r8), %rcx
incq %rcx
movslq 0x4(%r15,%rdi), %rdx
incq %rdx
movl (%r15,%rdi), %r9d
movslq %r9d, %rsi
movzwl 0x14(%r8), %r10d
cmpl $0x7fff, %r10d          # imm = 0x7FFF
jne 0x1c16b8
cmpl $0x0, 0x1c(%r8)
jne 0x1c16a7
cmpw $0x0, 0x12(%r8)
js 0x1c16cd
movzwl %r10w, %r11d
cmpl $0x7fff, %r11d          # imm = 0x7FFF
je 0x1c1764
testw %r10w, %r10w
jle 0x1c1764
cmpl $0x0, 0x1c(%r8)
jne 0x1c1764
movb 0x3(%rsp), %dil
testq %rbp, %rbp
je 0x1c1725
movl $0x1, %r8d
movq 0x20(%rsp), %r9
movb 0x3(%rsp), %dil
movl -0x10(%r9), %r10d
cmpq %rsi, %r10
ja 0x1c170a
movl -0xc(%r9), %r10d
cmpq %rdx, %r10
jb 0x1c170a
movl -0x4(%r9), %r10d
cmpq %r10, %rax
jb 0x1c170a
movl (%r9), %r10d
cmpq %r10, %rcx
jbe 0x1c1725
cmpq %rbp, %r8
setb %dil
leaq (%r8,%r13), %r10
incq %r10
incq %r8
addq $0x1c, %r9
cmpq $0x1, %r10
jne 0x1c16e7
testb $0x1, %dil
je 0x1c18a4
subq %rsi, %rdx
movq 0x198(%rsp), %rsi
addq %rdx, (%rsi)
subq %rax, %rcx
movq 0x1a0(%rsp), %rax
addq %rcx, (%rax)
movl $0x1, %eax
movq %rax, 0x28(%rsp)
xorl %edx, %edx
movq 0x1a8(%rsp), %rax
jmp 0x1c188d
testw %r10w, %r10w
je 0x1c1866
movl 0x18(%r15,%rdi), %eax
addq %rax, %rax
movq 0x10(%rsp), %rcx
addq 0x70(%rcx), %rax
movq %rax, 0x138(%rsp)
movl 0x1c(%r15,%rdi), %eax
movq %rax, 0x130(%rsp)
movq %rax, 0x128(%rsp)
movl %r9d, 0x9c(%rsp)
movl 0x4(%r15,%rdi), %eax
movl %eax, 0xa0(%rsp)
movl 0x8(%r15,%rdi), %eax
movl %eax, 0x90(%rsp)
movl 0xc(%r15,%rdi), %eax
movl %eax, 0x94(%rsp)
movswl 0x14(%r15,%rdi), %eax
movl %eax, 0xac(%rsp)
movl %eax, 0xa8(%rsp)
leaq 0x80(%rsp), %rdi
movq 0x40(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq %rbp, %rcx
movq %r12, %r8
leaq 0x60(%rsp), %r9
pushq $0x1
leaq 0x50(%rsp), %rax
pushq %rax
leaq 0x60(%rsp), %rax
pushq %rax
leaq 0x70(%rsp), %rax
pushq %rax
callq 0x1c0d6c
addq $0x20, %rsp
movq 0x60(%rsp), %rdx
movq 0x198(%rsp), %rcx
addq %rdx, (%rcx)
movq 0x58(%rsp), %rsi
movq 0x1a0(%rsp), %rcx
addq %rsi, (%rcx)
movq 0x50(%rsp), %rcx
xorq %rcx, %rdx
movq %rcx, %rdi
xorq %rsi, %rdi
movq 0x1a8(%rsp), %rsi
orq %rdx, %rdi
jne 0x1c1857
movq (%rsi), %rdx
addq %rdx, %rcx
addq 0x48(%rsp), %rbx
movq %rcx, (%rsi)
testq %rax, %rax
jne 0x1c1890
jmp 0x1c18a4
subq %rsi, %rdx
movq 0x198(%rsp), %rsi
addq %rdx, (%rsi)
subq %rax, %rcx
movq 0x1a0(%rsp), %rax
addq %rcx, (%rax)
movq 0x1a8(%rsp), %rax
addq (%rax), %rdx
movq %rdx, (%rax)
leaq -0x1(%r14), %rax
testq %r14, %r14
movq %rax, %r14
jg 0x1c1648
jmp 0x1c18a4
xorl %ebx, %ebx
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x70(%rsp), %rcx
subl 0x78(%rsp), %ecx
cmpq %rcx, %rax
jb 0x1c18d4
movq 0x30(%rsp), %rcx
movq (%rcx), %rcx
movq 0x10(%rsp), %rsi
movl 0x18(%rsi), %edx
subl 0x14(%rsi), %edx
incl %edx
cmpq %rdx, %rcx
jae 0x1c18f5
addq 0x8(%rsp), %rbx
movq 0x68(%rsp), %rax
subq %rbx, %rax
jle 0x1c1949
addq $0x158, %rsp            # imm = 0x158
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x198(%rsp), %rdx
cmpq (%rdx), %rax
movq 0x8(%rsp), %rdx
jne 0x1c1968
movq 0x1a0(%rsp), %rax
cmpq (%rax), %rcx
jne 0x1c1968
cmpq %rbx, %rdx
jne 0x1c1968
xorl %eax, %eax
cmpq $0x0, 0x28(%rsp)
jne 0x1c18e3
cmpq 0x68(%rsp), %rdx
je 0x1c18e3
leaq 0x7429c(%rip), %rdi     # 0x235bcd
leaq 0x72053(%rip), %rsi     # 0x23398b
leaq 0x741f3(%rip), %rcx     # 0x235b32
movl $0x2ee3, %edx           # imm = 0x2EE3
callq 0x2110
leaq 0x74299(%rip), %rdi     # 0x235be9
leaq 0x72034(%rip), %rsi     # 0x23398b
leaq 0x741d4(%rip), %rcx     # 0x235b32
movl $0x2eee, %edx           # imm = 0x2EEE
callq 0x2110
leaq 0x74188(%rip), %rdi     # 0x235af7
leaq 0x72015(%rip), %rsi     # 0x23398b
leaq 0x741b5(%rip), %rcx     # 0x235b32
movl $0x2ee2, %edx           # imm = 0x2EE2
callq 0x2110