// File: /workspace/github_c_makefile_star2_O0/skoren[P]bacValidation/bamcat.c
// Function: sam_read1
int sam_read1(tamFile fp, bam_header_t *header, bam1_t *b)
{
	int ret, doff, doff0, dret, z = 0;
	bam1_core_t *c = &b->core;
	kstring_t *str = fp->str;
	kstream_t *ks = fp->ks;

	if (fp->is_first) {
		fp->is_first = 0;
		ret = str->l;
	} else {
		do { // special consideration for empty lines
			ret = ks_getuntil(fp->ks, KS_SEP_TAB, str, &dret);
			if (ret >= 0) z += str->l + 1;
		} while (ret == 0);
	}
	if (ret < 0) return -1;
	++fp->n_lines;
	doff = 0;

	{ // name
		c->l_qname = strlen(str->s) + 1;
		memcpy(alloc_data(b, doff + c->l_qname) + doff, str->s, c->l_qname);
		doff += c->l_qname;
	}
	{ // flag
		long flag;
		char *s;
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1;
		flag = strtol((char*)str->s, &s, 0);
		if (*s) { // not the end of the string
			flag = 0;
			for (s = str->s; *s; ++s)
				flag |= bam_char2flag_table[(int)*s];
		}
		c->flag = flag;
	}
	{ // tid, pos, qual
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1; c->tid = bam_get_tid(header, str->s);
		if (c->tid < 0 && strcmp(str->s, "*")) {
			if (header->n_targets == 0) {
				fprintf(stderr, "[sam_read1] missing header? Abort!\n");
				exit(1);
			} else fprintf(stderr, "[sam_read1] reference '%s' is recognized as '*'.\n", str->s);
		}
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1; c->pos = isdigit(str->s[0])? atoi(str->s) - 1 : -1;
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1; c->qual = isdigit(str->s[0])? atoi(str->s) : 0;
		if (ret < 0) return -2;
	}
	{ // cigar
		char *s, *t;
		int i, op;
		long x;
		c->n_cigar = 0;
		if (ks_getuntil(ks, KS_SEP_TAB, str, &dret) < 0) return -3;
		z += str->l + 1;
		if (str->s[0] != '*') {
			uint32_t *cigar;
			for (s = str->s; *s; ++s) {
				if ((isalpha(*s)) || (*s=='=')) ++c->n_cigar;
				else if (!isdigit(*s)) parse_error(fp->n_lines, "invalid CIGAR character");
			}
			b->data = alloc_data(b, doff + c->n_cigar * 4);
			cigar = bam1_cigar(b);
			for (i = 0, s = str->s; i != c->n_cigar; ++i) {
				x = strtol(s, &t, 10);
				op = toupper(*t);
				if (op == 'M') op = BAM_CMATCH;
				else if (op == 'I') op = BAM_CINS;
				else if (op == 'D') op = BAM_CDEL;
				else if (op == 'N') op = BAM_CREF_SKIP;
				else if (op == 'S') op = BAM_CSOFT_CLIP;
				else if (op == 'H') op = BAM_CHARD_CLIP;
				else if (op == 'P') op = BAM_CPAD;
				else if (op == '=') op = BAM_CEQUAL;
				else if (op == 'X') op = BAM_CDIFF;
				else if (op == 'B') op = BAM_CBACK;
				else parse_error(fp->n_lines, "invalid CIGAR operation");
				s = t + 1;
				cigar[i] = bam_cigar_gen(x, op);
			}
			if (*s) parse_error(fp->n_lines, "unmatched CIGAR operation");
			c->bin = bam_reg2bin(c->pos, bam_calend(c, cigar));
			doff += c->n_cigar * 4;
		} else {
			if (!(c->flag&BAM_FUNMAP)) {
				fprintf(stderr, "Parse warning at line %lld: mapped sequence without CIGAR\n", (long long)fp->n_lines);
				c->flag |= BAM_FUNMAP;
			}
			c->bin = bam_reg2bin(c->pos, c->pos + 1);
		}
	}
	{ // mtid, mpos, isize
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1;
		c->mtid = strcmp(str->s, "=")? bam_get_tid(header, str->s) : c->tid;
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1;
		c->mpos = isdigit(str->s[0])? atoi(str->s) - 1 : -1;
		ret = ks_getuntil(ks, KS_SEP_TAB, str, &dret); z += str->l + 1;
		c->isize = (str->s[0] == '-' || isdigit(str->s[0]))? atoi(str->s) : 0;
		if (ret < 0) return -4;
	}
	{ // seq and qual
		int i;
		uint8_t *p = 0;
		if (ks_getuntil(ks, KS_SEP_TAB, str, &dret) < 0) return -5; // seq
		z += str->l + 1;
		if (strcmp(str->s, "*")) {
			c->l_qseq = strlen(str->s);
			if (c->n_cigar && c->l_qseq != (int32_t)bam_cigar2qlen(c, bam1_cigar(b))) {
				fprintf(stderr, "Line %ld, sequence length %i vs %i from CIGAR\n",
						(long)fp->n_lines, c->l_qseq, (int32_t)bam_cigar2qlen(c, bam1_cigar(b)));
				parse_error(fp->n_lines, "CIGAR and sequence length are inconsistent");
			}
			p = (uint8_t*)alloc_data(b, doff + c->l_qseq + (c->l_qseq+1)/2) + doff;
			memset(p, 0, (c->l_qseq+1)/2);
			for (i = 0; i < c->l_qseq; ++i)
				p[i/2] |= bam_nt16_table[(int)str->s[i]] << 4*(1-i%2);
		} else c->l_qseq = 0;
		if (ks_getuntil(ks, KS_SEP_TAB, str, &dret) < 0) return -6; // qual
		z += str->l + 1;
		if (strcmp(str->s, "*") && c->l_qseq != strlen(str->s))
			parse_error(fp->n_lines, "sequence and quality are inconsistent");
		p += (c->l_qseq+1)/2;
		if (strcmp(str->s, "*") == 0) for (i = 0; i < c->l_qseq; ++i) p[i] = 0xff;
		else for (i = 0; i < c->l_qseq; ++i) p[i] = str->s[i] - 33;
		doff += c->l_qseq + (c->l_qseq+1)/2;
	}
	doff0 = doff;
	if (dret != '\n' && dret != '\r') { // aux
		while (ks_getuntil(ks, KS_SEP_TAB, str, &dret) >= 0) {
			uint8_t *s, type, key[2];
			z += str->l + 1;
			if (str->l < 6 || str->s[2] != ':' || str->s[4] != ':')
				parse_error(fp->n_lines, "missing colon in auxiliary data");
			key[0] = str->s[0]; key[1] = str->s[1];
			type = str->s[3];
			s = alloc_data(b, doff + 3) + doff;
			s[0] = key[0]; s[1] = key[1]; s += 2; doff += 2;
			if (type == 'A' || type == 'a' || type == 'c' || type == 'C') { // c and C for backward compatibility
				s = alloc_data(b, doff + 2) + doff;
				*s++ = 'A'; *s = str->s[5];
				doff += 2;
			} else if (type == 'I' || type == 'i') {
				long long x;
				s = alloc_data(b, doff + 5) + doff;
				x = (long long)atoll(str->s + 5);
				if (x < 0) {
					if (x >= -127) {
						*s++ = 'c'; *(int8_t*)s = (int8_t)x;
						s += 1; doff += 2;
					} else if (x >= -32767) {
						*s++ = 's'; *(int16_t*)s = (int16_t)x;
						s += 2; doff += 3;
					} else {
						*s++ = 'i'; *(int32_t*)s = (int32_t)x;
						s += 4; doff += 5;
						if (x < -2147483648ll)
							fprintf(stderr, "Parse warning at line %lld: integer %lld is out of range.",
									(long long)fp->n_lines, x);
					}
				} else {
					if (x <= 255) {
						*s++ = 'C'; *s++ = (uint8_t)x;
						doff += 2;
					} else if (x <= 65535) {
						*s++ = 'S'; *(uint16_t*)s = (uint16_t)x;
						s += 2; doff += 3;
					} else {
						*s++ = 'I'; *(uint32_t*)s = (uint32_t)x;
						s += 4; doff += 5;
						if (x > 4294967295ll)
							fprintf(stderr, "Parse warning at line %lld: integer %lld is out of range.",
									(long long)fp->n_lines, x);
					}
				}
			} else if (type == 'f') {
				s = alloc_data(b, doff + 5) + doff;
				*s++ = 'f';
				*(float*)s = (float)atof(str->s + 5);
				s += 4; doff += 5;
			} else if (type == 'd') {
				s = alloc_data(b, doff + 9) + doff;
				*s++ = 'd';
				*(float*)s = (float)atof(str->s + 9);
				s += 8; doff += 9;
			} else if (type == 'Z' || type == 'H') {
				int size = 1 + (str->l - 5) + 1;
				if (type == 'H') { // check whether the hex string is valid
					int i;
					if ((str->l - 5) % 2 == 1) parse_error(fp->n_lines, "length of the hex string not even");
					for (i = 0; i < str->l - 5; ++i) {
						int c = toupper(str->s[5 + i]);
						if (!((c >= '0' && c <= '9') || (c >= 'A' && c <= 'F')))
							parse_error(fp->n_lines, "invalid hex character");
					}
				}
				s = alloc_data(b, doff + size) + doff;
				*s++ = type;
				memcpy(s, str->s + 5, str->l - 5);
				s[str->l - 5] = 0;
				doff += size;
			} else if (type == 'B') {
				int32_t n = 0, Bsize, k = 0, size;
				char *p;
				if (str->l < 8) parse_error(fp->n_lines, "too few values in aux type B");
				Bsize = bam_aux_type2size(str->s[5]); // the size of each element
				for (p = (char*)str->s + 6; *p; ++p) // count the number of elements in the array
					if (*p == ',') ++n;
				p = str->s + 7; // now p points to the first number in the array
				size = 6 + Bsize * n; // total number of bytes allocated to this tag
				s = alloc_data(b, doff + 6 * Bsize * n) + doff; // allocate memory
				*s++ = 'B'; *s++ = str->s[5];
				memcpy(s, &n, 4); s += 4; // write the number of elements
				if (str->s[5] == 'c')      while (p < str->s + str->l) ((int8_t*)s)[k++]   = (int8_t)strtol(p, &p, 0),   ++p;
				else if (str->s[5] == 'C') while (p < str->s + str->l) ((uint8_t*)s)[k++]  = (uint8_t)strtol(p, &p, 0),  ++p;
				else if (str->s[5] == 's') while (p < str->s + str->l) ((int16_t*)s)[k++]  = (int16_t)strtol(p, &p, 0),  ++p; // FIXME: avoid unaligned memory
				else if (str->s[5] == 'S') while (p < str->s + str->l) ((uint16_t*)s)[k++] = (uint16_t)strtol(p, &p, 0), ++p;
				else if (str->s[5] == 'i') while (p < str->s + str->l) ((int32_t*)s)[k++]  = (int32_t)strtol(p, &p, 0),  ++p;
				else if (str->s[5] == 'I') while (p < str->s + str->l) ((uint32_t*)s)[k++] = (uint32_t)strtol(p, &p, 0), ++p;
				else if (str->s[5] == 'f') while (p < str->s + str->l) ((float*)s)[k++]    = (float)strtod(p, &p),       ++p;
				else parse_error(fp->n_lines, "unrecognized array type");
				s += Bsize * n; doff += size;
			} else parse_error(fp->n_lines, "unrecognized type");
			if (dret == '\n' || dret == '\r') break;
		}
	}
	b->l_aux = doff - doff0;
	b->data_len = doff;
	if (bam_no_B) bam_remove_B(b);
	return z;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x120, %rsp            # imm = 0x120
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl $0x0, -0x34(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x20(%rax)
je 0x4aaf
movq -0x10(%rbp), %rax
movl $0x0, 0x20(%rax)
movq -0x48(%rbp), %rax
movq (%rax), %rax
movl %eax, -0x24(%rbp)
jmp 0x4af3
jmp 0x4ab1
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
cmpl $0x0, -0x24(%rbp)
jl 0x4ae9
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
jmp 0x4aeb
cmpl $0x0, -0x24(%rbp)
je 0x4ab1
jmp 0x4af3
cmpl $0x0, -0x24(%rbp)
jge 0x4b05
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x640f
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x18(%rax)
movl $0x0, -0x28(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3150
addq $0x1, %rax
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, %ecx
movl %ecx, %edx
movq 0x8(%rax), %rcx
andq $0xff, %rdx
shlq $0x18, %rdx
movabsq $-0xff000001, %rsi      # imm = 0xFFFFFFFF00FFFFFF
andq %rsi, %rcx
orq %rdx, %rcx
movq %rcx, 0x8(%rax)
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
shrq $0x18, %rax
andq $0xff, %rax
addl %eax, %esi
callq 0x9340
movq %rax, %rdi
movslq -0x28(%rbp), %rax
addq %rax, %rdi
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rsi
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
shrq $0x18, %rax
andq $0xff, %rax
movl %eax, %eax
movl %eax, %edx
callq 0x32d0
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
shrq $0x18, %rax
andq $0xff, %rax
addl -0x28(%rbp), %eax
movl %eax, -0x28(%rbp)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
leaq -0x60(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movq %rax, -0x58(%rbp)
movq -0x60(%rbp), %rax
cmpb $0x0, (%rax)
je 0x4c57
movq $0x0, -0x58(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x60(%rbp), %rax
cmpb $0x0, (%rax)
je 0x4c55
movq -0x60(%rbp), %rax
movsbl (%rax), %eax
movslq %eax, %rcx
leaq 0x12895(%rip), %rax     # 0x174d0
movzwl (%rax,%rcx,2), %eax
orq -0x58(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x60(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x4c21
jmp 0x4c57
movq -0x58(%rbp), %rax
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, %ecx
movl %ecx, %edx
movq 0x8(%rax), %rcx
andq $0xffff, %rdx           # imm = 0xFFFF
shlq $0x20, %rdx
movabsq $-0xffff00000001, %rsi  # imm = 0xFFFF0000FFFFFFFF
andq %rsi, %rcx
orq %rdx, %rcx
movq %rcx, 0x8(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x18(%rbp), %rdi
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x7d70
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, (%rax)
movq -0x40(%rbp), %rax
cmpl $0x0, (%rax)
jge 0x4d3e
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
leaq 0xd562(%rip), %rsi      # 0x12249
callq 0x3570
cmpl $0x0, %eax
je 0x4d3e
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
jne 0x4d1c
movq 0x122cf(%rip), %rax     # 0x16fd0
movq (%rax), %rdi
leaq 0xd540(%rip), %rsi      # 0x1224b
movb $0x0, %al
callq 0x3590
movl $0x1, %edi
callq 0x34b0
movq 0x122ad(%rip), %rax     # 0x16fd0
movq (%rax), %rdi
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdx
leaq 0xd53a(%rip), %rsi      # 0x1226f
movb $0x0, %al
callq 0x3590
jmp 0x4d3e
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
callq 0x3440
movq (%rax), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
je 0x4da8
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3610
subl $0x1, %eax
movl %eax, -0xdc(%rbp)
jmp 0x4db5
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %eax, -0xdc(%rbp)
jmp 0x4db5
movl -0xdc(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
callq 0x3440
movq (%rax), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
je 0x4e29
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3610
movl %eax, -0xe0(%rbp)
jmp 0x4e33
xorl %eax, %eax
movl %eax, -0xe0(%rbp)
jmp 0x4e33
movl -0xe0(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, %ecx
movl %ecx, %edx
movq 0x8(%rax), %rcx
andq $0xff, %rdx
shlq $0x10, %rdx
andq $-0xff0001, %rcx        # imm = 0xFF00FFFF
orq %rdx, %rcx
movq %rcx, 0x8(%rax)
cmpl $0x0, -0x24(%rbp)
jge 0x4e70
movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE
jmp 0x640f
movq -0x40(%rbp), %rax
movl $0x0, 0x10(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
cmpl $0x0, %eax
jge 0x4ea2
movl $0xfffffffd, -0x4(%rbp) # imm = 0xFFFFFFFD
jmp 0x640f
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl (%rax), %eax
cmpl $0x2a, %eax
je 0x5178
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
cmpb $0x0, (%rax)
je 0x4f68
callq 0x3440
movq (%rax), %rax
movq -0x68(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x400, %eax            # imm = 0x400
cmpl $0x0, %eax
jne 0x4f10
movq -0x68(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x3d, %eax
jne 0x4f1f
movq -0x40(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
jmp 0x4f55
callq 0x3440
movq (%rax), %rax
movq -0x68(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
jne 0x4f53
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xd353(%rip), %rsi      # 0x122a1
callq 0x9420
jmp 0x4f55
jmp 0x4f57
movq -0x68(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x68(%rbp)
jmp 0x4ed7
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
movq -0x40(%rbp), %rax
movl 0x10(%rax), %eax
shll $0x2, %eax
addl %eax, %esi
callq 0x9340
movq %rax, %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x30(%rax)
movq -0x20(%rbp), %rax
movq 0x30(%rax), %rax
movq -0x20(%rbp), %rcx
movq 0x8(%rcx), %rcx
shrq $0x18, %rcx
andq $0xff, %rcx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x88(%rbp)
movl $0x0, -0x74(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x68(%rbp)
movl -0x74(%rbp), %eax
movq -0x40(%rbp), %rcx
cmpl 0x10(%rcx), %eax
je 0x50f9
movq -0x68(%rbp), %rdi
leaq -0x70(%rbp), %rsi
movl $0xa, %edx
callq 0x3580
movq %rax, -0x80(%rbp)
movq -0x70(%rbp), %rax
movsbl (%rax), %edi
callq 0x36e0
movl %eax, -0x78(%rbp)
cmpl $0x4d, -0x78(%rbp)
jne 0x500d
movl $0x0, -0x78(%rbp)
jmp 0x50c0
cmpl $0x49, -0x78(%rbp)
jne 0x501f
movl $0x1, -0x78(%rbp)
jmp 0x50be
cmpl $0x44, -0x78(%rbp)
jne 0x5031
movl $0x2, -0x78(%rbp)
jmp 0x50bc
cmpl $0x4e, -0x78(%rbp)
jne 0x5040
movl $0x3, -0x78(%rbp)
jmp 0x50ba
cmpl $0x53, -0x78(%rbp)
jne 0x504f
movl $0x4, -0x78(%rbp)
jmp 0x50b8
cmpl $0x48, -0x78(%rbp)
jne 0x505e
movl $0x5, -0x78(%rbp)
jmp 0x50b6
cmpl $0x50, -0x78(%rbp)
jne 0x506d
movl $0x6, -0x78(%rbp)
jmp 0x50b4
cmpl $0x3d, -0x78(%rbp)
jne 0x507c
movl $0x7, -0x78(%rbp)
jmp 0x50b2
cmpl $0x58, -0x78(%rbp)
jne 0x508b
movl $0x8, -0x78(%rbp)
jmp 0x50b0
cmpl $0x42, -0x78(%rbp)
jne 0x509a
movl $0x9, -0x78(%rbp)
jmp 0x50ae
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xd210(%rip), %rsi      # 0x122b9
callq 0x9420
jmp 0x50b0
jmp 0x50b2
jmp 0x50b4
jmp 0x50b6
jmp 0x50b8
jmp 0x50ba
jmp 0x50bc
jmp 0x50be
jmp 0x50c0
movq -0x70(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x68(%rbp)
movq -0x80(%rbp), %rax
shlq $0x4, %rax
movslq -0x78(%rbp), %rcx
orq %rcx, %rax
movl %eax, %edx
movq -0x88(%rbp), %rax
movslq -0x74(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x74(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x74(%rbp)
jmp 0x4fc6
movq -0x68(%rbp), %rax
cmpb $0x0, (%rax)
je 0x5116
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xd1c0(%rip), %rsi      # 0x122d1
callq 0x9420
movq -0x40(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0xe4(%rbp)
movq -0x40(%rbp), %rdi
movq -0x88(%rbp), %rsi
callq 0x6420
movl -0xe4(%rbp), %edi
movl %eax, %esi
callq 0x9460
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, %ecx
movl %ecx, %edx
movq 0x8(%rax), %rcx
andq $0xffff, %rdx           # imm = 0xFFFF
andq $-0x10000, %rcx         # imm = 0xFFFF0000
orq %rdx, %rcx
movq %rcx, 0x8(%rax)
movq -0x40(%rbp), %rax
movl 0x10(%rax), %eax
shll $0x2, %eax
addl -0x28(%rbp), %eax
movl %eax, -0x28(%rbp)
jmp 0x5228
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
shrq $0x20, %rax
andq $0xffff, %rax           # imm = 0xFFFF
andl $0x4, %eax
cmpl $0x0, %eax
jne 0x51ef
movq 0x11e37(%rip), %rax     # 0x16fd0
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdx
leaq 0xd140(%rip), %rsi      # 0x122eb
movb $0x0, %al
callq 0x3590
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rcx
shrq $0x20, %rcx
andq $0xffff, %rcx           # imm = 0xFFFF
orl $0x4, %ecx
movl %ecx, %ecx
movl %ecx, %edx
movq 0x8(%rax), %rcx
andq $0xffff, %rdx           # imm = 0xFFFF
shlq $0x20, %rdx
movabsq $-0xffff00000001, %rsi  # imm = 0xFFFF0000FFFFFFFF
andq %rsi, %rcx
orq %rdx, %rcx
movq %rcx, 0x8(%rax)
movq -0x40(%rbp), %rax
movl 0x4(%rax), %edi
movq -0x40(%rbp), %rax
movl 0x4(%rax), %esi
addl $0x1, %esi
callq 0x9460
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, %ecx
movl %ecx, %edx
movq 0x8(%rax), %rcx
andq $0xffff, %rdx           # imm = 0xFFFF
andq $-0x10000, %rcx         # imm = 0xFFFF0000
orq %rdx, %rcx
movq %rcx, 0x8(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
leaq 0xd0c1(%rip), %rsi      # 0x12326
callq 0x3570
cmpl $0x0, %eax
je 0x5288
movq -0x18(%rbp), %rdi
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x7d70
movl %eax, -0xe8(%rbp)
jmp 0x5294
movq -0x40(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xe8(%rbp)
movl -0xe8(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, 0x18(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
callq 0x3440
movq (%rax), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
je 0x530b
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3610
subl $0x1, %eax
movl %eax, -0xec(%rbp)
jmp 0x5318
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %eax, -0xec(%rbp)
jmp 0x5318
movl -0xec(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, 0x1c(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
je 0x5387
callq 0x3440
movq (%rax), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
je 0x539c
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3610
movl %eax, -0xf0(%rbp)
jmp 0x53a6
xorl %eax, %eax
movl %eax, -0xf0(%rbp)
jmp 0x53a6
movl -0xf0(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, 0x20(%rax)
cmpl $0x0, -0x24(%rbp)
jge 0x53c5
movl $0xfffffffc, -0x4(%rbp) # imm = 0xFFFFFFFC
jmp 0x640f
movq $0x0, -0x98(%rbp)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
cmpl $0x0, %eax
jge 0x53f7
movl $0xfffffffb, -0x4(%rbp) # imm = 0xFFFFFFFB
jmp 0x640f
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
leaq 0xce2e(%rip), %rsi      # 0x12249
callq 0x3570
cmpl $0x0, %eax
je 0x5617
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3150
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, 0x14(%rax)
movq -0x40(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x5520
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
movl %eax, -0xf4(%rbp)
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x30(%rax), %rsi
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
shrq $0x18, %rax
andq $0xff, %rax
cltq
addq %rax, %rsi
callq 0x65c0
movl %eax, %ecx
movl -0xf4(%rbp), %eax
cmpl %ecx, %eax
je 0x5520
movq 0x11b37(%rip), %rax     # 0x16fd0
movq (%rax), %rax
movq %rax, -0x108(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x100(%rbp)
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
movl %eax, -0xf8(%rbp)
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x30(%rax), %rsi
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
shrq $0x18, %rax
andq $0xff, %rax
cltq
addq %rax, %rsi
callq 0x65c0
movq -0x108(%rbp), %rdi
movq -0x100(%rbp), %rdx
movl -0xf8(%rbp), %ecx
movl %eax, %r8d
leaq 0xce23(%rip), %rsi      # 0x12328
movb $0x0, %al
callq 0x3590
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xce3c(%rip), %rsi      # 0x12357
callq 0x9420
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
movq -0x40(%rbp), %rax
addl 0x14(%rax), %esi
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
addl $0x1, %eax
movl $0x2, %ecx
cltd
idivl %ecx
addl %eax, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0x98(%rbp)
movq -0x98(%rbp), %rdi
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
addl $0x1, %eax
movl $0x2, %ecx
cltd
idivl %ecx
movslq %eax, %rdx
xorl %esi, %esi
callq 0x31a0
movl $0x0, -0x8c(%rbp)
movl -0x8c(%rbp), %eax
movq -0x40(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jge 0x5615
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movslq -0x8c(%rbp), %rcx
movsbl (%rax,%rcx), %eax
movslq %eax, %rcx
leaq 0x11e1e(%rip), %rax     # 0x173d0
movzbl (%rax,%rcx), %esi
movl -0x8c(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl $0x1, %ecx
subl %edx, %ecx
shll $0x2, %ecx
shll %cl, %esi
movq -0x98(%rbp), %rax
movq %rax, -0x110(%rbp)
movl -0x8c(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movq -0x110(%rbp), %rax
movslq %ecx, %rcx
movzbl (%rax,%rcx), %edx
orl %esi, %edx
movb %dl, (%rax,%rcx)
movl -0x8c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8c(%rbp)
jmp 0x5582
jmp 0x5622
movq -0x40(%rbp), %rax
movl $0x0, 0x14(%rax)
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
cmpl $0x0, %eax
jge 0x5649
movl $0xfffffffa, -0x4(%rbp) # imm = 0xFFFFFFFA
jmp 0x640f
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
leaq 0xcbdc(%rip), %rsi      # 0x12249
callq 0x3570
cmpl $0x0, %eax
je 0x56b6
movq -0x40(%rbp), %rax
movslq 0x14(%rax), %rax
movq %rax, -0x118(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x3150
movq %rax, %rcx
movq -0x118(%rbp), %rax
cmpq %rcx, %rax
je 0x56b6
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xccd1(%rip), %rsi      # 0x12382
callq 0x9420
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
addl $0x1, %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movq -0x98(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x98(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
leaq 0xcb5c(%rip), %rsi      # 0x12249
callq 0x3570
cmpl $0x0, %eax
jne 0x5735
movl $0x0, -0x8c(%rbp)
movl -0x8c(%rbp), %eax
movq -0x40(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jge 0x5733
movq -0x98(%rbp), %rax
movslq -0x8c(%rbp), %rcx
movb $-0x1, (%rax,%rcx)
movl -0x8c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8c(%rbp)
jmp 0x5701
jmp 0x578a
movl $0x0, -0x8c(%rbp)
movl -0x8c(%rbp), %eax
movq -0x40(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jge 0x5788
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movslq -0x8c(%rbp), %rcx
movsbl (%rax,%rcx), %eax
subl $0x21, %eax
movb %al, %dl
movq -0x98(%rbp), %rax
movslq -0x8c(%rbp), %rcx
movb %dl, (%rax,%rcx)
movl -0x8c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8c(%rbp)
jmp 0x573f
jmp 0x578a
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
movl %eax, -0x11c(%rbp)
movq -0x40(%rbp), %rax
movl 0x14(%rax), %eax
addl $0x1, %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movl -0x11c(%rbp), %eax
addl %ecx, %eax
addl -0x28(%rbp), %eax
movl %eax, -0x28(%rbp)
movl -0x28(%rbp), %eax
movl %eax, -0x2c(%rbp)
cmpl $0xa, -0x30(%rbp)
je 0x63e0
cmpl $0xd, -0x30(%rbp)
je 0x63e0
jmp 0x57d5
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rdx
movl $0x1, %esi
leaq -0x30(%rbp), %rcx
callq 0x8730
cmpl $0x0, %eax
jl 0x63de
movq -0x48(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movslq -0x34(%rbp), %rax
addq %rcx, %rax
movl %eax, -0x34(%rbp)
movq -0x48(%rbp), %rax
cmpq $0x6, (%rax)
jb 0x5835
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x2(%rax), %eax
cmpl $0x3a, %eax
jne 0x5835
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x4(%rax), %eax
cmpl $0x3a, %eax
je 0x5849
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xcb64(%rip), %rsi      # 0x123a8
callq 0x9420
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movb (%rax), %al
movb %al, -0xa3(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movb 0x1(%rax), %al
movb %al, -0xa2(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movb 0x3(%rax), %al
movb %al, -0xa1(%rbp)
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
addl $0x3, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movb -0xa3(%rbp), %cl
movq -0xa0(%rbp), %rax
movb %cl, (%rax)
movb -0xa2(%rbp), %cl
movq -0xa0(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xa0(%rbp), %rax
addq $0x2, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x28(%rbp)
movzbl -0xa1(%rbp), %eax
cmpl $0x41, %eax
je 0x5902
movzbl -0xa1(%rbp), %eax
cmpl $0x61, %eax
je 0x5902
movzbl -0xa1(%rbp), %eax
cmpl $0x63, %eax
je 0x5902
movzbl -0xa1(%rbp), %eax
cmpl $0x43, %eax
jne 0x5959
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
addl $0x2, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x41, (%rax)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movb 0x5(%rax), %cl
movq -0xa0(%rbp), %rax
movb %cl, (%rax)
movl -0x28(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x28(%rbp)
jmp 0x63cb
movzbl -0xa1(%rbp), %eax
cmpl $0x49, %eax
je 0x5975
movzbl -0xa1(%rbp), %eax
cmpl $0x69, %eax
jne 0x5c12
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
addl $0x5, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
addq $0x5, %rdi
callq 0x32a0
movq %rax, -0xb0(%rbp)
cmpq $0x0, -0xb0(%rbp)
jge 0x5ae4
cmpq $-0x7f, -0xb0(%rbp)
jl 0x5a0c
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x63, (%rax)
movq -0xb0(%rbp), %rax
movb %al, %cl
movq -0xa0(%rbp), %rax
movb %cl, (%rax)
movq -0xa0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x28(%rbp)
jmp 0x5adf
cmpq $-0x7fff, -0xb0(%rbp) # imm = 0x8001
jl 0x5a62
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x73, (%rax)
movq -0xb0(%rbp), %rax
movw %ax, %cx
movq -0xa0(%rbp), %rax
movw %cx, (%rax)
movq -0xa0(%rbp), %rax
addq $0x2, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x3, %eax
movl %eax, -0x28(%rbp)
jmp 0x5add
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x69, (%rax)
movq -0xb0(%rbp), %rax
movl %eax, %ecx
movq -0xa0(%rbp), %rax
movl %ecx, (%rax)
movq -0xa0(%rbp), %rax
addq $0x4, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x5, %eax
movl %eax, -0x28(%rbp)
cmpq $-0x80000000, -0xb0(%rbp) # imm = 0x80000000
jge 0x5adb
movq 0x11515(%rip), %rax     # 0x16fd0
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdx
movq -0xb0(%rbp), %rcx
leaq 0xc8f4(%rip), %rsi      # 0x123c8
movb $0x0, %al
callq 0x3590
jmp 0x5add
jmp 0x5adf
jmp 0x5c0d
cmpq $0xff, -0xb0(%rbp)
jg 0x5b37
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x43, (%rax)
movq -0xb0(%rbp), %rax
movb %al, %cl
movq -0xa0(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0xa0(%rbp)
movb %cl, (%rax)
movl -0x28(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x28(%rbp)
jmp 0x5c0b
cmpq $0xffff, -0xb0(%rbp) # imm = 0xFFFF
jg 0x5b8d
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x53, (%rax)
movq -0xb0(%rbp), %rax
movw %ax, %cx
movq -0xa0(%rbp), %rax
movw %cx, (%rax)
movq -0xa0(%rbp), %rax
addq $0x2, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x3, %eax
movl %eax, -0x28(%rbp)
jmp 0x5c09
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x49, (%rax)
movq -0xb0(%rbp), %rax
movl %eax, %ecx
movq -0xa0(%rbp), %rax
movl %ecx, (%rax)
movq -0xa0(%rbp), %rax
addq $0x4, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x5, %eax
movl %eax, -0x28(%rbp)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rax, -0xb0(%rbp)
jle 0x5c07
movq 0x113e9(%rip), %rax     # 0x16fd0
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdx
movq -0xb0(%rbp), %rcx
leaq 0xc7c8(%rip), %rsi      # 0x123c8
movb $0x0, %al
callq 0x3590
jmp 0x5c09
jmp 0x5c0b
jmp 0x5c0d
jmp 0x63c9
movzbl -0xa1(%rbp), %eax
cmpl $0x66, %eax
jne 0x5c93
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
addl $0x5, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x66, (%rax)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
addq $0x5, %rdi
callq 0x34f0
cvtsd2ss %xmm0, %xmm0
movq -0xa0(%rbp), %rax
movss %xmm0, (%rax)
movq -0xa0(%rbp), %rax
addq $0x4, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x5, %eax
movl %eax, -0x28(%rbp)
jmp 0x63c7
movzbl -0xa1(%rbp), %eax
cmpl $0x64, %eax
jne 0x5d14
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
addl $0x9, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x64, (%rax)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rdi
addq $0x9, %rdi
callq 0x34f0
cvtsd2ss %xmm0, %xmm0
movq -0xa0(%rbp), %rax
movss %xmm0, (%rax)
movq -0xa0(%rbp), %rax
addq $0x8, %rax
movq %rax, -0xa0(%rbp)
movl -0x28(%rbp), %eax
addl $0x9, %eax
movl %eax, -0x28(%rbp)
jmp 0x63c5
movzbl -0xa1(%rbp), %eax
cmpl $0x5a, %eax
je 0x5d30
movzbl -0xa1(%rbp), %eax
cmpl $0x48, %eax
jne 0x5e9d
movq -0x48(%rbp), %rax
movq (%rax), %rax
subq $0x5, %rax
addq $0x1, %rax
addq $0x1, %rax
movl %eax, -0xb4(%rbp)
movzbl -0xa1(%rbp), %eax
cmpl $0x48, %eax
jne 0x5e16
movq -0x48(%rbp), %rax
movq (%rax), %rax
subq $0x5, %rax
andq $0x1, %rax
cmpq $0x1, %rax
jne 0x5d82
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xc685(%rip), %rsi      # 0x12402
callq 0x9420
movl $0x0, -0xb8(%rbp)
movslq -0xb8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq (%rcx), %rcx
subq $0x5, %rcx
cmpq %rcx, %rax
jae 0x5e14
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movl -0xb8(%rbp), %ecx
addl $0x5, %ecx
movslq %ecx, %rcx
movsbl (%rax,%rcx), %edi
callq 0x36e0
movl %eax, -0xbc(%rbp)
cmpl $0x30, -0xbc(%rbp)
jl 0x5dd8
cmpl $0x39, -0xbc(%rbp)
jle 0x5dfe
cmpl $0x41, -0xbc(%rbp)
jl 0x5dea
cmpl $0x46, -0xbc(%rbp)
jle 0x5dfe
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xc62b(%rip), %rsi      # 0x12424
callq 0x9420
jmp 0x5e00
movl -0xb8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xb8(%rbp)
jmp 0x5d8c
jmp 0x5e16
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
addl -0xb4(%rbp), %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movb -0xa1(%rbp), %cl
movq -0xa0(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0xa0(%rbp)
movb %cl, (%rax)
movq -0xa0(%rbp), %rdi
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rsi
addq $0x5, %rsi
movq -0x48(%rbp), %rax
movq (%rax), %rdx
subq $0x5, %rdx
callq 0x32d0
movq -0xa0(%rbp), %rax
movq -0x48(%rbp), %rcx
movq (%rcx), %rcx
subq $0x5, %rcx
movb $0x0, (%rax,%rcx)
movl -0xb4(%rbp), %eax
addl -0x28(%rbp), %eax
movl %eax, -0x28(%rbp)
jmp 0x63c3
movzbl -0xa1(%rbp), %eax
cmpl $0x42, %eax
jne 0x63ad
movl $0x0, -0xc0(%rbp)
movl $0x0, -0xc8(%rbp)
movq -0x48(%rbp), %rax
cmpq $0x8, (%rax)
jae 0x5edf
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xc560(%rip), %rsi      # 0x1243a
callq 0x9420
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %edi
callq 0x7590
movl %eax, -0xc4(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
addq $0x6, %rax
movq %rax, -0xd8(%rbp)
movq -0xd8(%rbp), %rax
cmpb $0x0, (%rax)
je 0x5f49
movq -0xd8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2c, %eax
jne 0x5f33
movl -0xc0(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc0(%rbp)
jmp 0x5f35
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x5f09
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
addq $0x7, %rax
movq %rax, -0xd8(%rbp)
movl -0xc4(%rbp), %eax
imull -0xc0(%rbp), %eax
addl $0x6, %eax
movl %eax, -0xcc(%rbp)
movq -0x20(%rbp), %rdi
movl -0x28(%rbp), %esi
imull $0x6, -0xc4(%rbp), %eax
imull -0xc0(%rbp), %eax
addl %eax, %esi
callq 0x9340
movslq -0x28(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0xa0(%rbp)
movb $0x42, (%rax)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movb 0x5(%rax), %cl
movq -0xa0(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0xa0(%rbp)
movb %cl, (%rax)
movq -0xa0(%rbp), %rax
movl -0xc0(%rbp), %ecx
movl %ecx, (%rax)
movq -0xa0(%rbp), %rax
addq $0x4, %rax
movq %rax, -0xa0(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x63, %eax
jne 0x6073
jmp 0x600a
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x606e
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movb %al, %dl
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0xc8(%rbp)
movslq %ecx, %rcx
movb %dl, (%rax,%rcx)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x600a
jmp 0x637e
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x43, %eax
jne 0x60ef
jmp 0x6086
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x60ea
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movb %al, %dl
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0xc8(%rbp)
movslq %ecx, %rcx
movb %dl, (%rax,%rcx)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x6086
jmp 0x637c
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x73, %eax
jne 0x616d
jmp 0x6102
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x6168
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movw %ax, %dx
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0xc8(%rbp)
movslq %ecx, %rcx
movw %dx, (%rax,%rcx,2)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x6102
jmp 0x637a
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x53, %eax
jne 0x61eb
jmp 0x6180
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x61e6
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movw %ax, %dx
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0xc8(%rbp)
movslq %ecx, %rcx
movw %dx, (%rax,%rcx,2)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x6180
jmp 0x6378
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x69, %eax
jne 0x6267
jmp 0x61fe
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x6262
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movl %eax, %edx
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0xc8(%rbp)
movslq %ecx, %rcx
movl %edx, (%rax,%rcx,4)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x61fe
jmp 0x6376
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x49, %eax
jne 0x62e3
jmp 0x627a
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x62de
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
callq 0x3580
movl %eax, %edx
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0xc8(%rbp)
movslq %ecx, %rcx
movl %edx, (%rax,%rcx,4)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x627a
jmp 0x6374
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movsbl 0x5(%rax), %eax
cmpl $0x66, %eax
jne 0x635e
jmp 0x62f6
movq -0xd8(%rbp), %rax
movq -0x48(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x48(%rbp), %rdx
addq (%rdx), %rcx
cmpq %rcx, %rax
jae 0x635c
movq -0xd8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
callq 0x3280
cvtsd2ss %xmm0, %xmm0
movq -0xa0(%rbp), %rax
movl -0xc8(%rbp), %ecx
movl %ecx, %edx
addl $0x1, %edx
movl %edx, -0xc8(%rbp)
movslq %ecx, %rcx
movss %xmm0, (%rax,%rcx,4)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0x62f6
jmp 0x6372
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xc0ea(%rip), %rsi      # 0x12457
callq 0x9420
jmp 0x6374
jmp 0x6376
jmp 0x6378
jmp 0x637a
jmp 0x637c
jmp 0x637e
movl -0xc4(%rbp), %ecx
imull -0xc0(%rbp), %ecx
movq -0xa0(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0xa0(%rbp)
movl -0xcc(%rbp), %eax
addl -0x28(%rbp), %eax
movl %eax, -0x28(%rbp)
jmp 0x63c1
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq 0xc0b3(%rip), %rsi      # 0x1246f
callq 0x9420
jmp 0x63c3
jmp 0x63c5
jmp 0x63c7
jmp 0x63c9
jmp 0x63cb
cmpl $0xa, -0x30(%rbp)
je 0x63d7
cmpl $0xd, -0x30(%rbp)
jne 0x63d9
jmp 0x63de
jmp 0x57d5
jmp 0x63e0
movl -0x28(%rbp), %ecx
subl -0x2c(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x24(%rax)
movl -0x28(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x28(%rax)
cmpl $0x0, 0x11512(%rip)     # 0x17910
je 0x6409
movq -0x20(%rbp), %rdi
callq 0x6950
movl -0x34(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x120, %rsp            # imm = 0x120
popq %rbp
retq
nopl (%rax,%rax)