LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: Method::construct_main_method(DeclarationVisitor*, MainClass*)
Method *Method::construct_main_method(DeclarationVisitor *visitor, MainClass *main_class) {
    Method *method = (Method *) allocate_zero(sizeof(Method), MEM::TYPECHECK);
    method->id = main_method_string;
    size_t locals_size = main_class->vars.len;
    method->locals.reserve(locals_size);

    for (LocalDeclaration *var : main_class->vars) {
        if (method->locals.find(var->id)) {
            typecheck_error(var->loc, "Variable `", var->id, "` is already defined",
                            " in method `", method->id, "`");
        } else {
            Var *v = var->accept(visitor);
            method->locals.insert(v->id, v);
        }
    }

    method->param_len = 0;
    method->stmts = main_class->stmts;
    method->ret_type = visitor->type_table.int_type;
    method->ret_expr = NULL;
    method->loc = main_class->loc;
    return method;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, 0x8(%rsp)
pushq $0x78
popq %rdi
pushq $0x3
popq %rsi
callq 0x23de
movq %rax, %r15
leaq 0x10aa5(%rip), %rax     # 0x18a48
movq (%rax), %rax
movq %rax, (%r15)
movq 0x18(%rbx), %rsi
movq %r15, %r12
addq $0x18, %r12
movq %r12, %rdi
callq 0xd17e
movq 0x18(%rbx), %r13
movq %rbx, 0x10(%rsp)
movq 0x20(%rbx), %rbp
shlq $0x3, %r13
xorl %ebx, %ebx
cmpq %rbx, %r13
je 0x803c
movq (%rbp,%rbx), %r14
movq 0x18(%r14), %rsi
movq %r12, %rdi
callq 0xda72
testq %rax, %rax
je 0x801b
movl (%r14), %edi
movq 0x18(%r14), %rdx
movq (%r15), %r9
leaq 0x79e6(%rip), %rax      # 0xf9e1
movq %rax, (%rsp)
leaq 0x8890(%rip), %rsi      # 0x10896
leaq 0x8867(%rip), %rcx      # 0x10874
leaq 0x8875(%rip), %r8       # 0x10889
callq 0x8429
jmp 0x8036
movq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x84a0
movq (%rax), %rsi
movq %r12, %rdi
movq %rax, %rdx
callq 0xcd72
addq $0x8, %rbx
jmp 0x7fcf
andq $0x0, 0x10(%r15)
movq 0x10(%rsp), %rcx
movups 0x28(%rcx), %xmm0
movups %xmm0, 0x58(%r15)
movq 0x38(%rcx), %rax
movq %rax, 0x68(%r15)
movq 0x8(%rsp), %rax
movq 0x10(%rax), %rax
movq %rax, 0x8(%r15)
andq $0x0, 0x70(%r15)
movl (%rcx), %eax
movl %eax, 0x50(%r15)
movq %r15, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: DeclarationVisitor::visit(LocalDeclaration*)
Local *DeclarationVisitor::visit(LocalDeclaration *local_decl) {
    // Note: It's responsibility of the one who calls this visit
    // to have assured that a local declaration with the same
    // id does not exist.
    LOG_SCOPE;
    assert(!local_decl->is_undefined());
    print_indentation();
    debug_log(local_decl->loc, "LocalDeclaration: ", local_decl->id, "\n");
    if (local_decl->typespec.id != NULL
        && local_decl->typespec.id == this->type_table.main_cls_type->id)
    {
        typecheck_error(local_decl->loc, "You can't declare a local of type of",
                        " the main class.");
    }
    Type *type = typespec_to_type(local_decl->typespec, local_decl->loc);
    Local *local = new Local(local_decl->id, type);
    return local;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xf(%rsp), %rdi
callq 0x3108
cmpq $0x0, 0x18(%rbx)
je 0x8548
callq 0x312f
movl (%rbx), %edi
movq 0x18(%rbx), %rdx
leaq 0x82ee(%rip), %rsi      # 0x107c4
callq 0x8336
movq 0x10(%rbx), %rdx
testq %rdx, %rdx
je 0x8509
movq 0x20(%r14), %rax
cmpq 0x8(%rax), %rdx
jne 0x850b
movl (%rbx), %edi
leaq 0x82e0(%rip), %rsi      # 0x107d7
leaq 0x8725(%rip), %rdx      # 0x10c23
callq 0x8580
movq 0x10(%rbx), %rdx
jmp 0x850b
xorl %edx, %edx
movl (%rbx), %ecx
movl 0x8(%rbx), %esi
movq %r14, %rdi
callq 0x7d16
movq %rax, %r14
pushq $0x40
popq %rdi
callq 0xcbbc
movq %rax, %r15
movq 0x18(%rbx), %rax
movq %rax, (%r15)
movq %r14, 0x8(%r15)
leaq 0xf(%rsp), %rdi
callq 0x311c
movq %r15, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x8224(%rip), %rdi      # 0x10773
leaq 0x7e98(%rip), %rsi      # 0x103ee
leaq 0x8232(%rip), %rcx      # 0x1078f
movl $0x293, %edx            # imm = 0x293
callq 0x20b0
jmp 0x856b
jmp 0x856b
movq %rax, %rbx
leaq 0xf(%rsp), %rdi
callq 0x311c
movq %rbx, %rdi
callq 0x21c0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: DeclarationVisitor::gen_id()
const char *DeclarationVisitor::gen_id() {
    static int count = 0;
    char buf[64];
    sprintf(buf, "a%d", count);
    count++;
    return str_intern(buf);
}

// Assembly:
pushq %rbx
subq $0x40, %rsp
movl 0x124b1(%rip), %edx     # 0x1aa8c
leaq 0x821a(%rip), %rsi      # 0x107fc
movq %rsp, %rbx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x2040
incl 0x12497(%rip)           # 0x1aa8c
movq %rbx, %rdi
callq 0x733c
addq $0x40, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: MainTypeCheckVisitor::visit(Goal*)
void MainTypeCheckVisitor::visit(Goal *goal) {
    LOG_SCOPE;
    debug_print("MainTypeCheck::Goal\n");
    goal->main_class.accept(this);
    for (IdType *type : this->type_table) {
        if (type->is_defined()) {
            type->accept(this);
        } else {
            // type->loc is going to be the location of its first usage (Check
            // id_to_type()). Ideally, we would like to have all the locations
            // it was used, or some, but this will at least make this a not very
            // bad message.
            typecheck_error(type->loc, "Type `", type->id, "` has not been ",
                            "defined");
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x7(%rsp), %rdi
callq 0x3108
leaq 0x8072(%rip), %rdi      # 0x108a1
xorl %eax, %eax
callq 0x317b
movq %rbx, %rdi
callq 0x88c4
movq 0x48(%rbx), %r13
movq 0x50(%rbx), %rbp
shlq $0x3, %rbp
xorl %r14d, %r14d
leaq 0x7d27(%rip), %r15      # 0x1057b
leaq 0x89b7(%rip), %r12      # 0x11212
cmpq %r14, %rbp
je 0x8893
movq (%r13,%r14), %rsi
cmpl $0x0, 0x4(%rsi)
je 0x8875
movq %rbx, %rdi
callq 0x892c
jmp 0x888d
movl (%rsi), %edi
movq 0x8(%rsi), %rdx
leaq 0x7cf2(%rip), %rsi      # 0x10574
movq %r15, %rcx
movq %r12, %r8
callq 0x7bee
addq $0x8, %r14
jmp 0x885b
leaq 0x7(%rsp), %rdi
callq 0x311c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x88ae
movq %rax, %rbx
leaq 0x7(%rsp), %rdi
callq 0x311c
movq %rbx, %rdi
callq 0x21c0
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: MainTypeCheckVisitor::visit(MainClass*)
void MainTypeCheckVisitor::visit(MainClass *main_class) {
    LOG_SCOPE;
    debug_print("MainTypeCheck::MainClass\n");
    this->curr_class = this->type_table.main_cls_type;
    this->type_table.main_method->accept(this, this->curr_class->id);
    this->curr_class = NULL;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0xf(%rsp), %rdi
callq 0x3108
leaq 0x7fd9(%rip), %rdi      # 0x108b6
xorl %eax, %eax
callq 0x317b
movq 0x20(%rbx), %rax
movq 0x28(%rbx), %rsi
movq %rax, 0x80(%rbx)
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x89ee
andq $0x0, 0x80(%rbx)
leaq 0xf(%rsp), %rdi
callq 0x311c
addq $0x10, %rsp
popq %rbx
retq
movq %rax, %rbx
leaq 0xf(%rsp), %rdi
callq 0x311c
movq %rbx, %rdi
callq 0x21c0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: MainTypeCheckVisitor::visit(IdType*)
void MainTypeCheckVisitor::visit(IdType *type) {
    LOG_SCOPE;
    assert(type->is_IdType());
    assert(type->is_defined());
    debug_print("MainTypeCheck::IdType %s\n", type->id);

    this->curr_class = type;
    for (Method *method : type->methods) {
        method->accept(this, type->id);
    }
    this->curr_class = NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xf(%rsp), %rdi
callq 0x3108
testq %r14, %r14
je 0x89b8
cmpl $0x4, 0x4(%r14)
jne 0x89b8
movq 0x8(%r14), %rsi
leaq 0x7fad(%rip), %rdi      # 0x1090d
xorl %eax, %eax
callq 0x317b
movq %r14, 0x80(%rbx)
movq 0x58(%r14), %r15
movq 0x60(%r14), %r12
shlq $0x3, %r12
xorl %r13d, %r13d
cmpq %r13, %r12
je 0x8998
movq (%r15,%r13), %rsi
movq 0x8(%r14), %rdx
movq %rbx, %rdi
callq 0x89ee
addq $0x8, %r13
jmp 0x897d
andq $0x0, 0x80(%rbx)
leaq 0xf(%rsp), %rdi
callq 0x311c
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0x7f11(%rip), %rdi      # 0x108d0
leaq 0x7a28(%rip), %rsi      # 0x103ee
leaq 0x7f15(%rip), %rcx      # 0x108e2
movl $0x2ea, %edx            # imm = 0x2EA
callq 0x20b0
jmp 0x89d9
movq %rax, %rbx
leaq 0xf(%rsp), %rdi
callq 0x311c
movq %rbx, %rdi
callq 0x21c0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: compatible_types(Type*, Type*)
static bool compatible_types(Type *lhs, Type *rhs) {
    if (lhs == rhs) return true;
    IdType *ty1 = lhs->is_IdType();
    IdType *ty2 = rhs->is_IdType();
    if (ty1 && ty2) {
        IdType *runner = ty2;
        while (runner->parent) {
            runner = runner->parent;
            if (runner == ty1) {
                return true;
            }
            // Cyclic inheritance, we issue error elsewhere.
            if (runner == ty2) break;
        }
        return false;
    }
    return false;
}

// Assembly:
cmpq %rsi, %rdi
je 0x8d0c
xorl %eax, %eax
cmpl $0x4, 0x4(%rdi)
cmovneq %rax, %rdi
cmpl $0x4, 0x4(%rsi)
movl $0x0, %ecx
cmoveq %rsi, %rcx
testq %rdi, %rdi
sete %dl
testq %rcx, %rcx
sete %r8b
orb %dl, %r8b
jne 0x8d0b
movq 0x78(%rsi), %rsi
testq %rsi, %rsi
je 0x8d09
cmpq %rdi, %rsi
je 0x8d0c
cmpq %rcx, %rsi
jne 0x8cf6
xorl %eax, %eax
retq
movb $0x1, %al
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: lookup_local(char const*, Method*, IdType*)
static Local *lookup_local(const char *id, Method *method, IdType *cls) {
    // Check current method's locals (vars and params).
    Local *local = method->locals.find(id);
    if (local) {
        return local;
    }
    // Check current class's fields.
    local = cls->fields.find(id);
    if (local) {
        return local;
    }
    // Check parent's fields (account for cyclic inheritance).
    IdType *runner = cls;
    while (runner->parent) {
        runner = runner->parent;
        local = runner->fields.find(id);
        if (local) {
            return local;
        }
        // Cyclic inheritance, we issue error elsewhere.
        if (runner == cls) break;
    }
    return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rdi, %r15
leaq 0x18(%rsi), %rdi
movq %r15, %rsi
callq 0xda72
testq %rax, %rax
jne 0xa904
leaq 0x10(%r14), %rdi
movq %r15, %rsi
callq 0xda72
testq %rax, %rax
je 0xa916
movq %rax, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
xorl %ebx, %ebx
movq %r14, %r12
movq 0x78(%r12), %r12
testq %r12, %r12
je 0xa907
leaq 0x10(%r12), %rdi
movq %r15, %rsi
callq 0xda72
testq %rax, %rax
jne 0xa904
cmpq %r14, %r12
jne 0xa91b
jmp 0xa907
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: typecheck_and_helper(bool, Expression*, MainTypeCheckVisitor*, Type*, Type*)
static Type *typecheck_and_helper(bool is_correct, Expression *expr,
                                  MainTypeCheckVisitor *v, Type *boolty, Type *undefinedty) {
    Type *ty = expr->accept(v);
    if (ty->kind == TY::UNDEFINED) {
        return undefinedty;
    }
    if (ty != boolty) {
        typecheck_error(expr->loc, "Bad right operand for binary operator `&&`. Operand ",
                        "of boolean type was expected, found: `", ty->name(), "`");
        is_correct = false;
    }
    if (is_correct) {
        return boolty;
    }
    return undefinedty;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %r8, %rbx
movq %rcx, %r14
movq %rsi, %r15
movl %edi, %ebp
movq %rdx, %rdi
callq 0x8d10
cmpl $0x0, 0x4(%rax)
je 0xa9d6
cmpq %r14, %rax
je 0xa9cf
movl (%r15), %ebp
movq %rax, %rdi
callq 0x7572
leaq 0x7086(%rip), %rsi      # 0x11a3b
leaq 0x63e5(%rip), %rdx      # 0x10da1
leaq 0x501e(%rip), %r8       # 0xf9e1
movl %ebp, %edi
movq %rax, %rcx
callq 0x7bee
jmp 0xa9d6
testb %bpl, %bpl
cmovneq %r14, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: MainTypeCheckVisitor::visit(BlockStatement*)
void MainTypeCheckVisitor::visit(BlockStatement *block_stmt) {
    LOG_SCOPE;
    debug_print("MainTypeCheck::BlockStatement\n");
    for (Statement *stmt : block_stmt->block) {
        stmt->accept(this);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x7(%rsp), %rdi
callq 0x3108
leaq 0x66fe(%rip), %rdi      # 0x11169
xorl %eax, %eax
callq 0x317b
movq 0x18(%r14), %r15
movq 0x20(%r14), %r14
shlq $0x3, %r15
xorl %r12d, %r12d
cmpq %r12, %r15
je 0xaa99
movq (%r14,%r12), %rdi
movq (%rdi), %rax
movq %rbx, %rsi
callq *0x18(%rax)
addq $0x8, %r12
jmp 0xaa81
leaq 0x7(%rsp), %rdi
callq 0x311c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0xaab1
movq %rax, %rbx
leaq 0x7(%rsp), %rdi
callq 0x311c
movq %rbx, %rdi
callq 0x21c0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: track_while_assignment_for_expr(Expression*, Array<WhileAssign, (MEM)4>)
bool track_while_assignment_for_expr(Expression *expr, FuncArr<WhileAssign> track_buf) {
    switch (expr->kind) {
    case EXPR::ID:
    {
        for (WhileAssign& wa : track_buf) {
            Local *local = wa.local;
            if (expr->id == local->id) {
                if (!wa.used) {
                    if (!wa.assigned) {
                        wa.used = 1;
                    } else {
                        wa.used = 2;
                    }
                }
                break;
            }
        }
    } break;
    case EXPR::ARR_ALLOC:
    case EXPR::ARR_LEN:
    case EXPR::NOT:
    {
        track_while_assignment_for_expr(expr->e1, track_buf);
    } break;
    case EXPR::AND:
    case EXPR::CMP:
    case EXPR::PLUS:
    case EXPR::MINUS:
    case EXPR::TIMES:
    case EXPR::ARR_LOOK:
    {
        BinaryExpression *be = (BinaryExpression *) expr;
        track_while_assignment_for_expr(be->e1, track_buf);
        track_while_assignment_for_expr(be->e2, track_buf);
    } break;
    case EXPR::MSG_SEND:
    {
        BinaryExpression *be = (BinaryExpression *) expr;
        track_while_assignment_for_expr(be->e1, track_buf);
        for (Expression *e : be->msd->expr_list) {
            track_while_assignment_for_expr(e, track_buf);
        }
    } break;
    default: break;
    }
    return false;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
leaq 0x80(%rsp), %r14
leaq 0x18(%rsp), %r15
pushq $0x10
popq %r12
leaq 0x483f(%rip), %r13      # 0x10354
pushq $0x18
popq %rbp
movl 0x4(%rbx), %eax
decl %eax
cmpl $0xd, %eax
ja 0xbc05
movslq (%r13,%rax,4), %rdx
addq %r13, %rdx
movq %r12, %rcx
movq %r15, %rax
jmpq *%rdx
movq 0x10(%rbx), %rdi
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movups (%r14), %xmm0
movups %xmm0, (%rsp)
callq 0xbaec
movq %rbp, %rcx
leaq 0x30(%rsp), %rax
movq (%rbx,%rcx), %rbx
movq 0x10(%r14), %rcx
movq %rcx, 0x10(%rax)
movups (%r14), %xmm0
movups %xmm0, (%rax)
jmp 0xbb18
movq 0x10(%rbx), %rdi
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movups (%r14), %xmm0
movups %xmm0, (%rsp)
callq 0xbaec
movq 0x18(%rbx), %rax
movq 0x10(%rax), %rbx
movq 0x18(%rax), %r15
shlq $0x3, %rbx
xorl %r12d, %r12d
cmpq %r12, %rbx
je 0xbc05
movq (%r15,%r12), %rdi
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movups (%r14), %xmm0
movups %xmm0, (%rsp)
callq 0xbaec
addq $0x8, %r12
jmp 0xbb9a
movq 0x8(%r14), %rdx
movq 0x10(%r14), %rax
shlq $0x4, %rdx
xorl %ecx, %ecx
cmpq %rcx, %rdx
je 0xbc05
movq (%rax,%rcx), %rsi
movq 0x10(%rbx), %rdi
cmpq (%rsi), %rdi
je 0xbbe5
addq $0x10, %rcx
jmp 0xbbcd
movb 0x8(%rax,%rcx), %dl
testb $0xc, %dl
jne 0xbc05
testb $0x3, %dl
setne %sil
shlb $0x2, %sil
addb %dl, %sil
addb $0x4, %sil
movb %sil, 0x8(%rax,%rcx)
xorl %eax, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: get_track_buf(SerializedHashTable<Local*>)
FuncArr<WhileAssign> get_track_buf(SerializedHashTable<Local*> locals) {
    FuncArr<WhileAssign> track_buf(locals.len);
    size_t i = 0;
    for (Local *lo : locals) {
        // Initialize its entry with its local and dumb
        // values for `assigned` and `used` (they will be overriden).
        track_buf.push({lo, 0, 0});
        ++i;
    }
    return track_buf;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x50(%rsp), %r14
movq %r14, %rsi
callq 0xd096
movq 0x48(%rsp), %r15
shlq $0x3, %r14
xorl %r12d, %r12d
cmpq %r12, %r14
je 0xbe88
movq (%r15,%r12), %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0xd0a6
addq $0x8, %r12
jmp 0xbe6f
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: MainTypeCheckVisitor::visit(PrintStatement*)
void MainTypeCheckVisitor::visit(PrintStatement *print_stmt) {
    LOG_SCOPE;
    debug_print("MainTypeCheck::PrintStatement\n");
    // A print statement can have only integer.
    Type *ty = print_stmt->to_print->accept(this);
    poison_stmt(ty);
    if (ty != this->type_table.int_type) {
        typecheck_error(print_stmt->to_print->loc,
                        "Print statement accepts only integer expressions.");
    }
    /// Codegen ///
    llvalue_t to_print = __expr_context.llval;
    cgen_print_stmt(to_print);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x27(%rsp), %rdi
callq 0x3108
leaq 0x4f27(%rip), %rdi      # 0x115a9
xorl %eax, %eax
callq 0x317b
movq 0x10(%rbx), %rsi
movq %r14, %rdi
callq 0x8d10
cmpl $0x0, 0x4(%rax)
je 0xc6d0
cmpq 0x10(%r14), %rax
je 0xc6b3
movq 0x10(%rbx), %rax
movl (%rax), %edi
leaq 0x4f1a(%rip), %rsi      # 0x115c8
callq 0xa93e
leaq 0xc2fe(%rip), %rax      # 0x189b8
movups 0x8(%rax), %xmm0
movups 0x18(%rax), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0x44a1
leaq 0x27(%rsp), %rdi
callq 0x311c
addq $0x28, %rsp
popq %rbx
popq %r14
retq
jmp 0xc6e6
jmp 0xc6e6
movq %rax, %rbx
leaq 0x27(%rsp), %rdi
callq 0x311c
movq %rbx, %rdi
callq 0x21c0
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: Method::Method(MethodDeclaration*)
Method::Method(MethodDeclaration *method_decl) {
    id = method_decl->id;
    size_t locals_size = method_decl->params.len + method_decl->vars.len;
    locals.reserve(locals_size);
    param_len = method_decl->params.len;
    stmts = method_decl->stmts;
    ret_expr = method_decl->ret;
    loc = method_decl->loc;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
addq $0x18, %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x38(%r14)
movups %xmm0, 0x28(%r14)
movups %xmm0, 0x18(%r14)
movups %xmm0, 0x58(%r14)
andq $0x0, 0x68(%r14)
movq 0x18(%rsi), %rax
movq %rax, (%r14)
movq 0x40(%rsi), %rsi
addq 0x28(%rbx), %rsi
callq 0xd17e
movq 0x28(%rbx), %rax
movq %rax, 0x10(%r14)
movups 0x50(%rbx), %xmm0
movups %xmm0, 0x58(%r14)
movq 0x60(%rbx), %rax
movq %rax, 0x68(%r14)
movq 0x68(%rbx), %rax
movq %rax, 0x70(%r14)
movl (%rbx), %eax
movl %eax, 0x50(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: VirtualTable::find(char const*)
VMethod *find(const char *id) {
        ssize_t val = this->hash(id);
        ssize_t index = buckets[val].find(id);
        if (index == -1) {
            return NULL;
        }
        return &vmethods[index];
    }

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl $0xbebca0a0, %eax       # imm = 0xBEBCA0A0
imulq %rsi, %rax
shrq $0x20, %rax
andl $0x1f, %eax
imulq $0x98, %rax, %rax
addq %rax, %rdi
addq $0x8, %rdi
callq 0xd1d6
movq %rax, %rdx
shlq $0x4, %rdx
addq 0x1318(%rbx), %rdx
xorl %ecx, %ecx
cmpq $-0x1, %rax
cmovneq %rdx, %rcx
movq %rcx, %rax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: void typecheck_error_no_ln<char const*, char const*, char const*, char const*>(location_t, char const*, char const*, char const*, char const*)
void typecheck_error_no_ln(location_t __loc, Args... args) {
    ++num_global_typecheck_errors;
    log(__loc);
    yellow_on();
    bold_on();
    log(" Semantic Error: ");
    bold_off();
    yellow_off();
    log(args...);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %r8, %rbx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
incl 0xe13c(%rip)            # 0x1aa88
callq 0xc769
callq 0xc783
callq 0xc79f
leaq 0x526f(%rip), %rdi      # 0x11bd1
callq 0xc7bb
callq 0xc7cc
callq 0xc7e8
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0xc804
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: VirtualTable::insert(Method*, char const*)
void insert(Method *method, const char *enclosing) {
        assert(method);
        // Keep index that it will be pushed in the serial buffer.
        ssize_t index = vmethods.len;
        vmethods.push({method, enclosing});
        // Insert it into the table (giving it an index to keep
        // in the serial buffer)
        const char *method_id = method->id;
        ssize_t val = this->hash(method_id);
        buckets[val].insert(method_id, index);
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rsi, %rsi
je 0xc9e0
movq %rsi, %r14
movq %rdi, %rbx
addq $0x1308, %rdi           # imm = 0x1308
movq 0x1310(%rbx), %r15
callq 0xd278
movq (%r14), %rsi
movl $0xbebca0a0, %eax       # imm = 0xBEBCA0A0
imulq %rsi, %rax
shrq $0x20, %rax
andl $0x1f, %eax
imulq $0x98, %rax, %rax
leaq (%rbx,%rax), %rdi
addq $0x8, %rdi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0xd2c6
leaq 0x3d7a(%rip), %rdi      # 0x10761
leaq 0x3a00(%rip), %rsi      # 0x103ee
leaq 0x4c70(%rip), %rcx      # 0x11665
movl $0xde, %edx
callq 0x20b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./buf.h
// Function: Buf<VMethod>::deep_copy()
Buf<T> deep_copy() {
        Buf<T> copy(cap);
        memcpy(copy.data, data, len * sizeof(T));
        copy.len = len;
        return copy;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq (%rsi), %rsi
callq 0xd8fc
movq 0x10(%r14), %rdi
movq 0x8(%rbx), %rdx
movq 0x10(%rbx), %rsi
shlq $0x4, %rdx
callq 0x20e0
movq 0x8(%rbx), %rax
movq %rax, 0x8(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: VirtualTable::clear()
void clear() {
        nelems = 0;
        vmethods.clear();
        for (ssize_t i = 0; i < nbuckets; ++i) {
            buckets[i].clear();
        }
        deallocate(MEM::VTABLE);
    }

// Assembly:
andq $0x0, (%rdi)
andq $0x0, 0x1310(%rdi)
leaq 0x8(%rdi), %rax
addq $0x98, %rdi
xorl %ecx, %ecx
xorps %xmm0, %xmm0
cmpq $0x1300, %rcx           # imm = 0x1300
je 0xcb73
leaq (%rax,%rcx), %rdx
movups %xmm0, -0x10(%rdi,%rcx)
movq %rdx, (%rdi,%rcx)
addq $0x98, %rcx
jmp 0xcb54
pushq $0x5
popq %rdi
jmp 0x23f5
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./typecheck.h
// Function: SerializedHashTable<IdType*>::reserve(unsigned long)
inline void reserve(size_t n) {
        if (n == 0) {
          return;
        }
        cap = n;
        len = 0;
        serialized = (T *) allocate(cap * sizeof(T), MEM::TYPECHECK);
        assert(serialized);
        table.reserve(cap);
    }

// Assembly:
pushq %rbx
testq %rsi, %rsi
je 0xcc2f
movq %rdi, %rbx
movq %rsi, 0x28(%rdi)
andq $0x0, 0x20(%rdi)
shlq $0x3, %rsi
pushq $0x3
popq %rax
movq %rsi, %rdi
movl %eax, %esi
callq 0x22dc
movq %rax, 0x18(%rbx)
testq %rax, %rax
je 0xcc31
movq 0x28(%rbx), %rsi
movq %rbx, %rdi
popq %rbx
jmp 0xd688
popq %rbx
retq
leaq 0x4cd0(%rip), %rdi      # 0x11908
leaq 0x4cd4(%rip), %rsi      # 0x11913
leaq 0x5061(%rip), %rcx      # 0x11ca7
pushq $0x2d
popq %rdx
callq 0x20b0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./typecheck.h
// Function: SerializedHashTable<IdType*>::insert(char const*, IdType*)
inline bool insert(const char *id, T v) {
        if (len == cap) return false;
        // Insert into HT
        if (table.insert(id, v)) {
            // Insert into serialized data
            serialized[len] = v;
            len = len + 1;
            return true;
        }
        return false;
    }

// Assembly:
movq 0x20(%rdi), %rax
cmpq 0x28(%rdi), %rax
jne 0xcc5b
xorl %eax, %eax
retq
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rdi, %rbx
callq 0xd9ac
testb %al, %al
je 0xcc85
movq 0x18(%rbx), %rax
movq 0x20(%rbx), %rcx
movq %r14, (%rax,%rcx,8)
incq %rcx
movq %rcx, 0x20(%rbx)
movb $0x1, %al
jmp 0xcc87
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./llvm.h
// Function: lbl_pair_t::construct(char const*)
void construct(const char *lbl) {
        long num = gen_lbl();
        size_t len = strlen(lbl);
        size_t alloc_size = len + 10;
        char *pstart = (char *) allocate(alloc_size, MEM::FUNC);
        char *pend = (char *) allocate(alloc_size, MEM::FUNC);
        sprintf(pstart, "%s", lbl);
        sprintf(pend, "%s_end", lbl);
        start.construct(pstart, num);
        end.construct(pend, num);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
callq 0x42c3
movq %rax, %r14
movq %r15, %rdi
callq 0x2080
leaq 0xa(%rax), %r12
pushq $0x4
popq %rbp
movq %r12, %rdi
movl %ebp, %esi
callq 0x22dc
movq %rax, %r13
movq %r12, %rdi
movl %ebp, %esi
callq 0x22dc
movq %rax, %r12
movq %r13, %rdi
movq %r15, %rsi
callq 0x20f0
leaq 0x4c26(%rip), %rsi      # 0x11a70
movq %r12, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x2040
movq %rbx, %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0xcf6c
addq $0x8, %rbx
movq %rbx, %rdi
movq %r12, %rsi
movq %r14, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xcf6c
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./array.h
// Function: Array<llvalue_t, (MEM)4>::push(llvalue_t)
void push(T v) {
        constexpr size_t size_t_max = std::numeric_limits<size_t>::max();
        assert(len < size_t_max);
        assert(len < cap);
        size_t new_len = len + 1;
        data[len] = v;
        len = new_len;
    }

// Assembly:
pushq %rax
movq 0x8(%rdi), %rax
cmpq $-0x1, %rax
je 0xcedd
cmpq (%rdi), %rax
jae 0xcef6
leaq 0x10(%rsp), %rcx
leaq 0x1(%rax), %rdx
movq 0x10(%rdi), %rsi
shlq $0x5, %rax
movups (%rcx), %xmm0
movups 0x10(%rcx), %xmm1
movups %xmm1, 0x10(%rsi,%rax)
movups %xmm0, (%rsi,%rax)
movq %rdx, 0x8(%rdi)
popq %rax
retq
leaq 0x4aa1(%rip), %rdi      # 0x11985
leaq 0x27d1(%rip), %rsi      # 0xf6bc
leaq 0x5057(%rip), %rcx      # 0x11f49
pushq $0x22
jmp 0xcf0d
leaq 0x4aea(%rip), %rdi      # 0x119e7
leaq 0x27b8(%rip), %rsi      # 0xf6bc
leaq 0x503e(%rip), %rcx      # 0x11f49
pushq $0x23
popq %rdx
callq 0x20b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./llvm.h
// Function: llvm_label_t::construct(char const*, long)
void construct(const char *_lbl, long num = -1) {
        assert(_lbl);
        assert(lbl == NULL);
        if (num == -1) {
            num = gen_lbl();
        }

        // Labels are allocated in MEM::FUNC arena.
        // This arena is freed when we finish a method.

        size_t len = strlen(_lbl);
        // Allocate space that will surely be enough.
        size_t alloc_size = len + 20;
        char *p = (char *) allocate(alloc_size, MEM::FUNC);
        // sprintf might be slow.
        sprintf(p, "%s%ld", _lbl, num);
        lbl = (const char *) p;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0xcfd3
movq %rdi, %rbx
cmpq $0x0, (%rdi)
jne 0xcfec
movq %rdx, %r15
movq %rsi, %r14
cmpq $-0x1, %rdx
jne 0xcf96
callq 0x42c3
movq %rax, %r15
movq %r14, %rdi
callq 0x2080
leaq 0x14(%rax), %rdi
pushq $0x4
popq %rsi
callq 0x22dc
movq %rax, %r12
leaq 0x4b77(%rip), %rsi      # 0x11b2b
movq %rax, %rdi
movq %r14, %rdx
movq %r15, %rcx
xorl %eax, %eax
callq 0x2040
movq %r12, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x4b06(%rip), %rdi      # 0x11ae0
leaq 0x4b04(%rip), %rsi      # 0x11ae5
leaq 0x4b06(%rip), %rcx      # 0x11aee
pushq $0x11
jmp 0xd003
leaq 0x4b2c(%rip), %rdi      # 0x11b1f
leaq 0x4aeb(%rip), %rsi      # 0x11ae5
leaq 0x4aed(%rip), %rcx      # 0x11aee
pushq $0x12
popq %rdx
callq 0x20b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./array.h
// Function: Array<llvalue_t, (MEM)4>::reserve(unsigned long)
void reserve(size_t n) {
        assert(len == 0 && cap == 0);
        if (!n) return;
        data = (T *) allocate(n * sizeof(T), mem);
        assert(data);
        len = 0;
        cap = n;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq (%rdi), %rax
orq 0x8(%rdi), %rax
jne 0xd148
movq %rsi, %rbx
testq %rsi, %rsi
je 0xd140
movq %rdi, %r14
movq %rbx, %rdi
shlq $0x5, %rdi
pushq $0x4
popq %rsi
callq 0x22dc
movq %rax, 0x10(%r14)
testq %rax, %rax
je 0xd161
andq $0x0, 0x8(%r14)
movq %rbx, (%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x45e0(%rip), %rdi      # 0x1172f
leaq 0x2566(%rip), %rsi      # 0xf6bc
leaq 0x4feb(%rip), %rcx      # 0x12148
pushq $0x2a
jmp 0xd178
leaq 0x2a3d(%rip), %rdi      # 0xfba5
leaq 0x254d(%rip), %rsi      # 0xf6bc
leaq 0x4fd2(%rip), %rcx      # 0x12148
pushq $0x2d
popq %rdx
callq 0x20b0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: FirstBucket::find(char const*) const
ssize_t find(const char *id) const {
        const Bucket *runner = &b;
        ssize_t lim = bucket_cap;
        ssize_t i = nelems;
        while (i > 0) {
            assert(runner);
            ssize_t lim = bucket_cap - 1;
            if (i < bucket_cap) {
                lim = i - 1;
            }
            ssize_t ndx = runner->find(id, lim);
            if (ndx >= 0) {
              return ndx;
            }
            runner = runner->next;
            i -= bucket_cap;
        }
        return -1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
movq 0x88(%rdi), %rax
pushq $-0x1
popq %rbx
pushq $0x7
popq %r12
testq %rax, %rax
jle 0xd22f
testq %r15, %r15
je 0xd23c
leaq -0x1(%rax), %r13
cmpq $0x8, %rax
movq %r13, %rdx
cmovaeq %r12, %rdx
movq %r15, %rdi
movq %r14, %rsi
callq 0xd25c
testq %rax, %rax
jns 0xd22c
movq 0x80(%r15), %r15
addq $-0x7, %r13
movq %r13, %rax
jmp 0xd1f3
movq %rax, %rbx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0x43ed(%rip), %rdi      # 0x11630
leaq 0x31a4(%rip), %rsi      # 0x103ee
leaq 0x43e6(%rip), %rcx      # 0x11637
movl $0xa4, %edx
callq 0x20b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: Bucket::find(char const*, long) const
ssize_t find(const char *id, ssize_t lim) const {
        for (ssize_t i = 0; i <= lim; ++i) {
            if (method_ids[i] == id) {
              return indexes[i];
            }
        }
        return -1;
    }

// Assembly:
xorl %ecx, %ecx
pushq $-0x1
popq %rax
cmpq %rdx, %rcx
jg 0xd276
cmpq %rsi, (%rdi,%rcx,8)
je 0xd271
incq %rcx
jmp 0xd261
movq 0x40(%rdi,%rcx,8), %rax
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/typecheck.cpp
// Function: FirstBucket::insert(char const*, long)
void insert(const char *method_id, ssize_t index_in_serial_buf) {
        ssize_t index_in_bucket = nelems % bucket_cap;
        if (nelems != 0 && index_in_bucket == 0) {
            // It may have been allocated from a previous downward
            // tree traversal.
            Bucket *b;
            if (last_bucket->next == NULL) {
                b = new Bucket;
                last_bucket->next = b;
            } else {
                b = last_bucket->next;
            }
            last_bucket = b;
        }
        last_bucket->insert(method_id, index_in_serial_buf, index_in_bucket);
        nelems++;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0x88(%rdi), %rcx
movq 0x90(%rdi), %rdi
pushq $0x8
popq %rsi
movq %rcx, %rax
cqto
idivq %rsi
movq %rdx, %r12
testq %rcx, %rcx
sete %al
testq %rdx, %rdx
setne %cl
orb %al, %cl
jne 0xd339
movq 0x80(%rdi), %rdi
testq %rdi, %rdi
jne 0xd332
movl $0x88, %edi
callq 0xd3f8
movq %rax, %rdi
andq $0x0, 0x80(%rax)
movq 0x90(%rbx), %rax
movq %rdi, 0x80(%rax)
movq %rdi, 0x90(%rbx)
movq %r15, %rsi
movq %r14, %rdx
movq %r12, %rcx
callq 0xd400
incq 0x88(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./hash_table.h
// Function: _HashTable<IdType*, (MEM)3>::find(char const*)
inline T find(const char *key) {
        if (!nbuckets) return NULL;
        assert(key);
        size_t bucket = this->hash(key);
        size_t i = bucket;
        bool wrapped = false;
        while (!wrapped) {
            if (this->ids[i] == key) { 
                return this->data[i];
            } else if (this->ids[i] == nullptr) {
                return nullptr;
            }
            ++i;
            if (i == this->nbuckets) i = 0;
            wrapped = (i == bucket);
        }
        return nullptr;
    }

// Assembly:
pushq %rax
movq (%rdi), %rcx
testq %rcx, %rcx
je 0xd4c3
testq %rsi, %rsi
je 0xd4d1
imull $0x5f5e505, %esi, %edx  # imm = 0x5F5E505
imulq %rcx, %rdx
shrq $0x20, %rdx
movq 0x8(%rdi), %r8
xorl %eax, %eax
movq %rdx, %r9
xorl %r10d, %r10d
testb $0x1, %r10b
jne 0xd4cf
movq (%r8,%r9,8), %r10
cmpq %rsi, %r10
je 0xd4c7
testq %r10, %r10
je 0xd4cf
incq %r9
cmpq %rcx, %r9
movl $0x0, %r10d
cmoveq %r10, %r9
cmpq %rdx, %r9
sete %r10b
jmp 0xd496
xorl %eax, %eax
jmp 0xd4cf
movq 0x10(%rdi), %rax
movq (%rax,%r9,8), %rax
popq %rcx
retq
leaq 0x429d(%rip), %rdi      # 0x11775
leaq 0x429a(%rip), %rsi      # 0x11779
leaq 0x42a2(%rip), %rcx      # 0x11788
pushq $0x5e
popq %rdx
callq 0x20b0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./hash_table.h
// Function: _HashTable<Method*, (MEM)3>::reserve(unsigned long)
inline void reserve(size_t nelements) {
        if (nelements) {
            nbuckets = nelements / 0.7;
            ids = (const char **) allocate_zero(nbuckets * sizeof(const char *), mem);
            assert(ids);
            data = (T *) allocate_zero(nbuckets * sizeof(T), mem);
            assert(data);
            for (size_t i = 0; i != nbuckets; ++i) {
                ids[i] = nullptr;
            }
        } else {
            nbuckets = 0;
            ids = NULL;
            data = NULL;
        }
    }

// Assembly:
pushq %rbx
movq %rdi, %rbx
testq %rsi, %rsi
je 0xd5bb
movq %rsi, %xmm0
punpckldq 0x2e78(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1]
subpd 0x2e80(%rip), %xmm0     # 0x103c0
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
addsd %xmm0, %xmm1
divsd 0x2e7c(%rip), %xmm1     # 0x103d0
cvttsd2si %xmm1, %rax
movq %rax, %rcx
sarq $0x3f, %rcx
subsd 0x2e70(%rip), %xmm1     # 0x103d8
cvttsd2si %xmm1, %rdi
andq %rcx, %rdi
orq %rax, %rdi
movq %rdi, (%rbx)
shlq $0x3, %rdi
pushq $0x3
popq %rsi
callq 0x23de
movq %rax, 0x8(%rbx)
testq %rax, %rax
je 0xd5ca
movq (%rbx), %rdi
shlq $0x3, %rdi
pushq $0x3
popq %rsi
callq 0x23de
movq %rax, 0x10(%rbx)
testq %rax, %rax
je 0xd5e3
movq (%rbx), %rax
xorl %ecx, %ecx
cmpq %rcx, %rax
je 0xd5c8
movq 0x8(%rbx), %rdx
andq $0x0, (%rdx,%rcx,8)
incq %rcx
jmp 0xd5a8
xorpd %xmm0, %xmm0
movupd %xmm0, (%rbx)
andq $0x0, 0x10(%rbx)
popq %rbx
retq
leaq 0x4218(%rip), %rdi      # 0x117e9
leaq 0x41a1(%rip), %rsi      # 0x11779
leaq 0x420e(%rip), %rcx      # 0x117ed
pushq $0x29
jmp 0xd5fa
leaq 0x25bb(%rip), %rdi      # 0xfba5
leaq 0x4188(%rip), %rsi      # 0x11779
leaq 0x41f5(%rip), %rcx      # 0x117ed
pushq $0x2b
popq %rdx
callq 0x20b0
// File: /workspace/github_cpp_makefile_star2_O2/baziotis[P]minijava-cpp/./hash_table.h
// Function: _HashTable<IdType*, (MEM)3>::insert(char const*, IdType*)
inline bool insert(const char *key, T value) {
        assert(key);
        assert(nbuckets);
        size_t bucket = this->hash(key);
        size_t i = bucket;
        bool wrapped = false;
        while (!wrapped) {
            if (this->ids[i] == nullptr) {
                this->ids[i] = key;
                this->data[i] = value;
                return true;
            } else if (this->ids[i] == key) {
                printf("\tDUPLICATE: %s\n", key);
                // Duplicates are not allowed
                assert(false);
            }
            ++i;
            if (i == this->nbuckets) i = 0;
            wrapped = (i == bucket); 
        }
        return false;
    }

// Assembly:
pushq %rax
testq %rsi, %rsi
je 0xda40
movq (%rdi), %rcx
testq %rcx, %rcx
je 0xda59
imull $0x5f5e505, %esi, %r8d  # imm = 0x5F5E505
imulq %rcx, %r8
shrq $0x20, %r8
movq 0x8(%rdi), %r9
xorl %eax, %eax
movq %r8, %r10
testb $0x1, %al
jne 0xda0f
movq (%r9,%r10,8), %r11
testq %r11, %r11
je 0xda03
cmpq %rsi, %r11
je 0xda15
incq %r10
cmpq %rcx, %r10
movl $0x0, %eax
cmoveq %rax, %r10
cmpq %r8, %r10
sete %al
jmp 0xd9da
movq %rsi, (%r9,%r10,8)
movq 0x10(%rdi), %rcx
movq %rdx, (%rcx,%r10,8)
notb %al
andb $0x1, %al
popq %rcx
retq
leaq 0x4340(%rip), %rdi      # 0x11d5c
xorl %eax, %eax
callq 0x2030
leaq 0x1c4c(%rip), %rdi      # 0xf676
leaq 0x3d48(%rip), %rsi      # 0x11779
leaq 0x42b2(%rip), %rcx      # 0x11cea
pushq $0x53
popq %rdx
callq 0x20b0
leaq 0x3d2e(%rip), %rdi      # 0x11775
leaq 0x3d2b(%rip), %rsi      # 0x11779
leaq 0x4295(%rip), %rcx      # 0x11cea
pushq $0x46
jmp 0xda3a
leaq 0x42f3(%rip), %rdi      # 0x11d53
leaq 0x3d12(%rip), %rsi      # 0x11779
leaq 0x427c(%rip), %rcx      # 0x11cea
pushq $0x47
jmp 0xda3a
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/graph.cpp
// Function: DHBW::Graph::add_edge(unsigned long, unsigned long)
EdgeId Graph::add_edge(VertexId ep1, VertexId ep2)
{
	_edges.emplace_back(num_edges(),ep1,ep2,*this);
	vertex(ep1).add_edge(num_edges()-1);
	vertex(ep2).add_edge(num_edges()-1);

	return num_edges()-1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x18(%rsp), %r15
movq %rsi, (%r15)
leaq 0x10(%rsp), %r14
movq %rdx, (%r14)
movq 0x20(%rdi), %rax
subq 0x18(%rdi), %rax
addq $0x18, %rdi
sarq $0x5, %rax
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
movq %r15, %rdx
movq %r14, %rcx
movq %rbx, %r8
callq 0x2a68
movq (%r15), %rsi
movq %rbx, %rdi
callq 0x2566
movq 0x20(%rbx), %rsi
subq 0x18(%rbx), %rsi
sarq $0x5, %rsi
decq %rsi
movq %rax, %rdi
callq 0x240a
movq (%r14), %rsi
movq %rbx, %rdi
callq 0x2566
movq 0x20(%rbx), %rsi
subq 0x18(%rbx), %rsi
sarq $0x5, %rsi
decq %rsi
movq %rax, %rdi
callq 0x240a
movq 0x20(%rbx), %rax
subq 0x18(%rbx), %rax
sarq $0x5, %rax
decq %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/graph.cpp
// Function: DHBW::Graph::write_to_file_plain(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
void Graph::write_to_file_plain(std::string const & filename)
{
	std::ofstream outfile(filename.c_str());
	
	// Write cities
	outfile << num_vertices();
	
	// Write edges
	for (Edge const & edge : _edges)
	{
		outfile << "\n" << edge.vertex1() << " " << edge.vertex2();
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x200, %rsp            # imm = 0x200
movq %rdi, %rbx
movq (%rsi), %rsi
movq %rsp, %r14
pushq $0x10
popq %rdx
movq %r14, %rdi
callq 0x2190
movq 0x8(%rbx), %rax
subq (%rbx), %rax
pushq $0x28
popq %rcx
cqto
idivq %rcx
movq %r14, %rdi
movq %rax, %rsi
callq 0x2100
movq 0x18(%rbx), %r12
movq 0x20(%rbx), %r13
leaq 0x18e3(%rip), %rbx      # 0x426e
movq %rsp, %r14
leaq 0x18db(%rip), %r15      # 0x4270
cmpq %r13, %r12
je 0x29d0
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2160
movq 0x8(%r12), %rsi
movq %rax, %rdi
callq 0x2100
movq %rax, %rdi
movq %r15, %rsi
callq 0x2160
movq 0x10(%r12), %rsi
movq %rax, %rdi
callq 0x2100
addq $0x20, %r12
jmp 0x2995
movq %rsp, %rdi
callq 0x21b0
addq $0x200, %rsp            # imm = 0x200
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x29eb
movq %rax, %rbx
movq %rsp, %rdi
callq 0x21b0
movq %rbx, %rdi
callq 0x2200
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/main.cpp
// Function: example_function1(DHBW::Graph&)
VertexId example_function1(Graph & g)
{
	// This method is written unneccessary compliceted to give a better feeling of the use of this class
	// EdgeId and GraphId are internally just the same as unsigned int's. I prefer using the aliases for 
	// better readability.
	EdgeId a;
	for (VertexId i = 0; i < g.num_vertices(); ++i)
	{
		// Get the i-th vertex
		Vertex & v = g.vertex(i);
		EdgeId b = 0;
		for (EdgeId e = 0;  e < v.num_edges(); ++ e)
		{
			++b;
		}
		if ( b > a)
		{
			a = b;
		}
	}
	return a;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
xorl %r14d, %r14d
pushq $-0x1
popq %r13
movq %rbx, %rdi
callq 0x2556
cmpq %rax, %r14
jae 0x3177
movq %rbx, %rdi
movq %r14, %rsi
callq 0x25a6
movq %rax, %r12
movq %r13, %rbp
movq %r12, %rdi
callq 0x23ac
incq %rbp
cmpq %rax, %rbp
jb 0x315b
cmpq %r15, %rbp
cmovaq %rbp, %r15
incq %r14
jmp 0x313d
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/main.cpp
// Function: random_path(DHBW::Graph&, unsigned long, unsigned long)
std::vector<VertexId> random_path(Graph & g, VertexId s, VertexId t)
{
	// Create empty vector
	std::vector<VertexId> path;
	// add first vertex, i.e. s, (represented by its id)
	path.push_back(s);
	
	// random walk :D
	VertexId current = s;
	while (current != t)
	{
		// Get vertex from VertexId
		Vertex & v = g.vertex(current);
		// Ask for number of edges
		EdgeId num_edges = v.num_edges();
		// compute random integer in [0,num_edges-1]
		EdgeId rand_id = rand()%num_edges;
		// Take edge (first take id from v, than get edge from g)
		Edge next_edge = g.edge(v.edge(rand_id));
		// Compute next vertex
		current = next_edge.other_vertex(v.id());
		path.push_back(current);
	}
	return path;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rcx, %r14
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x8(%rsp), %rsi
movq %rdx, (%rsi)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
callq 0x29fe
movq 0x8(%rsp), %rsi
movq %rsp, %rax
movq %rsi, (%rax)
leaq 0x10(%rsp), %r13
cmpq %r14, %rsi
je 0x3241
movq %r15, %rdi
callq 0x25a6
movq %rax, %rbp
movq %rax, %rdi
callq 0x23ac
movq %rax, %r12
callq 0x2050
cltq
xorl %edx, %edx
divq %r12
movq %rbp, %rdi
movq %rdx, %rsi
callq 0x23ba
movq (%rax), %rsi
movq %r15, %rdi
callq 0x25ba
movups (%rax), %xmm0
movups 0x10(%rax), %xmm1
movaps %xmm1, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
movq %rbp, %rdi
callq 0x23f2
movq %r13, %rdi
movq %rax, %rsi
callq 0x24ba
movq (%rax), %rax
movq %rax, (%rsp)
movq %rbx, %rdi
movq %rsp, %rsi
callq 0x29fe
movq (%rsp), %rsi
jmp 0x31c8
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x3259
jmp 0x3259
jmp 0x3259
movq %rax, %r14
movq %rbx, %rdi
callq 0x2ec4
movq %r14, %rdi
callq 0x2200
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/main.cpp
// Function: main
int main()
{	
	// Read graph from input file 
	Graph g("input/graph1.plain");
	// Print to console, std::endl is (almost) equivalent to "\n"
	std::cout << example_function1(g) << std::endl;
}

// Assembly:
pushq %rbx
subq $0x60, %rsp
leaq 0x1024(%rip), %rsi      # 0x429c
leaq 0x10(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x32fe
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
xorl %edx, %edx
callq 0x26ac
leaq 0x10(%rsp), %rdi
callq 0x20a0
leaq 0x30(%rsp), %rdi
callq 0x3128
movq 0x3d25(%rip), %rdi      # 0x6fd8
movq %rax, %rsi
callq 0x2100
movq %rax, %rdi
callq 0x20c0
leaq 0x30(%rsp), %rdi
callq 0x333a
xorl %eax, %eax
addq $0x60, %rsp
popq %rbx
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x20a0
jmp 0x32f6
movq %rax, %rbx
jmp 0x32f6
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x333a
movq %rbx, %rdi
callq 0x2200
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/randomgraph.cpp
// Function: DHBW::create_random_graph(DHBW::Graph&, unsigned long, double, double)
void create_random_graph(Graph & g, VertexId n, double p_edge, double directed)
	{
		assert(g.num_vertices() == 0);
		
		// Add vertices
		for (VertexId i = 0; i < n; ++i)
		{
			g.add_vertex();
		}
		
		// add random edges
		for (VertexId i = 0; i < n; ++i)
		{
			for (VertexId j = 0; j < i or (directed and j < n); ++j)
			{
				// Random number in [0,1]
				double const r = ((double) rand() / (RAND_MAX));
				if (p_edge >= r)
				{
					g.add_edge(j,i);
				}
			}
		}
	}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movsd %xmm1, 0x10(%rsp)
movsd %xmm0, 0x8(%rsp)
movq %rsi, %rbx
movq %rdi, %r14
callq 0x2556
testq %rax, %rax
jne 0x3497
movq %rbx, %r15
subq $0x1, %r15
jb 0x3426
movq %r14, %rdi
callq 0x25c0
jmp 0x3416
xorl %r15d, %r15d
cmpq %rbx, %r15
je 0x348b
xorl %r12d, %r12d
movsd 0x10(%rsp), %xmm0
ucomisd 0xea9(%rip), %xmm0      # 0x42e8
setp %cl
setne %al
cmpq %rbx, %r12
setb %dl
cmpq %r15, %r12
jb 0x3456
orb %cl, %al
andb %dl, %al
je 0x3486
callq 0x2050
cvtsi2sd %eax, %xmm0
divsd 0xe79(%rip), %xmm0      # 0x42e0
movsd 0x8(%rsp), %xmm1
ucomisd %xmm0, %xmm1
jb 0x3481
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x25fc
incq %r12
jmp 0x3431
incq %r15
jmp 0x3429
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0xe72(%rip), %rdi       # 0x4310
leaq 0xe81(%rip), %rsi       # 0x4326
leaq 0xe8a(%rip), %rcx       # 0x4336
pushq $0x9
popq %rdx
callq 0x20f0
// File: /workspace/github_cpp_makefile_star2_O2/DanielWochnik[P]CombOptWS2018/randomgraph.cpp
// Function: DHBW::write_random_graph_to_file(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, double)
void write_random_graph_to_file(VertexId n, std::string const & filename, double directed)
	{
		// Thats a sharp treshhold for connectivity, i.e. the probability that 
		// a random graph with n vertices and p is 
		// 		1, if p > for all p > log(n)/n
		// 		0, if p > for all p < log(n)/n
		// for n -> infinity (that's pretty cool btw!)
		// see also: https://www.math.cmu.edu/~af1p/MAA2005/L2.pdf
		double const p = std::log(n)/n;
		Graph g;
		create_random_graph(g,n,p,directed);
		g.write_to_file(filename);
	}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x40, %rsp
movsd %xmm0, 0x8(%rsp)
movq %rsi, %rbx
movq %rdi, %r14
callq 0x3553
movq %r14, %xmm2
punpckldq 0xe15(%rip), %xmm2 # xmm2 = xmm2[0],mem[0],xmm2[1],mem[1]
subpd 0xe1d(%rip), %xmm2      # 0x4300
movapd %xmm2, %xmm1
unpckhpd %xmm2, %xmm1            # xmm1 = xmm1[1],xmm2[1]
addsd %xmm2, %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, (%rsp)
leaq 0x10(%rsp), %r15
movq %r15, %rdi
callq 0x269c
movq %r15, %rdi
movq %r14, %rsi
movsd (%rsp), %xmm0
movsd 0x8(%rsp), %xmm1
callq 0x33e8
leaq 0x10(%rsp), %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x2934
leaq 0x10(%rsp), %rdi
callq 0x333a
addq $0x40, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x333a
movq %rbx, %rdi
callq 0x2200