LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/Board.cpp
// Function: Board::set_move_decider(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
void Board::set_move_decider(const std::string &solver)
{
    std::string base = basename_str(solver);
    if (base == "random") {
        decider = &Board::decide_move_random;
    } else if (base == "first") {
        decider = &Board::decide_move_first;
    } else if (base == "invalid") {
        decider = &Board::decide_move_invalid;
    } else if (base == "timeout") {
        decider = &Board::decide_move_timeout;
    } else if (base == "crash") {
        exit(1);
    } else if (base == "nocheap") {
        decider = &Board::decide_move_nocheap;
    } else {
        fprintf(stderr, "dots solver run with command: %s, cannot decide which move decider to use\n", base.c_str());
        exit(1);
    }
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x28e0
leaq 0x29e2(%rip), %rsi      # 0x531e
movq %r14, %rdi
callq 0x2bb7
testb %al, %al
je 0x2954
leaq 0x124d(%rip), %rax      # 0x3b9c
jmp 0x29df
leaq 0x2702(%rip), %rsi      # 0x505d
leaq 0x8(%rsp), %rdi
callq 0x2bb7
testb %al, %al
je 0x2972
leaq 0x1314(%rip), %rax      # 0x3c84
jmp 0x29df
leaq 0x26ea(%rip), %rsi      # 0x5063
leaq 0x8(%rsp), %rdi
callq 0x2bb7
testb %al, %al
je 0x2990
leaq 0x1356(%rip), %rax      # 0x3ce4
jmp 0x29df
leaq 0x26d4(%rip), %rsi      # 0x506b
leaq 0x8(%rsp), %rdi
callq 0x2bb7
testb %al, %al
je 0x29ae
leaq 0x133e(%rip), %rax      # 0x3cea
jmp 0x29df
leaq 0x26be(%rip), %rsi      # 0x5073
leaq 0x8(%rsp), %rdi
callq 0x2bb7
testb %al, %al
jne 0x2a17
leaq 0x26af(%rip), %rsi      # 0x5079
leaq 0x8(%rsp), %rdi
callq 0x2bb7
testb %al, %al
je 0x29fa
leaq 0x1327(%rip), %rax      # 0x3d06
movq %rax, 0x38(%rbx)
andq $0x0, 0x40(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x20e0
addq $0x28, %rsp
popq %rbx
popq %r14
retq
movq 0x55d7(%rip), %rax      # 0x7fd8
movq (%rax), %rdi
movq 0x8(%rsp), %rdx
leaq 0x2671(%rip), %rsi      # 0x5081
xorl %eax, %eax
callq 0x2290
pushq $0x1
popq %rdi
callq 0x2250
nop
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/InputOutput.cpp
// Function: read_edge(_IO_FILE*)
Edge read_edge(FILE *fp)
{
    int fd = fileno(fp);

    pollfd pev;
    pev.fd = fd;
    pev.events = POLLIN;
    pev.revents = 0;

    int pollret = poll(&pev, 1, 1000);
    if (pollret == 0) {
        throw std::runtime_error("took too long to move");
    } else if (pollret == -1) {
        printf("error poll'ing fd\n");
        exit(1);
    }

    fcntl(fd, F_SETFL, O_NONBLOCK);
    char buf[80] = {};
    ssize_t nbytes = read(fd, buf, sizeof(buf) - 1);
    fcntl(fd, F_SETFL, 0);

    if (nbytes == 0)
        throw std::runtime_error("exited early");

    char tmp;
    Edge move;
    int x, y;
    sscanf(buf, "(edge %c %d %d)\n", &tmp, &x, &y);

    move.x = x;
    move.y = y;

    if (tmp == 'h')
        move.dir = HORIZ;
    else
        move.dir = VERT;

    return move;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x78, %rsp
callq 0x21f0
movl %eax, %ebx
leaq 0x18(%rsp), %rdi
movl %eax, (%rdi)
movl $0x1, 0x4(%rdi)
pushq $0x1
popq %rsi
movl $0x3e8, %edx            # imm = 0x3E8
callq 0x22c0
cmpl $-0x1, %eax
je 0x2f61
testl %eax, %eax
je 0x2f75
pushq $0x4
popq %rbp
movl %ebx, %edi
movl %ebp, %esi
movl $0x800, %edx            # imm = 0x800
xorl %eax, %eax
callq 0x2120
xorps %xmm0, %xmm0
leaq 0x20(%rsp), %rsi
movaps %xmm0, 0x40(%rsi)
movaps %xmm0, 0x30(%rsi)
movaps %xmm0, 0x20(%rsi)
movaps %xmm0, 0x10(%rsi)
movaps %xmm0, (%rsi)
pushq $0x4f
popq %rdx
movl %ebx, %edi
callq 0x22a0
movq %rax, %r14
movl %ebx, %edi
movl %ebp, %esi
xorl %edx, %edx
xorl %eax, %eax
callq 0x2120
testq %r14, %r14
je 0x2f91
leaq 0x21e0(%rip), %rsi      # 0x50f6
leaq 0x20(%rsp), %rdi
leaq 0xf(%rsp), %rbx
leaq 0x14(%rsp), %r14
leaq 0x10(%rsp), %r15
movq %rbx, %rdx
movq %r14, %rcx
movq %r15, %r8
xorl %eax, %eax
callq 0x21c0
movl (%r14), %eax
andl $0x7f, %eax
movl (%r15), %ecx
shll $0x8, %ecx
xorl %edx, %edx
cmpb $0x68, (%rbx)
setne %dl
movzwl %cx, %ecx
leal (%rcx,%rax,2), %eax
orl %edx, %eax
addq $0x78, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x239e(%rip), %rdi      # 0x5306
callq 0x22d0
pushq $0x1
popq %rdi
callq 0x2250
pushq $0x10
popq %rdi
callq 0x20f0
movq %rax, %rbx
leaq 0x2180(%rip), %rsi      # 0x5107
movq %rax, %rdi
callq 0x20b0
jmp 0x2fab
pushq $0x10
popq %rdi
callq 0x20f0
movq %rax, %rbx
leaq 0x217a(%rip), %rsi      # 0x511d
movq %rax, %rdi
callq 0x20b0
movq 0x5046(%rip), %rsi      # 0x7ff8
movq 0x5017(%rip), %rdx      # 0x7fd0
movq %rbx, %rdi
callq 0x2340
jmp 0x2fc3
movq %rax, %r14
movq %rbx, %rdi
callq 0x2160
movq %r14, %rdi
callq 0x2350
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/InputOutput.cpp
// Function: Board::print_horiz_edges(int, _IO_FILE*) const
void Board::print_horiz_edges(int y, FILE *fp) const
{
    fprintf(fp, "+");
    for (int x = 0; x < width; ++x) {
        if (edges[edge_index(Edge(HORIZ, x, y))])
            fprintf(fp, "-+");
        else
            fprintf(fp, " +");
    }
    fprintf(fp, "\n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
pushq $0x2b
popq %rdi
movq %rdx, %rsi
callq 0x2260
leaq 0x10(%r14), %r15
shll $0x8, %ebp
movzwl %bp, %ebp
xorl %r12d, %r12d
xorl %r13d, %r13d
cmpl (%r14), %r13d
jge 0x3078
movl %r12d, %esi
andl $0xfe, %esi
orl %ebp, %esi
movq %r14, %rdi
callq 0x2b26
movslq %eax, %rsi
movq %r15, %rdi
callq 0x2b5e
testb %al, %al
leaq 0x20e5(%rip), %rdi      # 0x513b
leaq 0x20db(%rip), %rax      # 0x5138
cmovneq %rax, %rdi
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
callq 0x23b0
incl %r13d
addl $0x2, %r12d
jmp 0x302a
pushq $0xa
popq %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2260
nop
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/InputOutput.cpp
// Function: Board::print_vert_edges(int, _IO_FILE*) const
void Board::print_vert_edges(int y, FILE *fp) const
{
    for (int x = 0; x < width; ++x) {
        if (edges[edge_index(Edge(VERT, x, y))])
            fprintf(fp, "|");
        else
            fprintf(fp, " ");

        if (degree(Node(x, y)) == 4)
            fprintf(fp, "#");
        else
            fprintf(fp, " ");
    }

    if (edges[edge_index(Edge(VERT, width, y))])
        fprintf(fp, "|\n");
    else
        fprintf(fp, " \n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r15
leaq 0x10(%rdi), %rax
movq %rax, (%rsp)
shll $0x8, %esi
movzwl %si, %ebp
xorl %r12d, %r12d
movl $0xff, %r13d
xorl %r14d, %r14d
movl (%r15), %eax
cmpl %eax, %r14d
jge 0x3126
movl %r12d, %esi
andl %r13d, %esi
orl %ebp, %esi
orl $0x1, %esi
movq %r15, %rdi
callq 0x2b26
movslq %eax, %rsi
movq (%rsp), %rdi
callq 0x2b5e
testb %al, %al
pushq $0x20
popq %rdi
pushq $0x7c
popq %rax
cmovnel %eax, %edi
movq %rbx, %rsi
callq 0x2260
movl %r14d, %esi
andl %r13d, %esi
orl %ebp, %esi
movq %r15, %rdi
callq 0x2838
xorl %ecx, %ecx
cmpl $0x4, %eax
sete %cl
leal (%rcx,%rcx,2), %edi
addl $0x20, %edi
movq %rbx, %rsi
callq 0x2260
incl %r14d
addl $0x2, %r12d
jmp 0x30bd
addl %eax, %eax
movzbl %al, %eax
orl %eax, %ebp
orl $0x1, %ebp
movq %r15, %rdi
movl %ebp, %esi
callq 0x2b26
movslq %eax, %rsi
movq (%rsp), %rdi
callq 0x2b5e
leaq 0x1ff1(%rip), %rcx      # 0x513e
leaq 0x1fed(%rip), %rdi      # 0x5141
testb %al, %al
cmovneq %rcx, %rdi
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x23b0
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/InputOutput.cpp
// Function: Board::print(_IO_FILE*, int) const
void Board::print(FILE *fp, int player) const
{
    fprintf(fp, "%d %d %d %d\n", width, height, score[player], score[!player]);
    for (int y = 0; y < height; ++y) {
        print_horiz_edges(y, fp);
        print_vert_edges(y, fp);
    }
    print_horiz_edges(height, fp);
    fflush(fp);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movl (%rdi), %eax
movl 0x4(%rdi), %ecx
movslq %edx, %rdx
movl 0x8(%rdi,%rdx,4), %r8d
xorl %esi, %esi
testl %edx, %edx
sete %sil
movl 0x8(%rdi,%rsi,4), %r9d
leaq 0x1fa3(%rip), %rsi      # 0x5144
xorl %ebp, %ebp
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0x2290
movl 0x4(%r14), %esi
cmpl %esi, %ebp
jge 0x31d5
movq %r14, %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x2ffc
movq %r14, %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x3092
incl %ebp
jmp 0x31af
movq %r14, %rdi
movq %rbx, %rdx
callq 0x2ffc
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/InputOutput.cpp
// Function: Board::read_horiz_edges(int, _IO_FILE*)
void Board::read_horiz_edges(int y, FILE *fp)
{
    int c, x = 0;

    while ((c = fgetc(fp)) != EOF) {
        switch (c) {
            case '\r':
                break;
            case '\n':
                if (x != width) {
                    fprintf(stderr, "x (%d) != width (%d) at newline while reading board\n",
                            x, width);
                    exit(1);
                }
                return;
            case '+':
                break;
            case '-':
                if (x >= width) {
                    fprintf(stderr, "x (%d) >= width (%d) at dash while reading board\n",
                            x, width);
                    exit(1);
                }
                edges[edge_index(Edge(HORIZ, x, y))] = true;
                ++x;
                break;
            case ' ':
                if (x >= width) {
                    fprintf(stderr, "x (%d) >= width (%d) at space while reading board\n",
                            x, width);
                    exit(1);
                }
                edges[edge_index(Edge(HORIZ, x, y))] = false;
                ++x;
                break;
            default:
                fprintf(stderr, "unexpected character %d while reading board\n", c);
                exit(1);
        }
    }

    if (c == EOF)
        exit(0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rdi, %r15
leaq 0x10(%rdi), %r12
shll $0x8, %esi
movzwl %si, %ebp
xorl %ebx, %ebx
movq %r14, %rdi
callq 0x2300
cmpl $0xd, %eax
je 0x3206
cmpl $0x2b, %eax
je 0x3206
cmpl $0xa, %eax
je 0x3282
cmpl $0x20, %eax
je 0x3252
cmpl $0x2d, %eax
jne 0x3292
movl (%r15), %ecx
cmpl %ecx, %ebx
jge 0x32d3
leal (%rbx,%rbx), %eax
movzbl %al, %esi
orl %ebp, %esi
movq %r15, %rdi
callq 0x2b26
movslq %eax, %rsi
movq %r12, %rdi
callq 0x2b08
orq %rdx, (%rax)
jmp 0x327e
movl (%r15), %ecx
cmpl %ecx, %ebx
jge 0x32e6
leal (%rbx,%rbx), %eax
movzbl %al, %esi
orl %ebp, %esi
movq %r15, %rdi
callq 0x2b26
movslq %eax, %rsi
movq %r12, %rdi
callq 0x2b08
notq %rdx
andq %rdx, (%rax)
incl %ebx
jmp 0x3206
movl (%r15), %ecx
cmpl %ecx, %ebx
jne 0x32c0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
cmpl $-0x1, %eax
jne 0x329e
xorl %edi, %edi
callq 0x2250
movq 0x4d33(%rip), %rcx      # 0x7fd8
movq (%rcx), %rdi
leaq 0x1f3c(%rip), %rsi      # 0x51eb
movl %eax, %edx
xorl %eax, %eax
callq 0x2290
pushq $0x1
popq %rdi
callq 0x2250
movq 0x4d11(%rip), %rax      # 0x7fd8
movq (%rax), %rdi
leaq 0x1e80(%rip), %rsi      # 0x5151
jmp 0x32f7
movq 0x4cfe(%rip), %rax      # 0x7fd8
movq (%rax), %rdi
leaq 0x1ea2(%rip), %rsi      # 0x5186
jmp 0x32f7
movq 0x4ceb(%rip), %rax      # 0x7fd8
movq (%rax), %rdi
leaq 0x1ec1(%rip), %rsi      # 0x51b8
movl %ebx, %edx
xorl %eax, %eax
callq 0x2290
jmp 0x32b8
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/InputOutput.cpp
// Function: read_board(_IO_FILE*)
Board read_board(FILE *fp)
{
    Board board;

    fscanf(fp, "%d %d %d %d\n", &board.height, &board.width,
            &board.score[0], &board.score[1]);
    if (feof(fp))
        exit(0);

    board.edges.assign(board.width * (board.height + 1) + board.height * (board.width + 1), false);

    for (int y = 0; y < board.height; ++y) {
        board.read_horiz_edges(y, fp);
        board.read_vert_edges(y, fp);
    }
    board.read_horiz_edges(board.height, fp);

    if (feof(fp))
        exit(0);

    return board;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %r14
andq $0x0, 0x10(%rdi)
andl $0x0, 0x18(%rdi)
andq $0x0, 0x20(%rdi)
andl $0x0, 0x28(%rdi)
movq %rsi, %r15
andq $0x0, 0x30(%rdi)
leaq 0x10(%rdi), %rbx
leaq 0x4(%rdi), %r12
leaq 0x8(%rdi), %r8
leaq 0xc(%rdi), %r9
leaq 0x1cbf(%rip), %rsi      # 0x5144
movq %r15, %rdi
movq %r12, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x2390
movq %r15, %rdi
callq 0x22e0
testl %eax, %eax
jne 0x350d
movl (%r14), %eax
movl 0x4(%r14), %ecx
leal 0x1(%rcx), %edx
imull %eax, %edx
incl %eax
imull %ecx, %eax
addl %edx, %eax
movslq %eax, %rsi
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %edx, %edx
callq 0x358e
movl (%r12), %esi
cmpl %esi, %ebp
jge 0x34ea
movq %r14, %rdi
movl %ebp, %esi
movq %r15, %rdx
callq 0x31ec
movq %r14, %rdi
movl %ebp, %esi
movq %r15, %rdx
callq 0x3302
incl %ebp
jmp 0x34c4
movq %r14, %rdi
movq %r15, %rdx
callq 0x31ec
movq %r15, %rdi
callq 0x22e0
testl %eax, %eax
jne 0x350d
movq %r14, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
xorl %edi, %edi
callq 0x2250
jmp 0x3518
jmp 0x3518
movq %rax, %r14
movq %rbx, %rdi
callq 0x2c44
movq %r14, %rdi
callq 0x2350
nop
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/BasicMoveDeciders.cpp
// Function: Board::decide_move_random()
Edge Board::decide_move_random()
{
    std::vector<Edge> valid_moves;

    std::for_each(edge_begin(), edge_end(), [&] (Edge edge)
            { if (this->is_move_valid(edge)) valid_moves.push_back(edge); });

    int r = 0;

    int fd = open("/dev/urandom", O_RDONLY);
    read(fd, &r, sizeof(r));
    close(fd);

    return valid_moves[r % valid_moves.size()];
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %r14
movaps %xmm0, (%r14)
andq $0x0, 0x10(%r14)
movl (%rdi), %eax
movl 0x4(%rdi), %ecx
shlq $0x20, %rax
movq %rsp, %r15
movq %rax, (%r15)
movl %ecx, 0x8(%r15)
xorl %eax, %eax
leaq 0xc(%rsp), %r12
testb $0x1, %al
sete %cl
cmpw $-0x2, %ax
setae %al
testb %cl, %al
jne 0x3c11
movl (%rsp), %esi
movl %esi, 0xc(%rsp)
movq %rbx, %rdi
callq 0x26a4
testb %al, %al
je 0x3c03
movq %r14, %rdi
movq %r12, %rsi
callq 0x405a
movq %r15, %rdi
callq 0x3ff2
movzwl (%rsp), %eax
jmp 0x3bd5
andl $0x0, (%rsp)
leaq 0x16fc(%rip), %rdi      # 0x5318
xorl %esi, %esi
xorl %eax, %eax
callq 0x2170
movl %eax, %ebx
movq %rsp, %rsi
pushq $0x4
popq %rdx
movl %eax, %edi
callq 0x22a0
movl %ebx, %edi
callq 0x23c0
movslq (%rsp), %rax
leaq 0x10(%rsp), %rdi
movq (%rdi), %rcx
movq 0x8(%rdi), %rsi
subq %rcx, %rsi
sarq $0x2, %rsi
xorl %edx, %edx
divq %rsi
movl (%rcx,%rdx,4), %ebx
callq 0x3fbe
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0x3c6f
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x3fbe
movq %rbx, %rdi
callq 0x2350
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/BasicMoveDeciders.cpp
// Function: Board::decide_move_first()
Edge Board::decide_move_first()
{
    EdgeIterator it = std::find_if(edge_begin(), edge_end(),
            [&] (Edge edge)
            { return this->is_move_valid(edge); });
    return *it;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl (%rdi), %esi
movl 0x4(%rdi), %eax
shlq $0x20, %rsi
leaq 0x8(%rsp), %r14
movq %rsi, (%r14)
movl %eax, 0x8(%r14)
xorl %eax, %eax
testb $0x1, %al
sete %cl
cmpw $-0x2, %ax
setae %al
testb %cl, %al
jne 0x3cda
movq %rbx, %rdi
callq 0x26a4
testb %al, %al
jne 0x3cd5
movq %r14, %rdi
callq 0x3ff2
movzwl 0x8(%rsp), %eax
movq 0x8(%rsp), %rsi
jmp 0x3ca5
movq 0x8(%rsp), %rsi
movl %esi, %eax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/./Board.h
// Function: EdgeIterator::operator++()
EdgeIterator &operator++()
        {
            if (edge.dir == HORIZ) {
                if (edge.x < width) {
                    if (edge.y <= height) {
                        ++edge.y;
                    } else {
                        ++edge.x;
                        edge.y = 0;
                    }
                } else {
                    edge.dir = VERT;
                    edge.x = 0;
                    edge.y = 0;
                }
            } else {
                if (edge.x <= width) {
                    if (edge.y < height) {
                        ++edge.y;
                    } else {
                        ++edge.x;
                        edge.y = 0;
                    }
                } else {
                    edge.dir = HORIZ;
                    edge.x = -1;
                    edge.y = -1;
                }
            }
            return *this;
        }

// Assembly:
movq %rdi, %rax
movl (%rdi), %ecx
movl 0x4(%rdi), %edi
movsbl %cl, %edx
movl %edx, %esi
sarl %esi
testb $0x1, %dl
jne 0x4024
movw $0x1, %dx
cmpl %esi, %edi
jle 0x4056
movswl %cx, %edx
sarl $0x8, %edx
cmpl %edx, 0x8(%rax)
jge 0x403f
leal 0x2(%rcx), %edx
andl $0xfe, %edx
jmp 0x4056
movw $0xfffe, %dx            # imm = 0xFFFE
cmpl %esi, %edi
jl 0x4056
movswl %cx, %edx
sarl $0x8, %edx
cmpl %edx, 0x8(%rax)
jle 0x404c
leal 0x100(%rcx), %edx
jmp 0x4056
andl $-0x2, %ecx
addl $0x100, %ecx            # imm = 0x100
movl %ecx, %edx
jmp 0x4056
leal 0x3(,%rsi,2), %ecx
movzbl %cl, %edx
movw %dx, (%rax)
retq
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/DotsDriver.cpp
// Function: echo(void*)
void *echo(void *args)
{
    FILE *fd = (FILE *)args;
    char buf[200];
    while (fgets(buf, sizeof(buf), fd)) {
        fputs(buf, stderr);
    }
    return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0xd0, %rsp
movq %rdi, %rbx
movq %rsp, %r14
movq 0x3b99(%rip), %r15      # 0x7fd8
movq %r14, %rdi
movl $0xc8, %esi
movq %rbx, %rdx
callq 0x2310
testq %rax, %rax
je 0x4461
movq (%r15), %rsi
movq %r14, %rdi
callq 0x2210
jmp 0x443f
xorl %eax, %eax
addq $0xd0, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/grogers0[P]dots_and_boxes/DotsDriver.cpp
// Function: print_win_info(Board const&, int)
void print_win_info(const Board &board, int winning_player = -1)
{
    int score[2] = {board.get_score(0), board.get_score(1)};

    board.print(stdout);

    if (winning_player == -1) {
        if (score[0] > score[1]) {
            winning_player = 0;
        } else if (score[0] < score[1]) {
            winning_player = 1;
        } else {
            printf("tie game! final score => player 1: %d, player 2: %d\n",
                    score[0], score[1]);
            return;
        }
    }

    printf("player %d wins! final score => player 1: %d, player 2: %d\n",
            winning_player + 1, score[0], score[1]);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %r14d
movl 0x8(%rdi), %ebp
movl 0xc(%rdi), %ebx
movq 0x3b34(%rip), %rax      # 0x7fb8
movq (%rax), %rsi
xorl %edx, %edx
callq 0x3176
cmpl $-0x1, %r14d
jne 0x44a4
movl $0x0, %r14d
cmpl %ebx, %ebp
jg 0x44a4
jge 0x44c0
pushq $0x1
popq %r14
incl %r14d
leaq 0x1092(%rip), %rdi      # 0x5540
movl %r14d, %esi
movl %ebp, %edx
movl %ebx, %ecx
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
jmp 0x2040
leaq 0x1044(%rip), %rdi      # 0x550b
movl %ebp, %esi
movl %ebx, %edx
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
jmp 0x2040
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/convert_to_cpp.cpp
// Function: eval_expr(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
std::string eval_expr(std::string& s)
{
	std::string evaled = "";
	if(*s.begin()=='"') {
		std::string subject = "";
		std::string::iterator itr = s.begin()+1;
		for(;*itr!='"';++itr)
			subject.push_back(*itr);

		evaled.append("artificial_string(\""+subject+"\")");

		itr++;
		for(;itr!=s.end();++itr)
			evaled.push_back(*itr);
	}
	if(evaled == "")
		evaled  = s;

	return evaled;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x6bd6(%rip), %rsi      # 0x91fe
leaq -0x40(%rbp), %rdx
callq 0x20b0
movq (%r14), %rax
cmpb $0x22, (%rax)
jne 0x26e2
leaq 0x6bba(%rip), %rsi      # 0x91fe
leaq -0x40(%rbp), %rdi
leaq -0x60(%rbp), %rdx
callq 0x20b0
movq (%r14), %r12
addq $0x2, %r12
leaq -0x40(%rbp), %r15
movb -0x1(%r12), %al
cmpb $0x22, %al
je 0x2675
incq %r12
movsbl %al, %esi
movq %r15, %rdi
callq 0x2160
jmp 0x265c
leaq 0x6988(%rip), %rsi      # 0x9004
leaq -0x80(%rbp), %rdi
leaq -0x40(%rbp), %rdx
callq 0x4232
leaq 0x6988(%rip), %rdx      # 0x9018
leaq -0x60(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x4209
leaq -0x60(%rbp), %rsi
movq %rbx, %rdi
callq 0x2360
leaq -0x60(%rbp), %rdi
callq 0x20e0
leaq -0x80(%rbp), %rdi
callq 0x20e0
movq (%r14), %rax
addq 0x8(%r14), %rax
cmpq %rax, %r12
je 0x26d9
movsbl (%r12), %esi
movq %rbx, %rdi
callq 0x2160
incq %r12
jmp 0x26bb
leaq -0x40(%rbp), %rdi
callq 0x20e0
leaq 0x6b15(%rip), %rsi      # 0x91fe
movq %rbx, %rdi
callq 0x42a8
testb %al, %al
je 0x2700
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2110
movq %rbx, %rax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq -0x60(%rbp), %rdi
callq 0x20e0
jmp 0x2723
jmp 0x2730
movq %rax, %r14
leaq -0x80(%rbp), %rdi
callq 0x20e0
jmp 0x273a
jmp 0x2737
movq %rax, %r14
jmp 0x2743
jmp 0x2737
movq %rax, %r14
leaq -0x40(%rbp), %rdi
callq 0x20e0
movq %rbx, %rdi
callq 0x20e0
movq %r14, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/convert_to_cpp.cpp
// Function: is_symbol(char)
bool is_symbol(char c){
	char symbols[]=" =:;(){}[]|,.&+-<>*/'\n#";

	for(int i=0;symbols[i]!='#';++i)
		if(symbols[i]==c)
			return 1;
	return 0;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
xorl %edx, %edx
leaq 0x6a40(%rip), %rax      # 0x91a0
movq %rdx, %rcx
cmpq $0x16, %rdx
je 0x2773
leaq 0x1(%rcx), %rdx
cmpb %dil, (%rcx,%rax)
jne 0x2760
cmpq $0x16, %rcx
setne %al
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/convert_to_cpp.cpp
// Function: break_into_words(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, 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>>>>&)
void break_into_words(std::string& line,std::vector< std::string >& tokens)
{
	int flag=1;	//to check if a symbol has been pushed and tokens.end()-1 isn't a continuing token
	for(std::string::iterator itr=line.begin();itr!=line.end();++itr)
	{   
		if(*itr=='"'){
			tokens.push_back("");
			(tokens.end()-1)->push_back('"');
			while(*(++itr)!='"')
				(tokens.end()-1)->push_back(*itr);
			(tokens.end()-1)->push_back('"');
			continue;
			flag=1;
		}
		if(is_symbol(*itr))
		{
			if(*itr!=' '&&*itr!='\n')
			{
				std::string emp(1,*itr);	
				tokens.push_back(emp);
			}
			flag=1;
			continue;
		}	
		if(flag)
			tokens.push_back("");
		(tokens.end()-1)->push_back(*itr);
		flag=0;
	}
	
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq (%rdi), %rax
pushq $0x1
popq %rcx
leaq -0x58(%rbp), %r15
movq %rax, %r13
movl %ecx, -0x30(%rbp)
movq %rdi, -0x38(%rbp)
addq 0x8(%r14), %rax
cmpq %rax, %r13
je 0x2a62
movzbl (%r13), %r12d
cmpl $0x22, %r12d
jne 0x299f
movq %r15, %rdi
leaq 0x68ad(%rip), %rsi      # 0x91fe
leaq -0x29(%rbp), %rdx
callq 0x20b0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x48f6
movq %r15, %rdi
callq 0x20e0
movb $0x22, %al
movq 0x8(%rbx), %rdi
addq $-0x20, %rdi
movsbl %al, %esi
callq 0x2160
movb 0x1(%r13), %al
incq %r13
cmpb $0x22, %al
jne 0x296f
movq 0x8(%rbx), %rdi
addq $-0x20, %rdi
pushq $0x22
popq %rsi
callq 0x2160
jmp 0x2a57
movq %r15, %r14
movsbl %r12b, %r15d
movl %r15d, %edi
callq 0x2753
testb %al, %al
je 0x29d0
cmpl $0xa, %r12d
je 0x29be
cmpl $0x20, %r12d
jne 0x2a21
pushq $0x1
popq %rax
movl %eax, -0x30(%rbp)
movq %r14, %r15
movq -0x38(%rbp), %r14
jmp 0x2a57
cmpl $0x0, -0x30(%rbp)
movq %r14, %r15
movq -0x38(%rbp), %r14
je 0x2a07
movq %r15, %rdi
leaq 0x6817(%rip), %rsi      # 0x91fe
leaq -0x29(%rbp), %rdx
callq 0x20b0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x48f6
movq %r15, %rdi
callq 0x20e0
movb (%r13), %r12b
movq 0x8(%rbx), %rdi
addq $-0x20, %rdi
movsbl %r12b, %esi
callq 0x2160
movl $0x0, -0x30(%rbp)
jmp 0x2a57
leaq -0x48(%rbp), %rax
movq %rax, -0x58(%rbp)
movq %r14, %rdi
pushq $0x1
popq %rsi
movl %r15d, %edx
callq 0x2210
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4346
movq %r14, %r15
movq -0x38(%rbp), %r14
movq %r15, %rdi
callq 0x20e0
pushq $0x1
popq %rax
movl %eax, -0x30(%rbp)
incq %r13
movq (%r14), %rax
jmp 0x292f
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2a7e
jmp 0x2a79
jmp 0x2a7e
jmp 0x2a79
movq %rax, %rbx
jmp 0x2a8a
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x20e0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/convert_to_cpp.cpp
// Function: map_type(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
std::string map_type(std::string s, int l)
{
	if(s=="int")
		return "long int";
	if(s=="float")
		return "float";
	if(s=="s")
		return "artificial_string";
	else {
		std::cout<<"[ WARNING ] Bad type name "<<s<<"!! on line "<<l<<std::endl;
		return s;
	}


}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %r15d
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x6592(%rip), %rsi      # 0x903e
movq %r14, %rdi
callq 0x42a8
testb %al, %al
je 0x2ac5
leaq 0x657a(%rip), %rsi      # 0x9039
leaq -0x1b(%rbp), %rdx
jmp 0x2b03
leaq 0x6576(%rip), %rsi      # 0x9042
movq %r14, %rdi
callq 0x42a8
testb %al, %al
je 0x2ae5
leaq 0x6563(%rip), %rsi      # 0x9042
leaq -0x1a(%rbp), %rdx
jmp 0x2b03
leaq 0x685e(%rip), %rsi      # 0x934a
movq %r14, %rdi
callq 0x42a8
testb %al, %al
je 0x2b19
leaq 0x6521(%rip), %rsi      # 0x9020
leaq -0x19(%rbp), %rdx
movq %rbx, %rdi
callq 0x20b0
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0xa4b8(%rip), %rdi      # 0xcfd8
leaq 0x6521(%rip), %rsi      # 0x9048
callq 0x21a0
movq %rax, %rdi
movq %r14, %rsi
callq 0x2180
leaq 0x6525(%rip), %rsi      # 0x9063
movq %rax, %rdi
callq 0x21a0
movq %rax, %rdi
movl %r15d, %esi
callq 0x2310
movq %rax, %rdi
callq 0x20f0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2250
jmp 0x2b0b
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/generate_cpp_code.cpp
// Function: main_func(source_code&)
void main_func(source_code& src)
{
	function_declaration _function;
	_function.name="main";
	_function.return_type="int";
	_function.args.push_back(string_pair("",""));
	
	std::string converted_code;
	std::map< std::string,std::string > variables;	//name -> type
	convert_to_cpp(src.functions[0].first,src.functions[0].second,src.lines,converted_code,&_function,variables);
	converted_code.append(" \nreturn 0;");
	src.generated_cpp_code[0].first=converted_code;	//Only 1 line of sparse code maybe extend later
	src.generated_cpp_code[0].second=_function;	
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0xb8, %rsp
leaq -0xb0(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
xorl %ecx, %ecx
movb %cl, (%rax)
leaq -0x90(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movq %rdi, %rbx
movb %cl, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rax)
andq $0x0, 0x20(%rax)
leaq 0x3628(%rip), %rsi      # 0x9250
leaq -0xc0(%rbp), %rdi
callq 0x2350
leaq -0xa0(%rbp), %rdi
leaq 0x33fc(%rip), %rsi      # 0x903e
callq 0x2350
leaq 0x35b0(%rip), %rdx      # 0x91fe
leaq -0x68(%rbp), %rdi
movq %rdx, %rsi
callq 0x5f10
leaq -0x80(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x4c0a
leaq -0x68(%rbp), %rdi
callq 0x43b4
leaq -0x18(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq -0x60(%rbp), %rax
andl $0x0, (%rax)
andq $0x0, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
andq $0x0, 0x20(%rax)
movq 0x50(%rbx), %rax
movslq (%rax), %rdi
movslq 0x4(%rax), %rsi
leaq 0x38(%rbx), %rdx
leaq -0x28(%rbp), %rcx
leaq -0xc0(%rbp), %r8
leaq -0x68(%rbp), %r9
callq 0x2bd9
leaq 0x3592(%rip), %rsi      # 0x9255
leaq -0x28(%rbp), %rdi
callq 0x2340
movq 0x80(%rbx), %rdi
leaq -0x28(%rbp), %rsi
callq 0x2110
movq 0x80(%rbx), %rdi
addq $0x20, %rdi
leaq -0xc0(%rbp), %rsi
callq 0x5f56
leaq -0x68(%rbp), %rdi
callq 0x634c
leaq -0x28(%rbp), %rdi
callq 0x20e0
leaq -0xc0(%rbp), %rdi
callq 0x5f8e
addq $0xb8, %rsp
popq %rbx
popq %rbp
retq
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x43b4
jmp 0x5d45
jmp 0x5d2b
movq %rax, %rbx
jmp 0x5d45
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x634c
leaq -0x28(%rbp), %rdi
callq 0x20e0
leaq -0xc0(%rbp), %rdi
callq 0x5f8e
movq %rbx, %rdi
callq 0x2320
nop
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/main.cpp
// Function: main
int main(int argc, char *argv[])
{

	char *f=argv[1];
	std::string input_src;
	if (FILE *fp = fopen(f,"r"))
	{
		char buf[chunk];
		while (size_t len = fread(buf, 1, sizeof(buf), fp))
			input_src.insert(input_src.end(), buf, buf + len);
		fclose(fp);

		
	}
	else {
		std::cout<<"Unable to open source file (main.cpp)\n";
		exit(0);
	}

	
	for(int i=0;;++i)
		if(f[i]=='.')
		{
			f[i]='\0';
			break;
		}
		

	source_code input_code(input_src);
	input_code.file_name=f;
	input_code.functionize();
	//input_code.make_classes();
	
	input_code.generate_cpp_code();

	input_code.generate_cpp_classes();

	// std::cout<<f<<"\n";
	
	input_code.render_code();
		 std::cout<<f<<"done with rendering of code\n";





	// for(std::vector< line_pair >::iterator itr=input_code.lines.begin();itr!=input_code.lines.end();++itr)
	// 	std::cout<<itr->first<<"\n";

	return 0;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x428, %rsp            # imm = 0x428
movq 0x8(%rsi), %rbx
leaq -0x38(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x296a(%rip), %rsi      # 0x90cd
movq %rbx, %rdi
callq 0x2220
testq %rax, %rax
je 0x6861
movq %rax, %r14
leaq -0x450(%rbp), %r15
pushq $0x1
popq %r12
leaq -0x48(%rbp), %r13
movl $0x400, %edx            # imm = 0x400
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rcx
callq 0x22c0
testq %rax, %rax
je 0x67be
movq -0x48(%rbp), %rsi
addq -0x40(%rbp), %rsi
leaq (%rax,%rbp), %rcx
addq $-0x450, %rcx           # imm = 0xFBB0
movq %r13, %rdi
movq %r15, %rdx
callq 0x68a4
jmp 0x6786
movq %r14, %rdi
callq 0x21b0
movq %rbx, %rax
cmpb $0x2e, (%rax)
leaq 0x1(%rax), %rax
jne 0x67c9
movb $0x0, -0x1(%rax)
leaq -0x450(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x68ce
leaq -0x450(%rbp), %rdi
movq %rbx, 0x30(%rdi)
callq 0x5330
leaq -0x450(%rbp), %rdi
callq 0x5d5a
leaq -0x450(%rbp), %rdi
callq 0x838c
leaq -0x450(%rbp), %rdi
callq 0x6abc
movq 0x67b7(%rip), %rdi      # 0xcfd8
movq %rbx, %rsi
callq 0x21a0
leaq 0x2a5d(%rip), %rsi      # 0x928d
movq %rax, %rdi
callq 0x21a0
leaq -0x450(%rbp), %rdi
callq 0x6910
leaq -0x48(%rbp), %rdi
callq 0x20e0
xorl %eax, %eax
addq $0x428, %rsp            # imm = 0x428
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x6770(%rip), %rdi      # 0xcfd8
leaq 0x29f7(%rip), %rsi      # 0x9266
callq 0x21a0
xorl %edi, %edi
callq 0x2230
jmp 0x6890
jmp 0x6890
movq %rax, %rbx
leaq -0x450(%rbp), %rdi
callq 0x6910
jmp 0x6893
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x20e0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/convert_to_cpp_classes.cpp
// Function: is_symbol_(char)
bool is_symbol_(char c){
	char symbols[]=" =:;(){}[]|,.&+-<>*/'\n#";

	for(int i=0;symbols[i]!='#';++i)
		if(symbols[i]==c)
			return 1;
	return 0;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
xorl %edx, %edx
leaq 0x20fc(%rip), %rax      # 0x91a0
movq %rdx, %rcx
cmpq $0x16, %rdx
je 0x70b7
leaq 0x1(%rcx), %rdx
cmpb %dil, (%rcx,%rax)
jne 0x70a4
cmpq $0x16, %rcx
setne %al
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/convert_to_cpp_classes.cpp
// Function: expr_type_(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::string expr_type_(std::string& expr,std::map< std::string,std::string >& variables)
{	
	if(expr[0]=='"')
		return "artificial_string";
	if(isdigit(expr[0]) || expr[0]=='-')
	{
		for(std::string::iterator i=expr.begin();i!=expr.end();++i)
			if(*i=='.')
				return "double";
		return "long int";
	}	
	std::string::iterator itr=expr.begin();
	std::string first_variable;
	while(itr!=expr.end()){
		if(is_symbol_(*itr)&&*itr!='.')
			break;
		first_variable.push_back(*(itr++));
	}
	
	if(variables.count(first_variable))
		return variables[first_variable];	//Implicit type casting to be taken care of later on(small fix)
	else return "";
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movq (%rsi), %r14
movsbl (%r14), %eax
cmpl $0x22, %eax
jne 0x70ec
leaq 0x1f39(%rip), %rsi      # 0x9020
jmp 0x71b2
movq %rsi, %r15
movl %eax, %ecx
addl $-0x30, %ecx
cmpl $0xa, %ecx
setae %cl
cmpb $0x2d, %al
setne %al
testb %cl, %al
jne 0x7129
movq 0x8(%r15), %rax
xorl %ecx, %ecx
cmpq %rcx, %rax
je 0x71ab
cmpb $0x2e, (%r14,%rcx)
leaq 0x1(%rcx), %rcx
jne 0x7109
leaq 0x1f0e(%rip), %rsi      # 0x9032
jmp 0x71b2
movq %rdx, -0x58(%rbp)
movq %rbx, -0x60(%rbp)
leaq -0x40(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq -0x50(%rbp), %r12
movq (%r15), %rax
addq 0x8(%r15), %rax
cmpq %rax, %r14
je 0x7179
movsbl (%r14), %r13d
cmpl $0x2e, %r13d
setne %bl
movl %r13d, %edi
callq 0x7097
testb %al, %bl
jne 0x7179
incq %r14
movsbl %r13b, %esi
movq %r12, %rdi
callq 0x2160
jmp 0x7145
leaq -0x50(%rbp), %rsi
movq -0x58(%rbp), %r14
movq %r14, %rdi
callq 0x42b8
movq -0x60(%rbp), %rbx
testq %rax, %rax
je 0x71c0
leaq -0x50(%rbp), %rsi
movq %r14, %rdi
callq 0x42dc
movq %rbx, %rdi
movq %rax, %rsi
callq 0x2290
jmp 0x71d3
leaq 0x1e87(%rip), %rsi      # 0x9039
leaq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x20b0
jmp 0x71dc
leaq 0x2037(%rip), %rsi      # 0x91fe
leaq -0x29(%rbp), %rdx
movq %rbx, %rdi
callq 0x20b0
leaq -0x50(%rbp), %rdi
callq 0x20e0
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x71f2
jmp 0x71f2
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x20e0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O2/nikhilYadala[P]Python_to_cpp/Source/src/make_classes.cpp
// Function: source_code::make_classes()
void source_code::make_classes()
{
 //splitting of the code into lines has already been done while functionizing
	classes.resize(0); 

	for(std::vector <line_pair>::iterator classes_itr=lines.begin();classes_itr!=lines.end();)
	{

		//itr incrementing to be done in the following code.
		if(classes_itr->first[0]=='c'&&classes_itr->first[1]=='l'&&classes_itr->first[2]=='a'&&classes_itr->first[3]=='s'&&classes_itr->first[4]=='s')
	        {

	            //classes inherited are taken care off in convert_to_cpp_classes.cpp
	            
	        	int space_count=classes_itr->second;
	        	int i1,i2;
	        	i1=classes_itr-lines.begin();
	        	while((((++classes_itr)->second)) > space_count)
					i2=classes_itr-lines.begin()-1;
				classes.push_back(int_pair(i1,i2));

            }
        else
           {
                   classes_itr++;
           }
	}

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x68(%rdi), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x5716
movq 0x38(%rbx), %r15
pushq $0x28
popq %r13
leaq -0x30(%rbp), %rsi
movq %r15, %rdx
movq 0x40(%rbx), %r8
movq %r15, %rax
negq %rax
leaq 0x28(%r15), %rcx
movq %rcx, %r15
cmpq %r8, %rdx
je 0x8c0d
movq (%rdx), %rdi
cmpb $0x63, (%rdi)
jne 0x8bac
cmpb $0x6c, 0x1(%rdi)
jne 0x8bac
cmpb $0x61, 0x2(%rdi)
jne 0x8bac
cmpb $0x73, 0x3(%rdi)
jne 0x8bac
cmpb $0x73, 0x4(%rdi)
je 0x8bbe
addq $0x28, %rdx
addq $-0x28, %rax
addq $0x28, %r15
addq $0x28, %rcx
jmp 0x8b83
movl 0x20(%rdx), %edi
movq 0x38(%rbx), %r8
addq %r8, %rax
negq %rax
cqto
idivq %r13
movq %rax, %r9
subq %r8, %rcx
cmpl %edi, 0x20(%r15)
jle 0x8bf4
movq %rcx, %rax
cqto
idivq %r13
movq %rax, %r12
decl %r12d
addq $0x28, %r15
addq $0x28, %rcx
jmp 0x8bd6
movl %r9d, -0x30(%rbp)
movl %r12d, -0x2c(%rbp)
movq %r14, %rdi
callq 0x5afc
leaq -0x30(%rbp), %rsi
jmp 0x8b6f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/panosfoto[P]NGramGraphParallel/src/GraphSimilarity.cpp
// Function: GraphSimilarity::getSimilarityComponents[abi:cxx11]()
std::map<std::string, double> GraphSimilarity::getSimilarityComponents()
{
    // Init result map
    std::map<std::string, double> resultMap;
    // Update components
    resultMap["valueSimilarity"] = this->valueSimilarity;
    resultMap["containmentSimilarity"] = this->containmentSimilarity;
    resultMap["sizeSimilarity"] = this->sizeSimilarity;
    // Return
    return resultMap;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
andl $0x0, 0x8(%rdi)
andq $0x0, 0x10(%rdi)
movq %rsi, %r14
leaq 0x8(%rdi), %rax
movq %rax, 0x18(%rdi)
movq %rax, 0x20(%rdi)
andq $0x0, 0x28(%rdi)
movsd 0x8(%rsi), %xmm0
movsd %xmm0, -0x20(%rbp)
leaq 0x935a(%rip), %rsi      # 0x1de82
leaq -0x40(%rbp), %rdi
leaq -0x11(%rbp), %rdx
callq 0x7110
leaq -0x40(%rbp), %rsi
movq %rbx, %rdi
callq 0x7bd4
movsd -0x20(%rbp), %xmm0
movsd %xmm0, (%rax)
leaq -0x40(%rbp), %rdi
callq 0x7160
movsd 0x10(%r14), %xmm0
movsd %xmm0, -0x20(%rbp)
leaq 0x932d(%rip), %rsi      # 0x1de92
leaq -0x40(%rbp), %rdi
leaq -0x11(%rbp), %rdx
callq 0x7110
leaq -0x40(%rbp), %rsi
movq %rbx, %rdi
callq 0x7bd4
movsd -0x20(%rbp), %xmm0
movsd %xmm0, (%rax)
leaq -0x40(%rbp), %rdi
callq 0x7160
movsd 0x18(%r14), %xmm0
movsd %xmm0, -0x20(%rbp)
leaq 0x351b(%rip), %rsi      # 0x180bd
leaq -0x40(%rbp), %rdi
leaq -0x11(%rbp), %rdx
callq 0x7110
leaq -0x40(%rbp), %rsi
movq %rbx, %rdi
callq 0x7bd4
movsd -0x20(%rbp), %xmm0
movsd %xmm0, (%rax)
leaq -0x40(%rbp), %rdi
callq 0x7160
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
jmp 0x14be1
jmp 0x14bef
jmp 0x14be1
jmp 0x14bef
movq %rax, %r14
leaq -0x40(%rbp), %rdi
callq 0x7160
jmp 0x14bf2
movq %rax, %r14
movq %rbx, %rdi
callq 0x7c44
movq %r14, %rdi
callq 0x74d0
// File: /workspace/github_cpp_makefile_star2_O2/panosfoto[P]NGramGraphParallel/src/NGramGraph.cpp
// Function: NGramGraph::NGramGraph(ProximityEvaluator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>*, StringSplitter*, StringPayload*, unsigned int)
NGramGraph::NGramGraph(ProximityEvaluator<std::string> *newProximityEvaluator, StringSplitter *newSplitter, StringPayload *newPayload, unsigned int CorrelationWindowValue)
{
    evaluator = newProximityEvaluator;
    splitter = newSplitter;
    payload = newPayload;
    CorrelationWindow = CorrelationWindowValue;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %ebx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r13
callq 0x14ec4
leaq 0x16a83(%rip), %rax     # 0x2b700
movq %rax, (%r13)
movq %r12, 0x80(%r13)
movq %r15, 0x88(%r13)
movq %r14, 0x90(%r13)
movl %ebx, 0x98(%r13)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/toxemicsquire4[P]csci41_calc/main.cc
// Function: modulate(Number, Number)
int modulate ( Number x, Number y ) { //modulus, checks for 0
	if ( !y.get_value() ) {
		cout << "INVALID INPUT!\n";
		exit(0);
	}
	else return x.get_value() % y.get_value();
}

// Assembly:
testl %esi, %esi
je 0x2365
movl %edi, %eax
cltd
idivl %esi
movl %edx, %eax
retq
pushq %rbp
movq %rsp, %rbp
movq 0x2c60(%rip), %rdi      # 0x4fd0
leaq 0xcba(%rip), %rsi       # 0x3031
callq 0x2110
xorl %edi, %edi
callq 0x2140
// File: /workspace/github_cpp_makefile_star2_O2/tobias93[P]piano/rtmidi_build/tests/sysextest.cpp
// Function: mycallback(double, std::vector<unsigned char, std::allocator<unsigned char>>*, void*)
void mycallback( double deltatime, std::vector< unsigned char > *message, void * /*userData*/ )
{
  unsigned int nBytes = message->size();
  for ( unsigned int i=0; i<nBytes; i++ )
    std::cout << "Byte " << i << " = " << (int)message->at(i) << ", ";
  if ( nBytes > 0 )
    std::cout << "stamp = " << deltatime << std::endl;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movsd %xmm0, 0x8(%rsp)
movq 0x8(%rdi), %rax
subq (%rdi), %rax
movq %rax, 0x10(%rsp)
movl %eax, %r12d
xorl %r14d, %r14d
leaq 0xc6a(%rip), %r13       # 0x3063
leaq 0xc5b(%rip), %rbp       # 0x305b
cmpq %r14, %r12
je 0x2457
movq 0x2bc4(%rip), %rdi      # 0x4fd0
leaq 0xc42(%rip), %rsi       # 0x3055
callq 0x2140
movq %rax, %rdi
movq %r14, %rsi
callq 0x20d0
movq %rax, %rdi
movq %r13, %rsi
callq 0x2140
movq %rax, %r15
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2a54
movzbl (%rax), %esi
movq %r15, %rdi
callq 0x2230
movq %rax, %rdi
movq %rbp, %rsi
callq 0x2140
incq %r14
jmp 0x2400
cmpl $0x0, 0x10(%rsp)
je 0x2495
movq 0x2b6b(%rip), %rdi      # 0x4fd0
leaq 0xbf2(%rip), %rsi       # 0x305e
callq 0x2140
movq %rax, %rdi
movsd 0x8(%rsp), %xmm0
callq 0x2200
movq %rax, %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x20b0
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: node::update()
void node::update() {
    size = 1;
    sum_adjacent_nodes[0] = adjacent_nodes[0];
    sum_adjacent_nodes[1] = adjacent_nodes[1];
    if(left) {
        size += left->size;
        sum_adjacent_nodes[0] += left->sum_adjacent_nodes[0];
        sum_adjacent_nodes[1] += left->sum_adjacent_nodes[1];
    }
    if(right) {
        size += right->size;
        sum_adjacent_nodes[0] += right->sum_adjacent_nodes[0];
        sum_adjacent_nodes[1] += right->sum_adjacent_nodes[1];
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0x1, 0x1c(%rdi)
movl 0x20(%rdi), %ecx
movl %ecx, 0x28(%rdi)
movl 0x24(%rdi), %eax
movl %eax, 0x2c(%rdi)
movq (%rdi), %rsi
testq %rsi, %rsi
je 0x24cd
movl 0x1c(%rsi), %edx
incl %edx
movl %edx, 0x1c(%rdi)
addl 0x28(%rsi), %ecx
movl %ecx, 0x28(%rdi)
addl 0x2c(%rsi), %eax
movl %eax, 0x2c(%rdi)
jmp 0x24d2
movl $0x1, %edx
movq 0x8(%rdi), %rsi
testq %rsi, %rsi
je 0x24ed
addl 0x1c(%rsi), %edx
movl %edx, 0x1c(%rdi)
addl 0x28(%rsi), %ecx
movl %ecx, 0x28(%rdi)
addl 0x2c(%rsi), %eax
movl %eax, 0x2c(%rdi)
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: BinarySearchTree::insert_new(node*)
node * BinarySearchTree::insert_new(node *nn) {
    if(!nn)
        return new node();
    change_root(nn);
    while(nn->right)
        nn = nn->right;
    node * newnode = new node();
    newnode->par = nn;
    nn->right = newnode;
    nn->update();
    change_root(newnode);
    return newnode;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x254a
movq %rdi, %rbx
callq 0x2572
movq %rbx, %r14
movq 0x8(%rbx), %rbx
testq %rbx, %rbx
jne 0x2504
pushq $0x30
popq %rdi
callq 0x2160
movq %rax, %rbx
movl $0x1, 0x1c(%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0xc(%rax)
movups %xmm0, (%rax)
movups %xmm0, 0x20(%rax)
movq %r14, 0x10(%rax)
movq %rax, 0x8(%r14)
movq %r14, %rdi
callq 0x2498
movq %rbx, %rdi
callq 0x2572
jmp 0x256a
pushq $0x30
popq %rdi
callq 0x2160
movq %rax, %rbx
movl $0x1, 0x1c(%rax)
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movups %xmm0, 0xc(%rax)
movups %xmm0, 0x20(%rax)
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: BinarySearchTree::change_root(node*)
void BinarySearchTree::change_root(node * nn) {
    if(!nn)
        return;
    while(nn->par) {
        node * p = nn->par;
        node * gp = p->par;
        if(!gp) {
            rotate(nn);
            break;
        }

        if((nn == p->left) == (p == gp->left)) {
            rotate(p);          //left child, left child case
            rotate(nn);             //or right, right case
        }
        else {
            rotate(nn);         //zig zag 
            rotate(nn);
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x25b4
movq %rdi, %rbx
movq 0x10(%rbx), %rdi
testq %rdi, %rdi
je 0x25b4
movq 0x10(%rdi), %rax
testq %rax, %rax
je 0x25bb
cmpq %rbx, (%rdi)
sete %cl
cmpq (%rax), %rdi
setne %al
xorb %cl, %al
jne 0x25a5
movq %rbx, %rdi
callq 0x266c
movq %rbx, %rdi
callq 0x266c
jmp 0x2580
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x266c
nop
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: BinarySearchTree::rotate_left(node*)
void BinarySearchTree::rotate_left(node* nn) {
    node * p = nn->par;
    node * gp = p->par;
    node * lc = nn->left;
    nn->par = gp;

    if(gp) {
        if(p == gp->left)
            gp->left = nn;
        else
            gp->right = nn;
    }

    nn->left = p;
    p->par = nn;

    p->right = lc;
    if(lc)
        lc->par = p;
    p->update();
    nn->update();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
movq 0x10(%rdi), %rdi
movq 0x10(%rdi), %rcx
movq %rcx, 0x10(%rbx)
testq %rcx, %rcx
je 0x25f3
xorl %edx, %edx
cmpq (%rcx), %rdi
setne %dl
movq %rbx, (%rcx,%rdx,8)
movq %rdi, (%rbx)
movq %rbx, 0x10(%rdi)
movq %rax, 0x8(%rdi)
testq %rax, %rax
je 0x2607
movq %rdi, 0x10(%rax)
callq 0x2498
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x2498
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: BinarySearchTree::rotate_right(node*)
void BinarySearchTree::rotate_right(node * nn) {
    node * p = nn->par;
    node * gp = p->par;
    node * rc = nn->right;
    nn->par = gp;

    if(gp) {
        if(p == gp->left)
            gp->left = nn;
        else
            gp->right = nn;
    }

    nn->right = p;
    p->par = nn;

    p->left = rc;
    if(rc)
        rc->par = p;
    p->update();
    nn->update();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rax
movq 0x10(%rdi), %rdi
movq 0x10(%rdi), %rcx
movq %rcx, 0x10(%rbx)
testq %rcx, %rcx
je 0x2644
xorl %edx, %edx
cmpq (%rcx), %rdi
setne %dl
movq %rbx, (%rcx,%rdx,8)
movq %rdi, 0x8(%rbx)
movq %rbx, 0x10(%rdi)
movq %rax, (%rdi)
testq %rax, %rax
je 0x2658
movq %rdi, 0x10(%rax)
callq 0x2498
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x2498
nop
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: BinarySearchTree::rotate(node*)
void BinarySearchTree::rotate(node * nn) {
    node * p = nn->par;
    if(!p)
        return;
    if(nn == p->left)
        rotate_right(nn);
    else
        rotate_left(nn);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq 0x10(%rdi), %rax
testq %rax, %rax
je 0x2684
cmpq %rdi, (%rax)
je 0x2686
popq %rbp
jmp 0x25ca
popq %rbp
retq
popq %rbp
jmp 0x261a
// File: /workspace/github_cpp_makefile_star2_O2/yogesh1q2w[P]Dynamic-Graph-Algorithms/BinarySearchTree.cpp
// Function: BinarySearchTree::remove_child(node*)
void BinarySearchTree::remove_child(node * nn) {
    node * p = nn->par;
    if(!p)
        return;
    if(nn == p->left)
        p->left = NULL;
    else
        p->right = NULL;
    nn->par = NULL;
    p->update();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rax
movq 0x10(%rdi), %rdi
testq %rdi, %rdi
je 0x26b4
xorl %ecx, %ecx
cmpq %rax, (%rdi)
setne %cl
andq $0x0, (%rdi,%rcx,8)
andq $0x0, 0x10(%rax)
popq %rbp
jmp 0x2498
popq %rbp
retq