LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::~Container()
Container::~Container(void)
{
	for (_map_t::iterator it = _map.begin(); it != _map.end(); it++)
		delete_watch(it->first);
	while (!_v.empty()) {
		Window *p = _v.back();
		_v.pop_back();
		delete p;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq 0x7c09(%rip), %r14      # 0xc498
leaq 0x7bf2(%rip), %r15      # 0xc488
cmpq %r15, %r14
je 0x48dc
movl 0x20(%r14), %edi
callq 0x707a
movq %r14, %rdi
callq 0x3270
movq %rax, %r14
cmpq %r15, %rax
jne 0x489b
jmp 0x48dc
movq -0x8(%rax), %r14
addq $-0x8, %rax
movq %rax, 0x8(%rbx)
testq %r14, %r14
je 0x48cf
movq %r14, %rdi
callq 0x571a
movl $0x80, %esi
movq %r14, %rdi
callq 0x3380
movq (%rbx), %rdi
movq 0x8(%rbx), %rax
cmpq %rax, %rdi
jne 0x48b6
testq %rdi, %rdi
je 0x48fe
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x3380
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rdi
callq 0x5071
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::_goto_next_window()
void Container::_goto_next_window(void)
{
	std::vector<Window*>::iterator it = _it;
	(*_it)->focus(false);
	do {
		_it++;
		if (_it == _v.end())
			_it = _v.begin();
	} while ((*_it)->is_dead() && _it != it);
	(*_it)->focus(true);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %r14
movq (%r14), %rdi
xorl %esi, %esi
callq 0x5980
movq 0x18(%rbx), %rcx
addq $0x8, %rcx
movq %rcx, 0x18(%rbx)
cmpq 0x8(%rbx), %rcx
jne 0x493a
movq (%rbx), %rcx
movq %rcx, 0x18(%rbx)
movq (%rcx), %rdi
callq 0x5776
movq 0x18(%rbx), %rcx
testb %al, %al
je 0x494f
cmpq %r14, %rcx
jne 0x4925
movq (%rcx), %rdi
movl $0x1, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x5980
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::_goto_prev_window()
void Container::_goto_prev_window(void)
{
	std::vector<Window*>::iterator it = _it;
	(*_it)->focus(false);
	do {
		if (_it == _v.begin())
			_it = _v.end();
		_it--;
	} while ((*_it)->is_dead() && _it != it);
	(*_it)->focus(true);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %r14
movq (%r14), %rdi
xorl %esi, %esi
callq 0x5980
movq 0x18(%rbx), %rcx
cmpq (%rbx), %rcx
jne 0x4986
movq 0x8(%rbx), %rcx
leaq -0x8(%rcx), %rax
movq %rax, 0x18(%rbx)
movq -0x8(%rcx), %rdi
callq 0x5776
movq 0x18(%rbx), %rcx
testb %al, %al
je 0x49a4
cmpq %r14, %rcx
jne 0x497d
movq (%rcx), %rdi
movl $0x1, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x5980
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::_build_window_xy()
void Container::_build_window_xy(void)
{
	int seq = 0;
	int xx = get_terminal_cols();
	int yy = get_terminal_lines();
	int x = static_cast<int>(layout.size());
	int xq = xx / x;
	int xr = xx % x;

	for (int i = 0; i < x; i++) {
		int xpos = xq * i;
		int xlen = xq;
		if (i == x - 1)
			xlen += xr;
		int y = layout[i];
		if (y == -1)
			y = 1; // ignore invalid
		int yq = yy / y;
		int yr = yy % y;

		for (int j = 0; j < y; j++) {
			int ypos = yq * j;
			int ylen = yq;
			if (j == y - 1)
				ylen += yr;
			_alloc_window(seq++, ylen, xlen, ypos, xpos);
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, 0x18(%rsp)
callq 0x6c99
movl %eax, %ebp
callq 0x6c6d
leaq 0x79ea(%rip), %rcx      # 0xc3c8
movq 0x8(%rcx), %rsi
subq (%rcx), %rsi
movl %eax, 0x10(%rsp)
shrq $0x2, %rsi
movl %ebp, %eax
cltd
idivl %esi
movl %edx, 0xc(%rsp)
movl %eax, 0x8(%rsp)
testl %esi, %esi
jle 0x4abd
movq %rsi, %rax
leal -0x1(%rsi), %ecx
movq %rcx, 0x20(%rsp)
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %rax, 0x28(%rsp)
xorl %ecx, %ecx
xorl %esi, %esi
movq 0x18(%rsp), %r12
cmpq 0x20(%rsp), %rcx
movl $0x0, %eax
cmovel 0xc(%rsp), %eax
movl %eax, 0x4(%rsp)
leaq 0x798e(%rip), %rax      # 0xc3c8
movq (%rax), %rax
movl (%rax,%rcx,4), %ebx
cmpl $-0x1, %ebx
movl $0x1, %eax
cmovel %eax, %ebx
movl 0x10(%rsp), %eax
cltd
idivl %ebx
testl %ebx, %ebx
movq %rcx, 0x30(%rsp)
jle 0x4aa4
movl %edx, %r14d
movl %eax, %ebp
movl 0x8(%rsp), %eax
addl %eax, 0x4(%rsp)
imull %eax, %ecx
movl %ecx, 0x14(%rsp)
xorl %r15d, %r15d
cmpl $0x1, %ebx
movl $0x0, %edx
cmovel %r14d, %edx
addl %ebp, %edx
leal 0x1(%rsi), %r13d
movq %r12, %rdi
movl 0x4(%rsp), %ecx
movl %r15d, %r8d
movl 0x14(%rsp), %r9d
callq 0x4be0
addl %ebp, %r15d
movl %r13d, %esi
decl %ebx
jne 0x4a72
jmp 0x4aa7
movl %esi, %r13d
movq 0x30(%rsp), %rcx
incq %rcx
movl %r13d, %esi
cmpq 0x28(%rsp), %rcx
jne 0x4a20
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::_build_window_yx()
void Container::_build_window_yx(void)
{
	int seq = 0;
	int yy = get_terminal_lines();
	int xx = get_terminal_cols();
	int y = static_cast<int>(layout.size());
	int yq = yy / y;
	int yr = yy % y;

	for (int i = 0; i < y; i++) {
		int ypos = yq * i;
		int ylen = yq;
		if (i == y - 1)
			ylen += yr;
		int x = layout[i];
		if (x == -1)
			x = 1; // ignore invalid
		int xq = xx / x;
		int xr = xx % x;

		for (int j = 0; j < x; j++) {
			int xpos = xq * j;
			int xlen = xq;
			if (j == x - 1)
				xlen += xr;
			_alloc_window(seq++, ylen, xlen, ypos, xpos);
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, 0x18(%rsp)
callq 0x6c6d
movl %eax, %ebp
callq 0x6c99
leaq 0x78d6(%rip), %rcx      # 0xc3c8
movq 0x8(%rcx), %rsi
subq (%rcx), %rsi
movl %eax, 0x10(%rsp)
shrq $0x2, %rsi
movl %ebp, %eax
cltd
idivl %esi
movl %edx, 0xc(%rsp)
movl %eax, 0x8(%rsp)
testl %esi, %esi
jle 0x4bd1
movq %rsi, %rax
leal -0x1(%rsi), %ecx
movq %rcx, 0x20(%rsp)
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %rax, 0x28(%rsp)
xorl %ecx, %ecx
xorl %esi, %esi
movq 0x18(%rsp), %r12
cmpq 0x20(%rsp), %rcx
movl $0x0, %eax
cmovel 0xc(%rsp), %eax
movl %eax, 0x4(%rsp)
leaq 0x787a(%rip), %rax      # 0xc3c8
movq (%rax), %rax
movl (%rax,%rcx,4), %ebx
cmpl $-0x1, %ebx
movl $0x1, %eax
cmovel %eax, %ebx
movl 0x10(%rsp), %eax
cltd
idivl %ebx
testl %ebx, %ebx
movq %rcx, 0x30(%rsp)
jle 0x4bb8
movl %edx, %r14d
movl %eax, %ebp
movl 0x8(%rsp), %eax
addl %eax, 0x4(%rsp)
imull %eax, %ecx
movl %ecx, 0x14(%rsp)
xorl %r15d, %r15d
cmpl $0x1, %ebx
movl $0x0, %ecx
cmovel %r14d, %ecx
addl %ebp, %ecx
leal 0x1(%rsi), %r13d
movq %r12, %rdi
movl 0x4(%rsp), %edx
movl 0x14(%rsp), %r8d
movl %r15d, %r9d
callq 0x4be0
addl %ebp, %r15d
movl %r13d, %esi
decl %ebx
jne 0x4b86
jmp 0x4bbb
movl %esi, %r13d
movq 0x30(%rsp), %rcx
incq %rcx
movl %r13d, %esi
cmpq 0x28(%rsp), %rcx
jne 0x4b34
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::_alloc_window(int, int, int, int, int)
void Container::_alloc_window(int seq, int ylen, int xlen, int ypos, int xpos)
{
	try {
		Window *p = _v.at(seq);
		p->resize(ylen, xlen, ypos, xpos);
		p->signal();
	} catch (const std::out_of_range &e) {
		Window *p = new Window(ylen, xlen, ypos, xpos);
		_v.push_back(p);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %r9d, %ebp
movl %r8d, %r14d
movl %ecx, %r15d
movl %edx, %r12d
movq %rdi, %rbx
movslq %esi, %rsi
movq (%rdi), %rax
movq 0x8(%rdi), %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rsi, %rdx
jbe 0x4c42
movq (%rax,%rsi,8), %r13
movq %r13, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x5786
movq %r13, %rdi
callq 0x5c20
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x395a(%rip), %rdi      # 0x85a3
xorl %eax, %eax
callq 0x3570
movq %rax, 0x8(%rsp)
cmpl $0x1, %edx
jne 0x4cba
movq 0x8(%rsp), %rdi
callq 0x3160
movl $0x80, %edi
callq 0x3360
movq %rax, %r13
movq %rax, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x5624
leaq 0x10(%rsp), %rsi
movq %r13, (%rsi)
movq %rbx, %rdi
callq 0x507c
callq 0x3600
jmp 0x4c33
movq %rax, 0x8(%rsp)
movl $0x80, %esi
movq %r13, %rdi
callq 0x3380
jmp 0x4cb5
movq %rax, 0x8(%rsp)
callq 0x3600
movq 0x8(%rsp), %rdi
callq 0x3680
movq %rax, %rdi
callq 0x5071
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::parse_event(int)
void Container::parse_event(int x)
{
	Window *p = *_it;
	switch (x) {
	case KBD_ERR:
		break;
	case KBD_RESIZE:
	case KBD_CTRL('l'):
		clear_terminal();
		_build_window();
		break;
	case 'h':
	case KBD_LEFT:
		_goto_prev_window();
		break;
	case 'l':
	case KBD_RIGHT:
		_goto_next_window();
		break;
	case '0':
		p->goto_head();
		goto _signal;
	case '$':
		p->goto_tail();
		goto _signal;
	case 'k':
	case KBD_UP:
		p->goto_current(-1);
		goto _signal;
	case 'j':
	case KBD_DOWN:
		p->goto_current(1);
		goto _signal;
	case KBD_CTRL('B'):
		p->goto_current(-get_terminal_lines());
		goto _signal;
	case KBD_CTRL('U'):
		p->goto_current(-get_terminal_lines() / 2);
		goto _signal;
	case KBD_CTRL('F'):
		p->goto_current(get_terminal_lines());
		goto _signal;
	case KBD_CTRL('D'):
		p->goto_current(get_terminal_lines() / 2);
		goto _signal;
	default:
		goto _signal;
	}
	return;
_signal:
	p->signal();
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x18(%rdi), %rax
movq (%rax), %rbx
cmpl $0x67, %esi
jle 0x4d06
leal -0x68(%rsi), %eax
cmpl $0x4, %eax
jbe 0x4d5a
leal -0x102(%rsi), %eax
cmpl $0x3, %eax
ja 0x4db8
leaq 0x386b(%rip), %rcx      # 0x8568
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
cmpl $0xb, %esi
jg 0x4d2e
incl %esi
cmpl $0x7, %esi
ja 0x4e0b
leaq 0x3817(%rip), %rax      # 0x8534
movslq (%rax,%rsi,4), %rcx
addq %rax, %rcx
jmpq *%rcx
addq $0x8, %rsp
popq %rbx
popq %r14
retq
cmpl $0x23, %esi
jg 0x4d79
cmpl $0xc, %esi
je 0x4dc0
cmpl $0x15, %esi
jne 0x4e0b
callq 0x6c6d
movl %eax, %esi
shrl $0x1f, %esi
addl %eax, %esi
sarl %esi
negl %esi
jmp 0x4df5
leaq 0x37f3(%rip), %rcx      # 0x8554
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x4964
cmpl $0x24, %esi
je 0x4e1a
cmpl $0x30, %esi
jne 0x4e0b
movq %rbx, %rdi
callq 0x59b6
jmp 0x4e0b
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x490c
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
jmp 0x4e06
movq %rbx, %rdi
movl $0x1, %esi
jmp 0x4e06
cmpl $0x19a, %esi            # imm = 0x19A
jne 0x4e0b
callq 0x6c07
leaq 0x7626(%rip), %rax      # 0xc3f2
cmpb $0x0, (%rax)
je 0x4e24
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x4acc
callq 0x6c6d
jmp 0x4e01
callq 0x6c6d
movl %eax, %esi
shrl $0x1f, %esi
addl %eax, %esi
sarl %esi
movq %rbx, %rdi
jmp 0x4e06
callq 0x6c6d
negl %eax
movq %rbx, %rdi
movl %eax, %esi
callq 0x59ee
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x5c20
movq %rbx, %rdi
callq 0x59d0
jmp 0x4e0b
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x49b8
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::thread_create()
int Container::thread_create(void)
{
	int ret = _thread.create(watch_thread_handler, 0);
	if (ret) {
		log("create thread failed %d", ret);
		return ret;
	}

	for (size_t i = 0; i < _v.size(); i++) {
		ret = _v[i]->create();
		if (ret) {
			log("window=%p create thread failed %d",
				static_cast<void*>(_v[i]), ret);
			return ret;
		}
	}
	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x766d(%rip), %rdi      # 0xc4b0
leaq 0x50(%rip), %rdx        # 0x4e9a
xorl %r14d, %r14d
xorl %esi, %esi
xorl %ecx, %ecx
callq 0x36b0
testl %eax, %eax
je 0x4e66
movl %eax, %r14d
movl %r14d, %eax
popq %rbx
popq %r14
popq %r15
retq
movq (%rbx), %rax
cmpq %rax, 0x8(%rbx)
je 0x4e5d
xorl %r15d, %r15d
movq (%rax,%r15,8), %rdi
callq 0x5c6a
testl %eax, %eax
jne 0x4e5a
incq %r15
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
cmpq %rcx, %r15
jb 0x4e72
xorl %r14d, %r14d
jmp 0x4e5d
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: watch_thread_handler(void*)
static void *watch_thread_handler(void *arg)
{
	log("thread=%lu", get_thread_id());
	while (!interrupted) {
		watch_res r;
		if (read_watch(r) > 0) {
			for (watch_res::iterator it = r.begin(); it != r.end();
				it++) {
				Window *p = _map[it->first];
				switch (it->second) {
				case WATCH_MODIFY:
					p->update_buffer();
					break;
				}
			}
			flash_terminal();
		}
		_mutex.timedwait(1, 0);
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
leaq 0x7515(%rip), %r13      # 0xc3c4
cmpl $0x0, (%r13)
jne 0x4f58
leaq 0x10(%rsp), %rbp
xorl %r15d, %r15d
leaq 0x8(%rsp), %rbx
leaq 0x75b2(%rip), %r14      # 0xc480
movl $0x0, 0x10(%rsp)
movq %r15, 0x18(%rsp)
movq %rbp, 0x20(%rsp)
movq %rbp, 0x28(%rsp)
movq %r15, 0x30(%rsp)
movq %rbx, %rdi
callq 0x70b4
testl %eax, %eax
jle 0x4f32
movq 0x20(%rsp), %r12
cmpq %rbp, %r12
je 0x4f2d
leaq 0x20(%r12), %rsi
movq %r14, %rdi
callq 0x50ea
cmpl $0x1, 0x24(%r12)
jne 0x4f1d
movq (%rax), %rdi
callq 0x5976
movq %r12, %rdi
callq 0x3270
movq %rax, %r12
cmpq %rbp, %rax
jne 0x4f00
callq 0x6cc5
movl $0x1, %esi
leaq 0x74ea(%rip), %rdi      # 0xc428
xorl %edx, %edx
callq 0x6966
movq %rbx, %rdi
callq 0x5354
cmpl $0x0, (%r13)
je 0x4ece
xorl %eax, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4f6b
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x5354
movq %rbx, %rdi
callq 0x3680
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/container.cc
// Function: Container::thread_join()
void Container::thread_join(void)
{
	int ret;
	for (size_t i = 0; i < _v.size(); i++)
		_v[i]->signal();
	for (size_t i = 0; i < _v.size(); i++) {
		ret = _v[i]->join();
		if (ret)
			log("window=%p join thread failed %d",
				static_cast<void*>(_v[i]), ret);
	}

	_mutex.signal();
	ret = _thread.join();
	if (ret)
		log("join thread failed %d", ret);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
cmpq %rax, %rcx
je 0x4fbd
xorl %r14d, %r14d
movq (%rax,%r14,8), %rdi
callq 0x5c20
incq %r14
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
movq %rcx, %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rdx, %r14
jb 0x4f9b
cmpq %rax, %rcx
je 0x4ff0
xorl %r15d, %r15d
leaq 0x8(%rsp), %r14
movq (%rax,%r15,8), %rax
movq 0x58(%rax), %rdi
movq %r14, %rsi
callq 0x3320
incq %r15
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
cmpq %rcx, %r15
jb 0x4fca
leaq 0x7459(%rip), %rdi      # 0xc450
callq 0x3030
movq 0x74ad(%rip), %rdi      # 0xc4b0
leaq 0x8(%rsp), %rsi
callq 0x3320
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/window.cc
// Function: Window::Window(int, int, int, int)
Window::Window(int ylen, int xlen, int ypos, int xpos):
	_frame(0),
	_panel(0),
	_buffer(0),
	_offset(0)
{
	_frame = new Frame(ylen, xlen, ypos, xpos);
	_panel = new Panel(ylen - 2, xlen - 2, ypos + 1, xpos + 1);
	_frame->refresh();
	_panel->refresh();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %ebp
movl %ecx, %r15d
movl %edx, %r12d
movl %esi, %r13d
movq %rdi, %rbx
xorl %esi, %esi
callq 0x3550
leaq 0x28(%rbx), %rdi
movq %rdi, (%rsp)
xorl %esi, %esi
callq 0x3470
xorps %xmm0, %xmm0
movups %xmm0, 0x60(%rbx)
movups %xmm0, 0x6c(%rbx)
movl $0x48, %edi
callq 0x3360
movq %rax, %r14
movq %rax, %rdi
movl %r13d, %esi
movl %r12d, %edx
movl %r15d, %ecx
movl %ebp, %r8d
callq 0x5f82
leaq 0x60(%rbx), %rax
movq %r14, (%rax)
movl $0x20, %edi
callq 0x3360
movq %rax, %r14
addl $-0x2, %r13d
addl $-0x2, %r12d
incl %r15d
incl %ebp
movq %rax, %rdi
movl %r13d, %esi
movl %r12d, %edx
movl %r15d, %ecx
movl %ebp, %r8d
callq 0x5ec4
movq %r14, 0x68(%rbx)
movq 0x60(%rbx), %rax
movq 0x8(%rax), %rdi
callq 0x6e46
movq 0x68(%rbx), %rax
movq 0x8(%rax), %rdi
callq 0x6e46
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
movl $0x20, %esi
jmp 0x56f4
movq %rax, %r15
movl $0x48, %esi
movq %r14, %rdi
callq 0x3380
jmp 0x5701
movq %rax, %r15
movq (%rsp), %rdi
callq 0x36e0
movq %rbx, %rdi
callq 0x3450
movq %r15, %rdi
callq 0x3680
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/window.cc
// Function: Window::~Window()
Window::~Window(void)
{
	delete _buffer;
	delete _frame;
	delete _panel;
	log("window=%p", static_cast<void*>(this));
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x70(%rdi), %r14
testq %r14, %r14
je 0x5732
movq %r14, %rdi
callq 0x5d6e
movl $0x2a8, %esi            # imm = 0x2A8
movq %r14, %rdi
callq 0x3380
movq 0x60(%rbx), %rdi
testq %rdi, %rdi
je 0x574e
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x68(%rbx), %rdi
testq %rdi, %rdi
je 0x575d
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x28(%rbx), %rdi
callq 0x36e0
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x3450
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/window.cc
// Function: Window::attach_buffer(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void Window::attach_buffer(std::string f)
{
	_mutex.lock();
	if (_buffer) {
		_mutex.unlock();
		return;
	}
	_frame->set_title(f);
	_panel->set_title(f);
	_mutex.unlock();
	_buffer = new Buffer(f);
	log("window=%p path=%s", static_cast<void*>(this),
		_buffer->get_path().c_str());
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x3530
cmpq $0x0, 0x70(%rbx)
je 0x5826
movq %rbx, %rdi
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x32c0
movq 0x60(%rbx), %r15
leaq 0x50(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
leaq 0x40(%rsp), %r12
movq %r12, %rdi
callq 0x5e2e
movq (%r15), %rax
movq %r15, %rdi
movq %r12, %rsi
callq *0x10(%rax)
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x586d
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x3380
movq 0x68(%rbx), %r15
leaq 0x30(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
leaq 0x20(%rsp), %r12
movq %r12, %rdi
callq 0x5e2e
movq (%r15), %rax
movq %r15, %rdi
movq %r12, %rsi
callq *0x10(%rax)
movq 0x20(%rsp), %rdi
cmpq %r13, %rdi
je 0x58b4
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x3380
movq %rbx, %rdi
callq 0x32c0
movl $0x2a8, %edi            # imm = 0x2A8
callq 0x3360
movq %rax, %r15
leaq 0x10(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
movq %rsp, %rdi
callq 0x5e2e
movq %rsp, %rsi
movq %r15, %rdi
callq 0x610c
movq %r15, 0x70(%rbx)
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x590a
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x3380
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x5936
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x3380
jmp 0x5936
movq %rax, %rbx
movl $0x2a8, %esi            # imm = 0x2A8
movq %r15, %rdi
jmp 0x5969
movq %rax, %rbx
movq 0x20(%rsp), %rdi
cmpq %r13, %rdi
je 0x596e
movq 0x30(%rsp), %rsi
jmp 0x5966
movq %rax, %rbx
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x596e
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x3380
movq %rbx, %rdi
callq 0x3680
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/window.cc
// Function: Window::goto_current(int)
void Window::goto_current(int d)
{
	_mutex.lock();
	int x = _offset + d;
	if (x < 0)
		x = 0;
	if (x > _buffer->get_max_line())
		x = _buffer->get_max_line();
	_offset = x;
	_mutex.unlock();
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
callq 0x3530
addl 0x78(%rbx), %r14d
xorl %ebp, %ebp
testl %r14d, %r14d
cmovgl %r14d, %ebp
movq 0x70(%rbx), %rdi
callq 0x6288
cmpl %eax, %ebp
jle 0x5a22
movq 0x70(%rbx), %rdi
callq 0x6288
movl %eax, %ebp
movl %ebp, 0x78(%rbx)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x32c0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/window.cc
// Function: Window::repaint()
void Window::repaint(void)
{
	if (is_dead())
		return;

	int ret, pos, y = 0;
	bool standout;
	std::string s;

	_mutex.lock();
	int offset = _offset;
	int ylen = _panel->get_ylen();
	int xlen = _panel->get_xlen();
	_mutex.unlock();

	_buffer->block_till_ready();
	_panel->erase();
	while ((ret = _buffer->readline(pos, s, standout)) != -1) {
		_mutex.lock();
		if (y >= ylen || offset != _offset ||
			ylen != _panel->get_ylen() ||
			xlen != _panel->get_xlen()) {
			_mutex.unlock();
			break;
		}
		_mutex.unlock();
		if (pos < offset)
			continue;
		if (!foldline && (static_cast<int>(s.size()) > xlen))
			s = s.substr(0, xlen);
		_panel->print(y, 0, standout, s);
		if (!foldline) {
			y++;
		} else {
			size_t siz = s.size();
			y += (siz / xlen);
			if (siz % xlen)
				y++;
		}
	}
	_panel->refresh();
	_buffer->clear();
	_buffer->signal_blocked();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
movq 0x70(%rdi), %rdi
testq %rdi, %rdi
je 0x5be3
callq 0x6310
testb %al, %al
jne 0x5be3
leaq 0x18(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq %rbx, %rdi
callq 0x3530
movl 0x78(%rbx), %r12d
movq 0x68(%rbx), %rax
movl 0x10(%rax), %ebp
movslq 0x14(%rax), %r14
movq %rbx, %rdi
callq 0x32c0
movq 0x70(%rbx), %rdi
callq 0x62aa
movq 0x68(%rbx), %rax
movq 0x8(%rax), %rdi
callq 0x6e73
xorl %r15d, %r15d
leaq 0x8(%rsp), %r13
movq 0x70(%rbx), %rdi
leaq 0x4(%rsp), %rsi
movq %r13, %rdx
leaq 0x3(%rsp), %rcx
callq 0x633e
cmpl $-0x1, %eax
je 0x5ba8
movq %rbx, %rdi
callq 0x3530
cmpl %ebp, %r15d
jge 0x5ba0
cmpl 0x78(%rbx), %r12d
jne 0x5ba0
movq 0x68(%rbx), %rax
cmpl 0x10(%rax), %ebp
jne 0x5ba0
cmpl 0x14(%rax), %r14d
jne 0x5ba0
movq %rbx, %rdi
callq 0x32c0
cmpl %r12d, 0x4(%rsp)
jl 0x5aae
leaq 0x68dc(%rip), %rax      # 0xc3f1
cmpb $0x0, (%rax)
jne 0x5b5c
cmpl 0x10(%rsp), %r14d
jge 0x5b5c
leaq 0x28(%rsp), %rdi
movq %r13, %rsi
xorl %edx, %edx
movq %r14, %rcx
callq 0x33a0
movq %r13, %rdi
leaq 0x28(%rsp), %rsi
callq 0x34a0
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0x5b5c
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x3380
movq 0x68(%rbx), %rdi
movzbl 0x3(%rsp), %ecx
movl %r15d, %esi
xorl %edx, %edx
movq %r13, %r8
callq 0x5f74
leaq 0x6878(%rip), %rax      # 0xc3f1
cmpb $0x0, (%rax)
je 0x5b98
movq 0x10(%rsp), %rax
xorl %edx, %edx
divq %r14
addl %eax, %r15d
cmpq $0x1, %rdx
sbbl $-0x1, %r15d
jmp 0x5aae
incl %r15d
jmp 0x5aae
movq %rbx, %rdi
callq 0x32c0
movq 0x68(%rbx), %rax
movq 0x8(%rax), %rdi
callq 0x6e46
movq 0x70(%rbx), %rdi
callq 0x6584
movq 0x70(%rbx), %rdi
callq 0x62ee
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x5be3
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3380
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5bf8
jmp 0x5bf8
jmp 0x5bf8
movq %rax, %rbx
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x5c17
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3380
movq %rbx, %rdi
callq 0x3680
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/window.cc
// Function: thread_handler(void*)
static void *thread_handler(void *arg)
{
	Window *p = reinterpret_cast<Window*>(arg);
	long t = 0;
	if (usedelay) {
		long va = reinterpret_cast<long>(p);
		if (sinterval)
			t = va % 1000;
		else
			t = va % (ninterval / 1000 / 1000);
	}
	log("window=%p thread=%lu delay=%ld", static_cast<void*>(p),
		get_thread_id(), t);
	if (t) {
		p->repaint();
		p->timedwait(0, t * 1000 * 1000);
	}
	while (!interrupted) {
		p->repaint();
		p->timedwait(sinterval, ninterval);
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x675f(%rip), %rax      # 0xc3f3
cmpb $0x1, (%rax)
jne 0x5d0c
leaq 0x6740(%rip), %rax      # 0xc3e0
movl $0x3e8, %ecx            # imm = 0x3E8
cmpq $0x0, (%rax)
jne 0x5cd0
leaq 0x6736(%rip), %rcx      # 0xc3e8
movabsq $0x431bde82d7b634db, %rax # imm = 0x431BDE82D7B634DB
imulq (%rcx)
movq %rdx, %rcx
movq %rdx, %rax
shrq $0x3f, %rax
sarq $0x12, %rcx
addq %rax, %rcx
movq %rbx, %rax
cqto
idivq %rcx
testq %rdx, %rdx
je 0x5d0c
movq %rdx, %r14
movq %rbx, %rdi
callq 0x5a32
imulq $0xf4240, %r14, %r14    # imm = 0xF4240
movq %rbx, %rdi
callq 0x3530
movq %rbx, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x6966
movq %rbx, %rdi
callq 0x32c0
leaq 0x66b1(%rip), %r12      # 0xc3c4
cmpl $0x0, (%r12)
jne 0x5d5d
leaq 0x66bf(%rip), %r13      # 0xc3e0
leaq 0x66c0(%rip), %rbp      # 0xc3e8
movq %rbx, %rdi
callq 0x5a32
movq (%r13), %r14
movq (%rbp), %r15
movq %rbx, %rdi
callq 0x3530
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x6966
movq %rbx, %rdi
callq 0x32c0
cmpl $0x0, (%r12)
je 0x5d28
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/panel.cc
// Function: Panel::Panel(int, int, int, int)
Panel::Panel(int ylen, int xlen, int ypos, int xpos):
	_scr(0),
	_ylen(ylen),
	_xlen(xlen),
	_ypos(ypos),
	_xpos(xpos)
{
	_scr = alloc_screen(_ylen, _xlen, _ypos, _xpos);
	if (!_scr)
		throw std::bad_alloc();
	bkgd_screen(_scr);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
leaq 0x5de1(%rip), %rax      # 0xbcb0
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movl %esi, 0x10(%rdi)
movl %edx, 0x14(%rdi)
movl %ecx, 0x18(%rdi)
movl %r8d, 0x1c(%rdi)
movl %esi, %edi
movl %edx, %esi
movl %ecx, %edx
movl %r8d, %ecx
callq 0x6cca
movq %rax, 0x8(%rbx)
testq %rax, %rax
je 0x5f07
movq %rax, %rdi
popq %rbx
jmp 0x6f83
movl $0x8, %edi
callq 0x31b0
movq 0x6098(%rip), %rcx      # 0xbfb0
addq $0x10, %rcx
movq %rcx, (%rax)
movq 0x609a(%rip), %rsi      # 0xbfc0
movq 0x6073(%rip), %rdx      # 0xbfa0
movq %rax, %rdi
callq 0x3640
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/panel.cc
// Function: Panel::_resize(int, int, int, int)
void Panel::_resize(int ylen, int xlen, int ypos, int xpos)
{
	_ylen = ylen;
	_xlen = xlen;
	_ypos = ypos;
	_xpos = xpos;
	resize_screen(_scr, _ylen, _xlen);
	move_screen(_scr, _ypos, _xpos);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl %esi, 0x10(%rdi)
movl %edx, 0x14(%rdi)
movl %ecx, 0x18(%rdi)
movl %r8d, 0x1c(%rdi)
movq 0x8(%rdi), %rdi
callq 0x6ea0
movq 0x8(%rbx), %rdi
movl 0x18(%rbx), %esi
movl 0x1c(%rbx), %edx
popq %rbx
jmp 0x6edb
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/buffer.cc
// Function: Buffer::update()
void Buffer::update(void)
{
	if (is_dead())
		return;
	block_till_ready();
	size_t tmp = _ifs.tellg();
	_ifs.seekg(0);
	_maxline = std::count(std::istreambuf_iterator<char>(_ifs),
		std::istreambuf_iterator<char>(), '\n') - 1;
	_ifs.seekg(tmp);
	signal_blocked();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
callq 0x6310
testb %al, %al
jne 0x627d
movq %rbx, %rdi
callq 0x62aa
leaq 0x70(%rbx), %r14
movq %r14, %rdi
callq 0x3660
movq %rax, %r15
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x34d0
movq 0x70(%rbx), %rax
movq -0x18(%rax), %rax
movq 0x158(%rbx,%rax), %rdi
leaq 0xf(%rsp), %r8
movb $0xa, (%r8)
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0x65f0
decl %eax
movl %eax, 0x29c(%rbx)
movq %r14, %rdi
movq %r15, %rsi
xorl %edx, %edx
callq 0x34d0
movq %rbx, %rdi
callq 0x62ee
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/buffer.cc
// Function: Buffer::get_max_line()
int Buffer::get_max_line(void)
{
	block_till_ready();
	int ret = _maxline;
	signal_blocked();
	return ret;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x62aa
movl 0x29c(%rbx), %ebp
movq %rbx, %rdi
callq 0x62ee
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/buffer.cc
// Function: Buffer::block_till_ready()
void Buffer::block_till_ready(void)
{
	_mutex.lock();
	while (_busy)
		_mutex.wait();
	_busy = true;
	_mutex.unlock();
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x3530
cmpb $0x1, 0x2a0(%rbx)
jne 0x62d7
leaq 0x28(%rbx), %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x3580
cmpb $0x0, 0x2a0(%rbx)
jne 0x62c3
movb $0x1, 0x2a0(%rbx)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x32c0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/buffer.cc
// Function: Buffer::is_dead()
bool Buffer::is_dead(void)
{
	block_till_ready();
	bool ret = !_ifs.is_open();
	signal_blocked();
	return ret;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x62aa
leaq 0xe8(%rbx), %rdi
callq 0x30c0
movl %eax, %ebp
xorb $0x1, %bpl
movq %rbx, %rdi
callq 0x62ee
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: string_to_color(char const*)
short string_to_color(const char *arg)
{
	std::string s(arg);
	if (s == "black")
		return COLOR_BLACK;
	else if (s == "red")
		return COLOR_RED;
	else if (s == "green")
		return COLOR_GREEN;
	else if (s == "yellow")
		return COLOR_YELLOW;
	else if (s == "blue")
		return COLOR_BLUE;
	else if (s == "magenta")
		return COLOR_MAGENTA;
	else if (s == "cyan")
		return COLOR_CYAN;
	else if (s == "white")
		return COLOR_WHITE;
	return -1;
}

// Assembly:
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rsi
leaq 0x10(%rsp), %rbx
leaq 0xf(%rsp), %rdx
movq %rbx, %rdi
callq 0x5034
leaq 0x1bf6(%rip), %rsi      # 0x8617
movq %rbx, %rdi
callq 0x3100
testl %eax, %eax
je 0x6acf
leaq 0x1be5(%rip), %rsi      # 0x861d
leaq 0x10(%rsp), %rdi
callq 0x3100
testl %eax, %eax
je 0x6ad3
leaq 0x1bd0(%rip), %rsi      # 0x8621
leaq 0x10(%rsp), %rdi
callq 0x3100
testl %eax, %eax
je 0x6ad9
leaq 0x1bc1(%rip), %rsi      # 0x8627
leaq 0x10(%rsp), %rdi
callq 0x3100
testl %eax, %eax
je 0x6adf
leaq 0x1bb3(%rip), %rsi      # 0x862e
leaq 0x10(%rsp), %rdi
callq 0x3100
testl %eax, %eax
je 0x6ae5
leaq 0x1ba3(%rip), %rsi      # 0x8633
leaq 0x10(%rsp), %rdi
callq 0x3100
testl %eax, %eax
je 0x6aeb
leaq 0x1b96(%rip), %rsi      # 0x863b
leaq 0x10(%rsp), %rdi
callq 0x3100
testl %eax, %eax
je 0x6af1
leaq 0x1b86(%rip), %rsi      # 0x8640
leaq 0x10(%rsp), %rdi
callq 0x3100
xorl %ebx, %ebx
negl %eax
sbbl %ebx, %ebx
orl $0x7, %ebx
jmp 0x6af5
xorl %ebx, %ebx
jmp 0x6af5
movw $0x1, %bx
jmp 0x6af5
movw $0x2, %bx
jmp 0x6af5
movw $0x3, %bx
jmp 0x6af5
movw $0x4, %bx
jmp 0x6af5
movw $0x5, %bx
jmp 0x6af5
movw $0x6, %bx
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6b10
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x3380
movl %ebx, %eax
addq $0x30, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: init_screen(short, short)
int init_screen(short fg, short bg)
{
	if (!initscr())
		return -1;
	if (keypad(stdscr, TRUE) == ERR)
		return -2;
	noecho();
	cbreak();
	curs_set(0);
	wtimeout(stdscr, 500);
	clear_terminal();

	if (has_colors() == TRUE) {
		if (start_color() == ERR)
			return -4;
		if (use_default_colors() == ERR)
			return -5;
		if (init_pair(1, fg, bg) == ERR)
			return -6;
		color_attr = COLOR_PAIR(1);
	}

	const char *env = getenv("TERM");
	if (env && !strcmp(env, "screen"))
		standout_attr = A_REVERSE;
	else
		standout_attr = A_STANDOUT;
	return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebx
movl %edi, %ebp
callq 0x3540
testq %rax, %rax
je 0x6bd2
movq 0x5483(%rip), %r14      # 0xbfb8
movq (%r14), %rdi
movl $0x1, %esi
callq 0x3150
cmpl $-0x1, %eax
je 0x6bd9
callq 0x3410
callq 0x3110
xorl %edi, %edi
callq 0x32e0
movq (%r14), %rdi
movl $0x1f4, %esi            # imm = 0x1F4
callq 0x3430
callq 0x6c07
callq 0x35b0
testb %al, %al
je 0x6ba7
callq 0x30b0
cmpl $-0x1, %eax
je 0x6be0
callq 0x3250
cmpl $-0x1, %eax
je 0x6bf9
movswl %bp, %esi
movswl %bx, %edx
movl $0x1, %edi
callq 0x3080
cmpl $-0x1, %eax
je 0x6c00
movb $0x1, 0x5939(%rip)      # 0xc4e0
leaq 0x1a98(%rip), %rdi      # 0x8646
callq 0x3490
testq %rax, %rax
je 0x6bcb
leaq 0x1951(%rip), %rsi      # 0x8510
movq %rax, %rdi
callq 0x34f0
testl %eax, %eax
je 0x6be7
movl $0x10000, %eax          # imm = 0x10000
jmp 0x6bec
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x6bf4
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
jmp 0x6bf4
movl $0xfffffffc, %eax       # imm = 0xFFFFFFFC
jmp 0x6bf4
movl $0x40000, %eax          # imm = 0x40000
movl %eax, 0x58f2(%rip)      # 0xc4e4
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
movl $0xfffffffb, %eax       # imm = 0xFFFFFFFB
jmp 0x6bf4
movl $0xfffffffa, %eax       # imm = 0xFFFFFFFA
jmp 0x6bf4
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: clear_terminal()
void clear_terminal(void)
{
	global_lock();
	wclear(stdscr);
	wrefresh(stdscr);
	global_unlock();
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x58a6(%rip), %rbx      # 0xc4b8
movq %rbx, %rdi
callq 0x3530
movq 0x5397(%rip), %r14      # 0xbfb8
movq (%r14), %rdi
callq 0x3370
movq (%r14), %rdi
callq 0x33e0
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x32c0
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: get_terminal_lines()
int get_terminal_lines(void)
{
	global_lock();
	int y = static_cast<int>(LINES);
	global_unlock();
	return y;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
leaq 0x5841(%rip), %rbx      # 0xc4b8
movq %rbx, %rdi
callq 0x3530
movq 0x52e2(%rip), %rax      # 0xbf68
movl (%rax), %ebp
movq %rbx, %rdi
callq 0x32c0
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: get_terminal_cols()
int get_terminal_cols(void)
{
	global_lock();
	int x = static_cast<int>(COLS);
	global_unlock();
	return x;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
leaq 0x5815(%rip), %rbx      # 0xc4b8
movq %rbx, %rdi
callq 0x3530
movq 0x52ce(%rip), %rax      # 0xbf80
movl (%rax), %ebp
movq %rbx, %rdi
callq 0x32c0
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: alloc_screen(int, int, int, int)
Screen *alloc_screen(int ylen, int xlen, int ypos, int xpos)
{
	global_lock();
	Screen *scr = newwin(ylen, xlen, ypos, xpos);
	if (scr) {
		scrollok(scr, FALSE);
		idlok(scr, FALSE);
		keypad(scr, TRUE);
	}
	global_unlock();
	return scr;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebx
movl %edx, %ebp
movl %esi, %r14d
movl %edi, %r15d
leaq 0x57d6(%rip), %rdi      # 0xc4b8
callq 0x3530
movl %r15d, %edi
movl %r14d, %esi
movl %ebp, %edx
movl %ebx, %ecx
callq 0x33b0
movq %rax, %rbx
testq %rax, %rax
je 0x6d1f
movq %rbx, %rdi
xorl %esi, %esi
callq 0x3420
movq %rbx, %rdi
xorl %esi, %esi
callq 0x35d0
movq %rbx, %rdi
movl $0x1, %esi
callq 0x3150
leaq 0x5792(%rip), %rdi      # 0xc4b8
callq 0x32c0
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: box_screen(_win_st*)
void box_screen(Screen *scr)
{
	global_lock();
	wborder(scr, ACS_VLINE, ACS_VLINE, ACS_HLINE, ACS_HLINE,
		ACS_ULCORNER, ACS_URCORNER, ACS_LLCORNER, ACS_LRCORNER);
	global_unlock();
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x5594(%rip), %r14      # 0xc4b8
movq %r14, %rdi
callq 0x3530
movq 0x503d(%rip), %rax      # 0xbf70
movl 0x1e0(%rax), %edx
movl 0x1c4(%rax), %ecx
movl 0x1b0(%rax), %r9d
movl 0x1a8(%rax), %r10d
movl 0x1ac(%rax), %r11d
movl 0x1b4(%rax), %eax
subq $0x8, %rsp
movq %rbx, %rdi
movl %edx, %esi
movl %ecx, %r8d
pushq %r10
pushq %rax
pushq %r11
callq 0x31c0
addq $0x20, %rsp
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x32c0
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/curses.cc
// Function: bkgd_screen(_win_st*)
void bkgd_screen(Screen *scr)
{
	global_lock();
	if (color_attr != A_NORMAL)
		wbkgd(scr, color_attr | ' ');
	global_unlock();
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
leaq 0x552a(%rip), %rdi      # 0xc4b8
callq 0x3530
cmpb $0x1, 0x5546(%rip)      # 0xc4e0
jne 0x6fa9
movq %rbx, %rdi
movl $0x120, %esi            # imm = 0x120
callq 0x3620
leaq 0x5508(%rip), %rdi      # 0xc4b8
popq %rbx
jmp 0x32c0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/watch.cc
// Function: init_watch(bool)
int init_watch(bool nonblock)
{
	fd = inotify_init();
	if (fd == -1)
		return -1;
	if (nonblock) {
		int ret = fcntl(fd, F_GETFL, 0);
		if (ret == -1 || fcntl(fd, F_SETFL, ret | O_NONBLOCK) == -1) {
			close(fd);
			return -1;
		}
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %edi, %ebp
callq 0x36a0
movl %eax, 0x53e8(%rip)      # 0xc3b0
xorl %ebx, %ebx
cmpl $-0x1, %eax
sete %cl
setne %dl
andb %bpl, %dl
cmpb $0x1, %dl
jne 0x7022
xorl %ebx, %ebx
movl %eax, %edi
movl $0x3, %esi
xorl %edx, %edx
xorl %eax, %eax
callq 0x3210
cmpl $-0x1, %eax
je 0x7010
movl 0x53b8(%rip), %edi      # 0xc3b0
orl $0x800, %eax            # imm = 0x800
movl $0x4, %esi
movl %eax, %edx
xorl %eax, %eax
callq 0x3210
cmpl $-0x1, %eax
jne 0x7026
movl 0x539a(%rip), %edi      # 0xc3b0
callq 0x36f0
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x7026
movb %cl, %bl
negl %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/watch.cc
// Function: add_watch(char const*)
int add_watch(const char *path)
{
	int ret = inotify_add_watch(fd, path, IN_MODIFY);
	if (ret != -1)
		expand_buffer(1);
	return ret;
}

// Assembly:
pushq %rbx
movq %rdi, %rsi
movl 0x536c(%rip), %edi      # 0xc3b0
movl $0x2, %edx
callq 0x31e0
movl %eax, %ebx
cmpl $-0x1, %eax
je 0x7076
leaq 0x548c(%rip), %rdi      # 0xc4e8
movq 0x548d(%rip), %rsi      # 0xc4f0
subq 0x547e(%rip), %rsi      # 0xc4e8
addq $0x110, %rsi            # imm = 0x110
callq 0x7164
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/watch.cc
// Function: delete_watch(int)
int delete_watch(int wd)
{
	int ret = inotify_rm_watch(fd, wd);
	if (ret != -1)
		expand_buffer(-1);
	return ret;
}

// Assembly:
pushq %rbx
movl %edi, %esi
movl 0x532d(%rip), %edi      # 0xc3b0
callq 0x3190
movl %eax, %ebx
cmpl $-0x1, %eax
je 0x70b0
leaq 0x5452(%rip), %rdi      # 0xc4e8
movq 0x5453(%rip), %rsi      # 0xc4f0
subq 0x5444(%rip), %rsi      # 0xc4e8
addq $-0x110, %rsi           # imm = 0xFEF0
callq 0x7164
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/kusumi[P]procstat/watch.cc
// Function: read_watch(std::map<int, int, std::less<int>, std::allocator<std::pair<int const, int>>>&)
int read_watch(watch_res &r)
{
	char *p = &buf[0];
	int ret = read(fd, p, buf.size());
	if (ret == -1) {
		if (errno == EAGAIN)
			return 0;
		else
			return -1;
	}
	int i = 0;
	while (i < ret) {
		struct inotify_event *e =
			reinterpret_cast<struct inotify_event*>(p + i);
		if (e->mask & IN_MODIFY)
			r.insert(watch_res::value_type(e->wd, WATCH_MODIFY));
		i += sizeof(struct inotify_event) + e->len;
	}
	return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r14
movq 0x541d(%rip), %r15      # 0xc4e8
movl 0x52df(%rip), %edi      # 0xc3b0
movq 0x5418(%rip), %rdx      # 0xc4f0
subq %r15, %rdx
movq %r15, %rsi
callq 0x3510
movq %rax, %rbx
cmpl $-0x1, %ebx
je 0x712d
testl %ebx, %ebx
jle 0x713c
xorl %eax, %eax
leaq 0x8(%rsp), %r12
movslq %eax, %r13
testb $0x2, 0x4(%r15,%r13)
je 0x711c
movl (%r15,%r13), %eax
movl %eax, 0x8(%rsp)
movl $0x1, 0xc(%rsp)
movq %r14, %rdi
movq %r12, %rsi
callq 0x7294
movl 0xc(%r15,%r13), %eax
addl %r13d, %eax
addl $0x10, %eax
cmpl %ebx, %eax
jl 0x70f6
jmp 0x713c
callq 0x3050
xorl %ebx, %ebx
cmpl $0xb, (%rax)
setne %bl
negl %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/meirdev[P]HexViewer/./CLI11.hpp
// Function: CLI::detail::ExistingFileValidator::ExistingFileValidator()
ExistingFileValidator() {
        tname = "FILE";
        func = [](const std::string &filename) {
            struct stat buffer;
            bool exist = stat(filename.c_str(), &buffer) == 0;
            bool is_dir = (buffer.st_mode & S_IFDIR) != 0;
            if(!exist) {
                return "File does not exist: " + filename;
            } else if(is_dir) {
                return "File is actually a directory: " + filename;
            }
            return std::string();
        };
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rdi)
movups %xmm0, 0x30(%rdi)
leaq 0x1cdc7(%rip), %rcx     # 0x230e5
movl $0x4, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x5460
addq $0x20, %rbx
leaq 0x7(%rsp), %rsi
movq %rbx, %rdi
callq 0xbd44
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x6492
movq %r14, %rdi
callq 0x5510
nop
// File: /workspace/github_cpp_makefile_star2_O3/meirdev[P]HexViewer/./CLI11.hpp
// Function: CLI::detail::ExistingDirectoryValidator::ExistingDirectoryValidator()
ExistingDirectoryValidator() {
        tname = "DIR";
        func = [](const std::string &filename) {
            struct stat buffer;
            bool exist = stat(filename.c_str(), &buffer) == 0;
            bool is_dir = (buffer.st_mode & S_IFDIR) != 0;
            if(!exist) {
                return "Directory does not exist: " + filename;
            } else if(!is_dir) {
                return "Directory is actually a file: " + filename;
            }
            return std::string();
        };
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rdi)
movups %xmm0, 0x30(%rdi)
leaq 0x1cd99(%rip), %rcx     # 0x2311f
movl $0x3, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x5460
addq $0x20, %rbx
leaq 0x7(%rsp), %rsi
movq %rbx, %rdi
callq 0xbeb8
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x6492
movq %r14, %rdi
callq 0x5510
nop
// File: /workspace/github_cpp_makefile_star2_O3/meirdev[P]HexViewer/./CLI11.hpp
// Function: CLI::detail::ExistingPathValidator::ExistingPathValidator()
ExistingPathValidator() {
        tname = "PATH";
        func = [](const std::string &filename) {
            struct stat buffer;
            bool const exist = stat(filename.c_str(), &buffer) == 0;
            if(!exist) {
                return "Path does not exist: " + filename;
            }
            return std::string();
        };
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rdi)
movups %xmm0, 0x30(%rdi)
leaq 0x1cd6f(%rip), %rcx     # 0x2315d
movl $0x4, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x5460
addq $0x20, %rbx
leaq 0x7(%rsp), %rsi
movq %rbx, %rdi
callq 0xbfa4
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x6492
movq %r14, %rdi
callq 0x5510
nop
// File: /workspace/github_cpp_makefile_star2_O3/meirdev[P]HexViewer/./CLI11.hpp
// Function: CLI::detail::NonexistentPathValidator::NonexistentPathValidator()
NonexistentPathValidator() {
        tname = "PATH";
        func = [](const std::string &filename) {
            struct stat buffer;
            bool exist = stat(filename.c_str(), &buffer) == 0;
            if(exist) {
                return "Path already exists: " + filename;
            }
            return std::string();
        };
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rdi)
movups %xmm0, 0x30(%rdi)
leaq 0x1cd07(%rip), %rcx     # 0x2315d
movl $0x4, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x5460
addq $0x20, %rbx
leaq 0x7(%rsp), %rsi
movq %rbx, %rdi
callq 0xc080
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x6492
movq %r14, %rdi
callq 0x5510
nop
// File: /workspace/github_cpp_makefile_star2_O3/meirdev[P]HexViewer/./CLI11.hpp
// Function: CLI::App::get_options(std::function<bool (CLI::Option const*)>) const
std::vector<const Option *> get_options(const std::function<bool(const Option *)> filter = {}) const {
        std::vector<const Option *> options(options_.size());
        std::transform(std::begin(options_), std::end(options_), std::begin(options), [](const Option_p &val) {
            return val.get();
        });

        if(filter) {
            options.erase(std::remove_if(std::begin(options),
                                         std::end(options),
                                         [&filter](const Option *opt) { return !filter(opt); }),
                          std::end(options));
        }

        return options;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0xa0(%rsi), %rsi
subq 0x98(%r15), %rsi
sarq $0x3, %rsi
leaq 0xf(%rsp), %rdx
callq 0xc15c
movq 0x98(%r15), %rax
movq 0xa0(%r15), %rcx
cmpq %rcx, %rax
je 0x70fd
movq (%rbx), %rdx
movq (%rax), %rsi
movq %rsi, (%rdx)
addq $0x8, %rax
addq $0x8, %rdx
cmpq %rcx, %rax
jne 0x70ea
cmpq $0x0, 0x10(%r14)
je 0x711d
movq (%rbx), %rdi
movq 0x8(%rbx), %rsi
movq %r14, %rdx
callq 0xc205
cmpq 0x8(%rbx), %rax
je 0x711d
movq %rax, 0x8(%rbx)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x7141
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x52c0
movq %r14, %rdi
callq 0x5510
nop
// File: /workspace/github_cpp_makefile_star2_O3/meirdev[P]HexViewer/./CLI11.hpp
// Function: CLI::detail::ini_join(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>)
inline std::string ini_join(std::vector<std::string> args) {
    std::ostringstream s;
    size_t start = 0;
    for(const auto &arg : args) {
        if(start++ > 0)
            s << " ";

        auto it = std::find_if(arg.begin(), arg.end(), [](char ch) { return std::isspace<char>(ch, std::locale()); });
        if(it == arg.end())
            s << arg;
        else if(arg.find(R"(")") == std::string::npos)
            s << R"(")" << arg << R"(")";
        else
            s << R"(')" << arg << R"(')";
    }

    return s.str();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x188, %rsp            # imm = 0x188
movq %rsi, %r15
movq %rdi, 0x8(%rsp)
leaq 0x10(%rsp), %rdi
callq 0x53e0
movq (%r15), %r14
movq 0x8(%r15), %rbx
cmpq %rbx, %r14
je 0x7305
xorl %ebp, %ebp
leaq 0x10(%rsp), %r15
leaq 0x1bf7c(%rip), %r12     # 0x231bf
leaq 0x1bf77(%rip), %r13     # 0x231c1
subq $0x1, %rbp
jb 0x7264
movl $0x1, %edx
movq %r15, %rdi
leaq 0x1c502(%rip), %rsi     # 0x23761
callq 0x5320
movq (%r14), %rdi
movq 0x8(%r14), %rsi
addq %rdi, %rsi
callq 0xc56a
movq (%r14), %rsi
movq 0x8(%r14), %rdx
leaq (%rsi,%rdx), %rcx
cmpq %rcx, %rax
je 0x72bf
movl $0x1, %ecx
movq %r14, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0x5500
cmpq $-0x1, %rax
je 0x72c9
movl $0x1, %edx
movq %r15, %rdi
movq %r13, %rsi
callq 0x5320
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq %r15, %rdi
callq 0x5320
movq %r13, %rsi
jmp 0x72eb
movq %r15, %rdi
callq 0x5320
jmp 0x72f8
movl $0x1, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x5320
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq %r15, %rdi
callq 0x5320
movq %r12, %rsi
movl $0x1, %edx
movq %rax, %rdi
callq 0x5320
addq $0x20, %r14
cmpq %rbx, %r14
jne 0x724a
leaq 0x18(%rsp), %rsi
movq 0x8(%rsp), %rbx
movq %rbx, %rdi
callq 0x5480
movq 0x28c9a(%rip), %rsi     # 0x2ffb8
leaq 0x10(%rsp), %rdi
callq 0x5190
leaq 0x80(%rsp), %rdi
callq 0x5100
movq %rbx, %rax
addq $0x188, %rsp            # imm = 0x188
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x734e
jmp 0x734e
movq %rax, %rbx
movq 0x28c60(%rip), %rsi     # 0x2ffb8
leaq 0x10(%rsp), %rdi
callq 0x5190
leaq 0x80(%rsp), %rdi
callq 0x5100
movq %rbx, %rdi
callq 0x5510