LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: 2TallTim[P]modern-raytracing/./vec3.hpp
// Function: vec3::operator+=(vec3 const&)
inline vec3& vec3::operator+=(const vec3& v){
    e[0] += v.x();
    e[1] += v.y();
    e[2] += v.z();
    return *this;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
callq 0x3f50
movq -0x18(%rbp), %rax
addsd (%rax), %xmm0
movsd %xmm0, (%rax)
movq -0x10(%rbp), %rdi
callq 0x3f70
movq -0x18(%rbp), %rax
addsd 0x8(%rax), %xmm0
movsd %xmm0, 0x8(%rax)
movq -0x10(%rbp), %rdi
callq 0x3f90
movq -0x18(%rbp), %rax
addsd 0x10(%rax), %xmm0
movsd %xmm0, 0x10(%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax,%rax)
// File: 2TallTim[P]modern-raytracing/bvh.cpp
// Function: bvh_node::hit(ray const&, double, double, hit_record&) const
bool bvh_node::hit(const ray& r, double t_min, double t_max, hit_record& rec) const {
    if(box.hit(r,t_min,t_max)){
        hit_record left_rec, right_rec;
        bool hit_left = left->hit(r,t_min,t_max,left_rec);
        bool hit_right = right->hit(r,t_min,t_max,right_rec);
        if(hit_left && hit_right){
            rec = left_rec.t < right_rec.t ? left_rec : right_rec;
            return true;
        } else if(hit_left) {
            rec = left_rec;
            return true;
        } else if(hit_right) {
            rec = right_rec;
            return true;
        }
    }
    return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xf0, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movsd %xmm0, -0x20(%rbp)
movsd %xmm1, -0x28(%rbp)
movq %rdx, -0x30(%rbp)
movq -0x10(%rbp), %rdi
movq %rdi, -0xe0(%rbp)
addq $0x28, %rdi
movq -0x18(%rbp), %rsi
movsd -0x20(%rbp), %xmm0
movsd -0x28(%rbp), %xmm1
callq 0x12000
testb $0x1, %al
jne 0x11a1c
jmp 0x11bf0
leaq -0x78(%rbp), %rdi
callq 0x4600
leaq -0xc0(%rbp), %rdi
callq 0x4600
jmp 0x11a33
movq -0xe0(%rbp), %rdi
addq $0x8, %rdi
callq 0x4730
movq %rax, %rdi
movq -0x18(%rbp), %rsi
movsd -0x20(%rbp), %xmm0
movsd -0x28(%rbp), %xmm1
movq (%rdi), %rax
movq (%rax), %rax
leaq -0x78(%rbp), %rdx
callq *%rax
movb %al, -0xe1(%rbp)
jmp 0x11a68
movq -0xe0(%rbp), %rdi
movb -0xe1(%rbp), %al
andb $0x1, %al
movb %al, -0xcd(%rbp)
addq $0x18, %rdi
callq 0x4730
movq %rax, %rdi
movq -0x18(%rbp), %rsi
movsd -0x20(%rbp), %xmm0
movsd -0x28(%rbp), %xmm1
movq (%rdi), %rax
movq (%rax), %rax
leaq -0xc0(%rbp), %rdx
callq *%rax
movb %al, -0xe2(%rbp)
jmp 0x11aae
movb -0xe2(%rbp), %al
andb $0x1, %al
movb %al, -0xce(%rbp)
testb $0x1, -0xcd(%rbp)
je 0x11b63
testb $0x1, -0xce(%rbp)
je 0x11b63
movsd -0x78(%rbp), %xmm1
movsd -0xc0(%rbp), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x11af6
leaq -0x78(%rbp), %rax
movq %rax, -0xf0(%rbp)
jmp 0x11b06
leaq -0xc0(%rbp), %rax
movq %rax, -0xf0(%rbp)
jmp 0x11b06
movq -0xf0(%rbp), %rsi
movq -0x30(%rbp), %rdi
callq 0x4750
movb $0x1, -0x1(%rbp)
movl $0x1, -0xd4(%rbp)
jmp 0x11bc0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0x11be5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0xc0(%rbp), %rdi
callq 0x47e0
jmp 0x11be5
testb $0x1, -0xcd(%rbp)
je 0x11b89
movq -0x30(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x4750
movb $0x1, -0x1(%rbp)
movl $0x1, -0xd4(%rbp)
jmp 0x11bc0
testb $0x1, -0xce(%rbp)
je 0x11bb2
movq -0x30(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
callq 0x4750
movb $0x1, -0x1(%rbp)
movl $0x1, -0xd4(%rbp)
jmp 0x11bc0
jmp 0x11bb4
jmp 0x11bb6
movl $0x0, -0xd4(%rbp)
leaq -0xc0(%rbp), %rdi
callq 0x47e0
leaq -0x78(%rbp), %rdi
callq 0x47e0
movl -0xd4(%rbp), %eax
testl %eax, %eax
je 0x11be3
jmp 0x11be1
jmp 0x11bf4
jmp 0x11bf0
leaq -0x78(%rbp), %rdi
callq 0x47e0
jmp 0x11c02
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0xf0, %rsp
popq %rbp
retq
movq -0xc8(%rbp), %rdi
callq 0x3390
nop
// File: 2TallTim[P]modern-raytracing/./aabb.hpp
// Function: aabb::hit(ray const&, double, double) const
bool hit(const ray& r, double tmin, double tmax) const {
        for (int a = 0; a < 3; a++){
            double invD = 1.0 / r.direction()[a];
            double t0 = (_min[a] - r.origin()[a]) * invD;
            double t1 = (_max[a] - r.origin()[a]) * invD;

            if(invD < 0) std::swap(t0,t1);

            tmin = t0 > tmin ? t0 : tmin;
            tmax = t1 < tmax ? t1 : tmax;

            if (tmax <= tmin) return false;
        }
        return true;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movsd %xmm0, -0x20(%rbp)
movsd %xmm1, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x98(%rbp)
movl $0x0, -0x2c(%rbp)
cmpl $0x3, -0x2c(%rbp)
jge 0x121a4
movq -0x18(%rbp), %rsi
leaq -0x50(%rbp), %rdi
callq 0x3cf0
movl -0x2c(%rbp), %esi
leaq -0x50(%rbp), %rdi
callq 0x12480
movq -0x98(%rbp), %rdi
movsd 0x4fff(%rip), %xmm0     # 0x17060
divsd (%rax), %xmm0
movsd %xmm0, -0x38(%rbp)
movl -0x2c(%rbp), %esi
callq 0x124a0
movsd %xmm0, -0xa8(%rbp)
movq -0x18(%rbp), %rsi
leaq -0x70(%rbp), %rdi
callq 0x3b70
movl -0x2c(%rbp), %esi
leaq -0x70(%rbp), %rdi
callq 0x12480
movsd -0xa8(%rbp), %xmm0
movq -0x98(%rbp), %rdi
subsd (%rax), %xmm0
mulsd -0x38(%rbp), %xmm0
movsd %xmm0, -0x58(%rbp)
addq $0x18, %rdi
movl -0x2c(%rbp), %esi
callq 0x124a0
movsd %xmm0, -0xa0(%rbp)
movq -0x18(%rbp), %rsi
leaq -0x90(%rbp), %rdi
callq 0x3b70
movl -0x2c(%rbp), %esi
leaq -0x90(%rbp), %rdi
callq 0x12480
movsd -0xa0(%rbp), %xmm0
subsd (%rax), %xmm0
mulsd -0x38(%rbp), %xmm0
movsd %xmm0, -0x78(%rbp)
xorps %xmm0, %xmm0
ucomisd -0x38(%rbp), %xmm0
jbe 0x12110
leaq -0x58(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x124c0
movsd -0x58(%rbp), %xmm0
ucomisd -0x20(%rbp), %xmm0
jbe 0x1212b
movsd -0x58(%rbp), %xmm0
movsd %xmm0, -0xb0(%rbp)
jmp 0x12138
movsd -0x20(%rbp), %xmm0
movsd %xmm0, -0xb0(%rbp)
movsd -0xb0(%rbp), %xmm0
movsd %xmm0, -0x20(%rbp)
movsd -0x78(%rbp), %xmm1
movsd -0x28(%rbp), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x12164
movsd -0x78(%rbp), %xmm0
movsd %xmm0, -0xb8(%rbp)
jmp 0x12171
movsd -0x28(%rbp), %xmm0
movsd %xmm0, -0xb8(%rbp)
movsd -0xb8(%rbp), %xmm0
movsd %xmm0, -0x28(%rbp)
movsd -0x28(%rbp), %xmm1
movsd -0x20(%rbp), %xmm0
ucomisd %xmm1, %xmm0
jb 0x12194
movb $0x0, -0x1(%rbp)
jmp 0x121a8
jmp 0x12196
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x1202f
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0xc0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: 2TallTim[P]modern-raytracing/bvh.cpp
// Function: box_compare<0>::operator()(std::shared_ptr<hitable> const&, std::shared_ptr<hitable> const&)
inline bool operator() (const hitable::Ptr& a, const hitable::Ptr& b){
        aabb box_left, box_right;
        if(!a->bounding_box(box_left) || !b->bounding_box(box_right))
            std::cerr << "no bounding box in bvh_node constructor!" << std::endl;
        return box_left.min()[axis] < box_right.min()[axis];
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
leaq -0x48(%rbp), %rdi
callq 0x4890
leaq -0x78(%rbp), %rdi
callq 0x4890
movq -0x10(%rbp), %rdi
callq 0x4730
movq %rax, %rdi
movq (%rdi), %rax
leaq -0x48(%rbp), %rsi
callq *0x8(%rax)
testb $0x1, %al
jne 0x13205
jmp 0x1321f
movq -0x18(%rbp), %rdi
callq 0x4730
movq %rax, %rdi
movq (%rdi), %rax
leaq -0x78(%rbp), %rsi
callq *0x8(%rax)
testb $0x1, %al
jne 0x13241
movq 0xedca(%rip), %rdi      # 0x21ff0
leaq 0x42e2(%rip), %rsi      # 0x1750f
callq 0x3210
movq %rax, %rdi
movq 0xed74(%rip), %rsi      # 0x21fb0
callq 0x3240
leaq -0x90(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x4f00
leaq -0x90(%rbp), %rdi
xorl %esi, %esi
callq 0x12480
movsd (%rax), %xmm0
movsd %xmm0, -0xb0(%rbp)
leaq -0xa8(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x4f00
leaq -0xa8(%rbp), %rdi
xorl %esi, %esi
callq 0x12480
movsd -0xb0(%rbp), %xmm1
movsd (%rax), %xmm0
ucomisd %xmm1, %xmm0
seta %al
andb $0x1, %al
addq $0xb0, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: 0x6D70[P]chip8_emu/src/cpu.cpp
// Function: Cpu::Cpu()
Cpu::Cpu() {
    // clear ram
    for (int i = 0; i < 0x1000; i++) {
        this->state.ram[i] = 0;
    }

    // clear screen
    for (int y = 0; y < VIDEO_HEIGHT; y++) {
        for (int x = 0; x < VIDEO_WIDTH; x++) {
            this->state.video[x][y] = false;
        }
    }

    // load font
    unsigned char chip8_fontset[80] =
    {
            0xF0, 0x90, 0x90, 0x90, 0xF0, // 0
            0x20, 0x60, 0x20, 0x20, 0x70, // 1
            0xF0, 0x10, 0xF0, 0x80, 0xF0, // 2
            0xF0, 0x10, 0xF0, 0x10, 0xF0, // 3
            0x90, 0x90, 0xF0, 0x10, 0x10, // 4
            0xF0, 0x80, 0xF0, 0x10, 0xF0, // 5
            0xF0, 0x80, 0xF0, 0x90, 0xF0, // 6
            0xF0, 0x10, 0x20, 0x40, 0x40, // 7
            0xF0, 0x90, 0xF0, 0x90, 0xF0, // 8
            0xF0, 0x90, 0xF0, 0x10, 0xF0, // 9
            0xF0, 0x90, 0xF0, 0x90, 0x90, // A
            0xE0, 0x90, 0xE0, 0x90, 0xE0, // B
            0xF0, 0x80, 0x80, 0x80, 0xF0, // C
            0xE0, 0x90, 0x90, 0x90, 0xE0, // D
            0xF0, 0x80, 0xF0, 0x80, 0xF0, // E
            0xF0, 0x80, 0xF0, 0x80, 0x80  // F
    };

    for (int i = 0; i < 80; i++) {
        this->state.ram[0x50 + i] = chip8_fontset[i];
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x80(%rbp)
callq 0x3740
movl $0x0, -0xc(%rbp)
cmpl $0x1000, -0xc(%rbp)     # imm = 0x1000
jge 0x25e3
movq -0x80(%rbp), %rax
movslq -0xc(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x25c3
movl $0x0, -0x10(%rbp)
cmpl $0x20, -0x10(%rbp)
jge 0x2632
movl $0x0, -0x14(%rbp)
cmpl $0x40, -0x14(%rbp)
jge 0x2625
movq -0x80(%rbp), %rax
addq $0x1010, %rax           # imm = 0x1010
movslq -0x14(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movslq -0x10(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x25f7
jmp 0x2627
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x25ea
leaq -0x70(%rbp), %rdi
leaq 0x3b83(%rip), %rsi      # 0x61c0
movl $0x50, %edx
callq 0x21b0
movl $0x0, -0x74(%rbp)
cmpl $0x50, -0x74(%rbp)
jge 0x2677
movq -0x80(%rbp), %rax
movslq -0x74(%rbp), %rcx
movb -0x70(%rbp,%rcx), %dl
movl -0x74(%rbp), %ecx
addl $0x50, %ecx
movslq %ecx, %rcx
movb %dl, (%rax,%rcx)
movl -0x74(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x74(%rbp)
jmp 0x264e
addq $0x80, %rsp
popq %rbp
retq
// File: 0x6D70[P]chip8_emu/src/cpu.cpp
// Function: Cpu::load_rom(char*)
void Cpu::load_rom(char *path) {
    FILE *fp = fopen(path, "rb");
    std::filesystem::path p{path};
    fread(&this->state.ram[0x200], 1, (size_t)std::filesystem::file_size(p), fp);
    fclose(fp);

    this->state.pc = 0x200;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x3b6d(%rip), %rsi      # 0x6210
callq 0x2250
movq %rax, -0x18(%rbp)
leaq -0x40(%rbp), %rdi
movq %rdi, -0x68(%rbp)
leaq -0x10(%rbp), %rsi
movl $0x2, %edx
callq 0x3770
movq -0x70(%rbp), %rax
movq -0x68(%rbp), %rdi
addq $0x200, %rax            # imm = 0x200
movq %rax, -0x60(%rbp)
callq 0x2260
movq %rax, -0x58(%rbp)
jmp 0x26df
movq -0x58(%rbp), %rdx
movq -0x60(%rbp), %rdi
movq -0x18(%rbp), %rcx
movl $0x1, %esi
callq 0x22a0
jmp 0x26f7
movq -0x18(%rbp), %rdi
callq 0x2200
jmp 0x2702
movq -0x70(%rbp), %rax
movw $0x200, 0x1860(%rax)    # imm = 0x200
leaq -0x40(%rbp), %rdi
callq 0x3850
addq $0x70, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x40(%rbp), %rdi
callq 0x3850
movq -0x48(%rbp), %rdi
callq 0x22f0
nopl (%rax)
// File: 0x6D70[P]chip8_emu/src/cpu.cpp
// Function: keysym_to_index(SDL_Keysym)
uint8_t keysym_to_index(SDL_Keysym keysym) {
    switch (keysym.sym) {
        case SDLK_1:
            return 0x1;
        case SDLK_2:
            return 0x2;
        case SDLK_3:
            return 0x3;
        case SDLK_4:
            return 0xc;
        
        case SDLK_q:
            return 0x4;
        case SDLK_w:
            return 0x5;
        case SDLK_e:
            return 0x6;
        case SDLK_r:
            return 0xd;
        
        case SDLK_a:
            return 0x7;
        case SDLK_s:
            return 0x8;
        case SDLK_d:
            return 0x9;
        case SDLK_f:
            return 0xe;
        
        case SDLK_z:
            return 0xa;
        case SDLK_x:
            return 0x0;
        case SDLK_c:
            return 0xb;
        case SDLK_v:
            return 0xf;
        
        default:
            return 0xff;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x14(%rbp)
movq %rsi, -0xc(%rbp)
movl -0x10(%rbp), %eax
addl $-0x31, %eax
movl %eax, %ecx
movq %rcx, -0x20(%rbp)
subl $0x49, %eax
ja 0x27d1
movq -0x20(%rbp), %rax
leaq 0x38a8(%rip), %rcx      # 0x6010
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movb $0x1, -0x1(%rbp)
jmp 0x27d5
movb $0x2, -0x1(%rbp)
jmp 0x27d5
movb $0x3, -0x1(%rbp)
jmp 0x27d5
movb $0xc, -0x1(%rbp)
jmp 0x27d5
movb $0x4, -0x1(%rbp)
jmp 0x27d5
movb $0x5, -0x1(%rbp)
jmp 0x27d5
movb $0x6, -0x1(%rbp)
jmp 0x27d5
movb $0xd, -0x1(%rbp)
jmp 0x27d5
movb $0x7, -0x1(%rbp)
jmp 0x27d5
movb $0x8, -0x1(%rbp)
jmp 0x27d5
movb $0x9, -0x1(%rbp)
jmp 0x27d5
movb $0xe, -0x1(%rbp)
jmp 0x27d5
movb $0xa, -0x1(%rbp)
jmp 0x27d5
movb $0x0, -0x1(%rbp)
jmp 0x27d5
movb $0xb, -0x1(%rbp)
jmp 0x27d5
movb $0xf, -0x1(%rbp)
jmp 0x27d5
movb $-0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
popq %rbp
retq
nopw (%rax,%rax)
// File: 0x6D70[P]chip8_emu/src/cpu.cpp
// Function: isKeyPressed(bool*)
bool isKeyPressed(bool keys[0x10]) {
    for (int i = 0; i < 0x10; i++) {
        if (keys[i])
            return true;
    }

    return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
cmpl $0x10, -0x14(%rbp)
jge 0x2816
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
testb $0x1, (%rax,%rcx)
je 0x2809
movb $0x1, -0x1(%rbp)
jmp 0x281a
jmp 0x280b
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x27ef
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: 0x6D70[P]chip8_emu/src/main.cpp
// Function: main
int main(int argc, char **argv) {

	if (argc < 2) {
		std::cout << "no file specified" << std::endl;
		return EXIT_FAILURE;
	}

	SDL_Init(SDL_INIT_EVERYTHING);
		
	SDL_Window *window = SDL_CreateWindow(
		"CHIP8 interpreter",
		SDL_WINDOWPOS_CENTERED,
		SDL_WINDOWPOS_CENTERED,
		VIDEO_WIDTH * VIDEO_MULTI,
		VIDEO_HEIGHT * VIDEO_MULTI,
		SDL_WINDOW_SHOWN
		//SDL_WINDOW_HIDDEN
	);

	SDL_Renderer *renderer = SDL_CreateRenderer(window, -1, 0);
	
	if (window == NULL) {
		std::cout << "Could not create window: " << SDL_GetError() << std::endl;
		return 1;
	}

	Cpu cpu;
	cpu.load_rom(argv[1]);
	cpu.run(renderer);
	
	SDL_Delay(1000);	
	SDL_DestroyWindow(window);	
	SDL_Quit();

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x18b0, %rsp           # imm = 0x18B0
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
cmpl $0x2, -0x8(%rbp)
jge 0x523d
movq 0x3dc2(%rip), %rdi      # 0x8fd8
leaq 0x105c(%rip), %rsi      # 0x6279
callq 0x21f0
movq %rax, %rdi
movq 0x3d9c(%rip), %rsi      # 0x8fc8
callq 0x2230
movl $0x1, -0x4(%rbp)
jmp 0x5361
movl $0xf231, %edi           # imm = 0xF231
callq 0x21d0
leaq 0x103d(%rip), %rdi      # 0x628b
movl $0x2fff0000, %edx       # imm = 0x2FFF0000
movl $0x500, %ecx            # imm = 0x500
movl $0x280, %r8d            # imm = 0x280
movl $0x4, %r9d
movl %edx, %esi
callq 0x2050
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x2040
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x52d3
movq 0x3d47(%rip), %rdi      # 0x8fd8
leaq 0x1005(%rip), %rsi      # 0x629d
callq 0x21f0
movq %rax, -0x18a0(%rbp)
callq 0x2180
movq -0x18a0(%rbp), %rdi
movq %rax, %rsi
callq 0x21f0
movq %rax, %rdi
movq 0x3d06(%rip), %rsi      # 0x8fc8
callq 0x2230
movl $0x1, -0x4(%rbp)
jmp 0x5361
leaq -0x1888(%rbp), %rdi
movq %rdi, -0x18a8(%rbp)
callq 0x25a0
movq -0x18a8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x2680
jmp 0x52fc
movq -0x20(%rbp), %rsi
leaq -0x1888(%rbp), %rdi
callq 0x2830
jmp 0x530e
movl $0x3e8, %edi            # imm = 0x3E8
callq 0x2170
jmp 0x531a
movq -0x18(%rbp), %rdi
callq 0x2030
jmp 0x5325
callq 0x2060
jmp 0x532c
movl $0x0, -0x4(%rbp)
leaq -0x1888(%rbp), %rdi
callq 0x5380
jmp 0x5361
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1890(%rbp)
movl %eax, -0x1894(%rbp)
leaq -0x1888(%rbp), %rdi
callq 0x5380
jmp 0x536d
movl -0x4(%rbp), %eax
addq $0x18b0, %rsp           # imm = 0x18B0
popq %rbp
retq
movq -0x1890(%rbp), %rdi
callq 0x22f0
nopl (%rax)
// File: macfergus[P]baduk/cppsrc/apps/demo.cpp
// Function: print_board(baduk::Board const&)
void print_board(baduk::Board const& board) {
    for (int r = board.numRows() - 1; r >= 0; --r) {
        for (unsigned int c = 0; c < board.numCols(); ++c) {
            baduk::Point p(static_cast<unsigned int>(r), c);
            if (board.isEmpty(p)) {
                std::cout << ".";
            } else {
                const auto stone = board.at(p);
                std::cout << (stone == baduk::Stone::black ? "x" : "o");
            }
        }
        std::cout << "\n";
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
callq 0xb6a0
subl $0x1, %eax
movl %eax, -0xc(%rbp)
cmpl $0x0, -0xc(%rbp)
jl 0x400e0
movl $0x0, -0x10(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
callq 0xb6c0
movl %eax, %ecx
movl -0x30(%rbp), %eax
cmpl %ecx, %eax
jae 0x400bf
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
leaq -0x18(%rbp), %rdi
callq 0x9dc0
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rsi
callq 0x3c650
testb $0x1, %al
jne 0x40052
jmp 0x40067
movq 0xff5f(%rip), %rdi      # 0x4ffb8
leaq 0x15a5(%rip), %rsi      # 0x41605
callq 0x31e0
jmp 0x400af
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movq %rax, -0x2c(%rbp)
movq -0x2c(%rbp), %rsi
callq 0x3d4c0
movl %eax, -0x24(%rbp)
cmpl $0x0, -0x24(%rbp)
jne 0x40092
leaq 0x157b(%rip), %rax      # 0x41607
movq %rax, -0x38(%rbp)
jmp 0x4009f
leaq 0x1570(%rip), %rax      # 0x41609
movq %rax, -0x38(%rbp)
jmp 0x4009f
movq -0x38(%rbp), %rsi
movq 0xff0e(%rip), %rdi      # 0x4ffb8
callq 0x31e0
jmp 0x400b1
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x4000c
movq 0xfef2(%rip), %rdi      # 0x4ffb8
leaq 0x153e(%rip), %rsi      # 0x4160b
callq 0x31e0
movl -0xc(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x3fffb
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: macfergus[P]baduk/cppsrc/apps/demo.cpp
// Function: main
int main() {
        baduk::Board board(19, 19);
        board.place("E4", baduk::Stone::black);
        board.place(baduk::Point(4, 4), baduk::Stone::white);
        board.place(baduk::Point(4, 3), baduk::Stone::black);
        board.place(baduk::Point(4, 5), baduk::Stone::white);
        board.place(baduk::Point(3, 5), baduk::Stone::black);
        board.place(baduk::Point(5, 5), baduk::Stone::black);
        board.place(baduk::Point(5, 4), baduk::Stone::black);
        board.place(baduk::Point(3, 3), baduk::Stone::white);
        board.place(baduk::Point(4, 6), baduk::Stone::black);
        print_board(board);
        return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x5b80, %rsp           # imm = 0x5B80
movl $0x0, -0x4(%rbp)
leaq -0x5b38(%rbp), %rdi
movl $0x13, %edx
movl %edx, %esi
callq 0x3c5b0
leaq -0x5b40(%rbp), %rdi
leaq 0x150f(%rip), %rsi      # 0x41632
callq 0x402b0
movq -0x5b40(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
xorl %edx, %edx
callq 0x3c6f0
leaq -0x5b48(%rbp), %rdi
movl $0x4, %edx
movl %edx, %esi
callq 0x9dc0
movq -0x5b48(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
movl $0x1, %edx
callq 0x3c6f0
leaq -0x5b50(%rbp), %rdi
movl $0x4, %esi
movl $0x3, %edx
callq 0x9dc0
movq -0x5b50(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
xorl %edx, %edx
callq 0x3c6f0
leaq -0x5b58(%rbp), %rdi
movl $0x4, %esi
movl $0x5, %edx
callq 0x9dc0
movq -0x5b58(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
movl $0x1, %edx
callq 0x3c6f0
leaq -0x5b60(%rbp), %rdi
movl $0x3, %esi
movl $0x5, %edx
callq 0x9dc0
movq -0x5b60(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
xorl %edx, %edx
callq 0x3c6f0
leaq -0x5b68(%rbp), %rdi
movl $0x5, %edx
movl %edx, %esi
callq 0x9dc0
movq -0x5b68(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
xorl %edx, %edx
callq 0x3c6f0
leaq -0x5b70(%rbp), %rdi
movl $0x5, %esi
movl $0x4, %edx
callq 0x9dc0
movq -0x5b70(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
xorl %edx, %edx
callq 0x3c6f0
leaq -0x5b78(%rbp), %rdi
movl $0x3, %edx
movl %edx, %esi
callq 0x9dc0
movq -0x5b78(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
movl $0x1, %edx
callq 0x3c6f0
leaq -0x5b80(%rbp), %rdi
movl $0x4, %esi
movl $0x6, %edx
callq 0x9dc0
movq -0x5b80(%rbp), %rsi
leaq -0x5b38(%rbp), %rdi
xorl %edx, %edx
callq 0x3c6f0
leaq -0x5b38(%rbp), %rdi
callq 0x3ffe0
xorl %eax, %eax
addq $0x5b80, %rsp           # imm = 0x5B80
popq %rbp
retq
nopl (%rax)
// File: chahk0129[P]hash_bench/./pcm/cpucounters.h
// Function: PCM::getQPILinksPerSocket() const
uint64 getQPILinksPerSocket() const
    {
        switch (cpu_model)
        {
        case NEHALEM_EP:
        case WESTMERE_EP:
        case CLARKDALE:
            if (num_sockets == 2)
                return 2;
            else
                return 1;
        case NEHALEM_EX:
        case WESTMERE_EX:
            return 4;
        case JAKETOWN:
        case IVYTOWN:
        case HASWELLX:
        case BDX_DE:
        case BDX:
            return (server_pcicfg_uncore.size() && server_pcicfg_uncore[0].get()) ? (server_pcicfg_uncore[0]->getNumQPIPorts()) : 0;
        }
        return 0;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movl 0x4(%rax), %eax
movl %eax, -0x14(%rbp)
subl $0x1a, %eax
je 0x25180
jmp 0x25131
movl -0x14(%rbp), %eax
subl $0x25, %eax
je 0x25180
jmp 0x2513b
movl -0x14(%rbp), %eax
subl $0x2c, %eax
je 0x25180
jmp 0x25145
movl -0x14(%rbp), %eax
subl $0x2d, %eax
je 0x251ae
jmp 0x2514f
movl -0x14(%rbp), %eax
addl $-0x2e, %eax
subl $0x2, %eax
jb 0x251a4
jmp 0x2515c
movl -0x14(%rbp), %eax
addl $-0x3e, %eax
subl $0x2, %eax
jb 0x251ae
jmp 0x25169
movl -0x14(%rbp), %eax
subl $0x4f, %eax
je 0x251ae
jmp 0x25173
movl -0x14(%rbp), %eax
subl $0x56, %eax
je 0x251ae
jmp 0x25222
movq -0x20(%rbp), %rax
cmpl $0x2, 0x18(%rax)
jne 0x25197
movq $0x2, -0x8(%rbp)
jmp 0x2522a
movq $0x1, -0x8(%rbp)
jmp 0x2522a
movq $0x4, -0x8(%rbp)
jmp 0x2522a
movq -0x20(%rbp), %rdi
addq $0xd8, %rdi
callq 0x27d00
cmpq $0x0, %rax
je 0x25210
movq -0x20(%rbp), %rdi
addq $0xd8, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x27d20
movq %rax, %rdi
callq 0x27d40
cmpq $0x0, %rax
je 0x25210
movq -0x20(%rbp), %rdi
addq $0xd8, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x27d20
movq %rax, %rdi
callq 0x27d60
movq %rax, %rdi
callq 0x27d80
movq %rax, -0x28(%rbp)
jmp 0x25218
xorl %eax, %eax
movq %rax, -0x28(%rbp)
jmp 0x25218
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x2522a
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nop
// File: Sooryakiran[P]dotV/src/verilog.cpp
// Function: wire_name(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
wire wire_name(wire full_name){
    /*------------------------------------------------------------------------------------------
    This is a very usefull function to extract the wire name from a wire declaration string.

    Params : full_name (wire), full name including width. Example : "[9:0] my_wire"
    Returns : Parsed string, if input contains infomration about widths. Example : "my_wire"                      
    ------------------------------------------------------------------------------------------*/
    string delim = "] ";
    size_t index;
    if(string::npos != (index = full_name.find(delim, 0))){
        return full_name.substr(index + 2);
    }
    else{
        return full_name;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rsi, -0x78(%rbp)
movq %rdi, -0x70(%rbp)
movq %rdi, %rax
movq %rax, -0x68(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0x60(%rbp)
callq 0x1da80
movq -0x60(%rbp), %rdx
leaq 0x28e49(%rip), %rsi     # 0x47033
leaq -0x30(%rbp), %rdi
callq 0x1d8a0
jmp 0x1e1f5
leaq -0x31(%rbp), %rdi
callq 0x1ca40
movq -0x78(%rbp), %rdi
leaq -0x30(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0x1e020
movq %rax, %rcx
movq %rcx, -0x50(%rbp)
movq $-0x1, %rax
cmpq %rcx, %rax
je 0x1e277
movq -0x78(%rbp), %rsi
movq -0x70(%rbp), %rdi
movq -0x50(%rbp), %rdx
addq $0x2, %rdx
movq $-0x1, %rcx
callq 0x1c910
jmp 0x1e240
movl $0x1, -0x54(%rbp)
jmp 0x1e28b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x31(%rbp), %rdi
callq 0x1ca40
jmp 0x1e2a1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x1bea0
jmp 0x1e2a1
movq -0x78(%rbp), %rsi
movq -0x70(%rbp), %rdi
callq 0x1be00
movl $0x1, -0x54(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x1bea0
movq -0x68(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
movq -0x40(%rbp), %rdi
callq 0x1da60
nopw (%rax,%rax)
// File: Sooryakiran[P]dotV/src/verilog.cpp
// Function: Chip::generate_verilog[abi:cxx11]()
string Chip::generate_verilog(){
    /*------------------------------------------------------------------------------------------
    This function generates a formated output string verilog code.       

    Params : None
    Returns : code (string), output verilog code                          
    ------------------------------------------------------------------------------------------*/
    string code = "// Generated code\n// Sooryakiran P\n// ME17B174\n";
    set<string> headers = this->define_headers();
    for (set<string>::iterator i = headers.begin(); i != headers.end(); i++){
        code += "\n" + *i + "\n";
    }
    return code;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rdi, -0xc0(%rbp)
movq %rdi, %rax
movq %rax, -0xd0(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xc8(%rbp)
movb $0x0, -0x11(%rbp)
leaq -0x12(%rbp), %rdi
movq %rdi, -0xb8(%rbp)
callq 0x1da80
movq -0xc0(%rbp), %rdi
movq -0xb8(%rbp), %rdx
leaq 0x28cf8(%rip), %rsi     # 0x47000
callq 0x1d8a0
jmp 0x1e30f
leaq -0x12(%rbp), %rdi
callq 0x1ca40
movq -0xc8(%rbp), %rsi
leaq -0x58(%rbp), %rdi
callq 0x1cfd0
jmp 0x1e32a
leaq -0x58(%rbp), %rdi
callq 0x1cd80
movq %rax, -0x60(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x1b1b0
movq %rax, -0x68(%rbp)
leaq -0x60(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x1b120
testb $0x1, %al
jne 0x1e35a
jmp 0x1e445
leaq -0x60(%rbp), %rdi
callq 0x1d810
movq %rax, %rdx
leaq 0x28d7b(%rip), %rsi     # 0x470e8
leaq -0xa8(%rbp), %rdi
callq 0x1c5a0
jmp 0x1e37b
leaq 0x28d66(%rip), %rdx     # 0x470e8
leaq -0x88(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
callq 0x1b430
jmp 0x1e397
movq -0xc0(%rbp), %rdi
leaq -0x88(%rbp), %rsi
callq 0x1ce20
jmp 0x1e3ac
leaq -0x88(%rbp), %rdi
callq 0x1bea0
leaq -0xa8(%rbp), %rdi
callq 0x1bea0
leaq -0x60(%rbp), %rdi
xorl %esi, %esi
callq 0x1d110
movq %rax, -0xb0(%rbp)
jmp 0x1e337
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x12(%rbp), %rdi
callq 0x1ca40
jmp 0x1e48d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x1e481
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x1e45a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x1e437
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x88(%rbp), %rdi
callq 0x1bea0
leaq -0xa8(%rbp), %rdi
callq 0x1bea0
jmp 0x1e45a
movb $0x1, -0x11(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x1b5c0
testb $0x1, -0x11(%rbp)
jne 0x1e471
jmp 0x1e465
leaq -0x58(%rbp), %rdi
callq 0x1b5c0
jmp 0x1e481
movq -0xc0(%rbp), %rdi
callq 0x1bea0
movq -0xd0(%rbp), %rax
addq $0xd0, %rsp
popq %rbp
retq
movq -0xc0(%rbp), %rdi
callq 0x1bea0
movq -0x20(%rbp), %rdi
callq 0x1da60
nopw %cs:(%rax,%rax)
// File: Sooryakiran[P]dotV/src/verilog.cpp
// Function: Chip::define_headers[abi:cxx11]()
set<string> Chip::define_headers(){
    /*------------------------------------------------------------------------------------------
    This function recursively iterates through all the submodules if any to generate a set of
    module definitions.         

    Params : None
    Returns : all_headers (set<string>), a set of all module and submodule definitions.                          
    ------------------------------------------------------------------------------------------*/
    set<string> all_headers;
    all_headers.insert(this->definition);

    for(vector<Chip>::iterator sub = this->submodules.begin();
                               sub != this->submodules.end();
                               sub++){
        set<string> sub_header = sub->define_headers();
        all_headers.insert(sub_header.begin(), sub_header.end());
    }

    return all_headers;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0xa8(%rbp)
movq %rdi, %rax
movq %rax, -0xb8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xb0(%rbp)
movb $0x0, -0x11(%rbp)
callq 0x1c540
movq -0xb0(%rbp), %rsi
movq -0xa8(%rbp), %rdi
addq $0x20, %rsi
callq 0x1c880
movb %dl, -0x99(%rbp)
movq %rax, -0x98(%rbp)
jmp 0x1e4fe
movq -0xb0(%rbp), %rdi
movb -0x99(%rbp), %al
movq -0x98(%rbp), %rcx
movq %rcx, -0x38(%rbp)
movb %al, -0x30(%rbp)
addq $0x68, %rdi
callq 0x1bce0
movq %rax, -0x40(%rbp)
movq -0xb0(%rbp), %rdi
addq $0x68, %rdi
callq 0x1bbc0
movq %rax, -0x48(%rbp)
leaq -0x40(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x1b7a0
testb $0x1, %al
jne 0x1e550
jmp 0x1e5ec
leaq -0x40(%rbp), %rdi
callq 0x1b2a0
movq %rax, %rsi
leaq -0x78(%rbp), %rdi
callq 0x1cfd0
jmp 0x1e567
leaq -0x78(%rbp), %rdi
movq %rdi, -0xc0(%rbp)
callq 0x1cd80
movq -0xc0(%rbp), %rdi
movq %rax, -0x80(%rbp)
callq 0x1b1b0
movq -0xa8(%rbp), %rdi
movq %rax, -0x88(%rbp)
movq -0x80(%rbp), %rsi
movq -0x88(%rbp), %rdx
callq 0x1d740
jmp 0x1e5a7
leaq -0x78(%rbp), %rdi
callq 0x1b5c0
leaq -0x40(%rbp), %rdi
xorl %esi, %esi
callq 0x1ba70
movq %rax, -0x90(%rbp)
jmp 0x1e526
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x1e612
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x78(%rbp), %rdi
callq 0x1b5c0
jmp 0x1e612
movb $0x1, -0x11(%rbp)
testb $0x1, -0x11(%rbp)
jne 0x1e602
movq -0xa8(%rbp), %rdi
callq 0x1b5c0
movq -0xb8(%rbp), %rax
addq $0xc0, %rsp
popq %rbp
retq
movq -0xa8(%rbp), %rdi
callq 0x1b5c0
movq -0x20(%rbp), %rdi
callq 0x1da60
nopw (%rax,%rax)
// File: Sooryakiran[P]dotV/src/verilog.cpp
// Function: Chip::num_transistors()
int Chip::num_transistors(){
    /*------------------------------------------------------------------------------------------
    This function recursively iterates through all the submodules and behaviours if any to count
    the number of transistors required to create an instance.

    Params : None
    Returns : total (int), transitor count.                         
    ------------------------------------------------------------------------------------------*/
    int total = this->transistors;
    
    for(vector<Chip>::iterator sub = this->submodules.begin();
                               sub != this->submodules.end();
                               sub++){

        total += sub->num_transistors();
    }

    for(vector<BehaviourModel>::iterator sub = this->behaviours.begin();
                                         sub != this->behaviours.end();
                                         sub ++){
        total += sub->num_transistors;
    }

    return total;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x48(%rbp)
movl 0x60(%rdi), %eax
movl %eax, -0xc(%rbp)
addq $0x68, %rdi
callq 0x1bce0
movq %rax, -0x18(%rbp)
movq -0x48(%rbp), %rdi
addq $0x68, %rdi
callq 0x1bbc0
movq %rax, -0x20(%rbp)
leaq -0x18(%rbp), %rdi
leaq -0x20(%rbp), %rsi
callq 0x1b7a0
testb $0x1, %al
jne 0x1e67b
jmp 0x1e6a3
leaq -0x18(%rbp), %rdi
callq 0x1b2a0
movq %rax, %rdi
callq 0x1c8c0
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
leaq -0x18(%rbp), %rdi
xorl %esi, %esi
callq 0x1ba70
movq %rax, -0x28(%rbp)
jmp 0x1e657
movq -0x48(%rbp), %rdi
addq $0x178, %rdi            # imm = 0x178
callq 0x1c710
movq %rax, -0x30(%rbp)
movq -0x48(%rbp), %rdi
addq $0x178, %rdi            # imm = 0x178
callq 0x1dc10
movq %rax, -0x38(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x1bbe0
testb $0x1, %al
jne 0x1e6de
jmp 0x1e700
leaq -0x30(%rbp), %rdi
callq 0x1dbc0
movl (%rax), %eax
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
leaq -0x30(%rbp), %rdi
xorl %esi, %esi
callq 0x1c2c0
movq %rax, -0x40(%rbp)
jmp 0x1e6b7
movl -0xc(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax)
// File: Sooryakiran[P]dotV/src/verilog.cpp
// Function: BehaviourModel::BehaviourModel(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>>>>)
BehaviourModel::BehaviourModel(vector<string> sense_list){
    /*------------------------------------------------------------------------------------------
    The class constructor. 

    Param: sense_list (vector<string>), Sensitivity list
    ------------------------------------------------------------------------------------------*/
    this->sensitivity_list = sense_list;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rsi, -0x28(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x38(%rbp)
movl $0x0, (%rdi)
addq $0x8, %rdi
movq %rdi, -0x40(%rbp)
callq 0x1dad0
movq -0x38(%rbp), %rdi
addq $0x20, %rdi
movq %rdi, -0x30(%rbp)
callq 0x1dad0
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x1c9a0
jmp 0x2028f
addq $0x40, %rsp
popq %rbp
retq
movq -0x30(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
callq 0x1c100
movq -0x40(%rbp), %rdi
callq 0x1c100
movq -0x18(%rbp), %rdi
callq 0x1da60
nopl (%rax)
// File: Sooryakiran[P]dotV/src/verilog.cpp
// Function: BehaviourModel::add(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool)
void BehaviourModel::add(string lhs, string rhs, bool is_blocking){
    /*------------------------------------------------------------------------------------------
    Adds a new statement to the behaviour model.

    Param: lhs(string), Left hand side of the statement.
    Param: rhs(string), Right hand side of the statment.
    Param: is_blocking(bool), BLOCK/N_BLOCK for blovking or non blocking statements
    ------------------------------------------------------------------------------------------*/
    string asg = (is_blocking)? " = " : " <= " ;
    string expr = lhs + asg + rhs;
    this->statements.push_back(expr);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdx, -0xc0(%rbp)
movq %rsi, -0xb8(%rbp)
movb %cl, %al
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
andb $0x1, %al
movb %al, -0x19(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xb0(%rbp)
movb -0x19(%rbp), %dl
leaq 0x26e1d(%rip), %rcx     # 0x4711e
leaq 0x26e1a(%rip), %rax     # 0x47122
testb $0x1, %dl
cmovneq %rcx, %rax
movq %rax, -0xa8(%rbp)
leaq -0x41(%rbp), %rdi
movq %rdi, -0xa0(%rbp)
callq 0x1da80
movq -0xa8(%rbp), %rsi
movq -0xa0(%rbp), %rdx
leaq -0x40(%rbp), %rdi
callq 0x1d8a0
jmp 0x2033f
leaq -0x41(%rbp), %rdi
callq 0x1ca40
movq -0xb8(%rbp), %rsi
leaq -0x98(%rbp), %rdi
leaq -0x40(%rbp), %rdx
callq 0x1dee0
jmp 0x20361
movq -0xc0(%rbp), %rdx
leaq -0x78(%rbp), %rdi
leaq -0x98(%rbp), %rsi
callq 0x1d3b0
jmp 0x2037a
leaq -0x98(%rbp), %rdi
callq 0x1bea0
movq -0xb0(%rbp), %rdi
addq $0x8, %rdi
leaq -0x78(%rbp), %rsi
callq 0x1bc10
jmp 0x2039c
leaq -0x78(%rbp), %rdi
callq 0x1bea0
leaq -0x40(%rbp), %rdi
callq 0x1bea0
addq $0xc0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x41(%rbp), %rdi
callq 0x1ca40
jmp 0x20414
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
jmp 0x2040b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x98(%rbp), %rdi
callq 0x1bea0
jmp 0x2040b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x78(%rbp), %rdi
callq 0x1bea0
leaq -0x40(%rbp), %rdi
callq 0x1bea0
movq -0x50(%rbp), %rdi
callq 0x1da60
nopl (%rax)
// File: nvanbenschoten[P]byzantine-agreement/src/main.cc
// Function: ValidateCommanderId(std::vector<net::Address, std::allocator<net::Address>>&, int)
void ValidateCommanderId(generals::ProcessList& processes, int commander_id) {
  // Make sure the commander_id is valid
  if (commander_id < 0 || (size_t)commander_id >= processes.size()) {
    throw args::ValidationError("commander_id does not reference a process");
  }
  // Move the commander to the first element in the vector
  std::iter_swap(processes.begin(), processes.begin() + commander_id);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
cmpl $0x0, -0xc(%rbp)
jl 0x8279
movslq -0xc(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x8(%rbp), %rdi
callq 0xcaf0
movq %rax, %rcx
movq -0x68(%rbp), %rax
cmpq %rcx, %rax
jb 0x831c
movb $0x1, -0x45(%rbp)
movl $0x10, %edi
callq 0x6240
movq %rax, -0x78(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x6760
movq -0x70(%rbp), %rdx
leaq 0x2e6b4(%rip), %rsi     # 0x36957
leaq -0x30(%rbp), %rdi
callq 0xc850
jmp 0x82ae
movq -0x78(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0xcb20
jmp 0x82bd
movq -0x78(%rbp), %rdi
movb $0x0, -0x45(%rbp)
leaq 0x4a0ec(%rip), %rsi     # 0x523b8
leaq 0x488d(%rip), %rdx      # 0xcb60
callq 0x6730
jmp 0x8366
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x8300
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x6878
leaq -0x31(%rbp), %rdi
callq 0x6460
testb $0x1, -0x45(%rbp)
jne 0x8311
jmp 0x831a
movq -0x78(%rbp), %rdi
callq 0x6300
jmp 0x835d
movq -0x8(%rbp), %rdi
callq 0xccd0
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rdi
callq 0xccd0
movq %rax, -0x60(%rbp)
movslq -0xc(%rbp), %rsi
leaq -0x60(%rbp), %rdi
callq 0xcd00
movq %rax, -0x58(%rbp)
movq -0x50(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0xcc90
addq $0x80, %rsp
popq %rbp
retq
movq -0x40(%rbp), %rdi
callq 0x6750
nopw %cs:(%rax,%rax)
// File: nvanbenschoten[P]byzantine-agreement/src/main.cc
// Function: ValidateFaultyCount(std::vector<net::Address, std::allocator<net::Address>> const&, int)
void ValidateFaultyCount(const generals::ProcessList& processes, int faulty) {
  if (faulty < 0) {
    throw args::ValidationError("faulty count must be non-negative");
  }
  if ((size_t)faulty + 2 > processes.size()) {
    throw args::ValidationError(
        "the total number of processes must be no less than (faulty + 2)");
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
cmpl $0x0, -0xc(%rbp)
jge 0x8432
movb $0x1, -0x45(%rbp)
movl $0x10, %edi
callq 0x6240
movq %rax, -0x80(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0x78(%rbp)
callq 0x6760
movq -0x78(%rbp), %rdx
leaq 0x2e5cb(%rip), %rsi     # 0x36981
leaq -0x30(%rbp), %rdi
callq 0xc850
jmp 0x83c1
movq -0x80(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0xcb20
jmp 0x83d0
movq -0x80(%rbp), %rdi
movb $0x0, -0x45(%rbp)
leaq 0x49fd9(%rip), %rsi     # 0x523b8
leaq 0x477a(%rip), %rdx      # 0xcb60
callq 0x6730
jmp 0x8521
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x8413
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x6878
leaq -0x31(%rbp), %rdi
callq 0x6460
testb $0x1, -0x45(%rbp)
jne 0x8424
jmp 0x842d
movq -0x80(%rbp), %rdi
callq 0x6300
jmp 0x8518
movslq -0xc(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x88(%rbp)
movq -0x8(%rbp), %rdi
callq 0xcaf0
movq %rax, %rcx
movq -0x88(%rbp), %rax
cmpq %rcx, %rax
jbe 0x850f
movb $0x1, -0x6a(%rbp)
movl $0x10, %edi
callq 0x6240
movq %rax, -0x98(%rbp)
leaq -0x69(%rbp), %rdi
movq %rdi, -0x90(%rbp)
callq 0x6760
movq -0x90(%rbp), %rdx
leaq 0x2e513(%rip), %rsi     # 0x369a3
leaq -0x68(%rbp), %rdi
callq 0xc850
jmp 0x849b
movq -0x98(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0xcb20
jmp 0x84ad
movq -0x98(%rbp), %rdi
movb $0x0, -0x6a(%rbp)
leaq 0x49ef9(%rip), %rsi     # 0x523b8
leaq 0x469a(%rip), %rdx      # 0xcb60
callq 0x6730
jmp 0x8521
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x84f0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x6878
leaq -0x69(%rbp), %rdi
callq 0x6460
testb $0x1, -0x6a(%rbp)
jne 0x8501
jmp 0x850d
movq -0x98(%rbp), %rdi
callq 0x6300
jmp 0x8518
addq $0xa0, %rsp
popq %rbp
retq
movq -0x40(%rbp), %rdi
callq 0x6750
nopw %cs:(%rax,%rax)
// File: nvanbenschoten[P]byzantine-agreement/include/args.h
// Function: args::ValueFlagList<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::vector, args::ValueReader<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>::ParseValue(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
virtual void ParseValue(const std::string &value_) override {
    T v;
#ifdef ARGS_NOEXCEPT
    if (!reader(name, value_, v)) {
      error = Error::Parse;
    }
#else
    reader(name, value_, v);
#endif
    values.insert(std::end(values), v);
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x68(%rbp)
leaq -0x30(%rbp), %rdi
movq %rdi, -0x60(%rbp)
callq 0x65f0
movq -0x68(%rbp), %rsi
movq -0x60(%rbp), %rcx
movq %rsi, %rdi
addq $0xe0, %rdi
addq $0x30, %rsi
movq -0x10(%rbp), %rdx
callq 0x1f900
jmp 0x1fb79
movq -0x68(%rbp), %rdi
addq $0xc8, %rdi
movq %rdi, -0x78(%rbp)
callq 0xb1a0
movq %rax, -0x50(%rbp)
leaq -0x48(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0xb1d0
movq -0x78(%rbp), %rdi
movq -0x48(%rbp), %rsi
leaq -0x30(%rbp), %rdx
callq 0x1ff20
movq %rax, -0x70(%rbp)
jmp 0x1fbb5
movq -0x70(%rbp), %rax
movq %rax, -0x58(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x6878
addq $0x80, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x6878
movq -0x38(%rbp), %rdi
callq 0x6750
nopl (%rax)
// File: nvanbenschoten[P]byzantine-agreement/src/udp_conn.cc
// Function: udp::Client::Send(char const*, unsigned long) const
void Client::Send(const char *buf, size_t size) const {
  auto addr = remote_address_.addr();
  auto addrlen = remote_address_.addr_len();
  if (sendto(sockfd_, buf, size, 0, addr, addrlen) < 0) {
    throw net::SendException();
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x40(%rbp)
addq $0x14, %rdi
callq 0x23390
movq -0x40(%rbp), %rdi
movq %rax, -0x20(%rbp)
addq $0x14, %rdi
callq 0x233a0
movl %eax, %ecx
movq -0x40(%rbp), %rax
movl %ecx, -0x24(%rbp)
movl 0x10(%rax), %edi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %r8
movl -0x24(%rbp), %r9d
xorl %ecx, %ecx
callq 0x6080
cmpq $0x0, %rax
jge 0x22c08
movl $0x180, %edi            # imm = 0x180
callq 0x6240
movq %rax, %rdi
movq %rdi, %rax
movq %rax, -0x48(%rbp)
callq 0x233b0
jmp 0x22bda
movq -0x48(%rbp), %rdi
leaq 0x2fe23(%rip), %rsi     # 0x52a08
leaq 0x844(%rip), %rdx       # 0x23430
callq 0x6730
movq -0x48(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
callq 0x6300
jmp 0x22c0e
addq $0x50, %rsp
popq %rbp
retq
movq -0x30(%rbp), %rdi
callq 0x6750
nopw (%rax,%rax)
// File: nvanbenschoten[P]byzantine-agreement/src/message.cc
// Function: msg::OrderString[abi:cxx11](msg::Order)
std::string OrderString(Order o) {
  switch (o) {
    case Order::RETREAT:
      return "retreat";
    case Order::ATTACK:
      return "attack";
    case Order::NO_ORDER:
      return "no order";
    default:
      throw std::invalid_argument("unexpected Order value");
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x38(%rbp)
movq %rdi, %rax
movq %rax, -0x30(%rbp)
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x24(%rbp)
testl %eax, %eax
je 0x24dc1
jmp 0x24da6
movl -0x24(%rbp), %eax
subl $0x1, %eax
je 0x24e0c
jmp 0x24db0
movl -0x24(%rbp), %eax
subl $0x2, %eax
je 0x24e57
jmp 0x24e9c
leaq -0xd(%rbp), %rdi
movq %rdi, -0x40(%rbp)
callq 0x6760
movq -0x38(%rbp), %rdi
movq -0x40(%rbp), %rdx
leaq 0x12553(%rip), %rsi     # 0x37330
callq 0xc850
jmp 0x24de4
leaq -0xd(%rbp), %rdi
callq 0x6460
jmp 0x24eec
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0xd(%rbp), %rdi
callq 0x6460
jmp 0x24ef6
leaq -0x1d(%rbp), %rdi
movq %rdi, -0x48(%rbp)
callq 0x6760
movq -0x38(%rbp), %rdi
movq -0x48(%rbp), %rdx
leaq 0x12510(%rip), %rsi     # 0x37338
callq 0xc850
jmp 0x24e2f
leaq -0x1d(%rbp), %rdi
callq 0x6460
jmp 0x24eec
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0x1d(%rbp), %rdi
callq 0x6460
jmp 0x24ef6
leaq -0x1e(%rbp), %rdi
movq %rdi, -0x50(%rbp)
callq 0x6760
movq -0x38(%rbp), %rdi
movq -0x50(%rbp), %rdx
leaq 0x124f6(%rip), %rsi     # 0x37369
callq 0xc850
jmp 0x24e7a
leaq -0x1e(%rbp), %rdi
callq 0x6460
jmp 0x24eec
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0x1e(%rbp), %rdi
callq 0x6460
jmp 0x24ef6
movl $0x10, %edi
callq 0x6240
movq %rax, %rdi
movq %rdi, %rax
movq %rax, -0x58(%rbp)
leaq 0x124bb(%rip), %rsi     # 0x37372
callq 0x67f0
jmp 0x24ebe
movq -0x58(%rbp), %rdi
movq 0x2e0ff(%rip), %rsi     # 0x52fc8
movq 0x2e0d8(%rip), %rdx     # 0x52fa8
callq 0x6730
movq -0x58(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
callq 0x6300
jmp 0x24ef6
movq -0x30(%rbp), %rax
addq $0x60, %rsp
popq %rbp
retq
movq -0x18(%rbp), %rdi
callq 0x6750
nop
// File: nvanbenschoten[P]byzantine-agreement/src/message.cc
// Function: msg::operator<(msg::Message const&, msg::Message const&)
bool operator<(const Message& lhs, const Message& rhs) {
  if (lhs.round != rhs.round) {
    return lhs.round < rhs.round;
  }
  if (lhs.ids != rhs.ids) {
    return lhs.ids < rhs.ids;
  }
  return lhs.order < rhs.order;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
je 0x24f34
movq -0x10(%rbp), %rax
movl (%rax), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
setb %al
andb $0x1, %al
movb %al, -0x1(%rbp)
jmp 0x24f81
movq -0x10(%rbp), %rdi
addq $0x8, %rdi
movq -0x18(%rbp), %rsi
addq $0x8, %rsi
callq 0x250d0
testb $0x1, %al
jne 0x24f4f
jmp 0x24f6b
movq -0x10(%rbp), %rdi
addq $0x8, %rdi
movq -0x18(%rbp), %rsi
addq $0x8, %rsi
callq 0x25100
andb $0x1, %al
movb %al, -0x1(%rbp)
jmp 0x24f81
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movq -0x18(%rbp), %rcx
cmpl 0x4(%rcx), %eax
setl %al
andb $0x1, %al
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)