// File: chhylp123[P]hifiasm/inter.cpp
// Function: update_uovlp_chain_qse(ma_ug_t*, long, long, mg_lchain_t*, long)
void update_uovlp_chain_qse(ma_ug_t *ug, int64_t sidx, int64_t eidx, mg_lchain_t *a, int64_t a_n)
{
	// fprintf(stderr, "******[M::%s::] sidx:%ld, eidx:%ld\n", __func__, sidx, eidx);
	if(eidx - sidx <= 1) return;
	///for ug chains, sidx >= 0 && eidx < a_n
	assert(sidx>=0 && eidx<a_n);
	
	int64_t r_pos[4], q_pos[4];  uint64_t r_srt[4];
	int64_t i, rs, re, prs, pre, ars, are;//qs or qe might be -1, while rs and re should >= 0
	int64_t pqs, pqe, aqs, aqe, fail_s, fail_e;
	if(sidx >= 0) {
		get_u_offset(ug, &(a[sidx]), &r_pos[0], &r_pos[1], &q_pos[0], &q_pos[1]);
	} else {
		get_u_offset(ug, &(a[0]), &r_pos[0], &r_pos[1], &q_pos[0], &q_pos[1]);
	}

	if(eidx < a_n) {
		get_u_offset(ug, &(a[eidx]), &r_pos[2], &r_pos[3], &q_pos[2], &q_pos[3]);
	} else {
		get_u_offset(ug, &(a[a_n-1]), &r_pos[2], &r_pos[3], &q_pos[2], &q_pos[3]);
	}
	prs = r_pos[0]; pre = r_pos[1]; ars = r_pos[2]; are = r_pos[3]; 
	pqs = q_pos[0]; pqe = q_pos[1]; aqs = q_pos[2]; aqe = q_pos[3];
	// fprintf(stderr, "\n[M::%s::] sidx->%ld<r[0]::%ld, r[1]::%ld, q[0]::%ld, q[1]::%ld>, eidx->%ld<r[2]::%ld, r[3]::%ld, q[2]::%ld, q[3]::%ld>\n", __func__, 
	// sidx, r_pos[0], r_pos[1], q_pos[0], q_pos[1], 
	// eidx, r_pos[2], r_pos[3], q_pos[2], q_pos[3]);
	// assert((left_q[0] >= 0 && left_q[1] >= 0) || (right_q[0] >= 0 && right_q[1] >= 0)); ///assert(re >= rs);
	///for ug chains, sidx >= 0 && eidx < a_n
	assert(q_pos[0] >= 0 && q_pos[1] >= 0 && q_pos[2] >= 0 && q_pos[3] >= 0);
	r_srt[0] = r_pos[0]; r_srt[0] <<= 32;
	r_srt[1] = r_pos[1]; r_srt[1] <<= 32; r_srt[1] += 1;
	r_srt[2] = r_pos[2]; r_srt[2] <<= 32; r_srt[2] += 2;
	r_srt[3] = r_pos[3]; r_srt[3] <<= 32; r_srt[3] += 3;
	radix_sort_gfa64(r_srt, r_srt + 4);
	// assert(r_pos[(uint32_t)r_srt[0]] == (r_srt[0]>>32));
	// assert(r_pos[(uint32_t)r_srt[1]] == (r_srt[1]>>32));
	// assert(r_pos[(uint32_t)r_srt[2]] == (r_srt[2]>>32));
	// assert(r_pos[(uint32_t)r_srt[3]] == (r_srt[3]>>32));

	for (i = sidx+1; i < eidx; i++) {
		get_u_offset(ug, &(a[i]), &rs, &re, NULL, NULL);
		// assert(rs >= prs && rs <= ars && re >= pre && re <= are); 
		assert(rs <= re);
		a[i].qs = adjust_utg_chain_qoffset(r_srt, r_pos, q_pos, rs); fail_s = 1;
		a[i].qe = adjust_utg_chain_qoffset(r_srt, r_pos, q_pos, re); fail_e = 1;
		if(a[i].qs >= 0 && a[i].qs >= pqs && a[i].qs <= aqs) fail_s = 0;
		if(a[i].qe >= 0 && a[i].qe >= pqe && a[i].qe <= aqe) fail_e = 0;
		if(a[i].qs > a[i].qe) fail_s = fail_e = 1;

		if(fail_s || fail_e) {
			//  if(re >= pre && are >= pre && re <= are) {///aqe >= pqe is always true
			// 	a[i].qe = pqe + get_offset_adjust(re-pre, are-pre, aqe-pqe);///first priority
			//  } else {///abnormal coordinates
			// 	pd = ((re >= pre)?(re-pre):(pre-re));
			// 	ad = ((re >= are)?(re-are):(are-re));
			// 	a[i].qe = ((ad <= pd)?aqe:pqe);
			//  }
			a[i].qe = cal_qext_coor(pre, are, pqe, aqe, re);
			//  if(aqs <= a[i].qe) {
			// 	if(rs >= prs && ars >= prs && rs <= ars) {///aqs >= pqs is always true
			// 		a[i].qs = pqs + get_offset_adjust(rs-prs, ars-prs, aqs-pqs);
			// 	} else {
			// 		pd = ((rs >= prs)?(rs-prs):(prs-rs));
			// 		ad = ((rs >= ars)?(rs-ars):(ars-rs));
			// 		a[i].qs = ((ad <= pd)?aqs:pqs);
			// 	}
			//  } else {
			// 	if(rs >= prs && re >= prs && rs <= re) {///as a[i].qe >= pqe, a[i].qe >= pqs
			// 		a[i].qs = pqs + get_offset_adjust(rs-prs, re-prs, a[i].qe-pqs);
			// 	} else {
			// 		pd = ((rs >= prs)?(rs-prs):(prs-rs));
			// 		ad = ((rs >= re)?(rs-re):(re-rs));
			// 		a[i].qs = ((ad <= pd)?a[i].qe:pqs);
			// 	}
			//  }
			a[i].qs = cal_qext_coor(prs, (a[i].qe<=aqs)?re:ars, pqs, (a[i].qe<=aqs)?a[i].qe:aqs, rs);
		}
		// assert(a[i].qs >= pqs && a[i].qs <= aqs && a[i].qe >= pqe && a[i].qe <= aqe); assert(a[i].qs <= a[i].qe);
		assert(a[i].qs >= pqs && a[i].qs <= aqs && a[i].qe >= pqe && a[i].qe <= aqe && a[i].qs <= a[i].qe);
		// fprintf(stderr, "[M::%s::i->%ld] rs::%ld, re::%ld, a[i].qs::%d, a[i].qe::%d\n", 
		// 						__func__, i, rs, re, a[i].qs, a[i].qe);
		
		if(i + 1 < eidx) {
			q_pos[0] = a[i].qs; q_pos[1] = a[i].qe; r_pos[0] = rs; r_pos[1] = re;
			r_srt[0] = r_pos[0]; r_srt[0] <<= 32;
			r_srt[1] = r_pos[1]; r_srt[1] <<= 32; r_srt[1] += 1;
			r_srt[2] = r_pos[2]; r_srt[2] <<= 32; r_srt[2] += 2;
			r_srt[3] = r_pos[3]; r_srt[3] <<= 32; r_srt[3] += 3;
			radix_sort_gfa64(r_srt, r_srt + 4);
			// assert(r_pos[(uint32_t)r_srt[0]] == (r_srt[0]>>32));
			// assert(r_pos[(uint32_t)r_srt[1]] == (r_srt[1]>>32));
			// assert(r_pos[(uint32_t)r_srt[2]] == (r_srt[2]>>32));
			// assert(r_pos[(uint32_t)r_srt[3]] == (r_srt[3]>>32));
			// fprintf(stderr, "[Srt::i->%ld] <r[0]::%ld, r[1]::%ld, q[0]::%ld, q[1]::%ld>, <r[2]::%ld, r[3]::%ld, q[2]::%ld, q[3]::%ld>\n", i, 
			// 	r_pos[0], r_pos[1], q_pos[0], q_pos[1], 
			// 	r_pos[2], r_pos[3], q_pos[2], q_pos[3]);
		}
		prs = rs; pre = re; pqs = a[i].qs; pqe = a[i].qe;
	}
	


	// if(right_q[0] < 0 || right_q[1] < 0) {
	// 	for (i = sidx+1; i < eidx; i++) {
	// 		get_u_offset(ug, &(a[i]), &rs, &re, NULL, NULL);
	// 		a[i].qs = left_q[0] + get_offset_adjust(rs - left_r[0], left_r[1]-left_r[0], left_q[1]-left_q[0]);
	// 		a[i].qe = left_q[1] + (re - left_r[1]);
	// 		left_q[0] = a[i].qs; left_q[1] = a[i].qe;
	// 		left_r[0] = rs; left_r[1] = re;
	// 	}
	// }

	// if(left_q[0] < 0 || left_q[1] < 0) {
	// 	for (i = eidx-1; i > sidx; i--) {
	// 		get_u_offset(ug, &(a[i]), &rs, &re, NULL, NULL);
	// 		a[i].qe = right_q[1] - get_offset_adjust(right_r[1]-re, right_r[1]-right_r[0], right_q[1]-right_q[0]);
	// 		a[i].qs = right_q[0] - (right_r[0]-rs);
	// 		right_q[0] = a[i].qs; right_q[1] = a[i].qe;
	// 		right_r[0] = rs; right_r[1] = re;
	// 	}
	// }

	// fprintf(stderr, "******[M::%s::] right_q[0]:%ld, right_q[1]:%ld\n", __func__, right_q[0], right_q[1]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp            # imm = 0x130
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x18(%rbp), %rax
subq -0x10(%rbp), %rax
cmpq $0x1, %rax
jg 0x29a452
jmp 0x29ac44
xorl %eax, %eax
cmpq $0x0, -0x10(%rbp)
movb %al, -0xf9(%rbp)
jl 0x29a472
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
setl %al
movb %al, -0xf9(%rbp)
movb -0xf9(%rbp), %al
testb $0x1, %al
jne 0x29a47e
jmp 0x29a480
jmp 0x29a49f
leaq 0xf754c(%rip), %rdi     # 0x3919d3
leaq 0xf63a1(%rip), %rsi     # 0x39082f
movl $0x12bd, %edx           # imm = 0x12BD
leaq 0xf754d(%rip), %rcx     # 0x3919e7
callq 0x2130
cmpq $0x0, -0x10(%rbp)
jl 0x29a4d5
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
imulq $0x28, -0x10(%rbp), %rax
addq %rax, %rsi
leaq -0x50(%rbp), %rdx
leaq -0x50(%rbp), %rcx
addq $0x8, %rcx
leaq -0x70(%rbp), %r8
leaq -0x70(%rbp), %r9
addq $0x8, %r9
callq 0x2985f0
jmp 0x29a4fa
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
leaq -0x50(%rbp), %rdx
leaq -0x50(%rbp), %rcx
addq $0x8, %rcx
leaq -0x70(%rbp), %r8
leaq -0x70(%rbp), %r9
addq $0x8, %r9
callq 0x2985f0
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
jge 0x29a53b
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
imulq $0x28, -0x18(%rbp), %rax
addq %rax, %rsi
leaq -0x50(%rbp), %rdx
addq $0x10, %rdx
leaq -0x50(%rbp), %rcx
addq $0x18, %rcx
leaq -0x70(%rbp), %r8
addq $0x10, %r8
leaq -0x70(%rbp), %r9
addq $0x18, %r9
callq 0x2985f0
jmp 0x29a577
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rax
subq $0x1, %rax
imulq $0x28, %rax, %rax
addq %rax, %rsi
leaq -0x50(%rbp), %rdx
addq $0x10, %rdx
leaq -0x50(%rbp), %rcx
addq $0x18, %rcx
leaq -0x70(%rbp), %r8
addq $0x10, %r8
leaq -0x70(%rbp), %r9
addq $0x18, %r9
callq 0x2985f0
movq -0x50(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0xc0(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0xc8(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0xd0(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0xd8(%rbp)
movq -0x60(%rbp), %rax
movq %rax, -0xe0(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0xe8(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x70(%rbp)
movb %al, -0xfa(%rbp)
jl 0x29a60a
xorl %eax, %eax
cmpq $0x0, -0x68(%rbp)
movb %al, -0xfa(%rbp)
jl 0x29a60a
xorl %eax, %eax
cmpq $0x0, -0x60(%rbp)
movb %al, -0xfa(%rbp)
jl 0x29a60a
cmpq $0x0, -0x58(%rbp)
setge %al
movb %al, -0xfa(%rbp)
movb -0xfa(%rbp), %al
testb $0x1, %al
jne 0x29a616
jmp 0x29a618
jmp 0x29a637
leaq 0xf7419(%rip), %rdi     # 0x391a38
leaq 0xf6209(%rip), %rsi     # 0x39082f
movl $0x12d4, %edx           # imm = 0x12D4
leaq 0xf73b5(%rip), %rcx     # 0x3919e7
callq 0x2130
movq -0x50(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x90(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x90(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x88(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x80(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x78(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x90(%rbp), %rsi
addq $0x20, %rsi
callq 0x27a9b0
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x98(%rbp)
movq -0x98(%rbp), %rax
cmpq -0x18(%rbp), %rax
jge 0x29ac44
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
imulq $0x28, -0x98(%rbp), %rax
addq %rax, %rsi
leaq -0xa0(%rbp), %rdx
leaq -0xa8(%rbp), %rcx
xorl %eax, %eax
movl %eax, %r9d
movq %r9, %r8
callq 0x2985f0
movq -0xa0(%rbp), %rax
cmpq -0xa8(%rbp), %rax
jg 0x29a73a
jmp 0x29a759
leaq 0xf7338(%rip), %rdi     # 0x391a79
leaq 0xf60e7(%rip), %rsi     # 0x39082f
movl $0x12e2, %edx           # imm = 0x12E2
leaq 0xf7293(%rip), %rcx     # 0x3919e7
callq 0x2130
leaq -0x90(%rbp), %rdi
leaq -0x50(%rbp), %rsi
leaq -0x70(%rbp), %rdx
movq -0xa0(%rbp), %rcx
callq 0x29a0e0
movl %eax, %ecx
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rdx
addq %rdx, %rax
movl %ecx, 0x14(%rax)
movq $0x1, -0xf0(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x50(%rbp), %rsi
leaq -0x70(%rbp), %rdx
movq -0xa8(%rbp), %rcx
callq 0x29a0e0
movl %eax, %ecx
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rdx
addq %rdx, %rax
movl %ecx, 0x18(%rax)
movq $0x1, -0xf8(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
cmpl $0x0, 0x14(%rax)
jl 0x29a825
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x14(%rax), %rax
cmpq -0xd0(%rbp), %rax
jl 0x29a825
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x14(%rax), %rax
cmpq -0xe0(%rbp), %rax
jg 0x29a825
movq $0x0, -0xf0(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
cmpl $0x0, 0x18(%rax)
jl 0x29a87d
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
cmpq -0xd8(%rbp), %rax
jl 0x29a87d
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
cmpq -0xe8(%rbp), %rax
jg 0x29a87d
movq $0x0, -0xf8(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movl 0x14(%rax), %eax
movq -0x20(%rbp), %rcx
imulq $0x28, -0x98(%rbp), %rdx
addq %rdx, %rcx
cmpl 0x18(%rcx), %eax
jle 0x29a8b9
movq $0x1, -0xf8(%rbp)
movq $0x1, -0xf0(%rbp)
cmpq $0x0, -0xf0(%rbp)
jne 0x29a8d1
cmpq $0x0, -0xf8(%rbp)
je 0x29a9f3
movq -0xb8(%rbp), %rdi
movq -0xc8(%rbp), %rsi
movq -0xd8(%rbp), %rdx
movq -0xe8(%rbp), %rcx
movq -0xa8(%rbp), %r8
callq 0x29a310
movl %eax, %ecx
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rdx
addq %rdx, %rax
movl %ecx, 0x18(%rax)
movq -0xb0(%rbp), %rax
movq %rax, -0x108(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
cmpq -0xe0(%rbp), %rax
jg 0x29a947
movq -0xa8(%rbp), %rax
movq %rax, -0x110(%rbp)
jmp 0x29a955
movq -0xc0(%rbp), %rax
movq %rax, -0x110(%rbp)
movq -0x110(%rbp), %rax
movq %rax, -0x120(%rbp)
movq -0xd0(%rbp), %rax
movq %rax, -0x118(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
cmpq -0xe0(%rbp), %rax
jg 0x29a9a9
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
movq %rax, -0x128(%rbp)
jmp 0x29a9b7
movq -0xe0(%rbp), %rax
movq %rax, -0x128(%rbp)
movq -0x118(%rbp), %rdx
movq -0x120(%rbp), %rsi
movq -0x108(%rbp), %rdi
movq -0x128(%rbp), %rcx
movq -0xa0(%rbp), %r8
callq 0x29a310
movl %eax, %ecx
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rdx
addq %rdx, %rax
movl %ecx, 0x14(%rax)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x14(%rax), %rcx
xorl %eax, %eax
cmpq -0xd0(%rbp), %rcx
movb %al, -0x129(%rbp)
jl 0x29aab4
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x14(%rax), %rcx
xorl %eax, %eax
cmpq -0xe0(%rbp), %rcx
movb %al, -0x129(%rbp)
jg 0x29aab4
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rcx
xorl %eax, %eax
cmpq -0xd8(%rbp), %rcx
movb %al, -0x129(%rbp)
jl 0x29aab4
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rcx
xorl %eax, %eax
cmpq -0xe8(%rbp), %rcx
movb %al, -0x129(%rbp)
jg 0x29aab4
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movl 0x14(%rax), %eax
movq -0x20(%rbp), %rcx
imulq $0x28, -0x98(%rbp), %rdx
addq %rdx, %rcx
cmpl 0x18(%rcx), %eax
setle %al
movb %al, -0x129(%rbp)
movb -0x129(%rbp), %al
testb $0x1, %al
jne 0x29aac0
jmp 0x29aac2
jmp 0x29aae1
leaq 0xf6fb9(%rip), %rdi     # 0x391a82
leaq 0xf5d5f(%rip), %rsi     # 0x39082f
movl $0x1306, %edx           # imm = 0x1306
leaq 0xf6f0b(%rip), %rcx     # 0x3919e7
callq 0x2130
movq -0x98(%rbp), %rax
addq $0x1, %rax
cmpq -0x18(%rbp), %rax
jge 0x29abdd
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x14(%rax), %rax
movq %rax, -0x70(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
movq %rax, -0x68(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0xa8(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x90(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x90(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x88(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x80(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
shlq $0x20, %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x78(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x90(%rbp), %rsi
addq $0x20, %rsi
callq 0x27a9b0
movq -0xa0(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0xa8(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x14(%rax), %rax
movq %rax, -0xd0(%rbp)
movq -0x20(%rbp), %rax
imulq $0x28, -0x98(%rbp), %rcx
addq %rcx, %rax
movslq 0x18(%rax), %rax
movq %rax, -0xd8(%rbp)
movq -0x98(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x98(%rbp)
jmp 0x29a6e9
addq $0x130, %rsp            # imm = 0x130
popq %rbp
retq
nopl (%rax)