// File: /workspace/github_c_makefile_star2_O3/GangZhuo[P]dohclient/src/dohclient-cache.c
// Function: main
int main(int argc, char **argv)
{
	int ch, i, n, r;
	char buf[1024];
	char *pkg = buf + 2; /* 2 bytes length for TCP */
	int pkgsize = sizeof(buf) - 2;

#ifdef WINDOWS
	win_init();
#endif

	while ((ch = getopt(argc, argv, "s:t:Tvh")) != -1) {
		switch (ch) {
		case 'h':
			usage();
			exit(0);
			break;
		case 'v':
			fprintf(stdout, DOHCLIENT_NAME "-cache v" DOHCLIENT_VERSION "%s\n", git_version());
			exit(0);
			break;
		case 's':
			host = optarg;
			break;
		case 't':
			if (!is_digitstr(optarg)) {
				fprintf(stderr, "Invalid timeout -- %s\n", optarg);
				exit(1);
			}
			timeout = atoi(optarg);
			break;
		case 'T':
			tcp_mode = TRUE;
			break;
		case '?':
		default:
			exit(1);
			break;
		}
	}

	if (optind < argc)
		cmd = argv[optind++];

	for (i = optind; i < argc && cmd_arg_len < MAX_CMD_ARGS; i++) {
		cmd_args[cmd_arg_len++] = argv[i];
	}

	if (!cmd) {
		fprintf(stderr, "No command\n");
		exit(1);
	}

	if (timeout <= 0) {
		fprintf(stderr, "Invalid timeout\n");
		exit(1);
	}

	if (str2addr(host, server_addr, "5354")) {
		fprintf(stderr, "Invalid host address\n");
		exit(1);
	}

	if (strcasecmp(cmd, "GET") == 0) {
		if (cmd_arg_len < 2) {
			fprintf(stderr, "Missing arguments\n");
			exit(1);
		}
		else if (cmd_arg_len > 2) {
			for (i = 2; i < cmd_arg_len; i++) {
				fprintf(stderr, "Invalid argument -- %s\n", cmd_args[i]);
			}
			exit(1);
		}
		if (strcmp(cmd_args[0], "A") && strcmp(cmd_args[0], "AAAA")) {
			fprintf(stderr,
					"Invalid qtype -- %s\n"
					"Available value should be \"A\" or \"AAAA\".\n",
					cmd_args[0]);
			exit(1);
		}
		n = snprintf(pkg, pkgsize,
				"GET '%s IN %s.'", cmd_args[0], cmd_args[1]);
		if (n <= 0 || n >= pkgsize) {
			fprintf(stderr, "Domain too long -- %s\n", cmd_args[1]);
			exit(1);
		}
	}
	else if (strcasecmp(cmd, "LIST") == 0) {
		const char *keyword = "";
		int offset = 0, limit = 0;
		if (cmd_arg_len > 4) {
			for (i = 4; i < cmd_arg_len; i++) {
				fprintf(stderr, "Invalid argument -- %s\n", cmd_args[i]);
			}
			exit(1);
		}
		if (cmd_arg_len > 0)
			keyword = cmd_args[0];
		if (cmd_arg_len > 1)
			offset = atoi(cmd_args[1]);
		if (cmd_arg_len > 2)
			limit = atoi(cmd_args[2]);
		n = snprintf(pkg, pkgsize, "LIST '%s' %d %d", keyword, offset, limit);
		assert(n > 0 && n < pkgsize);
	}
	else if (strcasecmp(cmd, "PUT") == 0) {
		if (cmd_arg_len < 3) {
			fprintf(stderr, "Missing arguments\n");
			exit(1);
		}
		else if (cmd_arg_len > 4) {
			for (i = 4; i < cmd_arg_len; i++) {
				fprintf(stderr, "Invalid argument -- %s\n", cmd_args[i]);
			}
			exit(1);
		}
		if (strcmp(cmd_args[1], "A") && strcmp(cmd_args[1], "AAAA")) {
			fprintf(stderr,
					"Invalid type -- %s\n"
					"Available value should be \"A\" or \"AAAA\".\n",
					cmd_args[1]);
			exit(1);
		}
		if (cmd_arg_len == 4) {
			if (!is_digitstr(cmd_args[3])) {
				fprintf(stderr, "Invalid TTL -- %s\n", cmd_args[3]);
				exit(1);
			}
		}
		if (cmd_arg_len == 4) {
			n = snprintf(pkg, pkgsize,
					"PUT %s. %s %s %s",
					cmd_args[0], cmd_args[1], cmd_args[2], cmd_args[3]);
		}
		else {
			n = snprintf(pkg, pkgsize,
					"PUT %s. %s %s",
					cmd_args[0], cmd_args[1], cmd_args[2]);
		}
		if (n <= 0 || n >= pkgsize) {
			fprintf(stderr, "Domain or IP too long -- %s %s\n", cmd_args[0], cmd_args[2]);
			exit(1);
		}
	}
	else if (strcasecmp(cmd, "DELETE") == 0) {
		if (cmd_arg_len < 2) {
			fprintf(stderr, "Missing arguments\n");
			exit(1);
		}
		else if (cmd_arg_len > 2) {
			for (i = 2; i < cmd_arg_len; i++) {
				fprintf(stderr, "Invalid argument -- %s\n", cmd_args[i]);
			}
			exit(1);
		}
		if (strcasecmp(cmd_args[0], "A") && strcasecmp(cmd_args[0], "AAAA")) {
			fprintf(stderr,
					"Invalid qtype -- %s\n"
					"Available value should be \"A\" or \"AAAA\".\n",
					cmd_args[0]);
			exit(1);
		}
		n = snprintf(pkg, pkgsize,
				"DELETE '%s IN %s.'", cmd_args[0], cmd_args[1]);
		if (n <= 0 || n >= pkgsize) {
			fprintf(stderr, "Domain too long -- %s\n", cmd_args[1]);
			exit(1);
		}
	}
	else if (strcasecmp(cmd, "SAVE") == 0) {
		if (cmd_arg_len < 1) {
			fprintf(stderr, "Missing arguments\n");
			exit(1);
		}
		else if (cmd_arg_len > 1) {
			for (i = 1; i < cmd_arg_len; i++) {
				fprintf(stderr, "Invalid argument -- %s\n", cmd_args[i]);
			}
			exit(1);
		}
		n = snprintf(pkg, pkgsize,
				"SAVE \"%s\"", cmd_args[0]);
		if (n <= 0 || n >= pkgsize) {
			fprintf(stderr, "Filename too long -- %s\n", cmd_args[0]);
			exit(1);
		}
	}
	else if (strcasecmp(cmd, "LOAD") == 0) {
		const char *override = "";
		if (cmd_arg_len < 1) {
			fprintf(stderr, "Missing arguments\n");
			exit(1);
		}
		else if (cmd_arg_len > 2) {
			for (i = 2; i < cmd_arg_len; i++) {
				fprintf(stderr, "Invalid argument -- %s\n", cmd_args[i]);
			}
			exit(1);
		}
		if (cmd_arg_len > 1) {
			if (strcasecmp(cmd_args[1], "override")) {
				fprintf(stderr,
						"Unknown argument -- %s\n"
						"May be \"override\"?\n",
						cmd_args[1]);
				exit(1);
			}
			else {
				override = cmd_args[1];
			}
		}
		n = snprintf(pkg, pkgsize,
				"LOAD \"%s\" \"%s\"", cmd_args[0], override);
		if (n <= 0 || n >= pkgsize) {
			fprintf(stderr, "Filename too long -- %s\n", cmd_args[0]);
			exit(1);
		}
	}
	else {
		fprintf(stderr, "Invalid command -- %s\n", cmd);
		exit(1);
	}

	/*fprintf(stdout, "%s\n", pkg);*/

	if (tcp_mode)
		r = send_by_tcp(pkg, n);
	else
		r = send_by_udp(pkg, n);

	print_leak();

	return r;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x648, %rsp            # imm = 0x648
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x1607(%rip), %r14      # 0x76e0
movq 0x5ee8(%rip), %r12      # 0xbfc8
movl %ebp, %edi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x2090
cmpl $0x72, %eax
jle 0x6124
cmpl $0x73, %eax
je 0x6132
cmpl $0x74, %eax
jne 0x6d30
movq (%r12), %r15
movq %r15, %rdi
callq 0x6de7
movq %r15, %rdi
testl %eax, %eax
je 0x6d67
callq 0x2320
movl %eax, 0x60f6(%rip)      # 0xc218
jmp 0x60e0
cmpl $0x54, %eax
jne 0x613f
movb $0x1, 0x61d0(%rip)      # 0xc300
jmp 0x60e0
movq (%r12), %rax
movq %rax, 0x60d3(%rip)      # 0xc210
jmp 0x60e0
cmpl $-0x1, %eax
jne 0x6d56
movq 0x5e91(%rip), %rcx      # 0xbfe0
movl (%rcx), %eax
cmpl %ebp, %eax
jge 0x6167
movslq %eax, %rdx
incl %eax
movl %eax, (%rcx)
movq (%rbx,%rdx,8), %rcx
movq %rcx, 0x61a1(%rip)      # 0xc308
movl 0x61a2(%rip), %r14d     # 0xc310
cmpl %ebp, %eax
setl %cl
cmpl $0x4, %r14d
setl %dl
andb %cl, %dl
cmpb $0x1, %dl
jne 0x61d5
movl %r14d, %ecx
leaq 0x6195(%rip), %rdx      # 0xc320
leaq (%rdx,%rcx,8), %rdi
movslq %eax, %r15
leaq (%rbx,%r15,8), %rsi
notl %eax
addl %ebp, %eax
movl $0x3, %ecx
subl %r14d, %ecx
cmpl %ecx, %eax
cmovbl %eax, %ecx
leaq 0x8(,%rcx,8), %rdx
callq 0x21a0
movslq %ebp, %rax
incq %r15
leal 0x1(%r14), %ecx
cmpq %rax, %r15
jge 0x61cf
incq %r15
cmpl $0x3, %r14d
movl %ecx, %r14d
jl 0x61ba
movl %ecx, 0x613b(%rip)      # 0xc310
cmpq $0x0, 0x612b(%rip)      # 0xc308
je 0x6d76
cmpl $0x0, 0x602e(%rip)      # 0xc218
jle 0x6d7b
movq 0x6019(%rip), %rdi      # 0xc210
leaq 0x6142(%rip), %rsi      # 0xc340
leaq 0x1c4e(%rip), %rdx      # 0x7e53
callq 0x38b1
testl %eax, %eax
jne 0x6d80
movq 0x60ef(%rip), %rbx      # 0xc308
leaq 0x152c(%rip), %rsi      # 0x774c
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
je 0x62cf
leaq 0x15ae(%rip), %rsi      # 0x77e5
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
je 0x634c
leaq 0x15ee(%rip), %rsi      # 0x783c
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
je 0x6361
leaq 0x166a(%rip), %rsi      # 0x78cf
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
je 0x6461
leaq 0x166d(%rip), %rsi      # 0x78e9
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
je 0x6529
leaq 0x167e(%rip), %rsi      # 0x7911
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
jne 0x6da4
movl 0x6067(%rip), %eax      # 0xc310
testl %eax, %eax
jle 0x6dac
cmpl $0x3, %eax
jae 0x6db1
cmpl $0x1, %eax
jne 0x6575
leaq 0x1cd9(%rip), %rbx      # 0x7fa3
jmp 0x6593
movl 0x603b(%rip), %eax      # 0xc310
cmpl $0x1, %eax
jle 0x6d85
cmpl $0x2, %eax
jne 0x6d8a
movq 0x6032(%rip), %rbx      # 0xc320
cmpb $0x41, (%rbx)
jne 0x62f9
cmpb $0x0, 0x1(%rbx)
je 0x6310
leaq 0x147b(%rip), %rsi      # 0x777b
movq %rbx, %rdi
callq 0x2300
testl %eax, %eax
jne 0x6d8f
movq 0x6011(%rip), %r8       # 0xc328
leaq 0x14a0(%rip), %rdx      # 0x77be
movl $0x3fe, %esi            # imm = 0x3FE
leaq 0x242(%rsp), %rdi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x2330
movl %eax, %ebx
movl $0xfffffc02, %eax       # imm = 0xFFFFFC02
leal (%rbx,%rax), %ecx
cmpl %eax, %ecx
ja 0x65ca
callq 0x2bca
movl 0x5fbd(%rip), %r15d     # 0xc310
testl %r15d, %r15d
jle 0x63d7
movq 0x5fc1(%rip), %rbx      # 0xc320
jmp 0x63de
movl 0x5fa9(%rip), %ebp      # 0xc310
cmpl $0x2, %ebp
jle 0x6d97
movq 0x5fb1(%rip), %rbx      # 0xc328
cmpb $0x41, (%rbx)
jne 0x6382
cmpb $0x0, 0x1(%rbx)
je 0x6399
leaq 0x13f2(%rip), %rsi      # 0x777b
movq %rbx, %rdi
callq 0x2300
testl %eax, %eax
jne 0x6d9c
cmpl $0x4, %ebp
jne 0x64e6
movq 0x5f8f(%rip), %r14      # 0xc338
movq %r14, %rdi
callq 0x6de7
testl %eax, %eax
je 0x6dc5
movq 0x5f60(%rip), %rcx      # 0xc320
movq 0x5f69(%rip), %r9       # 0xc330
movq %r14, (%rsp)
leaq 0x14be(%rip), %rdx      # 0x7890
jmp 0x64fb
leaq 0x1bc5(%rip), %rbx      # 0x7fa3
xorl %ebp, %ebp
cmpl $0x2, %r15d
jl 0x640b
movq 0x5f3b(%rip), %rdi      # 0xc328
callq 0x2320
movl %eax, %r14d
cmpl $0x2, %r15d
je 0x640e
movq 0x5f2e(%rip), %rdi      # 0xc330
callq 0x2320
movl %eax, %ebp
jmp 0x640e
xorl %r14d, %r14d
leaq 0x13d5(%rip), %rdx      # 0x77ea
movl $0x3fe, %esi            # imm = 0x3FE
leaq 0x242(%rsp), %rdi
movq %rbx, %rcx
movl %r14d, %r8d
movl %ebp, %r9d
xorl %eax, %eax
callq 0x2330
movl %eax, %ebx
leal -0x1(%rbx), %eax
cmpl $0x3fd, %eax            # imm = 0x3FD
jb 0x65ca
leaq 0x13b1(%rip), %rdi      # 0x77fa
leaq 0x13bf(%rip), %rsi      # 0x780f
leaq 0x13ce(%rip), %rcx      # 0x7825
movl $0x1e4, %edx            # imm = 0x1E4
callq 0x2140
movl 0x5ea9(%rip), %eax      # 0xc310
cmpl $0x1, %eax
jle 0x6dbb
cmpl $0x2, %eax
jne 0x6dc0
movq 0x5ea0(%rip), %rbx      # 0xc320
leaq 0x12f7(%rip), %rsi      # 0x777e
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
je 0x64aa
leaq 0x12e1(%rip), %rsi      # 0x777b
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
jne 0x6dd7
movq 0x5e77(%rip), %r8       # 0xc328
leaq 0x141e(%rip), %rdx      # 0x78d6
movl $0x3fe, %esi            # imm = 0x3FE
leaq 0x242(%rsp), %rdi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x2330
movl %eax, %ebx
movl $0xfffffc02, %eax       # imm = 0xFFFFFC02
leal (%rbx,%rax), %ecx
cmpl %eax, %ecx
ja 0x65ca
callq 0x25fa
movq 0x5e33(%rip), %rcx      # 0xc320
movq 0x5e3c(%rip), %r9       # 0xc330
leaq 0x13a6(%rip), %rdx      # 0x78a1
movl $0x3fe, %esi            # imm = 0x3FE
leaq 0x242(%rsp), %rdi
movq %rbx, %r8
xorl %eax, %eax
callq 0x2330
movl %eax, %ebx
movl $0xfffffc02, %eax       # imm = 0xFFFFFC02
leal (%rbx,%rax), %ecx
cmpl %eax, %ecx
ja 0x65ca
callq 0x266b
movl 0x5de1(%rip), %eax      # 0xc310
testl %eax, %eax
jle 0x6dcd
cmpl $0x1, %eax
jne 0x6dd2
movq 0x5dd9(%rip), %rcx      # 0xc320
leaq 0x13a0(%rip), %rdx      # 0x78ee
movl $0x3fe, %esi            # imm = 0x3FE
leaq 0x242(%rsp), %rdi
xorl %eax, %eax
callq 0x2330
movl %eax, %ebx
movl $0xfffffc02, %eax       # imm = 0xFFFFFC02
leal (%rbx,%rax), %ecx
cmpl %eax, %ecx
ja 0x65ca
callq 0x2540
movq 0x5dac(%rip), %rbx      # 0xc328
leaq 0x1393(%rip), %rsi      # 0x7916
movq %rbx, %rdi
callq 0x2240
testl %eax, %eax
jne 0x6ddf
movq 0x5d86(%rip), %rcx      # 0xc320
leaq 0x13a9(%rip), %rdx      # 0x794a
movl $0x3fe, %esi            # imm = 0x3FE
leaq 0x242(%rsp), %rdi
movq %rbx, %r8
xorl %eax, %eax
callq 0x2330
movl %eax, %ebx
movl $0xfffffc02, %eax       # imm = 0xFFFFFC02
leal (%rbx,%rax), %ecx
cmpl %eax, %ecx
jbe 0x6db6
cmpb $0x1, 0x5d2f(%rip)      # 0xc300
jne 0x6979
leaq 0x1c0(%rsp), %rdi
movq $0x0, 0x10(%rdi)
movl 0x5dd3(%rip), %ebp      # 0xc3c0
leaq 0x240(%rsp), %rax
movq %rax, (%rdi)
movl $0x0, 0xc(%rdi)
leal 0x2(%rbx), %eax
movl %eax, 0x8(%rdi)
movl %eax, 0x10(%rdi)
xorl %esi, %esi
movl %ebx, %edx
movl $0x2, %ecx
callq 0x4fbc
movzwl 0x5d23(%rip), %edi      # 0xc340
movl $0x1, %esi
movl $0x6, %edx
callq 0x20a0
cmpl $-0x1, %eax
je 0x6c63
movl %eax, %r14d
movl %eax, %r15d
movl %r14d, %edi
callq 0x33cf
testl %eax, %eax
jne 0x6c8e
movl %r15d, %edi
callq 0x3477
testl %eax, %eax
jne 0x6ca2
movl %r15d, %edi
callq 0x34fa
testl %eax, %eax
jne 0x6cb6
leaq 0x5cce(%rip), %rsi      # 0xc340
movl %r15d, %edi
movl %ebp, %edx
callq 0x21b0
testl %eax, %eax
je 0x6695
callq 0x2030
movl (%rax), %edi
cmpl $0xb, %edi
je 0x6695
cmpl $0x73, %edi
jne 0x6d05
movq $0x0, 0x18(%rsp)
xorl %edi, %edi
callq 0x21e0
movq %rax, 0x8(%rsp)
leal 0x3f(%r14), %eax
testl %r14d, %r14d
cmovnsl %r14d, %eax
movl %eax, %edx
andl $-0x40, %edx
movl %r14d, %ecx
subl %edx, %ecx
movl $0x1, %ebx
shlq %cl, %rbx
sarl $0x6, %eax
movslq %eax, %r12
incl %r14d
movl $0xffffffff, 0x10(%rsp) # imm = 0xFFFFFFFF
xorl %r13d, %r13d
xorps %xmm0, %xmm0
movaps %xmm0, 0x1b0(%rsp)
movaps %xmm0, 0x1a0(%rsp)
movaps %xmm0, 0x190(%rsp)
movaps %xmm0, 0x180(%rsp)
movaps %xmm0, 0x170(%rsp)
movaps %xmm0, 0x160(%rsp)
movaps %xmm0, 0x150(%rsp)
movaps %xmm0, 0x140(%rsp)
movaps %xmm0, 0xc0(%rsp)
movaps %xmm0, 0xd0(%rsp)
movaps %xmm0, 0xe0(%rsp)
movaps %xmm0, 0xf0(%rsp)
movaps %xmm0, 0x100(%rsp)
movaps %xmm0, 0x110(%rsp)
movaps %xmm0, 0x120(%rsp)
movaps %xmm0, 0x130(%rsp)
movaps %xmm0, 0x40(%rsp)
movaps %xmm0, 0x50(%rsp)
movaps %xmm0, 0x60(%rsp)
movaps %xmm0, 0x70(%rsp)
movaps %xmm0, 0x80(%rsp)
movaps %xmm0, 0x90(%rsp)
testl %r13d, %r13d
leaq 0x140(%rsp), %rsi
movq %rsi, %rax
leaq 0xc0(%rsp), %rdx
cmoveq %rdx, %rax
movaps %xmm0, 0xa0(%rsp)
orq %rbx, (%rax,%r12,8)
movaps %xmm0, 0xb0(%rsp)
orq %rbx, 0x40(%rsp,%r12,8)
movq $0x0, 0x28(%rsp)
movq $0xc350, 0x30(%rsp)     # imm = 0xC350
movl %r14d, %edi
leaq 0x40(%rsp), %rcx
leaq 0x28(%rsp), %r8
callq 0x21f0
cmpl $-0x1, %eax
je 0x6c77
testq %rbx, 0x40(%rsp,%r12,8)
jne 0x6c84
testq %rbx, 0x140(%rsp,%r12,8)
je 0x6906
movq %r14, %rbp
movslq 0x1c8(%rsp), %rdx
movq %rdx, %rsi
addq 0x1c0(%rsp), %rsi
notl %edx
addl 0x1d0(%rsp), %edx
movl %r15d, %r14d
movl %r15d, %edi
callq 0x4620
testl %eax, %eax
jle 0x6871
movl %eax, %r15d
movq 0x1c0(%rsp), %rax
movslq 0x1c8(%rsp), %rcx
movslq %r15d, %rdx
addq %rcx, %rdx
movb $0x0, (%rax,%rdx)
cmpl $-0x1, 0x10(%rsp)
je 0x6882
movq 0x5764(%rip), %rax      # 0xbfb8
movq (%rax), %rsi
movq 0x1c0(%rsp), %rdi
callq 0x2260
movq 0x18(%rsp), %rax
addl %r15d, %eax
movq %rax, %r15
jmp 0x68ea
movl %r14d, %r15d
movq %rbp, %r14
jns 0x6906
jmp 0x6c47
addl 0x1c8(%rsp), %r15d
movl %r15d, 0x1c8(%rsp)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpl $0x2, %r15d
movq 0x18(%rsp), %r15
jl 0x68ee
leaq 0x1c0(%rsp), %rdi
movl $0x2, %esi
callq 0x5320
movl %eax, 0x10(%rsp)
movl 0x1c8(%rsp), %r15d
addl $-0x2, %r15d
movl $0x0, 0x1c8(%rsp)
movq 0x56e2(%rip), %rax      # 0xbfb8
movq (%rax), %rsi
movq 0x1c0(%rsp), %rdi
addq $0x2, %rdi
callq 0x2260
movl 0x10(%rsp), %eax
movq %r15, 0x18(%rsp)
movl %eax, 0x10(%rsp)
cmpl %eax, %r15d
movl %r14d, %r15d
movq %rbp, %r14
jge 0x6c24
testq %rbx, 0xc0(%rsp,%r12,8)
je 0x6955
movl %r15d, %edi
leaq 0x1c0(%rsp), %rsi
callq 0x44f2
cmpl $-0x1, %eax
je 0x6cef
leaq 0x5aa0(%rip), %rax      # 0xc3d0
movq %rax, 0x1c0(%rsp)
movq $0x0, 0x1c8(%rsp)
movl $0x200000, 0x1d0(%rsp) # imm = 0x200000
movl $0x1, %r13d
xorl %edi, %edi
callq 0x21e0
subl 0x8(%rsp), %eax
cmpl %eax, 0x58b2(%rip)      # 0xc218
jge 0x66db
movl %r15d, %edi
callq 0x2b2a
jmp 0x6d0d
movl 0x5a41(%rip), %eax      # 0xc3c0
movl %eax, 0x18(%rsp)
movzwl 0x59b6(%rip), %edi      # 0xc340
movl $0x2, %esi
movl $0x11, %edx
callq 0x20a0
cmpl $-0x1, %eax
je 0x6c6d
movl %eax, %r13d
movl %eax, %edi
callq 0x33cf
testl %eax, %eax
jne 0x6c98
movl %r13d, %edi
callq 0x3477
testl %eax, %eax
jne 0x6cac
xorl %r14d, %r14d
xorl %edi, %edi
callq 0x21e0
leal 0x3f(%r13), %edx
testl %r13d, %r13d
cmovnsl %r13d, %edx
movl %edx, %esi
andl $-0x40, %esi
movl %r13d, %ecx
subl %esi, %ecx
movl $0x1, %r15d
shlq %cl, %r15
movq %rax, 0x10(%rsp)
sarl $0x6, %edx
movslq %edx, %r12
movq %r13, 0x8(%rsp)
incl %r13d
movl %ebx, %eax
movq %rax, 0x38(%rsp)
leaq 0xc0(%rsp), %rbx
leaq 0x140(%rsp), %rbp
xorps %xmm0, %xmm0
movaps %xmm0, 0x1b0(%rsp)
movaps %xmm0, 0x1a0(%rsp)
movaps %xmm0, 0x190(%rsp)
movaps %xmm0, 0x180(%rsp)
movaps %xmm0, 0x170(%rsp)
movaps %xmm0, 0x160(%rsp)
movaps %xmm0, 0x150(%rsp)
movaps %xmm0, 0x140(%rsp)
movaps %xmm0, 0xc0(%rsp)
movaps %xmm0, 0xd0(%rsp)
movaps %xmm0, 0xe0(%rsp)
movaps %xmm0, 0xf0(%rsp)
movaps %xmm0, 0x100(%rsp)
movaps %xmm0, 0x110(%rsp)
movaps %xmm0, 0x120(%rsp)
movaps %xmm0, 0x130(%rsp)
movaps %xmm0, 0x40(%rsp)
movaps %xmm0, 0x50(%rsp)
movaps %xmm0, 0x60(%rsp)
movaps %xmm0, 0x70(%rsp)
movaps %xmm0, 0x80(%rsp)
movaps %xmm0, 0x90(%rsp)
testl %r14d, %r14d
movq %rbp, %rax
cmoveq %rbx, %rax
movaps %xmm0, 0xa0(%rsp)
orq %r15, (%rax,%r12,8)
movaps %xmm0, 0xb0(%rsp)
orq %r15, 0x40(%rsp,%r12,8)
movq $0x0, 0x28(%rsp)
movq $0xc350, 0x30(%rsp)     # imm = 0xC350
movl %r13d, %edi
movq %rbp, %rsi
movq %rbx, %rdx
leaq 0x40(%rsp), %rcx
leaq 0x28(%rsp), %r8
callq 0x21f0
cmpl $-0x1, %eax
je 0x6cc0
testq %r15, 0x40(%rsp,%r12,8)
jne 0x6ccc
testq %r15, 0x140(%rsp,%r12,8)
jne 0x6b8c
testq %r15, 0xc0(%rsp,%r12,8)
je 0x6b66
movq 0x8(%rsp), %rdi
leaq 0x242(%rsp), %rsi
movq 0x38(%rsp), %rdx
xorl %ecx, %ecx
leaq 0x57f3(%rip), %r8       # 0xc340
movl 0x18(%rsp), %r9d
callq 0x2050
movl $0x1, %r14d
cmpl $-0x1, %eax
je 0x6cf9
xorl %edi, %edi
callq 0x21e0
subl 0x10(%rsp), %eax
cmpl %eax, 0x56a1(%rip)      # 0xc218
jge 0x6a16
movq 0x8(%rsp), %rdi
callq 0x28a9
jmp 0x6d0d
xorps %xmm0, %xmm0
leaq 0x1c0(%rsp), %r8
movaps %xmm0, 0x70(%r8)
movaps %xmm0, 0x60(%r8)
movaps %xmm0, 0x50(%r8)
movaps %xmm0, 0x40(%r8)
movaps %xmm0, 0x30(%r8)
movaps %xmm0, 0x20(%r8)
movaps %xmm0, 0x10(%r8)
movaps %xmm0, (%r8)
leaq 0x24(%rsp), %r9
movl $0x80, (%r9)
leaq 0x57ff(%rip), %r14      # 0xc3d0
xorl %ebx, %ebx
movl $0x1fffff, %edx         # imm = 0x1FFFFF
movq 0x8(%rsp), %r15
movl %r15d, %edi
movq %r14, %rsi
xorl %ecx, %ecx
callq 0x2180
testl %eax, %eax
jle 0x6cd8
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movb $0x0, (%rax,%r14)
movq 0x53b5(%rip), %rax      # 0xbfb8
movq (%rax), %rdi
leaq 0xd7c(%rip), %rsi       # 0x7989
movq %r14, %rdx
xorl %eax, %eax
callq 0x2310
movl %r15d, %edi
callq 0x23b0
jmp 0x6d12
movq 0x538d(%rip), %rax      # 0xbfb8
movq (%rax), %rsi
movl $0xa, %edi
callq 0x22b0
movl %r15d, %edi
callq 0x23b0
xorl %ebx, %ebx
jmp 0x6d12
callq 0x2030
movl (%rax), %edi
testl %edi, %edi
jne 0x6d26
movl %r15d, %edi
callq 0x23b0
jmp 0x6d0d
callq 0x2b92
jmp 0x6d0d
callq 0x2911
jmp 0x6d0d
movl %r15d, %edi
callq 0x2b52
jmp 0x6d0d
movl %r15d, %edi
callq 0x2a5c
jmp 0x6d0d
movl %r15d, %edi
callq 0x2948
jmp 0x6d0d
movl %r13d, %edi
callq 0x2750
jmp 0x6d0d
movl %r15d, %edi
callq 0x2988
jmp 0x6d0d
movl %r13d, %edi
callq 0x278f
jmp 0x6d0d
movl %r15d, %edi
callq 0x29c8
jmp 0x6d0d
movq 0x8(%rsp), %rdi
callq 0x28d1
jmp 0x6d0d
movq 0x8(%rsp), %rdi
callq 0x27ce
jmp 0x6d0d
leaq 0x24(%rsp), %rsi
leaq 0x1c0(%rsp), %rdx
movl %r15d, %edi
callq 0x280e
jmp 0x6d0d
movl %r15d, %edi
callq 0x2acf
jmp 0x6d0d
movq 0x8(%rsp), %rdi
callq 0x284e
jmp 0x6d0d
movl %r15d, %esi
callq 0x2a08
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
addq $0x648, %rsp            # imm = 0x648
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x2a9c
jmp 0x6c56
cmpl $0x76, %eax
jne 0x6d6c
movq 0x527c(%rip), %rax      # 0xbfb8
movq (%rax), %rdi
leaq 0x9a2(%rip), %rsi       # 0x76e8
leaq 0x10f3(%rip), %rdx      # 0x7e40
xorl %eax, %eax
callq 0x2310
jmp 0x6d60
cmpl $0x68, %eax
jne 0x6d6c
callq 0x6e27
xorl %edi, %edi
callq 0x22a0
callq 0x23d0
movl $0x1, %edi
callq 0x22a0
callq 0x2c3c
callq 0x2c17
callq 0x23f4
callq 0x2bf2
callq 0x26e3
movq %rbx, %rdi
callq 0x272c
callq 0x26be
movq %rbx, %rdi
callq 0x2647
movq %rbx, %rdi
callq 0x2419
callq 0x24d2
callq 0x2489
callq 0x2461
callq 0x2622
callq 0x258d
movq %r14, %rdi
callq 0x269a
callq 0x2568
callq 0x24f7
movq %rbx, %rdi
callq 0x25d6
movq %rbx, %rdi
callq 0x243d