// File: canzarlab[P]Trajan/src/EditDist.cpp
// Function: EditDist(Graph&, 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>>&, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>&, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
void EditDist(Graph& g1, Graph& g2, string & fileName, string & outSolution, std::map<string, string> & t1Label2Node, std::map<string, string> & t2Label2Node, string & outScore)
{
    vn n1, n2;
    int k1 = GetNumTrees(g1.GetRoot(), n1), k2 = GetNumTrees(g2.GetRoot(), n2);
    Tree& t1 = (Tree&)(k1 >= k2 ? g1 : g2), &t2 = (Tree&)(k1 >= k2 ? g2 : g1);
    bool swp = false;
    if (k2 > k1)
    {
        cout << "Swap two tree\n";
        swap(n1, n2), swp = true;
        std::map<string, string> temp;
        temp = t1Label2Node;
        t1Label2Node = t2Label2Node;
        t2Label2Node = temp;
    }

    // read data.
    CSVReader reader(fileName);
    vector<vector<double>> cost_matrix = reader.getDoubleData();
    vector<vector<int>> scale_cost_matrix;
    const double scale = 1000.0;
    scale_cost_matrix.resize(swp ? cost_matrix[0].size() : cost_matrix.size());
    for (int i = 0; i < (int) cost_matrix.size(); ++i)
        for (int j = 0; j < (int) cost_matrix[0].size(); ++j)
            scale_cost_matrix[swp ? j : i].push_back((int) (scale*cost_matrix[i][j]));

    vvvi P;
    vvi S;
    GenPerms(n2, 0, S, P);
    vvvvi BP;
    vvi BL1, BL2;
    vvi BT1, BT2, BD1, BD2;
    int mm = numeric_limits<int>::max();
    for (int i = 0; i < P.size(); ++i)
    {
        newick_node* nroot = new newick_node(n2[0]->taxon);
        MakeTree(n2[0], nroot, 0, P[i]);
        int n = n1.size(), m = n2.size();
        vvi L1(n + 1, vi(n + 1)), L2(m + 1, vi(m + 1));
        vvi T1(n + 1, vi(n + 1, 1)), T2(m + 1, vi(m + 1, 1));
        vvi D1(n + 1, vi(n + 1, -1)), D2(m + 1, vi(m + 1, -1));
        GenTables(t1.GetRoot(), n, L1, T1, D1);
        GenTables(nroot, m, L2, T2, D2);
        vvvvi NP(n + 1, vvvi(n + 1, vvi(m + 1, vi(m + 1, -1))));
        int nm = OrderedEditDist(NP, L1, L2, T1, T2, D1, D2, n, m, scale_cost_matrix);
        if (nm < mm)
        {
            mm = nm, BP = move(NP);
            BL1 = move(L1), BL2 = move(L2);
            BT1 = move(T1), BT2 = move(T2);
            BD1 = move(D1), BD2 = move(D2);
        }
        DeallocTree(nroot);
    }
    ofstream myfile(outSolution);
    PrintMatching(BP, BL1, BL2, BT1, BT2, BD1, BD2, {0, 0, 0, 0}, swp, myfile, t1Label2Node, t2Label2Node);
    myfile.close();
    clog << "DIST: " << (double)mm/scale << endl;
    ofstream score(outScore);
    score << (double)mm/scale << endl;
    score.close();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa30, %rsp            # imm = 0xA30
movq 0x10(%rbp), %rax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
leaq -0x48(%rbp), %rdi
callq 0x99590
leaq -0x60(%rbp), %rdi
callq 0x99590
movq -0x8(%rbp), %rdi
callq 0xa8ec0
movq %rax, -0x868(%rbp)
jmp 0xfcfab
movq -0x868(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0xfae00
movl %eax, -0x86c(%rbp)
jmp 0xfcfc3
movl -0x86c(%rbp), %eax
movl %eax, -0x64(%rbp)
movq -0x10(%rbp), %rdi
callq 0xa8ec0
movq %rax, -0x878(%rbp)
jmp 0xfcfde
movq -0x878(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0xfae00
movl %eax, -0x87c(%rbp)
jmp 0xfcff6
movl -0x87c(%rbp), %eax
movl %eax, -0x78(%rbp)
movl -0x64(%rbp), %eax
cmpl -0x78(%rbp), %eax
jl 0xfd014
movq -0x8(%rbp), %rax
movq %rax, -0x888(%rbp)
jmp 0xfd01f
movq -0x10(%rbp), %rax
movq %rax, -0x888(%rbp)
movq -0x888(%rbp), %rax
movq %rax, -0x80(%rbp)
movl -0x64(%rbp), %eax
cmpl -0x78(%rbp), %eax
jl 0xfd03f
movq -0x10(%rbp), %rax
movq %rax, -0x890(%rbp)
jmp 0xfd04a
movq -0x8(%rbp), %rax
movq %rax, -0x890(%rbp)
movq -0x890(%rbp), %rax
movq %rax, -0x88(%rbp)
movb $0x0, -0x89(%rbp)
movl -0x78(%rbp), %eax
cmpl -0x64(%rbp), %eax
jle 0xfd116
movq 0xa3f3e(%rip), %rdi     # 0x1a0fb0
leaq 0x32588(%rip), %rsi     # 0x12f601
callq 0xa440
jmp 0xfd080
leaq -0x48(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0x9f750
movb $0x1, -0x89(%rbp)
leaq -0xc0(%rbp), %rdi
movq %rdi, -0x898(%rbp)
callq 0xec00
movq -0x898(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0xfec40
jmp 0xfd0b9
movq -0x30(%rbp), %rsi
movq -0x28(%rbp), %rdi
callq 0xfec40
jmp 0xfd0c8
movq -0x30(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
callq 0xfec40
jmp 0xfd0da
leaq -0xc0(%rbp), %rdi
callq 0xf240
jmp 0xfd116
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfe293
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0xc0(%rbp), %rdi
callq 0xf240
jmp 0xfe293
movq -0x18(%rbp), %rsi
leaq -0x120(%rbp), %rdi
callq 0xa190
jmp 0xfd128
leaq -0x141(%rbp), %rdi
movq %rdi, -0x8a0(%rbp)
callq 0xa7d0
movq -0x8a0(%rbp), %rdx
leaq 0x2d027(%rip), %rsi     # 0x12a170
leaq -0x140(%rbp), %rdi
callq 0xe9b0
jmp 0xfd157
leaq -0x100(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x140(%rbp), %rdx
callq 0xeba0
jmp 0xfd173
leaq -0x140(%rbp), %rdi
callq 0xa8d8
leaq -0x141(%rbp), %rdi
callq 0xa4c0
leaq -0x120(%rbp), %rdi
callq 0xa8d8
leaq -0x160(%rbp), %rdi
leaq -0x100(%rbp), %rsi
xorl %edx, %edx
movl $0x2710, %ecx           # imm = 0x2710
callq 0x104400
jmp 0xfd1b3
leaq -0x178(%rbp), %rdi
callq 0x99100
movsd 0x32421(%rip), %xmm0    # 0x12f5e8
movsd %xmm0, -0x180(%rbp)
testb $0x1, -0x89(%rbp)
je 0xfd1f9
leaq -0x160(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x9a070
movq %rax, %rdi
callq 0x9ce20
movq %rax, -0x8a8(%rbp)
jmp 0xfd20c
leaq -0x160(%rbp), %rdi
callq 0x9c200
movq %rax, -0x8a8(%rbp)
movq -0x8a8(%rbp), %rsi
leaq -0x178(%rbp), %rdi
callq 0x99160
jmp 0xfd221
movl $0x0, -0x184(%rbp)
movl -0x184(%rbp), %eax
movl %eax, -0x8ac(%rbp)
leaq -0x160(%rbp), %rdi
callq 0x9c200
movq %rax, %rcx
movl -0x8ac(%rbp), %eax
cmpl %ecx, %eax
jge 0xfd3b4
movl $0x0, -0x188(%rbp)
movl -0x188(%rbp), %eax
movl %eax, -0x8b0(%rbp)
leaq -0x160(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x9a070
movq %rax, %rdi
callq 0x9ce20
movq %rax, %rcx
movl -0x8b0(%rbp), %eax
cmpl %ecx, %eax
jge 0xfd39e
testb $0x1, -0x89(%rbp)
je 0xfd2aa
movl -0x188(%rbp), %eax
movl %eax, -0x8b4(%rbp)
jmp 0xfd2b6
movl -0x184(%rbp), %eax
movl %eax, -0x8b4(%rbp)
movl -0x8b4(%rbp), %eax
movslq %eax, %rsi
leaq -0x178(%rbp), %rdi
callq 0x993b0
movq %rax, -0x8c0(%rbp)
movslq -0x184(%rbp), %rsi
leaq -0x160(%rbp), %rdi
callq 0x9a070
movq %rax, %rdi
movslq -0x188(%rbp), %rsi
callq 0x9a090
movq -0x8c0(%rbp), %rdi
movsd (%rax), %xmm0
movsd 0x322e1(%rip), %xmm1    # 0x12f5e8
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, -0x18c(%rbp)
leaq -0x18c(%rbp), %rsi
callq 0x99440
jmp 0xfd323
jmp 0xfd325
movl -0x188(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x188(%rbp)
jmp 0xfd25e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfd35f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x140(%rbp), %rdi
callq 0xa8d8
leaq -0x141(%rbp), %rdi
callq 0xa4c0
leaq -0x120(%rbp), %rdi
callq 0xa8d8
jmp 0xfe293
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfe287
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfe26f
jmp 0xfd3a0
movl -0x184(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x184(%rbp)
jmp 0xfd22b
leaq -0x1a8(%rbp), %rdi
movq %rdi, -0x8c8(%rbp)
callq 0xfec70
leaq -0x1c0(%rbp), %rdi
movq %rdi, -0x8d0(%rbp)
callq 0x99100
movq -0x8d0(%rbp), %rdx
movq -0x8c8(%rbp), %rcx
leaq -0x60(%rbp), %rdi
xorl %esi, %esi
callq 0xfae90
jmp 0xfd3f5
leaq -0x1d8(%rbp), %rdi
callq 0xfec90
leaq -0x1f0(%rbp), %rdi
callq 0x99100
leaq -0x208(%rbp), %rdi
callq 0x99100
leaq -0x220(%rbp), %rdi
callq 0x99100
leaq -0x238(%rbp), %rdi
callq 0x99100
leaq -0x250(%rbp), %rdi
callq 0x99100
leaq -0x268(%rbp), %rdi
callq 0x99100
callq 0x47d90
movl %eax, -0x26c(%rbp)
movl $0x0, -0x270(%rbp)
movslq -0x270(%rbp), %rax
movq %rax, -0x8d8(%rbp)
leaq -0x1a8(%rbp), %rdi
callq 0xfecb0
movq %rax, %rcx
movq -0x8d8(%rbp), %rax
cmpq %rcx, %rax
jae 0xfdf64
movl $0x38, %edi
callq 0xa450
movq %rax, -0x8e0(%rbp)
jmp 0xfd49e
xorl %eax, %eax
movl %eax, %esi
movq %rsi, -0x8e8(%rbp)
leaq -0x60(%rbp), %rdi
callq 0xa19e0
movq -0x8e0(%rbp), %rdi
movq -0x8e8(%rbp), %rdx
movq (%rax), %rsi
addq $0x8, %rsi
xorps %xmm0, %xmm0
callq 0xc5fe0
jmp 0xfd4d1
movq -0x8e0(%rbp), %rax
movq %rax, -0x278(%rbp)
xorl %eax, %eax
movl %eax, -0x8ec(%rbp)
movl %eax, %esi
leaq -0x60(%rbp), %rdi
callq 0xa19e0
movq (%rax), %rax
movq %rax, -0x900(%rbp)
movq -0x278(%rbp), %rax
movq %rax, -0x8f8(%rbp)
movslq -0x270(%rbp), %rsi
leaq -0x1a8(%rbp), %rdi
callq 0xfe560
movq -0x900(%rbp), %rdi
movq -0x8f8(%rbp), %rsi
movl -0x8ec(%rbp), %edx
movq %rax, %rcx
callq 0xfb050
jmp 0xfd53b
leaq -0x48(%rbp), %rdi
callq 0x9f690
movl %eax, -0x27c(%rbp)
leaq -0x60(%rbp), %rdi
callq 0x9f690
movl %eax, -0x280(%rbp)
movl -0x27c(%rbp), %eax
incl %eax
cltq
movq %rax, -0x910(%rbp)
leaq -0x2b1(%rbp), %rdi
movq %rdi, -0x908(%rbp)
callq 0x14c70
movq -0x910(%rbp), %rsi
movq -0x908(%rbp), %rdx
leaq -0x2b0(%rbp), %rdi
callq 0x14c90
jmp 0xfd599
leaq -0x2b2(%rbp), %rdi
movq %rdi, -0x918(%rbp)
callq 0x9a850
movq -0x910(%rbp), %rsi
movq -0x918(%rbp), %rcx
leaq -0x298(%rbp), %rdi
leaq -0x2b0(%rbp), %rdx
callq 0xfe6d0
jmp 0xfd5cf
leaq -0x2b2(%rbp), %rdi
callq 0x9ae50
leaq -0x2b0(%rbp), %rdi
callq 0x14b50
leaq -0x2b1(%rbp), %rdi
callq 0x14d00
movl -0x280(%rbp), %eax
incl %eax
cltq
movq %rax, -0x928(%rbp)
leaq -0x2e9(%rbp), %rdi
movq %rdi, -0x920(%rbp)
callq 0x14c70
movq -0x928(%rbp), %rsi
movq -0x920(%rbp), %rdx
leaq -0x2e8(%rbp), %rdi
callq 0x14c90
jmp 0xfd633
leaq -0x2ea(%rbp), %rdi
movq %rdi, -0x930(%rbp)
callq 0x9a850
movq -0x928(%rbp), %rsi
movq -0x930(%rbp), %rcx
leaq -0x2d0(%rbp), %rdi
leaq -0x2e8(%rbp), %rdx
callq 0xfe6d0
jmp 0xfd669
leaq -0x2ea(%rbp), %rdi
callq 0x9ae50
leaq -0x2e8(%rbp), %rdi
callq 0x14b50
leaq -0x2e9(%rbp), %rdi
callq 0x14d00
movl -0x27c(%rbp), %eax
incl %eax
cltq
movq %rax, -0x940(%rbp)
movl $0x1, -0x324(%rbp)
leaq -0x325(%rbp), %rdi
movq %rdi, -0x938(%rbp)
callq 0x14c70
movq -0x940(%rbp), %rsi
movq -0x938(%rbp), %rcx
leaq -0x320(%rbp), %rdi
leaq -0x324(%rbp), %rdx
callq 0xaef30
jmp 0xfd6de
leaq -0x326(%rbp), %rdi
movq %rdi, -0x948(%rbp)
callq 0x9a850
movq -0x940(%rbp), %rsi
movq -0x948(%rbp), %rcx
leaq -0x308(%rbp), %rdi
leaq -0x320(%rbp), %rdx
callq 0xfe6d0
jmp 0xfd714
leaq -0x326(%rbp), %rdi
callq 0x9ae50
leaq -0x320(%rbp), %rdi
callq 0x14b50
leaq -0x325(%rbp), %rdi
callq 0x14d00
movl -0x280(%rbp), %eax
incl %eax
cltq
movq %rax, -0x958(%rbp)
movl $0x1, -0x35c(%rbp)
leaq -0x35d(%rbp), %rdi
movq %rdi, -0x950(%rbp)
callq 0x14c70
movq -0x958(%rbp), %rsi
movq -0x950(%rbp), %rcx
leaq -0x358(%rbp), %rdi
leaq -0x35c(%rbp), %rdx
callq 0xaef30
jmp 0xfd789
leaq -0x35e(%rbp), %rdi
movq %rdi, -0x960(%rbp)
callq 0x9a850
movq -0x958(%rbp), %rsi
movq -0x960(%rbp), %rcx
leaq -0x340(%rbp), %rdi
leaq -0x358(%rbp), %rdx
callq 0xfe6d0
jmp 0xfd7bf
leaq -0x35e(%rbp), %rdi
callq 0x9ae50
leaq -0x358(%rbp), %rdi
callq 0x14b50
leaq -0x35d(%rbp), %rdi
callq 0x14d00
movl -0x27c(%rbp), %eax
incl %eax
cltq
movq %rax, -0x970(%rbp)
movl $0xffffffff, -0x394(%rbp) # imm = 0xFFFFFFFF
leaq -0x395(%rbp), %rdi
movq %rdi, -0x968(%rbp)
callq 0x14c70
movq -0x970(%rbp), %rsi
movq -0x968(%rbp), %rcx
leaq -0x390(%rbp), %rdi
leaq -0x394(%rbp), %rdx
callq 0xaef30
jmp 0xfd834
leaq -0x396(%rbp), %rdi
movq %rdi, -0x978(%rbp)
callq 0x9a850
movq -0x970(%rbp), %rsi
movq -0x978(%rbp), %rcx
leaq -0x378(%rbp), %rdi
leaq -0x390(%rbp), %rdx
callq 0xfe6d0
jmp 0xfd86a
leaq -0x396(%rbp), %rdi
callq 0x9ae50
leaq -0x390(%rbp), %rdi
callq 0x14b50
leaq -0x395(%rbp), %rdi
callq 0x14d00
movl -0x280(%rbp), %eax
incl %eax
cltq
movq %rax, -0x988(%rbp)
movl $0xffffffff, -0x3cc(%rbp) # imm = 0xFFFFFFFF
leaq -0x3cd(%rbp), %rdi
movq %rdi, -0x980(%rbp)
callq 0x14c70
movq -0x988(%rbp), %rsi
movq -0x980(%rbp), %rcx
leaq -0x3c8(%rbp), %rdi
leaq -0x3cc(%rbp), %rdx
callq 0xaef30
jmp 0xfd8df
leaq -0x3ce(%rbp), %rdi
movq %rdi, -0x990(%rbp)
callq 0x9a850
movq -0x988(%rbp), %rsi
movq -0x990(%rbp), %rcx
leaq -0x3b0(%rbp), %rdi
leaq -0x3c8(%rbp), %rdx
callq 0xfe6d0
jmp 0xfd915
leaq -0x3ce(%rbp), %rdi
callq 0x9ae50
leaq -0x3c8(%rbp), %rdi
callq 0x14b50
leaq -0x3cd(%rbp), %rdi
callq 0x14d00
movq -0x80(%rbp), %rdi
callq 0xa8ec0
movq %rax, -0x998(%rbp)
jmp 0xfd94b
movq -0x998(%rbp), %rdi
movl -0x27c(%rbp), %esi
leaq -0x298(%rbp), %rdx
leaq -0x308(%rbp), %rcx
leaq -0x378(%rbp), %r8
callq 0xfbbe0
jmp 0xfd974
movq -0x278(%rbp), %rdi
movl -0x280(%rbp), %esi
leaq -0x2d0(%rbp), %rdx
leaq -0x340(%rbp), %rcx
leaq -0x3b0(%rbp), %r8
callq 0xfbbe0
jmp 0xfd99d
movl -0x27c(%rbp), %eax
incl %eax
cltq
movq %rax, -0x9b8(%rbp)
movq %rax, -0x9b0(%rbp)
movl -0x280(%rbp), %eax
incl %eax
cltq
movq %rax, -0x9a8(%rbp)
movl $0xffffffff, -0x434(%rbp) # imm = 0xFFFFFFFF
leaq -0x435(%rbp), %rdi
movq %rdi, -0x9a0(%rbp)
callq 0x14c70
movq -0x9a8(%rbp), %rsi
movq -0x9a0(%rbp), %rcx
leaq -0x430(%rbp), %rdi
leaq -0x434(%rbp), %rdx
callq 0xaef30
jmp 0xfda06
leaq -0x436(%rbp), %rdi
movq %rdi, -0x9c0(%rbp)
callq 0x9a850
movq -0x9a8(%rbp), %rsi
movq -0x9c0(%rbp), %rcx
leaq -0x418(%rbp), %rdi
leaq -0x430(%rbp), %rdx
callq 0xfe6d0
jmp 0xfda3c
leaq -0x437(%rbp), %rdi
movq %rdi, -0x9c8(%rbp)
callq 0xfe750
movq -0x9b8(%rbp), %rsi
movq -0x9c8(%rbp), %rcx
leaq -0x400(%rbp), %rdi
leaq -0x418(%rbp), %rdx
callq 0xfe770
jmp 0xfda72
leaq -0x438(%rbp), %rdi
movq %rdi, -0x9d0(%rbp)
callq 0xfe7f0
movq -0x9b0(%rbp), %rsi
movq -0x9d0(%rbp), %rcx
leaq -0x3e8(%rbp), %rdi
leaq -0x400(%rbp), %rdx
callq 0xfe810
jmp 0xfdaa8
leaq -0x438(%rbp), %rdi
callq 0xfe890
leaq -0x400(%rbp), %rdi
callq 0xfe8b0
leaq -0x437(%rbp), %rdi
callq 0xfe910
leaq -0x418(%rbp), %rdi
callq 0x99530
leaq -0x436(%rbp), %rdi
callq 0x9ae50
leaq -0x430(%rbp), %rdi
callq 0x14b50
leaq -0x435(%rbp), %rdi
callq 0x14d00
movl -0x27c(%rbp), %ecx
movl -0x280(%rbp), %edx
movq %rsp, %rax
leaq -0x178(%rbp), %rsi
movq %rsi, 0x18(%rax)
movl %edx, 0x10(%rax)
movl %ecx, 0x8(%rax)
leaq -0x3b0(%rbp), %rcx
movq %rcx, (%rax)
leaq -0x3e8(%rbp), %rdi
leaq -0x298(%rbp), %rsi
leaq -0x2d0(%rbp), %rdx
leaq -0x308(%rbp), %rcx
leaq -0x340(%rbp), %r8
leaq -0x378(%rbp), %r9
callq 0xfbe50
movl %eax, -0x9d4(%rbp)
jmp 0xfdb5d
movl -0x9d4(%rbp), %eax
movl %eax, -0x43c(%rbp)
movl -0x43c(%rbp), %eax
cmpl -0x26c(%rbp), %eax
jge 0xfdea1
movl -0x43c(%rbp), %eax
movl %eax, -0x26c(%rbp)
leaq -0x1d8(%rbp), %rdi
leaq -0x3e8(%rbp), %rsi
callq 0xfece0
leaq -0x1f0(%rbp), %rdi
leaq -0x298(%rbp), %rsi
callq 0xfed10
leaq -0x208(%rbp), %rdi
leaq -0x2d0(%rbp), %rsi
callq 0xfed10
leaq -0x220(%rbp), %rdi
leaq -0x308(%rbp), %rsi
callq 0xfed10
leaq -0x238(%rbp), %rdi
leaq -0x340(%rbp), %rsi
callq 0xfed10
leaq -0x250(%rbp), %rdi
leaq -0x378(%rbp), %rsi
callq 0xfed10
leaq -0x268(%rbp), %rdi
leaq -0x3b0(%rbp), %rsi
callq 0xfed10
jmp 0xfdea1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfe257
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfe203
movq -0x8e0(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
movl $0x38, %esi
callq 0xa460
jmp 0xfe203
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfdc87
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x2b2(%rbp), %rdi
callq 0x9ae50
leaq -0x2b0(%rbp), %rdi
callq 0x14b50
leaq -0x2b1(%rbp), %rdi
callq 0x14d00
jmp 0xfe203
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfdcca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x2ea(%rbp), %rdi
callq 0x9ae50
leaq -0x2e8(%rbp), %rdi
callq 0x14b50
leaq -0x2e9(%rbp), %rdi
callq 0x14d00
jmp 0xfdf53
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfdd0d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x326(%rbp), %rdi
callq 0x9ae50
leaq -0x320(%rbp), %rdi
callq 0x14b50
leaq -0x325(%rbp), %rdi
callq 0x14d00
jmp 0xfdf47
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfdd50
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x35e(%rbp), %rdi
callq 0x9ae50
leaq -0x358(%rbp), %rdi
callq 0x14b50
leaq -0x35d(%rbp), %rdi
callq 0x14d00
jmp 0xfdf3b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfdd93
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x396(%rbp), %rdi
callq 0x9ae50
leaq -0x390(%rbp), %rdi
callq 0x14b50
leaq -0x395(%rbp), %rdi
callq 0x14d00
jmp 0xfdf2f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfddd6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x3ce(%rbp), %rdi
callq 0x9ae50
leaq -0x3c8(%rbp), %rdi
callq 0x14b50
leaq -0x3cd(%rbp), %rdi
callq 0x14d00
jmp 0xfdf23
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfdf17
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfde76
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfde5e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfde46
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x438(%rbp), %rdi
callq 0xfe890
leaq -0x400(%rbp), %rdi
callq 0xfe8b0
leaq -0x437(%rbp), %rdi
callq 0xfe910
leaq -0x418(%rbp), %rdi
callq 0x99530
leaq -0x436(%rbp), %rdi
callq 0x9ae50
leaq -0x430(%rbp), %rdi
callq 0x14b50
leaq -0x435(%rbp), %rdi
callq 0x14d00
jmp 0xfdf17
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x3e8(%rbp), %rdi
callq 0xfe930
jmp 0xfdf17
movq -0x278(%rbp), %rdi
callq 0xfc2d0
jmp 0xfdeaf
leaq -0x3e8(%rbp), %rdi
callq 0xfe930
leaq -0x3b0(%rbp), %rdi
callq 0x99530
leaq -0x378(%rbp), %rdi
callq 0x99530
leaq -0x340(%rbp), %rdi
callq 0x99530
leaq -0x308(%rbp), %rdi
callq 0x99530
leaq -0x2d0(%rbp), %rdi
callq 0x99530
leaq -0x298(%rbp), %rdi
callq 0x99530
movl -0x270(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x270(%rbp)
jmp 0xfd45e
leaq -0x3b0(%rbp), %rdi
callq 0x99530
leaq -0x378(%rbp), %rdi
callq 0x99530
leaq -0x340(%rbp), %rdi
callq 0x99530
leaq -0x308(%rbp), %rdi
callq 0x99530
leaq -0x2d0(%rbp), %rdi
callq 0x99530
leaq -0x298(%rbp), %rdi
callq 0x99530
jmp 0xfe203
movq -0x20(%rbp), %rsi
leaq -0x640(%rbp), %rdi
movl $0x10, %edx
callq 0xa890
jmp 0xfdf7b
movl $0x0, -0x654(%rbp)
movl $0x0, -0x658(%rbp)
movl $0x0, -0x65c(%rbp)
movl $0x0, -0x660(%rbp)
leaq -0x650(%rbp), %rdi
movq %rdi, -0x9e0(%rbp)
leaq -0x654(%rbp), %rsi
leaq -0x658(%rbp), %rdx
leaq -0x65c(%rbp), %rcx
leaq -0x660(%rbp), %r8
callq 0xfed40
movq -0x9e0(%rbp), %rcx
movq -0x28(%rbp), %rsi
movq -0x30(%rbp), %rdi
movzbl -0x89(%rbp), %edx
movq %rsp, %rax
movq %rdi, 0x28(%rax)
movq %rsi, 0x20(%rax)
leaq -0x640(%rbp), %rsi
movq %rsi, 0x18(%rax)
andl $0x1, %edx
movl %edx, 0x10(%rax)
movq %rcx, 0x8(%rax)
leaq -0x268(%rbp), %rcx
movq %rcx, (%rax)
leaq -0x1d8(%rbp), %rdi
leaq -0x1f0(%rbp), %rsi
leaq -0x208(%rbp), %rdx
leaq -0x220(%rbp), %rcx
leaq -0x238(%rbp), %r8
leaq -0x250(%rbp), %r9
callq 0xfc340
jmp 0xfe043
leaq -0x640(%rbp), %rdi
callq 0xa620
jmp 0xfe051
movq 0xa2ef8(%rip), %rdi     # 0x1a0f50
leaq 0x315b1(%rip), %rsi     # 0x12f610
callq 0xa440
movq %rax, -0x9e8(%rbp)
jmp 0xfe06d
movq -0x9e8(%rbp), %rdi
cvtsi2sdl -0x26c(%rbp), %xmm0
movsd 0x31564(%rip), %xmm1    # 0x12f5e8
divsd %xmm1, %xmm0
callq 0xa870
movq %rax, -0x9f0(%rbp)
jmp 0xfe096
movq -0x9f0(%rbp), %rdi
movq 0xa2ebc(%rip), %rsi     # 0x1a0f60
callq 0xa4a0
jmp 0xfe0ab
movq 0x10(%rbp), %rsi
leaq -0x860(%rbp), %rdi
movl $0x10, %edx
callq 0xa890
jmp 0xfe0c2
cvtsi2sdl -0x26c(%rbp), %xmm0
movsd 0x31516(%rip), %xmm1    # 0x12f5e8
divsd %xmm1, %xmm0
leaq -0x860(%rbp), %rdi
callq 0xa870
movq %rax, -0x9f8(%rbp)
jmp 0xfe0eb
movq -0x9f8(%rbp), %rdi
movq 0xa2e67(%rip), %rsi     # 0x1a0f60
callq 0xa4a0
jmp 0xfe100
leaq -0x860(%rbp), %rdi
callq 0xa620
jmp 0xfe10e
leaq -0x860(%rbp), %rdi
callq 0xa670
leaq -0x640(%rbp), %rdi
callq 0xa670
leaq -0x268(%rbp), %rdi
callq 0x99530
leaq -0x250(%rbp), %rdi
callq 0x99530
leaq -0x238(%rbp), %rdi
callq 0x99530
leaq -0x220(%rbp), %rdi
callq 0x99530
leaq -0x208(%rbp), %rdi
callq 0x99530
leaq -0x1f0(%rbp), %rdi
callq 0x99530
leaq -0x1d8(%rbp), %rdi
callq 0xfe930
leaq -0x1c0(%rbp), %rdi
callq 0x99530
leaq -0x1a8(%rbp), %rdi
callq 0xfe8b0
leaq -0x178(%rbp), %rdi
callq 0x99530
leaq -0x160(%rbp), %rdi
callq 0x994d0
leaq -0x100(%rbp), %rdi
callq 0xf2c0
leaq -0x60(%rbp), %rdi
callq 0xffe0
leaq -0x48(%rbp), %rdi
callq 0xffe0
addq $0xa30, %rsp            # imm = 0xA30
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
jmp 0xfe1f7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x860(%rbp), %rdi
callq 0xa670
leaq -0x640(%rbp), %rdi
callq 0xa670
leaq -0x268(%rbp), %rdi
callq 0x99530
leaq -0x250(%rbp), %rdi
callq 0x99530
leaq -0x238(%rbp), %rdi
callq 0x99530
leaq -0x220(%rbp), %rdi
callq 0x99530
leaq -0x208(%rbp), %rdi
callq 0x99530
leaq -0x1f0(%rbp), %rdi
callq 0x99530
leaq -0x1d8(%rbp), %rdi
callq 0xfe930
leaq -0x1c0(%rbp), %rdi
callq 0x99530
leaq -0x1a8(%rbp), %rdi
callq 0xfe8b0
leaq -0x178(%rbp), %rdi
callq 0x99530
leaq -0x160(%rbp), %rdi
callq 0x994d0
leaq -0x100(%rbp), %rdi
callq 0xf2c0
leaq -0x60(%rbp), %rdi
callq 0xffe0
leaq -0x48(%rbp), %rdi
callq 0xffe0
movq -0x70(%rbp), %rdi
callq 0xa7c0
nop