// File: /workspace/github_cpp_makefile_star2_O3/lrq3000[P]rfrb/./src/fileHandler.cpp
// Function: FileHandler::buildMapHeuristic(std::vector<std::vector<Block, std::allocator<Block>>, std::allocator<std::vector<Block, std::allocator<Block>>>>&, std::vector<unsigned long, std::allocator<unsigned long>>&)
std::vector<std::vector<std::pair<bool, std::vector<size_t>>>>
FileHandler::buildMapHeuristic(std::vector<std::vector<Block>> &input, std::vector<size_t> &parityDist)
{
	//Initialization
	std::vector<std::vector<std::pair<bool, std::vector<size_t>>>> ret;
	ret.resize(inFiles.size());

	size_t maxCalls = input.at(0).size();
	std::vector<std::vector<Block>::iterator> iterators;
	for (auto &in : input)
	{
		iterators.push_back(in.begin());
		maxCalls = std::min(in.size(), maxCalls);
	}
	size_t curMin = -1;
	bool interestingStart=false;
	bool interestingEnd=false;
	std::vector<size_t> pushMe;

	std::vector<std::vector<size_t>> parityDistribution;
	for (size_t i = 0; i < inFiles.size(); ++i)
	{
		std::vector<size_t> tmp;
		for (size_t j = 0; j < inFiles.size(); ++j)
		{
			tmp.push_back(0);
		}
		parityDistribution.push_back(tmp);
	}
	while (maxCalls != 0)
	{
		maxCalls--;
		curMin = -1;
		for (auto &in : iterators)
		{
			curMin = std::min(curMin, (*in).startAdress);
		}
		interestingStart = true;
		pushMe.clear();
		size_t num=0;
		for (auto &in : iterators)
		{
			if ((*in).startAdress == curMin)
			{}
			else if ((*in).startAdress == curMin+1)
			{
				pushMe.push_back(num);
			}
			else
			{
				interestingStart=false;
			}
			++num;
		}
		if (interestingStart == true && (!(pushMe.empty())))
		{
			std::pair<bool, std::vector<size_t>> entry;
			entry = std::make_pair(true, pushMe);
			size_t modOp = (curMin) % inFiles.size();
			ret.at(modOp).push_back(entry);
		}

		//If an interesting start was found
		if (interestingStart == true)
		{
			size_t sAdress = curMin;
			curMin = -1;
			for (auto &in : iterators)
				curMin = std::min(curMin, (*in).entropies.size());
			for (size_t i = 1; i < curMin; ++i)
			{
				size_t pos=0;
				size_t par=0;
				float highest=0.0f;
				size_t en = (sAdress+i)%inFiles.size();
				for (auto &in : iterators)
				{
					if ((*in).startAdress == sAdress)
					{
						if ((*in).entropies.at(i) > highest)
						{
							highest = (*in).entropies.at(i);
							par = pos;
						}
					}
					else
					{
						if ((*in).entropies.at(i-1) > highest)
						{
							highest = (*in).entropies.at(i-1);
							par = pos;
						}
					}
					++pos;
				}
				parityDistribution.at(en).at(par) = parityDistribution.at(en).at(par)+1;
			}
		}

		curMin = -1;
		for (auto &in : iterators)
		{
			curMin = std::min(curMin, (*in).endAdress);
		}
		interestingEnd = true;
		pushMe.clear();
		num=0;
		for (auto &in : iterators)
		{
			if ((*in).endAdress == curMin)
			{
				pushMe.push_back(num);
				++in;
			}
			else if ((*in).endAdress == curMin+1)
			{
				++in;
			}
			else
			{
				interestingEnd=false;
			}
			++num;
		}

		//If an interesting end was found
		if (interestingEnd == true && pushMe.size()<inFiles.size())
		{
			std::pair<bool, std::vector<size_t>> entry;
			entry = std::make_pair(false, pushMe);
			size_t modOp = (curMin) % inFiles.size();
			ret.at(modOp).push_back(entry);
		}
	}

	//Build the hashMap
	std::map<std::vector<size_t>, size_t> hashMap;
	bool schlonz = true;
	for (size_t i = 0; i < ret.size();)
	{
		hashMap.clear();
		for (size_t j = 0; j < ret.at(i).size(); ++j)
		{
			if (ret.at(i).at(j).first == schlonz)
			{
				if (hashMap.find(ret.at(i).at(j).second) == hashMap.end())
				{
					hashMap.insert(std::pair<std::vector<size_t>, size_t>(ret.at(i).at(j).second, 0));
				}
				hashMap.at(ret.at(i).at(j).second) += 1;
			}
		}
		if (hashMap.size() == 1 && hashMap.begin()->first.size() > 1)
		{
			for (size_t j = 0; j < ret.at(i).size();)
			{
				if (ret.at(i).at(j).first == schlonz)
				{
					ret.at(i).erase(ret.at(i).begin()+j);
					continue;
				}
				++j;
			}
		}
		//Kill also all unnecessary entries
		for (std::map<std::vector<size_t>, size_t>::iterator j = hashMap.begin(); j != hashMap.end();)
		{
			bool killMe = false;
			for (std::map<std::vector<size_t>, size_t>::iterator x = j; x != hashMap.end();)
			{
				if (x == j)
				{
					++x;
					continue;
				}
				if (j->first.size() == x->first.size())
				{
					if (j->second >= x->second)
					{
						if (j->second == x->second)
							killMe = true;
						for (size_t kill = 0; kill < ret.at(i).size();)
						{
							if (ret.at(i).at(kill).first == schlonz && ret.at(i).at(kill).second == x->first)
							{
								ret.at(i).erase(ret.at(i).begin()+kill);
								continue;
							}
							++kill;
						}
						x = hashMap.erase(x);
						continue;
					}
					else
					{
						killMe = true;
					}
				}
				++x;
			}
			if (killMe == true)
			{
				for (size_t kill = 0; kill < ret.at(i).size();)
				{
					if (ret.at(i).at(kill).first == schlonz && ret.at(i).at(kill).second == j->first)
					{
						ret.at(i).erase(ret.at(i).begin()+kill);
						continue;
					}
					++kill;
				}
				j = hashMap.erase(j);
				continue;
			}
			++j;
		}
		if (schlonz == true)
		{
			schlonz = false;
		}
		else
		{
			schlonz = true;
			++i;
		}
	}

	//Parity distribution is estimated
	for (size_t i = 0; i < inFiles.size(); ++i)
	{
		size_t bestFit = 0;
		size_t highestScore=0;
		for (size_t j = 0; j < inFiles.size(); ++j)
		{
			//std::cout << parityDistribution.at(i).at(j) << "\t";
			if (parityDistribution.at(i).at(j) > highestScore)
			{
				highestScore = parityDistribution.at(i).at(j);
				bestFit = j;
			}
		}
		parityDist.push_back(bestFit);
		//std::cout << std::endl;
	}
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %rbp
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq 0x48(%rsi), %rsi
subq 0x40(%rbp), %rsi
sarq $0x3, %rsi
movq %rdi, 0x8(%rsp)
callq 0xd8a2
movq %rbx, 0xd0(%rsp)
movq (%r14), %rbx
movq 0x8(%r14), %r12
cmpq %rbx, %r12
je 0xb860
movq 0x8(%rbx), %rax
subq (%rbx), %rax
sarq $0x3, %rax
movabsq $0x6db6db6db6db6db7, %r13 # imm = 0x6DB6DB6DB6DB6DB7
imulq %r13, %rax
movq %rax, 0x10(%rsp)
xorps %xmm0, %xmm0
leaq 0x90(%rsp), %r14
movaps %xmm0, (%r14)
movq $0x0, 0x10(%r14)
leaq 0x40(%rsp), %r15
movq (%rbx), %rax
movq %rax, 0x40(%rsp)
movq 0x98(%rsp), %rsi
cmpq 0xa0(%rsp), %rsi
je 0xaba4
movq %rax, (%rsi)
addq $0x8, 0x98(%rsp)
jmp 0xabaf
movq %r14, %rdi
movq %r15, %rdx
callq 0x10070
movq 0x8(%rbx), %rax
subq (%rbx), %rax
sarq $0x3, %rax
imulq %r13, %rax
movq 0x10(%rsp), %rcx
cmpq %rax, %rcx
cmovaeq %rax, %rcx
movq %rcx, 0x10(%rsp)
addq $0x18, %rbx
cmpq %r12, %rbx
jne 0xab7c
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%rsp)
xorl %eax, %eax
movq %rax, 0x30(%rsp)
movq %rax, 0xc0(%rsp)
movaps %xmm0, 0xb0(%rsp)
movq 0x40(%rbp), %rax
movq 0x48(%rbp), %rcx
cmpq %rax, %rcx
je 0xacb9
xorl %ebx, %ebx
leaq 0xb0(%rsp), %r14
leaq 0x40(%rsp), %r12
leaq 0x70(%rsp), %r13
xorps %xmm0, %xmm0
movaps %xmm0, 0x40(%rsp)
movq $0x0, 0x50(%rsp)
cmpq %rax, %rcx
je 0xac81
xorl %r15d, %r15d
movq $0x0, 0x70(%rsp)
movq 0x48(%rsp), %rsi
cmpq 0x50(%rsp), %rsi
je 0xac5c
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x48(%rsp)
jmp 0xac6f
movq %r12, %rdi
movq %r13, %rdx
callq 0x101ae
movq 0x40(%rbp), %rax
movq 0x48(%rbp), %rcx
incq %r15
movq %rcx, %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rdx, %r15
jb 0xac35
movq %r14, %rdi
movq %r12, %rsi
callq 0xdbf0
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0xac9b
callq 0x5390
incq %rbx
movq 0x40(%rbp), %rax
movq 0x48(%rbp), %rcx
movq %rcx, %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rdx, %rbx
jb 0xac1c
cmpq $0x0, 0x10(%rsp)
movq %rbp, 0xc8(%rsp)
je 0xb1c5
movq 0x90(%rsp), %rbx
movq 0x98(%rsp), %r14
movq $-0x1, %r12
cmpq %r14, %rbx
je 0xad03
movq %rbx, %rax
movq (%rax), %rcx
movq 0x18(%rcx), %rcx
cmpq %r12, %rcx
cmovbq %rcx, %r12
addq $0x8, %rax
cmpq %r14, %rax
jne 0xacec
movq 0x20(%rsp), %rax
cmpq %rax, 0x28(%rsp)
je 0xad14
movq %rax, 0x28(%rsp)
movq $0x0, 0x18(%rsp)
cmpq %r14, %rbx
je 0xae93
leaq 0x1(%r12), %r15
movb $0x1, %r13b
xorl %eax, %eax
movq (%rbx), %rcx
movq 0x18(%rcx), %rcx
cmpq %r12, %rcx
je 0xad6a
cmpq %r15, %rcx
jne 0xad82
movq 0x28(%rsp), %rsi
cmpq 0x30(%rsp), %rsi
je 0xad5b
movq %rax, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x28(%rsp)
jmp 0xad6a
leaq 0x20(%rsp), %rdi
leaq 0x18(%rsp), %rdx
callq 0xe340
movq 0x18(%rsp), %rax
incq %rax
movq %rax, 0x18(%rsp)
addq $0x8, %rbx
cmpq %r14, %rbx
jne 0xad30
jmp 0xada0
movq 0x18(%rsp), %rax
incq %rax
movq %rax, 0x18(%rsp)
addq $0x8, %rbx
xorl %r13d, %r13d
cmpq %r14, %rbx
jne 0xad30
jmp 0xafd6
testb $0x1, %r13b
je 0xafd6
movq 0x20(%rsp), %rax
cmpq 0x28(%rsp), %rax
je 0xae93
movb $0x0, 0x40(%rsp)
leaq 0x48(%rsp), %rax
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movb $0x1, 0x70(%rsp)
leaq 0x78(%rsp), %rbx
movq %rbx, %rdi
leaq 0x20(%rsp), %rsi
callq 0xde80
movb 0x70(%rsp), %al
movb %al, 0x40(%rsp)
movq 0x48(%rsp), %rdi
movups 0x78(%rsp), %xmm0
movups %xmm0, 0x48(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x58(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq $0x0, 0x10(%rbx)
testq %rdi, %rdi
je 0xae34
callq 0x5390
movq 0x78(%rsp), %rdi
testq %rdi, %rdi
je 0xae34
callq 0x5390
movq 0x48(%rbp), %rcx
subq 0x40(%rbp), %rcx
sarq $0x3, %rcx
movq %r12, %rax
xorl %edx, %edx
divq %rcx
movq 0x8(%rsp), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rax
subq %rcx, %rax
sarq $0x3, %rax
movabsq $-0x5555555555555555, %rsi # imm = 0xAAAAAAAAAAAAAAAB
imulq %rsi, %rax
cmpq %rdx, %rax
jbe 0xb84c
leaq (%rdx,%rdx,2), %rax
leaq (%rcx,%rax,8), %rdi
leaq 0x40(%rsp), %rsi
callq 0xda6a
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0xae93
callq 0x5390
movq 0x90(%rsp), %rbx
movq 0x98(%rsp), %r13
movq $-0x1, %rdi
cmpq %r13, %rbx
je 0xaedd
movq %rbx, %rax
movq %rdi, %rcx
movq (%rax), %rdx
movq 0x8(%rdx), %rdi
subq (%rdx), %rdi
sarq $0x2, %rdi
cmpq %rcx, %rdi
cmovaeq %rcx, %rdi
addq $0x8, %rax
cmpq %r13, %rax
jne 0xaeb2
cmpq $0x2, %rdi
jb 0xafe6
movq 0x48(%rbp), %rax
subq 0x40(%rbp), %rax
sarq $0x3, %rax
movq %rax, 0x38(%rsp)
movq 0xb0(%rsp), %r10
movq 0xb8(%rsp), %r9
subq %r10, %r9
sarq $0x3, %r9
movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB
imulq %rax, %r9
movl $0x1, %r11d
leaq (%r11,%r12), %rax
xorl %edx, %edx
divq 0x38(%rsp)
movl $0x0, %esi
cmpq %r13, %rbx
je 0xaf96
leaq -0x1(%r11), %rax
xorps %xmm0, %xmm0
xorl %r14d, %r14d
xorl %r15d, %r15d
xorl %esi, %esi
movq (%rbx,%r15,8), %rcx
movq (%rcx), %rbp
movq 0x8(%rcx), %r8
subq %rbp, %r8
sarq $0x2, %r8
cmpq %r12, 0x18(%rcx)
jne 0xaf67
cmpq %r11, %r8
jbe 0xb7bb
movss (%rbp,%r11,4), %xmm1
jmp 0xaf77
cmpq %rax, %r8
jbe 0xb7be
movss -0x4(%rbp,%r11,4), %xmm1
ucomiss %xmm0, %xmm1
jbe 0xaf82
movaps %xmm1, %xmm0
movq %r15, %rsi
incq %r15
leaq (%rbx,%r14), %rcx
addq $0x8, %rcx
addq $0x8, %r14
cmpq %r13, %rcx
jne 0xaf3d
cmpq %rdx, %r9
jbe 0xb7ff
leaq (%rdx,%rdx,2), %rcx
movq (%r10,%rcx,8), %rax
movq 0x8(%r10,%rcx,8), %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rsi, %rdx
jbe 0xb7fa
incq (%rax,%rsi,8)
incq %r11
cmpq %rdi, %r11
jne 0xaf19
movq 0xc8(%rsp), %rbp
jmp 0xafe6
movq 0x90(%rsp), %rbx
movq 0x98(%rsp), %r13
movq $-0x1, %r14
cmpq %r13, %rbx
je 0xb00c
movq %rbx, %rax
movq (%rax), %rcx
movq 0x28(%rcx), %rcx
cmpq %r14, %rcx
cmovbq %rcx, %r14
addq $0x8, %rax
cmpq %r13, %rax
jne 0xaff5
movq 0x20(%rsp), %rax
cmpq %rax, 0x28(%rsp)
je 0xb01d
movq %rax, 0x28(%rsp)
movq $0x0, 0x18(%rsp)
movq %rax, %rcx
cmpq %r13, %rbx
je 0xb0cd
leaq 0x1(%r14), %r12
movb $0x1, %r15b
xorl %eax, %eax
movq (%rbx), %rcx
movq 0x28(%rcx), %rdx
cmpq %r14, %rdx
jne 0xb061
movq 0x28(%rsp), %rsi
cmpq 0x30(%rsp), %rsi
je 0xb06f
movq %rax, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x28(%rsp)
jmp 0xb081
cmpq %r12, %rdx
jne 0xb0a0
addq $0x38, %rcx
movq %rcx, (%rbx)
jmp 0xb08d
leaq 0x20(%rsp), %rdi
leaq 0x18(%rsp), %rdx
callq 0xe340
movq (%rbx), %rcx
addq $0x38, %rcx
movq %rcx, (%rbx)
movq 0x18(%rsp), %rax
incq %rax
movq %rax, 0x18(%rsp)
addq $0x8, %rbx
cmpq %r13, %rbx
jne 0xb03b
jmp 0xb0b9
incq %rax
movq %rax, 0x18(%rsp)
addq $0x8, %rbx
xorl %r15d, %r15d
cmpq %r13, %rbx
jne 0xb03b
jmp 0xb1ba
testb $0x1, %r15b
je 0xb1ba
movq 0x20(%rsp), %rax
movq 0x28(%rsp), %rcx
subq %rax, %rcx
movq 0x48(%rbp), %rax
subq 0x40(%rbp), %rax
cmpq %rax, %rcx
jae 0xb1ba
xorl %ecx, %ecx
movb %cl, 0x40(%rsp)
leaq 0x48(%rsp), %rax
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movb %cl, 0x70(%rsp)
leaq 0x78(%rsp), %rbx
movq %rbx, %rdi
leaq 0x20(%rsp), %rsi
callq 0xde80
movb 0x70(%rsp), %al
movb %al, 0x40(%rsp)
movq 0x48(%rsp), %rdi
movups 0x78(%rsp), %xmm0
movups %xmm0, 0x48(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x58(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq $0x0, 0x10(%rbx)
testq %rdi, %rdi
movabsq $-0x5555555555555555, %rbx # imm = 0xAAAAAAAAAAAAAAAB
je 0xb165
callq 0x5390
movq 0x78(%rsp), %rdi
testq %rdi, %rdi
je 0xb165
callq 0x5390
movq 0x48(%rbp), %rcx
subq 0x40(%rbp), %rcx
sarq $0x3, %rcx
movq %r14, %rax
xorl %edx, %edx
divq %rcx
movq 0x8(%rsp), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rax
subq %rcx, %rax
sarq $0x3, %rax
imulq %rbx, %rax
cmpq %rdx, %rax
jbe 0xb838
leaq (%rdx,%rdx,2), %rax
leaq (%rcx,%rax,8), %rdi
leaq 0x40(%rsp), %rsi
callq 0xda6a
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0xb1ba
callq 0x5390
decq 0x10(%rsp)
jne 0xaccd
leaq 0x48(%rsp), %rcx
movl $0x0, (%rcx)
xorl %eax, %eax
movq %rax, 0x8(%rcx)
movq %rcx, 0x10(%rcx)
movq %rcx, 0x18(%rcx)
movq %rax, 0x20(%rcx)
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
cmpq (%rcx), %rax
movabsq $-0x5555555555555555, %r12 # imm = 0xAAAAAAAAAAAAAAAB
je 0xb65d
movb $0x1, %r14b
xorl %ebx, %ebx
leaq 0x40(%rsp), %rbp
movq %rbp, %rdi
callq 0x10458
movq 0x8(%rsp), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rax
movq %rax, %rdx
subq %rcx, %rdx
sarq $0x3, %rdx
imulq %r12, %rdx
cmpq %rbx, %rdx
jbe 0xb7e9
movb %r14b, 0x7(%rsp)
andb $0x1, %r14b
movb %r14b, 0x38(%rsp)
movl $0x8, %r14d
leaq (%rbx,%rbx,2), %r13
xorl %r15d, %r15d
movq (%rcx,%r13,8), %rsi
movq 0x8(%rcx,%r13,8), %rdx
subq %rsi, %rdx
sarq $0x5, %rdx
cmpq %rdx, %r15
jae 0xb36f
movb 0x38(%rsp), %dl
cmpb %dl, -0x8(%rsi,%r14)
jne 0xb34c
addq %r14, %rsi
movq %rbp, %rdi
callq 0x10486
leaq 0x48(%rsp), %rcx
cmpq %rcx, %rax
jne 0xb2f9
movq 0x8(%rsp), %rcx
movq (%rcx), %rax
movq 0x8(%rcx), %rdx
subq %rax, %rdx
sarq $0x3, %rdx
imulq %r12, %rdx
cmpq %rbx, %rdx
jbe 0xb827
movq (%rax,%r13,8), %rsi
movq 0x8(%rax,%r13,8), %rdx
subq %rsi, %rdx
sarq $0x5, %rdx
cmpq %r15, %rdx
leaq 0x70(%rsp), %rdi
jbe 0xb824
addq %r14, %rsi
callq 0xde80
movq $0x0, 0x88(%rsp)
movq %rbp, %rdi
leaq 0x70(%rsp), %rsi
callq 0x1053e
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0xb2f9
callq 0x5390
movq 0x8(%rsp), %rcx
movq (%rcx), %rax
movq 0x8(%rcx), %rdx
subq %rax, %rdx
sarq $0x3, %rdx
imulq %r12, %rdx
cmpq %rbx, %rdx
jbe 0xb7e9
movq (%rax,%r13,8), %rsi
movq 0x8(%rax,%r13,8), %rdx
subq %rsi, %rdx
sarq $0x5, %rdx
cmpq %r15, %rdx
jbe 0xb7e6
addq %r14, %rsi
movq %rbp, %rdi
callq 0xdc56
incq (%rax)
movq 0x8(%rsp), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rax
incq %r15
movq %rax, %rdx
subq %rcx, %rdx
sarq $0x3, %rdx
imulq %r12, %rdx
addq $0x20, %r14
cmpq %rbx, %rdx
ja 0xb24e
jmp 0xb7e9
movq %rbx, 0x10(%rsp)
movq 0x58(%rsp), %rbp
cmpq $0x1, 0x68(%rsp)
jne 0xb3f6
movq 0x28(%rbp), %rdx
subq 0x20(%rbp), %rdx
cmpq $0x9, %rdx
leaq 0x48(%rsp), %r15
jb 0xb402
xorl %ebx, %ebx
movq 0x10(%rsp), %r14
movq 0x8(%rsp), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rax
movq %rax, %rdx
subq %rcx, %rdx
sarq $0x3, %rdx
imulq %r12, %rdx
cmpq %r14, %rdx
jbe 0xb813
movq (%rcx,%r13,8), %rsi
movq 0x8(%rcx,%r13,8), %rdx
subq %rsi, %rdx
sarq $0x5, %rdx
cmpq %rdx, %rbx
jae 0xb3fd
movq %rbx, %rax
shlq $0x5, %rax
movb 0x38(%rsp), %dl
cmpb %dl, (%rsi,%rax)
jne 0xb3f1
leaq (%rcx,%r13,8), %rdi
addq %rax, %rsi
callq 0x106ee
jmp 0xb39b
incq %rbx
jmp 0xb39b
leaq 0x48(%rsp), %r15
jmp 0xb402
movq 0x58(%rsp), %rbp
cmpq %r15, %rbp
je 0xb626
xorl %ebx, %ebx
movq %rbp, %r14
cmpq %rbp, %r14
jne 0xb42a
movq %r14, %rdi
callq 0x5270
movq %rax, %r14
cmpq %r15, %rax
jne 0xb410
jmp 0xb547
movq 0x28(%rbp), %rax
subq 0x20(%rbp), %rax
movq 0x28(%r14), %rcx
subq 0x20(%r14), %rcx
cmpq %rcx, %rax
jne 0xb4f9
movq 0x38(%r14), %rax
movb $0x1, %cl
cmpq %rax, 0x38(%rbp)
jb 0xb4fb
sete %al
orb %bl, %al
movb %al, 0x6(%rsp)
xorl %r12d, %r12d
movq 0x8(%rsp), %rax
movq (%rax), %rbx
movq 0x8(%rax), %rdx
subq %rbx, %rdx
sarq $0x3, %rdx
movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB
imulq %rax, %rdx
cmpq 0x10(%rsp), %rdx
jbe 0xb7a8
movq (%rbx,%r13,8), %r15
movq 0x8(%rbx,%r13,8), %rax
subq %r15, %rax
sarq $0x5, %rax
cmpq %rax, %r12
jae 0xb50c
movq %r12, %rax
shlq $0x5, %rax
movb 0x38(%rsp), %cl
cmpb %cl, (%r15,%rax)
jne 0xb4f1
addq %rax, %r15
movq 0x8(%r15), %rdi
movq 0x10(%r15), %rax
movq %rax, %rdx
subq %rdi, %rdx
movq 0x20(%r14), %rsi
movq 0x28(%r14), %rcx
subq %rsi, %rcx
cmpq %rcx, %rdx
jne 0xb4f1
cmpq %rdi, %rax
je 0xb4e0
callq 0x53f0
testl %eax, %eax
jne 0xb4f1
leaq (%rbx,%r13,8), %rdi
movq %r15, %rsi
callq 0x106ee
jmp 0xb45f
incq %r12
jmp 0xb45f
movl %ebx, %ecx
movb %cl, 0x6(%rsp)
movq %r14, %rdi
callq 0x5270
movq %rax, %r14
jmp 0xb536
movq %r14, %rdi
callq 0x5270
movq %rax, %r15
leaq 0x40(%rsp), %rdi
movq %r14, %rsi
callq 0x10760
movq %r15, %r14
movabsq $-0x5555555555555555, %r12 # imm = 0xAAAAAAAAAAAAAAAB
leaq 0x48(%rsp), %r15
movb 0x6(%rsp), %al
movl %eax, %ebx
cmpq %r15, %r14
jne 0xb410
jmp 0xb549
movl %ebx, %eax
testb $0x1, %al
je 0xb5e4
xorl %r15d, %r15d
movq 0x8(%rsp), %rax
movq (%rax), %rbx
movq 0x8(%rax), %rdx
subq %rbx, %rdx
sarq $0x3, %rdx
imulq %r12, %rdx
cmpq 0x10(%rsp), %rdx
jbe 0xb795
movq (%rbx,%r13,8), %r14
movq 0x8(%rbx,%r13,8), %rax
subq %r14, %rax
sarq $0x5, %rax
cmpq %rax, %r15
jae 0xb5f1
movq %r15, %rax
shlq $0x5, %rax
movb 0x38(%rsp), %cl
cmpb %cl, (%r14,%rax)
jne 0xb5dc
addq %rax, %r14
movq 0x8(%r14), %rdi
movq 0x10(%r14), %rax
movq %rax, %rdx
subq %rdi, %rdx
movq 0x20(%rbp), %rsi
movq 0x28(%rbp), %rcx
subq %rsi, %rcx
cmpq %rcx, %rdx
jne 0xb5dc
cmpq %rdi, %rax
je 0xb5cb
callq 0x53f0
testl %eax, %eax
jne 0xb5dc
leaq (%rbx,%r13,8), %rdi
movq %r14, %rsi
callq 0x106ee
jmp 0xb554
incq %r15
jmp 0xb554
movq %rbp, %rdi
callq 0x5270
movq %rax, %rbp
jmp 0xb611
movq %rbp, %rdi
callq 0x5270
movq %rax, %r14
leaq 0x40(%rsp), %rdi
movq %rbp, %rsi
callq 0x10760
movq %r14, %rbp
leaq 0x48(%rsp), %r15
cmpq %r15, %rbp
jne 0xb40b
movq 0x8(%rsp), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rax
subq %rcx, %rax
movb 0x7(%rsp), %r14b
xorb $0x1, %r14b
movb 0x38(%rsp), %cl
xorb $0x1, %cl
movzbl %cl, %ecx
movq 0x10(%rsp), %rbx
addq %rcx, %rbx
sarq $0x3, %rax
imulq %r12, %rax
cmpq %rax, %rbx
movq 0xc8(%rsp), %rbp
jb 0xb203
movq 0x40(%rbp), %rax
movq 0x48(%rbp), %rcx
movq %rcx, %rsi
subq %rax, %rsi
movq 0xd0(%rsp), %rbx
je 0xb746
sarq $0x3, %rsi
xorl %r14d, %r14d
leaq 0x70(%rsp), %r12
movq $0x0, 0x70(%rsp)
movq 0xb0(%rsp), %r8
movq 0xb8(%rsp), %rdx
subq %r8, %rdx
sarq $0x3, %rdx
movabsq $-0x5555555555555555, %rdi # imm = 0xAAAAAAAAAAAAAAAB
imulq %rdi, %rdx
cmpq %r14, %rdx
jbe 0xb7d5
leaq (%r14,%r14,2), %rdx
movq (%r8,%rdx,8), %rdi
movq 0x8(%r8,%rdx,8), %rdx
subq %rdi, %rdx
sarq $0x3, %rdx
cmpq $0x1, %rsi
adcq $0x0, %rsi
xorl %r8d, %r8d
xorl %r9d, %r9d
xorl %r10d, %r10d
cmpq %r9, %rdx
je 0xb7d2
movq (%rdi,%r9,8), %r11
cmpq %r10, %r11
jbe 0xb6fe
movq %r9, 0x70(%rsp)
movq %r9, %r8
movq %r11, %r10
incq %r9
cmpq %r9, %rsi
jne 0xb6e1
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0xb71d
movq %r8, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x8(%rbx)
jmp 0xb730
movq %rbx, %rdi
movq %r12, %rdx
callq 0xe340
movq 0x40(%rbp), %rax
movq 0x48(%rbp), %rcx
incq %r14
movq %rcx, %rsi
subq %rax, %rsi
sarq $0x3, %rsi
cmpq %rsi, %r14
jb 0xb685
leaq 0x40(%rsp), %rdi
callq 0xdf1c
leaq 0xb0(%rsp), %rdi
callq 0xdcd8
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0xb76c
callq 0x5390
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0xb77e
callq 0x5390
movq 0x8(%rsp), %rax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x912d(%rip), %rdi      # 0x148c9
movq 0x10(%rsp), %rsi
xorl %eax, %eax
callq 0x5570
leaq 0x911a(%rip), %rdi      # 0x148c9
movq 0x10(%rsp), %rsi
xorl %eax, %eax
callq 0x5570
movq %r11, %rax
leaq 0x9104(%rip), %rdi      # 0x148c9
movq %rax, %rsi
movq %r8, %rdx
xorl %eax, %eax
callq 0x5570
movq %rdx, %r14
leaq 0x90ed(%rip), %rdi      # 0x148c9
movq %r14, %rsi
xorl %eax, %eax
callq 0x5570
movq %r15, %rbx
leaq 0x90d9(%rip), %rdi      # 0x148c9
movq %rbx, %rsi
xorl %eax, %eax
callq 0x5570
movq %rdx, %r9
jmp 0xb802
movq %rdx, %rsi
leaq 0x90c0(%rip), %rdi      # 0x148c9
movq %r9, %rdx
xorl %eax, %eax
callq 0x5570
leaq 0x90af(%rip), %rdi      # 0x148c9
movq %r14, %rsi
xorl %eax, %eax
callq 0x5570
movq %r15, %rbx
leaq 0x909b(%rip), %rdi      # 0x148c9
movq %rbx, %rsi
xorl %eax, %eax
callq 0x5570
leaq 0x908a(%rip), %rdi      # 0x148c9
movq %rdx, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x5570
leaq 0x9076(%rip), %rdi      # 0x148c9
movq %rdx, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x5570
leaq 0x9062(%rip), %rdi      # 0x148c9
xorl %esi, %esi
xorl %edx, %edx
xorl %eax, %eax
callq 0x5570
jmp 0xb874
movq %rax, %r14
jmp 0xb91d
jmp 0xb886
jmp 0xb886
jmp 0xb886
jmp 0xb886
jmp 0xb886
movq %rax, %r14
movq 0x48(%rsp), %rdi
jmp 0xb8bd
jmp 0xb8e2
movq %rax, %r14
jmp 0xb90b
jmp 0xb8b5
jmp 0xb8dd
jmp 0xb8dd
jmp 0xb8e2
movq %rax, %r14
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0xb8e5
callq 0x5390
jmp 0xb8e5
jmp 0xb8e2
movq %rax, %r14
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0xb8ef
callq 0x5390
jmp 0xb8ef
jmp 0xb8e2
jmp 0xb8e2
jmp 0xb8e2
jmp 0xb8e2
jmp 0xb8dd
jmp 0xb8e2
jmp 0xb8e2
jmp 0xb8e2
jmp 0xb8e2
jmp 0xb8e2
movq %rax, %r14
jmp 0xb8ef
movq %rax, %r14
leaq 0x40(%rsp), %rdi
callq 0xdf1c
leaq 0xb0(%rsp), %rdi
callq 0xdcd8
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0xb90b
callq 0x5390
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0xb91d
callq 0x5390
movq 0x8(%rsp), %rdi
callq 0xdb2a
movq %r14, %rdi
callq 0x5650
nop