LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/client/view.cpp
// Function: (anonymous namespace)::draw_titles()
void draw_titles()
{
	char len;
	char *pos = &(viewbuffer[VIEWSIZE*VIEWSIZE*2+1]);
	char x, y;
	char syms;
	for(char num = viewbuffer[VIEWSIZE*VIEWSIZE*2]; num > 0; --num)
	{
		y = *(pos+1); // pos&pos+1 are x/y pair, string begins at pos+2.
		len = strlen(pos+2);
		// If we are alive, don't draw any title coming to the center (that
		// would be our OWN title)
		if(*pos != VIEWSIZE/2 || y != VIEWSIZE/2 || !ClassCPV::im_alive())
		{
			// x-position might need shifting so the string doesn't go over the edge:
			syms = num_syms(string(pos+2));
			x = *pos - syms/2;
			if(x < 0)
				x = 0;
			else if(x + syms > VIEWSIZE)
				x = VIEWSIZE - syms;
			Base::print_str(pos+2, TITLE_CPAIR, x, y, VIEW_WIN);
		}
		pos += len+3; // lenght of string + '\0' + 2 chars
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
leaq 0xc5d9(%rip), %r12      # 0x18ae3
movb 0xc5d2(%rip), %bl       # 0x18ae2
testb %bl, %bl
jle 0xc5c2
movb 0x1(%r12), %r15b
leaq 0x2(%r12), %r14
movq %r14, %rdi
callq 0x41c0
movq %rax, %r13
movb (%r12), %al
xorb $0xb, %al
movb %r15b, -0x29(%rbp)
xorb $0xb, %r15b
orb %al, %r15b
jne 0xc549
callq 0x6f7d
testb %al, %al
jne 0xc5b0
leaq -0x50(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
leaq -0x2a(%rbp), %rdx
callq 0x69bc
movq %r15, %rdi
callq 0xd028
movq %r15, %rdi
movl %eax, %r15d
callq 0x4748
movsbl %r15b, %eax
movb $-0x2, %cl
idivb %cl
addb (%r12), %al
js 0xc595
movsbl %r15b, %ecx
movzbl %al, %eax
addl %eax, %ecx
cmpl $0x18, %ecx
jl 0xc597
movb $0x17, %al
subb %r15b, %al
movzbl %al, %eax
jmp 0xc597
xorl %eax, %eax
movsbl %al, %edx
movsbl -0x29(%rbp), %ecx
movq %r14, %rdi
pushq $0x6a
popq %rsi
pushq $0x3
popq %r8
xorl %r9d, %r9d
callq 0x61ca
movsbq %r13b, %rax
addq %rax, %r12
addq $0x3, %r12
decb %bl
jmp 0xc510
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x4748
movq %rbx, %rdi
callq 0x4650
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/client/view.cpp
// Function: diff_titles()
void diff_titles()
{
	// cf. "draw_titles()"
	char *pos = &(viewbuffer[VIEWSIZE*VIEWSIZE*2+1]);
	string s = "";
	for(char num = viewbuffer[VIEWSIZE*VIEWSIZE*2]; num > 0; --num)
	{
		if(*pos != VIEWSIZE/2 || *(pos+1) != VIEWSIZE/2 || !ClassCPV::im_alive())
		{
			s += (pos+2);
			s += ", ";
		}
		pos += strlen(pos+2)+3;
	}
	if(!s.empty())
		s.erase(s.size()-2);
	s.insert(0, "Titles: ");
	add_to_chat(s, "", T_NO_TEAM);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x50, %rsp
leaq 0x1b9b(%rip), %rsi      # 0xe489
leaq -0x48(%rbp), %rbx
leaq -0x68(%rbp), %rdx
movq %rbx, %rdi
callq 0x69bc
leaq 0xc1de(%rip), %r15      # 0x18ae3
movb 0xc1d6(%rip), %r12b     # 0x18ae2
leaq 0x22a5(%rip), %r14      # 0xebb8
testb %r12b, %r12b
jle 0xc95a
cmpb $0xb, (%r15)
jne 0xc92e
cmpb $0xb, 0x1(%r15)
jne 0xc92e
callq 0x6f7d
testb %al, %al
jne 0xc945
leaq 0x2(%r15), %rsi
movq %rbx, %rdi
callq 0x46c0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x46c0
leaq 0x2(%r15), %rdi
callq 0x41c0
addq %rax, %r15
addq $0x3, %r15
decb %r12b
jmp 0xc913
movq -0x40(%rbp), %rsi
testq %rsi, %rsi
je 0xc973
addq $-0x2, %rsi
leaq -0x48(%rbp), %rdi
pushq $-0x1
popq %rdx
callq 0x40e0
leaq 0x2241(%rip), %rdx      # 0xebbb
leaq -0x48(%rbp), %rdi
xorl %esi, %esi
callq 0x4100
leaq 0x1afd(%rip), %rsi      # 0xe489
leaq -0x68(%rbp), %rdi
leaq -0x21(%rbp), %rdx
callq 0x69bc
leaq -0x48(%rbp), %rdi
leaq -0x68(%rbp), %rsi
pushq $0x3
popq %rdx
callq 0x8fec
leaq -0x68(%rbp), %rdi
callq 0x4748
leaq -0x48(%rbp), %rdi
callq 0x4748
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x4748
jmp 0xc9dd
jmp 0xc9da
jmp 0xc9da
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x4748
movq %rbx, %rdi
callq 0x4650
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/netutils.cpp
// Function: SerialBuffer::add(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
void SerialBuffer::add(const string &str)
{
	copy(str.begin(), str.end(), pos);
	pos += str.size();
	*pos = '\0';
	++pos;
	num += str.size()+1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq 0x8(%rsi), %rdx
testq %rdx, %rdx
je 0xccc1
movq (%r14), %rsi
movq (%rbx), %rdi
callq 0x4620
movq 0x8(%r14), %rax
jmp 0xccc3
xorl %eax, %eax
movq (%rbx), %rcx
leaq (%rcx,%rax), %rdx
movq %rdx, (%rbx)
movb $0x0, (%rcx,%rax)
incq (%rbx)
movzwl 0x8(%r14), %eax
addw 0x8(%rbx), %ax
incl %eax
movw %ax, 0x8(%rbx)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/netutils.cpp
// Function: SerialBuffer::write_compressed(char*, unsigned short)
void SerialBuffer::write_compressed(char *buffer, const unsigned short len)
{
	uLongf res_size = BUFFER_SIZE; // actually this is not how much room there is, but
	// we'll never run out of room here anyway.

	// leave room in the beginning for the size short
	compress((Bytef*)(pos+2), &res_size, (Bytef*)buffer, len);
	add((unsigned short)res_size); //NOTE: pos has not been moved, so this writes right before the compressed data
	pos += res_size;
	num += res_size;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rax
movq %rdi, %rbx
leaq -0x18(%rbp), %r14
movq $0x800, (%r14)          # imm = 0x800
movq (%rdi), %rdi
addq $0x2, %rdi
movl %edx, %ecx
movq %r14, %rsi
movq %rax, %rdx
callq 0x40d0
movzwl (%r14), %esi
movq %rbx, %rdi
callq 0xcc70
movq (%r14), %rax
addq %rax, (%rbx)
addw %ax, 0x8(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/netutils.cpp
// Function: SerialBuffer::read_str(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
void SerialBuffer::read_str(string &target)
{
	// If we trusted the other end blindly, we could just do:
#if 0
	target.assign(pos);
	pos += target.size()+1;
#endif
	/* But alas, there are mean people out there who would abuse such a hole.
	 * Hence we enforce a maximum length of a string and read carefully
	 * one byte at a time (there might not be any '\0' in the buffer to end the
	 * string!) */
	target.clear();
	// Read (A) at most the maximum string length, (B) at most as much as there
	// is buffer left!
	short bs_read = 0;
	while(bs_read < MAXIMUM_STR_LEN && pos != arr+BUFFER_SIZE)
	{
		if(*pos == '\0')
		{
			++pos;
			break;
		}
		target += *pos;
		++pos;
		++bs_read;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
andq $0x0, 0x8(%rsi)
movq (%rsi), %rax
movb $0x0, (%rax)
leaq 0x80a(%rdi), %r15
movw $0x15e, %r12w           # imm = 0x15E
subw $0x1, %r12w
jb 0xcdb5
movq (%rbx), %rax
cmpq %r15, %rax
je 0xcdb5
movb (%rax), %cl
testb %cl, %cl
je 0xcdaf
movsbl %cl, %esi
movq %r14, %rdi
callq 0x4310
incq (%rbx)
jmp 0xcd8a
incq %rax
movq %rax, (%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/netutils.cpp
// Function: SerialBuffer::read_compressed(char*)
bool SerialBuffer::read_compressed(char *buffer)
{
	// read the size of the block:
	unsigned short sh = read_sh();
	uLongf res_size = BUFFER_SIZE;
	int r = uncompress((Bytef*)buffer, &res_size, (Bytef*)pos, sh);
	if(r == Z_BUF_ERROR || r == Z_DATA_ERROR)
		return true;
	// Z_MEM_ERROR (insufficient memory) is highly unlikely and would cause more
	// general problems.
	pos += res_size;
	return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rsi, %rax
movq %rdi, %rbx
movq (%rdi), %rdx
movzwl (%rdx), %ecx
addq $0x2, %rdx
rolw $0x8, %cx
movq %rdx, (%rdi)
leaq -0x10(%rbp), %rsi
movq $0x800, (%rsi)          # imm = 0x800
movzwl %cx, %ecx
movq %rax, %rdi
callq 0x4170
cmpl $-0x5, %eax
je 0xce02
cmpl $-0x3, %eax
je 0xce02
movq -0x10(%rbp), %rcx
addq %rcx, (%rbx)
addl $0x5, %eax
testl $0xfffffffd, %eax       # imm = 0xFFFFFFFD
sete %al
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: del(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, int)
void del(string &s, const int n)
{
	string::iterator i = s.begin();
	advance(i, s, n);
	for(char c = seq_len(*i); c > 0; --c)
	{
		if((i = s.erase(i)) == s.end())
			break; /* If this happens, string is not proper UTF-8!
		            * We can't really do anything with such a string;
					* this is just to avoid nasty segfaults. */
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
leaq -0x20(%rbp), %r14
movq %rax, (%r14)
movswl %si, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xce9d
movq (%r14), %r14
movsbl (%r14), %edi
callq 0xcf19
movl %eax, %r15d
incb %r15b
decb %r15b
jle 0xce92
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4490
movq %rax, %r14
movq (%rbx), %rax
addq 0x8(%rbx), %rax
cmpq %rax, %r14
jne 0xce73
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: (anonymous namespace)::advance(__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, short)
void advance(string::iterator &i, string &s, short num)
{
	char l;
	for(; num > 0; --num)
	{
		l = seq_len(*i);
		do { ++i; --l; }
		while(l > 0 // sequence is ready,
			&& i != s.end() // premature end of string,
			&& !invalid_cont_byte(*i)); // non-first byte invalid for continuation

#ifdef DEBUG
		if(l > 0) // if was broken for some other reason than this, something is wrong
		{
			cerr << inv_utf8_warning << endl;
			return;
		}
#endif
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
testw %bx, %bx
jle 0xcf0e
movq (%r15), %rax
movsbl (%rax), %edi
callq 0xcf19
movq (%r15), %rdx
movq (%r14), %rcx
addq 0x8(%r14), %rcx
incq %rdx
movq %rdx, (%r15)
cmpb $0x2, %al
jl 0xcee5
cmpq %rcx, %rdx
je 0xcee9
decb %al
cmpb $-0x40, (%rdx)
leaq 0x1(%rdx), %rdx
jl 0xcecc
jmp 0xcee9
decl %ebx
jmp 0xceaf
movq 0x9100(%rip), %rdi      # 0x15ff0
leaq 0xc7d9(%rip), %rsi      # 0x196d0
callq 0x4340
movq %rax, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x41f0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: (anonymous namespace)::seq_len(char)
char seq_len(char leadch) // determine the length of the sequence starting with leadch
{
	unsigned char lead = static_cast<unsigned char>(leadch);
	if(lead < 0x80)
		return 1;
	if(lead >= 0xC2 && lead <= 0xDF)
		return 2;
	if(lead >= 0xE0 && lead <= 0xEF)
		return 3;
	if(lead >= 0xF0 && lead <= 0xF4)
		return 4;
#ifdef DEBUG
	cerr << inv_utf8_warning << endl;
#endif
	return 1; // invalid lead!
}

// Assembly:
movb $0x1, %al
testb %dil, %dil
js 0xcf21
retq
leal 0x3e(%rdi), %ecx
movb $0x2, %al
cmpb $0x1e, %cl
jb 0xcf20
movl %edi, %ecx
andb $-0x10, %cl
movb $0x3, %al
cmpb $-0x20, %cl
je 0xcf20
addb $0x10, %dil
movb $0x4, %al
cmpb $0x5, %dil
jb 0xcf20
pushq %rbp
movq %rsp, %rbp
movq 0x90a2(%rip), %rdi      # 0x15ff0
leaq 0xc77b(%rip), %rsi      # 0x196d0
callq 0x4340
movq %rax, %rdi
callq 0x41f0
movb $0x1, %al
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: ins(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, unsigned int, int)
void ins(string &s, const unsigned int c, const int n)
{
	// First interpret "n symbols" in terms of a string iterator:
	string::iterator i = s.begin();
	advance(i, s, n);
	if(c < 0x80) // single byte
		s.insert(i, static_cast<unsigned char>(c));
	else if(c < 0x800) // 2 bytes
	{
		i = s.insert(i, static_cast<unsigned char>((c >> 6) | 0xc0));
		s.insert(++i, static_cast<unsigned char>((c & 0x3f) | 0x80));
	}
	else if(c < 0x10000) // 3
	{
		i = s.insert(i, static_cast<unsigned char>((c >> 12) | 0xe0));
		i = s.insert(++i, static_cast<unsigned char>(((c >> 6) & 0x3f) | 0x80));
		s.insert(++i, static_cast<unsigned char>((c & 0x3f) | 0x80));
	}
	else // 4
	{
		i = s.insert(i, static_cast<unsigned char>((c >> 18) | 0xf0));
		i = s.insert(++i, static_cast<unsigned char>(((c >> 12) & 0x3f) | 0x80));
		i = s.insert(++i, static_cast<unsigned char>(((c >> 6) & 0x3f) | 0x80));
		s.insert(++i, static_cast<unsigned char>((c & 0x3f) | 0x80));
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %r14d
movq %rdi, %rbx
movq (%rdi), %rax
leaq -0x18(%rbp), %rdi
movq %rax, (%rdi)
movswl %dx, %edx
movq %rbx, %rsi
callq 0xce9d
cmpl $0x7f, %r14d
ja 0xcf98
movq -0x18(%rbp), %rsi
jmp 0xd014
cmpl $0x7ff, %r14d           # imm = 0x7FF
ja 0xcfaf
movq -0x18(%rbp), %rsi
movl %r14d, %eax
shrl $0x6, %eax
orb $-0x40, %al
jmp 0xcffd
movq -0x18(%rbp), %rsi
movl %r14d, %eax
cmpl $0xffff, %r14d          # imm = 0xFFFF
ja 0xcfc6
shrl $0xc, %eax
orb $-0x20, %al
jmp 0xcfe4
shrl $0x12, %eax
orb $-0x10, %al
movsbl %al, %edx
movq %rbx, %rdi
callq 0x46b0
leaq 0x1(%rax), %rsi
movl %r14d, %eax
shrl $0xc, %eax
andb $0x3f, %al
orb $-0x80, %al
movsbl %al, %edx
movq %rbx, %rdi
callq 0x46b0
leaq 0x1(%rax), %rsi
movl %r14d, %eax
shrl $0x6, %eax
andb $0x3f, %al
orb $-0x80, %al
movsbl %al, %edx
movq %rbx, %rdi
callq 0x46b0
leaq 0x1(%rax), %rsi
andb $0x3f, %r14b
orb $-0x80, %r14b
movsbl %r14b, %edx
movq %rbx, %rdi
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0x46b0
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: num_syms(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
short num_syms(const string &s)
{
	// we assume the string is valid UTF-8, and can hence simply count the non-continuation bytes
	int n = 0;
	for(string::const_iterator i = s.begin(); i != s.end(); ++i)
	{
		if(static_cast<unsigned char>(*i) < 0x80 || static_cast<unsigned char>(*i) > 0xBF)
			++n;
	}
	return n;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rcx
movq 0x8(%rdi), %rdx
xorl %esi, %esi
xorl %eax, %eax
cmpq %rsi, %rdx
je 0xd04d
xorl %edi, %edi
cmpb $-0x40, (%rcx,%rsi)
setge %dil
addl %edi, %eax
incq %rsi
jmp 0xd037
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: ind_of_sym(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int)
short ind_of_sym(const string &s, int n)
{
	short b = 0;
	for(; n > 0; --n)
		b += seq_len(s[b]);
	return b;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
xorl %r15d, %r15d
testl %ebx, %ebx
jle 0xd0cc
movswq %r15w, %rax
movq (%r14), %rcx
movsbl (%rcx,%rax), %edi
callq 0xcf19
movzbl %al, %eax
addl %r15d, %eax
decl %ebx
movl %eax, %r15d
jmp 0xd0ab
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: mb_substr(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, short, short)
std::string mb_substr(const string &s, const short beg, short len)
{
	short b = ind_of_sym(s, beg);
	short e = 0;
	for(; len > 0; --len)
		e += seq_len(s[b+e]);
	return s.substr(b, e);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %r15d
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
movl %edx, %esi
callq 0xd099
movswq %ax, %r12
xorl %eax, %eax
movswq %ax, %r13
testw %r15w, %r15w
jle 0xd166
movq (%r14), %rax
addq %r12, %rax
movsbl (%r13,%rax), %edi
callq 0xcf19
movzbl %al, %eax
addl %r13d, %eax
decl %r15d
jmp 0xd140
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movq %r13, %rcx
callq 0x43c0
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/lotuskip[P]yuxtapa/common/utfstr.cpp
// Function: low_bound(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, short)
short low_bound(const std::string &s, const short n)
{
	short a = n;
	while(!invalid_cont_byte(s[a]))
		--a;
	if(a + seq_len(s[a]) > n)
		return a;
	return n;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq (%rdi), %rcx
movl %ebx, %r14d
movswq %r14w, %rax
movb (%rcx,%rax), %al
decl %r14d
cmpb $-0x40, %al
jl 0xd19b
incl %r14d
movswl %r14w, %r15d
movsbl %al, %edi
callq 0xcf19
movzbl %al, %ecx
addl %r15d, %ecx
movswl %bx, %eax
cmpl %eax, %ecx
cmovgl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/confdir.cpp
// Function: get_conf_dir[abi:cxx11]()
std::string get_conf_dir()
{
	std::string s;
	char *tmp = getenv("HOME");
	if(tmp && tmp[0])
		s = std::string(tmp);
	else
	{
		std::cerr << "HOME not defined!" << std::endl;
		exit(1);
	}
	s += "/.config/yuxtapa/";
	return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
leaq 0x3eb8(%rip), %rdi      # 0x110b1
callq 0x4470
testq %rax, %rax
je 0xd24a
cmpb $0x0, (%rax)
je 0xd24a
leaq -0x38(%rbp), %rdi
leaq -0x11(%rbp), %rdx
movq %rax, %rsi
callq 0x69bc
leaq -0x38(%rbp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4480
movq %r14, %rdi
callq 0x4748
leaq 0x3e92(%rip), %rsi      # 0x110c8
movq %rbx, %rdi
callq 0x46c0
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0x8d9f(%rip), %rdi      # 0x15ff0
leaq 0x3e5e(%rip), %rsi      # 0x110b6
callq 0x4390
movq %rax, %rdi
callq 0x41f0
pushq $0x1
popq %rdi
callq 0x4460
jmp 0xd26f
movq %rax, %r14
movq %rbx, %rdi
callq 0x4748
movq %r14, %rdi
callq 0x4650
nop
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/coords.cpp
// Function: Coords::in(e_Dir) const
Coords Coords::in(const e_Dir d) const
{
	Coords c(x,y);
	switch(d)
	{
		case D_N: c.y--; break;
		case D_NE: c.x++; c.y--; break;
		case D_E: c.x++; break;
		case D_SE: c.x++; c.y++; break;
		case D_S: c.y++; break;
		case D_SW: c.x--; c.y++; break;
		case D_W: c.x--; break;
		case D_NW: c.x--; c.y--; break;
		default: /*assert(0)*/;
	}
	return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rax
movzwl (%rsi), %edi
movzwl 0x2(%rsi), %ecx
movw %di, (%rax)
movw %cx, 0x2(%rax)
cmpl $0x7, %edx
ja 0xd397
movl %edx, %edx
leaq 0x3d75(%rip), %rsi      # 0x110dc
movslq (%rsi,%rdx,4), %rdx
addq %rsi, %rdx
jmpq *%rdx
incl %edi
jmp 0xd37e
incl %edi
jmp 0xd387
incl %edi
jmp 0xd394
decl %edi
movw %di, (%rax)
decl %ecx
jmp 0xd38c
decl %edi
movw %di, (%rax)
incl %ecx
movw %cx, 0x2(%rax)
jmp 0xd397
decl %edi
movw %di, (%rax)
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/coords.cpp
// Function: Coords::unitise()
void Coords::unitise()
{
	short len = short(dist_eucl(Coords(0,0)));
	if(len)
	{
		x /= len;
		y /= len;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq -0xc(%rbp), %rsi
andl $0x0, (%rsi)
callq 0xd2dc
cvttss2si %xmm0, %eax
testw %ax, %ax
je 0xd3cf
movswl %ax, %ecx
movswl (%rbx), %eax
cltd
idivl %ecx
movw %ax, (%rbx)
movswl 0x2(%rbx), %eax
cltd
idivl %ecx
movw %ax, 0x2(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/coords.cpp
// Function: Coords::dir_of(Coords) const
e_Dir Coords::dir_of(Coords ref) const
{
	// Basically, we construct the vector from *this to ref and
	// shrink it (in a Euclidian fashion) to a unit vector, which
	// we then interpret as a direction:
	ref.x -= x;
	ref.y -= y;
	ref.unitise();
	switch(ref.x + ref.y)
	{
	case 2: return D_SE;
	case -2: return D_NW;
	case 1: if(ref.x) return D_E;
		return D_S;
	case -1: if(ref.x) return D_W;
		return D_N;
	case 0: if(ref.x == 1) return D_NE;
		return D_SW;
	}
	return D_N; // reaching this line is an error!
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movzwl (%rdi), %eax
subw %ax, (%rsi)
movzwl 0x2(%rdi), %eax
subw %ax, 0x2(%rsi)
movq %rsi, %rdi
callq 0xd39a
movswl (%rbx), %eax
movswl 0x2(%rbx), %ecx
addl %eax, %ecx
addl $0x2, %ecx
cmpl $0x4, %ecx
ja 0xd44f
leaq 0x3cef(%rip), %rdx      # 0x110fc
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
pushq $0x7
jmp 0xd41c
pushq $0x3
popq %rax
jmp 0xd451
xorl %ecx, %ecx
cmpw $0x1, %ax
setne %cl
leal 0x1(,%rcx,4), %eax
jmp 0xd451
xorl %ecx, %ecx
testw %ax, %ax
sete %cl
leal 0x2(,%rcx,2), %eax
jmp 0xd451
xorl %ecx, %ecx
testw %ax, %ax
pushq $0x6
popq %rax
cmovel %ecx, %eax
jmp 0xd451
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/common/util.cpp
// Function: trim_str(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
void trim_str(string &s)
{
	while(!s.empty() && s[0] == ' ')
		s.erase(0,1);
	while(!s.empty() && s[s.size()-1] == ' ')
		s.erase(s.size()-1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
pushq $0x1
popq %r14
movq 0x8(%rbx), %rsi
testq %rsi, %rsi
je 0xd50c
movq (%rbx), %rax
cmpb $0x20, (%rax)
jne 0xd50c
movq %rbx, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x40e0
jmp 0xd4d0
movq (%rbx), %rax
cmpb $0x20, -0x1(%rax,%rsi)
jne 0xd511
decq %rsi
pushq $-0x1
popq %rdx
movq %rbx, %rdi
callq 0x40e0
movq 0x8(%rbx), %rsi
testq %rsi, %rsi
jne 0xd4f0
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/error.cpp
// Function: printCachedErrors()
bool printCachedErrors()
{
    if (cached_errors.size() != 0) {
        std::cout << "compile terminated with error(s):" << std::endl;
        int count = 0;
        for (std::string msg : cached_errors) {
            if (count == 6) {
                std::cout << "Ommited " << (cached_errors.size() - 0) 
                    << "+ more errors" << std::endl;
                break;
            }
            std::cout << msg;
            count++;
        }
        return true;
    }
    return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq 0x152c4(%rip), %rax     # 0x1f0f8
movq 0x152b5(%rip), %rcx     # 0x1f0f0
movq %rax, -0x38(%rbp)
movq %rcx, -0x30(%rbp)
cmpq %rcx, %rax
je 0x9f0b
movq 0x14175(%rip), %rdi     # 0x1dfc8
leaq 0xc3e5(%rip), %rsi      # 0x1623f
callq 0x3280
movq %rax, %rdi
callq 0x3130
movq 0x15282(%rip), %r14     # 0x1f0f0
xorl %r13d, %r13d
movq 0x15280(%rip), %r12     # 0x1f0f8
leaq -0x58(%rbp), %r15
cmpq %r12, %r14
je 0x9f0b
movq %r15, %rdi
movq %r14, %rsi
callq 0x3350
cmpl $0x6, %r13d
jne 0x9edf
movq 0x1412b(%rip), %rdi     # 0x1dfc8
leaq 0xc3bd(%rip), %rsi      # 0x16261
callq 0x3280
movq 0x15248(%rip), %rsi     # 0x1f0f8
subq 0x15239(%rip), %rsi     # 0x1f0f0
sarq $0x5, %rsi
movq %rax, %rdi
callq 0x31d0
movq %rax, %rdi
leaq 0xc39d(%rip), %rsi      # 0x1626a
callq 0x3280
movq %rax, %rdi
callq 0x3130
pushq $0x6
popq %rbx
jmp 0x9ef2
movq 0x140e2(%rip), %rdi     # 0x1dfc8
movq %r15, %rsi
callq 0x3250
leal 0x1(%r13), %ebx
movq %r15, %rdi
callq 0x3498
addq $0x20, %r14
cmpl $0x6, %r13d
movl %ebx, %r13d
jne 0x9e7c
movq -0x30(%rbp), %rax
cmpq %rax, -0x38(%rbp)
setne %al
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x3498
movq %rbx, %rdi
callq 0x3430
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/error.cpp
// Function: skip(Symset)
void skip(Symset fsys)
{
    //bool skipped = false;
    while (!fsys.contains(g_sym)) {
        //skipped = true;
        // TODO: underline for skipped words
        readSymbol();
    }
    //if (skipped) std::cout << std::endl;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x1a6c6(%rip), %r14     # 0x24610
movl (%r14), %eax
btq %rax, %rbx
jb 0x9f5a
callq 0x13808
jmp 0x9f4a
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/error.cpp
// Function: test(Symset, Symset)
void test(Symset s1, Symset s2)
{
    if (!s1.contains(g_sym)) {
        std::vector<int> syms = s1.toVector();
        std::stringstream buffer;
        buffer << "error: expected ";
        for (unsigned int i = 0; i < syms.size(); i++) {
            if (i != 0) buffer << "|";
            buffer << sym2str[syms[i]];
        }
        buffer << " before " << sym2str[g_sym];
        printError(buffer.str());
        skip(s1 + s2);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1c8, %rsp            # imm = 0x1C8
movq %rdi, -0x30(%rbp)
leaq 0x1a692(%rip), %rax     # 0x24610
movl (%rax), %eax
btq %rax, %rdi
jb 0xa07d
movq %rsi, %rbx
leaq -0x48(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0xa500
leaq -0x1f0(%rbp), %rdi
callq 0x31f0
leaq -0x1e0(%rbp), %r15
leaq 0xc2c4(%rip), %rsi      # 0x16278
movq %r15, %rdi
callq 0x3280
xorl %r13d, %r13d
leaq 0x147aa(%rip), %r14     # 0x1e770
leaq 0xc2bc(%rip), %r12      # 0x16289
movl %r13d, %r13d
movq -0x48(%rbp), %rax
movq -0x40(%rbp), %rcx
subq %rax, %rcx
sarq $0x2, %rcx
cmpq %r13, %rcx
jbe 0xa010
testq %r13, %r13
je 0x9ff8
movq %r15, %rdi
movq %r12, %rsi
callq 0x3280
movq -0x48(%rbp), %rax
movslq (%rax,%r13,4), %rsi
shlq $0x5, %rsi
addq %r14, %rsi
movq %r15, %rdi
callq 0x3250
incl %r13d
jmp 0x9fcd
leaq 0xc274(%rip), %rsi      # 0x1628b
movq %r15, %rdi
callq 0x3280
leaq 0x1a5ea(%rip), %rcx     # 0x24610
movl (%rcx), %ecx
shlq $0x5, %rcx
addq %rcx, %r14
movq %rax, %rdi
movq %r14, %rsi
callq 0x3250
leaq -0x1d8(%rbp), %rsi
leaq -0x68(%rbp), %rdi
callq 0x33d0
leaq -0x68(%rbp), %rdi
callq 0xa0c4
leaq -0x68(%rbp), %rdi
callq 0x3498
orq -0x30(%rbp), %rbx
movq %rbx, %rdi
callq 0x9f39
leaq -0x1f0(%rbp), %rdi
callq 0x34a0
leaq -0x48(%rbp), %rdi
callq 0xa940
addq $0x1c8, %rsp            # imm = 0x1C8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x3498
jmp 0xa0a7
movq %rax, %rbx
jmp 0xa0b3
jmp 0xa0a4
movq %rax, %rbx
leaq -0x1f0(%rbp), %rdi
callq 0x34a0
leaq -0x48(%rbp), %rdi
callq 0xa940
movq %rbx, %rdi
callq 0x3430
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/error.cpp
// Function: printError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
static void printError(std::string msg)
{
    std::stringstream buffer;
    buffer << source_filename << ":" << g_line_no << ":"
        << g_word_pos << ":" << msg << std::endl;
    buffer << g_line;
    for (unsigned int i = 0; i < g_word_pos; i++)
        buffer << " ";
    buffer << "^";
    // NOTE:
    // use explicit type conversion here to avoid
    // negative numbers!
    // it took me 2 hour to find this! :(
    for (int i = 0; i < (int)g_pos - (int)g_word_pos - 2; i++)
        buffer << "~";
    buffer << std::endl;
    cached_errors.push_back(buffer.str());
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1a8, %rsp            # imm = 0x1A8
movq %rdi, %r14
leaq -0x1d0(%rbp), %rdi
callq 0x31f0
leaq -0x1c0(%rbp), %rbx
leaq 0x16f53(%rip), %rsi     # 0x21048
movq %rbx, %rdi
callq 0x3250
leaq 0xc15b(%rip), %rsi      # 0x1625f
movq %rax, %rdi
callq 0x3280
leaq 0x1a571(%rip), %rcx     # 0x24684
movl (%rcx), %esi
movq %rax, %rdi
callq 0x31d0
leaq 0xc13b(%rip), %rsi      # 0x1625f
movq %rax, %rdi
callq 0x3280
leaq 0x1a555(%rip), %r15     # 0x24688
movl (%r15), %esi
movq %rax, %rdi
callq 0x31d0
leaq 0xc11a(%rip), %rsi      # 0x1625f
movq %rax, %rdi
callq 0x3280
movq %rax, %rdi
movq %r14, %rsi
callq 0x3250
movq %rax, %rdi
callq 0x3130
leaq 0x1a4f9(%rip), %rsi     # 0x24660
movq %rbx, %rdi
callq 0x3250
xorl %r12d, %r12d
leaq 0xcad3(%rip), %r14      # 0x16c4c
cmpl (%r15), %r12d
jae 0xa18e
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3280
incl %r12d
jmp 0xa179
leaq 0xc13f(%rip), %rsi      # 0x162d4
movq %rbx, %rdi
callq 0x3280
xorl %r12d, %r12d
leaq 0x1a4d9(%rip), %r13     # 0x24680
leaq 0xc128(%rip), %r14      # 0x162d6
movl (%r13), %eax
subl (%r15), %eax
addl $-0x2, %eax
cmpl %eax, %r12d
jge 0xa1cd
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3280
incl %r12d
jmp 0xa1ae
movq %rbx, %rdi
callq 0x3130
leaq -0x1b8(%rbp), %rsi
leaq -0x48(%rbp), %rdi
callq 0x33d0
leaq 0x14f04(%rip), %rdi     # 0x1f0f0
leaq -0x48(%rbp), %rsi
callq 0xa762
leaq -0x48(%rbp), %rdi
callq 0x3498
leaq -0x1d0(%rbp), %rdi
callq 0x34a0
addq $0x1a8, %rsp            # imm = 0x1A8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x3498
jmp 0xa233
jmp 0xa230
jmp 0xa230
jmp 0xa230
movq %rax, %rbx
leaq -0x1d0(%rbp), %rdi
callq 0x34a0
movq %rbx, %rdi
callq 0x3430
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/error.cpp
// Function: expect(Symbol)
void expect(Symbol sym)
{
    if (g_sym != sym) {
        std::cout << "Error: expect " << sym2str[sym]
            << " but got " << sym2str[g_sym];
        if (g_sym == IDENTSY)
            std::cout << "<" << g_id << ">";
        std::cout << std::endl;
        std::exit(1);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1a370(%rip), %r14     # 0x24610
cmpl %edi, (%r14)
jne 0xa2aa
popq %rbx
popq %r14
popq %rbp
retq
movl %edi, %ebx
movq 0x13d15(%rip), %rdi     # 0x1dfc8
leaq 0xbfe2(%rip), %rsi      # 0x1629c
callq 0x3280
movl %ebx, %esi
shlq $0x5, %rsi
leaq 0x144a4(%rip), %rbx     # 0x1e770
addq %rbx, %rsi
movq %rax, %rdi
callq 0x3250
leaq 0xbfd2(%rip), %rsi      # 0x162b0
movq %rax, %rdi
callq 0x3280
movl (%r14), %esi
shlq $0x5, %rsi
addq %rbx, %rsi
movq %rax, %rdi
callq 0x3250
cmpl $0x0, (%r14)
jne 0xa32f
movq 0x13cc3(%rip), %rdi     # 0x1dfc8
leaq 0xbf9f(%rip), %rsi      # 0x162ab
callq 0x3280
leaq 0x1a300(%rip), %rsi     # 0x24618
movq %rax, %rdi
callq 0x3250
leaq 0xbf86(%rip), %rsi      # 0x162ad
movq %rax, %rdi
callq 0x3280
movq 0x13c92(%rip), %rdi     # 0x1dfc8
callq 0x3130
pushq $0x1
popq %rdi
callq 0x3300
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/error.cpp
// Function: expectMul(int, ...)
void expectMul(int num, ...) 
{
    va_list valist;
    va_start(valist, num);
    for (int i = 0; i < num; i++) {
        Symbol sym = (Symbol)va_arg(valist, int);
        if (g_sym == sym) {
            va_end(valist);
            return;
        }
    }
    va_end(valist);
    std::cout << "Error: expect ";
    va_start(valist, num);
    for (int i = 0; i < num; i++) {
        if (i != 0)
            std::cout << "|";
        std::cout << sym2str[va_arg(valist, int)];
    }
    va_end(valist);
    std::cout << ", but got " << sym2str[g_sym] << std::endl;
    std::exit(1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
leaq -0xf0(%rbp), %rbx
movq %rsi, 0x8(%rbx)
movq %rdx, 0x10(%rbx)
movq %rcx, 0x18(%rbx)
movq %r8, 0x20(%rbx)
movq %r9, 0x28(%rbx)
testb %al, %al
je 0xa3a2
movaps %xmm0, -0xc0(%rbp)
movaps %xmm1, -0xb0(%rbp)
movaps %xmm2, -0xa0(%rbp)
movaps %xmm3, -0x90(%rbp)
movaps %xmm4, -0x80(%rbp)
movaps %xmm5, -0x70(%rbp)
movaps %xmm6, -0x60(%rbp)
movaps %xmm7, -0x50(%rbp)
movq %rbx, -0x30(%rbp)
leaq 0x10(%rbp), %rdx
movq %rdx, -0x38(%rbp)
movabsq $0x3000000008, %r15     # imm = 0x3000000008
movq %r15, -0x40(%rbp)
pushq $0x8
popq %rax
leaq 0x1a24a(%rip), %rcx     # 0x24610
movl (%rcx), %ecx
xorl %r13d, %r13d
testl %edi, %edi
cmovgl %edi, %r13d
leal 0x1(%r13), %esi
decl %esi
je 0xa40f
cmpl $0x28, %eax
ja 0xa3ee
movq %rdx, %rdi
movl %eax, %edx
addq %rbx, %rdx
addl $0x8, %eax
movl %eax, -0x40(%rbp)
jmp 0xa3f6
leaq 0x8(%rdx), %rdi
movq %rdi, -0x38(%rbp)
cmpl (%rdx), %ecx
movq %rdi, %rdx
jne 0xa3d5
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x13bb2(%rip), %r14     # 0x1dfc8
leaq 0xbe7f(%rip), %rsi      # 0x1629c
movq %r14, %rdi
callq 0x3280
movq %r15, -0x40(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
movq %rbx, -0x30(%rbp)
xorl %r12d, %r12d
leaq 0x14331(%rip), %rbx     # 0x1e770
leaq 0xbe43(%rip), %r15      # 0x16289
cmpl %r12d, %r13d
je 0xa496
testl %r12d, %r12d
je 0xa45b
movq %r14, %rdi
movq %r15, %rsi
callq 0x3280
movl -0x40(%rbp), %ecx
cmpq $0x28, %rcx
ja 0xa473
movq %rcx, %rax
addq -0x30(%rbp), %rax
addl $0x8, %ecx
movl %ecx, -0x40(%rbp)
jmp 0xa47f
movq -0x38(%rbp), %rax
leaq 0x8(%rax), %rcx
movq %rcx, -0x38(%rbp)
movslq (%rax), %rsi
shlq $0x5, %rsi
addq %rbx, %rsi
movq %r14, %rdi
callq 0x3250
incl %r12d
jmp 0xa446
movq 0x13b2b(%rip), %rdi     # 0x1dfc8
leaq 0xbe0b(%rip), %rsi      # 0x162af
callq 0x3280
leaq 0x1a160(%rip), %rcx     # 0x24610
movl (%rcx), %ecx
shlq $0x5, %rcx
addq %rcx, %rbx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x3250
movq %rax, %rdi
callq 0x3130
pushq $0x1
popq %rdi
callq 0x3300
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/symbol.h
// Function: Symset::toVector()
std::vector<int> toVector() {
        std::vector<int> res;
        for (int i = 0; i < 64; i++) {
            if (contains(i))
                res.push_back(i);
        }
        return res;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
andq $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
xorl %eax, %eax
leaq -0x1c(%rbp), %r15
movl %eax, -0x1c(%rbp)
cmpl $0x40, %eax
jge 0xa544
movq (%r14), %rcx
btq %rax, %rcx
jae 0xa540
movq %rbx, %rdi
movq %r15, %rsi
callq 0xa5dc
movl -0x1c(%rbp), %eax
incl %eax
jmp 0xa521
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0xa940
movq %r14, %rdi
callq 0x3430
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/grammar.cpp
// Function: pCondition()
static void pCondition()
{
    std::string left_val, right_val;
    DataType left_dtype, right_dtype;
    pExpression(left_val, left_dtype);
    if ( g_sym == EQL || g_sym == NEQ || g_sym == LSS ||
         g_sym == LEQ || g_sym == GTR || g_sym == GEQ) {
        std::string op = tokens[g_sym];
        readSymbol();
        pExpression(right_val, right_dtype);
        if (left_dtype != right_dtype) {
            error(ERR_COMPARE_TYPE_NOT_MATCH);
        }
        genMidCode(COMPARE, left_val, op, right_val);
    } else {
        // must be DT_INT
        if (left_dtype != DT_INT) {
            error(ERR_EXPECT_INT_TYPE_SINGLE_CONDITION);
        }
        genMidCode(COMPARE, left_val, NONE, NONE);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0xb8, %rsp
leaq -0x48(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
xorl %ecx, %ecx
movb %cl, (%rax)
leaq -0x68(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb %cl, (%rax)
leaq -0x58(%rbp), %rdi
leaq -0xc(%rbp), %rsi
callq 0xd7bf
leaq 0x16fa5(%rip), %rax     # 0x24610
movl (%rax), %eax
leal -0x17(%rax), %ecx
cmpl $0x5, %ecx
ja 0xd6ff
shlq $0x5, %rax
leaq 0x11a9c(%rip), %rsi     # 0x1f120
addq %rax, %rsi
leaq -0x38(%rbp), %rdi
callq 0x3350
callq 0x13808
leaq -0x78(%rbp), %rdi
leaq -0x14(%rbp), %rsi
callq 0xd7bf
movl -0xc(%rbp), %eax
cmpl -0x14(%rbp), %eax
je 0xd6d9
leaq 0x8d79(%rip), %rsi      # 0x1642a
leaq -0xb8(%rbp), %rdi
leaq -0x10(%rbp), %rdx
callq 0x30f0
leaq -0xb8(%rbp), %rdi
callq 0xa247
leaq -0xb8(%rbp), %rdi
callq 0x3498
leaq -0x10(%rbp), %rdi
movl $0x11, (%rdi)
leaq -0x58(%rbp), %rsi
leaq -0x38(%rbp), %rdx
leaq -0x78(%rbp), %rcx
callq 0x100d0
leaq -0x38(%rbp), %rdi
callq 0x3498
jmp 0xd751
cmpl $0x1, -0xc(%rbp)
je 0xd734
leaq 0x8d38(%rip), %rsi      # 0x16444
leaq -0x98(%rbp), %rdi
leaq -0x38(%rbp), %rdx
callq 0x30f0
leaq -0x98(%rbp), %rdi
callq 0xa247
leaq -0x98(%rbp), %rdi
callq 0x3498
leaq -0x38(%rbp), %rdi
movl $0x11, (%rdi)
leaq 0x1281b(%rip), %rcx     # 0x1ff60
leaq -0x58(%rbp), %rsi
movq %rcx, %rdx
callq 0x100d0
leaq -0x78(%rbp), %rdi
callq 0x3498
leaq -0x58(%rbp), %rdi
callq 0x3498
addq $0xb8, %rsp
popq %rbx
popq %rbp
retq
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
callq 0x3498
jmp 0xd797
jmp 0xd794
movq %rax, %rbx
leaq -0x98(%rbp), %rdi
jmp 0xd79b
jmp 0xd7a2
jmp 0xd794
jmp 0xd7a2
jmp 0xd7a2
movq %rax, %rbx
leaq -0x38(%rbp), %rdi
callq 0x3498
jmp 0xd7a5
movq %rax, %rbx
leaq -0x78(%rbp), %rdi
callq 0x3498
leaq -0x58(%rbp), %rdi
callq 0x3498
movq %rbx, %rdi
callq 0x3430
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/grammar.cpp
// Function: pTerm(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, DataType&)
static void pTerm(std::string &res, DataType &res_dtype)
{
    std::string temp_var;
    DataType temp_dtype;
    pFactor(res, res_dtype);
    while (g_sym == STAR || g_sym == SLASH) {
        OpCode op = (g_sym == STAR ? MUL : DIV);
        readSymbol();
        pFactor(temp_var, temp_dtype);
        int t1, t2;
        if (isConstValue(res, t1) && isConstValue(temp_var, t2)) {
            res = std::to_string( op == MUL ? t1 * t2 : t1 / t2 );
            res_dtype = DT_INT;
        }
        else {
            std::string new_res = genTempVar();
            genMidCode(TEMP, "int", new_res, NONE);
            genMidCode(op, res, temp_var, new_res);
            res = new_res;
            res_dtype = DT_INT;
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x50(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
callq 0xdc40
leaq -0x60(%rbp), %r15
leaq -0xa0(%rbp), %r12
leaq -0x80(%rbp), %r13
leaq 0x16b1e(%rip), %rax     # 0x24610
movl (%rax), %eax
leal -0x15(%rax), %ecx
cmpl $0x1, %ecx
ja 0xdbeb
xorl %ecx, %ecx
cmpl $0x15, %eax
setne %cl
addl $0x3, %ecx
movl %ecx, -0x30(%rbp)
callq 0x13808
movq %r15, %rdi
leaq -0x40(%rbp), %rsi
callq 0xdc40
movq %r14, %rdi
leaq -0x3c(%rbp), %rsi
callq 0x10a5d
testb %al, %al
je 0xdb50
movq %r15, %rdi
leaq -0x38(%rbp), %rsi
callq 0x10a5d
testb %al, %al
je 0xdb50
cmpl $0x3, -0x30(%rbp)
movl -0x3c(%rbp), %eax
movl -0x38(%rbp), %esi
jne 0xdbc0
imull %eax, %esi
jmp 0xdbc5
movq %r12, %rdi
callq 0x1065a
movl $0x17, -0x34(%rbp)
movq %r13, %rdi
leaq 0x8aec(%rip), %rsi      # 0x16655
leaq -0x29(%rbp), %rdx
callq 0x30f0
leaq -0x34(%rbp), %rdi
movq %r13, %rsi
movq %r12, %rdx
leaq 0x123dd(%rip), %rcx     # 0x1ff60
callq 0x100d0
movq %r13, %rdi
callq 0x3498
leaq -0x30(%rbp), %rdi
movq %r14, %rsi
movq %r15, %rdx
movq %r12, %rcx
callq 0x100d0
movq %r14, %rdi
movq %r12, %rsi
callq 0x3160
movl $0x1, (%rbx)
movq %r12, %rdi
callq 0x3498
jmp 0xdaeb
cltd
idivl %esi
movl %eax, %esi
movq %r12, %rdi
callq 0xef70
movq %r14, %rdi
movq %r12, %rsi
callq 0x3310
movq %r12, %rdi
callq 0x3498
movl $0x1, (%rbx)
jmp 0xdaeb
leaq -0x60(%rbp), %rdi
callq 0x3498
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xdc2c
jmp 0xdc2c
movq %rax, %rbx
leaq -0x80(%rbp), %rdi
callq 0x3498
jmp 0xdc1c
jmp 0xdc2c
jmp 0xdc19
movq %rax, %rbx
leaq -0xa0(%rbp), %rdi
callq 0x3498
jmp 0xdc2f
jmp 0xdc2c
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x3498
movq %rbx, %rdi
callq 0x3430
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/grammar.cpp
// Function: pSignedInteger()
static void pSignedInteger() 
{
    int negtive = 1;
    if (g_sym == PLUS || g_sym == MINUS) {
        negtive = g_sym == MINUS ? -1 : 1;
        readSymbol();
    }
    test3(Symset({INTVALUE}));
    g_num *= negtive;
    readSymbol();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
leaq 0x160f0(%rip), %rax     # 0x24610
movl (%rax), %eax
leal -0x13(%rax), %ecx
cmpl $0x1, %ecx
ja 0xe541
xorl %ecx, %ecx
cmpl $0x14, %eax
setne %cl
leal -0x1(,%rcx,2), %r13d
callq 0x13808
jmp 0xe545
pushq $0x1
popq %r13
pushq $0x11
popq %rbx
leaq -0x2c(%rbp), %r14
movl %ebx, (%r14)
leaq -0x48(%rbp), %r15
pushq $0x1
popq %rdx
movq %r15, %rdi
movq %r14, %rsi
callq 0xef20
movabsq $0x2600000022, %rax     # imm = 0x2600000022
leaq -0x38(%rbp), %rsi
movq %rax, (%rsi)
leaq -0x40(%rbp), %r12
pushq $0x2
popq %rdx
movq %r12, %rdi
callq 0xef20
movq (%r15), %rdi
movq (%r12), %rsi
callq 0x9f5f
movl %ebx, (%r14)
leaq -0x38(%rbp), %r14
leaq -0x2c(%rbp), %rsi
movq %r14, %rdi
pushq $0x1
popq %rdx
callq 0xef20
movq (%r14), %rax
leaq 0x16063(%rip), %rcx     # 0x24610
movl (%rcx), %ecx
btq %rcx, %rax
jae 0xe5c3
leaq 0x16080(%rip), %rax     # 0x2463c
imull (%rax), %r13d
movl %r13d, (%rax)
callq 0x13808
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/symbol.h
// Function: Symset::Symset(std::initializer_list<int>)
Symset(std::initializer_list<int> il) {
        bitmap = 0LL;
        for (auto itm : il) {
            if (itm < 0 || itm >= 64) {
                std::cout << "values of symset must between 1 and 64"
                    << std::endl;
                exit(1);
            }
            // (long long) is important
            bitmap |= (long long)1 << itm;
        }
    }

// Assembly:
andq $0x0, (%rdi)
shlq $0x2, %rdx
xorl %eax, %eax
xorl %ecx, %ecx
cmpq %rax, %rdx
je 0xef48
movl (%rsi,%rax), %r8d
cmpq $0x40, %r8
jae 0xef49
btsq %r8, %rcx
movq %rcx, (%rdi)
addq $0x4, %rax
jmp 0xef2c
retq
pushq %rbp
movq %rsp, %rbp
movq 0xf074(%rip), %rdi      # 0x1dfc8
leaq 0x7451(%rip), %rsi      # 0x163ac
callq 0x3280
movq %rax, %rdi
callq 0x3130
pushq $0x1
popq %rdi
callq 0x3300
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/midcode.cpp
// Function: flushCachedMidCode()
void flushCachedMidCode()
{
    int t = cachedMidCode.size();
    assert(t > 0); // t must > 0
    std::vector<FourTuple> &cached = cachedMidCode[t - 1];
    for (const auto &item : cached) {
        genMidCode(item.op, item.a, item.b, item.res);
    }
    cachedMidCode.pop_back();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq 0x12067(%rip), %rax     # 0x22650
movq 0x12058(%rip), %rcx     # 0x22648
subq %rcx, %rax
pushq $0x18
popq %rsi
cqto
idivq %rsi
testl %eax, %eax
jle 0x1063d
decl %eax
imulq $0x18, %rax, %rax
movq (%rcx,%rax), %rbx
movq 0x8(%rcx,%rax), %r14
cmpq %r14, %rbx
je 0x1062d
leaq 0x8(%rbx), %rsi
leaq 0x28(%rbx), %rdx
leaq 0x48(%rbx), %rcx
movq %rbx, %rdi
callq 0x100d0
addq $0x68, %rbx
jmp 0x1060e
leaq 0x12014(%rip), %rdi     # 0x22648
popq %rbx
popq %r14
popq %rbp
jmp 0x10b6e
leaq 0x6245(%rip), %rdi      # 0x16889
leaq 0x6556(%rip), %rsi      # 0x16ba1
leaq 0x657a(%rip), %rcx      # 0x16bcc
pushq $0x48
popq %rdx
callq 0x31c0
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/midcode.cpp
// Function: isConstValue(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int&)
bool isConstValue(const std::string &t, int &val)
{
    if (t[0] == '\'') {
        assert(t[2] == '\'');
        val = t[1];
        return true;
    } else if (std::isdigit(t[0]) || t[0] == '-') {
        val = std::stoi(t);
        return true;
    }
    return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq (%rdi), %rax
movsbl (%rax), %ecx
cmpl $0x27, %ecx
jne 0x10a7d
cmpb $0x27, 0x2(%rax)
jne 0x10aab
movsbl 0x1(%rax), %eax
jmp 0x10a9c
movl %ecx, %eax
addl $-0x30, %eax
cmpl $0xa, %eax
setae %al
cmpb $0x2d, %cl
setne %cl
testb %al, %cl
jne 0x10aa2
pushq $0xa
popq %rdx
xorl %esi, %esi
callq 0x10bde
movl %eax, (%rbx)
movb $0x1, %al
jmp 0x10aa4
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x6151(%rip), %rdi      # 0x16c03
leaq 0x60e8(%rip), %rsi      # 0x16ba1
leaq 0x6150(%rip), %rcx      # 0x16c10
movl $0xb3, %edx
callq 0x31c0
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/mips.cpp
// Function: loadToReg(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
static void loadToReg(const std::string &reg, const std::string &t)
{
    TabEntry entry;
    int val;

    if (isConstValue(t, val)) {
        MIPS(T << "li" << HT << reg << ", " << val);
        return;
    }
    bool flag = tabFind(t, entry);
    assert(flag == true);
    if (entry.scope == GLOBAL) {
        MIPS(T << "lw" << HT << reg << ", " << t);
    } else {
        MIPS(T << "lw" << HT << reg << ", " << entry.addr << "($sp)");
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x1c(%rbp), %rsi
movq %rbx, %rdi
callq 0x10a5d
testb %al, %al
je 0x133d8
leaq 0x1020a(%rip), %rdi     # 0x235a0
leaq 0x3a20(%rip), %rsi      # 0x16dbd
callq 0x3280
leaq 0x39fb(%rip), %rsi      # 0x16da4
movq %rax, %rdi
callq 0x3280
movq %rax, %rdi
movq %r14, %rsi
callq 0x3250
leaq 0x3c5b(%rip), %rsi      # 0x1701e
movq %rax, %rdi
callq 0x3280
movl -0x1c(%rbp), %esi
movq %rax, %rdi
callq 0x3420
jmp 0x13454
leaq -0x30(%rbp), %rsi
movq %rbx, %rdi
callq 0x140e9
testb %al, %al
je 0x13467
movl -0x30(%rbp), %r15d
leaq 0x101ad(%rip), %rdi     # 0x235a0
leaq 0x3968(%rip), %rsi      # 0x16d62
callq 0x3280
leaq 0x399e(%rip), %rsi      # 0x16da4
movq %rax, %rdi
callq 0x3280
movq %rax, %rdi
movq %r14, %rsi
callq 0x3250
leaq 0x3bfe(%rip), %rsi      # 0x1701e
movq %rax, %rdi
callq 0x3280
testl %r15d, %r15d
je 0x13449
movl -0x20(%rbp), %esi
movq %rax, %rdi
callq 0x3420
leaq 0x39b6(%rip), %rsi      # 0x16df5
movq %rax, %rdi
callq 0x3280
jmp 0x13454
movq %rax, %rdi
movq %rbx, %rsi
callq 0x3250
movq %rax, %rdi
callq 0x1145d
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x3a34(%rip), %rdi      # 0x16ea2
leaq 0x38cb(%rip), %rsi      # 0x16d40
leaq 0x3a33(%rip), %rcx      # 0x16eaf
movl $0x1d4, %edx            # imm = 0x1D4
callq 0x31c0
// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/mips.cpp
// Function: getVariableAddr(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
static std::string getVariableAddr(const std::string &t)
{
    TabEntry entry;
    bool flag = tabFind(t, entry);
    if (!flag) {
        std::cout << "Did you forget the TEMP mid-code for temp var?"
                  << std::endl;
    }
    assert(flag == true);
    if (entry.scope == GLOBAL) {
        return t;
    } else {
        return std::to_string(entry.addr) + "($sp)";
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq -0x24(%rbp), %rsi
movq %r14, %rdi
callq 0x140e9
testb %al, %al
je 0x134f0
cmpl $0x0, -0x24(%rbp)
je 0x134d9
movl -0x14(%rbp), %esi
leaq -0x48(%rbp), %r14
movq %r14, %rdi
callq 0xef70
leaq 0x3932(%rip), %rdx      # 0x16df5
movq %rbx, %rdi
movq %r14, %rsi
callq 0x137df
leaq -0x48(%rbp), %rdi
callq 0x3498
jmp 0x134e4
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3350
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0xaad1(%rip), %rdi      # 0x1dfc8
leaq 0x39ea(%rip), %rsi      # 0x16ee8
callq 0x3280
movq %rax, %rdi
callq 0x3130
leaq 0x3990(%rip), %rdi      # 0x16ea2
leaq 0x3827(%rip), %rsi      # 0x16d40
leaq 0x39f7(%rip), %rcx      # 0x16f17
movl $0x1e9, %edx            # imm = 0x1E9
callq 0x31c0
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x3498
movq %rbx, %rdi
callq 0x3430