// File: /workspace/github_cpp_makefile_star2_O1/iPapatsoris[P]Maximum-Independent-Set/src/Alg.hpp
// Function: Alg::BranchingRule::getOptimalNode(Graph const&, unsigned int const&)
void getOptimalNode(const Graph &graph, const uint32_t &theta) {
            bool found = false;
            uint32_t count = 0;
            Graph::GraphTraversal graphTraversal(graph);
            while (graphTraversal.curNode != NONE) {
                if (graph.getNodeDegree(graphTraversal.curNode) == theta) {
                    count++;
                    uint32_t node = graphTraversal.curNode;
                    switch (theta) {
                        case 8: {
                            uint32_t degree8Neighbors = graph.getNumberOfDegreeNeighbors(node, 8);
                            if (degree8Neighbors <= 7) {
                                found = true;
                            } else if (degree8Neighbors == 8 && getMeasure(graph, node) >= 36) {
                                found = true;
                            }
                            break;
                        }
                        case 7: {
                            std::unordered_set<uint32_t> extendedGrandchildren;
                            graph.getExtendedGrandchildren(graphTraversal, extendedGrandchildren, NULL, true);
                            if (extendedGrandchildren.size()) {
                                found = true;
                            } else {
                                uint32_t degree7Neighbors = graph.getNumberOfDegreeNeighbors(node, 7);
                                if (degree7Neighbors <= 5) {
                                    found = true;
                                } else {
                                    uint32_t measure = getMeasure(graph, node);
                                    if (degree7Neighbors == 6 && measure >= 22 - 2 * graph.getNumberOfDegreeNeighbors(node, 3) - graph.getNumberOfDegreeNeighbors(node, 4) ||
                                    degree7Neighbors == 7 && measure >= 26) {
                                        found = true;
                                    }
                                }
                            }
                            break;
                        }
                        case 6: {
                            if (graph.getNumberOfDegreeNeighbors(node, 3) >= 1) {
                                found = true;
                            } else {
                                uint32_t degree6Neighbors = graph.getNumberOfDegreeNeighbors(node, 6);
                                if (degree6Neighbors <= 3) {
                                    found = true;
                                } else {
                                    uint32_t degree5Neighbors = graph.getNumberOfDegreeNeighbors(node, 5);
                                    if (degree6Neighbors == 4 && degree5Neighbors <= 1) {
                                        found = true;
                                    } else {
                                        std::unordered_set<uint32_t> neighborsAtDistance2;
                                        uint32_t count = 0;
                                        graph.getNeighborsAtDistance2(node, neighborsAtDistance2, theta, &count);
                                        uint32_t measure = getMeasure(graph, node, &neighborsAtDistance2);
                                        measure += count;
                                        if (degree6Neighbors == 4 && degree5Neighbors == 2 && measure >= 17 ||
                                        degree6Neighbors == 5 && graph.getNumberOfDegreeNeighbors(node, 4) == 1 && measure >= 18 ||
                                        degree6Neighbors == 5 && degree5Neighbors == 1 && measure >= 19 ||
                                        degree6Neighbors == 6 && measure >= 22) {
                                            found = true;
                                        }
                                    }
                                }
                            }
                            break;
                        }
                        default:
                            assert(false);
                    }
                    if (found) {
                        break;
                    }
                }
                graph.getNextNode(graphTraversal);
            }
            assert(found);
            node1 = graphTraversal.curNode;
        }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdx, 0x20(%rsp)
movq %rsi, %r15
movq %rdi, 0x60(%rsp)
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
callq 0x29d8
cmpl $-0x1, (%rbx)
je 0x16d46
xorl %ebp, %ebp
leaq 0x10(%rsp), %r12
leaq 0x4(%rsp), %r13
movq %r15, %rdi
movq %r12, %rsi
callq 0xc98e
movq 0x20(%rsp), %rcx
movl (%rcx), %ecx
cmpl %ecx, %eax
jne 0x16a42
movl 0x10(%rsp), %eax
movl %eax, 0x4(%rsp)
cmpl $0x6, %ecx
je 0x16b52
cmpl $0x7, %ecx
je 0x16a49
cmpl $0x8, %ecx
jne 0x16d27
movl $0x8, 0x28(%rsp)
movl $0x0, (%rsp)
movq %r15, %rdi
movq %r13, %rsi
leaq 0x28(%rsp), %rdx
movq %rsp, %rcx
callq 0x2b5a
movb $0x1, %bl
cmpl $0x8, %eax
jb 0x16cd4
jne 0x16cd2
movq %r15, %rdi
leaq 0x4(%rsp), %rsi
xorl %edx, %edx
callq 0x16d88
cmpl $0x24, %eax
movzbl %bpl, %ebx
movl $0x1, %eax
cmovael %eax, %ebx
jmp 0x16cd4
movl %ebp, %ebx
jmp 0x16ce0
leaq 0x58(%rsp), %rax
movq %rax, 0x28(%rsp)
movq $0x1, 0x30(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, -0x20(%rax)
movl $0x3f800000, 0x48(%rsp) # imm = 0x3F800000
movups %xmm0, -0x8(%rax)
movb $0x1, (%rsp)
movq %r15, %rdi
movq %r12, %rsi
leaq 0x28(%rsp), %rdx
xorl %ecx, %ecx
movq %rsp, %r8
callq 0x3f60
cmpq $0x0, 0x40(%rsp)
jne 0x16cc5
movl $0x7, (%rsp)
movl $0x0, 0x8(%rsp)
movq %r15, %rdi
movq %r13, %rsi
movq %rsp, %rdx
leaq 0x8(%rsp), %rcx
callq 0x2b5a
movl %eax, %ebx
cmpl $0x6, %eax
jb 0x16cc5
movq %r15, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x16d88
movl %eax, %r13d
cmpl $0x6, %ebx
jne 0x16b38
movl $0x3, (%rsp)
movl $0x0, 0x8(%rsp)
movq %r15, %rdi
leaq 0x4(%rsp), %rsi
movq %rsp, %rdx
leaq 0x8(%rsp), %rcx
callq 0x2b5a
movl %eax, %r14d
movl $0x4, 0xc(%rsp)
movl $0x0, 0x1c(%rsp)
movq %r15, %rdi
leaq 0x4(%rsp), %rsi
leaq 0xc(%rsp), %rdx
leaq 0x1c(%rsp), %rcx
callq 0x2b5a
leal (%rax,%r14,2), %eax
movl $0x16, %ecx
subl %eax, %ecx
cmpl %ecx, %r13d
jae 0x16cc5
cmpl $0x7, %ebx
sete %al
cmpl $0x1a, %r13d
setae %cl
testb %cl, %al
jne 0x16cc5
jmp 0x16cc8
movl $0x3, 0x28(%rsp)
movl $0x0, (%rsp)
movq %r15, %rdi
movq %r13, %rsi
leaq 0x28(%rsp), %r14
movq %r14, %rdx
movq %rsp, %r12
movq %r12, %rcx
callq 0x2b5a
movb $0x1, %bl
testl %eax, %eax
jne 0x16ba5
movl $0x6, 0x28(%rsp)
movl $0x0, (%rsp)
movq %r15, %rdi
movq %r13, %rsi
movq %r14, %rdx
movq %r12, %rcx
callq 0x2b5a
cmpl $0x4, %eax
jae 0x16baf
leaq 0x10(%rsp), %r12
jmp 0x16cd4
movq %r13, %rsi
movl %eax, %r13d
movl $0x5, 0x28(%rsp)
movl $0x0, (%rsp)
movq %r15, %rdi
movq %r14, %rdx
movq %r12, %rcx
callq 0x2b5a
cmpl $0x4, %r13d
sete %dl
movl %eax, 0x18(%rsp)
cmpl $0x2, %eax
setb %cl
testb %cl, %dl
leaq 0x10(%rsp), %r12
jne 0x16cd4
leaq 0x58(%rsp), %rax
movq %rax, 0x28(%rsp)
movq $0x1, 0x30(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, -0x20(%rax)
movl $0x3f800000, 0x48(%rsp) # imm = 0x3F800000
movups %xmm0, -0x8(%rax)
movl $0x0, (%rsp)
movq %r15, %rdi
leaq 0x4(%rsp), %rbx
movq %rbx, %rsi
leaq 0x28(%rsp), %r14
movq %r14, %rdx
movq 0x20(%rsp), %rcx
movq %rsp, %r8
callq 0x2c84
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x16d88
movl %eax, %ebx
movl %r13d, %eax
addl (%rsp), %ebx
xorl $0x4, %eax
movl 0x18(%rsp), %ecx
xorl $0x2, %ecx
orl %eax, %ecx
sete %al
cmpl $0x11, %ebx
setae %cl
testb %cl, %al
jne 0x16cc5
cmpl $0x5, %r13d
jne 0x16ca9
movl $0x4, 0x8(%rsp)
movl $0x0, 0xc(%rsp)
movq %r15, %rdi
leaq 0x4(%rsp), %rsi
leaq 0x8(%rsp), %rdx
leaq 0xc(%rsp), %rcx
callq 0x2b5a
cmpl $0x1, %eax
sete %al
cmpl $0x12, %ebx
setae %cl
testb %cl, %al
jne 0x16cc5
movl %r13d, %eax
xorl $0x5, %eax
movl 0x18(%rsp), %ecx
xorl $0x1, %ecx
orl %eax, %ecx
sete %al
cmpl $0x13, %ebx
setae %cl
testb %cl, %al
je 0x16cf8
movb $0x1, %bpl
leaq 0x28(%rsp), %rdi
callq 0xcff8
movl %ebp, %ebx
movl %ebx, %ebp
testb $0x1, %bl
leaq 0x4(%rsp), %r13
jne 0x16d07
movq %r15, %rdi
movq %r12, %rsi
callq 0xc034
cmpl $-0x1, 0x10(%rsp)
jne 0x169b7
jmp 0x16d07
cmpl $0x6, %r13d
sete %al
cmpl $0x16, %ebx
jmp 0x16b42
testb $0x1, %bl
je 0x16d46
movl 0x10(%rsp), %eax
movq 0x60(%rsp), %rcx
movl %eax, 0x4(%rcx)
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x3b9d(%rip), %rdi      # 0x1a8cb
leaq 0x3d94(%rip), %rsi      # 0x1aac9
leaq 0x3df0(%rip), %rcx      # 0x1ab2c
movl $0xef, %edx
callq 0x2110
leaq 0x3e28(%rip), %rdi      # 0x1ab75
leaq 0x3d75(%rip), %rsi      # 0x1aac9
leaq 0x3dd1(%rip), %rcx      # 0x1ab2c
movl $0xf7, %edx
callq 0x2110
jmp 0x16d73
jmp 0x16d73
jmp 0x16d73
jmp 0x16d73
jmp 0x16d73
jmp 0x16d73
jmp 0x16d73
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xcff8
movq %rbx, %rdi
callq 0x2320