// File: /workspace/github_cpp_makefile_star2_O2/fjamour[P]icentral/src/main.cc
// Function: do_paper_exp(int, int, double, int, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>, bool, bool, bool, bool)
void do_paper_exp(int num_edges,
        int num_iter,
        double max_time,
        int rand_seed,
        vector<string> path_vec,
        bool do_inc_brandes,
        bool do_qube,
        bool do_inc_qube,
        bool do_fuad) 
{     
    //to make sure the exact same edges are used for my system and QUBE
    //I pass the same edges to both systems
    
    vector<double>  brandes_time_vec;
    
    vector<vector<edge_t> > edge_vec2;
    printf("Reading graphs and generating edges...\n");
    printf("========================================\n");
    for(int i = 0; i < path_vec.size(); ++i) {
        graph_t graph;
        string path = path_vec[i].c_str();
        graph.read_graph(path);
        graph.graph_name = extract_graph_name(path_vec[i]);
        vector<edge_t> edge_vec;
        gen_rand_edges(num_edges, graph, edge_vec);
        edge_vec2.push_back(edge_vec);
    }
    
    printf("\n\n\n");
    printf("Starting Brandes...\n");
    printf("========================================\n");
    for(int i = 0; i < path_vec.size(); ++i) {
        graph_t graph;
        string path = path_vec[i].c_str();
        graph.read_graph(path);
        graph.graph_name = extract_graph_name(path_vec[i]);
        double brandes_time;
        brandes_time = exp_brandes_p(graph, num_iter, edge_vec2[i], max_time);
        brandes_time_vec.push_back(brandes_time);
    }
    
    if(do_inc_brandes) {
        printf("\n\n\n");
        printf("Starting Incremental-Brandes...\n");
        printf("========================================\n");
        for(int i = 0; i < path_vec.size(); ++i) {
            graph_t graph;
            string path = path_vec[i].c_str();
            graph.read_graph(path);
            graph.graph_name = extract_graph_name(path_vec[i]);
            double brandes_time = brandes_time_vec[i];
            exp_inc_brandes_p(graph, num_iter, edge_vec2[i], brandes_time);
        }
    }
    
    if(do_qube) {
        printf("\n\n\n");
        printf("Starting QUBE...\n");
        printf("========================================\n");
        for(int i = 0; i < path_vec.size(); ++i) {
            graph_t graph;
            string path = path_vec[i].c_str();
            graph.read_graph(path);
            graph.graph_name = extract_graph_name(path_vec[i]);
            double brandes_time = brandes_time_vec[i];
            int loc_num_iter = num_iter;
            if(num_iter != -1 && brandes_time < max_time)
                loc_num_iter = -1;
            exp_qube_p(graph, loc_num_iter, edge_vec2[i], brandes_time);
        }
    }
    
    if(do_inc_qube) {
        printf("\n\n\n");
        printf("Starting Incremental-QUBE...\n");
        printf("========================================\n");
        for(int i = 0; i < path_vec.size(); ++i) {
            graph_t graph;
            string path = path_vec[i].c_str();
            graph.read_graph(path);
            graph.graph_name = extract_graph_name(path_vec[i]);
            double brandes_time = brandes_time_vec[i];
            int loc_num_iter = num_iter;
            if(num_iter != -1 && brandes_time < max_time)
                loc_num_iter = -1;
            exp_inc_qube_p(graph, loc_num_iter, edge_vec2[i], brandes_time);
        }
    }
    
    if(do_fuad) {
        printf("\n\n\n");
        printf("Starting FUAD...\n");
        printf("========================================\n");
        for(int i = 0; i < path_vec.size(); ++i) {
            graph_t graph;
            string path = path_vec[i].c_str();
            graph.read_graph(path);
            graph.graph_name = extract_graph_name(path_vec[i]);
            double brandes_time = brandes_time_vec[i];
            int loc_num_iter = num_iter;
            if(num_iter != -1 && brandes_time < max_time)
                loc_num_iter = -1;
            exp_fuad_p(graph, loc_num_iter, edge_vec2[i], brandes_time);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3d8, %rsp            # imm = 0x3D8
movl %r9d, 0x78(%rsp)
movl %r8d, 0x20(%rsp)
movq %rcx, 0x8(%rsp)
movsd %xmm0, 0x28(%rsp)
movl %esi, 0x1c(%rsp)
movl %edi, 0x10(%rsp)
xorpd %xmm0, %xmm0
movapd %xmm0, 0xa0(%rsp)
andq $0x0, 0xb0(%rsp)
leaq 0x80(%rsp), %rax
movapd %xmm0, (%rax)
andq $0x0, 0x10(%rax)
leaq 0xd474(%rip), %rdi      # 0x28ea1
callq 0x2360
leaq 0xd0d9(%rip), %rdi      # 0x28b12
callq 0x2360
xorl %ebp, %ebp
leaq 0x50(%rsp), %r14
leaq 0x3b8(%rsp), %rbx
xorl %r15d, %r15d
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
subq (%rcx), %rax
sarq $0x5, %rax
cmpq %r15, %rax
jbe 0x1bb5a
leaq 0xb8(%rsp), %rdi
callq 0x1d14e
movq 0x8(%rsp), %rax
movq (%rax), %rax
movq (%rax,%rbp), %rsi
leaq 0x30(%rsp), %r12
movq %r12, %rdi
movq %r14, %rdx
callq 0x1d278
movq %rbx, %rdi
movq %r12, %rsi
callq 0x22f0
leaq 0xb8(%rsp), %rdi
movq %rbx, %rsi
callq 0x18d4c
movq %rbx, %rdi
callq 0x20d0
movq 0x8(%rsp), %rax
movq (%rax), %rsi
addq %rbp, %rsi
leaq 0x398(%rsp), %r12
movq %r12, %rdi
callq 0x22f0
movq %r14, %rdi
movq %r12, %rsi
callq 0x26be0
leaq 0x1c0(%rsp), %rdi
movq %r14, %rsi
callq 0x22d0
movq %r14, %rdi
callq 0x20d0
movq %r12, %rdi
callq 0x20d0
xorpd %xmm0, %xmm0
movapd %xmm0, 0x50(%rsp)
andq $0x0, 0x60(%rsp)
movl 0x10(%rsp), %edi
leaq 0xb8(%rsp), %rsi
movq %r14, %rdx
callq 0x12cba
leaq 0x80(%rsp), %rdi
movq %r14, %rsi
callq 0x1d316
movq %r14, %rdi
callq 0x16656
leaq 0x30(%rsp), %rdi
callq 0x20d0
leaq 0xb8(%rsp), %rdi
callq 0x1d2b4
incq %r15
addq $0x20, %rbp
jmp 0x1ba50
leaq 0xd197(%rip), %rdi      # 0x28cf8
callq 0x2360
leaq 0xd35b(%rip), %rdi      # 0x28ec8
callq 0x2360
leaq 0xcf99(%rip), %rdi      # 0x28b12
callq 0x2360
xorl %ebp, %ebp
leaq 0x378(%rsp), %r13
leaq 0x240(%rsp), %r15
movq $0x0, 0x10(%rsp)
xorl %edx, %edx
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
subq (%rcx), %rax
sarq $0x5, %rax
cmpq %rdx, %rax
jbe 0x1bcd0
movq %rdx, %r12
leaq 0xb8(%rsp), %rdi
callq 0x1d14e
movq 0x8(%rsp), %rax
movq (%rax), %rax
movq 0x10(%rsp), %rcx
movq (%rax,%rcx), %rsi
leaq 0x30(%rsp), %r14
movq %r14, %rdi
leaq 0x50(%rsp), %rdx
callq 0x1d278
movq %r13, %rdi
movq %r14, %rsi
callq 0x22f0
leaq 0xb8(%rsp), %rdi
movq %r13, %rsi
callq 0x18d4c
movq %r13, %rdi
callq 0x20d0
movq 0x8(%rsp), %rax
movq (%rax), %rsi
addq 0x10(%rsp), %rsi
leaq 0x358(%rsp), %r14
movq %r14, %rdi
callq 0x22f0
leaq 0x50(%rsp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x26be0
leaq 0x1c0(%rsp), %rdi
movq %rbx, %rsi
callq 0x22d0
movq %rbx, %rdi
callq 0x20d0
movq %r14, %rdi
callq 0x20d0
movq 0x80(%rsp), %rsi
addq %rbp, %rsi
movq %r15, %rdi
callq 0x1d3b6
leaq 0xb8(%rsp), %rdi
movl 0x1c(%rsp), %esi
movq %r15, %rdx
movsd 0x28(%rsp), %xmm0
callq 0x1e590
movsd %xmm0, 0x50(%rsp)
movq %r15, %rdi
callq 0x16656
leaq 0xa0(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x163a4
leaq 0x30(%rsp), %rdi
callq 0x20d0
leaq 0xb8(%rsp), %rdi
callq 0x1d2b4
movq %r12, %rdx
incq %rdx
addq $0x20, 0x10(%rsp)
addq $0x18, %rbp
jmp 0x1bb9b
cmpb $0x0, 0x20(%rsp)
je 0x1be37
leaq 0xd016(%rip), %rdi      # 0x28cf8
callq 0x2360
leaq 0xd1ee(%rip), %rdi      # 0x28edc
callq 0x2360
leaq 0xce18(%rip), %rdi      # 0x28b12
callq 0x2360
xorl %ebp, %ebp
leaq 0x338(%rsp), %rbx
xorl %r14d, %r14d
xorl %r12d, %r12d
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
subq (%rcx), %rax
sarq $0x5, %rax
cmpq %r12, %rax
jbe 0x1be37
leaq 0xb8(%rsp), %rdi
callq 0x1d14e
movq 0x8(%rsp), %rax
movq (%rax), %rax
movq (%rax,%r14), %rsi
leaq 0x30(%rsp), %r15
movq %r15, %rdi
leaq 0x50(%rsp), %rdx
callq 0x1d278
movq %rbx, %rdi
movq %r15, %rsi
callq 0x22f0
leaq 0xb8(%rsp), %rdi
movq %rbx, %rsi
callq 0x18d4c
movq %rbx, %rdi
callq 0x20d0
movq 0x8(%rsp), %rax
movq (%rax), %rsi
addq %r14, %rsi
leaq 0x318(%rsp), %r13
movq %r13, %rdi
callq 0x22f0
leaq 0x50(%rsp), %r15
movq %r15, %rdi
movq %r13, %rsi
callq 0x26be0
leaq 0x1c0(%rsp), %rdi
movq %r15, %rsi
callq 0x22d0
movq %r15, %rdi
callq 0x20d0
movq %r13, %rdi
callq 0x20d0
movq 0xa0(%rsp), %rax
movsd (%rax,%r12,8), %xmm0
movsd %xmm0, 0x10(%rsp)
movq 0x80(%rsp), %rsi
addq %rbp, %rsi
leaq 0x228(%rsp), %r13
movq %r13, %rdi
callq 0x1d3b6
leaq 0xb8(%rsp), %r15
movq %r15, %rdi
movl 0x1c(%rsp), %esi
movq %r13, %rdx
movsd 0x10(%rsp), %xmm0
callq 0x1e7ad
movq %r13, %rdi
callq 0x16656
leaq 0x30(%rsp), %rdi
callq 0x20d0
movq %r15, %rdi
callq 0x1d2b4
incq %r12
addq $0x20, %r14
addq $0x18, %rbp
jmp 0x1bd0f
cmpb $0x0, 0x78(%rsp)
je 0x1bfbd
leaq 0xceaf(%rip), %rdi      # 0x28cf8
callq 0x2360
leaq 0xd0a7(%rip), %rdi      # 0x28efc
callq 0x2360
leaq 0xccb1(%rip), %rdi      # 0x28b12
callq 0x2360
movq $0x0, 0x10(%rsp)
leaq 0xb8(%rsp), %r14
leaq 0x210(%rsp), %r12
xorl %ebx, %ebx
xorl %r15d, %r15d
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
subq (%rcx), %rax
sarq $0x5, %rax
cmpq %r15, %rax
jbe 0x1bfbd
movq %r14, %rdi
callq 0x1d14e
movq 0x8(%rsp), %rax
movq (%rax), %rax
movq (%rax,%rbx), %rsi
leaq 0x30(%rsp), %r13
movq %r13, %rdi
leaq 0x50(%rsp), %rdx
callq 0x1d278
leaq 0x2f8(%rsp), %rbp
movq %rbp, %rdi
movq %r13, %rsi
callq 0x22f0
movq %r14, %rdi
movq %rbp, %rsi
callq 0x18d4c
movq %rbp, %rdi
callq 0x20d0
movq 0x8(%rsp), %rax
movq (%rax), %rsi
addq %rbx, %rsi
leaq 0x2d8(%rsp), %rbp
movq %rbp, %rdi
callq 0x22f0
leaq 0x50(%rsp), %r13
movq %r13, %rdi
movq %rbp, %rsi
callq 0x26be0
leaq 0x1c0(%rsp), %rdi
movq %r13, %rsi
callq 0x22d0
movq %r13, %rdi
callq 0x20d0
movq %rbp, %rdi
callq 0x20d0
movq 0xa0(%rsp), %rax
movsd (%rax,%r15,8), %xmm1
pushq $-0x1
popq %r13
cmpl $-0x1, 0x1c(%rsp)
je 0x1bf62
movsd 0x28(%rsp), %xmm0
ucomisd %xmm1, %xmm0
movl 0x1c(%rsp), %r13d
jbe 0x1bf62
pushq $-0x1
popq %r13
movsd %xmm1, 0x20(%rsp)
movq 0x80(%rsp), %rsi
addq 0x10(%rsp), %rsi
movq %r12, %rdi
callq 0x1d3b6
movq %r14, %rdi
movl %r13d, %esi
movq %r12, %rdx
movsd 0x20(%rsp), %xmm0
callq 0x1ebb7
movq %r12, %rdi
callq 0x16656
leaq 0x30(%rsp), %rdi
callq 0x20d0
movq %r14, %rdi
callq 0x1d2b4
incq %r15
addq $0x20, %rbx
addq $0x18, 0x10(%rsp)
jmp 0x1be84
cmpb $0x0, 0x410(%rsp)
je 0x1c146
leaq 0xcd26(%rip), %rdi      # 0x28cf8
callq 0x2360
leaq 0xcf2f(%rip), %rdi      # 0x28f0d
callq 0x2360
leaq 0xcb28(%rip), %rdi      # 0x28b12
callq 0x2360
movq $0x0, 0x10(%rsp)
leaq 0xb8(%rsp), %r14
leaq 0x1f8(%rsp), %r12
xorl %ebx, %ebx
xorl %r15d, %r15d
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
subq (%rcx), %rax
sarq $0x5, %rax
cmpq %r15, %rax
jbe 0x1c146
movq %r14, %rdi
callq 0x1d14e
movq 0x8(%rsp), %rax
movq (%rax), %rax
movq (%rax,%rbx), %rsi
leaq 0x30(%rsp), %r13
movq %r13, %rdi
leaq 0x50(%rsp), %rdx
callq 0x1d278
leaq 0x2b8(%rsp), %rbp
movq %rbp, %rdi
movq %r13, %rsi
callq 0x22f0
movq %r14, %rdi
movq %rbp, %rsi
callq 0x18d4c
movq %rbp, %rdi
callq 0x20d0
movq 0x8(%rsp), %rax
movq (%rax), %rsi
addq %rbx, %rsi
leaq 0x298(%rsp), %rbp
movq %rbp, %rdi
callq 0x22f0
leaq 0x50(%rsp), %r13
movq %r13, %rdi
movq %rbp, %rsi
callq 0x26be0
leaq 0x1c0(%rsp), %rdi
movq %r13, %rsi
callq 0x22d0
movq %r13, %rdi
callq 0x20d0
movq %rbp, %rdi
callq 0x20d0
movq 0xa0(%rsp), %rax
movsd (%rax,%r15,8), %xmm1
pushq $-0x1
popq %r13
cmpl $-0x1, 0x1c(%rsp)
je 0x1c0eb
movsd 0x28(%rsp), %xmm0
ucomisd %xmm1, %xmm0
movl 0x1c(%rsp), %r13d
jbe 0x1c0eb
pushq $-0x1
popq %r13
movsd %xmm1, 0x20(%rsp)
movq 0x80(%rsp), %rsi
addq 0x10(%rsp), %rsi
movq %r12, %rdi
callq 0x1d3b6
movq %r14, %rdi
movl %r13d, %esi
movq %r12, %rdx
movsd 0x20(%rsp), %xmm0
callq 0x1ef22
movq %r12, %rdi
callq 0x16656
leaq 0x30(%rsp), %rdi
callq 0x20d0
movq %r14, %rdi
callq 0x1d2b4
incq %r15
addq $0x20, %rbx
addq $0x18, 0x10(%rsp)
jmp 0x1c00d
cmpb $0x0, 0x418(%rsp)
je 0x1c2e9
leaq 0xcb9d(%rip), %rdi      # 0x28cf8
callq 0x2360
leaq 0xcdc3(%rip), %rdi      # 0x28f2a
callq 0x2360
leaq 0xc99f(%rip), %rdi      # 0x28b12
callq 0x2360
movq $0x0, 0x20(%rsp)
leaq 0xb8(%rsp), %r14
leaq 0x1e0(%rsp), %r15
movq $0x0, 0x10(%rsp)
xorl %edx, %edx
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %rax
subq (%rcx), %rax
sarq $0x5, %rax
cmpq %rdx, %rax
jbe 0x1c2e9
movq %rdx, %rbx
movq %r14, %rdi
callq 0x1d14e
movq 0x8(%rsp), %rax
movq (%rax), %rax
movq 0x10(%rsp), %rcx
movq (%rax,%rcx), %rsi
leaq 0x30(%rsp), %r13
movq %r13, %rdi
leaq 0x50(%rsp), %rdx
callq 0x1d278
leaq 0x278(%rsp), %rbp
movq %rbp, %rdi
movq %r13, %rsi
callq 0x22f0
movq %r14, %rdi
movq %rbp, %rsi
callq 0x18d4c
movq %rbp, %rdi
callq 0x20d0
movq 0x8(%rsp), %rax
movq (%rax), %rsi
addq 0x10(%rsp), %rsi
leaq 0x258(%rsp), %r13
movq %r13, %rdi
callq 0x22f0
movq %r14, %rbp
leaq 0x50(%rsp), %r14
movq %r14, %rdi
movq %r13, %rsi
callq 0x26be0
leaq 0x1c0(%rsp), %rdi
movq %r14, %rsi
callq 0x22d0
movq %r14, %rdi
callq 0x20d0
movq %r13, %rdi
callq 0x20d0
movq 0xa0(%rsp), %rax
movsd (%rax,%rbx,8), %xmm1
pushq $-0x1
popq %r12
cmpl $-0x1, 0x1c(%rsp)
je 0x1c286
movsd 0x28(%rsp), %xmm0
ucomisd %xmm1, %xmm0
movl 0x1c(%rsp), %r12d
jbe 0x1c286
pushq $-0x1
popq %r12
movsd %xmm1, 0x78(%rsp)
movq 0x80(%rsp), %rsi
addq 0x20(%rsp), %rsi
movq %r15, %rdi
callq 0x1d3b6
movq %rbp, %rdi
movl %r12d, %esi
movq %r15, %rdx
movsd 0x78(%rsp), %xmm0
callq 0x1f281
movq %r15, %rdi
callq 0x16656
leaq 0x30(%rsp), %rdi
callq 0x20d0
movq %rbp, %rdi
callq 0x1d2b4
movq %rbx, %rdx
incq %rdx
addq $0x20, 0x10(%rsp)
addq $0x18, 0x20(%rsp)
movq %rbp, %r14
jmp 0x1c19c
leaq 0x80(%rsp), %rdi
callq 0x1d342
leaq 0xa0(%rsp), %rdi
callq 0x5754
addq $0x3d8, %rsp            # imm = 0x3D8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x1c456
jmp 0x1c483
movq %rax, %rbx
leaq 0x1e0(%rsp), %rdi
jmp 0x1c490
jmp 0x1c483
jmp 0x1c45d
jmp 0x1c483
movq %rax, %rbx
leaq 0x258(%rsp), %rdi
jmp 0x1c47c
movq %rax, %rbx
leaq 0x278(%rsp), %rdi
jmp 0x1c47c
jmp 0x1c456
jmp 0x1c483
movq %rax, %rbx
leaq 0x1f8(%rsp), %rdi
jmp 0x1c490
jmp 0x1c483
jmp 0x1c45d
jmp 0x1c483
movq %rax, %rbx
leaq 0x298(%rsp), %rdi
jmp 0x1c47c
movq %rax, %rbx
leaq 0x2b8(%rsp), %rdi
jmp 0x1c47c
jmp 0x1c456
jmp 0x1c483
movq %rax, %rbx
leaq 0x210(%rsp), %rdi
jmp 0x1c490
jmp 0x1c483
jmp 0x1c45d
jmp 0x1c483
movq %rax, %rbx
leaq 0x2d8(%rsp), %rdi
jmp 0x1c47c
movq %rax, %rbx
leaq 0x2f8(%rsp), %rdi
jmp 0x1c47c
jmp 0x1c456
jmp 0x1c483
movq %rax, %rbx
leaq 0x228(%rsp), %rdi
jmp 0x1c490
jmp 0x1c483
jmp 0x1c483
jmp 0x1c45d
movq %rax, %rbx
leaq 0x318(%rsp), %rdi
jmp 0x1c47c
movq %rax, %rbx
leaq 0x338(%rsp), %rdi
jmp 0x1c47c
jmp 0x1c45d
jmp 0x1c483
movq %rax, %rbx
leaq 0x378(%rsp), %rdi
jmp 0x1c47c
jmp 0x1c456
movq %rax, %rbx
leaq 0x358(%rsp), %rdi
jmp 0x1c47c
movq %rax, %rbx
leaq 0x240(%rsp), %rdi
jmp 0x1c490
jmp 0x1c483
movq %rax, %rbx
jmp 0x1c49f
jmp 0x1c483
movq %rax, %rbx
jmp 0x1c4ac
jmp 0x1c483
movq %rax, %rbx
leaq 0x398(%rsp), %rdi
jmp 0x1c47c
movq %rax, %rbx
leaq 0x3b8(%rsp), %rdi
callq 0x20d0
jmp 0x1c495
movq %rax, %rbx
jmp 0x1c495
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x16656
leaq 0x30(%rsp), %rdi
callq 0x20d0
leaq 0xb8(%rsp), %rdi
callq 0x1d2b4
leaq 0x80(%rsp), %rdi
callq 0x1d342
leaq 0xa0(%rsp), %rdi
callq 0x5754
movq %rbx, %rdi
callq 0x23d0