// File: JohnCGriffin[P]BrainForked/bf_optimizations.cpp
// Function: bf::optimizations(std::vector<bf::Instruction, std::allocator<bf::Instruction>> const&, bool)
Instructions optimizations(const Instructions& instrs, bool take_second_pass)
    {
	Instructions result;
	const int sz = instrs.size();

	for(int i=0; i<sz; i++){

#define AT(x) instrs.at(i+x)
#define VAL(x) instrs.at(i+x).val


	    auto pattern  = [&](Actions actions){ return matches(instrs, i, actions); };


	    //////////////////////////////////////////////
	    // The following block contains optimizations
	    // for non-terminals, available in pass two.
	    //////////////////////////////////////////////

	    {
		if(pattern({ZERO, MOVE}) && VAL(1) == 1){
		    result.push_back({ ZEROM1 });
		    i++;
		    continue;
		}

		if(pattern({MOVE, ZERO}) && VAL(0) == 1){
		    result.push_back({ M1ZERO });
		    i++;
		    continue;
		}

		if(pattern({FALSEJUMP, MOVE, ZERO, MXDECR1, TRUEJUMP }) &&
		   VAL(1) == 1 && VAL(3) == -1){
		    result.push_back({ZERO2IF});
		    i+=4;
		    continue;
		}

		if(pattern({ MOVE, GIVE, MOVE}) &&
		   VAL(2) == VAL(1) &&
		   VAL(0) == -VAL(2)){
		    result.push_back({ TAKE, VAL(0) });
		    i+=2;
		    continue;
		}

		if(pattern({FALSEJUMP, MOVE, GIVE, MOVE, TRUEJUMP})){
		    result.push_back({VALUE, VAL(1) });
		    result.push_back({VALUE, VAL(2) });
		    result.push_back({WHILEMGM, VAL(3) });
		    i += 4;
		    continue;
		}

		if(pattern({DECR1MX, GIVE, MOVE}) &&
		   VAL(0) == -VAL(1) && VAL(0) == -VAL(2)){
		    result.push_back({INCR, -1});
		    result.push_back({TAKE, VAL(0)});
		    i += 2;
		    continue;
		}

		if(pattern({ADVANCE, VALUE, VALUE, VALUE, VALUE, VALUE, VALUE, WHILEIM3}) &&
		   VAL(1) == -1 && VAL(3) ==1 && VAL(5) == 1 && (VAL(2) + VAL(4) + VAL(6) == 0)){
		    result.push_back({VALUE, VAL(2)});
		    result.push_back({VALUE, (short) (VAL(4)+VAL(2))});
		    result.push_back({WHILEDECROI2});
		    i += 7;
		    continue;
		}
	    }


	    ///////////////////////////////////////////////////
	    //	All that follow are primitives for first pass.
	    //////////////////////////////////////////////////
	    {
		// subtract value from current cell and add it to another cell
		if(pattern({ FALSEJUMP, INCR, MOVE, INCR, MOVE, TRUEJUMP }) &&
		   VAL(1) == -1 && VAL(3) == 1 && VAL(2) == -VAL(4)){
		    result.push_back( { GIVE, VAL(2) } );
		    i += 5;
		    continue;
		}

		// alternate version decrements last
		// subtract value from current cell and add it to another cell
		if(pattern({ FALSEJUMP, MOVE, INCR, MOVE, INCR, TRUEJUMP }) &&
		   VAL(2) == 1 && VAL(4) == -1 && VAL(1) == -VAL(3)){
		    result.push_back( { GIVE, VAL(1) });
		    i += 5;
		    continue;
		}

		// [+>-<<<---->>>>>]
		if(pattern({ FALSEJUMP, INCR, MOVE, INCR, MOVE, INCR, MOVE, TRUEJUMP})){
		    result.push_back({ ADVANCE, 6 });
		    for(int j=0; j<6; j++){
			result.push_back({ VALUE, VAL(j+1) });
		    }
		    result.push_back({ WHILEIM3 });
		    i += 7;
		    continue;
		}

		// [+>-<]
		if(pattern({ FALSEJUMP, INCR, MOVE, INCR, MOVE, TRUEJUMP})){
		    result.push_back({ ADVANCE, 4 });
		    for(int j=0; j<4; j++){
			result.push_back({ VALUE, VAL(j+1) });
		    }
		    result.push_back({ WHILEIM2 });
		    i += 5;
		    continue;
		}

		// >>+++<<
		if(pattern({ MOVE, INCR, MOVE}) && AT(0).val == -AT(2).val){
		    result.push_back({VALUE, VAL(0)});
		    result.push_back({OFFINCR, VAL(1)});
		    i+=2;
		    continue;
		}

		if(pattern({ INCR, MOVE}) && VAL(0) == -1){
		    result.push_back({ DECR1MX, VAL(1) });
		    i++;
		    continue;
		}

		if(pattern({ INCR, MOVE}) && VAL(0) == 1){
		    result.push_back({ INCR1MX, VAL(1) });
		    i++;
		    continue;
		}

		if(pattern({ MOVE, INCR }) && VAL(1) == 1){
		    result.push_back({ MXINCR1, VAL(0) });
		    i++;
		    continue;
		}

		if(pattern({ MOVE, INCR }) && VAL(1) == -1){
		    result.push_back({ MXDECR1, VAL(0) });
		    i++;
		    continue;
		}

		// [-]
		if(pattern({ FALSEJUMP, INCR, TRUEJUMP })){
		    while(result.back().action == ZERO || result.back().action == INCR){
			result.pop_back();
		    }
		    result.push_back({ ZERO });
		    i+=2;
		    continue;
		}

		// move while, e.g. [<<<]
		if(pattern({ FALSEJUMP, MOVE, TRUEJUMP })){
		    result.push_back({ MOVEWHILE, VAL(1) });
		    i += 2;
		    continue;
		}
	    }

	    result.push_back(instrs.at(i));
	}

	if(take_second_pass){
	    result = optimizations(result,false);
	}

	return result;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x7b0, %rsp            # imm = 0x7B0
movq %rdi, -0x4b0(%rbp)
movb %dl, %al
movq %rdi, %rcx
movq %rcx, -0x4a8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
andb $0x1, %al
movb %al, -0x11(%rbp)
movb $0x0, -0x12(%rbp)
callq 0x8690
movq -0x10(%rbp), %rdi
callq 0x3d40
movl %eax, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x18(%rbp), %eax
jge 0xc757
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
leaq -0x1c(%rbp), %rax
movq %rax, -0x28(%rbp)
movl $0x16, -0x48(%rbp)
movl $0x7, -0x44(%rbp)
leaq -0x48(%rbp), %rax
movq %rax, -0x40(%rbp)
movq $0x2, -0x38(%rbp)
movq -0x40(%rbp), %rsi
movq -0x38(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x4b1(%rbp)
jmp 0xae3a
movb -0x4b1(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x4b2(%rbp)
jne 0xae4f
jmp 0xae80
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x4c0(%rbp)
jmp 0xae69
movq -0x4c0(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $0x1, %eax
sete %al
movb %al, -0x4b2(%rbp)
movb -0x4b2(%rbp), %al
testb $0x1, %al
jne 0xae8c
jmp 0xaede
movq -0x4b0(%rbp), %rdi
movl $0x18, -0x68(%rbp)
movw $0x0, -0x64(%rbp)
movq $0x0, -0x60(%rbp)
leaq -0x68(%rbp), %rsi
callq 0x3e40
jmp 0xaeb3
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movq -0x4b0(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
callq 0x3db0
jmp 0xc7b9
movl $0x7, -0x80(%rbp)
movl $0x16, -0x7c(%rbp)
leaq -0x80(%rbp), %rax
movq %rax, -0x78(%rbp)
movq $0x2, -0x70(%rbp)
movq -0x78(%rbp), %rsi
movq -0x70(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x4c1(%rbp)
jmp 0xaf15
movb -0x4c1(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x4c2(%rbp)
jne 0xaf2a
jmp 0xaf57
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x4d0(%rbp)
jmp 0xaf40
movq -0x4d0(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $0x1, %eax
sete %al
movb %al, -0x4c2(%rbp)
movb -0x4c2(%rbp), %al
testb $0x1, %al
jne 0xaf63
jmp 0xafa4
movq -0x4b0(%rbp), %rdi
movl $0x6, -0x90(%rbp)
movw $0x0, -0x8c(%rbp)
movq $0x0, -0x88(%rbp)
leaq -0x90(%rbp), %rsi
callq 0x3e40
jmp 0xaf96
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x2341(%rip), %xmm0     # 0xd2ec
movaps %xmm0, -0xc0(%rbp)
movl $0x10, -0xb0(%rbp)
leaq -0xc0(%rbp), %rax
movq %rax, -0xa0(%rbp)
movq $0x5, -0x98(%rbp)
movq -0xa0(%rbp), %rsi
movq -0x98(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x4d1(%rbp)
jmp 0xaff4
movb -0x4d1(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x4d2(%rbp)
jne 0xb009
jmp 0xb06d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x4e0(%rbp)
jmp 0xb023
movq -0x4e0(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
movb %al, -0x4d2(%rbp)
jne 0xb06d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x3, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x4e8(%rbp)
jmp 0xb056
movq -0x4e8(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $-0x1, %eax
sete %al
movb %al, -0x4d2(%rbp)
movb -0x4d2(%rbp), %al
testb $0x1, %al
jne 0xb079
jmp 0xb0ba
movq -0x4b0(%rbp), %rdi
movl $0x17, -0xd0(%rbp)
movw $0x0, -0xcc(%rbp)
movq $0x0, -0xc8(%rbp)
leaq -0xd0(%rbp), %rsi
callq 0x3e40
jmp 0xb0ac
movl -0x1c(%rbp), %eax
addl $0x4, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x7, -0xec(%rbp)
movl $0x3, -0xe8(%rbp)
movl $0x7, -0xe4(%rbp)
leaq -0xec(%rbp), %rax
movq %rax, -0xe0(%rbp)
movq $0x3, -0xd8(%rbp)
movq -0xe0(%rbp), %rsi
movq -0xd8(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x4e9(%rbp)
jmp 0xb110
movb -0x4e9(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x4ea(%rbp)
jne 0xb128
jmp 0xb1ed
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x4f8(%rbp)
jmp 0xb143
movq -0x4f8(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x504(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x500(%rbp)
jmp 0xb16e
movl -0x504(%rbp), %ecx
movq -0x500(%rbp), %rax
movswl 0x4(%rax), %edx
xorl %eax, %eax
cmpl %edx, %ecx
movb %al, -0x4ea(%rbp)
jne 0xb1ed
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x510(%rbp)
jmp 0xb1a1
movq -0x510(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x51c(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x518(%rbp)
jmp 0xb1cd
movl -0x51c(%rbp), %eax
movq -0x518(%rbp), %rcx
movswl 0x4(%rcx), %edx
xorl %ecx, %ecx
subl %edx, %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x4ea(%rbp)
movb -0x4ea(%rbp), %al
testb $0x1, %al
jne 0xb1f9
jmp 0xb26a
movl $0xe, -0x100(%rbp)
leaq -0xfc(%rbp), %rax
movq %rax, -0x530(%rbp)
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x528(%rbp)
jmp 0xb227
movq -0x4b0(%rbp), %rdi
movq -0x530(%rbp), %rax
movq -0x528(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0xf8(%rbp)
leaq -0x100(%rbp), %rsi
callq 0x3e40
jmp 0xb25c
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x208f(%rip), %xmm0     # 0xd300
movaps %xmm0, -0x130(%rbp)
movl $0x10, -0x120(%rbp)
leaq -0x130(%rbp), %rax
movq %rax, -0x110(%rbp)
movq $0x5, -0x108(%rbp)
movq -0x110(%rbp), %rsi
movq -0x108(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x531(%rbp)
jmp 0xb2ba
movb -0x531(%rbp), %al
testb $0x1, %al
jne 0xb2c9
jmp 0xb40e
movl $0x11, -0x140(%rbp)
leaq -0x13c(%rbp), %rax
movq %rax, -0x548(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x540(%rbp)
jmp 0xb2fb
movq -0x4b0(%rbp), %rdi
movq -0x548(%rbp), %rax
movq -0x540(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x138(%rbp)
leaq -0x140(%rbp), %rsi
callq 0x3e40
jmp 0xb330
movl $0x11, -0x150(%rbp)
leaq -0x14c(%rbp), %rax
movq %rax, -0x558(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x550(%rbp)
jmp 0xb363
movq -0x4b0(%rbp), %rdi
movq -0x558(%rbp), %rax
movq -0x550(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x148(%rbp)
leaq -0x150(%rbp), %rsi
callq 0x3e40
jmp 0xb398
movl $0x15, -0x160(%rbp)
leaq -0x15c(%rbp), %rax
movq %rax, -0x568(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x3, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x560(%rbp)
jmp 0xb3cb
movq -0x4b0(%rbp), %rdi
movq -0x568(%rbp), %rax
movq -0x560(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x158(%rbp)
leaq -0x160(%rbp), %rsi
callq 0x3e40
jmp 0xb400
movl -0x1c(%rbp), %eax
addl $0x4, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x1, -0x17c(%rbp)
movl $0x3, -0x178(%rbp)
movl $0x7, -0x174(%rbp)
leaq -0x17c(%rbp), %rax
movq %rax, -0x170(%rbp)
movq $0x3, -0x168(%rbp)
movq -0x170(%rbp), %rsi
movq -0x168(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x569(%rbp)
jmp 0xb464
movb -0x569(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x56a(%rbp)
jne 0xb47c
jmp 0xb540
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x578(%rbp)
jmp 0xb492
movq -0x578(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x584(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x580(%rbp)
jmp 0xb4bd
movl -0x584(%rbp), %ecx
movq -0x580(%rbp), %rax
movswl 0x4(%rax), %eax
xorl %edx, %edx
subl %eax, %edx
xorl %eax, %eax
cmpl %edx, %ecx
movb %al, -0x56a(%rbp)
jne 0xb540
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x590(%rbp)
jmp 0xb4f4
movq -0x590(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x59c(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x598(%rbp)
jmp 0xb520
movl -0x59c(%rbp), %eax
movq -0x598(%rbp), %rcx
movswl 0x4(%rcx), %edx
xorl %ecx, %ecx
subl %edx, %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x56a(%rbp)
movb -0x56a(%rbp), %al
testb $0x1, %al
jne 0xb54f
jmp 0xb5f3
movq -0x4b0(%rbp), %rdi
movl $0x4, -0x190(%rbp)
movw $0xffff, -0x18c(%rbp)   # imm = 0xFFFF
movq $0x0, -0x188(%rbp)
leaq -0x190(%rbp), %rsi
callq 0x3e40
jmp 0xb582
movl $0xe, -0x1a0(%rbp)
leaq -0x19c(%rbp), %rax
movq %rax, -0x5b0(%rbp)
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x5a8(%rbp)
jmp 0xb5b0
movq -0x4b0(%rbp), %rdi
movq -0x5b0(%rbp), %rax
movq -0x5a8(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x198(%rbp)
leaq -0x1a0(%rbp), %rsi
callq 0x3e40
jmp 0xb5e5
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x1d2a(%rip), %xmm0     # 0xd324
movaps %xmm0, -0x1c0(%rbp)
movups 0x1d0c(%rip), %xmm0     # 0xd314
movaps %xmm0, -0x1d0(%rbp)
leaq -0x1d0(%rbp), %rax
movq %rax, -0x1b0(%rbp)
movq $0x8, -0x1a8(%rbp)
movq -0x1b0(%rbp), %rsi
movq -0x1a8(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x5b1(%rbp)
jmp 0xb647
movb -0x5b1(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x5b2(%rbp)
jne 0xb65f
jmp 0xb79d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x5c0(%rbp)
jmp 0xb679
movq -0x5c0(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
movb %al, -0x5b2(%rbp)
jne 0xb79d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x3, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x5c8(%rbp)
jmp 0xb6b0
movq -0x5c8(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
movb %al, -0x5b2(%rbp)
jne 0xb79d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x5, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x5d0(%rbp)
jmp 0xb6e7
movq -0x5d0(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
movb %al, -0x5b2(%rbp)
jne 0xb79d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x5d8(%rbp)
jmp 0xb71e
movq -0x5d8(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x5e4(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x4, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x5e0(%rbp)
jmp 0xb74a
movl -0x5e4(%rbp), %eax
movq -0x5e0(%rbp), %rcx
movswl 0x4(%rcx), %ecx
addl %ecx, %eax
movl %eax, -0x5f4(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x6, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x5f0(%rbp)
jmp 0xb77e
movl -0x5f4(%rbp), %eax
movq -0x5f0(%rbp), %rcx
movswl 0x4(%rcx), %ecx
addl %ecx, %eax
cmpl $0x0, %eax
sete %al
movb %al, -0x5b2(%rbp)
movb -0x5b2(%rbp), %al
testb $0x1, %al
jne 0xb7ac
jmp 0xb8f0
movl $0x11, -0x1e0(%rbp)
leaq -0x1dc(%rbp), %rax
movq %rax, -0x608(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x600(%rbp)
jmp 0xb7df
movq -0x4b0(%rbp), %rdi
movq -0x608(%rbp), %rax
movq -0x600(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x1d8(%rbp)
leaq -0x1e0(%rbp), %rsi
callq 0x3e40
jmp 0xb814
movl $0x11, -0x1f0(%rbp)
leaq -0x1ec(%rbp), %rax
movq %rax, -0x618(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x4, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x610(%rbp)
jmp 0xb847
movq -0x610(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x624(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x620(%rbp)
jmp 0xb873
movq -0x4b0(%rbp), %rdi
movq -0x618(%rbp), %rax
movl -0x624(%rbp), %ecx
movq -0x620(%rbp), %rdx
movl 0x4(%rdx), %edx
addl %edx, %ecx
movw %cx, (%rax)
movq $0x0, -0x1e8(%rbp)
leaq -0x1f0(%rbp), %rsi
callq 0x3e40
jmp 0xb8af
movq -0x4b0(%rbp), %rdi
movl $0x12, -0x200(%rbp)
movw $0x0, -0x1fc(%rbp)
movq $0x0, -0x1f8(%rbp)
leaq -0x200(%rbp), %rsi
callq 0x3e40
jmp 0xb8e2
movl -0x1c(%rbp), %eax
addl $0x7, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x1a3d(%rip), %xmm0     # 0xd334
movaps %xmm0, -0x230(%rbp)
movabsq $0x1000000007, %rax     # imm = 0x1000000007
movq %rax, -0x220(%rbp)
leaq -0x230(%rbp), %rax
movq %rax, -0x210(%rbp)
movq $0x6, -0x208(%rbp)
movq -0x210(%rbp), %rsi
movq -0x208(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x625(%rbp)
jmp 0xb947
movb -0x625(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x626(%rbp)
jne 0xb95f
jmp 0xba2f
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x630(%rbp)
jmp 0xb979
movq -0x630(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
movb %al, -0x626(%rbp)
jne 0xba2f
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x3, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x638(%rbp)
jmp 0xb9b0
movq -0x638(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
movb %al, -0x626(%rbp)
jne 0xba2f
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x640(%rbp)
jmp 0xb9e3
movq -0x640(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x64c(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x4, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x648(%rbp)
jmp 0xba0f
movl -0x64c(%rbp), %eax
movq -0x648(%rbp), %rcx
movswl 0x4(%rcx), %edx
xorl %ecx, %ecx
subl %edx, %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x626(%rbp)
movb -0x626(%rbp), %al
testb $0x1, %al
jne 0xba3b
jmp 0xbab1
movl $0x3, -0x240(%rbp)
leaq -0x23c(%rbp), %rax
movq %rax, -0x660(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x658(%rbp)
jmp 0xba6e
movq -0x4b0(%rbp), %rdi
movq -0x660(%rbp), %rax
movq -0x658(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x238(%rbp)
leaq -0x240(%rbp), %rsi
callq 0x3e40
jmp 0xbaa3
movl -0x1c(%rbp), %eax
addl $0x5, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x1894(%rip), %xmm0     # 0xd34c
movaps %xmm0, -0x270(%rbp)
movabsq $0x1000000004, %rax     # imm = 0x1000000004
movq %rax, -0x260(%rbp)
leaq -0x270(%rbp), %rax
movq %rax, -0x250(%rbp)
movq $0x6, -0x248(%rbp)
movq -0x250(%rbp), %rsi
movq -0x248(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x661(%rbp)
jmp 0xbb08
movb -0x661(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x662(%rbp)
jne 0xbb20
jmp 0xbbf0
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x670(%rbp)
jmp 0xbb3b
movq -0x670(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
movb %al, -0x662(%rbp)
jne 0xbbf0
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x4, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x678(%rbp)
jmp 0xbb72
movq -0x678(%rbp), %rax
movswl 0x4(%rax), %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
movb %al, -0x662(%rbp)
jne 0xbbf0
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x680(%rbp)
jmp 0xbba4
movq -0x680(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x68c(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x3, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x688(%rbp)
jmp 0xbbd0
movl -0x68c(%rbp), %eax
movq -0x688(%rbp), %rcx
movswl 0x4(%rcx), %edx
xorl %ecx, %ecx
subl %edx, %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x662(%rbp)
movb -0x662(%rbp), %al
testb $0x1, %al
jne 0xbbfc
jmp 0xbc71
movl $0x3, -0x280(%rbp)
leaq -0x27c(%rbp), %rax
movq %rax, -0x6a0(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x698(%rbp)
jmp 0xbc2e
movq -0x4b0(%rbp), %rdi
movq -0x6a0(%rbp), %rax
movq -0x698(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x278(%rbp)
leaq -0x280(%rbp), %rsi
callq 0x3e40
jmp 0xbc63
movl -0x1c(%rbp), %eax
addl $0x5, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x16fc(%rip), %xmm0     # 0xd374
movaps %xmm0, -0x2a0(%rbp)
movups 0x16de(%rip), %xmm0     # 0xd364
movaps %xmm0, -0x2b0(%rbp)
leaq -0x2b0(%rbp), %rax
movq %rax, -0x290(%rbp)
movq $0x8, -0x288(%rbp)
movq -0x290(%rbp), %rsi
movq -0x288(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x6a1(%rbp)
jmp 0xbcc5
movb -0x6a1(%rbp), %al
testb $0x1, %al
jne 0xbcd4
jmp 0xbde8
movq -0x4b0(%rbp), %rdi
movl $0x0, -0x2c0(%rbp)
movw $0x6, -0x2bc(%rbp)
movq $0x0, -0x2b8(%rbp)
leaq -0x2c0(%rbp), %rsi
callq 0x3e40
jmp 0xbd07
movl $0x0, -0x2c4(%rbp)
cmpl $0x6, -0x2c4(%rbp)
jge 0xbda7
movl $0x11, -0x2d8(%rbp)
leaq -0x2d4(%rbp), %rax
movq %rax, -0x6b8(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %edx
movl -0x2c4(%rbp), %eax
movl %eax, %ecx
movl %edx, %eax
leal 0x1(%rax,%rcx), %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x6b0(%rbp)
jmp 0xbd5c
movq -0x4b0(%rbp), %rdi
movq -0x6b8(%rbp), %rax
movq -0x6b0(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x2d0(%rbp)
leaq -0x2d8(%rbp), %rsi
callq 0x3e40
jmp 0xbd91
jmp 0xbd93
movl -0x2c4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c4(%rbp)
jmp 0xbd11
movq -0x4b0(%rbp), %rdi
movl $0x14, -0x2e8(%rbp)
movw $0x0, -0x2e4(%rbp)
movq $0x0, -0x2e0(%rbp)
leaq -0x2e8(%rbp), %rsi
callq 0x3e40
jmp 0xbdda
movl -0x1c(%rbp), %eax
addl $0x7, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movups 0x1595(%rip), %xmm0     # 0xd384
movaps %xmm0, -0x310(%rbp)
movabsq $0x1000000007, %rax     # imm = 0x1000000007
movq %rax, -0x300(%rbp)
leaq -0x310(%rbp), %rax
movq %rax, -0x2f8(%rbp)
movq $0x6, -0x2f0(%rbp)
movq -0x2f8(%rbp), %rsi
movq -0x2f0(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x6b9(%rbp)
jmp 0xbe3f
movb -0x6b9(%rbp), %al
testb $0x1, %al
jne 0xbe4e
jmp 0xbf62
movq -0x4b0(%rbp), %rdi
movl $0x0, -0x320(%rbp)
movw $0x4, -0x31c(%rbp)
movq $0x0, -0x318(%rbp)
leaq -0x320(%rbp), %rsi
callq 0x3e40
jmp 0xbe81
movl $0x0, -0x324(%rbp)
cmpl $0x4, -0x324(%rbp)
jge 0xbf21
movl $0x11, -0x338(%rbp)
leaq -0x334(%rbp), %rax
movq %rax, -0x6d0(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %edx
movl -0x324(%rbp), %eax
movl %eax, %ecx
movl %edx, %eax
leal 0x1(%rax,%rcx), %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x6c8(%rbp)
jmp 0xbed6
movq -0x4b0(%rbp), %rdi
movq -0x6d0(%rbp), %rax
movq -0x6c8(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x330(%rbp)
leaq -0x338(%rbp), %rsi
callq 0x3e40
jmp 0xbf0b
jmp 0xbf0d
movl -0x324(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x324(%rbp)
jmp 0xbe8b
movq -0x4b0(%rbp), %rdi
movl $0x13, -0x348(%rbp)
movw $0x0, -0x344(%rbp)
movq $0x0, -0x340(%rbp)
leaq -0x348(%rbp), %rsi
callq 0x3e40
jmp 0xbf54
movl -0x1c(%rbp), %eax
addl $0x5, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x7, -0x364(%rbp)
movl $0x4, -0x360(%rbp)
movl $0x7, -0x35c(%rbp)
leaq -0x364(%rbp), %rax
movq %rax, -0x358(%rbp)
movq $0x3, -0x350(%rbp)
movq -0x358(%rbp), %rsi
movq -0x350(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x6d1(%rbp)
jmp 0xbfb8
movb -0x6d1(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x6d2(%rbp)
jne 0xbfcd
jmp 0xc02f
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x6e0(%rbp)
jmp 0xbfe3
movq -0x6e0(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x6ec(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x6e8(%rbp)
jmp 0xc00f
movl -0x6ec(%rbp), %eax
movq -0x6e8(%rbp), %rcx
movswl 0x4(%rcx), %edx
xorl %ecx, %ecx
subl %edx, %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x6d2(%rbp)
movb -0x6d2(%rbp), %al
testb $0x1, %al
jne 0xc03e
jmp 0xc116
movl $0x11, -0x378(%rbp)
leaq -0x374(%rbp), %rax
movq %rax, -0x700(%rbp)
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x6f8(%rbp)
jmp 0xc06c
movq -0x4b0(%rbp), %rdi
movq -0x700(%rbp), %rax
movq -0x6f8(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x370(%rbp)
leaq -0x378(%rbp), %rsi
callq 0x3e40
jmp 0xc0a1
movl $0xb, -0x388(%rbp)
leaq -0x384(%rbp), %rax
movq %rax, -0x710(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x708(%rbp)
jmp 0xc0d3
movq -0x4b0(%rbp), %rdi
movq -0x710(%rbp), %rax
movq -0x708(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x380(%rbp)
leaq -0x388(%rbp), %rsi
callq 0x3e40
jmp 0xc108
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x4, -0x3a0(%rbp)
movl $0x7, -0x39c(%rbp)
leaq -0x3a0(%rbp), %rax
movq %rax, -0x398(%rbp)
movq $0x2, -0x390(%rbp)
movq -0x398(%rbp), %rsi
movq -0x390(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x711(%rbp)
jmp 0xc162
movb -0x711(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x712(%rbp)
jne 0xc177
jmp 0xc1a4
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x720(%rbp)
jmp 0xc18d
movq -0x720(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $-0x1, %eax
sete %al
movb %al, -0x712(%rbp)
movb -0x712(%rbp), %al
testb $0x1, %al
jne 0xc1b0
jmp 0xc225
movl $0x1, -0x3b0(%rbp)
leaq -0x3ac(%rbp), %rax
movq %rax, -0x730(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x728(%rbp)
jmp 0xc1e2
movq -0x4b0(%rbp), %rdi
movq -0x730(%rbp), %rax
movq -0x728(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x3a8(%rbp)
leaq -0x3b0(%rbp), %rsi
callq 0x3e40
jmp 0xc217
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x4, -0x3c8(%rbp)
movl $0x7, -0x3c4(%rbp)
leaq -0x3c8(%rbp), %rax
movq %rax, -0x3c0(%rbp)
movq $0x2, -0x3b8(%rbp)
movq -0x3c0(%rbp), %rsi
movq -0x3b8(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x731(%rbp)
jmp 0xc271
movb -0x731(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x732(%rbp)
jne 0xc286
jmp 0xc2b3
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x740(%rbp)
jmp 0xc29c
movq -0x740(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $0x1, %eax
sete %al
movb %al, -0x732(%rbp)
movb -0x732(%rbp), %al
testb $0x1, %al
jne 0xc2bf
jmp 0xc334
movl $0x5, -0x3d8(%rbp)
leaq -0x3d4(%rbp), %rax
movq %rax, -0x750(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x748(%rbp)
jmp 0xc2f1
movq -0x4b0(%rbp), %rdi
movq -0x750(%rbp), %rax
movq -0x748(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x3d0(%rbp)
leaq -0x3d8(%rbp), %rsi
callq 0x3e40
jmp 0xc326
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x7, -0x3f0(%rbp)
movl $0x4, -0x3ec(%rbp)
leaq -0x3f0(%rbp), %rax
movq %rax, -0x3e8(%rbp)
movq $0x2, -0x3e0(%rbp)
movq -0x3e8(%rbp), %rsi
movq -0x3e0(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x751(%rbp)
jmp 0xc380
movb -0x751(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x752(%rbp)
jne 0xc395
jmp 0xc3c6
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x760(%rbp)
jmp 0xc3af
movq -0x760(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $0x1, %eax
sete %al
movb %al, -0x752(%rbp)
movb -0x752(%rbp), %al
testb $0x1, %al
jne 0xc3d2
jmp 0xc443
movl $0xa, -0x400(%rbp)
leaq -0x3fc(%rbp), %rax
movq %rax, -0x770(%rbp)
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x768(%rbp)
jmp 0xc400
movq -0x4b0(%rbp), %rdi
movq -0x770(%rbp), %rax
movq -0x768(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x3f8(%rbp)
leaq -0x400(%rbp), %rsi
callq 0x3e40
jmp 0xc435
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x7, -0x418(%rbp)
movl $0x4, -0x414(%rbp)
leaq -0x418(%rbp), %rax
movq %rax, -0x410(%rbp)
movq $0x2, -0x408(%rbp)
movq -0x410(%rbp), %rsi
movq -0x408(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x771(%rbp)
jmp 0xc48f
movb -0x771(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x772(%rbp)
jne 0xc4a4
jmp 0xc4d5
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x780(%rbp)
jmp 0xc4be
movq -0x780(%rbp), %rax
movswl 0x4(%rax), %eax
cmpl $-0x1, %eax
sete %al
movb %al, -0x772(%rbp)
movb -0x772(%rbp), %al
testb $0x1, %al
jne 0xc4e1
jmp 0xc552
movl $0x9, -0x428(%rbp)
leaq -0x424(%rbp), %rax
movq %rax, -0x790(%rbp)
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x788(%rbp)
jmp 0xc50f
movq -0x4b0(%rbp), %rdi
movq -0x790(%rbp), %rax
movq -0x788(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x420(%rbp)
leaq -0x428(%rbp), %rsi
callq 0x3e40
jmp 0xc544
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x2, -0x444(%rbp)
movl $0x4, -0x440(%rbp)
movl $0x10, -0x43c(%rbp)
leaq -0x444(%rbp), %rax
movq %rax, -0x438(%rbp)
movq $0x3, -0x430(%rbp)
movq -0x438(%rbp), %rsi
movq -0x430(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x791(%rbp)
jmp 0xc5a8
movb -0x791(%rbp), %al
testb $0x1, %al
jne 0xc5b7
jmp 0xc648
jmp 0xc5b9
movq -0x4b0(%rbp), %rdi
callq 0x5030
movq %rax, %rcx
movb $0x1, %al
cmpl $0x16, (%rcx)
movb %al, -0x792(%rbp)
je 0xc5ed
movq -0x4b0(%rbp), %rdi
callq 0x5030
cmpl $0x4, (%rax)
sete %al
movb %al, -0x792(%rbp)
movb -0x792(%rbp), %al
testb $0x1, %al
jne 0xc5f9
jmp 0xc607
movq -0x4b0(%rbp), %rdi
callq 0xc910
jmp 0xc5b9
movq -0x4b0(%rbp), %rdi
movl $0x16, -0x458(%rbp)
movw $0x0, -0x454(%rbp)
movq $0x0, -0x450(%rbp)
leaq -0x458(%rbp), %rsi
callq 0x3e40
jmp 0xc63a
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movl $0x2, -0x474(%rbp)
movl $0x7, -0x470(%rbp)
movl $0x10, -0x46c(%rbp)
leaq -0x474(%rbp), %rax
movq %rax, -0x468(%rbp)
movq $0x3, -0x460(%rbp)
movq -0x468(%rbp), %rsi
movq -0x460(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0xc7d0
movb %al, -0x793(%rbp)
jmp 0xc69e
movb -0x793(%rbp), %al
testb $0x1, %al
jne 0xc6aa
jmp 0xc71c
movl $0x8, -0x488(%rbp)
leaq -0x484(%rbp), %rax
movq %rax, -0x7a8(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
incl %eax
movslq %eax, %rsi
callq 0xc8d0
movq %rax, -0x7a0(%rbp)
jmp 0xc6dc
movq -0x4b0(%rbp), %rdi
movq -0x7a8(%rbp), %rax
movq -0x7a0(%rbp), %rcx
movw 0x4(%rcx), %cx
movw %cx, (%rax)
movq $0x0, -0x480(%rbp)
leaq -0x488(%rbp), %rsi
callq 0x3e40
jmp 0xc711
movl -0x1c(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x1c(%rbp)
jmp 0xc749
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0xc8d0
movq %rax, -0x7b0(%rbp)
jmp 0xc732
movq -0x7b0(%rbp), %rsi
movq -0x4b0(%rbp), %rdi
callq 0xc940
jmp 0xc747
jmp 0xc749
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xade7
testb $0x1, -0x11(%rbp)
je 0xc793
movq -0x4b0(%rbp), %rsi
leaq -0x4a0(%rbp), %rdi
xorl %edx, %edx
callq 0xada0
jmp 0xc774
movq -0x4b0(%rbp), %rdi
leaq -0x4a0(%rbp), %rsi
callq 0x3e10
leaq -0x4a0(%rbp), %rdi
callq 0x3db0
movb $0x1, -0x12(%rbp)
testb $0x1, -0x12(%rbp)
jne 0xc7a9
movq -0x4b0(%rbp), %rdi
callq 0x3db0
movq -0x4a8(%rbp), %rax
addq $0x7b0, %rsp            # imm = 0x7B0
popq %rbp
retq
movq -0x50(%rbp), %rdi
callq 0x2330
nopw %cs:(%rax,%rax)