// File: /workspace/github_cpp_makefile_star2_O3/canzarlab[P]Trajan/src/LP.cpp
// Function: LP::MatchingConstraints()
void LP::MatchingConstraints()
{
    cnt = 0;
    vb P(t1.GetNumNodes());
    int n = t1.GetNumNodes(), m = t2.GetNumNodes();
    DFSLeft(t1.GetRoot(), P, [&](newick_node* nodel, newick_node* noder, double w)
    {
        if (w != 0 && (dag || (nodel->parent && nodel->child && noder->parent && noder->child)))
        {
            int i = nodel->taxoni, j = noder->taxoni;
            int col = i * m + j - cnt;
            K[i][j] = col;
            Triplets.emplace_back(i, col, 1.);
            Triplets.emplace_back(n + j, col, 1.);
            c(col) = w;
        }
        else
            ++cnt;
    });
    nr_rows = n + m;
    nr_cols = n * m - cnt;
    c.conservativeResize(nr_cols);
    // set warm_x and warm_y initialy to zeroes
    warm_x = Vector::Zero(nr_cols);
    warm_y = Vector::Zero(nr_rows);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
movl $0x0, 0x110(%rdi)
movq 0x30(%rdi), %rax
movslq 0x70(%rax), %rsi
leaq 0x1c(%rsp), %r14
movb $0x0, (%r14)
leaq 0x38(%rsp), %r15
leaq 0x18(%rsp), %r12
movq %r15, %rdi
movq %r14, %rdx
movq %r12, %rcx
callq 0x306d4
movq 0x30(%rbx), %rax
movl 0x70(%rax), %ecx
movl %ecx, (%r14)
movq 0x38(%rbx), %rcx
movl 0x70(%rcx), %ecx
movl %ecx, (%r12)
movq 0x68(%rax), %rsi
movq %rbx, 0x20(%rsp)
movq %r12, 0x28(%rsp)
movq %r14, 0x30(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movups 0x20(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %rbx, %rdi
movq %r15, %rdx
callq 0x3488a
movl 0x1c(%rsp), %eax
movl 0x18(%rsp), %ecx
leal (%rcx,%rax), %edx
movl %edx, 0x108(%rbx)
imull %eax, %ecx
movslq 0x110(%rbx), %rax
movslq %ecx, %rdx
subq %rax, %rdx
movl %edx, 0x10c(%rbx)
leaq 0xf8(%rbx), %rdi
movl $0x1, %ecx
movq %rdx, %rsi
callq 0x379dc
movslq 0x10c(%rbx), %r14
testq %r14, %r14
js 0x34793
leaq 0xa0(%rbx), %r15
cmpq %r14, 0xa8(%rbx)
je 0x34675
movl $0x1, %ecx
movq %r15, %rdi
movq %r14, %rsi
movq %r14, %rdx
callq 0xff4c
cmpq %r14, 0xa8(%rbx)
jne 0x347b2
movl %r14d, %r12d
movq (%r15), %r15
movl %r12d, %ebp
andl $0x7ffffffe, %ebp       # imm = 0x7FFFFFFE
cmpl $0x2, %r12d
jb 0x346af
cmpl $0x3, %ebp
movl $0x2, %eax
cmovael %ebp, %eax
leaq -0x8(,%rax,8), %rdx
andq $-0x10, %rdx
addq $0x10, %rdx
movq %r15, %rdi
xorl %esi, %esi
callq 0x91c0
cmpl %r14d, %ebp
je 0x346d2
shrl %r12d
shlq $0x4, %r12
addq %r12, %r15
shlq $0x3, %r14
subq %r12, %r14
movq %r15, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x91c0
movslq 0x108(%rbx), %r14
testq %r14, %r14
js 0x34793
leaq 0xb0(%rbx), %r15
cmpq %r14, 0xb8(%rbx)
je 0x34712
movl $0x1, %ecx
movq %r15, %rdi
movq %r14, %rsi
movq %r14, %rdx
callq 0xff4c
cmpq %r14, 0xb8(%rbx)
jne 0x347b2
movl %r14d, %r12d
movq (%r15), %rbx
movl %r12d, %ebp
andl $0x7ffffffe, %ebp       # imm = 0x7FFFFFFE
cmpl $0x2, %r12d
jb 0x3474c
cmpl $0x3, %ebp
movl $0x2, %eax
cmovael %ebp, %eax
leaq -0x8(,%rax,8), %rdx
andq $-0x10, %rdx
addq $0x10, %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x91c0
cmpl %r14d, %ebp
je 0x3476f
shrl %r12d
shlq $0x4, %r12
addq %r12, %rbx
shlq $0x3, %r14
subq %r12, %r14
movq %rbx, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x91c0
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x34786
movq 0x58(%rsp), %rsi
subq %rdi, %rsi
callq 0x9350
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x27dc2(%rip), %rdi     # 0x5c55c
leaq 0x27e50(%rip), %rsi     # 0x5c5f1
leaq 0x28c44(%rip), %rcx     # 0x5d3ec
movl $0x4a, %edx
callq 0x9200
leaq 0x288c7(%rip), %rdi     # 0x5d080
leaq 0x27d79(%rip), %rsi     # 0x5c539
leaq 0x28d1c(%rip), %rcx     # 0x5d4e3
movl $0x2d1, %edx            # imm = 0x2D1
callq 0x9200
jmp 0x347d5
jmp 0x347d5
movq %rax, %rbx
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x347ef
movq 0x58(%rsp), %rsi
subq %rdi, %rsi
callq 0x9350
movq %rbx, %rdi
callq 0x9680
nop