// File: /workspace/github_c_makefile_star2_O0/nh13[P]ksw/src/ksw2/ksw2_extz.c
// Function: ksw_extz
void ksw_extz(void *km, int qlen, const uint8_t *query, int tlen, const uint8_t *target, int8_t m, const int8_t *mat, int8_t gapo, int8_t gape, int w, int zdrop, int flag, ksw_extz_t *ez)
{
	eh_t *eh;
	int8_t *qp; // query profile
	int32_t i, j, k, max_j = 0, gapoe = gapo + gape, n_col, *off = 0, with_cigar = !(flag&KSW_EZ_SCORE_ONLY);
	uint8_t *z = 0; // backtrack matrix; in each cell: f<<4|e<<2|h; in principle, we can halve the memory, but backtrack will be more complex

	ksw_reset_extz(ez);

	// allocate memory
	if (w < 0) w = tlen > qlen? tlen : qlen;
	n_col = qlen < 2*w+1? qlen : 2*w+1; // maximum #columns of the backtrack matrix
	qp = (int8_t*)kmalloc(km, qlen * m);
	eh = (eh_t*)kcalloc(km, qlen + 1, 8);
	if (with_cigar) {
		z = (uint8_t*)kmalloc(km, (size_t)n_col * tlen);
		off = (int32_t*)kcalloc(km, tlen, 4);
	}

	// generate the query profile
	for (k = i = 0; k < m; ++k) {
		const int8_t *p = &mat[k * m];
		for (j = 0; j < qlen; ++j) qp[i++] = p[query[j]];
	}

	// fill the first row
	eh[0].h = 0, eh[0].e = -gapoe - gapoe;
	for (j = 1; j <= qlen && j <= w; ++j)
		eh[j].h = -(gapoe + gape * (j - 1)), eh[j].e = -(gapoe + gapoe + gape * j);
	for (; j <= qlen; ++j) eh[j].h = eh[j].e = KSW_NEG_INF; // everything is -inf outside the band

	// DP loop
	for (i = 0; i < tlen; ++i) { // target sequence is in the outer loop
		int32_t f, h1, st, en, max = KSW_NEG_INF;
		int8_t *q = &qp[target[i] * qlen];
		st = i > w? i - w : 0;
		en = i + w < qlen - 1? i + w : qlen - 1;
		h1 = st > 0? KSW_NEG_INF : -(gapoe + gape * i);
		f  = st > 0? KSW_NEG_INF : -(gapoe + gapoe + gape * i);
		if (!with_cigar) {
			for (j = st; j <= en; ++j) {
				eh_t *p = &eh[j];
				int32_t h = p->h, e = p->e;
				p->h = h1;
				h += q[j];
				h = h >= e? h : e;
				h = h >= f? h : f;
				h1 = h;
				max_j = max > h? max_j : j;
				max   = max > h? max   : h;
				h -= gapoe;
				e -= gape;
				e  = e > h? e : h;
				p->e = e;
				f -= gape;
				f  = f > h? f : h;
			}
		} else if (!(flag&KSW_EZ_RIGHT)) {
			uint8_t *zi = &z[(long)i * n_col];
			off[i] = st;
			for (j = st; j <= en; ++j) {
				eh_t *p = &eh[j];
				int32_t h = p->h, e = p->e;
				uint8_t d; // direction
				p->h = h1;
				h += q[j];
				d = h >= e? 0 : 1;
				h = h >= e? h : e;
				d = h >= f? d : 2;
				h = h >= f? h : f;
				h1 = h;
				max_j = max > h? max_j : j;
				max   = max > h? max   : h;
				h -= gapoe;
				e -= gape;
				d |= e > h? 0x08 : 0;
				e  = e > h? e    : h;
				p->e = e;
				f -= gape;
				d |= f > h? 0x10 : 0; // if we want to halve the memory, use one bit only, instead of two
				f  = f > h? f    : h;
				zi[j - st] = d; // z[i,j] keeps h for the current cell and e/f for the next cell
			}
		} else {
			uint8_t *zi = &z[(long)i * n_col];
			off[i] = st;
			for (j = st; j <= en; ++j) {
				eh_t *p = &eh[j];
				int32_t h = p->h, e = p->e;
				uint8_t d; // direction
				p->h = h1;
				h += q[j];
				d = h > e? 0 : 1;
				h = h > e? h : e;
				d = h > f? d : 2;
				h = h > f? h : f;
				h1 = h;
				max_j = max >= h? max_j : j;
				max   = max >= h? max   : h;
				h -= gapoe;
				e -= gape;
				d |= e >= h? 0x08 : 0;
				e  = e >= h? e    : h;
				p->e = e;
				f -= gape;
				d |= f >= h? 0x10 : 0; // if we want to halve the memory, use one bit only, instead of two
				f  = f >= h? f    : h;
				zi[j - st] = d; // z[i,j] keeps h for the current cell and e/f for the next cell
			}
		}
		eh[j].h = h1, eh[j].e = KSW_NEG_INF;
		// update ez
		if (en == qlen - 1 && eh[qlen].h > ez->mqe)
			ez->mqe = eh[qlen].h, ez->mqe_t = i;
		if (i == tlen - 1)
			ez->mte = max, ez->mte_q = max_j;
		if (ksw_apply_zdrop(ez, 0, max, i, max_j, zdrop, gape)) break;
		if (i == tlen - 1 && en == qlen - 1)
			ez->score = eh[qlen].h;
	}
	kfree(km, qp); kfree(km, eh);
	if (with_cigar) {
		int rev_cigar = !!(flag & KSW_EZ_REV_CIGAR);
		if (!ez->zdropped && !(flag&KSW_EZ_EXTZ_ONLY))
			ksw_backtrack(km, 0, rev_cigar, 0, z, off, 0, n_col, tlen-1, qlen-1, &ez->m_cigar, &ez->n_cigar, &ez->cigar);
		else if (ez->max_t >= 0 && ez->max_q >= 0)
			ksw_backtrack(km, 0, rev_cigar, 0, z, off, 0, n_col, ez->max_t, ez->max_q, &ez->m_cigar, &ez->n_cigar, &ez->cigar);
		kfree(km, z); kfree(km, off);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x198, %rsp            # imm = 0x198
movb %r9b, %al
movq 0x40(%rbp), %r9
movl 0x38(%rbp), %r9d
movl 0x30(%rbp), %r9d
movl 0x28(%rbp), %r9d
movb 0x20(%rbp), %r9b
movb 0x18(%rbp), %r9b
movq 0x10(%rbp), %r9
movq %rdi, -0x20(%rbp)
movl %esi, -0x24(%rbp)
movq %rdx, -0x30(%rbp)
movl %ecx, -0x34(%rbp)
movq %r8, -0x40(%rbp)
movb %al, -0x41(%rbp)
movl $0x0, -0x68(%rbp)
movsbl 0x18(%rbp), %eax
movsbl 0x20(%rbp), %ecx
addl %ecx, %eax
movl %eax, -0x6c(%rbp)
movq $0x0, -0x78(%rbp)
movl 0x38(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
setne %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x7c(%rbp)
movq $0x0, -0x88(%rbp)
movq 0x40(%rbp), %rdi
callq 0x1af2b0
cmpl $0x0, 0x28(%rbp)
jge 0x1ae525
movl -0x34(%rbp), %eax
cmpl -0x24(%rbp), %eax
jle 0x1ae513
movl -0x34(%rbp), %eax
movl %eax, -0x104(%rbp)
jmp 0x1ae51c
movl -0x24(%rbp), %eax
movl %eax, -0x104(%rbp)
movl -0x104(%rbp), %eax
movl %eax, 0x28(%rbp)
movl -0x24(%rbp), %eax
movl 0x28(%rbp), %ecx
shll %ecx
addl $0x1, %ecx
cmpl %ecx, %eax
jge 0x1ae53f
movl -0x24(%rbp), %eax
movl %eax, -0x108(%rbp)
jmp 0x1ae54d
movl 0x28(%rbp), %eax
shll %eax
addl $0x1, %eax
movl %eax, -0x108(%rbp)
movl -0x108(%rbp), %eax
movl %eax, -0x70(%rbp)
movq -0x20(%rbp), %rdi
movl -0x24(%rbp), %eax
movsbl -0x41(%rbp), %ecx
imull %ecx, %eax
movslq %eax, %rsi
callq 0x19e720
movq %rax, -0x58(%rbp)
movq -0x20(%rbp), %rdi
movl -0x24(%rbp), %eax
addl $0x1, %eax
movslq %eax, %rsi
movl $0x8, %edx
callq 0x19e9c0
movq %rax, -0x50(%rbp)
cmpl $0x0, -0x7c(%rbp)
je 0x1ae5c3
movq -0x20(%rbp), %rdi
movslq -0x70(%rbp), %rsi
movslq -0x34(%rbp), %rax
imulq %rax, %rsi
callq 0x19e720
movq %rax, -0x88(%rbp)
movq -0x20(%rbp), %rdi
movslq -0x34(%rbp), %rsi
movl $0x4, %edx
callq 0x19e9c0
movq %rax, -0x78(%rbp)
movl $0x0, -0x5c(%rbp)
movl $0x0, -0x64(%rbp)
movl -0x64(%rbp), %eax
movsbl -0x41(%rbp), %ecx
cmpl %ecx, %eax
jge 0x1ae649
movq 0x10(%rbp), %rax
movl -0x64(%rbp), %ecx
movsbl -0x41(%rbp), %edx
imull %edx, %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x90(%rbp)
movl $0x0, -0x60(%rbp)
movl -0x60(%rbp), %eax
cmpl -0x24(%rbp), %eax
jge 0x1ae63c
movq -0x90(%rbp), %rax
movq -0x30(%rbp), %rcx
movslq -0x60(%rbp), %rdx
movzbl (%rcx,%rdx), %ecx
movb (%rax,%rcx), %dl
movq -0x58(%rbp), %rax
movl -0x5c(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0x5c(%rbp)
movslq %ecx, %rcx
movb %dl, (%rax,%rcx)
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x1ae5fe
jmp 0x1ae63e
movl -0x64(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x64(%rbp)
jmp 0x1ae5d1
movq -0x50(%rbp), %rax
movl $0x0, (%rax)
xorl %ecx, %ecx
subl -0x6c(%rbp), %ecx
subl -0x6c(%rbp), %ecx
movq -0x50(%rbp), %rax
movl %ecx, 0x4(%rax)
movl $0x1, -0x60(%rbp)
movl -0x60(%rbp), %ecx
xorl %eax, %eax
cmpl -0x24(%rbp), %ecx
movb %al, -0x109(%rbp)
jg 0x1ae688
movl -0x60(%rbp), %eax
cmpl 0x28(%rbp), %eax
setle %al
movb %al, -0x109(%rbp)
movb -0x109(%rbp), %al
testb $0x1, %al
jne 0x1ae694
jmp 0x1ae6e0
movl -0x6c(%rbp), %eax
movsbl 0x20(%rbp), %ecx
movl -0x60(%rbp), %edx
subl $0x1, %edx
imull %edx, %ecx
addl %ecx, %eax
xorl %edx, %edx
subl %eax, %edx
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl %edx, (%rax,%rcx,8)
movl -0x6c(%rbp), %eax
addl -0x6c(%rbp), %eax
movsbl 0x20(%rbp), %ecx
imull -0x60(%rbp), %ecx
addl %ecx, %eax
xorl %edx, %edx
subl %eax, %edx
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl %edx, 0x4(%rax,%rcx,8)
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x1ae669
jmp 0x1ae6e2
movl -0x60(%rbp), %eax
cmpl -0x24(%rbp), %eax
jg 0x1ae714
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl $0xc0000000, 0x4(%rax,%rcx,8) # imm = 0xC0000000
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl $0xc0000000, (%rax,%rcx,8) # imm = 0xC0000000
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x1ae6e2
movl $0x0, -0x5c(%rbp)
movl -0x5c(%rbp), %eax
cmpl -0x34(%rbp), %eax
jge 0x1af125
movl $0xc0000000, -0xa4(%rbp) # imm = 0xC0000000
movq -0x58(%rbp), %rax
movq -0x40(%rbp), %rcx
movslq -0x5c(%rbp), %rdx
movzbl (%rcx,%rdx), %ecx
imull -0x24(%rbp), %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0xb0(%rbp)
movl -0x5c(%rbp), %eax
cmpl 0x28(%rbp), %eax
jle 0x1ae768
movl -0x5c(%rbp), %eax
subl 0x28(%rbp), %eax
movl %eax, -0x110(%rbp)
jmp 0x1ae772
xorl %eax, %eax
movl %eax, -0x110(%rbp)
jmp 0x1ae772
movl -0x110(%rbp), %eax
movl %eax, -0x9c(%rbp)
movl -0x5c(%rbp), %eax
addl 0x28(%rbp), %eax
movl -0x24(%rbp), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jge 0x1ae79c
movl -0x5c(%rbp), %eax
addl 0x28(%rbp), %eax
movl %eax, -0x114(%rbp)
jmp 0x1ae7a8
movl -0x24(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x114(%rbp)
movl -0x114(%rbp), %eax
movl %eax, -0xa0(%rbp)
cmpl $0x0, -0x9c(%rbp)
jle 0x1ae7ca
movl $0xc0000000, %eax       # imm = 0xC0000000
movl %eax, -0x118(%rbp)
jmp 0x1ae7e1
movl -0x6c(%rbp), %ecx
movsbl 0x20(%rbp), %eax
imull -0x5c(%rbp), %eax
addl %eax, %ecx
xorl %eax, %eax
subl %ecx, %eax
movl %eax, -0x118(%rbp)
movl -0x118(%rbp), %eax
movl %eax, -0x98(%rbp)
cmpl $0x0, -0x9c(%rbp)
jle 0x1ae803
movl $0xc0000000, %eax       # imm = 0xC0000000
movl %eax, -0x11c(%rbp)
jmp 0x1ae81d
movl -0x6c(%rbp), %ecx
addl -0x6c(%rbp), %ecx
movsbl 0x20(%rbp), %eax
imull -0x5c(%rbp), %eax
addl %eax, %ecx
xorl %eax, %eax
subl %ecx, %eax
movl %eax, -0x11c(%rbp)
movl -0x11c(%rbp), %eax
movl %eax, -0x94(%rbp)
cmpl $0x0, -0x7c(%rbp)
jne 0x1aea3d
movl -0x9c(%rbp), %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %eax
cmpl -0xa0(%rbp), %eax
jg 0x1aea38
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0xb8(%rbp)
movq -0xb8(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xbc(%rbp)
movq -0xb8(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0xc0(%rbp)
movl -0x98(%rbp), %ecx
movq -0xb8(%rbp), %rax
movl %ecx, (%rax)
movq -0xb0(%rbp), %rax
movslq -0x60(%rbp), %rcx
movsbl (%rax,%rcx), %eax
addl -0xbc(%rbp), %eax
movl %eax, -0xbc(%rbp)
movl -0xbc(%rbp), %eax
cmpl -0xc0(%rbp), %eax
jl 0x1ae8c6
movl -0xbc(%rbp), %eax
movl %eax, -0x120(%rbp)
jmp 0x1ae8d2
movl -0xc0(%rbp), %eax
movl %eax, -0x120(%rbp)
movl -0x120(%rbp), %eax
movl %eax, -0xbc(%rbp)
movl -0xbc(%rbp), %eax
cmpl -0x94(%rbp), %eax
jl 0x1ae8fa
movl -0xbc(%rbp), %eax
movl %eax, -0x124(%rbp)
jmp 0x1ae906
movl -0x94(%rbp), %eax
movl %eax, -0x124(%rbp)
movl -0x124(%rbp), %eax
movl %eax, -0xbc(%rbp)
movl -0xbc(%rbp), %eax
movl %eax, -0x98(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0xbc(%rbp), %eax
jle 0x1ae937
movl -0x68(%rbp), %eax
movl %eax, -0x128(%rbp)
jmp 0x1ae940
movl -0x60(%rbp), %eax
movl %eax, -0x128(%rbp)
movl -0x128(%rbp), %eax
movl %eax, -0x68(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0xbc(%rbp), %eax
jle 0x1ae965
movl -0xa4(%rbp), %eax
movl %eax, -0x12c(%rbp)
jmp 0x1ae971
movl -0xbc(%rbp), %eax
movl %eax, -0x12c(%rbp)
movl -0x12c(%rbp), %eax
movl %eax, -0xa4(%rbp)
movl -0x6c(%rbp), %ecx
movl -0xbc(%rbp), %eax
subl %ecx, %eax
movl %eax, -0xbc(%rbp)
movsbl 0x20(%rbp), %ecx
movl -0xc0(%rbp), %eax
subl %ecx, %eax
movl %eax, -0xc0(%rbp)
movl -0xc0(%rbp), %eax
cmpl -0xbc(%rbp), %eax
jle 0x1ae9bc
movl -0xc0(%rbp), %eax
movl %eax, -0x130(%rbp)
jmp 0x1ae9c8
movl -0xbc(%rbp), %eax
movl %eax, -0x130(%rbp)
movl -0x130(%rbp), %eax
movl %eax, -0xc0(%rbp)
movl -0xc0(%rbp), %ecx
movq -0xb8(%rbp), %rax
movl %ecx, 0x4(%rax)
movsbl 0x20(%rbp), %ecx
movl -0x94(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x94(%rbp)
movl -0x94(%rbp), %eax
cmpl -0xbc(%rbp), %eax
jle 0x1aea12
movl -0x94(%rbp), %eax
movl %eax, -0x134(%rbp)
jmp 0x1aea1e
movl -0xbc(%rbp), %eax
movl %eax, -0x134(%rbp)
movl -0x134(%rbp), %eax
movl %eax, -0x94(%rbp)
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x1ae83c
jmp 0x1af037
movl 0x38(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0x1aed42
movq -0x88(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movslq -0x70(%rbp), %rdx
imulq %rdx, %rcx
addq %rcx, %rax
movq %rax, -0xc8(%rbp)
movl -0x9c(%rbp), %edx
movq -0x78(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x9c(%rbp), %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %eax
cmpl -0xa0(%rbp), %eax
jg 0x1aed3d
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0xd0(%rbp)
movq -0xd0(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xd4(%rbp)
movq -0xd0(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0xd8(%rbp)
movl -0x98(%rbp), %ecx
movq -0xd0(%rbp), %rax
movl %ecx, (%rax)
movq -0xb0(%rbp), %rax
movslq -0x60(%rbp), %rcx
movsbl (%rax,%rcx), %eax
addl -0xd4(%rbp), %eax
movl %eax, -0xd4(%rbp)
movl -0xd4(%rbp), %edx
movl -0xd8(%rbp), %esi
movl $0x1, %eax
xorl %ecx, %ecx
cmpl %esi, %edx
cmovgel %ecx, %eax
movb %al, -0xd9(%rbp)
movl -0xd4(%rbp), %eax
cmpl -0xd8(%rbp), %eax
jl 0x1aeb2b
movl -0xd4(%rbp), %eax
movl %eax, -0x138(%rbp)
jmp 0x1aeb37
movl -0xd8(%rbp), %eax
movl %eax, -0x138(%rbp)
movl -0x138(%rbp), %eax
movl %eax, -0xd4(%rbp)
movl -0xd4(%rbp), %eax
cmpl -0x94(%rbp), %eax
jl 0x1aeb60
movzbl -0xd9(%rbp), %eax
movl %eax, -0x13c(%rbp)
jmp 0x1aeb6d
movl $0x2, %eax
movl %eax, -0x13c(%rbp)
jmp 0x1aeb6d
movl -0x13c(%rbp), %eax
movb %al, -0xd9(%rbp)
movl -0xd4(%rbp), %eax
cmpl -0x94(%rbp), %eax
jl 0x1aeb95
movl -0xd4(%rbp), %eax
movl %eax, -0x140(%rbp)
jmp 0x1aeba1
movl -0x94(%rbp), %eax
movl %eax, -0x140(%rbp)
movl -0x140(%rbp), %eax
movl %eax, -0xd4(%rbp)
movl -0xd4(%rbp), %eax
movl %eax, -0x98(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0xd4(%rbp), %eax
jle 0x1aebd2
movl -0x68(%rbp), %eax
movl %eax, -0x144(%rbp)
jmp 0x1aebdb
movl -0x60(%rbp), %eax
movl %eax, -0x144(%rbp)
movl -0x144(%rbp), %eax
movl %eax, -0x68(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0xd4(%rbp), %eax
jle 0x1aec00
movl -0xa4(%rbp), %eax
movl %eax, -0x148(%rbp)
jmp 0x1aec0c
movl -0xd4(%rbp), %eax
movl %eax, -0x148(%rbp)
movl -0x148(%rbp), %eax
movl %eax, -0xa4(%rbp)
movl -0x6c(%rbp), %ecx
movl -0xd4(%rbp), %eax
subl %ecx, %eax
movl %eax, -0xd4(%rbp)
movsbl 0x20(%rbp), %ecx
movl -0xd8(%rbp), %eax
subl %ecx, %eax
movl %eax, -0xd8(%rbp)
movl -0xd8(%rbp), %edx
movl -0xd4(%rbp), %esi
xorl %ecx, %ecx
movl $0x8, %eax
cmpl %esi, %edx
cmovgl %eax, %ecx
movzbl -0xd9(%rbp), %eax
orl %ecx, %eax
movb %al, -0xd9(%rbp)
movl -0xd8(%rbp), %eax
cmpl -0xd4(%rbp), %eax
jle 0x1aec7e
movl -0xd8(%rbp), %eax
movl %eax, -0x14c(%rbp)
jmp 0x1aec8a
movl -0xd4(%rbp), %eax
movl %eax, -0x14c(%rbp)
movl -0x14c(%rbp), %eax
movl %eax, -0xd8(%rbp)
movl -0xd8(%rbp), %ecx
movq -0xd0(%rbp), %rax
movl %ecx, 0x4(%rax)
movsbl 0x20(%rbp), %ecx
movl -0x94(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x94(%rbp)
movl -0x94(%rbp), %edx
movl -0xd4(%rbp), %esi
xorl %ecx, %ecx
movl $0x10, %eax
cmpl %esi, %edx
cmovgl %eax, %ecx
movzbl -0xd9(%rbp), %eax
orl %ecx, %eax
movb %al, -0xd9(%rbp)
movl -0x94(%rbp), %eax
cmpl -0xd4(%rbp), %eax
jle 0x1aecfb
movl -0x94(%rbp), %eax
movl %eax, -0x150(%rbp)
jmp 0x1aed07
movl -0xd4(%rbp), %eax
movl %eax, -0x150(%rbp)
movl -0x150(%rbp), %eax
movl %eax, -0x94(%rbp)
movb -0xd9(%rbp), %dl
movq -0xc8(%rbp), %rax
movl -0x60(%rbp), %ecx
subl -0x9c(%rbp), %ecx
movslq %ecx, %rcx
movb %dl, (%rax,%rcx)
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x1aea83
jmp 0x1af035
movq -0x88(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movslq -0x70(%rbp), %rdx
imulq %rdx, %rcx
addq %rcx, %rax
movq %rax, -0xe8(%rbp)
movl -0x9c(%rbp), %edx
movq -0x78(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x9c(%rbp), %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %eax
cmpl -0xa0(%rbp), %eax
jg 0x1af033
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0xf0(%rbp)
movq -0xf0(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xf4(%rbp)
movq -0xf0(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0xf8(%rbp)
movl -0x98(%rbp), %ecx
movq -0xf0(%rbp), %rax
movl %ecx, (%rax)
movq -0xb0(%rbp), %rax
movslq -0x60(%rbp), %rcx
movsbl (%rax,%rcx), %eax
addl -0xf4(%rbp), %eax
movl %eax, -0xf4(%rbp)
movl -0xf4(%rbp), %edx
movl -0xf8(%rbp), %esi
movl $0x1, %eax
xorl %ecx, %ecx
cmpl %esi, %edx
cmovgl %ecx, %eax
movb %al, -0xf9(%rbp)
movl -0xf4(%rbp), %eax
cmpl -0xf8(%rbp), %eax
jle 0x1aee21
movl -0xf4(%rbp), %eax
movl %eax, -0x154(%rbp)
jmp 0x1aee2d
movl -0xf8(%rbp), %eax
movl %eax, -0x154(%rbp)
movl -0x154(%rbp), %eax
movl %eax, -0xf4(%rbp)
movl -0xf4(%rbp), %eax
cmpl -0x94(%rbp), %eax
jle 0x1aee56
movzbl -0xf9(%rbp), %eax
movl %eax, -0x158(%rbp)
jmp 0x1aee63
movl $0x2, %eax
movl %eax, -0x158(%rbp)
jmp 0x1aee63
movl -0x158(%rbp), %eax
movb %al, -0xf9(%rbp)
movl -0xf4(%rbp), %eax
cmpl -0x94(%rbp), %eax
jle 0x1aee8b
movl -0xf4(%rbp), %eax
movl %eax, -0x15c(%rbp)
jmp 0x1aee97
movl -0x94(%rbp), %eax
movl %eax, -0x15c(%rbp)
movl -0x15c(%rbp), %eax
movl %eax, -0xf4(%rbp)
movl -0xf4(%rbp), %eax
movl %eax, -0x98(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0xf4(%rbp), %eax
jl 0x1aeec8
movl -0x68(%rbp), %eax
movl %eax, -0x160(%rbp)
jmp 0x1aeed1
movl -0x60(%rbp), %eax
movl %eax, -0x160(%rbp)
movl -0x160(%rbp), %eax
movl %eax, -0x68(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0xf4(%rbp), %eax
jl 0x1aeef6
movl -0xa4(%rbp), %eax
movl %eax, -0x164(%rbp)
jmp 0x1aef02
movl -0xf4(%rbp), %eax
movl %eax, -0x164(%rbp)
movl -0x164(%rbp), %eax
movl %eax, -0xa4(%rbp)
movl -0x6c(%rbp), %ecx
movl -0xf4(%rbp), %eax
subl %ecx, %eax
movl %eax, -0xf4(%rbp)
movsbl 0x20(%rbp), %ecx
movl -0xf8(%rbp), %eax
subl %ecx, %eax
movl %eax, -0xf8(%rbp)
movl -0xf8(%rbp), %edx
movl -0xf4(%rbp), %esi
xorl %ecx, %ecx
movl $0x8, %eax
cmpl %esi, %edx
cmovgel %eax, %ecx
movzbl -0xf9(%rbp), %eax
orl %ecx, %eax
movb %al, -0xf9(%rbp)
movl -0xf8(%rbp), %eax
cmpl -0xf4(%rbp), %eax
jl 0x1aef74
movl -0xf8(%rbp), %eax
movl %eax, -0x168(%rbp)
jmp 0x1aef80
movl -0xf4(%rbp), %eax
movl %eax, -0x168(%rbp)
movl -0x168(%rbp), %eax
movl %eax, -0xf8(%rbp)
movl -0xf8(%rbp), %ecx
movq -0xf0(%rbp), %rax
movl %ecx, 0x4(%rax)
movsbl 0x20(%rbp), %ecx
movl -0x94(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x94(%rbp)
movl -0x94(%rbp), %edx
movl -0xf4(%rbp), %esi
xorl %ecx, %ecx
movl $0x10, %eax
cmpl %esi, %edx
cmovgel %eax, %ecx
movzbl -0xf9(%rbp), %eax
orl %ecx, %eax
movb %al, -0xf9(%rbp)
movl -0x94(%rbp), %eax
cmpl -0xf4(%rbp), %eax
jl 0x1aeff1
movl -0x94(%rbp), %eax
movl %eax, -0x16c(%rbp)
jmp 0x1aeffd
movl -0xf4(%rbp), %eax
movl %eax, -0x16c(%rbp)
movl -0x16c(%rbp), %eax
movl %eax, -0x94(%rbp)
movb -0xf9(%rbp), %dl
movq -0xe8(%rbp), %rax
movl -0x60(%rbp), %ecx
subl -0x9c(%rbp), %ecx
movslq %ecx, %rcx
movb %dl, (%rax,%rcx)
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x1aed79
jmp 0x1af035
jmp 0x1af037
movl -0x98(%rbp), %edx
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl %edx, (%rax,%rcx,8)
movq -0x50(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl $0xc0000000, 0x4(%rax,%rcx,8) # imm = 0xC0000000
movl -0xa0(%rbp), %eax
movl -0x24(%rbp), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jne 0x1af098
movq -0x50(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,8), %eax
movq 0x40(%rbp), %rcx
cmpl 0xc(%rcx), %eax
jle 0x1af098
movq -0x50(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,8), %ecx
movq 0x40(%rbp), %rax
movl %ecx, 0xc(%rax)
movl -0x5c(%rbp), %ecx
movq 0x40(%rbp), %rax
movl %ecx, 0x10(%rax)
movl -0x5c(%rbp), %eax
movl -0x34(%rbp), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jne 0x1af0bc
movl -0xa4(%rbp), %ecx
movq 0x40(%rbp), %rax
movl %ecx, 0x14(%rax)
movl -0x68(%rbp), %ecx
movq 0x40(%rbp), %rax
movl %ecx, 0x18(%rax)
movq 0x40(%rbp), %rdi
movl -0xa4(%rbp), %edx
movl -0x5c(%rbp), %ecx
movl -0x68(%rbp), %r8d
movl 0x30(%rbp), %r9d
xorl %esi, %esi
movsbl 0x20(%rbp), %eax
movl %eax, (%rsp)
callq 0x1af340
cmpl $0x0, %eax
je 0x1af0e6
jmp 0x1af125
movl -0x5c(%rbp), %eax
movl -0x34(%rbp), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jne 0x1af115
movl -0xa0(%rbp), %eax
movl -0x24(%rbp), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jne 0x1af115
movq -0x50(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,8), %ecx
movq 0x40(%rbp), %rax
movl %ecx, 0x1c(%rax)
jmp 0x1af117
movl -0x5c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x5c(%rbp)
jmp 0x1ae71b
movq -0x20(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x19e3f0
movq -0x20(%rbp), %rdi
movq -0x50(%rbp), %rsi
callq 0x19e3f0
cmpl $0x0, -0x7c(%rbp)
je 0x1af296
movl 0x38(%rbp), %eax
andl $0x80, %eax
cmpl $0x0, %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x100(%rbp)
movq 0x40(%rbp), %rax
movl (%rax), %eax
shrl $0x1f, %eax
cmpl $0x0, %eax
jne 0x1af1f3
movl 0x38(%rbp), %eax
andl $0x40, %eax
cmpl $0x0, %eax
jne 0x1af1f3
movq -0x20(%rbp), %rdi
movl -0x100(%rbp), %edx
movq -0x88(%rbp), %r8
movq -0x78(%rbp), %r9
movl -0x70(%rbp), %r15d
movl -0x34(%rbp), %r14d
subl $0x1, %r14d
movl -0x24(%rbp), %ebx
subl $0x1, %ebx
movq 0x40(%rbp), %r11
addq $0x20, %r11
movq 0x40(%rbp), %r10
addq $0x24, %r10
movq 0x40(%rbp), %rax
addq $0x28, %rax
xorl %ecx, %ecx
xorl %esi, %esi
movl %ecx, %esi
movq $0x0, (%rsp)
movl %r15d, 0x8(%rsp)
movl %r14d, 0x10(%rsp)
movl %ebx, 0x18(%rsp)
movq %r11, 0x20(%rsp)
movq %r10, 0x28(%rsp)
movq %rax, 0x30(%rsp)
callq 0x1af480
jmp 0x1af279
movq 0x40(%rbp), %rax
cmpl $0x0, 0x8(%rax)
jl 0x1af277
movq 0x40(%rbp), %rax
cmpl $0x0, 0x4(%rax)
jl 0x1af277
movq -0x20(%rbp), %rdi
movl -0x100(%rbp), %edx
movq -0x88(%rbp), %r8
movq -0x78(%rbp), %r9
movl -0x70(%rbp), %r15d
movq 0x40(%rbp), %rax
movl 0x8(%rax), %r14d
movq 0x40(%rbp), %rax
movl 0x4(%rax), %ebx
movq 0x40(%rbp), %r11
addq $0x20, %r11
movq 0x40(%rbp), %r10
addq $0x24, %r10
movq 0x40(%rbp), %rax
addq $0x28, %rax
xorl %ecx, %ecx
xorl %esi, %esi
movl %ecx, %esi
movq $0x0, (%rsp)
movl %r15d, 0x8(%rsp)
movl %r14d, 0x10(%rsp)
movl %ebx, 0x18(%rsp)
movq %r11, 0x20(%rsp)
movq %r10, 0x28(%rsp)
movq %rax, 0x30(%rsp)
callq 0x1af480
jmp 0x1af279
movq -0x20(%rbp), %rdi
movq -0x88(%rbp), %rsi
callq 0x19e3f0
movq -0x20(%rbp), %rdi
movq -0x78(%rbp), %rsi
callq 0x19e3f0
addq $0x198, %rsp            # imm = 0x198
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nopw %cs:(%rax,%rax)