// File: Proudc[P]CTSS/src/Test.cpp
// Function: roadContinuousQuery(Graph*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int, int)
void roadContinuousQuery(Graph* myGraph, string inputFolder, string outputFolder, const int startCount, const int stopCount)
{
	int count = startCount;
	while (count <= stopCount)
	{
		printf("Start %dth query...\n", count);
		string strCount = changeIntToStr(count);
		ReferencePath* referencePath = new ReferencePath;
		CompletePath*  completePath  = new CompletePath;
		setQueryEnv(myGraph, referencePath, completePath, inputFolder, strCount);
		
		int    currentVertex = completePath->initialVertex;
		int    recordPos = 0;
		int    timeFlag  = 0;
		int    ifCalFlag = 0;
		Record record[completePath->edges.size()];
		double currPathLength = 0.0;
		double boundDistance  = 0.0;
		double pathDistance;
		vector<Edge> temPath;
		vector<Edge> lastPath;
		initializeLastPath(referencePath, lastPath);
		
		clock_t startTime = clock();
		for (unsigned int i = 1; i < completePath->edges.size(); i++)
		{
			ifCalFlag = 0;
			currPathLength += completePath->edges[i - 1].realLength;
			if (completePath->edges[i - 1].firstVertexID == currentVertex)
			{
				currentVertex = completePath->edges[i - 1].secVertexID;
			}
			else
			{
				currentVertex = completePath->edges[i - 1].firstVertexID;
			}

			vector<Edge> currentPath;
			setCurrPath(myGraph, &currentPath, completePath, i);
			
			Record* temRecord = new Record;
			temRecord->ratioNumEdge = ((double)(i)) / completePath->edges.size();
			temRecord->runTime = 0;
			temRecord->comPathSize = completePath->edges.size();
			temRecord->numOfOutPriQueue = 0;
			temRecord->referPathLength = referencePath->referenceLength;
			temRecord->ratioPathLength = currPathLength / (completePath->completeLength);
			temRecord->currPathLength = currPathLength;
			temRecord->comPathLength = completePath->completeLength;
			record[recordPos++] = (*temRecord);

			if (lastPath[i - 1].edgeID == currentPath[i - 1].edgeID)
			{
				continue;
			}
			else
			{
				int firstVertexID;
				int secVertexID;
				int endVertexID;
				if (currentPath[i - 1].firstVertexID == currentVertex)
				{
					firstVertexID = currentPath[i - 1].secVertexID;
					secVertexID   = currentPath[i - 1].firstVertexID;
				}
				else
				{
					firstVertexID = currentPath[i - 1].firstVertexID;
					secVertexID   = currentPath[i - 1].secVertexID;
				}													
				vector<Edge> localPath;
				maxmalOverlapPath(myGraph, localPath, lastPath, firstVertexID, secVertexID, &endVertexID);
				if (localPath.size() == 0)
				{
					printf("localPath's size is 0\n");
					int  timeOutFlag = 0;
					bool queryResultFlag = roadSimpleQueryPath(myGraph, referencePath, currentPath, temPath, temRecord, currentVertex, &timeOutFlag, &pathDistance);
					if (queryResultFlag == false)
					{
						if (timeOutFlag == 1)
						{
							timeFlag = 1;
							break;
						}
						else
						{
							timeOutFlag = 0;
							bool queryResultFlagWithLoop = roadSimleQueryPathWithLoop(myGraph, referencePath, currentPath, temPath, temRecord, currentVertex, &timeOutFlag, &pathDistance);
							if (queryResultFlagWithLoop == false)
							{
								if (timeOutFlag == 1)
								{
									timeFlag = 1;
								}
								break;
							}
							else
							{
								updateLastPath(lastPath, temPath, &boundDistance, &pathDistance);
							}
						}
					}
					else
					{
						updateLastPath(lastPath, temPath, &boundDistance, &pathDistance);
					}
				}
				else
				{
					printf("localPath's size is not 0\n");
					vector<Edge> localLastPath;
					int edgePos;
					for (edgePos = i - 1; edgePos < lastPath.size(); edgePos++)
					{
						int temFirstVertexID = lastPath[edgePos].firstVertexID;
						int temSecVertexID   = lastPath[edgePos].secVertexID;
						if (temFirstVertexID == endVertexID || temSecVertexID == endVertexID)
						{
							localLastPath.push_back(lastPath[edgePos]);
							break;
						}
						localLastPath.push_back(lastPath[edgePos]);
					}
					double temDistance = dfdBetweenTwoLocalPaths(myGraph, localPath, localLastPath, firstVertexID);
					boundDistance += temDistance;
					if (boundDistance <= myGraph->delta)
					{
						replacePath(lastPath, localPath, i - 1, edgePos + 1);
					}
					else
					{
						int  timeOutFlag = 0;
						bool queryResultFlag = roadSimpleQueryPath(myGraph, referencePath, currentPath, temPath, temRecord, currentVertex, &timeOutFlag, &pathDistance);
						if (queryResultFlag == false)
						{
							if (timeOutFlag == 1)
							{
								timeFlag = 1;
								break;
							}
							else
							{
								timeOutFlag = 0;
								bool queryResultFlagWithLoop = roadSimleQueryPathWithLoop(myGraph, referencePath, currentPath, temPath, temRecord, currentVertex, &timeOutFlag, &pathDistance);
								if (queryResultFlagWithLoop == false)
								{
									if (timeOutFlag == 1)
									{
										timeFlag = 1;
									}
									break;
								}
								else
								{
									updateLastPath(lastPath, temPath, &boundDistance, &pathDistance);
								}
							}
						}
						else
						{
							updateLastPath(lastPath, temPath, &boundDistance, &pathDistance);
						}
					}
				}
			}
		}
		clock_t stopTime = clock();
		if (timeFlag == 1)
		{
			count++;
			continue;
		}
		string writeFilePath = outputFolder + "/" + strCount + "roadContinuousQuery.txt";
		writeContinuousRecordToFile(record, recordPos, writeFilePath, (double)(stopTime - startTime) / CLOCKS_PER_SEC);
		
		delete referencePath;
		delete completePath;
		count++;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x3a0, %rsp            # imm = 0x3A0
movq %rsi, -0x2b0(%rbp)
movq %rdx, -0x2a8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl %r8d, -0x20(%rbp)
movl -0x1c(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x20(%rbp), %eax
jg 0x528d
movl -0x24(%rbp), %esi
leaq 0x14cf3(%rip), %rdi     # 0x1907b
xorl %eax, %eax
callq 0x2040
movl -0x24(%rbp), %esi
leaq -0x48(%rbp), %rdi
callq 0x6680
movl $0x38, %edi
callq 0x2170
movq %rax, -0x2b8(%rbp)
jmp 0x43ae
movq -0x2b8(%rbp), %rdi
callq 0x5320
movq -0x2b8(%rbp), %rax
movq %rax, -0x50(%rbp)
movl $0x28, %edi
callq 0x2170
movq %rax, -0x2c0(%rbp)
jmp 0x43d8
movq -0x2c0(%rbp), %rdi
callq 0x5340
movq -0x2c0(%rbp), %rax
movq -0x2b0(%rbp), %rsi
movq %rax, -0x68(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x2d8(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x2d0(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x2c8(%rbp)
leaq -0x88(%rbp), %rdi
callq 0x2090
jmp 0x4425
leaq -0xa8(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x2090
jmp 0x4437
movq -0x2c8(%rbp), %rdx
movq -0x2d0(%rbp), %rsi
movq -0x2d8(%rbp), %rdi
leaq -0x88(%rbp), %rcx
leaq -0xa8(%rbp), %r8
callq 0x66b0
jmp 0x4461
leaq -0xa8(%rbp), %rdi
callq 0x20d0
leaq -0x88(%rbp), %rdi
callq 0x20d0
movq -0x68(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xac(%rbp)
movl $0x0, -0xb0(%rbp)
movl $0x0, -0xb4(%rbp)
movl $0x0, -0xb8(%rbp)
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
callq 0x5360
movq %rsp, %rcx
movq %rcx, -0xc0(%rbp)
movq %rax, %rcx
shlq $0x4, %rcx
leaq (%rcx,%rcx,4), %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x2e8(%rbp)
movq %rcx, %rsp
movq %rax, -0xc8(%rbp)
movq $0x0, -0xd0(%rbp)
movq $0x0, -0xd8(%rbp)
leaq -0xf8(%rbp), %rdi
callq 0x53a0
leaq -0x110(%rbp), %rdi
movq %rdi, -0x2e0(%rbp)
callq 0x53a0
movq -0x2e0(%rbp), %rsi
movq -0x50(%rbp), %rdi
callq 0x8950
jmp 0x4523
callq 0x2100
movq %rax, -0x118(%rbp)
movl $0x1, -0x11c(%rbp)
movl -0x11c(%rbp), %eax
movq %rax, -0x2f0(%rbp)
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
callq 0x5360
movq %rax, %rcx
movq -0x2f0(%rbp), %rax
cmpq %rcx, %rax
jae 0x5052
movl $0x0, -0xb8(%rbp)
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x5380
movsd 0x18(%rax), %xmm0
addsd -0xd0(%rbp), %xmm0
movsd %xmm0, -0xd0(%rbp)
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x5380
movl 0x4(%rax), %eax
cmpl -0xac(%rbp), %eax
jne 0x4642
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x5380
movl 0x8(%rax), %eax
movl %eax, -0xac(%rbp)
jmp 0x4665
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x5282
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x4620
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0xa8(%rbp), %rdi
callq 0x20d0
leaq -0x88(%rbp), %rdi
callq 0x20d0
jmp 0x5282
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x526a
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x5380
movl 0x4(%rax), %eax
movl %eax, -0xac(%rbp)
leaq -0x138(%rbp), %rdi
movq %rdi, -0x2f8(%rbp)
callq 0x53a0
movq -0x2f8(%rbp), %rsi
movq -0x8(%rbp), %rdi
movq -0x68(%rbp), %rdx
movl -0x11c(%rbp), %ecx
callq 0x6c40
jmp 0x4694
movl $0x50, %edi
callq 0x2170
movq %rax, -0x300(%rbp)
jmp 0x46a7
movq -0x300(%rbp), %rax
movq %rax, -0x140(%rbp)
movl -0x11c(%rbp), %eax
cvtsi2sd %rax, %xmm0
movsd %xmm0, -0x310(%rbp)
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
callq 0x5360
movsd -0x310(%rbp), %xmm0
movq %rax, %xmm1
movaps 0x14927(%rip), %xmm2    # 0x19010
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x1492b(%rip), %xmm2    # 0x19020
subpd %xmm2, %xmm1
movaps %xmm1, %xmm2
unpckhpd %xmm1, %xmm1            # xmm1 = xmm1[1,1]
addsd %xmm2, %xmm1
divsd %xmm1, %xmm0
movq -0x140(%rbp), %rax
movsd %xmm0, 0x38(%rax)
movq -0x140(%rbp), %rax
xorps %xmm0, %xmm0
movsd %xmm0, 0x20(%rax)
movq -0x68(%rbp), %rdi
addq $0x10, %rdi
callq 0x5360
movq -0x2e8(%rbp), %rdi
movl %eax, %ecx
movq -0x140(%rbp), %rax
movl %ecx, 0x14(%rax)
movq -0x140(%rbp), %rax
movl $0x0, 0x10(%rax)
movq -0x50(%rbp), %rax
movsd 0x18(%rax), %xmm0
movq -0x140(%rbp), %rax
movsd %xmm0, 0x48(%rax)
movsd -0xd0(%rbp), %xmm0
movq -0x68(%rbp), %rax
divsd 0x8(%rax), %xmm0
movq -0x140(%rbp), %rax
movsd %xmm0, 0x40(%rax)
movsd -0xd0(%rbp), %xmm0
movq -0x140(%rbp), %rax
movsd %xmm0, 0x28(%rax)
movq -0x68(%rbp), %rax
movsd 0x8(%rax), %xmm0
movq -0x140(%rbp), %rax
movsd %xmm0, 0x30(%rax)
movq -0x140(%rbp), %rsi
movl -0xb0(%rbp), %eax
movl %eax, %ecx
addl $0x1, %ecx
movl %ecx, -0xb0(%rbp)
cltq
imulq $0x50, %rax, %rax
addq %rax, %rdi
movl $0x50, %edx
callq 0x2130
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x110(%rbp), %rdi
callq 0x5380
movl (%rax), %eax
movl %eax, -0x304(%rbp)
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x138(%rbp), %rdi
callq 0x5380
movq %rax, %rcx
movl -0x304(%rbp), %eax
cmpl (%rcx), %eax
jne 0x483e
movl $0x6, -0x144(%rbp)
jmp 0x4ffe
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x5041
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x138(%rbp), %rdi
callq 0x5380
movl 0x4(%rax), %eax
cmpl -0xac(%rbp), %eax
jne 0x48a8
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x138(%rbp), %rdi
callq 0x5380
movl 0x8(%rax), %eax
movl %eax, -0x148(%rbp)
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x138(%rbp), %rdi
callq 0x5380
movl 0x4(%rax), %eax
movl %eax, -0x14c(%rbp)
jmp 0x48ec
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x138(%rbp), %rdi
callq 0x5380
movl 0x4(%rax), %eax
movl %eax, -0x148(%rbp)
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x138(%rbp), %rdi
callq 0x5380
movl 0x8(%rax), %eax
movl %eax, -0x14c(%rbp)
leaq -0x168(%rbp), %rdi
movq %rdi, -0x318(%rbp)
callq 0x53a0
movq -0x318(%rbp), %rsi
movq -0x8(%rbp), %rdi
movl -0x148(%rbp), %ecx
movl -0x14c(%rbp), %r8d
leaq -0x110(%rbp), %rdx
leaq -0x150(%rbp), %r9
callq 0x13660
jmp 0x492c
leaq -0x168(%rbp), %rdi
callq 0x5360
cmpq $0x0, %rax
jne 0x4ba6
leaq 0x14770(%rip), %rdi     # 0x190b9
xorl %eax, %eax
callq 0x2040
jmp 0x4952
movl $0x0, -0x16c(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x328(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x320(%rbp)
leaq -0x188(%rbp), %rdi
leaq -0x138(%rbp), %rsi
callq 0x53c0
jmp 0x4987
movq -0x320(%rbp), %rsi
movq -0x328(%rbp), %rdi
movq -0x140(%rbp), %r8
movl -0xac(%rbp), %r9d
subq $0x10, %rsp
movq %rsp, %rax
leaq -0xe0(%rbp), %rcx
movq %rcx, 0x8(%rax)
leaq -0x16c(%rbp), %rcx
movq %rcx, (%rax)
leaq -0x188(%rbp), %rdx
leaq -0xf8(%rbp), %rcx
callq 0x10ba0
addq $0x10, %rsp
movb %al, -0x329(%rbp)
jmp 0x49de
leaq -0x188(%rbp), %rdi
callq 0x54b0
movb -0x329(%rbp), %al
andb $0x1, %al
movb %al, -0x16d(%rbp)
movb -0x16d(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x4b7c
cmpl $0x1, -0x16c(%rbp)
jne 0x4a5c
movl $0x1, -0xb4(%rbp)
movl $0x4, -0x144(%rbp)
jmp 0x4fcc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x4fe6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x188(%rbp), %rdi
callq 0x54b0
jmp 0x4fe6
movl $0x0, -0x16c(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x340(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x338(%rbp)
leaq -0x1a8(%rbp), %rdi
leaq -0x138(%rbp), %rsi
callq 0x53c0
jmp 0x4a91
movq -0x338(%rbp), %rsi
movq -0x340(%rbp), %rdi
movq -0x140(%rbp), %r8
movl -0xac(%rbp), %r9d
subq $0x10, %rsp
movq %rsp, %rax
leaq -0xe0(%rbp), %rcx
movq %rcx, 0x8(%rax)
leaq -0x16c(%rbp), %rcx
movq %rcx, (%rax)
leaq -0x1a8(%rbp), %rdx
leaq -0xf8(%rbp), %rcx
callq 0x12cd0
addq $0x10, %rsp
movb %al, -0x341(%rbp)
jmp 0x4ae8
leaq -0x1a8(%rbp), %rdi
callq 0x54b0
movb -0x341(%rbp), %al
andb $0x1, %al
movb %al, -0x189(%rbp)
movb -0x189(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x4b53
cmpl $0x1, -0x16c(%rbp)
jne 0x4b44
movl $0x1, -0xb4(%rbp)
jmp 0x4b44
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x1a8(%rbp), %rdi
callq 0x54b0
jmp 0x4fe6
movl $0x4, -0x144(%rbp)
jmp 0x4fcc
leaq -0x110(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
leaq -0xd8(%rbp), %rdx
leaq -0xe0(%rbp), %rcx
callq 0x88c0
jmp 0x4b76
jmp 0x4b78
jmp 0x4b7a
jmp 0x4ba1
leaq -0x110(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
leaq -0xd8(%rbp), %rdx
leaq -0xe0(%rbp), %rcx
callq 0x88c0
jmp 0x4b9f
jmp 0x4ba1
jmp 0x4fc2
leaq 0x14523(%rip), %rdi     # 0x190d0
xorl %eax, %eax
callq 0x2040
jmp 0x4bb6
leaq -0x1c0(%rbp), %rdi
callq 0x53a0
movl -0x11c(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x1c4(%rbp)
movslq -0x1c4(%rbp), %rax
movq %rax, -0x350(%rbp)
leaq -0x110(%rbp), %rdi
callq 0x5360
movq %rax, %rcx
movq -0x350(%rbp), %rax
cmpq %rcx, %rax
jae 0x4cc3
movslq -0x1c4(%rbp), %rsi
leaq -0x110(%rbp), %rdi
callq 0x5380
movl 0x4(%rax), %eax
movl %eax, -0x1c8(%rbp)
movslq -0x1c4(%rbp), %rsi
leaq -0x110(%rbp), %rdi
callq 0x5380
movl 0x8(%rax), %eax
movl %eax, -0x1cc(%rbp)
movl -0x1c8(%rbp), %eax
cmpl -0x150(%rbp), %eax
je 0x4c52
movl -0x1cc(%rbp), %eax
cmpl -0x150(%rbp), %eax
jne 0x4c89
movslq -0x1c4(%rbp), %rsi
leaq -0x110(%rbp), %rdi
callq 0x5380
movq %rax, %rsi
leaq -0x1c0(%rbp), %rdi
callq 0x55f0
jmp 0x4c76
jmp 0x4cc3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x4fb4
movslq -0x1c4(%rbp), %rsi
leaq -0x110(%rbp), %rdi
callq 0x5380
movq %rax, %rsi
leaq -0x1c0(%rbp), %rdi
callq 0x55f0
jmp 0x4cad
jmp 0x4caf
movl -0x1c4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c4(%rbp)
jmp 0x4bd1
movq -0x8(%rbp), %rdi
movl -0x148(%rbp), %ecx
leaq -0x168(%rbp), %rsi
leaq -0x1c0(%rbp), %rdx
callq 0xd000
movsd %xmm0, -0x358(%rbp)
jmp 0x4cea
movsd -0x358(%rbp), %xmm0
movsd %xmm0, -0x1d8(%rbp)
movsd -0x1d8(%rbp), %xmm0
addsd -0xd8(%rbp), %xmm0
movsd %xmm0, -0xd8(%rbp)
movsd -0xd8(%rbp), %xmm1
movq -0x8(%rbp), %rax
movsd 0x18(%rax), %xmm0
ucomisd %xmm1, %xmm0
jb 0x4d53
movl -0x11c(%rbp), %edx
decl %edx
movl -0x1c4(%rbp), %ecx
incl %ecx
leaq -0x110(%rbp), %rdi
leaq -0x168(%rbp), %rsi
callq 0x8740
jmp 0x4d4e
jmp 0x4f90
movl $0x0, -0x1dc(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x368(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x360(%rbp)
leaq -0x1f8(%rbp), %rdi
leaq -0x138(%rbp), %rsi
callq 0x53c0
jmp 0x4d88
movq -0x360(%rbp), %rsi
movq -0x368(%rbp), %rdi
movq -0x140(%rbp), %r8
movl -0xac(%rbp), %r9d
subq $0x10, %rsp
movq %rsp, %rax
leaq -0xe0(%rbp), %rcx
movq %rcx, 0x8(%rax)
leaq -0x1dc(%rbp), %rcx
movq %rcx, (%rax)
leaq -0x1f8(%rbp), %rdx
leaq -0xf8(%rbp), %rcx
callq 0x10ba0
addq $0x10, %rsp
movb %al, -0x369(%rbp)
jmp 0x4ddf
leaq -0x1f8(%rbp), %rdi
callq 0x54b0
movb -0x369(%rbp), %al
andb $0x1, %al
movb %al, -0x1dd(%rbp)
movb -0x1dd(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x4f69
cmpl $0x1, -0x1dc(%rbp)
jne 0x4e4c
movl $0x1, -0xb4(%rbp)
movl $0x4, -0x144(%rbp)
jmp 0x4f9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x1f8(%rbp), %rdi
callq 0x54b0
jmp 0x4fb4
movl $0x0, -0x1dc(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x380(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x378(%rbp)
leaq -0x218(%rbp), %rdi
leaq -0x138(%rbp), %rsi
callq 0x53c0
jmp 0x4e81
movq -0x378(%rbp), %rsi
movq -0x380(%rbp), %rdi
movq -0x140(%rbp), %r8
movl -0xac(%rbp), %r9d
subq $0x10, %rsp
movq %rsp, %rax
leaq -0xe0(%rbp), %rcx
movq %rcx, 0x8(%rax)
leaq -0x1dc(%rbp), %rcx
movq %rcx, (%rax)
leaq -0x218(%rbp), %rdx
leaq -0xf8(%rbp), %rcx
callq 0x12cd0
addq $0x10, %rsp
movb %al, -0x381(%rbp)
jmp 0x4ed8
leaq -0x218(%rbp), %rdi
callq 0x54b0
movb -0x381(%rbp), %al
andb $0x1, %al
movb %al, -0x1f9(%rbp)
movb -0x1f9(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x4f40
cmpl $0x1, -0x1dc(%rbp)
jne 0x4f34
movl $0x1, -0xb4(%rbp)
jmp 0x4f34
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x218(%rbp), %rdi
callq 0x54b0
jmp 0x4fb4
movl $0x4, -0x144(%rbp)
jmp 0x4f9a
leaq -0x110(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
leaq -0xd8(%rbp), %rdx
leaq -0xe0(%rbp), %rcx
callq 0x88c0
jmp 0x4f63
jmp 0x4f65
jmp 0x4f67
jmp 0x4f8e
leaq -0x110(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
leaq -0xd8(%rbp), %rdx
leaq -0xe0(%rbp), %rcx
callq 0x88c0
jmp 0x4f8c
jmp 0x4f8e
jmp 0x4f90
movl $0x0, -0x144(%rbp)
leaq -0x1c0(%rbp), %rdi
callq 0x54b0
movl -0x144(%rbp), %eax
testl %eax, %eax
jne 0x4fcc
jmp 0x4fb2
jmp 0x4fc2
leaq -0x1c0(%rbp), %rdi
callq 0x54b0
jmp 0x4fe6
movl $0x0, -0x144(%rbp)
leaq -0x168(%rbp), %rdi
callq 0x54b0
movl -0x144(%rbp), %eax
testl %eax, %eax
jne 0x4ffe
jmp 0x4fe4
jmp 0x4ff4
leaq -0x168(%rbp), %rdi
callq 0x54b0
jmp 0x5041
movl $0x0, -0x144(%rbp)
leaq -0x138(%rbp), %rdi
callq 0x54b0
movl -0x144(%rbp), %eax
movl %eax, -0x388(%rbp)
testl %eax, %eax
je 0x502b
jmp 0x501c
movl -0x388(%rbp), %eax
subl $0x4, %eax
je 0x5052
jmp 0x5029
jmp 0x502d
jmp 0x502d
movl -0x11c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x11c(%rbp)
jmp 0x4539
leaq -0x138(%rbp), %rdi
callq 0x54b0
jmp 0x526a
callq 0x2100
movq %rax, -0x220(%rbp)
cmpl $0x1, -0xb4(%rbp)
jne 0x507f
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
movl $0x2, -0x144(%rbp)
jmp 0x51c3
movq -0x2a8(%rbp), %rsi
leaq 0x14003(%rip), %rdx     # 0x19090
leaq -0x280(%rbp), %rdi
callq 0x52a0
jmp 0x509b
leaq -0x260(%rbp), %rdi
leaq -0x280(%rbp), %rsi
leaq -0x48(%rbp), %rdx
callq 0x5560
jmp 0x50b4
leaq 0x14030(%rip), %rdx     # 0x190eb
leaq -0x240(%rbp), %rdi
leaq -0x260(%rbp), %rsi
callq 0x5510
jmp 0x50d0
leaq -0x260(%rbp), %rdi
callq 0x20d0
leaq -0x280(%rbp), %rdi
callq 0x20d0
movl -0xb0(%rbp), %eax
movl %eax, -0x38c(%rbp)
leaq -0x2a0(%rbp), %rdi
leaq -0x240(%rbp), %rsi
callq 0x2090
jmp 0x5109
movl -0x38c(%rbp), %esi
movq -0x2e8(%rbp), %rdi
movq -0x220(%rbp), %rax
movq -0x118(%rbp), %rcx
subq %rcx, %rax
cvtsi2sd %rax, %xmm0
movsd 0x13ed4(%rip), %xmm1    # 0x19008
divsd %xmm1, %xmm0
leaq -0x2a0(%rbp), %rdx
callq 0x8180
jmp 0x5146
leaq -0x2a0(%rbp), %rdi
callq 0x20d0
movq -0x50(%rbp), %rax
movq %rax, -0x398(%rbp)
cmpq $0x0, %rax
je 0x517b
movq -0x398(%rbp), %rdi
callq 0x55b0
movq -0x398(%rbp), %rdi
callq 0x2150
movq -0x68(%rbp), %rax
movq %rax, -0x3a0(%rbp)
cmpq $0x0, %rax
je 0x51a4
movq -0x3a0(%rbp), %rdi
callq 0x55d0
movq -0x3a0(%rbp), %rdi
callq 0x2150
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
leaq -0x240(%rbp), %rdi
callq 0x20d0
movl $0x0, -0x144(%rbp)
leaq -0x110(%rbp), %rdi
callq 0x54b0
leaq -0xf8(%rbp), %rdi
callq 0x54b0
movq -0xc0(%rbp), %rax
movq %rax, %rsp
leaq -0x48(%rbp), %rdi
callq 0x20d0
movl -0x144(%rbp), %eax
testl %eax, %eax
je 0x51ff
jmp 0x51fa
jmp 0x4372
jmp 0x4372
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x522a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x260(%rbp), %rdi
callq 0x20d0
leaq -0x280(%rbp), %rdi
callq 0x20d0
jmp 0x526a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x525e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x2a0(%rbp), %rdi
callq 0x20d0
leaq -0x240(%rbp), %rdi
callq 0x20d0
leaq -0x110(%rbp), %rdi
callq 0x54b0
leaq -0xf8(%rbp), %rdi
callq 0x54b0
leaq -0x48(%rbp), %rdi
callq 0x20d0
jmp 0x5292
movq %rbp, %rsp
popq %rbp
retq
movq -0x58(%rbp), %rdi
callq 0x2240
nopl (%rax,%rax)