LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::WriteFile(char const*) const
int R3PointSet::
WriteFile(const char *filename) const
{
  // Parse input filename extension
  const char *extension;
  if (!(extension = strrchr(filename, '.'))) {
    printf("Filename %s has no extension (e.g., .mm)\n", filename);
    return 0;
  }

  // Write file of appropriate type
  if (!strcmp(extension, ".xyz")) return WriteXYZFile(filename);
  else if (!strcmp(extension, ".xyzn")) return WriteXYZNFile(filename);
  else if (!strcmp(extension, ".pset")) return WriteBinaryFile(filename);
  else if (!strcmp(extension, ".pts")) return WritePTSFile(filename);
  else if (!strcmp(extension, ".sdf")) return WriteSDFFile(filename);
  else return WriteMeshFile(filename);

  // Should not get here
  RNFail("Unrecognized file extension in %s\n", filename);
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
pushq $0x2e
popq %rsi
movq %rbx, %rdi
callq 0x22990
testq %rax, %rax
je 0x754b5
movq %rax, %r15
leaq 0x67f05(%rip), %rsi     # 0xdd352
movq %rax, %rdi
callq 0x22d00
testl %eax, %eax
je 0x754ce
leaq 0x67ef7(%rip), %rsi     # 0xdd357
movq %r15, %rdi
callq 0x22d00
testl %eax, %eax
je 0x754de
leaq 0x67eea(%rip), %rsi     # 0xdd35d
movq %r15, %rdi
callq 0x22d00
testl %eax, %eax
je 0x754ee
leaq 0x67edd(%rip), %rsi     # 0xdd363
movq %r15, %rdi
callq 0x22d00
testl %eax, %eax
je 0x754fe
leaq 0x67ecf(%rip), %rsi     # 0xdd368
movq %r15, %rdi
callq 0x22d00
movq %r14, %rdi
movq %rbx, %rsi
testl %eax, %eax
je 0x7550e
popq %rbx
popq %r14
popq %r15
jmp 0x75afe
leaq 0x67e6c(%rip), %rdi     # 0xdd328
movq %rbx, %rsi
xorl %eax, %eax
callq 0x22080
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x75518
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x755c2
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x756a0
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x758c8
popq %rbx
popq %r14
popq %r15
jmp 0x759e8
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::WriteXYZFile(char const*) const
int R3PointSet::
WriteXYZFile(const char *filename) const
{
 // Open file
  FILE *fp = fopen(filename, "w");
  if (!fp) {
    RNFail("Unable to open %s\n", filename);
    return 0;
  }

  // Write points
  for (int i = 0; i < NPoints(); i++) {
    const R3Point& p = PointPosition(i);
    fprintf(fp, "%g %g %g\n", p[0], p[1], p[2]);
  }

  // Close file
  fclose(fp);

  // Return success
  return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x6870a(%rip), %rsi     # 0xddc3a
movq %r15, %rdi
callq 0x22a70
testq %rax, %rax
je 0x7559e
movq %rax, %r14
pushq $0x10
popq %r12
xorl %r13d, %r13d
pushq $0x18
popq %rbp
leaq 0x6679e(%rip), %r15     # 0xdbcef
movq (%rbx), %rcx
movq 0x8(%rbx), %rax
subq %rcx, %rax
cqto
idivq %rbp
cltq
cmpq %rax, %r13
jge 0x75591
movsd -0x10(%rcx,%r12), %xmm0
movsd -0x8(%rcx,%r12), %xmm1
movsd (%rcx,%r12), %xmm2
movq %r14, %rdi
movq %r15, %rsi
movb $0x3, %al
callq 0x22d70
incq %r13
addq $0x18, %r12
jmp 0x75551
movq %r14, %rdi
callq 0x22890
pushq $0x1
popq %rbx
jmp 0x755b1
leaq 0x67dcd(%rip), %rdi     # 0xdd372
xorl %ebx, %ebx
movq %r15, %rsi
xorl %eax, %eax
callq 0x93dbe
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::WriteXYZNFile(char const*) const
int R3PointSet::
WriteXYZNFile(const char *filename) const
{
 // Open file
  FILE *fp = fopen(filename, "w");
  if (!fp) {
    RNFail("Unable to open %s\n", filename);
    return 0;
  }

  // Write points
  for (int i = 0; i < NPoints(); i++) {
    const R3Point& p = PointPosition(i);
    const R3Vector& n = PointNormal(i);
    fprintf(fp, "%g %g %g %g %g %g\n", p[0], p[1], p[2], n[0], n[1], n[2]);
  }

  // Close file
  fclose(fp);

  // Return success
  return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x68660(%rip), %rsi     # 0xddc3a
movq %r15, %rdi
callq 0x22a70
testq %rax, %rax
je 0x7567c
movq %rax, %r14
xorl %r12d, %r12d
pushq $0x18
popq %r13
leaq 0x67d89(%rip), %r15     # 0xdd385
xorl %ebp, %ebp
movq (%rbx), %rcx
movq 0x8(%rbx), %rax
subq %rcx, %rax
cqto
idivq %r13
cltq
cmpq %rax, %rbp
jge 0x7566f
movq 0x18(%rbx), %rsi
movq 0x20(%rbx), %rax
subq %rsi, %rax
cqto
idivq %r13
cltq
cmpq %rax, %rbp
jl 0x75634
leaq 0x67c1e(%rip), %rsi     # 0xdd250
jmp 0x75637
addq %r12, %rsi
movsd (%rcx,%r12), %xmm0
movsd 0x8(%rcx,%r12), %xmm1
movsd 0x10(%rcx,%r12), %xmm2
movsd (%rsi), %xmm3
movsd 0x8(%rsi), %xmm4
movsd 0x10(%rsi), %xmm5
movq %r14, %rdi
movq %r15, %rsi
movb $0x6, %al
callq 0x22d70
incq %rbp
addq $0x18, %r12
jmp 0x755fe
movq %r14, %rdi
callq 0x22890
pushq $0x1
popq %rbx
jmp 0x7568f
leaq 0x67cef(%rip), %rdi     # 0xdd372
xorl %ebx, %ebx
movq %r15, %rsi
xorl %eax, %eax
callq 0x93dbe
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::WritePTSFile(char const*) const
int R3PointSet::
WritePTSFile(const char *filename) const
{
 // Open file
  FILE *fp = fopen(filename, "wb");
  if (!fp) {
    RNFail("Unable to open %s\n", filename);
    return 0;
  }

  // Write points
  float buf[6];
  for (int i = 0; i < NPoints(); i++) {
    const R3Point& p = PointPosition(i);
    const R3Vector& n = PointNormal(i);
    buf[0] = p[0]; buf[1] = p[1]; buf[2] = p[2];
    buf[3] = n[0]; buf[4] = n[1]; buf[5] = n[2];
    if (fwrite(buf, sizeof(float), 6, fp) != (unsigned int) 6) {
      RNFail("Unable to write point %d to %s\n", i, filename);
      return 0;
    }
  }

  // Close file
  fclose(fp);

  // Return success
  return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r12
movq %rdi, %r14
leaq 0x6734a(%rip), %rsi     # 0xdcc2d
movq %r12, %rdi
callq 0x22a70
testq %rax, %rax
je 0x7599c
movq %rax, %r15
movq %r12, 0x8(%rsp)
xorl %r13d, %r13d
pushq $0x18
popq %rbp
pushq $0x6
popq %rbx
xorl %r12d, %r12d
movq (%r14), %rcx
movq 0x8(%r14), %rax
subq %rcx, %rax
cqto
idivq %rbp
cltq
cmpq %rax, %r12
jge 0x759b1
movq 0x18(%r14), %rsi
movq 0x20(%r14), %rax
subq %rsi, %rax
cqto
idivq %rbp
cltq
cmpq %rax, %r12
jl 0x75942
leaq 0x67910(%rip), %rsi     # 0xdd250
jmp 0x75945
addq %r13, %rsi
movupd (%rcx,%r13), %xmm0
movsd 0x10(%rcx,%r13), %xmm1
movhpd (%rsi), %xmm1           # xmm1 = xmm1[0],mem[0]
cvtpd2ps %xmm1, %xmm1
cvtpd2ps %xmm0, %xmm0
unpcklpd %xmm1, %xmm0            # xmm0 = xmm0[0],xmm1[0]
movapd %xmm0, 0x10(%rsp)
movupd 0x8(%rsi), %xmm0
cvtpd2ps %xmm0, %xmm0
movlpd %xmm0, 0x20(%rsp)
leaq 0x10(%rsp), %rdi
pushq $0x4
popq %rsi
movq %rbx, %rdx
movq %r15, %rcx
callq 0x23270
cmpq $0x6, %rax
jne 0x759be
incq %r12
addq $0x18, %r13
jmp 0x75908
leaq 0x679cf(%rip), %rdi     # 0xdd372
xorl %ebx, %ebx
movq %r12, %rsi
xorl %eax, %eax
callq 0x93dbe
jmp 0x759d6
movq %r15, %rdi
callq 0x22890
pushq $0x1
popq %rbx
jmp 0x759d6
leaq 0x679d3(%rip), %rdi     # 0xdd398
xorl %ebx, %ebx
movl %r12d, %esi
movq 0x8(%rsp), %rdx
xorl %eax, %eax
callq 0x93dbe
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::WriteSDFFile(char const*) const
int R3PointSet::
WriteSDFFile(const char *filename) const
{
 // Open file
  FILE *fp = fopen(filename, "wb");
  if (!fp) {
    RNFail("Unable to open %s\n", filename);
    return 0;
  }

  // Write points
  float buf[4];
  for (int i = 0; i < NPoints(); i++) {
    const R3Point& p = PointPosition(i);
    buf[0] = p[0]; buf[1] = p[1]; buf[2] = p[2];
    buf[3] = PointValue(i);
    if (fwrite(buf, sizeof(float), 4, fp) != (unsigned int) 4) {
      RNFail("Unable to write point %d to %s\n", i, filename);
      return 0;
    }
  }

  // Close file
  fclose(fp);

  // Return success
  return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x6722a(%rip), %rsi     # 0xdcc2d
movq %rbx, %rdi
callq 0x22a70
testq %rax, %rax
je 0x75ab3
movq %rax, %r15
movq %rbx, 0x10(%rsp)
pushq $0x2
popq %rbx
xorl %r12d, %r12d
movq %rsp, %r13
pushq $0x4
popq %rbp
movq (%r14), %rcx
movq 0x8(%r14), %rax
subq %rcx, %rax
cqto
pushq $0x18
popq %rsi
idivq %rsi
cltq
cmpq %rax, %r12
jge 0x75ac8
movupd -0x10(%rcx,%rbx,8), %xmm0
cvtpd2ps %xmm0, %xmm0
movlpd %xmm0, (%rsp)
cvtsd2ss (%rcx,%rbx,8), %xmm0
movss %xmm0, 0x8(%rsp)
movq 0xf0(%r14), %rax
movq 0xf8(%r14), %rcx
subq %rax, %rcx
shrq $0x3, %rcx
movslq %ecx, %rcx
movss 0x66871(%rip), %xmm0    # 0xdc2f0
cmpq %rcx, %r12
jge 0x75a8a
cvtsd2ss (%rax,%r12,8), %xmm0
movss %xmm0, 0xc(%rsp)
movq %r13, %rdi
movq %rbp, %rsi
movq %rbp, %rdx
movq %r15, %rcx
callq 0x23270
cmpq $0x4, %rax
jne 0x75ad5
incq %r12
addq $0x3, %rbx
jmp 0x75a28
leaq 0x678b8(%rip), %rdi     # 0xdd372
xorl %ebp, %ebp
movq %rbx, %rsi
xorl %eax, %eax
callq 0x93dbe
jmp 0x75aed
movq %r15, %rdi
callq 0x22890
pushq $0x1
popq %rbp
jmp 0x75aed
leaq 0x678bc(%rip), %rdi     # 0xdd398
xorl %ebp, %ebp
movl %r12d, %esi
movq 0x10(%rsp), %rdx
xorl %eax, %eax
callq 0x93dbe
movl %ebp, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::WriteMeshFile(char const*) const
int R3PointSet::
WriteMeshFile(const char *filename) const
{
  // Create mesh
  R3Mesh mesh;
  for (int i = 0; i < NPoints(); i++) {
    mesh.CreateVertex(PointPosition(i), PointNormal(i), PointColor(i));
  }

  // Write mesh
  return mesh.WriteFile(filename);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x148, %rsp            # imm = 0x148
movq %rsi, 0x8(%rsp)
movq %rdi, %r14
leaq 0x10(%rsp), %r15
movq %r15, %rdi
callq 0x51bb4
xorl %r12d, %r12d
pushq $0x18
popq %r13
leaq 0xe4b5e(%rip), %rbx     # 0x15a690
xorl %ebp, %ebp
movq (%r14), %rsi
movq 0x8(%r14), %rax
subq %rsi, %rax
cqto
idivq %r13
cltq
cmpq %rax, %rbp
jge 0x75ba9
movq 0x18(%r14), %r8
movq 0x20(%r14), %rax
subq %r8, %rax
cqto
idivq %r13
cltq
cmpq %rax, %rbp
jl 0x75b6a
leaq 0x676e8(%rip), %r8      # 0xdd250
jmp 0x75b6d
addq %r12, %r8
movq 0x80(%r14), %rax
movq 0x78(%r14), %rcx
subq %rcx, %rax
cqto
idivq %r13
cltq
cmpq %rax, %rbp
jl 0x75b8c
movq %rbx, %rcx
jmp 0x75b8f
addq %r12, %rcx
addq %r12, %rsi
movq %r15, %rdi
movq %r8, %rdx
xorl %r8d, %r8d
callq 0x54a4e
incq %rbp
addq $0x18, %r12
jmp 0x75b34
leaq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rsi
callq 0x60ae0
movl %eax, %ebx
leaq 0x10(%rsp), %rdi
callq 0x5209c
movl %ebx, %eax
addq $0x148, %rsp            # imm = 0x148
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x75bda
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x5209c
movq %rbx, %rdi
callq 0x230b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/kusumi[P]procstat/main.cc
// Function: (anonymous namespace)::atexit_handler()
void atexit_handler(void)
{
	cleanup_screen();
	cleanup_watch();
	cleanup_log();
	cleanup_lock();
	if (_what)
		std::cerr << _what << std::endl;
}

// Assembly:
pushq %rax
callq 0x73cb
callq 0x77bd
callq 0x7126
movq 0x7462(%rip), %rsi      # 0xc438
testq %rsi, %rsi
je 0x4ff0
movq 0x700e(%rip), %rdi      # 0xbff0
callq 0x4380
movq %rax, %rdi
popq %rax
jmp 0x41c0
popq %rax
retq
// File: /workspace/github_cpp_makefile_star2_O2/kusumi[P]procstat/container.cc
// Function: Container::Container(int, char**)
Container::Container(int argc, char *argv[])
{
	_build_window();
	for (int i = 0; i < argc; i++) {
		char *p = argv[i];
		struct stat st;
		if (stat(p, &st) == -1 || !S_ISREG(st.st_mode))
			continue;
		if (i < static_cast<int>(_v.size())) {
			_v[i]->attach_buffer(p);
			int wd = add_watch(p);
			if (wd != -1)
				_map.insert(_map_t::value_type(wd, _v[i]));
		}
	}
	_it = _v.begin();
	(*_it)->focus(true);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rdx, %r14
movl %esi, %r15d
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdi)
movups %xmm0, (%rdi)
movq %rdi, (%rsp)
callq 0x52f2
xorl %r12d, %r12d
testl %r15d, %r15d
cmovlel %r12d, %r15d
leaq 0x18(%rsp), %r13
cmpq %r12, %r15
je 0x52a1
movq (%r14,%r12,8), %rbp
movq %rbp, %rdi
leaq 0x38(%rsp), %rsi
callq 0x4360
cmpl $-0x1, %eax
je 0x5299
movl 0x50(%rsp), %eax
movl $0xf000, %ecx           # imm = 0xF000
andl %ecx, %eax
cmpl $0x8000, %eax           # imm = 0x8000
jne 0x5299
movq (%rsp), %rcx
movq (%rcx), %rax
movq 0x8(%rcx), %rcx
subq %rax, %rcx
shrq $0x3, %rcx
movslq %ecx, %rcx
cmpq %rcx, %r12
jge 0x5299
movq (%rax,%r12,8), %rbx
movq %r13, %rdi
movq %rbp, %rsi
leaq 0x8(%rsp), %rdx
callq 0x5a26
movq %rbx, %rdi
movq %r13, %rsi
callq 0x629c
movq %r13, %rdi
callq 0x4738
movq %rbp, %rdi
callq 0x77c8
cmpl $-0x1, %eax
je 0x5299
movq (%rsp), %rcx
movq (%rcx), %rcx
movl %eax, 0x8(%rsp)
movq (%rcx,%r12,8), %rax
movq %rax, 0x10(%rsp)
leaq 0x7209(%rip), %rdi      # 0xc498
leaq 0x8(%rsp), %rsi
callq 0x5ef4
incq %r12
jmp 0x51f1
movq (%rsp), %rcx
movq (%rcx), %rax
movq %rax, 0x18(%rcx)
movq (%rax), %rdi
pushq $0x1
popq %rsi
callq 0x63b4
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x52de
jmp 0x52de
jmp 0x52de
movq %rax, %r14
leaq 0x18(%rsp), %rdi
callq 0x4738
jmp 0x52e1
movq %rax, %r14
movq (%rsp), %rdi
callq 0x5e2a
movq %r14, %rdi
callq 0x46a0
// File: /workspace/github_cpp_makefile_star2_O2/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 0x7199(%rip), %r14      # 0xc4b0
leaq 0x7182(%rip), %r15      # 0xc4a0
cmpq %r15, %r14
je 0x535f
movl 0x20(%r14), %edi
callq 0x7814
movq %r14, %rdi
callq 0x4290
movq %rax, %r14
jmp 0x531e
movq -0x8(%rax), %r14
addq $-0x8, %rax
movq %rax, 0x8(%rbx)
testq %r14, %r14
je 0x5352
movq %r14, %rdi
callq 0x61d0
movl $0x80, %esi
movq %r14, %rdi
callq 0x43b0
movq 0x8(%rbx), %rax
cmpq %rax, (%rbx)
jne 0x5339
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x5e2a
movq %rax, %rdi
callq 0x5003
nop
// File: /workspace/github_cpp_makefile_star2_O2/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 0x63b4
movq 0x18(%rbx), %rcx
addq $0x8, %rcx
movq %rcx, 0x18(%rbx)
cmpq 0x8(%rbx), %rcx
jne 0x53ac
movq (%rbx), %rcx
movq %rcx, 0x18(%rbx)
movq (%rcx), %rdi
callq 0x6222
movq 0x18(%rbx), %rcx
testb %al, %al
je 0x53c1
cmpq %r14, %rcx
jne 0x5397
movq (%rcx), %rdi
pushq $0x1
popq %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x63b4
nop
// File: /workspace/github_cpp_makefile_star2_O2/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 0x63b4
movq 0x18(%rbx), %rcx
cmpq (%rbx), %rcx
jne 0x53f6
movq 0x8(%rbx), %rcx
leaq -0x8(%rcx), %rax
movq %rax, 0x18(%rbx)
movq -0x8(%rcx), %rdi
callq 0x6222
movq 0x18(%rbx), %rcx
testb %al, %al
je 0x5414
cmpq %r14, %rcx
jne 0x53ed
movq (%rcx), %rdi
pushq $0x1
popq %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x63b4
// File: /workspace/github_cpp_makefile_star2_O2/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 $0x48, %rsp
movq %rdi, 0x40(%rsp)
callq 0x7422
movl %eax, %ebp
callq 0x73f6
movl %eax, 0x14(%rsp)
leaq 0x6f90(%rip), %rax      # 0xc3e0
movq 0x8(%rax), %rcx
subq (%rax), %rcx
shrq $0x2, %rcx
movl %ebp, %eax
cltd
idivl %ecx
movl %eax, 0x10(%rsp)
movl %edx, 0xc(%rsp)
leal -0x1(%rcx), %eax
movq %rax, 0x28(%rsp)
xorl %edi, %edi
testl %ecx, %ecx
cmovlel %edi, %ecx
movq %rcx, 0x30(%rsp)
movq $0x0, 0x20(%rsp)
cmpq 0x30(%rsp), %rdi
je 0x5535
xorl %r12d, %r12d
cmpq 0x28(%rsp), %rdi
movl $0x0, %eax
cmovel 0xc(%rsp), %eax
movl 0x10(%rsp), %ecx
addl %ecx, %eax
movl %eax, 0x1c(%rsp)
leaq 0x6f2d(%rip), %rax      # 0xc3e0
movq (%rax), %rax
movl (%rax,%rdi,4), %ebx
cmpl $-0x1, %ebx
pushq $0x1
popq %rax
cmovel %eax, %ebx
movl 0x14(%rsp), %eax
cltd
idivl %ebx
movl %eax, %ebp
movl %edx, 0x18(%rsp)
leal -0x1(%rbx), %r13d
testl %ebx, %ebx
cmovlel %r12d, %ebx
movq %rdi, 0x38(%rsp)
movl %edi, %r14d
imull %ecx, %r14d
xorl %r15d, %r15d
movq 0x20(%rsp), %rax
leal (%rax,%r15), %esi
cmpl %r15d, %ebx
je 0x5521
cmpl %r15d, %r13d
movl $0x0, %edx
cmovel 0x18(%rsp), %edx
addl %ebp, %edx
movq 0x40(%rsp), %rdi
movl 0x1c(%rsp), %ecx
movl %r12d, %r8d
movl %r14d, %r9d
callq 0x5662
incl %r15d
addl %ebp, %r12d
jmp 0x54e8
movq 0x38(%rsp), %rdi
incq %rdi
movl %esi, %eax
movq %rax, 0x20(%rsp)
jmp 0x5485
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 $0x48, %rsp
movq %rdi, 0x40(%rsp)
callq 0x73f6
movl %eax, %ebp
callq 0x7422
movl %eax, 0x14(%rsp)
leaq 0x6e72(%rip), %rax      # 0xc3e0
movq 0x8(%rax), %rcx
subq (%rax), %rcx
shrq $0x2, %rcx
movl %ebp, %eax
cltd
idivl %ecx
movl %eax, 0x10(%rsp)
movl %edx, 0xc(%rsp)
leal -0x1(%rcx), %eax
movq %rax, 0x28(%rsp)
xorl %edi, %edi
testl %ecx, %ecx
cmovlel %edi, %ecx
movq %rcx, 0x30(%rsp)
movq $0x0, 0x20(%rsp)
cmpq 0x30(%rsp), %rdi
je 0x5653
xorl %r12d, %r12d
cmpq 0x28(%rsp), %rdi
movl $0x0, %eax
cmovel 0xc(%rsp), %eax
movl 0x10(%rsp), %ecx
addl %ecx, %eax
movl %eax, 0x1c(%rsp)
leaq 0x6e0f(%rip), %rax      # 0xc3e0
movq (%rax), %rax
movl (%rax,%rdi,4), %ebx
cmpl $-0x1, %ebx
pushq $0x1
popq %rax
cmovel %eax, %ebx
movl 0x14(%rsp), %eax
cltd
idivl %ebx
movl %eax, %ebp
movl %edx, 0x18(%rsp)
leal -0x1(%rbx), %r13d
testl %ebx, %ebx
cmovlel %r12d, %ebx
movq %rdi, 0x38(%rsp)
movl %edi, %r14d
imull %ecx, %r14d
xorl %r15d, %r15d
movq 0x20(%rsp), %rax
leal (%rax,%r15), %esi
cmpl %r15d, %ebx
je 0x563f
cmpl %r15d, %r13d
movl $0x0, %ecx
cmovel 0x18(%rsp), %ecx
addl %ebp, %ecx
movq 0x40(%rsp), %rdi
movl 0x1c(%rsp), %edx
movl %r14d, %r8d
movl %r12d, %r9d
callq 0x5662
incl %r15d
addl %ebp, %r12d
jmp 0x5606
movq 0x38(%rsp), %rdi
incq %rdi
movl %esi, %eax
movq %rax, 0x20(%rsp)
jmp 0x55a3
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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
callq 0x5a62
movq (%rax), %r13
movq %r13, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x6232
movq %r13, %rdi
callq 0x6602
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, 0x8(%rsp)
cmpl $0x1, %edx
jne 0x571f
movq 0x8(%rsp), %rdi
callq 0x4160
movl $0x80, %edi
callq 0x4390
movq %rax, %r13
movq %rax, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x6104
leaq 0x10(%rsp), %rsi
movq %r13, (%rsi)
movq %rbx, %rdi
callq 0x5a84
callq 0x4630
jmp 0x56a6
movq %rax, 0x8(%rsp)
movl $0x80, %esi
movq %r13, %rdi
callq 0x43b0
jmp 0x571a
movq %rax, 0x8(%rsp)
callq 0x4630
movq 0x8(%rsp), %rdi
callq 0x46a0
movq %rax, %rdi
callq 0x5003
nop
// File: /workspace/github_cpp_makefile_star2_O2/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 0x18(%rdi), %rax
movq (%rax), %rbx
leal 0x1(%rsi), %eax
cmpl $0x7, %eax
jbe 0x579b
movq %rdi, %r14
leal -0x68(%rsi), %eax
cmpl $0x4, %eax
jbe 0x57b3
leal -0x102(%rsi), %eax
cmpl $0x3, %eax
jbe 0x57c3
cmpl $0x19a, %esi            # imm = 0x19A
je 0x5787
cmpl $0x15, %esi
je 0x5816
cmpl $0x24, %esi
je 0x5844
cmpl $0x30, %esi
je 0x583a
cmpl $0xc, %esi
jne 0x582b
callq 0x7392
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x52f2
leaq 0x2d92(%rip), %rcx      # 0x8534
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x2d9a(%rip), %rcx      # 0x8554
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x2d9e(%rip), %rcx      # 0x8568
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
pushq $0x1
jmp 0x57f7
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x53d4
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x537e
pushq $-0x1
popq %rsi
movq %rbx, %rdi
jmp 0x5826
callq 0x73f6
jmp 0x5821
callq 0x73f6
negl %eax
jmp 0x5821
callq 0x73f6
pushq $0x2
jmp 0x581d
callq 0x73f6
pushq $-0x2
popq %rcx
cltd
idivl %ecx
movq %rbx, %rdi
movl %eax, %esi
callq 0x641e
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x6602
movq %rbx, %rdi
callq 0x63ea
jmp 0x582b
movq %rbx, %rdi
callq 0x6400
jmp 0x582b
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6c6b(%rip), %rdi      # 0xc4c8
leaq 0x40(%rip), %rsi        # 0x58a4
xorl %edx, %edx
callq 0x5aa2
testl %eax, %eax
jne 0x5898
xorl %r14d, %r14d
xorl %r15d, %r15d
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
cmpq %rcx, %r15
jae 0x589b
movq (%rax,%r15,8), %rdi
callq 0x664c
incq %r15
testl %eax, %eax
je 0x5875
movl %eax, %r14d
movl %r14d, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x10(%rsp), %rbp
leaq 0x8(%rsp), %rbx
leaq 0x6bd5(%rip), %r14      # 0xc498
leaq 0x6b76(%rip), %r15      # 0xc440
pushq $0x1
popq %r12
leaq 0x6b07(%rip), %rax      # 0xc3dc
cmpl $0x0, (%rax)
jne 0x5952
andl $0x0, 0x10(%rsp)
andq $0x0, 0x18(%rsp)
movq %rbp, 0x20(%rsp)
movq %rbp, 0x28(%rsp)
andq $0x0, 0x30(%rsp)
movq %rbx, %rdi
callq 0x7835
testl %eax, %eax
jle 0x5938
movq 0x20(%rsp), %r13
cmpq %rbp, %r13
je 0x5933
leaq 0x20(%r13), %rsi
movq %r14, %rdi
callq 0x5b16
cmpl $0x1, 0x24(%r13)
jne 0x5926
movq (%rax), %rdi
callq 0x63aa
movq %r13, %rdi
callq 0x4290
movq %rax, %r13
jmp 0x5906
callq 0x744e
movq %r15, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0x7132
movq %rbx, %rdi
callq 0x5dd2
jmp 0x58ce
xorl %eax, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5965
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x5dd2
movq %rbx, %rdi
callq 0x46a0
// File: /workspace/github_cpp_makefile_star2_O2/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 %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
xorl %r14d, %r14d
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
movq %rcx, %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rdx, %r14
jae 0x59a8
movq (%rax,%r14,8), %rdi
callq 0x6602
incq %r14
jmp 0x5984
xorl %r14d, %r14d
subq %rax, %rcx
sarq $0x3, %rcx
cmpq %rcx, %r14
jae 0x59d0
movq (%rax,%r14,8), %rdi
addq $0x58, %rdi
callq 0x5ab0
incq %r14
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
jmp 0x59ab
leaq 0x6a91(%rip), %rdi      # 0xc468
callq 0x4030
leaq 0x6ae5(%rip), %rdi      # 0xc4c8
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x5ab0
nop
// File: /workspace/github_cpp_makefile_star2_O2/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, %r14d
movl %edx, %r15d
movl %esi, %r12d
movq %rdi, %rbx
callq 0x59f0
xorps %xmm0, %xmm0
movups %xmm0, 0x6c(%rbx)
movups %xmm0, 0x60(%rbx)
pushq $0x48
popq %rdi
callq 0x4390
movq %rax, %r13
movq %rax, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x689a
leaq 0x60(%rbx), %rax
movq %r13, (%rax)
pushq $0x20
popq %rdi
callq 0x4390
movq %rax, %r13
addl $-0x2, %r12d
addl $-0x2, %r15d
incl %r14d
incl %ebp
movq %rax, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x67e4
movq %r13, 0x68(%rbx)
movq 0x60(%rbx), %rdi
callq 0x670a
movq 0x68(%rbx), %rdi
callq 0x670a
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
pushq $0x20
jmp 0x61b1
movq %rax, %r14
pushq $0x48
popq %rsi
movq %r13, %rdi
callq 0x43b0
jmp 0x61bf
movq %rax, %r14
movq %rbx, %rdi
callq 0x5a0a
movq %r14, %rdi
callq 0x46a0
nop
// File: /workspace/github_cpp_makefile_star2_O2/kusumi[P]procstat/window.cc
// Function: Window::resize(int, int, int, int)
void Window::resize(int ylen, int xlen, int ypos, int xpos)
{
	_mutex.lock();
	_frame->resize(ylen, xlen, ypos, xpos);
	_panel->resize(ylen - 2, xlen - 2, ypos + 1, xpos + 1);
	_offset = 0;
	_mutex.unlock();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r8d, %ebp
movl %ecx, %r14d
movl %edx, %r15d
movl %esi, %r12d
movq %rdi, %rbx
callq 0x4560
movq 0x60(%rbx), %rdi
movq (%rdi), %rax
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq *0x20(%rax)
movq 0x68(%rbx), %rdi
addl $-0x2, %r12d
addl $-0x2, %r15d
incl %r14d
incl %ebp
movq (%rdi), %rax
movl %r12d, %esi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq *0x20(%rax)
andl $0x0, 0x78(%rbx)
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x42e0
nop
// File: /workspace/github_cpp_makefile_star2_O2/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 %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x4560
cmpq $0x0, 0x70(%rbx)
je 0x62cc
movq %rbx, %rdi
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x42e0
movq 0x60(%rbx), %r15
leaq 0x48(%rsp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x4510
movq (%r15), %rax
movq %r15, %rdi
movq %r12, %rsi
callq *0x10(%rax)
leaq 0x48(%rsp), %rdi
callq 0x4738
movq 0x68(%rbx), %r15
leaq 0x28(%rsp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x4510
movq (%r15), %rax
movq %r15, %rdi
movq %r12, %rsi
callq *0x10(%rax)
leaq 0x28(%rsp), %rdi
callq 0x4738
movq %rbx, %rdi
callq 0x42e0
movl $0x2a8, %edi            # imm = 0x2A8
callq 0x4390
movq %rax, %r15
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x4510
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x69d0
movq %r15, 0x70(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x4738
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x4738
jmp 0x637b
movq %rax, %rbx
movl $0x2a8, %esi            # imm = 0x2A8
movq %r15, %rdi
callq 0x43b0
jmp 0x63a1
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
jmp 0x639c
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x4738
movq %rbx, %rdi
callq 0x46a0
nop
// File: /workspace/github_cpp_makefile_star2_O2/kusumi[P]procstat/window.cc
// Function: Window::focus(bool)
void Window::focus(bool t)
{
	_mutex.lock();
	_frame->set_focus(t);
	_panel->set_focus(t);
	_mutex.unlock();
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
callq 0x4560
movq 0x60(%r14), %rdi
movq (%rdi), %rax
movl %ebx, %esi
callq *0x18(%rax)
movq 0x68(%r14), %rdi
movq (%rdi), %rax
movl %ebx, %esi
callq *0x18(%rax)
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x42e0
nop
// File: /workspace/github_cpp_makefile_star2_O2/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 0x4560
addl 0x78(%rbx), %r14d
xorl %ebp, %ebp
testl %r14d, %r14d
cmovgl %r14d, %ebp
movq 0x70(%rbx), %rdi
callq 0x6afc
cmpl %eax, %ebp
jle 0x6452
movq 0x70(%rbx), %rdi
callq 0x6afc
movl %eax, %ebp
movl %ebp, 0x78(%rbx)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x42e0
nop
// File: /workspace/github_cpp_makefile_star2_O2/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
callq 0x6222
testb %al, %al
jne 0x65d7
leaq 0x18(%rsp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq %rbx, %rdi
callq 0x4560
movl 0x78(%rbx), %r12d
movq 0x68(%rbx), %rax
movl 0x10(%rax), %ebp
movslq 0x14(%rax), %r14
movq %rbx, %rdi
callq 0x42e0
movq 0x70(%rbx), %rdi
callq 0x6b1e
movq 0x68(%rbx), %rdi
callq 0x675c
xorl %r15d, %r15d
leaq 0x8(%rsp), %r13
movq 0x70(%rbx), %rdi
leaq 0x4(%rsp), %rsi
movq %r13, %rdx
leaq 0x3(%rsp), %rcx
callq 0x6b9a
cmpl $-0x1, %eax
je 0x65b2
movq %rbx, %rdi
callq 0x4560
cmpl %ebp, %r15d
jge 0x65aa
cmpl 0x78(%rbx), %r12d
jne 0x65aa
movq 0x68(%rbx), %rax
cmpl 0x10(%rax), %ebp
jne 0x65aa
cmpl 0x14(%rax), %r14d
jne 0x65aa
movq %rbx, %rdi
callq 0x42e0
cmpl %r12d, 0x4(%rsp)
jl 0x64ca
leaq 0x5ed8(%rip), %rax      # 0xc409
cmpb $0x0, (%rax)
jne 0x6566
cmpl 0x10(%rsp), %r14d
jge 0x6566
leaq 0x28(%rsp), %rdi
movq %r13, %rsi
xorl %edx, %edx
movq %r14, %rcx
callq 0x43c0
movq %r13, %rdi
leaq 0x28(%rsp), %rsi
callq 0x44b0
leaq 0x28(%rsp), %rdi
callq 0x4738
movq 0x68(%rbx), %rdi
movzbl 0x3(%rsp), %ecx
movl %r15d, %esi
xorl %edx, %edx
movq %r13, %r8
callq 0x688c
leaq 0x5e86(%rip), %rax      # 0xc409
cmpb $0x0, (%rax)
je 0x65a2
movq 0x10(%rsp), %rax
xorl %edx, %edx
divq %r14
addl %eax, %r15d
cmpq $0x1, %rdx
sbbl $-0x1, %r15d
jmp 0x64ca
incl %r15d
jmp 0x64ca
movq %rbx, %rdi
callq 0x42e0
movq 0x68(%rbx), %rdi
callq 0x670a
movq 0x70(%rbx), %rdi
callq 0x6d52
movq 0x70(%rbx), %rdi
callq 0x6b4a
leaq 0x8(%rsp), %rdi
callq 0x4738
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x65ec
jmp 0x65ec
jmp 0x65ec
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x4738
movq %rbx, %rdi
callq 0x46a0
nop
// File: /workspace/github_cpp_makefile_star2_O2/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 %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x5d9a(%rip), %rax      # 0xc40b
cmpb $0x1, (%rax)
jne 0x66c8
leaq 0x5d7b(%rip), %rax      # 0xc3f8
movl $0x3e8, %ecx            # imm = 0x3E8
cmpq $0x0, (%rax)
jne 0x669f
leaq 0x5d71(%rip), %rax      # 0xc400
movq (%rax), %rax
movl $0xf4240, %ecx          # imm = 0xF4240
cqto
idivq %rcx
movq %rax, %rcx
movq %rbx, %rax
cqto
idivq %rcx
testq %rdx, %rdx
je 0x66c8
movq %rdx, %r14
movq %rbx, %rdi
callq 0x6462
imulq $0xf4240, %r14, %rdx    # imm = 0xF4240
movq %rbx, %rdi
xorl %esi, %esi
callq 0x661e
leaq 0x5d0d(%rip), %r14      # 0xc3dc
leaq 0x5d22(%rip), %r15      # 0xc3f8
leaq 0x5d23(%rip), %r12      # 0xc400
cmpl $0x0, (%r14)
jne 0x66fc
movq %rbx, %rdi
callq 0x6462
movq (%r15), %rsi
movq (%r12), %rdx
movq %rbx, %rdi
callq 0x661e
jmp 0x66dd
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x54d1(%rip), %rax      # 0xbcc0
movq %rax, (%rdi)
andq $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 0x7453
movq %rax, 0x8(%rbx)
testq %rax, %rax
je 0x6824
movq %rax, %rdi
popq %rbx
jmp 0x770a
pushq $0x8
popq %rdi
callq 0x41d0
movq 0x5785(%rip), %rcx      # 0xbfb8
addq $0x10, %rcx
movq %rcx, (%rax)
movq 0x5787(%rip), %rsi      # 0xbfc8
movq 0x5760(%rip), %rdx      # 0xbfa8
movq %rax, %rdi
callq 0x4670
// File: /workspace/github_cpp_makefile_star2_O2/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 0x7627
movq 0x8(%rbx), %rdi
movl 0x18(%rbx), %esi
movl 0x1c(%rbx), %edx
popq %rbx
jmp 0x7662
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6b6c
testb %al, %al
jne 0x6af2
movq %rbx, %rdi
callq 0x6b1e
leaq 0x70(%rbx), %r14
movq %r14, %rdi
callq 0x4690
movq %rax, %r15
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x44e0
movq 0x70(%rbx), %rax
movq -0x18(%rax), %rax
movq 0x158(%rbx,%rax), %rdi
leaq 0xf(%rsp), %r8
movb $0xa, (%r8)
pushq $-0x1
popq %rcx
movl %ecx, %esi
xorl %edx, %edx
callq 0x6dd0
decl %eax
movl %eax, 0x29c(%rbx)
movq %r14, %rdi
movq %r15, %rsi
xorl %edx, %edx
callq 0x44e0
movq %rbx, %rdi
callq 0x6b4a
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6b1e
movl 0x29c(%rbx), %ebp
movq %rbx, %rdi
callq 0x6b4a
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 %rbx
movq %rdi, %rbx
callq 0x4560
cmpb $0x1, 0x2a0(%rbx)
jne 0x6b3a
movq %rbx, %rdi
callq 0x6dc4
jmp 0x6b27
movb $0x1, 0x2a0(%rbx)
movq %rbx, %rdi
popq %rbx
jmp 0x42e0
// File: /workspace/github_cpp_makefile_star2_O2/kusumi[P]procstat/buffer.cc
// Function: Buffer::signal_blocked()
void Buffer::signal_blocked(void)
{
	_mutex.lock();
	_busy = false;
	_mutex.signal();
	_mutex.unlock();
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
callq 0x4560
movb $0x0, 0x2a0(%rbx)
leaq 0x28(%rbx), %rdi
callq 0x4030
movq %rbx, %rdi
popq %rbx
jmp 0x42e0
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6b1e
leaq 0xe8(%rbx), %rdi
callq 0x40c0
movl %eax, %ebp
xorb $0x1, %bpl
movq %rbx, %rdi
callq 0x6b4a
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/kusumi[P]procstat/buffer.cc
// Function: Buffer::readline(int&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, bool&)
int Buffer::readline(int &pos, std::string &s, bool &standout)
{
	std::getline(_ifs, s);
	if (_ifs.eof() && s.empty())
		return -1;

	size_t i = 0;
	while ((i = s.find("%", i)) != std::string::npos) {
		s.insert(i, "%");
		i += 2;
	}

	if (blinkline) {
		if (_curline >= static_cast<int>(_chunk.size()))
			_chunk.resize(_chunk.size() * 2 + 1);
		standout = (!_chunk[_curline].empty() && _chunk[_curline] != s);
		_chunk[_curline] = s;
	} else {
		standout = false;
	}

	pos = _curline++;
	if (showlnum) {
		std::stringstream ss;
		ss << _curline << ' ' << s;
		s = ss.str();
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1a8, %rsp            # imm = 0x1A8
movq %rcx, %r12
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
addq $0x70, %rdi
movq %rdx, %rsi
callq 0x4090
movq 0x70(%r14), %rax
movq -0x18(%rax), %rax
testb $0x2, 0x90(%r14,%rax)
je 0x6be5
cmpq $0x0, 0x8(%rbx)
jne 0x6be5
pushq $-0x1
popq %rbp
jmp 0x6d27
xorl %ebp, %ebp
leaq 0x1a0d(%rip), %r13      # 0x85fb
movq %rbx, %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x4720
cmpq $-0x1, %rax
je 0x6c19
movq %rax, %rbp
movq %rbx, %rdi
movq %rax, %rsi
movq %r13, %rdx
callq 0x40e0
addq $0x2, %rbp
jmp 0x6bee
leaq 0x5788(%rip), %rax      # 0xc3a8
cmpb $0x1, (%rax)
jne 0x6c88
movl 0x298(%r14), %eax
movq 0x58(%r14), %rdi
movq 0x60(%r14), %rsi
subq %rdi, %rsi
movq %rsi, %rcx
shrq $0x5, %rcx
cmpl %ecx, %eax
jl 0x6c5e
leaq 0x58(%r14), %rdi
sarq $0x4, %rsi
orq $0x1, %rsi
callq 0x6d8a
movl 0x298(%r14), %eax
movq 0x58(%r14), %rdi
movslq %eax, %rcx
movq %rcx, %rax
shlq $0x5, %rax
cmpq $0x0, 0x8(%rdi,%rax)
je 0x6c8f
addq %rax, %rdi
movq %rbx, %rsi
callq 0x6dba
movslq 0x298(%r14), %rcx
movq 0x58(%r14), %rdi
jmp 0x6c91
movb $0x0, (%r12)
jmp 0x6ca7
xorl %eax, %eax
movb %al, (%r12)
shlq $0x5, %rcx
addq %rdi, %rcx
movq %rcx, %rdi
movq %rbx, %rsi
callq 0x4220
movl 0x298(%r14), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x298(%r14)
movl %eax, (%r15)
leaq 0x5746(%rip), %rax      # 0xc408
xorl %ebp, %ebp
cmpb $0x1, (%rax)
jne 0x6d27
leaq 0x20(%rsp), %rdi
callq 0x42a0
leaq 0x30(%rsp), %rdi
movl 0x298(%r14), %esi
callq 0x4680
pushq $0x20
popq %rsi
movq %rax, %rdi
callq 0x4450
movq %rax, %rdi
movq %rbx, %rsi
callq 0x4340
leaq 0x38(%rsp), %rsi
movq %rsp, %rdi
callq 0x4610
movq %rsp, %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x44b0
movq %r14, %rdi
callq 0x4738
leaq 0x20(%rsp), %rdi
callq 0x42c0
movl %ebp, %eax
addq $0x1a8, %rsp            # imm = 0x1A8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x6d3d
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x42c0
movq %rbx, %rdi
callq 0x46a0
// File: /workspace/github_cpp_makefile_star2_O2/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 0x5a26
leaq 0x143a(%rip), %rsi      # 0x8617
movq %rbx, %rdi
callq 0x773d
testb %al, %al
je 0x71f0
xorl %ebx, %ebx
jmp 0x72a3
leaq 0x1426(%rip), %rsi      # 0x861d
leaq 0x10(%rsp), %rdi
callq 0x773d
movw $0x1, %bx
testb %al, %al
jne 0x72a3
leaq 0x140d(%rip), %rsi      # 0x8621
leaq 0x10(%rsp), %rdi
callq 0x773d
movw $0x2, %bx
testb %al, %al
jne 0x72a3
leaq 0x13fa(%rip), %rsi      # 0x8627
leaq 0x10(%rsp), %rdi
callq 0x773d
movw $0x3, %bx
testb %al, %al
jne 0x72a3
leaq 0x13e8(%rip), %rsi      # 0x862e
leaq 0x10(%rsp), %rdi
callq 0x773d
movw $0x4, %bx
testb %al, %al
jne 0x72a3
leaq 0x13d4(%rip), %rsi      # 0x8633
leaq 0x10(%rsp), %rdi
callq 0x773d
movw $0x5, %bx
testb %al, %al
jne 0x72a3
leaq 0x13c3(%rip), %rsi      # 0x863b
leaq 0x10(%rsp), %rdi
callq 0x773d
movw $0x6, %bx
testb %al, %al
jne 0x72a3
leaq 0x13af(%rip), %rsi      # 0x8640
leaq 0x10(%rsp), %rdi
callq 0x773d
movzbl %al, %ebx
decl %ebx
orl $0x7, %ebx
leaq 0x10(%rsp), %rdi
callq 0x4738
movl %ebx, %eax
addq $0x30, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x4570
testq %rax, %rax
je 0x736b
movq 0x4cee(%rip), %r14      # 0xbfc0
movq (%r14), %rdi
pushq $0x1
popq %rsi
callq 0x4150
cmpl $-0x1, %eax
je 0x736f
callq 0x4410
callq 0x4120
xorl %edi, %edi
callq 0x4300
movq (%r14), %rdi
movl $0x1f4, %esi            # imm = 0x1F4
callq 0x4430
callq 0x7392
callq 0x45e0
testb %al, %al
je 0x7340
callq 0x40b0
cmpl $-0x1, %eax
je 0x7373
callq 0x4280
cmpl $-0x1, %eax
je 0x7386
movswl %bp, %esi
movswl %bx, %edx
pushq $0x1
popq %rdi
callq 0x4070
cmpl $-0x1, %eax
je 0x738a
movb $0x1, 0x51b8(%rip)      # 0xc4f8
leaq 0x12ff(%rip), %rdi      # 0x8646
callq 0x44a0
testq %rax, %rax
je 0x7364
leaq 0x11b8(%rip), %rsi      # 0x8510
movq %rax, %rdi
callq 0x4520
testl %eax, %eax
je 0x7377
movl $0x10000, %eax          # imm = 0x10000
jmp 0x737c
pushq $-0x1
jmp 0x738c
pushq $-0x2
jmp 0x738c
pushq $-0x4
jmp 0x738c
movl $0x40000, %eax          # imm = 0x40000
movl %eax, 0x517a(%rip)      # 0xc4fc
xorl %eax, %eax
jmp 0x738d
pushq $-0x5
jmp 0x738c
pushq $-0x6
popq %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x5133(%rip), %rbx      # 0xc4d0
movq %rbx, %rdi
callq 0x4560
movq 0x4c14(%rip), %r14      # 0xbfc0
movq (%r14), %rdi
callq 0x43a0
movq (%r14), %rdi
callq 0x43f0
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x42e0
// File: /workspace/github_cpp_makefile_star2_O2/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 0x50d0(%rip), %rbx      # 0xc4d0
movq %rbx, %rdi
callq 0x4560
movq 0x4b69(%rip), %rax      # 0xbf78
movl (%rax), %ebp
movq %rbx, %rdi
callq 0x42e0
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq