LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/parth-shel[P]xpac/installed_packages_modules.cpp
// Function: rewrite_installed_packages()
void rewrite_installed_packages(){
	std::fstream file;
	file.open(installed_file, std::ios::out | std::ios::trunc);

	for(auto itr = user_installed_list.begin(); itr!=user_installed_list.end(); itr++) {
		file << itr->first << " " << itr->second << "\n";
	}

	file.close();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x218, %rsp            # imm = 0x218
leaq -0x238(%rbp), %rbx
movq %rbx, %rdi
callq 0x3400
leaq 0x662a(%rip), %rsi      # 0xf5b0
pushq $0x30
popq %rdx
movq %rbx, %rdi
callq 0x3490
movq 0x6650(%rip), %r15      # 0xf5e8
leaq -0x228(%rbp), %rbx
leaq 0x6632(%rip), %r13      # 0xf5d8
leaq 0x1548(%rip), %r14      # 0xa4f5
leaq 0x1816(%rip), %r12      # 0xa7ca
cmpq %r13, %r15
je 0x8ff4
leaq 0x20(%r15), %rsi
movq %rbx, %rdi
callq 0x3340
movq %rax, %rdi
movq %r14, %rsi
callq 0x3370
leaq 0x40(%r15), %rsi
movq %rax, %rdi
callq 0x3340
movq %rax, %rdi
movq %r12, %rsi
callq 0x3370
movq %r15, %rdi
callq 0x32a0
movq %rax, %r15
jmp 0x8fb4
leaq -0x238(%rbp), %rdi
callq 0x3070
leaq -0x238(%rbp), %rdi
callq 0x30d0
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x9020
movq %rax, %rbx
leaq -0x238(%rbp), %rdi
callq 0x30d0
movq %rbx, %rdi
callq 0x35c0
nop
// File: /workspace/github_cpp_makefile_star2_O2/parth-shel[P]xpac/cleanup_directory.cpp
// Function: cleanup_directory(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void cleanup_directory(std::string dir_name){
	dir_name = get_current_dir_name() + std::string("/") + dir_name;
	int ret = fork();
	if(ret == 0) {
		execl("/bin/rm", "rm", "-rf", dir_name.c_str(), NULL);
		exit(1);
	} else {
		waitpid( ret, NULL, 0);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x68, %rsp
movq %rdi, %rbx
callq 0x3630
movq %rax, %r14
leaq 0xfb3(%rip), %rsi       # 0xa00a
leaq -0x60(%rbp), %r15
leaq -0x19(%rbp), %rdx
movq %r15, %rdi
callq 0x3180
leaq -0x40(%rbp), %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x911a
leaq -0x80(%rbp), %rdi
leaq -0x40(%rbp), %rsi
movq %rbx, %rdx
callq 0x5f53
leaq -0x80(%rbp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3420
movq %r14, %rdi
callq 0x36a8
leaq -0x40(%rbp), %rdi
callq 0x36a8
leaq -0x60(%rbp), %rdi
callq 0x36a8
callq 0x3120
testl %eax, %eax
je 0x90ce
movl %eax, %edi
xorl %esi, %esi
xorl %edx, %edx
callq 0x32d0
addq $0x68, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq (%rbx), %rcx
leaq 0x17db(%rip), %rdi      # 0xa8b3
leaq 0x17d9(%rip), %rsi      # 0xa8b8
leaq 0x17d5(%rip), %rdx      # 0xa8bb
xorl %r8d, %r8d
xorl %eax, %eax
callq 0x3440
pushq $0x1
popq %rdi
callq 0x3410
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
callq 0x36a8
jmp 0x9109
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x36a8
movq %rbx, %rdi
callq 0x35c0
// File: /workspace/github_cpp_makefile_star2_O2/parth-shel[P]xpac/MD5checksum.cc
// Function: MD5checksum::generate_hash()
void MD5checksum::generate_hash() {
	int fd;
	unsigned char result[MD5_DIGEST_LENGTH];
	void * file_buffer;
	if((fd = open(file_path.c_str(), O_RDONLY)) < 0) {
		return;
	}

	if((file_size = get_file_size(fd)) == 0) {
		return;
	}
	
	file_buffer = mmap(0, file_size, PROT_READ, MAP_SHARED, fd, 0);
	MD5((unsigned char*) file_buffer, file_size, result);
	munmap(file_buffer, file_size);

	close(fd);

	result_hash.clear();
	for(int i = 0;i < MD5_DIGEST_LENGTH;i++) {
		result_hash.push_back(result[i]);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movq (%rdi), %rdi
xorl %esi, %esi
xorl %eax, %eax
callq 0x32b0
testl %eax, %eax
js 0x9247
movl %eax, %r14d
movl %eax, %esi
callq 0x9272
movq %rax, 0x20(%rbx)
testq %rax, %rax
je 0x9247
pushq $0x1
popq %rcx
xorl %edi, %edi
movq %rax, %rsi
movl %ecx, %edx
movl %r14d, %r8d
xorl %r9d, %r9d
callq 0x35d0
movq %rax, %r15
movq 0x20(%rbx), %rsi
leaq -0x30(%rbp), %rdx
movq %rax, %rdi
callq 0x3530
movq 0x20(%rbx), %rsi
movq %r15, %rdi
callq 0x3260
movl %r14d, %edi
callq 0x3680
movq 0x28(%rbx), %rax
cmpq %rax, 0x30(%rbx)
je 0x9225
movq %rax, 0x30(%rbx)
addq $0x28, %rbx
xorl %r14d, %r14d
cmpq $0x10, %r14
je 0x9247
leaq (%r14,%rbp), %rsi
addq $-0x30, %rsi
movq %rbx, %rdi
callq 0x9474
incq %r14
jmp 0x922c
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/parth-shel[P]xpac/MD5checksum.cc
// Function: MD5checksum::save_hash()
void MD5checksum::save_hash() {
	std::string hash_path(file_path);
	hash_path.append(".md5hash");
	std::ofstream hash_file(hash_path, std::ios::out | std::ios::trunc);
	std::string str(result_hash.begin(), result_hash.end());
	hash_file << str; 
	hash_file.close();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x240, %rsp            # imm = 0x240
movq %rdi, %rbx
leaq -0x50(%rbp), %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x34a0
leaq 0x15f8(%rip), %rsi      # 0xa8bf
movq %r14, %rdi
callq 0x3650
leaq -0x250(%rbp), %rdi
leaq -0x50(%rbp), %rsi
pushq $0x30
popq %rdx
callq 0x3660
movq 0x28(%rbx), %rsi
movq 0x30(%rbx), %rdx
leaq -0x20(%rbp), %rax
movq %rax, -0x10(%rax)
leaq -0x30(%rbp), %rdi
callq 0x9610
leaq -0x250(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x3340
leaq -0x250(%rbp), %rdi
callq 0x34c0
leaq -0x30(%rbp), %rdi
callq 0x36a8
leaq -0x250(%rbp), %rdi
callq 0x34e0
leaq -0x50(%rbp), %rdi
callq 0x36a8
addq $0x240, %rsp            # imm = 0x240
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
jmp 0x9359
jmp 0x9348
movq %rax, %rbx
jmp 0x9365
movq %rax, %rbx
leaq -0x30(%rbp), %rdi
callq 0x36a8
leaq -0x250(%rbp), %rdi
callq 0x34e0
leaq -0x50(%rbp), %rdi
callq 0x36a8
movq %rbx, %rdi
callq 0x35c0
// File: /workspace/github_cpp_makefile_star2_O2/parth-shel[P]xpac/MD5checksum.cc
// Function: MD5checksum::compare_saved_hash(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
bool MD5checksum::compare_saved_hash(std::string other_file_path) {
	std::ifstream file(other_file_path, std::ios::in);
	if(!file.good()) {
		return false;
	}

	if(file.is_open()) {
		std::string buf((std::istreambuf_iterator<char>(file)), std::istreambuf_iterator<char>());
		std::string str(result_hash.begin(), result_hash.end());
		return (str == buf);
	}
	return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x248, %rsp            # imm = 0x248
movq %rdi, %rbx
leaq -0x260(%rbp), %r14
pushq $0x8
popq %rdx
movq %r14, %rdi
callq 0x3560
movq (%r14), %rax
movq -0x18(%rax), %r14
cmpl $0x0, -0x240(%rbp,%r14)
jne 0x941e
leaq -0x1e8(%rbp), %rdi
callq 0x30e0
testb %al, %al
je 0x941e
movq -0x178(%rbp,%r14), %rsi
leaq -0x28(%rbp), %rax
movq %rax, -0x10(%rax)
leaq -0x38(%rbp), %rdi
pushq $-0x1
popq %rdx
xorl %ecx, %ecx
movl %edx, %r8d
callq 0x9688
movq 0x28(%rbx), %rsi
movq 0x30(%rbx), %rdx
leaq -0x48(%rbp), %rax
movq %rax, -0x10(%rax)
leaq -0x58(%rbp), %rdi
callq 0x9610
leaq -0x58(%rbp), %r14
leaq -0x38(%rbp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x7022
movl %eax, %ebx
movq %r14, %rdi
callq 0x36a8
movq %r15, %rdi
callq 0x36a8
jmp 0x9420
xorl %ebx, %ebx
leaq -0x260(%rbp), %rdi
callq 0x3110
movl %ebx, %eax
addq $0x248, %rsp            # imm = 0x248
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x38(%rbp), %rdi
callq 0x36a8
jmp 0x944d
movq %rax, %rbx
leaq -0x260(%rbp), %rdi
callq 0x3110
movq %rbx, %rdi
callq 0x35c0
nop
// File: /workspace/github_cpp_makefile_star2_O2/lagoproject[P]arti/analysis/showers.cc
// Function: curved(double, double)
void curved(double xp, double yp) {
  double d = r_earth + h;
  double t = sqrt(xp*xp + yp*yp)/d;
  double f = atan2(yp,xp);
  z = (d*cos(t) - r_earth)*cm2m;
  d *= sin(t);
  x = d*cos(f)*cm2m;
  y = d*sin(f)*cm2m;
}

// Assembly:
subq $0x18, %rsp
movsd 0x5a0e(%rip), %xmm4     # 0x7118
addsd 0x5c06(%rip), %xmm4     # 0x7318
movsd %xmm4, (%rsp)
movapd %xmm0, %xmm2
movapd %xmm1, %xmm0
mulsd %xmm1, %xmm0
movapd %xmm2, %xmm3
mulsd %xmm2, %xmm3
addsd %xmm0, %xmm3
sqrtsd %xmm3, %xmm0
divsd %xmm4, %xmm0
movsd %xmm0, 0x8(%rsp)
movapd %xmm1, %xmm0
movapd %xmm2, %xmm1
callq 0x1030
movsd %xmm0, 0x10(%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x11e0
mulsd (%rsp), %xmm0
subsd 0x59b0(%rip), %xmm0     # 0x7118
mulsd 0x59c8(%rip), %xmm0     # 0x7138
movsd %xmm0, 0x5b98(%rip)     # 0x7310
movsd 0x8(%rsp), %xmm0
callq 0x1040
mulsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x11e0
mulsd (%rsp), %xmm0
mulsd 0x5993(%rip), %xmm0     # 0x7138
movsd %xmm0, 0x5b53(%rip)     # 0x7300
movsd 0x10(%rsp), %xmm0
callq 0x1040
mulsd (%rsp), %xmm0
mulsd 0x5973(%rip), %xmm0     # 0x7138
movsd %xmm0, 0x5b3b(%rip)     # 0x7308
addq $0x18, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O2/t0mm4rx[P]piscine_cpp/day01/ex02/ZombieEvent.cpp
// Function: ZombieEvent::randomChump()
Zombie *ZombieEvent::randomChump(void)
{
	std::string names[] = {"Gabrielle", "Charlie", "Aimée", "Jacqueline", "Adele", "Marie", "Harris", "Jessie", "Calvin", "John", "Jordan"};

	if (this->type == "")
		this->type = "NoType";
	return (this->newZombie(names[rand() % 11]));
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x190, %rsp            # imm = 0x190
movq %rdi, %r15
leaq 0xb89(%rip), %rsi       # 0x2013
leaq 0x30(%rsp), %rbx
leaq 0xf(%rsp), %rdx
movq %rbx, %rdi
callq 0x16a0
leaq 0x50(%rsp), %r14
leaq 0xb75(%rip), %rsi       # 0x201d
leaq 0xe(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0x70(%rsp), %r14
leaq 0xb64(%rip), %rsi       # 0x2025
leaq 0xd(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0x90(%rsp), %r14
leaq 0xb4f(%rip), %rsi       # 0x202c
leaq 0xc(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0xb0(%rsp), %r14
leaq 0xb3e(%rip), %rsi       # 0x2037
leaq 0xb(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0xd0(%rsp), %r14
leaq 0xb28(%rip), %rsi       # 0x203d
leaq 0xa(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0xf0(%rsp), %r14
leaq 0xb12(%rip), %rsi       # 0x2043
leaq 0x9(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0x110(%rsp), %r14
leaq 0xafd(%rip), %rsi       # 0x204a
leaq 0x8(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0x130(%rsp), %r14
leaq 0xae8(%rip), %rsi       # 0x2051
leaq 0x7(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0x150(%rsp), %r14
leaq 0xad3(%rip), %rsi       # 0x2058
leaq 0x6(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0x170(%rsp), %r14
leaq 0xabc(%rip), %rsi       # 0x205d
leaq 0x5(%rsp), %rdx
movq %r14, %rdi
callq 0x16a0
leaq 0xa57(%rip), %rsi       # 0x200c
movq %r15, %rdi
callq 0x16db
testb %al, %al
je 0x15d0
leaq 0xa9c(%rip), %rsi       # 0x2064
movq %r15, %rdi
callq 0x1160
callq 0x1030
pushq $0xb
popq %rcx
cltd
idivl %ecx
movslq %edx, %rax
shlq $0x5, %rax
leaq (%rsp,%rax), %rsi
addq $0x30, %rsi
leaq 0x10(%rsp), %rdi
callq 0x1120
leaq 0x10(%rsp), %rsi
movq %r15, %rdi
callq 0x13e0
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x1060
movl $0x140, %r14d           # imm = 0x140
leaq (%rsp,%r14), %rdi
addq $0x30, %rdi
callq 0x1060
addq $-0x20, %r14
cmpq $-0x20, %r14
jne 0x1614
movq %rbx, %rax
addq $0x190, %rsp            # imm = 0x190
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r15
leaq 0x10(%rsp), %rdi
callq 0x1060
jmp 0x167b
jmp 0x165c
jmp 0x165c
jmp 0x165c
jmp 0x165c
jmp 0x165c
jmp 0x165c
jmp 0x165c
jmp 0x165c
jmp 0x165c
movq %rax, %r15
addq $-0x20, %r14
movq %r14, %rdi
callq 0x1060
cmpq %rbx, %r14
jne 0x165f
movq %r15, %rdi
callq 0x1140
movq %rax, %r15
movl $0x140, %ebx            # imm = 0x140
leaq (%rsp,%rbx), %rdi
addq $0x30, %rdi
callq 0x1060
addq $-0x20, %rbx
cmpq $-0x20, %rbx
jne 0x1680
jmp 0x1670
nop
// File: /workspace/github_cpp_makefile_star2_O2/t0mm4rx[P]piscine_cpp/day01/ex02/main.cpp
// Function: fight(Zombie**, Zombie**)
void	fight(Zombie *tall[10], Zombie *small[10])
{
	int	actions;
	int zombieIndex;

	actions = 5 + rand() % 5;
	for (int i = 0; i < actions; i++)
	{
		zombieIndex = rand() % 10;
		if (rand() % 2 == 1)
			tall[zombieIndex]->announce();
		else
			small[zombieIndex]->announce();
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
callq 0x1030
pushq $0x5
popq %rcx
cltd
idivl %ecx
movl %edx, %ebp
addl $0x5, %ebp
pushq $0xa
popq %r12
subl $0x1, %ebp
jb 0x17d5
callq 0x1030
cltd
idivl %r12d
movl %edx, %r15d
callq 0x1030
andl $0x80000001, %eax       # imm = 0x80000001
cmpl $0x1, %eax
movslq %r15d, %rax
movq %rbx, %rcx
cmoveq %r14, %rcx
movq (%rcx,%rax,8), %rdi
callq 0x1326
jmp 0x17a2
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/grisu48[P]geoJson/geoJson.cpp
// Function: Coords::Coords(Coords const&)
Coords(const Coords &src) {
        this->lon = src.lon;
        this->lat = src.lat;
        this->ele = src.ele;
        this->time = src.time;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x20(%rdi), %rax
andq $0x0, (%rdi)
andl $0x0, 0x8(%rdi)
leaq 0x10(%rdi), %rbx
movq %rax, 0x10(%rdi)
andq $0x0, 0x18(%rdi)
movb $0x0, 0x20(%rdi)
vmovsd (%rsi), %xmm0
vmovsd %xmm0, (%rdi)
vmovss 0x8(%rsi), %xmm0
addq $0x10, %rsi
vmovss %xmm0, 0x8(%rdi)
movq %rbx, %rdi
callq 0x2130
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rbx, %rdi
movq %rax, %r14
callq 0x20f0
movq %r14, %rdi
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O2/SeanLee97[P]LL1-Parser/driver.cpp
// Function: main
int main(int argc, char* argv[]) {
	Grammar g;
	g.init(argv[1]);
	g.parse();
	//g.print_table();
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x300, %rsp            # imm = 0x300
movq %rsi, %rbx
leaq -0x308(%rbp), %r14
movq %r14, %rdi
callq 0x2b7c
movq 0x8(%rbx), %rsi
movq %r14, %rdi
callq 0x3fdc
leaq -0x308(%rbp), %rdi
callq 0x4478
leaq -0x308(%rbp), %rdi
callq 0x24f6
xorl %eax, %eax
addq $0x300, %rsp            # imm = 0x300
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
leaq -0x308(%rbp), %rdi
callq 0x24f6
movq %rbx, %rdi
callq 0x22c0
nop
// File: /workspace/github_cpp_makefile_star2_O2/SeanLee97[P]LL1-Parser/scan.cpp
// Function: make_token(tok_num)
static inline token make_token(tok_num t) {
    token rtn;
    rtn.num = t;
    assert(image_index < TOKEN_MAX);
    token_image[image_index] = 0;
    rtn.name = token_names[t];
    rtn.image = string(token_image);
    rtn.line = tok_line;
    rtn.column = tok_col;
    return rtn;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
leaq 0x20(%rdi), %rax
movq %rax, 0x10(%rdi)
andq $0x0, 0x18(%rdi)
movb $0x0, 0x20(%rdi)
movl %esi, (%rdi)
movslq 0x8948(%rip), %rcx      # 0xb2d4
cmpq $0x64, %rcx
jge 0x29fc
movq %rdi, %rbx
leaq 0x10(%rdi), %r14
leaq 0x8950(%rip), %rax      # 0xb2f0
movb $0x0, (%rcx,%rax)
movl %esi, %ecx
leaq 0x87f3(%rip), %rdx      # 0xb1a0
movq (%rdx,%rcx,8), %rcx
movq %rcx, 0x8(%rdi)
leaq -0x40(%rbp), %rdi
leaq -0x19(%rbp), %rdx
movq %rax, %rsi
callq 0x2aa0
leaq -0x40(%rbp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x2210
movq %r15, %rdi
callq 0x20d0
movl 0x88fa(%rip), %eax      # 0xb2dc
movl %eax, 0x30(%rbx)
movl 0x88f5(%rip), %eax      # 0xb2e0
movl %eax, 0x34(%rbx)
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4765(%rip), %rdi      # 0x7168
leaq 0x4776(%rip), %rsi      # 0x7180
leaq 0x4778(%rip), %rcx      # 0x7189
pushq $0x55
popq %rdx
callq 0x2130
movq %rax, %rbx
movq %r14, %rdi
callq 0x20d0
movq %rbx, %rdi
callq 0x22c0
// File: /workspace/github_cpp_makefile_star2_O2/SeanLee97[P]LL1-Parser/scan.cpp
// Function: nextchar()
static inline void nextchar() {
    assert(image_index < TOKEN_MAX);
    token_image[image_index++] = cur_char;
    cur_char = cin.get();
    cur_col++;
    if (cur_char == '\n') {
        cur_line++;
        cur_col = 0;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movslq 0x889d(%rip), %rax      # 0xb2d4
cmpq $0x64, %rax
jge 0x2a82
movb 0x8865(%rip), %cl       # 0xb2a8
leal 0x1(%rax), %edx
movl %edx, 0x8888(%rip)      # 0xb2d4
leaq 0x889d(%rip), %rdx      # 0xb2f0
movb %cl, (%rax,%rdx)
movq 0x8583(%rip), %rdi      # 0xafe0
callq 0x21f0
movl %eax, 0x8840(%rip)      # 0xb2a8
incl 0x886a(%rip)            # 0xb2d8
cmpl $0xa, %eax
jne 0x2a80
incl 0x8833(%rip)            # 0xb2ac
andl $0x0, 0x8858(%rip)      # 0xb2d8
popq %rbp
retq
leaq 0x46df(%rip), %rdi      # 0x7168
leaq 0x46f0(%rip), %rsi      # 0x7180
leaq 0x4736(%rip), %rcx      # 0x71cd
pushq $0x48
popq %rdx
callq 0x2130
nop
// File: /workspace/github_cpp_makefile_star2_O2/SeanLee97[P]LL1-Parser/grammar.cpp
// Function: Grammar::_get_idx_by_symbol(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
int Grammar::_get_idx_by_symbol(string symbol_to_find) {

	for(int i = 0; i < terminal_names.size(); i++) {
		if(terminal_names[i].compare(symbol_to_find) == 0)
			return i * -1;
	}

	for(int i = 0; i < nonterminal_names.size(); i++) {
		if(nonterminal_names[i].compare(symbol_to_find) == 0)
			return i;
	}

	return 999;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
xorl %r12d, %r12d
xorl %ebx, %ebx
movq 0x238(%r15), %rdi
movq 0x240(%r15), %rax
subq %rdi, %rax
sarq $0x5, %rax
cmpq %rbx, %rax
jbe 0x2f06
addq %r12, %rdi
movq %r14, %rsi
callq 0x2030
testl %eax, %eax
je 0x2f3d
incq %rbx
addq $0x20, %r12
jmp 0x2ed4
xorl %r12d, %r12d
xorl %ebx, %ebx
movq 0x250(%r15), %rdi
movq 0x258(%r15), %rax
subq %rdi, %rax
sarq $0x5, %rax
cmpq %rbx, %rax
jbe 0x2f41
addq %r12, %rdi
movq %r14, %rsi
callq 0x2030
testl %eax, %eax
je 0x2f46
incq %rbx
addq $0x20, %r12
jmp 0x2f0b
negl %ebx
jmp 0x2f46
movl $0x3e7, %ebx            # imm = 0x3E7
movl %ebx, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/SeanLee97[P]LL1-Parser/grammar.cpp
// Function: Grammar::_push_unique_elements(std::vector<int, std::allocator<int>>, std::vector<int, std::allocator<int>>)
vector<int> Grammar::_push_unique_elements(vector<int> target, vector<int> source) {
	for(int i = 0; i < source.size(); i++) {
		if(!_in_array(target, abs(source[i]))) {
			target.push_back(source[i]);
		}
	}
	return target;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %r15
movq %rdx, -0x30(%rbp)
movq %rdi, -0x38(%rbp)
xorl %r14d, %r14d
leaq -0x50(%rbp), %r12
xorl %ebx, %ebx
movq 0x8(%r15), %rax
subq (%r15), %rax
sarq $0x2, %rax
cmpq %rbx, %rax
jbe 0x372c
movq %r12, %rdi
movq -0x30(%rbp), %rsi
callq 0x4c16
movq (%r15), %rax
movl (%rax,%rbx,4), %eax
movl %eax, %edx
negl %edx
cmovsl %eax, %edx
movq %r12, %rsi
callq 0x3230
movl %eax, %r13d
movq %r12, %rdi
callq 0x2632
testb %r13b, %r13b
jne 0x3723
movq (%r15), %rsi
addq %r14, %rsi
movq -0x30(%rbp), %rdi
callq 0x4c6e
incq %rbx
addq $0x4, %r14
jmp 0x36d3
movq -0x30(%rbp), %rcx
movq (%rcx), %rdx
movq -0x38(%rbp), %rax
movq %rdx, (%rax)
movq 0x8(%rcx), %rdx
movq %rdx, 0x8(%rax)
movq 0x10(%rcx), %rdx
movq %rdx, 0x10(%rax)
xorps %xmm0, %xmm0
movups %xmm0, (%rcx)
andq $0x0, 0x10(%rcx)
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/SeanLee97[P]LL1-Parser/grammar.cpp
// Function: Grammar::_grammar_counter(char*)
void Grammar::_grammar_counter(char* inputFile) {
	input.open(inputFile);
	// 获取出现次数最多的字符
	string cur_maxfreq_terminals;

	while(getline(input, line)){
		if(line.compare("") == 0) break;

		stringstream ss(line);

		getline(ss, cur_maxfreq_terminals, ' ');
		getline(ss, cur_maxfreq_terminals, ' ');
		// 最大id-terminal
		// atoi字符串转换成整型数的一个函数
		maxidx_terminal = atoi(cur_maxfreq_terminals.c_str());
	}

	string last_unique_nonterminal(""); 
	string this_nonterminal;

	while(getline(input, line)) {
		stringstream ss(line); 
		getline(ss, this_nonterminal, ' ');

		if(this_nonterminal.compare(last_unique_nonterminal) != 0) {
			++num_nonterminals;
			last_unique_nonterminal = this_nonterminal;
		}

		++num_rules;
	}

	input.close();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1f8, %rsp            # imm = 0x1F8
movq %rdi, %r14
addq $0x10, %rdi
pushq $0x8
popq %rdx
movq %rdi, -0x30(%rbp)
callq 0x2120
leaq -0x40(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x218(%r14), %r15
leaq -0x218(%rbp), %r13
pushq $0x20
popq %r12
movq -0x30(%rbp), %rdi
movq %r15, %rsi
callq 0x2050
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x3eac
movq %r15, %rdi
leaq 0x346f(%rip), %rsi      # 0x72ce
callq 0x2090
testl %eax, %eax
je 0x3eac
movq %r13, %rdi
movq %r15, %rsi
pushq $0x18
popq %rdx
callq 0x2270
movq %r13, %rdi
leaq -0x50(%rbp), %rbx
movq %rbx, %rsi
movl %r12d, %edx
callq 0x22e0
movq %r13, %rdi
movq %rbx, %rsi
movl %r12d, %edx
callq 0x22e0
movq -0x50(%rbp), %rdi
callq 0x2260
movl %eax, (%r14)
movq %r13, %rdi
callq 0x2150
jmp 0x3e3b
leaq 0x341b(%rip), %rsi      # 0x72ce
leaq -0x90(%rbp), %rdi
leaq -0x218(%rbp), %rdx
callq 0x2aa0
leaq -0x60(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq -0x218(%rbp), %r12
leaq -0x70(%rbp), %r13
leaq -0x90(%rbp), %rbx
movq -0x30(%rbp), %rdi
movq %r15, %rsi
callq 0x2050
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x3f4a
movq %r12, %rdi
movq %r15, %rsi
pushq $0x18
popq %rdx
callq 0x2270
movq %r12, %rdi
movq %r13, %rsi
pushq $0x20
popq %rdx
callq 0x22e0
movq %r13, %rdi
movq %rbx, %rsi
callq 0x2030
testl %eax, %eax
je 0x3f3c
incl 0x4(%r14)
movq %rbx, %rdi
movq %r13, %rsi
callq 0x2100
incl 0x8(%r14)
movq %r12, %rdi
callq 0x2150
jmp 0x3ee8
movq -0x30(%rbp), %rdi
callq 0x2060
leaq -0x70(%rbp), %rdi
callq 0x20d0
leaq -0x90(%rbp), %rdi
callq 0x20d0
leaq -0x50(%rbp), %rdi
callq 0x20d0
addq $0x1f8, %rsp            # imm = 0x1F8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x3fa1
jmp 0x3f89
jmp 0x3f89
movq %rax, %rbx
jmp 0x3fca
movq %rax, %rbx
leaq -0x218(%rbp), %rdi
callq 0x2150
jmp 0x3fca
jmp 0x3fa1
movq %rax, %rbx
jmp 0x3fb5
movq %rax, %rbx
leaq -0x218(%rbp), %rdi
callq 0x2150
leaq -0x70(%rbp), %rdi
callq 0x20d0
leaq -0x90(%rbp), %rdi
callq 0x20d0
leaq -0x50(%rbp), %rdi
callq 0x20d0
movq %rbx, %rdi
callq 0x22c0
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/beam_search.cpp
// Function: beam_search(board const&, std::vector<block, std::allocator<block>> const&, int, bool)
vector<placement_t> beam_search(board const & brd, std::vector<block> const & blks, int beam_width, bool is_chokudai) {
    if (is_chokudai) {
        unordered_set<bitset<board_size * board_size> > cache;
        while (true) beam_search_solver(beam_width, &cache)(brd, blks);
    } else {
        return beam_search_solver(beam_width, nullptr)(brd, blks);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x21a8, %rsp           # imm = 0x21A8
movl %ecx, %ebp
movq %rdx, %rbx
movq %rsi, %r14
testl %r8d, %r8d
jne 0x24f2
movq %rdi, %r15
leaq 0x50(%rsp), %r12
movq %r12, %rdi
movl %ebp, %esi
xorl %edx, %edx
callq 0x26da
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x28ea
leaq 0x50(%rsp), %rdi
callq 0x3c2a
movq %r15, %rax
addq $0x21a8, %rsp           # imm = 0x21A8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x30(%rsp), %rax
movq %rax, -0x30(%rax)
movq $0x1, -0x28(%rax)
xorps %xmm0, %xmm0
movups %xmm0, -0x20(%rax)
movl $0x3f800000, -0x10(%rax) # imm = 0x3F800000
movups %xmm0, -0x8(%rax)
leaq 0x50(%rsp), %r15
movq %rsp, %r12
leaq 0x38(%rsp), %r13
movq %r15, %rdi
movl %ebp, %esi
movq %r12, %rdx
callq 0x26da
movq %r13, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x28ea
movq %r13, %rdi
callq 0x742c
movq %r15, %rdi
callq 0x3c2a
jmp 0x2522
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x3c2a
jmp 0x2564
movq %rax, %rbx
movq %rsp, %rdi
callq 0x74ec
jmp 0x257b
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x3c2a
movq %rbx, %rdi
callq 0x2270
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/beam_search.cpp
// Function: beam_search_solver::evaluate(photon_t const&)
double evaluate(photon_t const & a) {
        double p = a.bix /(double) n;
        double q = 1 - p;
        return
            - a.circumference * (8 * q)
            - a.score * (12 * p)
            - max(0.0, a.score - a.remaining_stone * 0.8) * 64
            - max(0, a.isolated[0] - remaining_small_blks[0][a.bix]) * 32 * q
            - max(0, a.isolated[1] - remaining_small_blks[1][a.bix]) * 32 * q
            - a.isolated[0] * 16 * (q + 0.3)
            - a.isolated[1] *  8 * (q + 0.3)
            - a.isolated[2] *  6 * (q + 0.3)
            - a.isolated[3] *  4 * (q + 0.3)
            - a.stone_count * 0.00001;
    }

// Assembly:
movslq 0x20e0(%rsi), %rax
cvtsi2sd %eax, %xmm2
cvtsi2sdl 0x20ec(%rdi), %xmm0
divsd %xmm0, %xmm2
movsd 0x8a4f(%rip), %xmm0     # 0xb008
subsd %xmm2, %xmm0
xorl %ecx, %ecx
subl 0x20b8(%rsi), %ecx
cvtsi2sd %ecx, %xmm1
xorl %ecx, %ecx
movsd 0x8a3d(%rip), %xmm3     # 0xb010
mulsd %xmm0, %xmm3
mulsd %xmm1, %xmm3
cvtsi2sdl 0x20b0(%rsi), %xmm4
mulsd 0x8a2d(%rip), %xmm2     # 0xb018
mulsd %xmm4, %xmm2
addsd %xmm3, %xmm2
cvtsi2sdl 0x20c0(%rsi), %xmm1
mulsd 0x8a1d(%rip), %xmm1     # 0xb020
addsd %xmm4, %xmm1
xorpd %xmm3, %xmm3
maxsd %xmm3, %xmm1
mulsd 0x8a11(%rip), %xmm1     # 0xb028
movl 0x20e4(%rsi), %edx
movq 0x2120(%rdi), %r8
movl %edx, %r9d
subl (%r8,%rax,4), %r9d
addsd %xmm2, %xmm1
testl %r9d, %r9d
cmovlel %ecx, %r9d
movl 0x20e8(%rsi), %r8d
shll $0x5, %r9d
cvtsi2sd %r9d, %xmm2
movq 0x2138(%rdi), %rdi
movl %r8d, %r9d
subl (%rdi,%rax,4), %r9d
mulsd %xmm0, %xmm2
testl %r9d, %r9d
cmovlel %ecx, %r9d
subsd %xmm2, %xmm1
shll $0x5, %r9d
cvtsi2sd %r9d, %xmm2
mulsd %xmm0, %xmm2
shll $0x4, %edx
cvtsi2sd %edx, %xmm3
subsd %xmm2, %xmm1
addsd 0x89ad(%rip), %xmm0     # 0xb030
mulsd %xmm0, %xmm3
subsd %xmm3, %xmm1
shll $0x3, %r8d
cvtsi2sd %r8d, %xmm2
mulsd %xmm0, %xmm2
subsd %xmm2, %xmm1
imull $0x6, 0x20ec(%rsi), %eax
cvtsi2sd %eax, %xmm2
mulsd %xmm0, %xmm2
subsd %xmm2, %xmm1
movl 0x20f0(%rsi), %eax
shll $0x2, %eax
cvtsi2sd %eax, %xmm2
mulsd %xmm0, %xmm2
subsd %xmm2, %xmm1
cvtsi2sdl 0x20b4(%rsi), %xmm0
mulsd 0x8964(%rip), %xmm0     # 0xb038
addsd %xmm1, %xmm0
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/beam_search.cpp
// Function: beam_search_solver::beam_search_solver(int, std::unordered_set<std::bitset<1024ul>, std::hash<std::bitset<1024ul>>, std::equal_to<std::bitset<1024ul>>, std::allocator<std::bitset<1024ul>>>*)
beam_search_solver(int a_beam_width, unordered_set<bitset<board_size * board_size> > *a_cache)
            : beam_width(a_beam_width),
              cache(a_cache) {
        n = -1;
        highscore = 1000000007;
        least_stone = 1000000007;
        component_pack_table[0 + 2 * 10] = 5;
        component_pack_table[0 + 6 * 10] = 5;
        component_pack_table[1 + 1 * 10] = 6;
        component_pack_table[1 + 3 * 10] = 6;
        component_pack_table[1 + 5 * 10] = 6;
        component_pack_table[3 + 3 * 10] = 6;
        component_pack_table[3 + 3 * 10] = 6;
        component_pack_table[0 + 3 * 10] = 7;
        component_pack_table[0 + 1 * 10] = 7;
        component_pack_table[1 + 4 * 10] = 7;
        component_pack_table[2 + 2 * 10] = 8;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %rbx
callq 0x7554
xorps %xmm0, %xmm0
movups %xmm0, 0x20d0(%rbx)
movups %xmm0, 0x20c0(%rbx)
movups %xmm0, 0x20b0(%rbx)
movl %ebp, 0x20e8(%rbx)
leaq 0x20f0(%rbx), %r14
andl $0x0, 0x20f8(%rbx)
leaq 0x20f8(%rbx), %rax
andq $0x0, 0x2100(%rbx)
movq %rax, 0x2108(%rbx)
movq %rax, 0x2110(%rbx)
movups %xmm0, 0x2118(%rbx)
movups %xmm0, 0x2128(%rbx)
movups %xmm0, 0x2138(%rbx)
andq $0x0, 0x2148(%rbx)
movq %r15, 0x2150(%rbx)
orl $-0x1, 0x20ec(%rbx)
movabsq $0x3b9aca073b9aca07, %rax # imm = 0x3B9ACA073B9ACA07
movq %rax, 0x20e0(%rbx)
leaq 0xc(%rsp), %rsi
movl $0x14, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x5, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x3c, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x5, (%rax)
leaq 0xc(%rsp), %rsi
movl $0xb, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x6, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x1f, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x6, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x33, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x6, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x21, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x6, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x21, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x6, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x1e, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x7, (%rax)
leaq 0xc(%rsp), %rsi
movl $0xa, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x7, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x29, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x7, (%rax)
leaq 0xc(%rsp), %rsi
movl $0x16, (%rsi)
movq %r14, %rdi
callq 0x3c62
movl $0x8, (%rax)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
jmp 0x28ac
movq %rax, %r15
leaq 0x20b0(%rbx), %r12
leaq 0x2120(%rbx), %rdi
addq $0x20c8, %rbx           # imm = 0x20C8
callq 0x3cb0
movq %r14, %rdi
callq 0x3fa4
movq %rbx, %rdi
callq 0x742c
movq %r12, %rdi
callq 0x3cd6
movq %r15, %rdi
callq 0x2270
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: signature_block(bool const (&) [8][8], point_t const&)
uint64_t signature_block(bool const (& a)[block_size][block_size], point_t const & offset) {
    static_assert (block_size == 8, "");
    uint64_t z = 0; // 8*8 == 64
    repeat_from (y, offset.y, 8) {
        uint64_t w = 0;
        repeat_from (x, offset.x, 8) {
            w = w << 1;
            if (a[y][x]) w = w | 1;
        }
        w = w << offset.x;
        z = (z << 8) | w;
    }
    z = z << (8 * offset.y);
    return z;
}

// Assembly:
movslq 0x4(%rsi), %rdx
movslq (%rsi), %rcx
leaq (%rdi,%rdx,8), %rsi
xorl %eax, %eax
movq %rdx, %rdi
cmpq $0x7, %rdi
jg 0x754b
movq %rcx, %r9
xorl %r8d, %r8d
cmpq $0x8, %r9
jge 0x7538
movzbl (%rsi,%r9), %r10d
leaq (%r10,%r8,2), %r8
incq %r9
jmp 0x7524
shlq %cl, %r8
shlq $0x8, %rax
orq %r8, %rax
incq %rdi
addq $0x8, %rsi
jmp 0x7518
shll $0x3, %edx
movl %edx, %ecx
shlq %cl, %rax
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: board::board(board_t const&)
board::board(board_t const & a) {
    copy_cell_map(a.a, m_cell, [](bool x) -> int { return x; });
    repeat (y, board_size) {
        repeat (x, board_size) {
            m_packed[y * board_size + x] = m_cell[y][x];
        }
    }
    shrink();
    update();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
leaq 0x2030(%rdi), %r15
xorps %xmm0, %xmm0
movups %xmm0, 0x20a0(%rdi)
movups %xmm0, 0x2090(%rdi)
movups %xmm0, 0x2080(%rdi)
movups %xmm0, 0x2070(%rdi)
movups %xmm0, 0x2060(%rdi)
movups %xmm0, 0x2050(%rdi)
movups %xmm0, 0x2040(%rdi)
movups %xmm0, 0x2030(%rdi)
xorl %eax, %eax
movq %rdi, %rcx
cmpq $0x20, %rax
je 0x760e
xorl %edx, %edx
cmpq $0x20, %rdx
je 0x7601
movzbl (%rsi,%rdx), %r8d
movl %r8d, (%rcx,%rdx,4)
incq %rdx
jmp 0x75ed
incq %rax
subq $-0x80, %rcx
addq $0x20, %rsi
jmp 0x75e5
xorl %r12d, %r12d
leaq 0x8(%rsp), %r14
movq %rdi, (%rsp)
movq %rdi, %r13
xorl %ebp, %ebp
cmpq $0x20, %rbp
je 0x766f
xorl %ebx, %ebx
cmpq $0x20, %rbx
je 0x7662
xorl %esi, %esi
cmpl $0x0, (%r13,%rbx,4)
setne %sil
leaq (%r12,%rbx), %rax
movq %rax, %rcx
shrq $0x6, %rcx
leaq (%r15,%rcx,8), %rcx
movq %rcx, 0x8(%rsp)
andl $0x3f, %eax
movq %rax, 0x10(%rsp)
movq %r14, %rdi
callq 0x8d4e
incq %rbx
jmp 0x7627
incq %rbp
addq $0x20, %r12
subq $-0x80, %r13
jmp 0x761f
movq (%rsp), %rbx
movq %rbx, %rdi
callq 0x7692
movq %rbx, %rdi
callq 0x7850
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: board::shrink()
void board::shrink() {
    m_offset = { 0, 0 };
    m_size = { N, N };
    shrink_cell(m_cell, m_offset, m_size, 1);
    repeat (y,board_size) {
        m_skips[y][board_size-1] = 1;
        for (int x = board_size - 2; x >= 0; -- x) {
            m_skips[y][x] = m_cell[y][x+1] == 0 ? 1 : m_skips[y][x+1] + 1;
        }
    }
    m_stone_offset = { 0, 0 };
    m_stone_size = { N, N };
    shrink_cell(m_cell, m_stone_offset, m_stone_size, [](int n) -> bool { return n <= 1; });
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x1000(%rdi), %rsi
leaq 0x1008(%rdi), %rdx
movaps 0x3b8f(%rip), %xmm0     # 0xb240
movups %xmm0, 0x1000(%rdi)
pushq $0x1
popq %rbp
movl %ebp, %ecx
callq 0x8d6f
leaq 0x102c(%rbx), %rax
xorl %ecx, %ecx
pushq $0x1f
popq %rdx
movq %rbx, %rsi
cmpq $0x20, %rcx
je 0x7719
movq %rcx, %rdi
shlq $0x7, %rdi
movl $0x1, 0x7c(%rax,%rdi)
addq %rax, %rdi
movq %rdx, %r9
movl %ebp, %r8d
leaq -0x1(%r9), %r10
testl %r10d, %r10d
js 0x7710
incl %r8d
cmpl $0x0, (%rsi,%r9,4)
cmovel %ebp, %r8d
movl %r10d, %r9d
movl %r8d, (%rdi,%r9,4)
movq %r10, %r9
jmp 0x76ef
incq %rcx
subq $-0x80, %rsi
jmp 0x76d1
movaps 0x3b20(%rip), %xmm0     # 0xb240
movups %xmm0, 0x1014(%rbx)
pushq $0x20
popq %rdi
xorl %eax, %eax
movq %rbx, %rcx
movq $-0x1080, %rdx          # imm = 0xEF80
movq $-0x1080, %rsi          # imm = 0xEF80
subq $-0x80, %rsi
je 0x7752
cmpl $0x2, 0x1080(%rcx,%rdx)
movq %rsi, %rdx
jge 0x773d
jmp 0x7769
incq %rax
movl %eax, 0x1014(%rbx)
decl %edi
movl %edi, 0x101c(%rbx)
addq $0x4, %rcx
jmp 0x772f
movslq %eax, %rsi
leaq (%rbx,%rsi,4), %r8
xorl %eax, %eax
testl %edi, %edi
movl $0x0, %r9d
cmovgl %edi, %r9d
pushq $0x20
popq %rcx
pushq $0x1f
popq %rdx
xorl %r10d, %r10d
cmpq %r10, %r9
je 0x7799
cmpl $0x2, (%r8,%r10,4)
leaq 0x1(%r10), %r10
jge 0x7787
jmp 0x77b2
incq %rax
movl %eax, 0x1018(%rbx)
decl %ecx
movl %ecx, 0x1020(%rbx)
decl %edx
subq $-0x80, %r8
jmp 0x7784
movl %edi, %edi
xorl %r8d, %r8d
testl %ecx, %ecx
cmovgl %ecx, %r8d
shlq $0x7, %r8
subq $-0x80, %r8
pushq $0x1f
popq %r10
movl %eax, %r9d
movslq %r10d, %r11
movslq %eax, %r14
shlq $0x7, %r14
leaq (%r14,%r11,4), %r11
addq %rbx, %r11
xorl %r14d, %r14d
leaq 0x80(%r14), %r15
cmpq %r15, %r8
je 0x77f8
cmpl $0x2, (%r11,%r14)
movq %r15, %r14
jge 0x77e0
jmp 0x7806
decq %rdi
movl %edi, 0x101c(%rbx)
decl %r10d
jmp 0x77c9
leaq (%rbx,%rsi,4), %rsi
xorl %r8d, %r8d
testl %edi, %edi
cmovgl %edi, %r8d
decl %ecx
addl %edx, %r9d
movslq %r9d, %rdi
shlq $0x7, %rdi
addq %rsi, %rdi
xorl %r9d, %r9d
cmpq %r9, %r8
je 0x7837
cmpl $0x2, (%rdi,%r9,4)
leaq 0x1(%r9), %r9
jge 0x7825
jmp 0x7844
movl %ecx, 0x1020(%rbx)
decl %edx
movl %eax, %r9d
jmp 0x7813
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: board::update()
void board::update() {
    m_area = 0;
    m_stone_area = 0;
    m_first_stone = 1000000007;
    repeat (y,board_size) {
        repeat (x,board_size) {
            switch (m_cell[y][x]) {
                case 0:
                    m_area += 1;
                    break;
                case 1:
                    break;
                default:
                    m_stone_area += 1;
                    m_first_stone = std::min(m_first_stone, m_cell[y][x]);
            }
        }
    }
}

// Assembly:
andl $0x0, 0x1010(%rdi)
movabsq $0x3b9aca0700000000, %rax # imm = 0x3B9ACA0700000000
movq %rax, 0x1024(%rdi)
xorl %eax, %eax
movl $0x3b9aca07, %ecx       # imm = 0x3B9ACA07
movq %rdi, %rdx
xorl %esi, %esi
xorl %r8d, %r8d
cmpq $0x20, %rax
je 0x78c8
xorl %r9d, %r9d
cmpq $0x20, %r9
je 0x78bf
movl (%rdx,%r9,4), %r10d
cmpl $0x1, %r10d
je 0x78ba
testl %r10d, %r10d
jne 0x78a1
incl %r8d
movl %r8d, 0x1010(%rdi)
jmp 0x78ba
incl %esi
movl %esi, 0x1024(%rdi)
movl (%rdx,%r9,4), %r10d
cmpl %ecx, %r10d
cmovll %r10d, %ecx
movl %ecx, 0x1028(%rdi)
incq %r9
jmp 0x7880
incq %rax
subq $-0x80, %rdx
jmp 0x7877
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: board::is_intersect(block const&, placement_t const&, int*) const
bool board::is_intersect(block const & blk, placement_t const & p, int *skipp) const {
    repeat (i, blk.area()) {
        point_t q = blk.stones(p.f,p.r)[i] + p.p;
        if (q.y < 0 or board_size <= q.y or board_size <= q.x) {
            if (skipp) *skipp = board_size;
            return true;
        }
        if (q.x < 0) {
            if (skipp) *skipp = - q.x;
            return true;
        }
        if (at(q)) {
            if (skipp) *skipp = std::max(skip(q), blk.skips(p.f,p.r)[i]);
            return true;
        }
    }
    if (skipp) *skipp = 1;
    return false;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movslq 0x280(%rsi), %rax
movl 0xc(%rdx), %r8d
movl 0x10(%rdx), %r9d
imulq $0x60, %r8, %r8
addq %rsi, %r8
imulq $0x18, %r9, %r9
leaq (%r9,%r8), %r10
addq $0x290, %r10            # imm = 0x290
movl 0x4(%rdx), %r11d
movl 0x8(%rdx), %ebx
xorl %r12d, %r12d
testl %eax, %eax
movl $0x0, %r14d
cmovgl %eax, %r14d
movq %r12, %rdx
cmpq %r12, %r14
je 0x7a10
movq (%r10), %r15
movl (%r15,%rdx,8), %esi
addl %r11d, %esi
cmpl $0x1f, %esi
jg 0x7a1c
movl 0x4(%r15,%rdx,8), %r15d
addl %ebx, %r15d
cmpl $0x20, %r15d
jae 0x7a1c
testl %esi, %esi
js 0x7a28
shlq $0x7, %r15
addq %rdi, %r15
leaq 0x1(%rdx), %r12
cmpl $0x0, (%r15,%rsi,4)
je 0x79b4
testq %rcx, %rcx
je 0x7a31
movl 0x102c(%r15,%rsi,4), %edi
movq 0x350(%r9,%r8), %rsi
movl -0x4(%rsi,%r12,4), %esi
cmpl %esi, %edi
cmovgl %edi, %esi
jmp 0x7a2f
testq %rcx, %rcx
je 0x7a31
movl $0x1, %esi
jmp 0x7a2f
testq %rcx, %rcx
je 0x7a31
movl $0x20, %esi
jmp 0x7a2f
testq %rcx, %rcx
je 0x7a31
negl %esi
movl %esi, (%rcx)
cmpq %rax, %rdx
setl %al
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: board::is_puttable(block const&, placement_t const&, int, int*) const
bool board::is_puttable(block const & blk, placement_t const & p, int n, int *skipp) const {
    if (is_intersect(blk, p, skipp)) return false;
    if (is_new()) {
        return true;
    } else {
        repeat (j,blk.area()) {
            repeat (i,4) {
                point_t r = blk.stones(p.f,p.r)[j] + p.p + dp[i];
                if (not is_on_board(r)) continue;
                int a = at(r);
                if (2 <= a and a < n) return true; // is a stone
                if (2 <= a and n < a and a == m_first_stone) return true;
            }
        }
        return false;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, 0x4(%rsp)
movq %rdx, %r14
movq %rsi, %rbp
movq %rdi, %r12
movq %r8, %rcx
callq 0x7972
testb %al, %al
je 0x7a90
xorl %eax, %eax
jmp 0x7b6e
movb $0x1, %al
cmpl $0x0, 0x1024(%r12)
je 0x7b6e
leaq 0x290(%rbp), %rbx
xorl %r15d, %r15d
leaq 0x37ae(%rip), %r13      # 0xb260
movq %rbp, 0x10(%rsp)
movslq 0x280(%rbp), %rax
cmpq %rax, %r15
jge 0x7a89
xorl %ebp, %ebp
cmpq $0x4, %rbp
je 0x7b5f
movl 0xc(%r14), %eax
movl 0x10(%r14), %ecx
imulq $0x60, %rax, %rax
addq %rbx, %rax
imulq $0x18, %rcx, %rcx
movq (%rcx,%rax), %rax
movl 0x4(%r14), %ecx
movl 0x8(%r14), %edx
addl (%rax,%r15,8), %ecx
addl 0x4(%rax,%r15,8), %edx
addl (%r13,%rbp,8), %ecx
addl 0x4(%r13,%rbp,8), %edx
shlq $0x20, %rdx
orq %rdx, %rcx
movq %rcx, 0x8(%rsp)
leaq 0x8(%rsp), %rdi
callq 0x9de0
testb %al, %al
je 0x7b57
movq 0x8(%rsp), %rax
movslq %eax, %rcx
sarq $0x20, %rax
shlq $0x7, %rax
addq %r12, %rax
movl (%rax,%rcx,4), %eax
cmpl $0x2, %eax
setge %cl
cmpl 0x4(%rsp), %eax
setl %dl
testb %dl, %cl
jne 0x7b6c
cmpl $0x2, %eax
jl 0x7b57
cmpl 0x4(%rsp), %eax
jle 0x7b57
cmpl 0x1028(%r12), %eax
je 0x7b6c
incq %rbp
jmp 0x7ac5
incq %r15
movq 0x10(%rsp), %rbp
jmp 0x7ab7
movb $0x1, %al
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: next_placement(placement_t&, block const&, point_t const&, point_t const&)
bool next_placement(placement_t & p, block const & blk, point_t const & lp, point_t const & rp) {
    p.p.x += 1;
    if (p.p.x >= rp.x + 1 - blk.offset(p.f, p.r).x) {
        p.p.x = initial_placement(blk, lp, p.f, p.r).p.x;
        p.p.y += 1;
        if (p.p.y >= rp.y + 1 - blk.offset(p.f, p.r).y) {
            do {
                p.r = rot90(p.r);
                if (p.r == R0) {
                    p.f = flip(p.f);
                    if (p.f == H) {
                        return false;
                    }
                }
            } while (blk.is_duplicated(p.f, p.r));
            p.p = initial_placement(blk, lp, p.f, p.r).p;
        }
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %r12
movq %rsi, %r14
movq %rdi, %rbx
movl 0x4(%rdi), %eax
movl 0xc(%rdi), %ecx
incl %eax
movl %eax, 0x4(%rdi)
movl (%r12), %esi
movl 0x10(%rdi), %r8d
movq %rcx, %rdi
shlq $0x5, %rdi
addq %r14, %rdi
addq $0x200, %rdi            # imm = 0x200
subl (%rdi,%r8,8), %esi
incl %esi
movb $0x1, %bpl
cmpl %esi, %eax
jl 0x8916
leaq 0x200(%r14), %r15
leaq 0x14(%rsp), %r13
movq %r13, %rdi
movq %r14, %rsi
movq %rdx, 0x8(%rsp)
callq 0x879c
movl 0x4(%r13), %eax
movl %eax, 0x4(%rbx)
movl 0x8(%rbx), %ecx
movl 0xc(%rbx), %edx
incl %ecx
movl %ecx, 0x8(%rbx)
movl 0x4(%r12), %esi
movl 0x10(%rbx), %eax
shlq $0x5, %rdx
addq %r15, %rdx
subl 0x4(%rdx,%rax,8), %esi
incl %esi
cmpl %esi, %ecx
jl 0x8916
leaq 0x288(%r14), %r12
movl %eax, %edi
callq 0x9c12
movl %eax, 0x10(%rbx)
movl 0xc(%rbx), %ecx
testl %eax, %eax
jne 0x88e3
movl %ecx, %edi
callq 0x9c06
movl %eax, 0xc(%rbx)
testl %eax, %eax
je 0x8914
movl %eax, %ecx
movl 0x10(%rbx), %eax
movl %ecx, %edx
movl %eax, %esi
leaq (%r12,%rdx,4), %rdx
cmpb $0x0, (%rsi,%rdx)
jne 0x88bf
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movq %r14, %rsi
movq 0x8(%rsp), %rdx
movl %eax, %r8d
callq 0x879c
movq 0x4(%r12), %rax
movq %rax, 0x4(%rbx)
jmp 0x8916
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: operator<<(std::ostream&, board const&)
std::ostream & operator << (std::ostream & out, board const & brd) {
    repeat (y, board_size) {
        repeat (x, board_size) {
            int n = brd.at({ x, y });
            if (n == 0) {
                out << "\x1b[40m  ";
            } else if (n == 1) {
                out << "\x1b[47m  ";
            } else {
                const char table[] = "0123456789ABCDEF";
                int a = (n-2)/16;
                int b = (n-2)%16;
                out << "\x1b[4" << ((n - 2) % 6 + 1) << "m" << (a == 0 ? ' ' : table[a]) << table[b];
            }
        }
        out << "\x1b[49m" << std::endl;
    }
    return out;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
xorl %eax, %eax
cmpq $0x20, %rax
je 0x8a38
movq %rax, (%rsp)
xorl %r15d, %r15d
cmpq $0x20, %r15
je 0x8a11
movl (%r14,%r15,4), %ebp
cmpl $0x1, %ebp
je 0x896e
testl %ebp, %ebp
jne 0x8982
movq %rbx, %rdi
leaq 0x2a07(%rip), %rsi      # 0xb373
jmp 0x8978
movq %rbx, %rdi
leaq 0x2a03(%rip), %rsi      # 0xb37b
callq 0x2140
jmp 0x8a09
leal -0x2(%rbp), %r13d
movl %r13d, %eax
cltd
pushq $0x10
popq %rcx
idivl %ecx
movl %eax, %r12d
movq %rbx, %rdi
leaq 0x29e7(%rip), %rsi      # 0xb383
callq 0x2140
movq %rax, %rdi
movl %r13d, %eax
cltd
pushq $0x6
popq %rcx
idivl %ecx
leal 0x1(%rdx), %esi
callq 0x2260
movq %rax, %rdi
leaq 0x29cc(%rip), %rsi      # 0xb38b
callq 0x2140
leal 0xd(%rbp), %edx
movb $0x20, %cl
cmpl $0x1f, %edx
jb 0x89db
movslq %r12d, %rcx
leaq 0x29b8(%rip), %rdx      # 0xb390
movb (%rcx,%rdx), %cl
shll $0x4, %r12d
negl %r12d
addl %r12d, %ebp
addl $-0x2, %ebp
movsbl %cl, %esi
movq %rax, %rdi
callq 0x2190
movslq %ebp, %rcx
leaq 0x2993(%rip), %rdx      # 0xb390
movsbl (%rcx,%rdx), %esi
movq %rax, %rdi
callq 0x2190
incq %r15
jmp 0x894b
movq %rbx, %rdi
leaq 0x296c(%rip), %rsi      # 0xb387
callq 0x2140
movq %rax, %rdi
callq 0x2090
movq (%rsp), %rax
incq %rax
subq $-0x80, %r14
jmp 0x893a
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: int area_cell<bool, 8>(bool const (&) [8][8], bool)
int area_cell(T const (& a)[N][N], T target) {
    int n = 0;
    repeat (y,N) {
        repeat (x,N) {
            if (a[y][x] == target) {
                n += 1;
            }
        }
    }
    return n;
}

// Assembly:
xorl %ecx, %ecx
xorl %eax, %eax
cmpq $0x8, %rcx
je 0x8de7
xorl %edx, %edx
cmpq $0x8, %rdx
je 0x8dde
xorl %r8d, %r8d
cmpb %sil, (%rdi,%rdx)
sete %r8b
addl %r8d, %eax
incq %rdx
jmp 0x8dc5
incq %rcx
addq $0x8, %rdi
jmp 0x8dbd
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: void copy_cell_flip<bool, 8>(bool const (&) [8][8], bool (&) [8][8])
void copy_cell_flip(T const (& src)[N][N], T (& dst)[N][N]) {
    repeat (y,N) {
        repeat (x,N) {
            // > 裏返した後は，与えられたときの配置と左右に反転しているものとする。
            dst[y][N-x-1] = src[y][x];
        }
    }
}

// Assembly:
xorl %eax, %eax
pushq $0x8
popq %rcx
cmpq $0x8, %rax
je 0x8e48
movq %rdi, %rdx
movq %rcx, %r9
movq %rcx, %r8
subq $0x1, %r8
jb 0x8e3b
movb (%rdx), %r10b
movb %r10b, -0x1(%rsi,%r9)
incq %rdx
movq %r8, %r9
jmp 0x8e25
incq %rax
addq $0x8, %rsi
addq $0x8, %rdi
jmp 0x8e16
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: void copy_cell_rot90<bool, 8>(bool const (&) [8][8], bool (&) [8][8])
void copy_cell_rot90(T const (& src)[N][N], T (& dst)[N][N]) {
    repeat (y,N) {
        repeat (x,N) {
            // 8×8 のマス全体を時計回りに 90 度，180 度，270 度回転させることができる。
            dst[x][N-1-y] = src[y][x];
        }
    }
}

// Assembly:
addq $0x7, %rsi
xorl %eax, %eax
cmpq $0x8, %rax
je 0x8e74
xorl %ecx, %ecx
cmpq $0x8, %rcx
je 0x8e68
movb (%rdi,%rcx), %dl
movb %dl, (%rsi,%rcx,8)
incq %rcx
jmp 0x8e57
incq %rax
addq $0x8, %rdi
decq %rsi
jmp 0x8e4f
retq
// File: /workspace/github_cpp_makefile_star2_O2/kmyk[P]procon26/procon26.cpp
// Function: std::vector<point_t, std::allocator<point_t>> collect_cell<bool, 8>(bool const (&) [8][8], point_t const&, point_t const&)
std::vector<point_t> collect_cell(T const (& a)[N][N], point_t const & offset, point_t const & size) {
    std::vector<point_t> result;
    repeat (y,size.y) {
        repeat (x,size.x) {
            point_t p = offset + (point_t) { x, y };
            if (a[p.y][p.x]) result.push_back(p);
        }
    }
    return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
andq $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
xorl %ebp, %ebp
cmpl 0x4(%r14), %ebp
jge 0x8ef9
xorl %r13d, %r13d
cmpl (%r14), %r13d
jge 0x8ef1
movslq (%r15), %rax
leal (%rax,%r13), %ecx
movslq 0x4(%r15), %rdx
leal (%rdx,%rbp), %esi
shlq $0x20, %rsi
orq %rsi, %rcx
movq %rcx, (%rsp)
leaq (%rax,%rdx,8), %rax
addq %r12, %rax
cmpb $0x1, (%r13,%rax)
jne 0x8eec
movq %rbx, %rdi
movq %rsp, %rsi
callq 0x42c8
incq %r13
jmp 0x8eb4
incl %ebp
addq $0x8, %r12
jmp 0x8eab
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x409a
movq %r14, %rdi
callq 0x2270