LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/gatecat[P]subprime/subprime.cpp
// Function: (anonymous namespace)::get_config(void*, void**)
void get_config(EGLDisplay dp, EGLConfig *egl_cfg) {
	// TODO: proper config choosing
	int cfg_attrs[] = {EGL_SURFACE_TYPE, EGL_PBUFFER_BIT,
		EGL_RENDERABLE_TYPE, EGL_OPENGL_BIT,
		EGL_COLOR_BUFFER_TYPE, EGL_RGB_BUFFER,
		EGL_RED_SIZE, 8,
		EGL_GREEN_SIZE, 8,
		EGL_BLUE_SIZE, 8,
		EGL_NONE};
	int num_configs;
	SP_CHECK(fn_eglChooseConfig(dp, cfg_attrs, egl_cfg, 1, &num_configs));
	SP_ASSERT(num_configs > 0);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rsi, %rdx
movaps 0x2a18(%rip), %xmm0     # 0xc080
leaq 0x10(%rsp), %rsi
movaps %xmm0, 0x20(%rsi)
movaps 0x29f8(%rip), %xmm0     # 0xc070
movaps %xmm0, 0x10(%rsi)
movaps 0x29dd(%rip), %xmm0     # 0xc060
movaps %xmm0, (%rsi)
movl $0x3038, 0x30(%rsi)     # imm = 0x3038
pushq $0x1
popq %rcx
leaq 0xc(%rsp), %r8
callq *0x6fcd(%rip)           # 0x10668
cmpl $0x1, %eax
jne 0x96af
cmpl $0x0, 0xc(%rsp)
jle 0x96e3
addq $0x48, %rsp
popq %rbx
popq %r14
retq
movl %eax, %ebx
movq 0x6920(%rip), %rax      # 0xffd8
movq (%rax), %r14
callq *0x6fbf(%rip)           # 0x10680
leaq 0x2dd5(%rip), %rsi      # 0xc49d
leaq 0x2e37(%rip), %rdx      # 0xc506
movq %r14, %rdi
movl %ebx, %ecx
movl %eax, %r8d
xorl %eax, %eax
callq 0x7610
callq 0x70f0
movq 0x68ee(%rip), %rax      # 0xffd8
movq (%rax), %rdi
leaq 0x2e4e(%rip), %rsi      # 0xc542
leaq 0x2e6c(%rip), %rdx      # 0xc567
leaq 0x2e72(%rip), %r8       # 0xc574
pushq $0x69
popq %rcx
xorl %eax, %eax
callq 0x7610
callq 0x70f0
// File: /workspace/github_cpp_makefile_star2_O2/gatecat[P]subprime/subprime.cpp
// Function: (anonymous namespace)::get_new_id(_XDisplay*)
XID get_new_id(Display *dpy) {
    XID id;
    XLockDisplay(dpy);
    id = XAllocID(dpy);
    XUnlockDisplay(dpy);
    return id;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x7250
movq %rbx, %rdi
callq *0x48(%rbx)
movq %rax, %r14
movq %rbx, %rdi
callq 0x71f0
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/gatecat[P]subprime/subprime.cpp
// Function: (anonymous namespace)::lookup_drawable(_XDisplay*, unsigned long, __GLXFBConfigRec*)
EGLSurface lookup_drawable(Display *dpy, GLXDrawable drawable, GLXFBConfig cfg = nullptr) {
	if (drawable2surface.count(drawable))
		return drawable2surface.at(drawable).egl_sfc;
	// Create a new backing PBuffer
	EGLDisplay dp = disp();
	EGLConfig egl_cfg;
	if (cfg == nullptr) {
		get_config(dp, &egl_cfg);
	} else {
		egl_cfg = *reinterpret_cast<EGLConfig*>(cfg);
	}
	unsigned width, height;
	std::tie(width, height) = get_drawable_dims(dpy, drawable);
	std::vector<int> attrs{EGL_WIDTH, int(width), EGL_HEIGHT, int(height), EGL_NONE};
	EGLSurface surface = fn_eglCreatePbufferSurface(dp, egl_cfg, attrs.data());
	drawable2surface[drawable].egl_sfc = surface;
	drawable2surface[drawable].width = width;
	drawable2surface[drawable].height = height;
	drawable2surface[drawable].cfg = cfg;
	return surface;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x50, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r12
leaq 0x10(%rsp), %rdi
movq %rsi, (%rdi)
callq 0x985e
testq %rax, %rax
je 0x9773
leaq 0x10(%rsp), %rdi
callq 0x9884
movq (%rax), %r14
jmp 0x9838
callq 0x95e6
movq %rax, %r14
testq %rbx, %rbx
je 0x978a
movq (%rbx), %rax
movq %rax, 0x18(%rsp)
jmp 0x9797
leaq 0x18(%rsp), %rsi
movq %r14, %rdi
callq 0x9657
movq %r12, %rdi
movq %r15, %rsi
callq 0x98b3
movq %rax, %r15
movq %rax, %r13
shrq $0x20, %r13
leaq 0x3c(%rsp), %rsi
movl $0x3057, (%rsi)         # imm = 0x3057
movl %r15d, 0x4(%rsi)
movl $0x3056, 0x8(%rsi)      # imm = 0x3056
movl %r13d, 0xc(%rsi)
movl $0x3038, 0x10(%rsi)     # imm = 0x3038
leaq 0x20(%rsp), %r12
pushq $0x5
popq %rdx
leaq 0xf(%rsp), %rcx
movq %r12, %rdi
callq 0x7870
movq 0x18(%rsp), %rsi
movq (%r12), %rdx
movq %r14, %rdi
callq *0x6e94(%rip)           # 0x10688
movq %rax, %r14
leaq 0x10(%rsp), %rdi
callq 0x990e
movq %r14, (%rax)
leaq 0x10(%rsp), %rdi
callq 0x990e
movl %r15d, 0x8(%rax)
leaq 0x10(%rsp), %rdi
callq 0x990e
movl %r13d, 0xc(%rax)
leaq 0x10(%rsp), %rdi
callq 0x990e
movq %rbx, 0x10(%rax)
leaq 0x20(%rsp), %rdi
callq 0x74a0
movq %r14, %rax
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x74a0
movq %rbx, %rdi
callq 0x7820
// File: /workspace/github_cpp_makefile_star2_O2/gatecat[P]subprime/subprime.cpp
// Function: (anonymous namespace)::get_drawable_dims(_XDisplay*, unsigned long)
std::pair<unsigned, unsigned> get_drawable_dims(Display *dpy, GLXDrawable drawable) {
	Window root;
	int x, y;
	unsigned int width = 0, height = 0, border_width, depth;
	auto st = XGetGeometry(dpy, drawable, &root, &x, &y, &width, &height, &border_width, &depth);
	return std::make_pair(width, height);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x28, %rsp
leaq 0x14(%rsp), %rbx
andl $0x0, (%rbx)
leaq 0x10(%rsp), %r14
andl $0x0, (%r14)
subq $0x8, %rsp
leaq 0x10(%rsp), %rax
leaq 0x14(%rsp), %r10
leaq 0x28(%rsp), %rdx
leaq 0x24(%rsp), %rcx
leaq 0x20(%rsp), %r8
movq %rbx, %r9
pushq %rax
pushq %r10
pushq %r14
callq 0x7670
addq $0x20, %rsp
movl (%rbx), %ecx
movl (%r14), %eax
shlq $0x20, %rax
orq %rcx, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/kulpreet[P]lightning-network-graph-analysis/src/include/support.hpp
// Function: lncentrality::print_edges_with_components(boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, lncentrality::LitVertex, lncentrality::LitEdge, boost::no_property, boost::listS>&)
void print_edges_with_components(LitGraph &g) {
  graph_traits<LitGraph>::vertex_descriptor src, tgt;
  graph_traits<LitGraph>::edge_iterator ei, ei_end;
  for (boost::tie(ei, ei_end) = edges(g); ei != ei_end; ++ei) {
    src = source(*ei, g);
    tgt = target(*ei, g);
    if (degree(src, g) > 1 && degree(src, g) > 1) {
      std::cout << g[src].name << " -- " << g[tgt].name << " [label=\""
                << g[*ei].component << "\"]\n";
    }
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x118a7(%rip), %r15     # 0x19088
leaq 0x118a5(%rip), %r12     # 0x1908d
leaq 0x118a8(%rip), %r13     # 0x19097
movq %rdi, %rbp
movq (%rbp), %rbp
cmpq %rbx, %rbp
je 0x787a
movq 0x18(%rbx), %rax
imulq $0xb8, 0x10(%rbp), %rcx
movq 0x8(%rax,%rcx), %rdx
subq (%rax,%rcx), %rdx
cmpq $0x11, %rdx
jb 0x77f2
leaq (%rax,%rcx), %rsi
addq $0x58, %rsi
imulq $0xb8, 0x18(%rbp), %r14
movq 0x22783(%rip), %rdi     # 0x29fb0
callq 0x72c0
movq %rax, %rdi
movq %r15, %rsi
callq 0x72e0
movq 0x18(%rbx), %rcx
leaq (%rcx,%r14), %rsi
addq $0x58, %rsi
movq %rax, %rdi
callq 0x72c0
movq %rax, %rdi
movq %r12, %rsi
callq 0x72e0
movl 0xf8(%rbp), %esi
movq %rax, %rdi
callq 0x7520
movq %rax, %rdi
movq %r13, %rsi
callq 0x72e0
jmp 0x77f2
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/kulpreet[P]lightning-network-graph-analysis/src/include/algos.hpp
// Function: lncentrality::get_articulation_points(boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, lncentrality::LitVertex, lncentrality::LitEdge, boost::no_property, boost::listS>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
void get_articulation_points(LitGraph &g, string &stem, string &outdir) {
  std::ofstream out;
  std::vector<Vertex> art_points;
  std::pair<std::size_t, std::back_insert_iterator<std::vector<Vertex>>>
      results = biconnected_components(g, get(&LitEdge::component, g),
                                       std::back_inserter(art_points));

  // date, #components, #interesting art points
  out.open(outdir + "/all_ap_stats.csv", std::fstream::out | std::fstream::app);
  out << stem << "," << results.first << "," << art_points.size() << std::endl;
  out.close();

  find_non_singleton_components(art_points, g, stem, outdir);
  sort_and_print_art_points(art_points, g, stem, outdir);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x238, %rsp            # imm = 0x238
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x38(%rsp), %rdi
callq 0x7500
xorps %xmm0, %xmm0
movq %rsp, %rdx
movaps %xmm0, (%rdx)
andq $0x0, 0x10(%rdx)
movl $0xd8, %esi
movq %r15, %rdi
callq 0x91d2
movq %rax, %r12
leaq 0x10dd3(%rip), %rdx     # 0x19134
leaq 0x18(%rsp), %rdi
movq %rbx, %rsi
callq 0x9066
leaq 0x38(%rsp), %rdi
leaq 0x18(%rsp), %rsi
pushq $0x11
popq %rdx
callq 0x7190
leaq 0x18(%rsp), %rdi
callq 0x7180
leaq 0x38(%rsp), %rdi
movq %r14, %rsi
callq 0x72c0
leaq 0x10d28(%rip), %rsi     # 0x190c6
movq %rax, %rdi
callq 0x72e0
movq %rax, %rdi
movq %r12, %rsi
callq 0x7240
leaq 0x10d0e(%rip), %rsi     # 0x190c6
movq %rax, %rdi
callq 0x72e0
movq 0x8(%rsp), %rsi
subq (%rsp), %rsi
sarq $0x3, %rsi
movq %rax, %rdi
callq 0x7240
movq %rax, %rdi
callq 0x71a0
leaq 0x38(%rsp), %rdi
callq 0x7430
movq %rsp, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x7e1c
movq %rsp, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x7c3c
movq %rsp, %rdi
callq 0xa45c
leaq 0x38(%rsp), %rdi
callq 0x7450
addq $0x238, %rsp            # imm = 0x238
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x7180
jmp 0x843e
jmp 0x843b
movq %rax, %rbx
movq %rsp, %rdi
callq 0xa45c
leaq 0x38(%rsp), %rdi
callq 0x7450
movq %rbx, %rdi
callq 0x7550
// File: /workspace/github_cpp_makefile_star2_O2/kulpreet[P]lightning-network-graph-analysis/src/include/degree_stats.hpp
// Function: lncentrality::get_degrees(std::vector<unsigned long, std::allocator<unsigned long>>&, std::vector<unsigned long, std::allocator<unsigned long>>&, std::vector<unsigned long, std::allocator<unsigned long>>&, boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, lncentrality::LitVertex, lncentrality::LitEdge, boost::no_property, boost::listS>&)
void get_degrees(vector<Degree> &in_degrees, vector<Degree> &out_degrees,
                 vector<Degree> &degrees, LitGraph &g) {
  graph_traits<LitGraph>::vertex_iterator i, end;
  for (boost::tie(i, end) = vertices(g); i != end; ++i) {
    in_degrees.push_back(in_degree(*i, g));
    out_degrees.push_back(out_degree(*i, g));
    degrees.push_back(degree(*i, g));
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %rbx
movq %rdx, 0x10(%rsp)
movq %rsi, %r15
movq 0x20(%rcx), %rax
subq 0x18(%rcx), %rax
movq %rdi, %r12
movl $0xb8, %ecx
cqto
idivq %rcx
movq %rax, %r13
pushq $0x8
popq %r14
leaq 0x8(%rsp), %rbp
subq $0x1, %r13
jb 0x8506
movq 0x18(%rbx), %rax
movq (%rax,%r14), %rcx
subq -0x8(%rax,%r14), %rcx
sarq $0x4, %rcx
movq %rcx, 0x8(%rsp)
movq %r12, %rdi
movq %rbp, %rsi
callq 0xe00a
movq 0x18(%rbx), %rax
movq (%rax,%r14), %rcx
subq -0x8(%rax,%r14), %rcx
sarq $0x4, %rcx
movq %rcx, 0x8(%rsp)
movq %r15, %rdi
movq %rbp, %rsi
callq 0xe00a
movq 0x18(%rbx), %rax
movq (%rax,%r14), %rcx
subq -0x8(%rax,%r14), %rcx
sarq $0x4, %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rsp), %rdi
movq %rbp, %rsi
callq 0xe00a
addq $0xb8, %r14
jmp 0x8492
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/sudocode1[P]radio/compiler.cpp
// Function: split(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char)
std::vector<std::string> split(std::string str, char delimiter) {
  std::vector<std::string> result;
  std::stringstream ss(str); // Turn the string into a stream.
  std::string tok;
  
  while(std::getline(ss,tok,delimiter)) {
    result.push_back(tok);
  }
  
  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1b0, %rsp            # imm = 0x1B0
movl %edx, %r14d
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
leaq -0x1c8(%rbp), %rdi
pushq $0x18
popq %rdx
callq 0x21f0
leaq -0x30(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movsbl %r14b, %r14d
leaq -0x1c8(%rbp), %r15
leaq -0x40(%rbp), %r12
movq %r15, %rdi
movq %r12, %rsi
movl %r14d, %edx
callq 0x2260
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x2436
movq %rbx, %rdi
movq %r12, %rsi
callq 0x3508
jmp 0x240d
leaq -0x40(%rbp), %rdi
callq 0x20b0
leaq -0x1c8(%rbp), %rdi
callq 0x20f0
movq %rbx, %rax
addq $0x1b0, %rsp            # imm = 0x1B0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0x247b
movq %rax, %r14
leaq -0x40(%rbp), %rdi
callq 0x20b0
leaq -0x1c8(%rbp), %rdi
callq 0x20f0
movq %rbx, %rdi
callq 0x3544
movq %r14, %rdi
callq 0x2240
// File: /workspace/github_cpp_makefile_star2_O2/sudocode1[P]radio/compiler.cpp
// Function: readIncl(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>*)
void readIncl(std::string fileName, std::vector<std::string> *lines) {
    std::string curLine;
    std::ifstream inclFile(fileName);
    while (std::getline(inclFile, curLine)) {
        (*lines).push_back(curLine);
    }
    inclFile.close();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x228, %rsp            # imm = 0x228
movq %rsi, %rbx
movq %rdi, %rsi
leaq -0x28(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq -0x240(%rbp), %rdi
pushq $0x8
popq %rdx
callq 0x2200
leaq -0x240(%rbp), %r14
leaq -0x38(%rbp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x2030
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x24f1
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3508
jmp 0x24cb
leaq -0x240(%rbp), %rdi
callq 0x2040
leaq -0x240(%rbp), %rdi
callq 0x2050
leaq -0x38(%rbp), %rdi
callq 0x20b0
addq $0x228, %rsp            # imm = 0x228
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2527
movq %rax, %rbx
jmp 0x2536
movq %rax, %rbx
leaq -0x240(%rbp), %rdi
callq 0x2050
leaq -0x38(%rbp), %rdi
callq 0x20b0
movq %rbx, %rdi
callq 0x2240
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/hitable_list.cpp
// Function: hitable_list::hit(ray const&, double, double, hit_record&) const
bool hitable_list::hit(const ray& r, double t_min, double t_max, hit_record& rec) const{
    hit_record temp_rec;
    bool hit_anything = false;
    double closest_so_far = t_max;
    for (auto ht : list){
        if (ht->hit(r,t_min,closest_so_far,temp_rec)){
            hit_anything = true;
            closest_so_far = temp_rec.t;
            rec = temp_rec;
        }
    }
    return hit_anything;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdx, 0x10(%rsp)
movsd %xmm1, 0x8(%rsp)
movsd %xmm0, 0x18(%rsp)
movq %rsi, %r14
xorps %xmm0, %xmm0
leaq 0x30(%rsp), %r15
movups %xmm0, 0x38(%r15)
movups %xmm0, 0x28(%r15)
movups %xmm0, 0x18(%r15)
movups %xmm0, 0x8(%r15)
movq 0x8(%rdi), %r13
movq 0x10(%rdi), %r12
xorl %ebp, %ebp
leaq 0x20(%rsp), %rbx
cmpq %r12, %r13
je 0x3909
movq %rbx, %rdi
movq %r13, %rsi
callq 0x3b16
movq 0x20(%rsp), %rdi
movq (%rdi), %rax
movq %r14, %rsi
movsd 0x18(%rsp), %xmm0
movsd 0x8(%rsp), %xmm1
movq %r15, %rdx
callq *(%rax)
testb %al, %al
je 0x38f9
movsd 0x30(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movq 0x10(%rsp), %rdi
movq %r15, %rsi
callq 0x3a10
movb $0x1, %bpl
leaq 0x28(%rsp), %rdi
callq 0x3b4a
addq $0x10, %r13
jmp 0x38ad
leaq 0x70(%rsp), %rdi
callq 0x3b4a
andb $0x1, %bpl
movl %ebp, %eax
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x3b4a
leaq 0x70(%rsp), %rdi
callq 0x3b4a
movq %rbx, %rdi
callq 0x3300
nop
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/./aabb.hpp
// Function: aabb::surrounding_box(aabb const&, aabb const&)
static aabb surrounding_box(const aabb& box0, const aabb& box1){
        vec3 small( fmin(box0.min().x(), box1.min().x()),
                    fmin(box0.min().y(), box1.min().y()),
                    fmin(box0.min().z(), box1.min().z()));

        vec3 big( fmax(box0.max().x(), box1.max().x()),
                fmax(box0.max().y(), box1.max().y()),
                fmax(box0.max().z(), box1.max().z()));

        return aabb(small,big);
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movsd 0x10(%rsi), %xmm0
movsd 0x10(%rdx), %xmm1
callq 0x30c0
movsd %xmm0, 0x8(%rsp)
movsd 0x28(%r15), %xmm0
movsd 0x28(%r14), %xmm1
callq 0x3220
movupd (%r15), %xmm1
movupd (%r14), %xmm2
movapd %xmm2, %xmm3
minpd %xmm1, %xmm3
cmpunordpd %xmm1, %xmm1
andpd %xmm1, %xmm2
andnpd %xmm3, %xmm1
orpd %xmm2, %xmm1
movupd %xmm1, (%rbx)
movsd 0x8(%rsp), %xmm1
movsd %xmm1, 0x10(%rbx)
movupd 0x18(%r15), %xmm1
movupd 0x18(%r14), %xmm2
movapd %xmm2, %xmm3
maxpd %xmm1, %xmm3
cmpunordpd %xmm1, %xmm1
andpd %xmm1, %xmm2
andnpd %xmm3, %xmm1
orpd %xmm2, %xmm1
movupd %xmm1, 0x18(%rbx)
movsd %xmm0, 0x28(%rbx)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/rng.cpp
// Function: rng::random_in_unit_sphere()
vec3 rng::random_in_unit_sphere(){
    vec3 p;
    do {
        p = 2.0 * vec3(gen01(), gen01(), gen01()) - vec3(1, 1, 1);
    } while(p.squared_length() >= 1.0);
    return p;
}

// Assembly:
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
callq 0x3d54
movapd %xmm0, (%rsp)
callq 0x3d54
movapd %xmm0, 0x10(%rsp)
callq 0x3d54
movapd (%rsp), %xmm3
addsd %xmm0, %xmm0
unpcklpd 0x10(%rsp), %xmm3       # xmm3 = xmm3[0],mem[0]
addpd %xmm3, %xmm3
addpd 0x62bd(%rip), %xmm3     # 0xa070
addsd 0x62ad(%rip), %xmm0     # 0xa068
movapd %xmm3, %xmm1
mulpd %xmm3, %xmm1
unpckhpd %xmm1, %xmm1            # xmm1 = xmm1[1,1]
movapd %xmm3, %xmm2
mulsd %xmm3, %xmm2
addsd %xmm1, %xmm2
movapd %xmm0, %xmm1
mulsd %xmm0, %xmm1
addsd %xmm2, %xmm1
ucomisd 0x6279(%rip), %xmm1     # 0xa060
jae 0x3d7e
movsd %xmm0, 0x10(%rbx)
movupd %xmm3, (%rbx)
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/rng.cpp
// Function: rng::random_in_unit_disk()
vec3 rng::random_in_unit_disk(){
    vec3 p;
    do {
        p = 2.0 * vec3(gen01(),gen01(),0) - vec3(1,1,0);
    } while(p.squared_length() >= 1.0);
    return p;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
callq 0x3d54
movapd %xmm0, (%rsp)
callq 0x3d54
movapd (%rsp), %xmm2
unpcklpd %xmm0, %xmm2            # xmm2 = xmm2[0],xmm0[0]
addpd %xmm2, %xmm2
addpd 0x6248(%rip), %xmm2     # 0xa070
movapd %xmm2, %xmm0
mulpd %xmm2, %xmm0
unpckhpd %xmm0, %xmm0            # xmm0 = xmm0[1,1]
movapd %xmm2, %xmm1
mulsd %xmm2, %xmm1
addsd %xmm0, %xmm1
ucomisd 0x6218(%rip), %xmm1     # 0xa060
jae 0x3e04
andq $0x0, 0x10(%rbx)
movupd %xmm2, (%rbx)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/raytrace.cpp
// Function: color(ray const&, std::shared_ptr<hitable>, int)
vec3 color(const ray &r, hitable::Ptr world, int depth = 0)
{
    hit_record rec;
    if(world->hit(r, 0.001, MAXFLOAT, rec)){
        ray scattered;
        vec3 attenuation;
        vec3 emitted = rec.mat_ptr->emitted();
        if (depth < 5 && rec.mat_ptr->scatter(r, rec, attenuation, scattered)) {
            return emitted + attenuation * color(scattered, world, depth+1);
        }else{
            return emitted;
        }
    } else {
        vec3 unit_direction = unit_vector(r.direction());
        double t = 0.5 * (unit_direction.y() + 1.0);
        return (1.0 - t) * vec3(1.0, 1.0, 1.0) + t * vec3(0.5, 0.7, 1.0);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xe8, %rsp
movl %ecx, %ebp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
leaq 0xa0(%rsp), %rdx
movups %xmm0, 0x38(%rdx)
movups %xmm0, 0x28(%rdx)
movups %xmm0, 0x18(%rdx)
movups %xmm0, 0x8(%rdx)
movq (%r14), %rdi
movq (%rdi), %rax
movsd 0x5dd7(%rip), %xmm0     # 0xa0e0
movsd 0x5dd7(%rip), %xmm1     # 0xa0e8
callq *(%rax)
testb %al, %al
je 0x43df
xorps %xmm0, %xmm0
movaps %xmm0, 0x90(%rsp)
movaps %xmm0, 0x80(%rsp)
andq $0x0, 0x30(%rsp)
movaps %xmm0, 0x70(%rsp)
movaps %xmm0, 0x20(%rsp)
movq 0xd8(%rsp), %rsi
movq (%rsi), %rax
movq %rsp, %rdi
callq *0x8(%rax)
cmpl $0x4, %ebp
jg 0x4450
leaq 0xa0(%rsp), %rdx
movq 0x38(%rdx), %rdi
movq (%rdi), %rax
leaq 0x20(%rsp), %rcx
leaq 0x70(%rsp), %r8
movq %r15, %rsi
callq *(%rax)
testb %al, %al
je 0x4450
leaq 0x40(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x3b16
incl %ebp
leaq 0x50(%rsp), %rdi
leaq 0x70(%rsp), %rsi
movq %r15, %rdx
movl %ebp, %ecx
callq 0x42c8
movsd 0x30(%rsp), %xmm0
mulsd 0x60(%rsp), %xmm0
addsd 0x10(%rsp), %xmm0
movapd 0x20(%rsp), %xmm1
mulpd 0x50(%rsp), %xmm1
addpd (%rsp), %xmm1
movupd %xmm1, (%rbx)
movsd %xmm0, 0x10(%rbx)
leaq 0x48(%rsp), %rdi
callq 0x3b4a
jmp 0x4462
movsd 0x18(%r15), %xmm0
movsd 0x20(%r15), %xmm1
movsd 0x28(%r15), %xmm2
movapd %xmm1, %xmm3
mulsd %xmm1, %xmm3
mulsd %xmm0, %xmm0
addsd %xmm3, %xmm0
mulsd %xmm2, %xmm2
addsd %xmm0, %xmm2
sqrtsd %xmm2, %xmm0
divsd %xmm0, %xmm1
movsd 0x5c47(%rip), %xmm0     # 0xa060
addsd %xmm0, %xmm1
mulsd 0x5ccb(%rip), %xmm1     # 0xa0f0
subsd %xmm1, %xmm0
movapd %xmm1, %xmm2
addsd %xmm0, %xmm2
unpcklpd %xmm1, %xmm1            # xmm1 = xmm1[0,0]
mulpd 0x5d63(%rip), %xmm1     # 0xa1a0
unpcklpd %xmm0, %xmm0            # xmm0 = xmm0[0,0]
addpd %xmm1, %xmm0
movupd %xmm0, (%rbx)
movsd %xmm2, 0x10(%rbx)
jmp 0x4462
movq 0x10(%rsp), %rax
movq %rax, 0x10(%rbx)
movapd (%rsp), %xmm0
movupd %xmm0, (%rbx)
leaq 0xe0(%rsp), %rdi
callq 0x3b4a
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x3b4a
jmp 0x4494
jmp 0x4491
movq %rax, %rbx
leaq 0xe0(%rsp), %rdi
callq 0x3b4a
movq %rbx, %rdi
callq 0x3300
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/./camera.hpp
// Function: camera::camera(vec3, vec3, vec3, double, double, double, double)
camera(vec3 origin_, vec3 aim_, vec3 up_,
           double vfov, double aspect, double aperture, double focus_dist) {
        lens_radius = aperture / 2;
        double theta = vfov*M_PI/180;
        double half_height = tan(theta/2);
        double half_width = aspect*half_height;
        origin = origin_;
        w = unit_vector(origin_ - aim_);
        u = unit_vector(cross(up_, w));
        v = cross(w,u);
        horizontal = 2*half_width*focus_dist*u;
        vertical = 2*half_height*focus_dist*v;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x78, %rsp
movaps %xmm3, 0x30(%rsp)
movaps %xmm1, 0x10(%rsp)
movsd %xmm0, (%rsp)
movq %rdi, %rbx
addq $0x8, %rdi
leaq 0x68(%rbx), %r14
leaq 0x98(%rbx), %r15
mulsd 0x484c(%rip), %xmm2     # 0xa0f0
movsd %xmm2, 0x28(%rsp)
movl $0x90, %edx
xorl %esi, %esi
callq 0x30d0
movsd (%rsp), %xmm0
mulsd 0x488d(%rip), %xmm0     # 0xa150
movsd 0x28(%rsp), %xmm1
movsd %xmm1, (%rbx)
divsd 0x4883(%rip), %xmm0     # 0xa158
mulsd 0x4813(%rip), %xmm0     # 0xa0f0
callq 0x30e0
movapd %xmm0, %xmm1
movapd %xmm0, (%rsp)
movapd 0x10(%rsp), %xmm0
mulsd %xmm1, %xmm0
movapd %xmm0, 0x10(%rsp)
movaps 0xa0(%rsp), %xmm0
movups %xmm0, 0x20(%rbx)
movq 0xb0(%rsp), %rax
movq %rax, 0x30(%rbx)
movsd 0xb0(%rsp), %xmm0
subsd 0xc8(%rsp), %xmm0
movapd 0xa0(%rsp), %xmm1
movupd 0xb8(%rsp), %xmm2
subpd %xmm2, %xmm1
movapd %xmm1, %xmm2
mulpd %xmm1, %xmm2
unpckhpd %xmm2, %xmm2            # xmm2 = xmm2[1,1]
movapd %xmm1, %xmm3
mulsd %xmm1, %xmm3
addsd %xmm2, %xmm3
movapd %xmm0, %xmm2
mulsd %xmm0, %xmm2
addsd %xmm3, %xmm2
sqrtsd %xmm2, %xmm2
divsd %xmm2, %xmm0
unpcklpd %xmm2, %xmm2            # xmm2 = xmm2[0,0]
divpd %xmm2, %xmm1
movupd %xmm1, 0x98(%rbx)
movsd %xmm0, 0xa8(%rbx)
leaq 0x40(%rsp), %r12
leaq 0xd0(%rsp), %rsi
movq %r12, %rdi
movq %r15, %rdx
callq 0x5b35
movsd 0x10(%r12), %xmm0
movapd (%r12), %xmm1
movapd %xmm1, %xmm2
mulpd %xmm1, %xmm2
unpckhpd %xmm2, %xmm2            # xmm2 = xmm2[1,1]
movapd %xmm1, %xmm3
mulsd %xmm1, %xmm3
addsd %xmm2, %xmm3
movapd %xmm0, %xmm2
mulsd %xmm0, %xmm2
addsd %xmm3, %xmm2
sqrtsd %xmm2, %xmm2
divsd %xmm2, %xmm0
unpcklpd %xmm2, %xmm2            # xmm2 = xmm2[0,0]
divpd %xmm2, %xmm1
movupd %xmm1, 0x68(%rbx)
movsd %xmm0, 0x78(%rbx)
leaq 0x60(%rsp), %r12
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x5b35
movq 0x10(%r12), %rax
movq %rax, 0x90(%rbx)
movups (%r12), %xmm0
movups %xmm0, 0x80(%rbx)
movapd 0x10(%rsp), %xmm0
unpcklpd (%rsp), %xmm0           # xmm0 = xmm0[0],mem[0]
addpd %xmm0, %xmm0
movapd 0x30(%rsp), %xmm3
unpcklpd %xmm3, %xmm3            # xmm3 = xmm3[0,0]
mulpd %xmm0, %xmm3
movapd %xmm3, %xmm0
unpcklpd %xmm3, %xmm0            # xmm0 = xmm0[0],xmm3[0]
movupd 0x68(%rbx), %xmm1
mulpd %xmm0, %xmm1
movupd 0x78(%rbx), %xmm0
movupd 0x88(%rbx), %xmm2
movupd %xmm1, 0x38(%rbx)
mulpd %xmm3, %xmm0
movupd %xmm0, 0x48(%rbx)
unpckhpd %xmm3, %xmm3            # xmm3 = xmm3[1,1]
mulpd %xmm2, %xmm3
movupd %xmm3, 0x58(%rbx)
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/./material.hpp
// Function: lambert::scatter(ray const&, hit_record const&, vec3&, ray&) const
virtual bool scatter(const ray& r_in,
                         const hit_record& rec,
                         vec3& attenuation,
                         ray& scattered) const {
        vec3 target = rec.p + rec.normal + rng::random_in_unit_sphere();
        scattered = ray(rec.p, target-rec.p);
        attenuation = albedo;
        return true;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %r8, %r14
movq %rcx, %rbx
movq %rdx, %r15
movsd 0x18(%rdx), %xmm0
addsd 0x30(%rdx), %xmm0
movsd %xmm0, 0x8(%rsp)
movq %rdi, %r12
movupd 0x8(%rdx), %xmm0
movupd 0x20(%rdx), %xmm1
addpd %xmm0, %xmm1
movapd %xmm1, 0x10(%rsp)
leaq 0x20(%rsp), %r13
movq %r13, %rdi
callq 0x3d76
movapd 0x10(%rsp), %xmm2
addpd (%r13), %xmm2
movsd 0x8(%rsp), %xmm1
addsd 0x10(%r13), %xmm1
movupd 0x8(%r15), %xmm0
subsd 0x18(%r15), %xmm1
subpd %xmm0, %xmm2
movups 0x8(%r15), %xmm0
movq 0x18(%r15), %rax
movq %rax, 0x10(%r14)
movups %xmm0, (%r14)
movupd %xmm2, 0x18(%r14)
movsd %xmm1, 0x28(%r14)
movq 0x18(%r12), %rax
movq %rax, 0x10(%rbx)
movups 0x8(%r12), %xmm0
movups %xmm0, (%rbx)
movb $0x1, %al
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/2TallTim[P]modern-raytracing/./material.hpp
// Function: metal::scatter(ray const&, hit_record const&, vec3&, ray&) const
virtual bool scatter(const ray& r_in,
                         const hit_record& rec,
                         vec3& attenuation,
                         ray& scattered) const {
        vec3 reflected = ray::reflect(unit_vector(r_in.direction()), rec.normal);
        scattered = ray(rec.p, reflected + fuzz*rng::random_in_unit_sphere());
        attenuation = albedo;
        return (dot(scattered.direction(), rec.normal) > 0);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r8, %r14
movq %rcx, %r15
movq %rdx, %rbx
movq %rdi, %r12
movsd 0x28(%rsi), %xmm0
movupd 0x18(%rsi), %xmm1
movapd %xmm1, %xmm2
mulpd %xmm1, %xmm2
unpckhpd %xmm2, %xmm2            # xmm2 = xmm2[1,1]
movapd %xmm1, %xmm3
mulsd %xmm1, %xmm3
addsd %xmm2, %xmm3
movapd %xmm0, %xmm2
mulsd %xmm0, %xmm2
addsd %xmm3, %xmm2
sqrtsd %xmm2, %xmm2
divsd %xmm2, %xmm0
unpcklpd %xmm2, %xmm2            # xmm2 = xmm2[0,0]
divpd %xmm2, %xmm1
leaq 0x10(%rsp), %rsi
movapd %xmm1, (%rsi)
movsd %xmm0, 0x10(%rsi)
addq $0x20, %rdx
leaq 0x30(%rsp), %r13
movq %r13, %rdi
callq 0x60c4
movsd 0x20(%r12), %xmm0
movaps %xmm0, (%rsp)
leaq 0x10(%rsp), %rbp
movq %rbp, %rdi
callq 0x3d76
movsd 0x10(%rbp), %xmm0
movapd (%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd 0x10(%r13), %xmm0
movups 0x8(%rbx), %xmm1
movq 0x18(%rbx), %rax
movq %rax, 0x10(%r14)
movups %xmm1, (%r14)
unpcklpd %xmm2, %xmm2            # xmm2 = xmm2[0,0]
mulpd (%rbp), %xmm2
addpd (%r13), %xmm2
movupd %xmm2, 0x18(%r14)
movsd %xmm0, 0x28(%r14)
movq 0x18(%r12), %rax
movq %rax, 0x10(%r15)
movups 0x8(%r12), %xmm0
movups %xmm0, (%r15)
movsd 0x18(%r14), %xmm0
movsd 0x20(%r14), %xmm1
mulsd 0x28(%rbx), %xmm1
mulsd 0x20(%rbx), %xmm0
movsd 0x28(%r14), %xmm2
addsd %xmm1, %xmm0
mulsd 0x30(%rbx), %xmm2
addsd %xmm0, %xmm2
xorpd %xmm0, %xmm0
ucomisd %xmm0, %xmm2
seta %al
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xa0, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r12
addq $0x28, %rdi
movsd %xmm0, (%rsp)
movsd %xmm1, 0x8(%rsp)
callq 0x79aa
testb %al, %al
je 0x7702
xorpd %xmm0, %xmm0
leaq 0x58(%rsp), %r14
movupd %xmm0, 0x38(%r14)
movupd %xmm0, 0x28(%r14)
movupd %xmm0, 0x18(%r14)
movupd %xmm0, 0x8(%r14)
movupd %xmm0, 0x48(%rsp)
movupd %xmm0, 0x38(%rsp)
movupd %xmm0, 0x28(%rsp)
movupd %xmm0, 0x18(%rsp)
movq 0x8(%r12), %rdi
movq (%rdi), %rax
movq %r15, %rsi
movsd (%rsp), %xmm0
movsd 0x8(%rsp), %xmm1
movq %r14, %rdx
callq *(%rax)
movl %eax, %ebp
movq 0x18(%r12), %rdi
movq (%rdi), %rax
leaq 0x10(%rsp), %r12
movq %r15, %rsi
movsd (%rsp), %xmm0
movsd 0x8(%rsp), %xmm1
movq %r12, %rdx
callq *(%rax)
movl %ebp, %ecx
andb %al, %cl
cmpb $0x1, %cl
jne 0x76b7
movsd 0x10(%rsp), %xmm0
ucomisd 0x58(%rsp), %xmm0
cmovaq %r14, %r12
jmp 0x76c5
orb %bpl, %al
testb %bpl, %bpl
cmovneq %r14, %r12
testb %al, %al
je 0x76eb
movq %rbx, %rdi
movq %r12, %rsi
callq 0x3a10
leaq 0x50(%rsp), %rdi
callq 0x3b4a
leaq 0x98(%rsp), %rdi
callq 0x3b4a
movb $0x1, %al
jmp 0x7704
leaq 0x50(%rsp), %rdi
callq 0x3b4a
leaq 0x98(%rsp), %rdi
callq 0x3b4a
xorl %eax, %eax
addq $0xa0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x7716
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x3b4a
leaq 0x98(%rsp), %rdi
callq 0x3b4a
movq %rbx, %rdi
callq 0x3300
// File: /workspace/github_cpp_makefile_star2_O2/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:
leaq 0x18(%rsi), %rax
xorl %edx, %edx
movsd 0x26a8(%rip), %xmm2     # 0xa060
xorpd %xmm3, %xmm3
movq %rdx, %rcx
cmpq $0x3, %rdx
je 0x7a62
movq 0x10(%rax), %rdx
movq %rdx, -0x8(%rsp)
movups (%rax), %xmm4
movaps %xmm4, -0x18(%rsp)
movapd %xmm2, %xmm4
divsd -0x18(%rsp,%rcx,8), %xmm4
movsd (%rdi,%rcx,8), %xmm5
movq 0x10(%rsi), %rdx
movq %rdx, -0x8(%rsp)
movups (%rsi), %xmm6
movaps %xmm6, -0x18(%rsp)
subsd -0x18(%rsp,%rcx,8), %xmm5
mulsd %xmm4, %xmm5
movsd 0x18(%rdi,%rcx,8), %xmm6
movq 0x10(%rsi), %rdx
movq %rdx, -0x8(%rsp)
movups (%rsi), %xmm7
movaps %xmm7, -0x18(%rsp)
subsd -0x18(%rsp,%rcx,8), %xmm6
mulsd %xmm4, %xmm6
ucomisd %xmm4, %xmm3
movapd %xmm6, %xmm7
ja 0x7a33
movapd %xmm5, %xmm7
maxsd %xmm0, %xmm7
cmpltsd %xmm3, %xmm4
andpd %xmm4, %xmm5
andnpd %xmm6, %xmm4
orpd %xmm5, %xmm4
minsd %xmm1, %xmm4
leaq 0x1(%rcx), %rdx
ucomisd %xmm4, %xmm7
movapd %xmm7, %xmm0
movapd %xmm4, %xmm1
jb 0x79bc
cmpq $0x3, %rcx
setae %al
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 %rbx
subq $0x60, %rsp
movq %rdx, %rbx
xorps %xmm0, %xmm0
leaq 0x30(%rsp), %rax
movaps %xmm0, 0x20(%rax)
movaps %xmm0, 0x10(%rax)
movaps %xmm0, (%rax)
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
movaps %xmm0, (%rsp)
movq (%rsi), %rdi
movq (%rdi), %rcx
movq %rax, %rsi
callq *0x8(%rcx)
testb %al, %al
je 0x8037
movq (%rbx), %rdi
movq (%rdi), %rax
movq %rsp, %rsi
callq *0x8(%rax)
testb %al, %al
jne 0x8052
movq 0x7fb2(%rip), %rdi      # 0xfff0
leaq 0x2533(%rip), %rsi      # 0xa578
callq 0x31d0
movq %rax, %rdi
callq 0x3090
movsd (%rsp), %xmm0
ucomisd 0x30(%rsp), %xmm0
seta %al
addq $0x60, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
pushq %rbx
pushq %rax
movq %rdi, %rbx
addq $0x1810, %rdi           # imm = 0x1810
callq 0x2eb4
xorl %eax, %eax
cmpq $0x1000, %rax           # imm = 0x1000
je 0x249a
movb $0x0, (%rbx,%rax)
incq %rax
jmp 0x2489
leaq 0x1010(%rbx), %rax
xorl %ecx, %ecx
cmpq $0x20, %rcx
je 0x24c6
xorl %edx, %edx
cmpq $0x800, %rdx            # imm = 0x800
je 0x24be
movb $0x0, (%rax,%rdx)
addq $0x20, %rdx
jmp 0x24ab
incq %rcx
incq %rax
jmp 0x24a3
xorl %eax, %eax
leaq 0x1c41(%rip), %rcx      # 0x4110
cmpq $0x50, %rax
je 0x24e1
movb (%rax,%rcx), %dl
movb %dl, 0x50(%rbx,%rax)
incq %rax
jmp 0x24cf
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rax
movq %rdi, %rbx
leaq -0x28(%rbp), %r15
movq %rsi, (%r15)
leaq 0x1c55(%rip), %rsi      # 0x4160
movq %rax, %rdi
callq 0x2220
movq %rax, %r14
leaq -0x50(%rbp), %r12
pushq $0x2
popq %rdx
movq %r12, %rdi
movq %r15, %rsi
callq 0x2e26
movq %r12, %rdi
callq 0x2230
leaq 0x200(%rbx), %rdi
pushq $0x1
popq %rsi
movq %rax, %rdx
movq %r14, %rcx
callq 0x2260
movq %r14, %rdi
callq 0x21f0
movw $0x200, 0x1860(%rbx)    # imm = 0x200
leaq -0x50(%rbp), %rdi
callq 0x2e94
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x2e94
movq %rbx, %rdi
callq 0x22a0
// File: /workspace/github_cpp_makefile_star2_O2/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
shrq $0x20, %rdi
leal -0x61(%rdi), %eax
cmpl $0x19, %eax
ja 0x25a4
leaq 0x1a89(%rip), %rcx      # 0x4020
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movb $0x7, %al
jmp 0x25fa
addl $-0x31, %edi
cmpl $0x3, %edi
ja 0x25c0
leaq 0x1a5d(%rip), %rax      # 0x4010
movslq (%rax,%rdi,4), %rcx
addq %rax, %rcx
jmpq *%rcx
movb $0x1, %al
jmp 0x25fa
movb $-0x1, %al
jmp 0x25fa
movb $0x8, %al
jmp 0x25fa
movb $0x5, %al
jmp 0x25fa
movb $0xe, %al
jmp 0x25fa
movb $0xb, %al
jmp 0x25fa
xorl %eax, %eax
jmp 0x25fa
movb $0x4, %al
jmp 0x25fa
movb $0x9, %al
jmp 0x25fa
movb $0x6, %al
jmp 0x25fa
movb $0xd, %al
jmp 0x25fa
movb $0xf, %al
jmp 0x25fa
movb $0xa, %al
jmp 0x25fa
movb $0x3, %al
jmp 0x25fa
movb $0xc, %al
jmp 0x25fa
movb $0x2, %al
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
xorl %ecx, %ecx
movq %rcx, %rax
cmpq $0x10, %rcx
je 0x2615
leaq 0x1(%rax), %rcx
cmpb $0x1, (%rdi,%rax)
jne 0x2602
cmpq $0x10, %rax
setb %al
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1870, %rsp           # imm = 0x1870
cmpl $0x1, %edi
jg 0x34f2
movq 0x2af2(%rip), %rdi      # 0x5fd8
leaq 0xcef(%rip), %rsi       # 0x41dc
jmp 0x35ab
movq %rsi, %r14
movl $0xf231, %edi           # imm = 0xF231
callq 0x21b0
leaq 0xce8(%rip), %rdi       # 0x41ee
pushq $0x4
popq %r9
movl $0x2fff0000, %esi       # imm = 0x2FFF0000
movl $0x2fff0000, %edx       # imm = 0x2FFF0000
movl $0x500, %ecx            # imm = 0x500
movl $0x280, %r8d            # imm = 0x280
callq 0x2050
movq %rax, %rbx
pushq $-0x1
popq %rsi
movq %rax, %rdi
xorl %edx, %edx
callq 0x2040
testq %rbx, %rbx
je 0x358a
movq %rax, %r15
leaq -0x1888(%rbp), %r12
movq %r12, %rdi
callq 0x2472
movq 0x8(%r14), %rsi
movq %r12, %rdi
callq 0x24e8
leaq -0x1888(%rbp), %rdi
movq %r15, %rsi
callq 0x261e
movl $0x3e8, %edi            # imm = 0x3E8
callq 0x2150
movq %rbx, %rdi
callq 0x2030
callq 0x2060
leaq -0x78(%rbp), %rdi
callq 0x35e0
xorl %eax, %eax
jmp 0x35bb
movq 0x2a47(%rip), %rdi      # 0x5fd8
leaq 0xc68(%rip), %rsi       # 0x4200
callq 0x21e0
movq %rax, %rbx
callq 0x2160
movq %rbx, %rdi
movq %rax, %rsi
callq 0x21e0
movq %rax, %rdi
callq 0x2100
pushq $0x1
popq %rax
addq $0x1870, %rsp           # imm = 0x1870
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x78(%rbp), %rdi
callq 0x35e0
movq %rbx, %rdi
callq 0x22a0
nop
// File: /workspace/github_cpp_makefile_star2_O2/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
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl 0x8(%rdi), %eax
leal 0x7fffffff(%rax), %r12d
leaq 0x946(%rip), %r15       # 0x115c8
movq 0x6327(%rip), %r14      # 0x16fb0
movabsq $0x100000000, %rbp      # imm = 0x100000000
decq %rax
testl %eax, %eax
js 0x10d1e
movq %rax, 0x10(%rsp)
andl $0x7fffffff, %r12d      # imm = 0x7FFFFFFF
movq %r12, 0x8(%rsp)
xorl %r13d, %r13d
movl 0xc(%rbx), %eax
cmpq %rax, %r13
jae 0x10cf9
movq %rbx, %rdi
movq %r12, %rsi
callq 0xfa38
movq %r15, %rsi
testb %al, %al
jne 0x10ce9
movq %rbx, %rdi
movq %r12, %rsi
callq 0x10118
leaq 0x8ec(%rip), %rsi       # 0x115ca
testl %eax, %eax
je 0x10ce9
leaq 0x8e3(%rip), %rsi       # 0x115cc
movq %r14, %rdi
callq 0x3160
incq %r13
addq %rbp, %r12
jmp 0x10cb2
movq %r14, %rdi
leaq 0x8cb(%rip), %rsi       # 0x115ce
callq 0x3160
movq 0x8(%rsp), %r12
addl $0x7fffffff, %r12d      # imm = 0x7FFFFFFF
movq 0x10(%rsp), %rax
jmp 0x10c93
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x5b40, %rsp           # imm = 0x5B40
leaq 0x10(%rsp), %rbx
pushq $0x13
popq %rdx
movq %rbx, %rdi
movl %edx, %esi
callq 0xf9ce
leaq 0x89d(%rip), %rsi       # 0x115f2
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x10e24
movq (%r14), %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0xfa5c
movabsq $0x400000004, %r14      # imm = 0x400000004
pushq $0x1
popq %rbp
movq %rbx, %rdi
movq %r14, %rsi
movl %ebp, %edx
callq 0xfa5c
movabsq $0x300000003, %r15      # imm = 0x300000003
leaq 0x1(%r15), %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0xfa5c
movabsq $0x500000003, %r12      # imm = 0x500000003
leaq 0x1(%r12), %rsi
movq %rbx, %rdi
movl %ebp, %edx
callq 0xfa5c
movq %rbx, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0xfa5c
addq $0x2, %r12
movq %rbx, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0xfa5c
incq %r14
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0xfa5c
movq %rbx, %rdi
movq %r15, %rsi
movl %ebp, %edx
callq 0xfa5c
movabsq $0x600000004, %rsi      # imm = 0x600000004
movq %rbx, %rdi
xorl %edx, %edx
callq 0xfa5c
movq %rbx, %rdi
callq 0x10c60
xorl %eax, %eax
addq $0x5b40, %rsp           # imm = 0x5B40
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/chahk0129[P]hash_bench/./bench/benchmark.h
// Function: benchmark_t<unsigned long>::benchmark_t(bool)
benchmark_t(bool enable_pcm){
	    if(enable_pcm){
		pcm = PCM::getInstance();
		auto status = pcm->program();
		if(status != PCM::Success){
		    std::cout << "Error opening PCM: " << status << std::endl;
		    exit(0);
		}
	    }
	    else
		pcm = nullptr;
	}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
andq $0x0, (%rdi)
testl %esi, %esi
je 0x9da4
callq 0x18d90
movq %rax, 0x18(%rbx)
movq %rax, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x1d140
movl %eax, %ebp
testl %eax, %eax
je 0x9da9
movq 0x30239(%rip), %rdi     # 0x39fb8
leaq 0x207fd(%rip), %rsi     # 0x2a583
callq 0x53f0
movq %rax, %rdi
movl %ebp, %esi
callq 0x5710
movq %rax, %rdi
callq 0x51e0
xorl %edi, %edi
callq 0x54d0
andq $0x0, 0x18(%rbx)
popq %rbx
popq %r14
popq %rbp
retq
jmp 0x9db0
movq %rax, %r14
movq %rbx, %rdi
callq 0xac06
movq %r14, %rdi
callq 0x5740
nop
// File: /workspace/github_cpp_makefile_star2_O2/chahk0129[P]hash_bench/./pcm/cpucounters.h
// Function: SystemCounterState::SystemCounterState()
SystemCounterState() :
        uncoreTSC(0)
    {
        PCM * m = PCM::getInstance();
        incomingQPIPackets.resize(m->getNumSockets(),
                                  std::vector<uint64>((uint32)m->getQPILinksPerSocket(), 0));
        outgoingQPIIdleFlits.resize(m->getNumSockets(),
                                    std::vector<uint64>((uint32)m->getQPILinksPerSocket(), 0));
        outgoingQPIDataNonDataFlits.resize(m->getNumSockets(),
                                           std::vector<uint64>((uint32)m->getQPILinksPerSocket(), 0));
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
movq %rdi, %r12
xorps %xmm0, %xmm0
movups %xmm0, 0x38(%rdi)
movups %xmm0, 0x28(%rdi)
movups %xmm0, 0x18(%rdi)
movups %xmm0, 0x8(%rdi)
movl $0x80000000, 0xa0(%rdi) # imm = 0x80000000
movups %xmm0, 0x48(%rdi)
movups %xmm0, 0x58(%rdi)
movups %xmm0, 0x68(%rdi)
movups %xmm0, 0x78(%rdi)
andq $0x0, 0x98(%rdi)
movups %xmm0, 0x88(%rdi)
movups %xmm0, 0xa8(%rdi)
movups %xmm0, 0xb8(%rdi)
addq $0xd0, %rdi
movl $0x90, %edx
xorl %esi, %esi
callq 0x5230
leaq 0x2b6ff(%rip), %rax     # 0x39a20
movq %rax, (%r12)
leaq 0x2b714(%rip), %rax     # 0x39a40
movq %rax, 0xc8(%r12)
leaq 0x160(%r12), %rbx
leaq 0x178(%r12), %r14
leaq 0x190(%r12), %r15
xorps %xmm0, %xmm0
movups %xmm0, 0x160(%r12)
movups %xmm0, 0x170(%r12)
movups %xmm0, 0x180(%r12)
movups %xmm0, 0x190(%r12)
movups %xmm0, 0x1a0(%r12)
callq 0x18d90
movq %rax, %r12
movq %rax, %rdi
callq 0x124c0
movl %eax, %ebp
movq %r12, %rdi
callq 0xe4de
movl %eax, %esi
leaq 0x28(%rsp), %rdx
andq $0x0, (%rdx)
leaq 0x10(%rsp), %rdi
leaq 0xf(%rsp), %rcx
callq 0xe54c
movl %ebp, %esi
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
callq 0xe4a2
leaq 0x10(%rsp), %rdi
callq 0xe8e4
movq %r12, %rdi
callq 0x124c0
movl %eax, %ebp
movq %r12, %rdi
callq 0xe4de
movl %eax, %esi
leaq 0x28(%rsp), %rdx
andq $0x0, (%rdx)
leaq 0x10(%rsp), %rdi
leaq 0xf(%rsp), %rcx
callq 0xe54c
movl %ebp, %esi
leaq 0x10(%rsp), %rdx
movq %r14, %rdi
callq 0xe4a2
leaq 0x10(%rsp), %rdi
callq 0xe8e4
movq %r12, %rdi
callq 0x124c0
movl %eax, %ebp
movq %r12, %rdi
callq 0xe4de
movl %eax, %esi
leaq 0x28(%rsp), %rdx
andq $0x0, (%rdx)
leaq 0x10(%rsp), %rdi
leaq 0xf(%rsp), %rcx
callq 0xe54c
movl %ebp, %esi
leaq 0x10(%rsp), %rdx
movq %r15, %rdi
callq 0xe4a2
leaq 0x10(%rsp), %rdi
callq 0xe8e4
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0xe46c
jmp 0xe47f
jmp 0xe47f
jmp 0xe46c
jmp 0xe47f
jmp 0xe47f
movq %rax, %r12
leaq 0x10(%rsp), %rdi
callq 0xe8e4
jmp 0xe482
jmp 0xe47f
jmp 0xe47f
movq %rax, %r12
movq %r15, %rdi
callq 0xe5a2
movq %r14, %rdi
callq 0xe5a2
movq %rbx, %rdi
callq 0xe5a2
movq %r12, %rdi
callq 0x5740