// File: /workspace/github_cpp_makefile_star2_O1/CK7[P]abawaca/src/ClusterData.cpp
// Function: ClusterData::ClusterData(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, ScafDpData const&)
ClusterData::ClusterData(string esom_lrn_file, const ScafDpData& scaf_db)
{
        FILE* fp = fopen(esom_lrn_file.c_str(), "r");

        if(!fp) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: could not read " << esom_lrn_file << endl << endl;
                exit(-1);
        }

        char line[8192] = {};

	/********** Read # of dps **********/
	// % 8430
        if(!fgets(line, 8192, fp)) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: " << esom_lrn_file << " is empty" << endl << endl;
                exit(-1);
        }

        // % 8430
        unsigned int ndps;
        char    c;
        if((sscanf(line, "%c %u", &c, &ndps) != 2) || (c != '%')) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: unexpected line 1 in " << esom_lrn_file << ": " << endl << line << endl << endl;
                exit(-1);
        }

	/********** Read # of dimensions **********/
	// % 12
        if(!fgets(line, 8192, fp)) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: failed to read line 2 in " << esom_lrn_file << endl << endl;
                exit(-1);
        }

        unsigned int ndimensions;
        if((sscanf(line, "%c %u", &c, &ndimensions) != 2) || (c != '%')) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: unexpected line 2 in " << esom_lrn_file << ": " << endl << line << endl << endl;
                exit(-1);
        }
	ndimensions--;		// Count in the file contains the dp column

	/********** Read weights for dimensions. We don't use it but just verify that the number found is right **********/
	// % 9	1	1	1	1	1	1	1	1	1	1	1
        if(!fgets(line, 8192, fp)) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: failed to read line 3 in " << esom_lrn_file << endl << endl;
                exit(-1);
        }

        unsigned int t = 1;
	while(strrchr(line, '\t') != NULL) {
		t++;
		*strrchr(line, '\t') = 0;
	}
        if(t != (ndimensions+1)) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: unexpected line 3 in " << esom_lrn_file << ": number of fileds is differemt that " << ndimensions << endl << line << endl << endl;
                exit(-1);
        }

	/********** Read dimension names **********/
	// % key	74-1	74-10	74-11	74-12	74-2	74-3	74-4	74-5	74-6	74-7	74-9
        if(!fgets(line, 8192, fp)) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: failed to read line 4 in " << esom_lrn_file << endl << endl;
                exit(-1);
        }

	// Chomp
	while((strlen(line)>0) && isspace(*(line+strlen(line)-1)))
		*(line+strlen(line)-1) = 0;

	dimensions.push_back(NULL);
	// We skip the first column which contains the dp title
	char *p1=strchr(line, '\t')+1, *p2=strchr(p1, '\t');
	size_t	i = 1;
	while(p2) {
		*p2 = 0;
		dimensions.push_back(new Dimension(i++, string(p1)));
		p1 = p2+1;
		p2=strchr(p1, '\t');
	}
	// Last dimension is not accompanied by a tab
	dimensions.push_back(new Dimension(i, string(p1)));

	if(i != ndimensions) {
                cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: number of dimensions found in line 4 (" << i << ") is different than expected (" << ndimensions << ") in file " << esom_lrn_file << ":" << endl << line << endl << endl;
                exit(-1);
	}

	/********** And finally, read the values themselves **********/	
	size_t entry=0;
	map<size_t, string>	data;

	while(fgets(line, 8192, fp)) {
		// Chomp
		while((strlen(line)>0) && isspace(*(line+strlen(line)-1)))
			*(line+strlen(line)-1) = 0;

		// Skip empty or comment lines
		if((line[0] == '%') || (strlen(line) == 0))
			continue;

		// The following means that we have more lines than expected by the % dps information
		if(entry >= ndps) {
			cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: number of datapoint lines found is higher than expected (" << ndps << "), file " << esom_lrn_file << endl << endl;
			exit(-1);
		}

		char *p1, *p2;
		size_t t=1;
		// Count the number of values and make sure it's what we would expect
		for(p1=line, p2=strchr(p1, '\t'); p2!=NULL; p1=p2+1, p2=strchr(p1, '\t'))
			t++;
		if(t != (ndimensions+1)) {
			cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: number of dimensions found is " << t << ", expected to find " << ndimensions << ": " << line << endl << endl; 
			exit(-1);
		}

		// 1	0.181737916437441	0	0.00990659188488923	0.551726686306843	0.0250488966425045	0.0706148967876072	0	0	0.00324475022645163	0.0147897529305731	0.142930508783691
		p1=line;
		p2=strchr(p1, '\t');
		*p2=0;
		int dp = scaf_db.dp_name2id(atoi(p1));

		if(dp != 0) {
			data.insert(pair<size_t, string>(dp, string(p2+1)));
		}
		entry++;
	}

	for(auto it=data.begin(); it!=data.end(); it++) {
		size_t dp = it->first;
		dps.insert(dp);
		int p1, p2, t;
		for(t=1, p1=0, p2=it->second.find('\t', 0); p2!=string::npos; t++, p1=p2+1, p2=p2=it->second.find('\t', p1)) {
			dimensions[t]->insert(dp, atof(it->second.substr(p1, p2-p1).c_str()));
		}
		// Last value
		dimensions[t]->insert(dp, atof(it->second.substr(p1).c_str()));
	}
	if(entry != ndps) {
		cerr << __FILE__ << " (" << __LINE__ << "): Fatal error: number of datapoint lines found (" << entry << ") is different than expected (" << ndps << "), file " << esom_lrn_file << endl << endl;
		exit(-1);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2108, %rsp           # imm = 0x2108
movq %rdx, -0xe8(%rbp)
movq %rsi, %r15
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
leaq 0x18(%rdi), %rax
movq %rax, -0xb0(%rbp)
leaq 0x48(%rdi), %rax
movq %rax, 0x18(%rdi)
movq $0x1, 0x20(%rdi)
movups %xmm0, 0x28(%rdi)
movl $0x3f800000, 0x38(%rdi) # imm = 0x3F800000
movq %rdi, -0x48(%rbp)
movups %xmm0, 0x40(%rdi)
movq (%rsi), %rdi
leaq 0x9fff(%rip), %rsi      # 0x1a131
callq 0x5450
testq %rax, %rax
je 0x107f3
movq %rax, %r14
leaq -0x2130(%rbp), %rbx
movl $0x2000, %edx           # imm = 0x2000
movq %rbx, %rdi
xorl %esi, %esi
callq 0x51f0
movq %rbx, %rdi
movl $0x2000, %esi           # imm = 0x2000
movq %r14, %rdx
callq 0x55e0
testq %rax, %rax
je 0x1086f
leaq 0xa6ba(%rip), %rsi      # 0x1a833
leaq -0x2130(%rbp), %rdi
leaq -0x29(%rbp), %rdx
leaq -0x34(%rbp), %rcx
xorl %eax, %eax
callq 0x5370
cmpl $0x2, %eax
jne 0x10902
cmpb $0x25, -0x29(%rbp)
jne 0x10902
leaq -0x2130(%rbp), %rdi
movl $0x2000, %esi           # imm = 0x2000
movq %r14, %rdx
callq 0x55e0
testq %rax, %rax
je 0x109bd
leaq 0xa66d(%rip), %rsi      # 0x1a833
leaq -0x2130(%rbp), %rdi
leaq -0x29(%rbp), %rdx
leaq -0x30(%rbp), %rcx
xorl %eax, %eax
callq 0x5370
cmpl $0x2, %eax
jne 0x10a39
cmpb $0x25, -0x29(%rbp)
jne 0x10a39
decl -0x30(%rbp)
leaq -0x2130(%rbp), %rdi
movl $0x2000, %esi           # imm = 0x2000
movq %r14, %rdx
callq 0x55e0
testq %rax, %rax
je 0x10af4
movq %r14, -0x58(%rbp)
leaq -0x2130(%rbp), %rdi
movl $0x9, %esi
callq 0x53f0
movl $0x1, %r14d
testq %rax, %rax
je 0x10244
incl %r14d
movb $0x0, (%rax)
movq %rbx, %rdi
movl $0x9, %esi
callq 0x53f0
jmp 0x1022a
movl -0x30(%rbp), %eax
incl %eax
cmpl %eax, %r14d
jne 0x10b70
leaq -0x2130(%rbp), %rdi
movl $0x2000, %esi           # imm = 0x2000
movq -0x58(%rbp), %rdx
callq 0x55e0
testq %rax, %rax
je 0x10c33
leaq -0x2130(%rbp), %rdi
callq 0x5180
testq %rax, %rax
je 0x102b6
movq %rax, %r14
leaq -0x2130(%rbp), %rbx
movsbl -0x2131(%rbp,%r14), %edi
callq 0x5070
testl %eax, %eax
je 0x102b6
movb $0x0, -0x2131(%rbp,%r14)
movq %rbx, %rdi
callq 0x5180
movq %rax, %r14
testq %rax, %rax
jne 0x1028b
movq $0x0, -0xe0(%rbp)
movq -0x48(%rbp), %rdi
movq 0x8(%rdi), %rsi
cmpq 0x10(%rdi), %rsi
je 0x102dd
movq $0x0, (%rsi)
addq $0x8, 0x8(%rdi)
jmp 0x102e9
leaq -0xe0(%rbp), %rdx
callq 0x1141e
movq %r15, -0x88(%rbp)
leaq -0x2130(%rbp), %rdi
movl $0x9, %esi
callq 0x5150
movq %rax, %r14
incq %r14
movq %r14, %rdi
movl $0x9, %esi
callq 0x5150
testq %rax, %rax
je 0x103e7
movq %rax, %r13
movl $0x1, %r15d
leaq -0x118(%rbp), %rbx
movq %r15, -0x40(%rbp)
movb $0x0, (%r13)
movl $0xa0, %edi
callq 0x53a0
movq %rax, %r12
movq %rbx, %r15
movq %rbx, -0x128(%rbp)
movq %r14, %rdi
callq 0x5180
leaq (%rax,%r14), %rdx
leaq -0x128(%rbp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb314
movb $0x1, %r14b
movq %r12, %rdi
movq -0x40(%rbp), %rsi
movq %rbx, %rdx
movq %r15, %rbx
callq 0xfae6
movq %r12, -0xe0(%rbp)
movq -0x48(%rbp), %rdi
movq 0x8(%rdi), %rsi
cmpq 0x10(%rdi), %rsi
je 0x1039f
movq %r12, (%rsi)
addq $0x8, 0x8(%rdi)
jmp 0x103ae
xorl %r14d, %r14d
leaq -0xe0(%rbp), %rdx
callq 0x1141e
movq -0x128(%rbp), %rdi
cmpq %rbx, %rdi
je 0x103bf
callq 0x5340
movq %r13, %r14
incq %r14
movq %r14, %rdi
movl $0x9, %esi
callq 0x5150
movq %rax, %r13
movq -0x40(%rbp), %r15
incq %r15
testq %rax, %rax
jne 0x1032d
jmp 0x103ed
movl $0x1, %r15d
movl $0xa0, %edi
callq 0x53a0
movq %rax, %r12
leaq -0xf8(%rbp), %rbx
movq %rbx, -0x10(%rbx)
movq %r14, %rdi
callq 0x5180
leaq (%rax,%r14), %rdx
leaq -0x108(%rbp), %rdi
movq %r14, %rsi
callq 0xb314
movb $0x1, %r14b
leaq -0x108(%rbp), %rdx
movq %r12, %rdi
movq %r15, %rsi
callq 0xfae6
movq %r12, -0xe0(%rbp)
movq -0x48(%rbp), %rdi
movq 0x8(%rdi), %rsi
cmpq 0x10(%rdi), %rsi
je 0x10454
movq %r12, (%rsi)
addq $0x8, 0x8(%rdi)
jmp 0x10463
xorl %r14d, %r14d
leaq -0xe0(%rbp), %rdx
callq 0x1141e
movq -0x108(%rbp), %rdi
cmpq %rbx, %rdi
je 0x10474
callq 0x5340
movl -0x30(%rbp), %eax
cmpq %rax, %r15
movq -0x58(%rbp), %r14
jne 0x10cb4
leaq -0xd8(%rbp), %rax
movl $0x0, (%rax)
xorl %ecx, %ecx
movq %rcx, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq $0x0, -0x50(%rbp)
movq %rcx, 0x20(%rax)
leaq -0x2130(%rbp), %rdi
movl $0x2000, %esi           # imm = 0x2000
movq %r14, %rdx
callq 0x55e0
testq %rax, %rax
je 0x10686
leaq -0x68(%rbp), %r13
movq $0x0, -0x50(%rbp)
leaq -0x2130(%rbp), %r12
movq %r12, %rdi
callq 0x5180
testq %rax, %rax
je 0x10514
movq %rax, %rbx
movsbl -0x2131(%rbp,%rbx), %edi
callq 0x5070
testl %eax, %eax
je 0x10514
movb $0x0, -0x2131(%rbp,%rbx)
movq %r12, %rdi
callq 0x5180
movq %rax, %rbx
testq %rax, %rax
jne 0x104eb
movzbl -0x2130(%rbp), %eax
cmpl $0x25, %eax
je 0x10524
testl %eax, %eax
jne 0x1053e
movq %r12, %rdi
movl $0x2000, %esi           # imm = 0x2000
movq %r14, %rdx
callq 0x55e0
testq %rax, %rax
jne 0x104db
jmp 0x10686
movl -0x34(%rbp), %eax
cmpq %rax, -0x50(%rbp)
jae 0x10e82
movq %r12, %rdi
movl $0x9, %esi
callq 0x5150
movq %rax, %r15
movl $0x1, %r14d
testq %rax, %rax
je 0x10581
movq %r15, %rax
incq %r14
incq %rax
movq %rax, %rdi
movl $0x9, %esi
callq 0x5150
testq %rax, %rax
jne 0x10569
movl -0x30(%rbp), %eax
incl %eax
cmpq %rax, %r14
jne 0x10f27
movb $0x0, (%r15)
movq %r12, %rdi
callq 0x55c0
movslq %eax, %rsi
movq -0xe8(%rbp), %rdi
callq 0x111e0
movq %rax, %rbx
testl %ebx, %ebx
movq -0x58(%rbp), %r14
je 0x1067d
movq %r13, %r14
leaq 0x1(%r15), %rdi
movq %rdi, -0x40(%rbp)
leaq -0x98(%rbp), %r13
movq %r13, -0xa8(%rbp)
callq 0x5180
leaq (%r15,%rax), %rdx
incq %rdx
leaq -0xa8(%rbp), %rdi
movq -0x40(%rbp), %rsi
callq 0xb314
movslq %ebx, %rax
movq %rax, -0x80(%rbp)
movq %r14, %r15
movq %r14, -0x78(%rbp)
movq -0xa8(%rbp), %rax
cmpq %r13, %rax
movq %r13, %rbx
je 0x1061c
movq %rax, -0x78(%rbp)
movq -0x98(%rbp), %rax
movq %rax, -0x68(%rbp)
jmp 0x10623
movups (%rbx), %xmm0
movups %xmm0, (%r15)
movq -0x58(%rbp), %r14
movq %r15, %r13
movq -0xa0(%rbp), %rax
movq %rax, -0x70(%rbp)
movq %rbx, -0xa8(%rbp)
movq $0x0, -0xa0(%rbp)
movb $0x0, -0x98(%rbp)
leaq -0xe0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x11558
movq -0x78(%rbp), %rdi
cmpq %r13, %rdi
je 0x1066c
callq 0x5340
movq -0xa8(%rbp), %rdi
cmpq %rbx, %rdi
je 0x1067d
callq 0x5340
incq -0x50(%rbp)
jmp 0x10524
movq -0xc8(%rbp), %r14
leaq -0xd8(%rbp), %rax
cmpq %rax, %r14
je 0x107c8
movq 0x20(%r14), %rax
movq %rax, -0xa8(%rbp)
movq -0xb0(%rbp), %rdi
movq %rdi, -0x80(%rbp)
leaq -0xa8(%rbp), %rsi
leaq -0x80(%rbp), %rdx
callq 0x11712
leaq 0x28(%r14), %r13
movq %r13, %rdi
movl $0x9, %esi
xorl %edx, %edx
callq 0x54e0
movl $0x1, %edx
movl $0x0, %ebx
cmpl $-0x1, %eax
movq -0x48(%rbp), %rcx
je 0x1076e
movq %r14, -0x40(%rbp)
xorl %r14d, %r14d
movl $0x1, %r15d
movq (%rcx), %rcx
movq (%rcx,%r15,8), %rbx
movq -0xa8(%rbp), %r12
movslq %r14d, %rdx
movq %rax, %r14
subl %edx, %eax
movslq %eax, %rcx
leaq -0x80(%rbp), %rdi
movq %r13, %rsi
callq 0x53c0
movq -0x80(%rbp), %rdi
callq 0x54a0
movq %rbx, %rdi
movq %r12, %rsi
callq 0xf8f2
movq -0x80(%rbp), %rdi
leaq -0x70(%rbp), %rax
cmpq %rax, %rdi
je 0x10745
callq 0x5340
incq %r15
incl %r14d
movslq %r14d, %rbx
movq %r13, %rdi
movl $0x9, %esi
movq %rbx, %rdx
callq 0x54e0
cmpl $-0x1, %eax
movq -0x48(%rbp), %rcx
jne 0x106fa
movl %r15d, %edx
movq -0x40(%rbp), %r14
movq (%rcx), %rcx
movq (%rcx,%rdx,8), %r12
movq -0xa8(%rbp), %r15
leaq -0x80(%rbp), %rdi
movq %r13, %rsi
movq %rbx, %rdx
movq $-0x1, %rcx
callq 0x53c0
movq -0x80(%rbp), %rdi
callq 0x54a0
movq %r12, %rdi
movq %r15, %rsi
callq 0xf8f2
movq -0x80(%rbp), %rdi
leaq -0x70(%rbp), %rax
cmpq %rax, %rdi
je 0x107b8
callq 0x5340
movq %r14, %rdi
callq 0x5260
movq %rax, %r14
jmp 0x1068d
movl -0x34(%rbp), %eax
cmpq %rax, -0x50(%rbp)
jne 0x10dba
leaq -0xe0(%rbp), %rdi
callq 0x1138a
addq $0x2108, %rsp           # imm = 0x2108
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x127ee(%rip), %rdi     # 0x22fe8
leaq 0xa5ad(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x127d6(%rip), %rdi     # 0x22fe8
leaq 0xa724(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x127be(%rip), %rdi     # 0x22fe8
movl $0x20, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa584(%rip), %rsi      # 0x1adc2
movl $0x1f, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x12772(%rip), %rdi     # 0x22fe8
leaq 0xa531(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x1275a(%rip), %rdi     # 0x22fe8
leaq 0xa6a8(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x12742(%rip), %rdi     # 0x22fe8
movl $0x29, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa528(%rip), %rsi      # 0x1ade2
movl $0x10, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rbx
leaq 0x9f49(%rip), %rsi      # 0x1a829
movl $0x9, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x126df(%rip), %rdi     # 0x22fe8
leaq 0xa49e(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x126c7(%rip), %rdi     # 0x22fe8
leaq 0xa615(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x126af(%rip), %rdi     # 0x22fe8
movl $0x31, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa4a6(%rip), %rsi      # 0x1adf3
movl $0x25, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rbx
leaq 0xaa5d(%rip), %rsi      # 0x1b3d0
movl $0x2, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rbx
leaq -0x2130(%rbp), %r14
movq %r14, %rdi
callq 0x5180
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x12624(%rip), %rdi     # 0x22fe8
leaq 0xa3e3(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x1260c(%rip), %rdi     # 0x22fe8
leaq 0xa55a(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x125f4(%rip), %rdi     # 0x22fe8
movl $0x38, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa411(%rip), %rsi      # 0x1ae19
movl $0x29, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x125a8(%rip), %rdi     # 0x22fe8
leaq 0xa367(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x12590(%rip), %rdi     # 0x22fe8
leaq 0xa4de(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x12578(%rip), %rdi     # 0x22fe8
movl $0x3e, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa3bf(%rip), %rsi      # 0x1ae43
movl $0x25, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rbx
leaq 0xa926(%rip), %rsi      # 0x1b3d0
movl $0x2, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rbx
leaq -0x2130(%rbp), %r14
movq %r14, %rdi
callq 0x5180
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x124ed(%rip), %rdi     # 0x22fe8
leaq 0xa2ac(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x124d5(%rip), %rdi     # 0x22fe8
leaq 0xa423(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x124bd(%rip), %rdi     # 0x22fe8
movl $0x46, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa32a(%rip), %rsi      # 0x1ae69
movl $0x29, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x12471(%rip), %rdi     # 0x22fe8
leaq 0xa230(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x12459(%rip), %rdi     # 0x22fe8
leaq 0xa3a7(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x12441(%rip), %rdi     # 0x22fe8
movl $0x50, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa2d8(%rip), %rsi      # 0x1ae93
movl $0x25, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rbx
leaq 0xa2d8(%rip), %rsi      # 0x1aeb9
movl $0x25, %edx
movq %rax, %rdi
callq 0x5420
movl -0x30(%rbp), %esi
movq %rbx, %rdi
callq 0x5240
movq %rax, %rdi
callq 0x51a0
movq %rax, %rbx
leaq -0x2130(%rbp), %r14
movq %r14, %rdi
callq 0x5180
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x123ae(%rip), %rdi     # 0x22fe8
leaq 0xa16d(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x12396(%rip), %rdi     # 0x22fe8
leaq 0xa2e4(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x1237e(%rip), %rdi     # 0x22fe8
movl $0x57, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa261(%rip), %rsi      # 0x1aedf
movl $0x29, %edx
movq %rax, %rdi
callq 0x5420
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x5480
movq 0x1232d(%rip), %rdi     # 0x22fe8
leaq 0xa0ec(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x12315(%rip), %rdi     # 0x22fe8
leaq 0xa263(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x122fd(%rip), %rdi     # 0x22fe8
movl $0x6d, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa20a(%rip), %rsi      # 0x1af09
movl $0x36, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
movq %r15, %rsi
callq 0x5240
movq %rax, %rbx
leaq 0xa21f(%rip), %rsi      # 0x1af40
movl $0x1e, %edx
movq %rax, %rdi
callq 0x5420
movl -0x30(%rbp), %esi
movq %rbx, %rdi
callq 0x5240
movq %rax, %rbx
leaq 0xa21c(%rip), %rsi      # 0x1af5f
movl $0xa, %edx
movq %rax, %rdi
callq 0x5420
movq -0x88(%rbp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rbx
leaq 0x96f9(%rip), %rsi      # 0x1a469
movl $0x1, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rbx
leaq -0x2130(%rbp), %r14
movq %r14, %rdi
callq 0x5180
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x12227(%rip), %rdi     # 0x22fe8
leaq 0x9fe6(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x1220f(%rip), %rdi     # 0x22fe8
leaq 0xa15d(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x121f7(%rip), %rdi     # 0x22fe8
movl $0xa5, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa1fb(%rip), %rsi      # 0x1b000
movl $0x31, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
movq -0x50(%rbp), %rsi
callq 0x5240
movq %rax, %rbx
leaq 0xa118(%rip), %rsi      # 0x1af40
movl $0x1e, %edx
movq %rax, %rdi
callq 0x5420
movl -0x34(%rbp), %esi
movq %rbx, %rdi
callq 0x5240
movq %rax, %rbx
leaq 0xa16a(%rip), %rsi      # 0x1afb4
movl $0x8, %edx
movq %rax, %rdi
callq 0x5420
movq -0x88(%rbp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x1215f(%rip), %rdi     # 0x22fe8
leaq 0x9f1e(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x12147(%rip), %rdi     # 0x22fe8
leaq 0xa095(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x1212f(%rip), %rdi     # 0x22fe8
movl $0x80, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa09d(%rip), %rsi      # 0x1af6a
movl $0x49, %edx
movq %rax, %rdi
callq 0x5420
movl -0x34(%rbp), %esi
movq %rbx, %rdi
callq 0x5240
movq %rax, %rbx
leaq 0xa0c5(%rip), %rsi      # 0x1afb4
movl $0x8, %edx
movq %rax, %rdi
callq 0x5420
movq -0x88(%rbp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x5420
movq %rax, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq 0x120ba(%rip), %rdi     # 0x22fe8
leaq 0x9e79(%rip), %rsi      # 0x1adae
movl $0x13, %edx
callq 0x5420
movq 0x120a2(%rip), %rdi     # 0x22fe8
leaq 0x9ff0(%rip), %rsi      # 0x1af3d
movl $0x2, %edx
callq 0x5420
movq 0x1208a(%rip), %rdi     # 0x22fe8
movl $0x8a, %esi
callq 0x5670
movq %rax, %rbx
leaq 0xa04b(%rip), %rsi      # 0x1afbd
movl $0x2e, %edx
movq %rax, %rdi
callq 0x5420
movq %rbx, %rdi
movq %r14, %rsi
callq 0x5240
movq %rax, %rbx
leaq 0xa058(%rip), %rsi      # 0x1afec
movl $0x13, %edx
movq %rax, %rdi
callq 0x5420
movl -0x30(%rbp), %esi
movq %rbx, %rdi
callq 0x5240
movq %rax, %rbx
leaq 0xa41a(%rip), %rsi      # 0x1b3d0
movl $0x2, %edx
movq %rax, %rdi
callq 0x5420
leaq -0x2130(%rbp), %r14
movq %r14, %rdi
callq 0x5180
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x5420
movq %rbx, %rdi
callq 0x51a0
movq %rax, %rdi
callq 0x51a0
jmp 0x10caa
movq %rax, %r15
movq -0x78(%rbp), %rdi
cmpq %r13, %rdi
je 0x11006
callq 0x5340
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
jmp 0x11082
jmp 0x11072
jmp 0x11072
jmp 0x11072
jmp 0x11042
jmp 0x11042
jmp 0x11042
jmp 0x11042
jmp 0x11047
jmp 0x11042
jmp 0x11072
movq %rax, %r15
movq -0x108(%rbp), %rdi
jmp 0x11059
jmp 0x11042
jmp 0x11042
jmp 0x11042
jmp 0x11072
jmp 0x11077
jmp 0x11072
movq %rax, %r15
jmp 0x11098
movq %rax, %r15
movb $0x1, %r14b
jmp 0x11063
movq %rax, %r15
movq -0x128(%rbp), %rdi
cmpq %rbx, %rdi
je 0x11063
callq 0x5340
testb %r14b, %r14b
je 0x11098
movq %r12, %rdi
callq 0x5340
jmp 0x11098
movq %rax, %r15
jmp 0x1108c
movq %rax, %r15
movq -0x80(%rbp), %rdi
leaq -0x70(%rbp), %rax
cmpq %rax, %rdi
je 0x1108c
callq 0x5340
leaq -0xe0(%rbp), %rdi
callq 0x1138a
movq -0xb0(%rbp), %rdi
callq 0x9cd8
movq -0x48(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x110b5
callq 0x5340
movq %r15, %rdi
callq 0x56a0
nop