// File: AraKhachatryan[P]GraphAlgo/main.cpp
// Function: main
int main()
{
	// Printing a headline in terminal, used namespace termianl for text colors
	std::cout << std::endl;
	std::cout << "~~~~~~~~~~~~~~~ "
			  << terminal::TEXT_BOLD << terminal::TEXTCOLOR_BLUE
			  << "GraphAlgo: Algorithms library for planar graphs."
			  << terminal::RESET_ALL
			  << "~~~~~~~~~~~~~~~" << std::endl;
	
	// Initialize an empty graph object
	GraphAlgo::graph g;

	// Build a graph via adding edges
	g.add_edge(1, 2);
	g.add_edge(1, 4);	
	g.add_edge(2, 4);
	g.add_edge(2, 5);
	g.add_edge(3, 4);
	g.add_edge(3, 6);
	g.add_edge(3, 12);
	g.add_edge(3, 13);
	g.add_edge(4, 6);
	g.add_edge(4, 7);
	g.add_edge(5, 7);
	g.add_edge(6, 11);
	g.add_edge(6, 12);
	g.add_edge(7, 10);
	g.add_edge(7, 11);
	g.add_edge(8, 10);
	g.add_edge(8, 16);
	g.add_edge(9, 10);
	g.add_edge(9, 11);
	g.add_edge(9, 15);
	g.add_edge(10, 16);
	g.add_edge(11, 14);
	g.add_edge(12, 13);
	g.add_edge(14, 15);
	g.add_edge(15, 16);
	
	
	// Drawing a graph on terminal for visualisation
	draw_graph( graph_data );
	
	
	std::cout << "Printing graph as adjacency-list:" << std::endl;
	g.print_neighborhood();
	
	std::this_thread::sleep_for(std::chrono::milliseconds(4000));  // sleep
	
	
	
	
	std::cout << std::endl << std::endl;
	std::cout << "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ DFS Algorithm ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~";
	std::cout << std::endl << std::endl;
	
	// making dfs object and starting the algorithm from vertex 1 in graph g
	GraphAlgo::dfs depth_first(g, 1);
	
	GraphAlgo::graph g_out_dfs;
	g_out_dfs = depth_first();
	
	
	std::cout << "Executing DFS algorithm on initial graph with start vertex 1" << std::endl;
	// Drawing a graph on terminal for DFS Algorithm visualisation
	draw_graph( graph_data_dfs );	
	
	
	std::cout << "Print DFS algorithm output as adjacency-list:" << std::endl;
	g_out_dfs.print_neighborhood();
	
	std::this_thread::sleep_for(std::chrono::milliseconds(4000));  // sleep
	
	
	
	
	std::cout << std::endl << std::endl;
	std::cout << "~~~~~~~~~~~~~~~~~~~~~~~~~~~ Connectivity Algorithm ~~~~~~~~~~~~~~~~~~~~~~~~~~~~";
	std::cout << std::endl << std::endl;
	
	GraphAlgo::graph g_con = g;   // copy intitial graph		
	g_con.remove_vertex(7);       // remove vertex for disconecting a graph
	g_con.remove_edge(6, 11);     // remove edge for disconecting a graph
	
	std::cout << "Vertex 7 and edge (6, 11) removed from initial graph.";
	std::cout << std::endl;
//	g_con.print_neighborhood();
	
	
	// Drawing a graph on terminal for Connectivity visualisation
	draw_graph( graph_data_connectivity );	
	
	
	// making connectivity object and starting the algorithm
	GraphAlgo::connectivity con(g_con);
	
	if( !con.is_connected() )
	{
		std::cout << "Graph is not connected." << std::endl;
	} else {
		std::cout << "Graph not connected." << std::endl;
	}
	
	GraphAlgo::graphs con_out;
	con_out = con();
	
	std::cout << "Printing disconected graph's conected components:";
	std::cout << std::endl;
	
	GraphAlgo::graphs::const_iterator c_it = con_out.begin();
	for( ; c_it != con_out.end(); ++c_it) 
	{	
		std::cout << "+++++++++++++++++++++++" << std::endl;
		c_it->print_neighborhood();
	}
	
	std::this_thread::sleep_for(std::chrono::milliseconds(4000));  // sleep
	
	
	
	
	std::cout << std::endl << std::endl;
	std::cout << "~~~~~~~~~~~~~~~~~~~~~~~~~~ BiConnectivity Algorithm ~~~~~~~~~~~~~~~~~~~~~~~~~~~";
	std::cout << std::endl << std::endl;
	 
	GraphAlgo::graph g_bicon = g;  // copy intitial graph
	g_bicon.remove_edge(6, 11);    // for making graph not biconected
	
	std::cout << "From initial graph is removed edge(6, 11)." << std::endl;
//	g_bicon.print_neighborhood();
	
	
	// Drawing a graph on terminal for BiConnectivity visualisation
	draw_graph( graph_data_biconnectivity );	
	
	
	// making biconnectivity object and starting the algorithm
	GraphAlgo::biconnectivity bicon( g_bicon );
	
	if ( !bicon.is_biconnected() ) 
	{
		std::cout << "Graph is not bicoconnected." << std::endl;
		// Print cutvertices
		bicon.print_cutvertices();
	} else {
		std::cout << "Graph is bicoconnected." << std::endl;
	}
	
	GraphAlgo::graphs bicon_out;
	bicon_out = bicon();
	
	std::cout << "Printing graph's biconected components:" << std::endl;
	GraphAlgo::graphs::const_iterator b_it = bicon_out.begin();
	for( ; b_it != bicon_out.end(); ++b_it) 
	{
		std::cout << "+++++++++++++++++++++++" << std::endl;
		b_it->print_neighborhood();
	}
	
	std::this_thread::sleep_for(std::chrono::milliseconds(4000));  // sleep
	
	
	
	
	std::cout << std::endl << std::endl;
	std::cout << "~~~~~~~~~~~~~~~~~~~~~~~~~~~ Dijkstra's Algorithm ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~";
	std::cout << std::endl << std::endl;
	
	// making dijkstra object from initial graph g
	GraphAlgo::dijkstra dijk(g);
	
	// 
	dijk.set_edge_weight(1, 2, 1);
	dijk.set_edge_weight(1, 4, 5);	
	dijk.set_edge_weight(2, 4, 3);
	dijk.set_edge_weight(2, 5, 2);
	dijk.set_edge_weight(3, 4, 4);
	dijk.set_edge_weight(3, 6, 2);
	dijk.set_edge_weight(3, 12, 3);
	dijk.set_edge_weight(3, 13, 1);
	dijk.set_edge_weight(4, 6, 6);
	dijk.set_edge_weight(4, 7, 3);
	dijk.set_edge_weight(5, 7, 1);
	dijk.set_edge_weight(6, 11, 5);
	dijk.set_edge_weight(6, 12, 1);
	dijk.set_edge_weight(7, 10, 2);
	dijk.set_edge_weight(7, 11, 9);
	dijk.set_edge_weight(8, 10, 1);
	dijk.set_edge_weight(8, 16, 1);
	dijk.set_edge_weight(9, 10, 3);
	dijk.set_edge_weight(9, 11, 4);
	dijk.set_edge_weight(9, 15, 2);
	dijk.set_edge_weight(10, 16, 3);
	dijk.set_edge_weight(11, 14, 1);
	dijk.set_edge_weight(12, 13, 2);
	dijk.set_edge_weight(14, 15, 1);
	dijk.set_edge_weight(15, 16, 2);
	
	
	// Drawing a graph on terminal for Dijkstra's Algorithm visualisation
	draw_graph( graph_data_dijkstra);	
	

	dijk.shortest_paths_from(1);
	dijk.get_shortest_path_to(14);
	dijk.print_path();
	std::cout << std::endl;
	
	// another shortest path: from 1 to 9
	dijk.get_shortest_path_to(9);
	dijk.print_path();
	std::cout << std::endl;

	// another shortest path: from 13 to 8
	dijk.shortest_paths_from(13);
	dijk.get_shortest_path_to(8);
	dijk.print_path();


	std::cout << std::endl << std::endl;
	std::cout << "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ END ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~";
	std::cout << std::endl << std::endl;
	
	
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa70, %rsp            # imm = 0xA70
movl $0x0, -0x4(%rbp)
movq 0x13abf(%rip), %rdi     # 0x2ffd8
movq %rdi, -0x9a0(%rbp)
movq 0x13aa1(%rip), %rsi     # 0x2ffc8
movq %rsi, -0x998(%rbp)
callq 0x21e0
movq -0x9a0(%rbp), %rdi
leaq 0x3fff(%rip), %rsi      # 0x20540
callq 0x21a0
movq %rax, %rdi
movl $0x1, %esi
callq 0x1dc00
movq %rax, %rdi
movl $0x22, %esi
callq 0x1dc00
movq %rax, %rdi
leaq 0x3fe7(%rip), %rsi      # 0x20551
callq 0x21a0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1dc00
movq %rax, %rdi
leaq 0x4219(%rip), %rsi      # 0x2079c
callq 0x21a0
movq -0x998(%rbp), %rsi
movq %rax, %rdi
callq 0x21e0
leaq -0x68(%rbp), %rdi
movq %rdi, -0x990(%rbp)
callq 0x16d80
movq -0x990(%rbp), %rdi
movl $0x1, -0x6c(%rbp)
movl $0x2, -0x70(%rbp)
leaq -0x6c(%rbp), %rsi
leaq -0x70(%rbp), %rdx
callq 0x16290
jmp 0x1c5cb
movl $0x1, -0x80(%rbp)
movl $0x4, -0x84(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x80(%rbp), %rsi
leaq -0x84(%rbp), %rdx
callq 0x16290
jmp 0x1c5f2
movl $0x2, -0x88(%rbp)
movl $0x4, -0x8c(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x88(%rbp), %rsi
leaq -0x8c(%rbp), %rdx
callq 0x16290
jmp 0x1c61f
movl $0x2, -0x90(%rbp)
movl $0x5, -0x94(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x90(%rbp), %rsi
leaq -0x94(%rbp), %rdx
callq 0x16290
jmp 0x1c64c
movl $0x3, -0x98(%rbp)
movl $0x4, -0x9c(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x98(%rbp), %rsi
leaq -0x9c(%rbp), %rdx
callq 0x16290
jmp 0x1c679
movl $0x3, -0xa0(%rbp)
movl $0x6, -0xa4(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
leaq -0xa4(%rbp), %rdx
callq 0x16290
jmp 0x1c6a6
movl $0x3, -0xa8(%rbp)
movl $0xc, -0xac(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
leaq -0xac(%rbp), %rdx
callq 0x16290
jmp 0x1c6d3
movl $0x3, -0xb0(%rbp)
movl $0xd, -0xb4(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
leaq -0xb4(%rbp), %rdx
callq 0x16290
jmp 0x1c700
movl $0x4, -0xb8(%rbp)
movl $0x6, -0xbc(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
leaq -0xbc(%rbp), %rdx
callq 0x16290
jmp 0x1c72d
movl $0x4, -0xc0(%rbp)
movl $0x7, -0xc4(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
leaq -0xc4(%rbp), %rdx
callq 0x16290
jmp 0x1c75a
movl $0x5, -0xc8(%rbp)
movl $0x7, -0xcc(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xc8(%rbp), %rsi
leaq -0xcc(%rbp), %rdx
callq 0x16290
jmp 0x1c787
movl $0x6, -0xd0(%rbp)
movl $0xb, -0xd4(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
leaq -0xd4(%rbp), %rdx
callq 0x16290
jmp 0x1c7b4
movl $0x6, -0xd8(%rbp)
movl $0xc, -0xdc(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
leaq -0xdc(%rbp), %rdx
callq 0x16290
jmp 0x1c7e1
movl $0x7, -0xe0(%rbp)
movl $0xa, -0xe4(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xe0(%rbp), %rsi
leaq -0xe4(%rbp), %rdx
callq 0x16290
jmp 0x1c80e
movl $0x7, -0xe8(%rbp)
movl $0xb, -0xec(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
leaq -0xec(%rbp), %rdx
callq 0x16290
jmp 0x1c83b
movl $0x8, -0xf0(%rbp)
movl $0xa, -0xf4(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xf0(%rbp), %rsi
leaq -0xf4(%rbp), %rdx
callq 0x16290
jmp 0x1c868
movl $0x8, -0xf8(%rbp)
movl $0x10, -0xfc(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
leaq -0xfc(%rbp), %rdx
callq 0x16290
jmp 0x1c895
movl $0x9, -0x100(%rbp)
movl $0xa, -0x104(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x100(%rbp), %rsi
leaq -0x104(%rbp), %rdx
callq 0x16290
jmp 0x1c8c2
movl $0x9, -0x108(%rbp)
movl $0xb, -0x10c(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x108(%rbp), %rsi
leaq -0x10c(%rbp), %rdx
callq 0x16290
jmp 0x1c8ef
movl $0x9, -0x110(%rbp)
movl $0xf, -0x114(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x110(%rbp), %rsi
leaq -0x114(%rbp), %rdx
callq 0x16290
jmp 0x1c91c
movl $0xa, -0x118(%rbp)
movl $0x10, -0x11c(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x118(%rbp), %rsi
leaq -0x11c(%rbp), %rdx
callq 0x16290
jmp 0x1c949
movl $0xb, -0x120(%rbp)
movl $0xe, -0x124(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x124(%rbp), %rdx
callq 0x16290
jmp 0x1c976
movl $0xc, -0x128(%rbp)
movl $0xd, -0x12c(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x128(%rbp), %rsi
leaq -0x12c(%rbp), %rdx
callq 0x16290
jmp 0x1c9a3
movl $0xe, -0x130(%rbp)
movl $0xf, -0x134(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x130(%rbp), %rsi
leaq -0x134(%rbp), %rdx
callq 0x16290
jmp 0x1c9d0
movl $0xf, -0x138(%rbp)
movl $0x10, -0x13c(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x138(%rbp), %rsi
leaq -0x13c(%rbp), %rdx
callq 0x16290
jmp 0x1c9fd
leaq 0x1379c(%rip), %rdi     # 0x301a0
callq 0x1dae0
jmp 0x1ca0b
movq 0x135c6(%rip), %rdi     # 0x2ffd8
leaq 0x3b69(%rip), %rsi      # 0x20582
callq 0x21a0
movq %rax, -0x9a8(%rbp)
jmp 0x1ca27
movq -0x9a8(%rbp), %rdi
movq 0x13593(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1ca3c
leaq -0x68(%rbp), %rdi
callq 0x16ef0
jmp 0x1ca47
movl $0xfa0, -0x14c(%rbp)    # imm = 0xFA0
leaq -0x148(%rbp), %rdi
leaq -0x14c(%rbp), %rsi
callq 0x1dcf0
jmp 0x1ca66
leaq -0x148(%rbp), %rdi
callq 0x1dc40
jmp 0x1ca74
movq 0x1355d(%rip), %rdi     # 0x2ffd8
movq 0x13546(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0x9b0(%rbp)
jmp 0x1ca90
movq -0x9b0(%rbp), %rdi
movq 0x1352a(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1caa5
movq 0x1352c(%rip), %rdi     # 0x2ffd8
leaq 0x3af1(%rip), %rsi      # 0x205a4
callq 0x21a0
jmp 0x1caba
movq 0x13517(%rip), %rdi     # 0x2ffd8
movq 0x13500(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0x9b8(%rbp)
jmp 0x1cad6
movq -0x9b8(%rbp), %rdi
movq 0x134e4(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1caeb
movl $0x1, -0x28c(%rbp)
leaq -0x288(%rbp), %rdi
leaq -0x68(%rbp), %rsi
leaq -0x28c(%rbp), %rdx
callq 0xcef0
jmp 0x1cb0e
leaq -0x2f0(%rbp), %rdi
callq 0x16d80
jmp 0x1cb1c
leaq -0x288(%rbp), %rdi
callq 0xcd70
movq %rax, -0x9c0(%rbp)
jmp 0x1cb31
movq -0x9c0(%rbp), %rsi
leaq -0x2f0(%rbp), %rdi
callq 0x16e00
jmp 0x1cb46
movq 0x1348b(%rip), %rdi     # 0x2ffd8
leaq 0x3aa0(%rip), %rsi      # 0x205f4
callq 0x21a0
movq %rax, -0x9c8(%rbp)
jmp 0x1cb62
movq -0x9c8(%rbp), %rdi
movq 0x13458(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cb77
leaq 0x1363a(%rip), %rdi     # 0x301b8
callq 0x1dae0
jmp 0x1cb85
movq 0x1344c(%rip), %rdi     # 0x2ffd8
leaq 0x3a9e(%rip), %rsi      # 0x20631
callq 0x21a0
movq %rax, -0x9d0(%rbp)
jmp 0x1cba1
movq -0x9d0(%rbp), %rdi
movq 0x13419(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cbb6
leaq -0x2f0(%rbp), %rdi
callq 0x16ef0
jmp 0x1cbc4
movl $0xfa0, -0x2fc(%rbp)    # imm = 0xFA0
leaq -0x2f8(%rbp), %rdi
leaq -0x2fc(%rbp), %rsi
callq 0x1dcf0
jmp 0x1cbe3
leaq -0x2f8(%rbp), %rdi
callq 0x1dc40
jmp 0x1cbf1
movq 0x133e0(%rip), %rdi     # 0x2ffd8
movq 0x133c9(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0x9d8(%rbp)
jmp 0x1cc0d
movq -0x9d8(%rbp), %rdi
movq 0x133ad(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cc22
movq 0x133af(%rip), %rdi     # 0x2ffd8
leaq 0x3a2f(%rip), %rsi      # 0x2065f
callq 0x21a0
jmp 0x1cc37
movq 0x1339a(%rip), %rdi     # 0x2ffd8
movq 0x13383(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0x9e0(%rbp)
jmp 0x1cc53
movq -0x9e0(%rbp), %rdi
movq 0x13367(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cc68
leaq -0x360(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x16c30
jmp 0x1cc7a
leaq -0x360(%rbp), %rdi
movl $0x7, %esi
callq 0x15970
jmp 0x1cc8d
leaq -0x360(%rbp), %rdi
movl $0x6, %esi
movl $0xb, %edx
callq 0x15a80
jmp 0x1cca5
movq 0x1332c(%rip), %rdi     # 0x2ffd8
leaq 0x39fc(%rip), %rsi      # 0x206af
callq 0x21a0
jmp 0x1ccba
movq 0x13317(%rip), %rdi     # 0x2ffd8
movq 0x13300(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cccf
leaq 0x134fa(%rip), %rdi     # 0x301d0
callq 0x1dae0
jmp 0x1ccdd
leaq -0x408(%rbp), %rdi
leaq -0x360(%rbp), %rsi
callq 0xc400
jmp 0x1ccf2
leaq -0x408(%rbp), %rdi
callq 0xc370
movb %al, -0x9e1(%rbp)
jmp 0x1cd06
movb -0x9e1(%rbp), %al
testb $0x1, %al
jne 0x1cda1
jmp 0x1cd16
movq 0x132bb(%rip), %rdi     # 0x2ffd8
leaq 0x39c1(%rip), %rsi      # 0x206e5
callq 0x21a0
movq %rax, -0x9f0(%rbp)
jmp 0x1cd32
movq -0x9f0(%rbp), %rdi
movq 0x13288(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cd47
jmp 0x1cdd4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1dac8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1dabc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1dab0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1daa4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1da98
movq 0x13230(%rip), %rdi     # 0x2ffd8
leaq 0x394e(%rip), %rsi      # 0x206fd
callq 0x21a0
movq %rax, -0x9f8(%rbp)
jmp 0x1cdbd
movq -0x9f8(%rbp), %rdi
movq 0x131fd(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cdd2
jmp 0x1cdd4
leaq -0x420(%rbp), %rdi
callq 0x63a0
leaq -0x408(%rbp), %rdi
callq 0xc4d0
movq %rax, -0xa00(%rbp)
jmp 0x1cdf5
movq -0xa00(%rbp), %rsi
leaq -0x420(%rbp), %rdi
callq 0x1dd10
jmp 0x1ce0a
movq 0x131c7(%rip), %rdi     # 0x2ffd8
leaq 0x38fa(%rip), %rsi      # 0x20712
callq 0x21a0
jmp 0x1ce1f
movq 0x131b2(%rip), %rdi     # 0x2ffd8
movq 0x1319b(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1ce34
leaq -0x420(%rbp), %rdi
callq 0x80e0
movq %rax, -0x430(%rbp)
leaq -0x428(%rbp), %rdi
leaq -0x430(%rbp), %rsi
callq 0x1df60
leaq -0x420(%rbp), %rdi
callq 0x7f50
movq %rax, -0x438(%rbp)
leaq -0x428(%rbp), %rdi
leaq -0x438(%rbp), %rsi
callq 0x1dfa0
testb $0x1, %al
jne 0x1ce86
jmp 0x1cef1
movq 0x1314b(%rip), %rdi     # 0x2ffd8
leaq 0x38b0(%rip), %rsi      # 0x20744
callq 0x21a0
movq %rax, -0xa08(%rbp)
jmp 0x1cea2
movq -0xa08(%rbp), %rdi
movq 0x13118(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1ceb7
leaq -0x428(%rbp), %rdi
callq 0x1dfe0
movq %rax, %rdi
callq 0x16ef0
jmp 0x1cecd
jmp 0x1cecf
leaq -0x428(%rbp), %rdi
callq 0x1e000
jmp 0x1ce5a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1da8c
movl $0xfa0, -0x444(%rbp)    # imm = 0xFA0
leaq -0x440(%rbp), %rdi
leaq -0x444(%rbp), %rsi
callq 0x1dcf0
jmp 0x1cf10
leaq -0x440(%rbp), %rdi
callq 0x1dc40
jmp 0x1cf1e
movq 0x130b3(%rip), %rdi     # 0x2ffd8
movq 0x1309c(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0xa10(%rbp)
jmp 0x1cf3a
movq -0xa10(%rbp), %rdi
movq 0x13080(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cf4f
movq 0x13082(%rip), %rdi     # 0x2ffd8
leaq 0x37ff(%rip), %rsi      # 0x2075c
callq 0x21a0
jmp 0x1cf64
movq 0x1306d(%rip), %rdi     # 0x2ffd8
movq 0x13056(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0xa18(%rbp)
jmp 0x1cf80
movq -0xa18(%rbp), %rdi
movq 0x1303a(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cf95
leaq -0x4a8(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x16c30
jmp 0x1cfa7
leaq -0x4a8(%rbp), %rdi
movl $0x6, %esi
movl $0xb, %edx
callq 0x15a80
jmp 0x1cfbf
movq 0x13012(%rip), %rdi     # 0x2ffd8
leaq 0x37df(%rip), %rsi      # 0x207ac
callq 0x21a0
movq %rax, -0xa20(%rbp)
jmp 0x1cfdb
movq -0xa20(%rbp), %rdi
movq 0x12fdf(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1cff0
leaq 0x131f1(%rip), %rdi     # 0x301e8
callq 0x1dae0
jmp 0x1cffe
leaq -0x680(%rbp), %rdi
leaq -0x4a8(%rbp), %rsi
callq 0x59f0
jmp 0x1d013
leaq -0x680(%rbp), %rdi
callq 0x5170
movb %al, -0xa21(%rbp)
jmp 0x1d027
movb -0xa21(%rbp), %al
testb $0x1, %al
jne 0x1d096
jmp 0x1d033
movq 0x12f9e(%rip), %rdi     # 0x2ffd8
leaq 0x3796(%rip), %rsi      # 0x207d7
callq 0x21a0
movq %rax, -0xa30(%rbp)
jmp 0x1d04f
movq -0xa30(%rbp), %rdi
movq 0x12f6b(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d064
leaq -0x680(%rbp), %rdi
callq 0x51b0
jmp 0x1d072
jmp 0x1d0c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1da80
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1da74
movq 0x12f3b(%rip), %rdi     # 0x2ffd8
leaq 0x374f(%rip), %rsi      # 0x207f3
callq 0x21a0
movq %rax, -0xa38(%rbp)
jmp 0x1d0b2
movq -0xa38(%rbp), %rdi
movq 0x12f08(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d0c7
jmp 0x1d0c9
leaq -0x698(%rbp), %rdi
callq 0x63a0
leaq -0x680(%rbp), %rdi
callq 0x5ca0
movq %rax, -0xa40(%rbp)
jmp 0x1d0ea
movq -0xa40(%rbp), %rsi
leaq -0x698(%rbp), %rdi
callq 0x1dd10
jmp 0x1d0ff
movq 0x12ed2(%rip), %rdi     # 0x2ffd8
leaq 0x36fe(%rip), %rsi      # 0x2080b
callq 0x21a0
movq %rax, -0xa48(%rbp)
jmp 0x1d11b
movq -0xa48(%rbp), %rdi
movq 0x12e9f(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d130
leaq -0x698(%rbp), %rdi
callq 0x80e0
movq %rax, -0x6a8(%rbp)
leaq -0x6a0(%rbp), %rdi
leaq -0x6a8(%rbp), %rsi
callq 0x1df60
leaq -0x698(%rbp), %rdi
callq 0x7f50
movq %rax, -0x6b0(%rbp)
leaq -0x6a0(%rbp), %rdi
leaq -0x6b0(%rbp), %rsi
callq 0x1dfa0
testb $0x1, %al
jne 0x1d182
jmp 0x1d1ed
movq 0x12e4f(%rip), %rdi     # 0x2ffd8
leaq 0x35b4(%rip), %rsi      # 0x20744
callq 0x21a0
movq %rax, -0xa50(%rbp)
jmp 0x1d19e
movq -0xa50(%rbp), %rdi
movq 0x12e1c(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d1b3
leaq -0x6a0(%rbp), %rdi
callq 0x1dfe0
movq %rax, %rdi
callq 0x16ef0
jmp 0x1d1c9
jmp 0x1d1cb
leaq -0x6a0(%rbp), %rdi
callq 0x1e000
jmp 0x1d156
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x1da68
movl $0xfa0, -0x6bc(%rbp)    # imm = 0xFA0
leaq -0x6b8(%rbp), %rdi
leaq -0x6bc(%rbp), %rsi
callq 0x1dcf0
jmp 0x1d20c
leaq -0x6b8(%rbp), %rdi
callq 0x1dc40
jmp 0x1d21a
movq 0x12db7(%rip), %rdi     # 0x2ffd8
movq 0x12da0(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0xa58(%rbp)
jmp 0x1d236
movq -0xa58(%rbp), %rdi
movq 0x12d84(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d24b
movq 0x12d86(%rip), %rdi     # 0x2ffd8
leaq 0x35da(%rip), %rsi      # 0x20833
callq 0x21a0
jmp 0x1d260
movq 0x12d71(%rip), %rdi     # 0x2ffd8
movq 0x12d5a(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0xa60(%rbp)
jmp 0x1d27c
movq -0xa60(%rbp), %rdi
movq 0x12d3e(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d291
leaq -0x858(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0xf7f0
jmp 0x1d2a3
movl $0x1, -0x85c(%rbp)
movl $0x2, -0x860(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x85c(%rbp), %rsi
leaq -0x860(%rbp), %rdx
movsd 0x3234(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d2db
movl $0x1, -0x864(%rbp)
movl $0x4, -0x868(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x864(%rbp), %rsi
leaq -0x868(%rbp), %rdx
movsd 0x3204(%rip), %xmm0     # 0x20510
callq 0xed20
jmp 0x1d313
movl $0x2, -0x86c(%rbp)
movl $0x4, -0x870(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x86c(%rbp), %rsi
leaq -0x870(%rbp), %rdx
movsd 0x31d4(%rip), %xmm0     # 0x20518
callq 0xed20
jmp 0x1d34b
movl $0x2, -0x874(%rbp)
movl $0x5, -0x878(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x874(%rbp), %rsi
leaq -0x878(%rbp), %rdx
movsd 0x31a4(%rip), %xmm0     # 0x20520
callq 0xed20
jmp 0x1d383
movl $0x3, -0x87c(%rbp)
movl $0x4, -0x880(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x87c(%rbp), %rsi
leaq -0x880(%rbp), %rdx
movsd 0x3174(%rip), %xmm0     # 0x20528
callq 0xed20
jmp 0x1d3bb
movl $0x3, -0x884(%rbp)
movl $0x6, -0x888(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x884(%rbp), %rsi
leaq -0x888(%rbp), %rdx
movsd 0x3134(%rip), %xmm0     # 0x20520
callq 0xed20
jmp 0x1d3f3
movl $0x3, -0x88c(%rbp)
movl $0xc, -0x890(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x88c(%rbp), %rsi
leaq -0x890(%rbp), %rdx
movsd 0x30f4(%rip), %xmm0     # 0x20518
callq 0xed20
jmp 0x1d42b
movl $0x3, -0x894(%rbp)
movl $0xd, -0x898(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x894(%rbp), %rsi
leaq -0x898(%rbp), %rdx
movsd 0x30ac(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d463
movl $0x4, -0x89c(%rbp)
movl $0x6, -0x8a0(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x89c(%rbp), %rsi
leaq -0x8a0(%rbp), %rdx
movsd 0x309c(%rip), %xmm0     # 0x20530
callq 0xed20
jmp 0x1d49b
movl $0x4, -0x8a4(%rbp)
movl $0x7, -0x8a8(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8a4(%rbp), %rsi
leaq -0x8a8(%rbp), %rdx
movsd 0x304c(%rip), %xmm0     # 0x20518
callq 0xed20
jmp 0x1d4d3
movl $0x5, -0x8ac(%rbp)
movl $0x7, -0x8b0(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8ac(%rbp), %rsi
leaq -0x8b0(%rbp), %rdx
movsd 0x3004(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d50b
movl $0x6, -0x8b4(%rbp)
movl $0xb, -0x8b8(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8b4(%rbp), %rsi
leaq -0x8b8(%rbp), %rdx
movsd 0x2fd4(%rip), %xmm0     # 0x20510
callq 0xed20
jmp 0x1d543
movl $0x6, -0x8bc(%rbp)
movl $0xc, -0x8c0(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8bc(%rbp), %rsi
leaq -0x8c0(%rbp), %rdx
movsd 0x2f94(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d57b
movl $0x7, -0x8c4(%rbp)
movl $0xa, -0x8c8(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8c4(%rbp), %rsi
leaq -0x8c8(%rbp), %rdx
movsd 0x2f74(%rip), %xmm0     # 0x20520
callq 0xed20
jmp 0x1d5b3
movl $0x7, -0x8cc(%rbp)
movl $0xb, -0x8d0(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8cc(%rbp), %rsi
leaq -0x8d0(%rbp), %rdx
movsd 0x2f54(%rip), %xmm0     # 0x20538
callq 0xed20
jmp 0x1d5eb
movl $0x8, -0x8d4(%rbp)
movl $0xa, -0x8d8(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8d4(%rbp), %rsi
leaq -0x8d8(%rbp), %rdx
movsd 0x2eec(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d623
movl $0x8, -0x8dc(%rbp)
movl $0x10, -0x8e0(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8dc(%rbp), %rsi
leaq -0x8e0(%rbp), %rdx
movsd 0x2eb4(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d65b
movl $0x9, -0x8e4(%rbp)
movl $0xa, -0x8e8(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8e4(%rbp), %rsi
leaq -0x8e8(%rbp), %rdx
movsd 0x2e8c(%rip), %xmm0     # 0x20518
callq 0xed20
jmp 0x1d693
movl $0x9, -0x8ec(%rbp)
movl $0xb, -0x8f0(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8ec(%rbp), %rsi
leaq -0x8f0(%rbp), %rdx
movsd 0x2e64(%rip), %xmm0     # 0x20528
callq 0xed20
jmp 0x1d6cb
movl $0x9, -0x8f4(%rbp)
movl $0xf, -0x8f8(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8f4(%rbp), %rsi
leaq -0x8f8(%rbp), %rdx
movsd 0x2e24(%rip), %xmm0     # 0x20520
callq 0xed20
jmp 0x1d703
movl $0xa, -0x8fc(%rbp)
movl $0x10, -0x900(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x8fc(%rbp), %rsi
leaq -0x900(%rbp), %rdx
movsd 0x2de4(%rip), %xmm0     # 0x20518
callq 0xed20
jmp 0x1d73b
movl $0xb, -0x904(%rbp)
movl $0xe, -0x908(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x904(%rbp), %rsi
leaq -0x908(%rbp), %rdx
movsd 0x2d9c(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d773
movl $0xc, -0x90c(%rbp)
movl $0xd, -0x910(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x90c(%rbp), %rsi
leaq -0x910(%rbp), %rdx
movsd 0x2d7c(%rip), %xmm0     # 0x20520
callq 0xed20
jmp 0x1d7ab
movl $0xe, -0x914(%rbp)
movl $0xf, -0x918(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x914(%rbp), %rsi
leaq -0x918(%rbp), %rdx
movsd 0x2d2c(%rip), %xmm0     # 0x20508
callq 0xed20
jmp 0x1d7e3
movl $0xf, -0x91c(%rbp)
movl $0x10, -0x920(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x91c(%rbp), %rsi
leaq -0x920(%rbp), %rdx
movsd 0x2d0c(%rip), %xmm0     # 0x20520
callq 0xed20
jmp 0x1d81b
leaq 0x129de(%rip), %rdi     # 0x30200
callq 0x1dae0
jmp 0x1d829
movl $0x1, -0x924(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x924(%rbp), %rsi
callq 0xf6d0
jmp 0x1d848
movl $0xe, -0x944(%rbp)
leaq -0x940(%rbp), %rdi
leaq -0x858(%rbp), %rsi
leaq -0x944(%rbp), %rdx
callq 0xec20
jmp 0x1d86e
leaq -0x940(%rbp), %rdi
callq 0x10810
leaq -0x858(%rbp), %rdi
callq 0xe9c0
jmp 0x1d888
movq 0x12749(%rip), %rdi     # 0x2ffd8
movq 0x12732(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d89d
movl $0x9, -0x964(%rbp)
leaq -0x960(%rbp), %rdi
leaq -0x858(%rbp), %rsi
leaq -0x964(%rbp), %rdx
callq 0xec20
jmp 0x1d8c3
leaq -0x960(%rbp), %rdi
callq 0x10810
leaq -0x858(%rbp), %rdi
callq 0xe9c0
jmp 0x1d8dd
movq 0x126f4(%rip), %rdi     # 0x2ffd8
movq 0x126dd(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d8f2
movl $0xd, -0x968(%rbp)
leaq -0x858(%rbp), %rdi
leaq -0x968(%rbp), %rsi
callq 0xf6d0
jmp 0x1d911
movl $0x8, -0x984(%rbp)
leaq -0x980(%rbp), %rdi
leaq -0x858(%rbp), %rsi
leaq -0x984(%rbp), %rdx
callq 0xec20
jmp 0x1d937
leaq -0x980(%rbp), %rdi
callq 0x10810
leaq -0x858(%rbp), %rdi
callq 0xe9c0
jmp 0x1d951
movq 0x12680(%rip), %rdi     # 0x2ffd8
movq 0x12669(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0xa68(%rbp)
jmp 0x1d96d
movq -0xa68(%rbp), %rdi
movq 0x1264d(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d982
movq 0x1264f(%rip), %rdi     # 0x2ffd8
leaq 0x2ef3(%rip), %rsi      # 0x20883
callq 0x21a0
jmp 0x1d997
movq 0x1263a(%rip), %rdi     # 0x2ffd8
movq 0x12623(%rip), %rsi     # 0x2ffc8
callq 0x21e0
movq %rax, -0xa70(%rbp)
jmp 0x1d9b3
movq -0xa70(%rbp), %rdi
movq 0x12607(%rip), %rsi     # 0x2ffc8
callq 0x21e0
jmp 0x1d9c8
movl $0x0, -0x4(%rbp)
leaq -0x858(%rbp), %rdi
callq 0xfa30
leaq -0x698(%rbp), %rdi
callq 0x6520
leaq -0x680(%rbp), %rdi
callq 0x5c00
leaq -0x4a8(%rbp), %rdi
callq 0x16dc0
leaq -0x420(%rbp), %rdi
callq 0x6520
leaq -0x408(%rbp), %rdi
callq 0xc490
leaq -0x360(%rbp), %rdi
callq 0x16dc0
leaq -0x2f0(%rbp), %rdi
callq 0x16dc0
leaq -0x288(%rbp), %rdi
callq 0xd190
leaq -0x68(%rbp), %rdi
callq 0x16dc0
movl -0x4(%rbp), %eax
addq $0xa70, %rsp            # imm = 0xA70
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x858(%rbp), %rdi
callq 0xfa30
leaq -0x698(%rbp), %rdi
callq 0x6520
leaq -0x680(%rbp), %rdi
callq 0x5c00
leaq -0x4a8(%rbp), %rdi
callq 0x16dc0
leaq -0x420(%rbp), %rdi
callq 0x6520
leaq -0x408(%rbp), %rdi
callq 0xc490
leaq -0x360(%rbp), %rdi
callq 0x16dc0
leaq -0x2f0(%rbp), %rdi
callq 0x16dc0
leaq -0x288(%rbp), %rdi
callq 0xd190
leaq -0x68(%rbp), %rdi
callq 0x16dc0
movq -0x78(%rbp), %rdi
callq 0x22b0
nopw (%rax,%rax)