// File: ynilu[P]elastic/simulator.cpp
// Function: main
int main(int argc, char *argv[])
{
    if( argc > 6 )
    {
        cout << "\nToo many arguments,EX: simulation labmda rquest_number" << "\n";
        return 1;
    }
    if( argc > 1 )
    {
        if( atoi( argv[ 1 ] ) > 0 )
        {
            traffic_lambda = atoi( argv[ 1 ] );
        }
        else
        {
            cout << "\nError parameter: 1" << "\n";
            return 1;
        }
    }
    if( argc > 2 )
    {
        if( atoi( argv[ 2 ] ) > 0 )
        {
            num_requests = atoi( argv[ 2 ] );
        }
        else
        {
            cout << "\nError parameter: 2" << "\n";
            return 1;
        }
    }
    if( argc > 3 )
    {
        if( atoi( argv[ 3 ] ) == 0 )
        {
            enable_OTDM = 0;
        }
    }
    if( argc > 4 )
    {
        if( atoi( argv[ 4 ] ) > 0 )
        {
            num_transceiver = atoi( argv[ 4 ] );
        }
        else
        {
            cout << "\nError parameter: 4" << "\n";
            return 1;
        }
    }
    if( argc > 5 )
    {
        switch( atoi( argv[5] ) )
        {
        case 1:
            graph_file = (char*) "USnet.txt";
            source_file = (char*) "USnet_source.txt";
            traffic_file = (char*) "USnet_traffic.txt";
            break;
        default:
            break;
        }
    }

    if(num_transceiver < 800)
    {
        OEO_weight = hop_limit;
    }

    if(enable_OTDM)
    {
        num_OFDM_transceiver = num_transceiver / 2;
        num_OTDM_transceiver = num_transceiver / 2;
    }
    else
    {
        num_OFDM_transceiver = num_transceiver;
        num_OTDM_transceiver = 0;
    }

    start_clk = clock();

    accepted_requests_BM.resize(num_batch, 0);
    blocked_requests_BM.resize(num_batch, 0);
    blocked_bandwidth_BM.resize(num_batch, 0);
    num_OEO_BM.resize(num_batch, 0);
    num_OFDM_lightpath_use_BM.resize(num_batch, 0);
    num_OTDM_lightpath_use_BM.resize(num_batch, 0);

    Graph_info g_info;
    g_info.graph_file = graph_file;
    g_info.num_slots = num_slots;
    g_info.num_OTDM_transceiver = num_OTDM_transceiver;
    g_info.num_OFDM_transceiver = num_OFDM_transceiver;
    g_info.slot_capacity = slot_capacity;
    g_info.transceiver_slot_limit = transceiver_slot_limit;
    g_info.transceiver_connection_limit = transceiver_connection_limit;
    g_info.transmission_distance_16QAM = transmission_distance_16QAM;
    g_info.transmission_distance_8QAM = transmission_distance_8QAM;
    g_info.transmission_distance_QPSK = transmission_distance_QPSK;

    Phy_graph p_graph(g_info);

    cout << "num_nodes : " << p_graph.node_list.size() << "\n";
    num_nodes = p_graph.node_list.size();

    Traffic_info t_info;
    t_info.source_file = source_file;
    t_info.traffic_file = traffic_file;
    t_info.num_nodes = p_graph.node_list.size();
    t_info.num_requests = num_requests;
    t_info.OC1_share = OC1_share;
    t_info.OC3_share = OC3_share;
    t_info.OC9_share = OC9_share;
    t_info.OC12_share = OC12_share;
    t_info.OC18_share = OC18_share;
    t_info.OC24_share = OC24_share;
    t_info.OC36_share = OC36_share;
    t_info.OC48_share = OC48_share;
    t_info.OC192_share = OC192_share;
    t_info.OC768_share = OC768_share;
    t_info.OC3072_share = OC3072_share;
    t_info.traffic_lambda = traffic_lambda;
    t_info.traffic_mu = traffic_mu;
    t_info.unicast_percentage = unicast_percentage;

    t_info.aTime_seed = aTime_seed;
    t_info.hTime_seed = hTime_seed;
    t_info.s_seed = s_seed;
    t_info.d_seed = d_seed;
    t_info.numD_seed = numD_seed;
    t_info.b_seed = b_seed;

    Traffic traffic (t_info);

    request2lightpath.resize(num_requests);

    Auxiliary_info a_info;
    a_info.num_nodes = num_nodes;
    a_info.num_slots = num_slots;
    a_info.transceiver_weight = transceiver_weight;
    a_info.used_transceiver_weight = used_transceiver_weight;
    a_info.OFDM_transceiver_weight = OFDM_transceiver_weight;
    a_info.used_OFDM_transceiver_weight = used_OFDM_transceiver_weight;
    a_info.OEO_weight = OEO_weight;
    Aux_graph a_graph(a_info);


    while( !traffic.empty() )
    {
        Event event = traffic.next_event();
        if(event.type == Event::arrival)
        {
            cout << "arrival :\nid = " << event.request_id << "\nsource = " << event.source << "\ndest = " << *event.destination.begin() << "\nbandwidth = " << event.bandwidth << "\narrivaltime = " << event.arrival_time << "\n\n";
            start_clk_construction = clock();
            construct_candidate_path(event, p_graph, a_graph);
            construct_exist_path(event, p_graph, a_graph);
            clk_construction += (double) ( clock() - start_clk_construction ) / CLOCKS_PER_SEC;
            start_clk_finding = clock();
            Aux_node* aux_source = a_graph.get_adding_node(event.source);
            Aux_node* aux_destination = a_graph.get_dropping_node(*(event.destination.begin()));
            Aux_node2Aux_link result = BellmanFordSP(aux_source);
            clk_finding += (double) ( clock() - start_clk_finding ) / CLOCKS_PER_SEC;
            start_clk_parsing = clock();
            if(result[aux_destination] != NULL) // Accepted
            {
                path_parsing(p_graph, result, aux_source, aux_destination, event);
                accepted_requests++;
                accepted_requests_BM[(int)event.request_id/(num_requests/num_batch)]++;
            }
            else
            {
                blocked_requests++;
                blocked_requests_BM[(int)event.request_id/(num_requests/num_batch)]++;
                blocked_bandwidth += event.bandwidth;
                blocked_bandwidth_BM[(int)event.request_id/(num_requests/num_batch)] += event.bandwidth;
            }
            clk_parsing += (double) ( clock() - start_clk_parsing ) / CLOCKS_PER_SEC;
            total_bandwidth += event.bandwidth;
            start_clk_construction = clock();
            reset_auxiliary_graph();
            clk_construction += (double) ( clock() - start_clk_construction ) / CLOCKS_PER_SEC;
        }
        else // if(event.type == Event::departure)
        {
            cout << "departure :\nid = " << event.request_id << "\nsource = " << event.source << "\ndest = " << *event.destination.begin() << "\nbandwidth = " << event.bandwidth << "\narrivaltime = " << event.arrival_time << "\n\n";
            for(auto &lp : request2lightpath[event.request_id])
            {
                lp->requests.erase(event.request_id);
                if(lp->requests.empty())
                {
                    int slot_st;
                    int slot_ed;
                    Path& path = lp->p_path;
                    switch(lp->type)
                    {
                    case LightPath::OTDM:
                        slot_st = lp->spectrum.slot_st;
                        slot_ed = lp->spectrum.slot_ed;

                        for(unsigned int node_i = 0; node_i < path.size() - 1; node_i++)
                        {
                            int from = path[node_i];
                            int to = path[node_i + 1];
                            Phy_link& link = p_graph.get_link(from, to);

                            for(int i = slot_st; i <= slot_ed; i++)
                            {
                                link.slot[i] = -1;
                            }
                        }

                        for(unsigned int i = 0; i < lp->transmitter_index.size(); i++)
                        {
                            if(lp->transmitter_index[i] != -1)
                            {
                                p_graph.get_node(path[i]).num_available_transmitter++;
                            }
                        }

                        for(unsigned int i = 0; i < lp->receiver_index.size(); i++)
                        {
                            if(lp->receiver_index[i] != -1)
                            {
                                p_graph.get_node(path[i]).num_available_receiver++;
                            }
                        }
                        delete lp;
                        exist_OTDM_light_path_list.remove(lp);
                        break;
                    case LightPath::OFDM_WOB:
                    case LightPath::OFDM_WB:
                    case LightPath::OFDM:
                        slot_st = lp->spectrum.slot_st;
                        slot_ed = lp->spectrum.slot_ed;

                        Phy_node& src_node = p_graph.get_node(path.front());
                        Phy_node& dst_node = p_graph.get_node(path.back());
                        src_node.OFDMtransmitter[lp->transmitter_index.front()].num_available_sub_transceiver++;
                        dst_node.OFDMreceiver[lp->receiver_index.back()].num_available_sub_transceiver++;

                        for(unsigned int node_i = 0; node_i < path.size() - 1; node_i++)
                        {
                            int from = path[node_i];
                            int to = path[node_i + 1];
                            Phy_link& link = p_graph.get_link(from, to);

                            for(int i = slot_st; i <= slot_ed; i++)
                            {
                                link.slot[i] = -1;
                            }
                        }

                        if(src_node.OFDMtransmitter[lp->transmitter_index.front()].num_available_sub_transceiver >= transceiver_connection_limit)
                        {
                            src_node.OFDMtransmitter[lp->transmitter_index.front()].spectrum.slot_st = -1;
                            src_node.OFDMtransmitter[lp->transmitter_index.front()].spectrum.slot_ed = -1;
                            src_node.OFDMtransmitter[lp->transmitter_index.front()].in_used = false;
                            src_node.OFDMtransmitter[lp->transmitter_index.front()].num_available_sub_transceiver = transceiver_connection_limit;
                            src_node.num_available_OFDM_transmitter++;
                        }

                        if(dst_node.OFDMreceiver[lp->receiver_index.back()].num_available_sub_transceiver >= transceiver_connection_limit)
                        {
                            dst_node.OFDMreceiver[lp->receiver_index.back()].spectrum.slot_st = -1;
                            dst_node.OFDMreceiver[lp->receiver_index.back()].spectrum.slot_ed = -1;
                            dst_node.OFDMreceiver[lp->receiver_index.back()].in_used = false;
                            dst_node.OFDMreceiver[lp->receiver_index.back()].num_available_sub_transceiver = transceiver_connection_limit;
                            dst_node.num_available_OFDM_receiver++;
                        }
                        delete lp;
                        exist_OFDM_light_path_list.remove(lp);
                        break;
                    }
                }
                else
                {
                    lp->available_bitrate += event.bandwidth;
                }
            }
            end_time = event.arrival_time;
        }
    }
    total_network_bandwidth = slot_capacity * num_slots * p_graph.link_list.size();
    print_result(traffic);
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x850, %rsp            # imm = 0x850
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
cmpl $0x6, -0x8(%rbp)
jle 0x396d
movq 0x3f68a(%rip), %rdi     # 0x42fd0
leaq 0x29797(%rip), %rsi     # 0x2d0e4
callq 0x31f0
movq %rax, %rdi
leaq 0x29879(%rip), %rsi     # 0x2d1d5
callq 0x31f0
movl $0x1, -0x4(%rbp)
jmp 0x4f32
cmpl $0x1, -0x8(%rbp)
jle 0x39ca
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x32f0
cmpl $0x0, %eax
jle 0x399a
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x32f0
movl %eax, 0x3f84c(%rip)     # 0x431e4
jmp 0x39c8
movq 0x3f62f(%rip), %rdi     # 0x42fd0
leaq 0x29774(%rip), %rsi     # 0x2d11c
callq 0x31f0
movq %rax, %rdi
leaq 0x2981e(%rip), %rsi     # 0x2d1d5
callq 0x31f0
movl $0x1, -0x4(%rbp)
jmp 0x4f32
jmp 0x39ca
cmpl $0x2, -0x8(%rbp)
jle 0x3a27
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x32f0
cmpl $0x0, %eax
jle 0x39f7
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x32f0
movl %eax, 0x3f7e7(%rip)     # 0x431dc
jmp 0x3a25
movq 0x3f5d2(%rip), %rdi     # 0x42fd0
leaq 0x2972b(%rip), %rsi     # 0x2d130
callq 0x31f0
movq %rax, %rdi
leaq 0x297c1(%rip), %rsi     # 0x2d1d5
callq 0x31f0
movl $0x1, -0x4(%rbp)
jmp 0x4f32
jmp 0x3a27
cmpl $0x3, -0x8(%rbp)
jle 0x3a4b
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x32f0
cmpl $0x0, %eax
jne 0x3a49
movl $0x0, 0x3f7bf(%rip)     # 0x43208
jmp 0x3a4b
cmpl $0x4, -0x8(%rbp)
jle 0x3aa8
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x32f0
cmpl $0x0, %eax
jle 0x3a78
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x32f0
movl %eax, 0x3f776(%rip)     # 0x431ec
jmp 0x3aa6
movq 0x3f551(%rip), %rdi     # 0x42fd0
leaq 0x296be(%rip), %rsi     # 0x2d144
callq 0x31f0
movq %rax, %rdi
leaq 0x29740(%rip), %rsi     # 0x2d1d5
callq 0x31f0
movl $0x1, -0x4(%rbp)
jmp 0x4f32
jmp 0x3aa8
cmpl $0x5, -0x8(%rbp)
jle 0x3af2
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x32f0
subl $0x1, %eax
jne 0x3aee
jmp 0x3ac2
leaq 0x2968f(%rip), %rax     # 0x2d158
movq %rax, 0x3f7b8(%rip)     # 0x43288
leaq 0x2968b(%rip), %rax     # 0x2d162
movq %rax, 0x3f7b2(%rip)     # 0x43290
leaq 0x2968e(%rip), %rax     # 0x2d173
movq %rax, 0x3f7ac(%rip)     # 0x43298
jmp 0x3af0
jmp 0x3af0
jmp 0x3af2
cmpl $0x320, 0x3f6f0(%rip)   # imm = 0x320
jge 0x3b0e
cvtsi2sdl 0x3f6ce(%rip), %xmm0 # 0x431d4
movsd %xmm0, 0x3f8f2(%rip)    # 0x43400
cmpl $0x0, 0x3f6f3(%rip)     # 0x43208
je 0x3b41
movl 0x3f6cf(%rip), %eax     # 0x431ec
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, 0x3f6c9(%rip)     # 0x431f4
movl 0x3f6bb(%rip), %eax     # 0x431ec
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, 0x3f6b1(%rip)     # 0x431f0
jmp 0x3b57
movl 0x3f6a5(%rip), %eax     # 0x431ec
movl %eax, 0x3f6a7(%rip)     # 0x431f4
movl $0x0, 0x3f699(%rip)     # 0x431f0
callq 0x3150
movq %rax, 0x3f755(%rip)     # 0x432b8
movslq 0x3f666(%rip), %rsi     # 0x431d0
movl $0x0, -0x14(%rbp)
leaq 0x3f7b0(%rip), %rdi     # 0x43328
leaq -0x14(%rbp), %rdx
callq 0xb010
movslq 0x3f648(%rip), %rsi     # 0x431d0
movl $0x0, -0x18(%rbp)
leaq 0x3f7aa(%rip), %rdi     # 0x43340
leaq -0x18(%rbp), %rdx
callq 0xb010
movslq 0x3f62a(%rip), %rsi     # 0x431d0
movl $0x0, -0x1c(%rbp)
leaq 0x3f7a4(%rip), %rdi     # 0x43358
leaq -0x1c(%rbp), %rdx
callq 0xb010
movslq 0x3f60c(%rip), %rsi     # 0x431d0
movl $0x0, -0x20(%rbp)
leaq 0x3f79e(%rip), %rdi     # 0x43370
leaq -0x20(%rbp), %rdx
callq 0xb010
movslq 0x3f5ee(%rip), %rsi     # 0x431d0
movl $0x0, -0x24(%rbp)
leaq 0x3f798(%rip), %rdi     # 0x43388
leaq -0x24(%rbp), %rdx
callq 0xb010
movslq 0x3f5d0(%rip), %rsi     # 0x431d0
movl $0x0, -0x28(%rbp)
leaq 0x3f792(%rip), %rdi     # 0x433a0
leaq -0x28(%rbp), %rdx
callq 0xb010
movq 0x3f66a(%rip), %rax     # 0x43288
movq %rax, -0x58(%rbp)
movl 0x3f5b8(%rip), %eax     # 0x431e0
movl %eax, -0x50(%rbp)
movl 0x3f5bf(%rip), %eax     # 0x431f0
movl %eax, -0x4c(%rbp)
movl 0x3f5ba(%rip), %eax     # 0x431f4
movl %eax, -0x48(%rbp)
movl 0x3f5b5(%rip), %eax     # 0x431f8
movl %eax, -0x44(%rbp)
movl 0x3f5b0(%rip), %eax     # 0x431fc
movl %eax, -0x40(%rbp)
movl 0x3f5ab(%rip), %eax     # 0x43200
movl %eax, -0x3c(%rbp)
movl 0x3f5b2(%rip), %eax     # 0x43210
movl %eax, -0x38(%rbp)
movl 0x3f5ad(%rip), %eax     # 0x43214
movl %eax, -0x34(%rbp)
movl 0x3f5a8(%rip), %eax     # 0x43218
movl %eax, -0x30(%rbp)
leaq -0xe8(%rbp), %rdi
leaq -0x58(%rbp), %rsi
callq 0x1a780
movq 0x3f346(%rip), %rdi     # 0x42fd0
leaq 0x294f4(%rip), %rsi     # 0x2d185
callq 0x31f0
movq %rax, -0x690(%rbp)
jmp 0x3c9f
leaq -0xe0(%rbp), %rdi
callq 0xb0c0
movq -0x690(%rbp), %rdi
movq %rax, %rsi
callq 0x3080
movq %rax, -0x698(%rbp)
jmp 0x3cc3
movq -0x698(%rbp), %rdi
leaq 0x29504(%rip), %rsi     # 0x2d1d5
callq 0x31f0
jmp 0x3cd8
leaq -0xe0(%rbp), %rdi
movq %rdi, -0x6a0(%rbp)
callq 0xb0c0
movq -0x6a0(%rbp), %rdi
movl %eax, 0x3f5f8(%rip)     # 0x432f0
movq 0x3f591(%rip), %rax     # 0x43290
movq %rax, -0x180(%rbp)
movq 0x3f58b(%rip), %rax     # 0x43298
movq %rax, -0x178(%rbp)
callq 0xb0c0
movl %eax, -0x170(%rbp)
movl 0x3f4b7(%rip), %eax     # 0x431dc
movl %eax, -0x16c(%rbp)
movl 0x3f5c3(%rip), %eax     # 0x432f4
movl %eax, -0x128(%rbp)
movl 0x3f5bb(%rip), %eax     # 0x432f8
movl %eax, -0x124(%rbp)
movl 0x3f5b3(%rip), %eax     # 0x432fc
movl %eax, -0x120(%rbp)
movl 0x3f5ab(%rip), %eax     # 0x43300
movl %eax, -0x11c(%rbp)
movl 0x3f4bb(%rip), %eax     # 0x4321c
movl %eax, -0x118(%rbp)
movl 0x3f4b3(%rip), %eax     # 0x43220
movl %eax, -0x114(%rbp)
movl 0x3f4ab(%rip), %eax     # 0x43224
movl %eax, -0x110(%rbp)
movl 0x3f4a3(%rip), %eax     # 0x43228
movl %eax, -0x10c(%rbp)
movl 0x3f49b(%rip), %eax     # 0x4322c
movl %eax, -0x108(%rbp)
movl 0x3f493(%rip), %eax     # 0x43230
movl %eax, -0x104(%rbp)
movl 0x3f48b(%rip), %eax     # 0x43234
movl %eax, -0x100(%rbp)
movl 0x3f42f(%rip), %eax     # 0x431e4
movl %eax, -0x168(%rbp)
movl 0x3f427(%rip), %eax     # 0x431e8
movl %eax, -0x164(%rbp)
movss 0x3f409(%rip), %xmm0    # 0x431d8
movss %xmm0, -0x160(%rbp)
movq 0x3f45a(%rip), %rax     # 0x43238
movq %rax, -0x158(%rbp)
movq 0x3f454(%rip), %rax     # 0x43240
movq %rax, -0x150(%rbp)
movq 0x3f44e(%rip), %rax     # 0x43248
movq %rax, -0x148(%rbp)
movq 0x3f448(%rip), %rax     # 0x43250
movq %rax, -0x140(%rbp)
movq 0x3f442(%rip), %rax     # 0x43258
movq %rax, -0x138(%rbp)
movq 0x3f43c(%rip), %rax     # 0x43260
movq %rax, -0x130(%rbp)
leaq -0x2d0(%rbp), %rdi
leaq -0x180(%rbp), %rsi
callq 0x269c0
jmp 0x3e40
movslq 0x3f395(%rip), %rsi     # 0x431dc
leaq 0x3f602(%rip), %rdi     # 0x43450
callq 0xb0f0
jmp 0x3e55
movl 0x3f495(%rip), %eax     # 0x432f0
movl %eax, -0x2fc(%rbp)
movl 0x3f379(%rip), %eax     # 0x431e0
movl %eax, -0x300(%rbp)
movsd 0x3f56b(%rip), %xmm0    # 0x433e0
movsd %xmm0, -0x2f8(%rbp)
movsd 0x3f563(%rip), %xmm0    # 0x433e8
movsd %xmm0, -0x2f0(%rbp)
movsd 0x3f55b(%rip), %xmm0    # 0x433f0
movsd %xmm0, -0x2e8(%rbp)
movsd 0x3f553(%rip), %xmm0    # 0x433f8
movsd %xmm0, -0x2e0(%rbp)
movsd 0x3f54b(%rip), %xmm0    # 0x43400
movsd %xmm0, -0x2d8(%rbp)
leaq -0x3f8(%rbp), %rdi
leaq -0x300(%rbp), %rsi
callq 0x2add0
jmp 0x3ed2
jmp 0x3ed4
leaq -0x2d0(%rbp), %rdi
callq 0x27850
movb %al, -0x6a1(%rbp)
jmp 0x3ee8
movb -0x6a1(%rbp), %al
xorb $-0x1, %al
testb $0x1, %al
jne 0x3ef9
jmp 0x4e5f
leaq -0x450(%rbp), %rdi
leaq -0x2d0(%rbp), %rsi
callq 0x27880
jmp 0x3f0e
cmpl $0x0, -0x448(%rbp)
jne 0x4407
movq 0x3f0ae(%rip), %rdi     # 0x42fd0
leaq 0x29269(%rip), %rsi     # 0x2d192
callq 0x31f0
movq %rax, -0x6b0(%rbp)
jmp 0x3f37
movq -0x6b0(%rbp), %rdi
movl -0x444(%rbp), %esi
callq 0x3330
movq %rax, -0x6b8(%rbp)
jmp 0x3f52
movq -0x6b8(%rbp), %rdi
leaq 0x29242(%rip), %rsi     # 0x2d1a2
callq 0x31f0
movq %rax, -0x6c0(%rbp)
jmp 0x3f6e
movq -0x6c0(%rbp), %rdi
movl -0x440(%rbp), %esi
callq 0x3330
movq %rax, -0x6c8(%rbp)
jmp 0x3f89
movq -0x6c8(%rbp), %rdi
leaq 0x29216(%rip), %rsi     # 0x2d1ad
callq 0x31f0
movq %rax, -0x6d0(%rbp)
jmp 0x3fa5
leaq -0x438(%rbp), %rdi
callq 0xb180
movq %rax, -0x458(%rbp)
leaq -0x458(%rbp), %rdi
callq 0xb1b0
movq -0x6d0(%rbp), %rdi
movl (%rax), %esi
callq 0x3330
movq %rax, -0x6d8(%rbp)
jmp 0x3fdb
movq -0x6d8(%rbp), %rdi
leaq 0x291cd(%rip), %rsi     # 0x2d1b6
callq 0x31f0
movq %rax, -0x6e0(%rbp)
jmp 0x3ff7
movq -0x6e0(%rbp), %rdi
movl -0x404(%rbp), %esi
callq 0x3330
movq %rax, -0x6e8(%rbp)
jmp 0x4012
movq -0x6e8(%rbp), %rdi
leaq 0x291a4(%rip), %rsi     # 0x2d1c4
callq 0x31f0
movq %rax, -0x6f0(%rbp)
jmp 0x402e
movq -0x6f0(%rbp), %rdi
movss -0x400(%rbp), %xmm0
callq 0x3170
movq %rax, -0x6f8(%rbp)
jmp 0x404b
movq -0x6f8(%rbp), %rdi
leaq 0x2917b(%rip), %rsi     # 0x2d1d4
callq 0x31f0
jmp 0x4060
callq 0x3150
movq %rax, 0x3f264(%rip)     # 0x432d0
leaq -0x450(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
leaq -0x3f8(%rbp), %rdx
callq 0x4f50
jmp 0x4088
leaq -0x450(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
leaq -0x3f8(%rbp), %rdx
callq 0x5060
jmp 0x40a4
callq 0x3150
movq 0x3f220(%rip), %rcx     # 0x432d0
subq %rcx, %rax
cvtsi2sd %rax, %xmm1
movsd 0x28f60(%rip), %xmm0    # 0x2d020
divsd %xmm0, %xmm1
movsd 0x3f20c(%rip), %xmm0    # 0x432d8
addsd %xmm1, %xmm0
movsd %xmm0, 0x3f200(%rip)    # 0x432d8
callq 0x3150
movq %rax, 0x3f1dc(%rip)     # 0x432c0
movl -0x440(%rbp), %esi
leaq -0x3f8(%rbp), %rdi
callq 0x2b950
movq %rax, -0x700(%rbp)
jmp 0x40ff
movq -0x700(%rbp), %rax
movq %rax, -0x460(%rbp)
leaq -0x438(%rbp), %rdi
callq 0xb180
movq %rax, -0x470(%rbp)
leaq -0x470(%rbp), %rdi
callq 0xb1b0
movl (%rax), %esi
leaq -0x3f8(%rbp), %rdi
callq 0x2b980
movq %rax, -0x708(%rbp)
jmp 0x4143
movq -0x708(%rbp), %rax
movq %rax, -0x468(%rbp)
movq -0x460(%rbp), %rsi
leaq -0x4a8(%rbp), %rdi
callq 0x5520
jmp 0x4166
callq 0x3150
movq 0x3f14e(%rip), %rcx     # 0x432c0
subq %rcx, %rax
cvtsi2sd %rax, %xmm1
movsd 0x28e9e(%rip), %xmm0    # 0x2d020
divsd %xmm0, %xmm1
movsd 0x3f13a(%rip), %xmm0    # 0x432c8
addsd %xmm1, %xmm0
movsd %xmm0, 0x3f12e(%rip)    # 0x432c8
callq 0x3150
movq %rax, 0x3f13a(%rip)     # 0x432e0
leaq -0x4a8(%rbp), %rdi
leaq -0x468(%rbp), %rsi
callq 0xb1e0
movq %rax, -0x710(%rbp)
jmp 0x41c2
movq -0x710(%rbp), %rax
cmpq $0x0, (%rax)
je 0x42ca
movq -0x460(%rbp), %rdx
movq -0x468(%rbp), %rcx
leaq -0xe8(%rbp), %rdi
leaq -0x4a8(%rbp), %rsi
leaq -0x450(%rbp), %r8
callq 0x5730
jmp 0x41fd
movl 0x3f101(%rip), %eax     # 0x43304
addl $0x1, %eax
movl %eax, 0x3f0f8(%rip)     # 0x43304
movl -0x444(%rbp), %eax
movl %eax, -0x714(%rbp)
movl 0x3efbe(%rip), %eax     # 0x431dc
cltd
idivl 0x3efab(%rip)           # 0x431d0
movl %eax, %ecx
movl -0x714(%rbp), %eax
cltd
idivl %ecx
movslq %eax, %rsi
leaq 0x3f0ee(%rip), %rdi     # 0x43328
callq 0xb210
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0x436e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xf0(%rbp)
movl %eax, -0xf4(%rbp)
jmp 0x4f24
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xf0(%rbp)
movl %eax, -0xf4(%rbp)
jmp 0x4f18
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xf0(%rbp)
movl %eax, -0xf4(%rbp)
jmp 0x4f0c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xf0(%rbp)
movl %eax, -0xf4(%rbp)
jmp 0x4e4e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xf0(%rbp)
movl %eax, -0xf4(%rbp)
leaq -0x4a8(%rbp), %rdi
callq 0xb230
jmp 0x4e4e
movl 0x3f038(%rip), %eax     # 0x43308
addl $0x1, %eax
movl %eax, 0x3f02f(%rip)     # 0x43308
movl -0x444(%rbp), %eax
movl %eax, -0x720(%rbp)
movl 0x3eef1(%rip), %eax     # 0x431dc
cltd
idivl 0x3eede(%rip)           # 0x431d0
movl %eax, %ecx
movl -0x720(%rbp), %eax
cltd
idivl %ecx
movslq %eax, %rsi
leaq 0x3f039(%rip), %rdi     # 0x43340
callq 0xb210
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
movl -0x404(%rbp), %eax
addl 0x3efed(%rip), %eax     # 0x4330c
movl %eax, 0x3efe7(%rip)     # 0x4330c
movl -0x404(%rbp), %eax
movl %eax, -0x718(%rbp)
movl -0x444(%rbp), %eax
movl %eax, -0x71c(%rbp)
movl 0x3ee99(%rip), %eax     # 0x431dc
cltd
idivl 0x3ee86(%rip)           # 0x431d0
movl %eax, %ecx
movl -0x71c(%rbp), %eax
cltd
idivl %ecx
movslq %eax, %rsi
leaq 0x3eff9(%rip), %rdi     # 0x43358
callq 0xb210
movl -0x718(%rbp), %ecx
addl (%rax), %ecx
movl %ecx, (%rax)
callq 0x3150
movq 0x3ef66(%rip), %rcx     # 0x432e0
subq %rcx, %rax
cvtsi2sd %rax, %xmm1
movsd 0x28c96(%rip), %xmm0    # 0x2d020
divsd %xmm0, %xmm1
movsd 0x3ef52(%rip), %xmm0    # 0x432e8
addsd %xmm1, %xmm0
movsd %xmm0, 0x3ef46(%rip)    # 0x432e8
movl -0x404(%rbp), %ecx
movl 0x3ef6e(%rip), %eax     # 0x4331c
addl %ecx, %eax
movl %eax, 0x3ef66(%rip)     # 0x4331c
callq 0x3150
movq %rax, 0x3ef0e(%rip)     # 0x432d0
callq 0x5e90
jmp 0x43c9
callq 0x3150
subq 0x3eefb(%rip), %rax     # 0x432d0
cvtsi2sd %rax, %xmm0
movsd 0x28c3e(%rip), %xmm1    # 0x2d020
divsd %xmm1, %xmm0
addsd 0x3eeea(%rip), %xmm0    # 0x432d8
movsd %xmm0, 0x3eee2(%rip)    # 0x432d8
leaq -0x4a8(%rbp), %rdi
callq 0xb230
jmp 0x4e3d
movq 0x3ebc2(%rip), %rdi     # 0x42fd0
leaq 0x28dc2(%rip), %rsi     # 0x2d1d7
callq 0x31f0
movq %rax, -0x728(%rbp)
jmp 0x4423
movq -0x728(%rbp), %rdi
movl -0x444(%rbp), %esi
callq 0x3330
movq %rax, -0x730(%rbp)
jmp 0x443e
movq -0x730(%rbp), %rdi
leaq 0x28d56(%rip), %rsi     # 0x2d1a2
callq 0x31f0
movq %rax, -0x738(%rbp)
jmp 0x445a
movq -0x738(%rbp), %rdi
movl -0x440(%rbp), %esi
callq 0x3330
movq %rax, -0x740(%rbp)
jmp 0x4475
movq -0x740(%rbp), %rdi
leaq 0x28d2a(%rip), %rsi     # 0x2d1ad
callq 0x31f0
movq %rax, -0x748(%rbp)
jmp 0x4491
leaq -0x438(%rbp), %rdi
callq 0xb180
movq %rax, -0x4b0(%rbp)
leaq -0x4b0(%rbp), %rdi
callq 0xb1b0
movq -0x748(%rbp), %rdi
movl (%rax), %esi
callq 0x3330
movq %rax, -0x750(%rbp)
jmp 0x44c7
movq -0x750(%rbp), %rdi
leaq 0x28ce1(%rip), %rsi     # 0x2d1b6
callq 0x31f0
movq %rax, -0x758(%rbp)
jmp 0x44e3
movq -0x758(%rbp), %rdi
movl -0x404(%rbp), %esi
callq 0x3330
movq %rax, -0x760(%rbp)
jmp 0x44fe
movq -0x760(%rbp), %rdi
leaq 0x28cb8(%rip), %rsi     # 0x2d1c4
callq 0x31f0
movq %rax, -0x768(%rbp)
jmp 0x451a
movq -0x768(%rbp), %rdi
movss -0x400(%rbp), %xmm0
callq 0x3170
movq %rax, -0x770(%rbp)
jmp 0x4537
movq -0x770(%rbp), %rdi
leaq 0x28c8f(%rip), %rsi     # 0x2d1d4
callq 0x31f0
jmp 0x454c
movslq -0x444(%rbp), %rsi
leaq 0x3eef6(%rip), %rdi     # 0x43450
callq 0xb250
movq %rax, -0x4b8(%rbp)
movq -0x4b8(%rbp), %rdi
callq 0xb270
movq %rax, -0x4c0(%rbp)
movq -0x4b8(%rbp), %rdi
callq 0xb2a0
movq %rax, -0x4c8(%rbp)
leaq -0x4c0(%rbp), %rdi
leaq -0x4c8(%rbp), %rsi
callq 0xb2d0
testb $0x1, %al
jne 0x45a8
jmp 0x4e29
leaq -0x4c0(%rbp), %rdi
callq 0xb310
movq %rax, -0x4d0(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0x10, %rdi
leaq -0x444(%rbp), %rsi
callq 0xb330
jmp 0x45d7
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0x10, %rdi
callq 0xb360
testb $0x1, %al
jne 0x45f3
jmp 0x4e00
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
addq $0x68, %rax
movq %rax, -0x4e0(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movl 0x8(%rax), %eax
movl %eax, -0x774(%rbp)
testl %eax, %eax
je 0x4637
jmp 0x4621
movl -0x774(%rbp), %eax
decl %eax
subl $0x3, %eax
jb 0x48fc
jmp 0x4dfe
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movl 0x58(%rax), %eax
movl %eax, -0x4d4(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movl 0x5c(%rax), %eax
movl %eax, -0x4d8(%rbp)
movl $0x0, -0x4e4(%rbp)
movl -0x4e4(%rbp), %eax
movq %rax, -0x780(%rbp)
movq -0x4e0(%rbp), %rdi
callq 0xb380
movq %rax, %rcx
movq -0x780(%rbp), %rax
subq $0x1, %rcx
cmpq %rcx, %rax
jae 0x475e
movq -0x4e0(%rbp), %rdi
movl -0x4e4(%rbp), %eax
movl %eax, %esi
callq 0xb210
movl (%rax), %eax
movl %eax, -0x4e8(%rbp)
movq -0x4e0(%rbp), %rdi
movl -0x4e4(%rbp), %eax
incl %eax
movl %eax, %esi
callq 0xb210
movl (%rax), %eax
movl %eax, -0x4ec(%rbp)
movl -0x4e8(%rbp), %esi
movl -0x4ec(%rbp), %edx
leaq -0xe8(%rbp), %rdi
callq 0x1a730
movq %rax, -0x788(%rbp)
jmp 0x46f2
movq -0x788(%rbp), %rax
movq %rax, -0x4f8(%rbp)
movl -0x4d4(%rbp), %eax
movl %eax, -0x4fc(%rbp)
movl -0x4fc(%rbp), %eax
cmpl -0x4d8(%rbp), %eax
jg 0x4748
movq -0x4f8(%rbp), %rdi
addq $0x18, %rdi
movslq -0x4fc(%rbp), %rsi
callq 0xb210
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
movl -0x4fc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4fc(%rbp)
jmp 0x470c
jmp 0x474a
movl -0x4e4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4e4(%rbp)
jmp 0x4667
movl $0x0, -0x500(%rbp)
movl -0x500(%rbp), %eax
movq %rax, -0x790(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb380
movq %rax, %rcx
movq -0x790(%rbp), %rax
cmpq %rcx, %rax
jae 0x480e
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
movl -0x500(%rbp), %eax
movl %eax, %esi
callq 0xb210
cmpl $-0x1, (%rax)
je 0x47f8
movq -0x4e0(%rbp), %rdi
movl -0x500(%rbp), %eax
movl %eax, %esi
callq 0xb210
movl (%rax), %esi
leaq -0xe8(%rbp), %rdi
callq 0x1b450
movq %rax, -0x798(%rbp)
jmp 0x47e8
movq -0x798(%rbp), %rax
movl 0x28(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x28(%rax)
jmp 0x47fa
movl -0x500(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x500(%rbp)
jmp 0x4768
movl $0x0, -0x504(%rbp)
movl -0x504(%rbp), %eax
movq %rax, -0x7a0(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb380
movq %rax, %rcx
movq -0x7a0(%rbp), %rax
cmpq %rcx, %rax
jae 0x48be
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
movl -0x504(%rbp), %eax
movl %eax, %esi
callq 0xb210
cmpl $-0x1, (%rax)
je 0x48a8
movq -0x4e0(%rbp), %rdi
movl -0x504(%rbp), %eax
movl %eax, %esi
callq 0xb210
movl (%rax), %esi
leaq -0xe8(%rbp), %rdi
callq 0x1b450
movq %rax, -0x7a8(%rbp)
jmp 0x4898
movq -0x7a8(%rbp), %rax
movl 0x30(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x30(%rax)
jmp 0x48aa
movl -0x504(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x504(%rbp)
jmp 0x4818
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x7b0(%rbp)
cmpq $0x0, %rax
je 0x48e2
movq -0x7b0(%rbp), %rdi
movq (%rdi), %rax
callq *0x8(%rax)
movq -0x4d0(%rbp), %rsi
leaq 0x3eb30(%rip), %rdi     # 0x43420
callq 0xb3a0
jmp 0x48f7
jmp 0x4dfe
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movl 0x58(%rax), %eax
movl %eax, -0x4d4(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movl 0x5c(%rax), %eax
movl %eax, -0x4d8(%rbp)
movq -0x4e0(%rbp), %rdi
callq 0xb480
movl (%rax), %esi
leaq -0xe8(%rbp), %rdi
callq 0x1b450
movq %rax, -0x7b8(%rbp)
jmp 0x4945
movq -0x7b8(%rbp), %rax
movq %rax, -0x510(%rbp)
movq -0x4e0(%rbp), %rdi
callq 0xb4b0
movl (%rax), %esi
leaq -0xe8(%rbp), %rdi
callq 0x1b450
movq %rax, -0x7c0(%rbp)
jmp 0x4976
movq -0x7c0(%rbp), %rax
movq %rax, -0x518(%rbp)
movq -0x510(%rbp), %rax
addq $0x68, %rax
movq %rax, -0x7d0(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb480
movq -0x7d0(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl 0xc(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0xc(%rax)
movq -0x518(%rbp), %rax
addq $0x80, %rax
movq %rax, -0x7c8(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb4b0
movq -0x7c8(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl 0xc(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0xc(%rax)
movl $0x0, -0x51c(%rbp)
movl -0x51c(%rbp), %eax
movq %rax, -0x7d8(%rbp)
movq -0x4e0(%rbp), %rdi
callq 0xb380
movq %rax, %rcx
movq -0x7d8(%rbp), %rax
subq $0x1, %rcx
cmpq %rcx, %rax
jae 0x4b07
movq -0x4e0(%rbp), %rdi
movl -0x51c(%rbp), %eax
movl %eax, %esi
callq 0xb210
movl (%rax), %eax
movl %eax, -0x520(%rbp)
movq -0x4e0(%rbp), %rdi
movl -0x51c(%rbp), %eax
incl %eax
movl %eax, %esi
callq 0xb210
movl (%rax), %eax
movl %eax, -0x524(%rbp)
movl -0x520(%rbp), %esi
movl -0x524(%rbp), %edx
leaq -0xe8(%rbp), %rdi
callq 0x1a730
movq %rax, -0x7e0(%rbp)
jmp 0x4a9b
movq -0x7e0(%rbp), %rax
movq %rax, -0x530(%rbp)
movl -0x4d4(%rbp), %eax
movl %eax, -0x534(%rbp)
movl -0x534(%rbp), %eax
cmpl -0x4d8(%rbp), %eax
jg 0x4af1
movq -0x530(%rbp), %rdi
addq $0x18, %rdi
movslq -0x534(%rbp), %rsi
callq 0xb210
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
movl -0x534(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x534(%rbp)
jmp 0x4ab5
jmp 0x4af3
movl -0x51c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x51c(%rbp)
jmp 0x4a10
movq -0x510(%rbp), %rax
addq $0x68, %rax
movq %rax, -0x7e8(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb480
movq -0x7e8(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl 0xc(%rax), %eax
cmpl 0x3e6b9(%rip), %eax     # 0x43200
jl 0x4c60
movq -0x510(%rbp), %rax
addq $0x68, %rax
movq %rax, -0x810(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb480
movq -0x810(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl $0xffffffff, 0x48(%rax) # imm = 0xFFFFFFFF
movq -0x510(%rbp), %rax
addq $0x68, %rax
movq %rax, -0x808(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb480
movq -0x808(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl $0xffffffff, 0x4c(%rax) # imm = 0xFFFFFFFF
movq -0x510(%rbp), %rax
addq $0x68, %rax
movq %rax, -0x800(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb480
movq -0x800(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movb $0x0, 0x8(%rax)
movl 0x3e5f6(%rip), %eax     # 0x43200
movl %eax, -0x7ec(%rbp)
movq -0x510(%rbp), %rax
addq $0x68, %rax
movq %rax, -0x7f8(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xc8, %rdi
callq 0xb480
movq -0x7f8(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl -0x7ec(%rbp), %ecx
movl %ecx, 0xc(%rax)
movq -0x510(%rbp), %rax
movl 0x2c(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x2c(%rax)
movq -0x518(%rbp), %rax
addq $0x80, %rax
movq %rax, -0x818(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb4b0
movq -0x818(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl 0xc(%rax), %eax
cmpl 0x3e55e(%rip), %eax     # 0x43200
jl 0x4dc3
movq -0x518(%rbp), %rax
addq $0x80, %rax
movq %rax, -0x840(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb4b0
movq -0x840(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl $0xffffffff, 0x48(%rax) # imm = 0xFFFFFFFF
movq -0x518(%rbp), %rax
addq $0x80, %rax
movq %rax, -0x838(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb4b0
movq -0x838(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl $0xffffffff, 0x4c(%rax) # imm = 0xFFFFFFFF
movq -0x518(%rbp), %rax
addq $0x80, %rax
movq %rax, -0x830(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb4b0
movq -0x830(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movb $0x0, 0x8(%rax)
movl 0x3e495(%rip), %eax     # 0x43200
movl %eax, -0x81c(%rbp)
movq -0x518(%rbp), %rax
addq $0x80, %rax
movq %rax, -0x828(%rbp)
movq -0x4d0(%rbp), %rax
movq (%rax), %rdi
addq $0xe0, %rdi
callq 0xb4b0
movq -0x828(%rbp), %rdi
movslq (%rax), %rsi
callq 0xb4f0
movl -0x81c(%rbp), %ecx
movl %ecx, 0xc(%rax)
movq -0x518(%rbp), %rax
movl 0x34(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x34(%rax)
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x848(%rbp)
cmpq $0x0, %rax
je 0x4de7
movq -0x848(%rbp), %rdi
movq (%rdi), %rax
callq *0x8(%rax)
movq -0x4d0(%rbp), %rsi
leaq 0x3e643(%rip), %rdi     # 0x43438
callq 0xb3a0
jmp 0x4dfc
jmp 0x4dfe
jmp 0x4e16
movl -0x404(%rbp), %ecx
movq -0x4d0(%rbp), %rax
movq (%rax), %rax
addl 0x44(%rax), %ecx
movl %ecx, 0x44(%rax)
jmp 0x4e18
leaq -0x4c0(%rbp), %rdi
callq 0xb510
jmp 0x458c
movss -0x400(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
movsd %xmm0, 0x3e59b(%rip)    # 0x433d8
leaq -0x450(%rbp), %rdi
callq 0x27ff0
jmp 0x3ed4
leaq -0x450(%rbp), %rdi
callq 0x27ff0
jmp 0x4f0c
movl 0x3e393(%rip), %eax     # 0x431f8
movl 0x3e375(%rip), %ecx     # 0x431e0
imull %ecx, %eax
movl %eax, -0x84c(%rbp)
leaq -0xc8(%rbp), %rdi
callq 0xb530
movq %rax, %rcx
movl -0x84c(%rbp), %eax
imull %ecx, %eax
movl %eax, 0x3e48e(%rip)     # 0x43320
leaq -0x688(%rbp), %rdi
leaq -0x2d0(%rbp), %rsi
callq 0xb550
jmp 0x4ea7
leaq -0x688(%rbp), %rdi
callq 0x6150
jmp 0x4eb5
leaq -0x688(%rbp), %rdi
callq 0x277b0
movl $0x0, -0x4(%rbp)
leaq -0x3f8(%rbp), %rdi
callq 0x2b550
leaq -0x2d0(%rbp), %rdi
callq 0x277b0
leaq -0xe8(%rbp), %rdi
callq 0x1af20
jmp 0x4f32
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xf0(%rbp)
movl %eax, -0xf4(%rbp)
leaq -0x688(%rbp), %rdi
callq 0x277b0
leaq -0x3f8(%rbp), %rdi
callq 0x2b550
leaq -0x2d0(%rbp), %rdi
callq 0x277b0
leaq -0xe8(%rbp), %rdi
callq 0x1af20
jmp 0x4f3e
movl -0x4(%rbp), %eax
addq $0x850, %rsp            # imm = 0x850
popq %rbp
retq
movq -0xf0(%rbp), %rdi
callq 0x3340
nopw (%rax,%rax)