LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/Konano[P]Artificial-Intelligence-Input-Method/main.cpp
// Function: main
int main()
{
	ReadData();

	BuildTree();

	#ifdef __DEBUG
	puts("�������ݵ��룡");
	#endif

	ifstream fin("input.txt");
	ofstream fout("output.txt");

	string str; int tot = 0;
	while (getline(fin, str) && str != "")
	{
		printf("Now: %d\n", ++tot);
		fout << Translate(str) << endl;
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x468, %rsp            # imm = 0x468
callq 0x2a59
callq 0x2d7e
leaq 0x3852(%rip), %rdi      # 0x6050
callq 0x2270
leaq 0x3855(%rip), %rsi      # 0x605f
leaq 0x260(%rsp), %rbx
movq %rbx, %rdi
movl $0x8, %edx
callq 0x22f0
leaq 0x3843(%rip), %rsi      # 0x6069
leaq 0x60(%rsp), %rdi
movl $0x10, %edx
callq 0x2200
leaq 0x10(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x50(%rsp), %r15
movl $0x1, %ebp
movq %rsp, %r14
leaq 0x40(%rsp), %r13
movq 0x260(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21b0
movsbl %al, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2300
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x2959
movq %r14, %rdi
leaq 0x37de(%rip), %rsi      # 0x607c
callq 0x2090
testl %eax, %eax
je 0x2959
leaq 0x37c2(%rip), %rdi      # 0x6074
movl %ebp, %esi
xorl %eax, %eax
callq 0x2050
movq %r15, 0x40(%rsp)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
addq %rsi, %rdx
movq %r13, %rdi
callq 0x5338
leaq 0x20(%rsp), %rdi
movq %r13, %rsi
callq 0x2ea6
movq 0x20(%rsp), %rsi
movq 0x28(%rsp), %rdx
leaq 0x60(%rsp), %rdi
callq 0x2210
movq %rax, %r12
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r12, %rdi
movl $0xa, %esi
callq 0x21b0
movsbl %al, %esi
movq %r12, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2130
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x293b
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x21d0
movq 0x40(%rsp), %rdi
cmpq %r15, %rdi
je 0x2952
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x21d0
incl %ebp
jmp 0x285b
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x2974
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21d0
movq 0x665d(%rip), %rax      # 0x8fd8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x68(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x60(%rsp,%rcx)
callq 0x2190
leaq 0x158(%rsp), %rdi
callq 0x20b0
leaq 0x260(%rsp), %rdi
callq 0x2070
xorl %eax, %eax
addq $0x468, %rsp            # imm = 0x468
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x2a33
jmp 0x29d3
movq %rax, %rbx
jmp 0x29f7
movq %rax, %rbx
jmp 0x2a0e
movq %rax, %rbx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x29f7
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x21d0
movq 0x40(%rsp), %rdi
cmpq %r15, %rdi
je 0x2a0e
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x21d0
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x2a29
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21d0
leaq 0x60(%rsp), %rdi
callq 0x2250
leaq 0x260(%rsp), %rdi
callq 0x2070
movq %rbx, %rdi
callq 0x22d0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/main.cc
// Function: usage(char const*)
void usage(const char* message = nullptr) {
  if (message) {
    std::cerr << message << std::endl << std::endl;
  }
  std::cerr << "Usage:" << std::endl;
  std::cerr << "http-client <options> <url>" << std::endl << std::endl;
  std::cerr << "-v:       verbose mode" << std::endl;
  std::cerr << "-h:       show this help" << std::endl;
  std::cerr << "--http2:  use http/2 (https only)" << std::endl;
  std::cerr << "--keylog <filename>:  TLS keylog file" << std::endl;
  std::cerr << "-H:       add header (Ex.-H \"X-Foo: bar\")" << std::endl;
  std::cerr << "-k:       skip certificate verification" << std::endl;

  exit(1);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0xcdb3
movq %rdi, %rbx
callq 0xb2c0
movq 0x3a28c(%rip), %r14     # 0x46fe0
movq %r14, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0xb730
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %rbx, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq 0x3a226(%rip), %rbx     # 0x46fe0
leaq 0x2429b(%rip), %rsi     # 0x3105c
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
leaq 0x2428b(%rip), %rsi     # 0x31063
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
movq %rax, %rdi
callq 0xb2f0
leaq 0x24288(%rip), %rsi     # 0x3107f
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
leaq 0x24288(%rip), %rsi     # 0x31096
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
leaq 0x2428a(%rip), %rsi     # 0x310af
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
leaq 0x24295(%rip), %rsi     # 0x310d1
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
leaq 0x242a4(%rip), %rsi     # 0x310f7
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
leaq 0x242b7(%rip), %rsi     # 0x31121
movq %rbx, %rdi
callq 0xb5d0
movq %rax, %rdi
callq 0xb2f0
movl $0x1, %edi
callq 0xb7c0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/http_header.cc
// Function: create_http_header_from_header_line(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
http_header_ptr create_http_header_from_header_line(const std::string& line) {
  auto h = create_http_header_from_header_line_or_null(line);
  if (!h) {
    std::ostringstream os;
    os << "invalid format (" << line << ")";
    throw std::invalid_argument(os.str());
  }
  return h;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x198, %rsp            # imm = 0x198
movq %rsi, %r14
movq %rdi, %rbx
callq 0x20dfb
cmpq $0x0, (%rbx)
je 0x210d9
movq %rbx, %rax
addq $0x198, %rsp            # imm = 0x198
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x20(%rsp), %rdi
callq 0xb8c0
leaq 0x11cef(%rip), %rsi     # 0x32dd9
leaq 0x20(%rsp), %rdi
movl $0x10, %edx
callq 0xb730
movq (%r14), %rsi
movq 0x8(%r14), %rdx
leaq 0x20(%rsp), %rdi
callq 0xb730
leaq 0x1000e(%rip), %rsi     # 0x3111f
movl $0x1, %edx
movq %rax, %rdi
callq 0xb730
movl $0x10, %edi
callq 0xb300
movq %rax, %r14
leaq 0x28(%rsp), %rsi
movq %rsp, %rdi
callq 0xba80
movb $0x1, %bpl
movq %rsp, %rsi
movq %r14, %rdi
callq 0xbb90
xorl %ebp, %ebp
movq 0x25e69(%rip), %rsi     # 0x46fb8
movq 0x25e3a(%rip), %rdx     # 0x46f90
movq %r14, %rdi
callq 0xbb60
movq %rax, %r15
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2117c
movq 0x10(%rsp), %rsi
incq %rsi
callq 0xb600
testb %bpl, %bpl
jne 0x21186
jmp 0x21193
movq %rax, %r15
movq %r14, %rdi
callq 0xb4b0
jmp 0x21193
movq %rax, %r15
movq 0x25dc6(%rip), %rsi     # 0x46f60
leaq 0x20(%rsp), %rdi
callq 0xb380
leaq 0x90(%rsp), %rdi
callq 0xb1f0
jmp 0x211b6
movq %rax, %r15
movq $0x0, (%rbx)
movq %r15, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./string_util_trim.h
// Function: std::basic_string_view<char, std::char_traits<char>> string_util::rtrim<char, std::char_traits<char>>(std::basic_string_view<char, std::char_traits<char>> const&, char const*)
std::basic_string_view<CharT, Traits>
rtrim(const std::basic_string_view<CharT, Traits>& s, const CharT* chars) {
  using _SView = std::basic_string_view<CharT, Traits>;

  auto pos = s.find_last_not_of(chars);
  if (pos == _SView::npos) {
    return s;
  }

  return s.substr(0, pos + 1);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0xb2c0
movq %rbx, %rdi
movq %r14, %rsi
movq $-0x1, %rdx
movq %rax, %rcx
callq 0x21336
cmpq $-0x1, %rax
je 0x212be
incq %rax
movq (%rbx), %rcx
cmpq %rax, %rcx
cmovbq %rcx, %rax
jmp 0x212c1
movq (%rbx), %rax
movq 0x8(%rbx), %rdx
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./string_util_trim.h
// Function: std::basic_string_view<char, std::char_traits<char>> string_util::ltrim<char, std::char_traits<char>>(std::basic_string_view<char, std::char_traits<char>> const&, char const*)
std::basic_string_view<CharT, Traits>
ltrim(const std::basic_string_view<CharT, Traits>& s, const CharT* chars) {
  using _SView = std::basic_string_view<CharT, Traits>;

  auto pos = s.find_first_not_of(chars);
  if (pos == _SView::npos) {
    return s;
  }

  return s.substr(pos);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0xb2c0
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0x213a4
movq %rax, %rcx
movq (%rbx), %rax
cmpq $-0x1, %rcx
je 0x2130f
movq %rax, %rsi
subq %rcx, %rsi
jb 0x2131b
movq 0x8(%rbx), %rdx
addq %rcx, %rdx
movq %rsi, %rax
jmp 0x21313
movq 0x8(%rbx), %rdx
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x11ae2(%rip), %rdi     # 0x32e04
leaq 0x11ac1(%rip), %rsi     # 0x32dea
movq %rcx, %rdx
movq %rax, %rcx
xorl %eax, %eax
callq 0xba20
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./string_util_trim.h
// Function: std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> string_util::rtrim<char, std::char_traits<char>, std::allocator<char>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*)
std::basic_string<CharT, Traits, Alloc>
rtrim(const std::basic_string<CharT, Traits, Alloc>& s, const CharT* chars) {
  using _String = std::basic_string<CharT, Traits, Alloc>;

  auto pos = s.find_last_not_of(chars);
  if (pos == _String::npos) {
    return s;
  }

  return s.substr(0, pos + 1);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0xb2c0
movq %r14, %rdi
movq %r15, %rsi
movq $-0x1, %rdx
movq %rax, %rcx
callq 0xbab0
cmpq $-0x1, %rax
je 0x21455
incq %rax
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0xb660
jmp 0x2146e
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0xe500
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./string_util_trim.h
// Function: std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> string_util::ltrim<char, std::char_traits<char>, std::allocator<char>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*)
std::basic_string<CharT, Traits, Alloc>
ltrim(const std::basic_string<CharT, Traits, Alloc>& s, const CharT* chars) {
  using _String = std::basic_string<CharT, Traits, Alloc>;

  auto pos = s.find_first_not_of(chars);
  if (pos == _String::npos) {
    return s;
  }

  return s.substr(pos);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0xb2c0
movq %r14, %rdi
movq %r15, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0xbb40
cmpq $-0x1, %rax
je 0x214ba
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
movq $-0x1, %rcx
callq 0xb660
jmp 0x214d3
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0xe500
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/http_response.cc
// Function: dump(http_response const&)
void dump(const http_response& r) {
  std::cout << "HTTP Response" << std::endl;
  std::cout << "Status " << r.code_ << std::endl;
  std::cout << "Headers" << std::endl;
  for (const auto& h : r.headers_) {
    std::cout << *h << std::endl;
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x25a72(%rip), %r14     # 0x46f80
leaq 0x11920(%rip), %rsi     # 0x32e35
movl $0xd, %edx
movq %r14, %rdi
callq 0xb730
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
leaq 0x118f3(%rip), %rsi     # 0x32e43
movl $0x7, %edx
movq %r14, %rdi
callq 0xb730
movl (%rbx), %esi
movq %r14, %rdi
callq 0xb440
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r15, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
leaq 0x118b3(%rip), %rsi     # 0x32e4b
movl $0x7, %edx
movq %r14, %rdi
callq 0xb730
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq 0x8(%rbx), %r15
movq 0x10(%rbx), %r12
cmpq %r12, %r15
je 0x2161e
movq 0x259a0(%rip), %rbx     # 0x46f80
movq (%r15), %rsi
movq %rbx, %rdi
callq 0x211c5
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
addq $0x8, %r15
cmpq %r12, %r15
jne 0x215e0
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./string_util_split.h
// Function: 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>>>> string_util::split<char, std::char_traits<char>, std::allocator<char>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*)
std::vector<std::basic_string<CharT, Traits, Alloc> >
split(const std::basic_string<CharT, Traits, Alloc>& s,
      const CharT* delimiter) {
  using _String = std::basic_string<CharT, Traits, Alloc>;

  auto delimiter_size = _String(delimiter).size();
  if (delimiter_size == 0) {
    throw std::invalid_argument("empty delimiter");
  }

  std::vector<_String> results;

  typename _String::size_type pos = 0;

  while (true) {
    typename _String::size_type next = s.find(delimiter, pos);
    if (next == _String::npos) {
      results.push_back(s.substr(pos));
      break;
    }
    results.push_back(s.substr(pos, next - pos));

    pos = next + delimiter_size;
  }

  return results;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, 0x10(%rsp)
leaq 0x18(%rsp), %r12
leaq 0xf(%rsp), %rdx
movq %r12, %rdi
movq %r15, %rsi
callq 0xd9d2
movq (%r12), %rdi
movq 0x8(%r12), %rbx
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x234e3
movq 0x28(%rsp), %rsi
incq %rsi
callq 0xb600
testq %rbx, %rbx
je 0x235e4
xorps %xmm0, %xmm0
movq 0x10(%rsp), %rax
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movq %r15, %rdi
callq 0xb2c0
xorl %ebp, %ebp
movq %r14, %rdi
movq %r15, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0xbba0
cmpq $-0x1, %rax
je 0x2358e
movq %rax, %r13
xorl %ebp, %ebp
leaq 0x18(%rsp), %r12
movq %r13, %rcx
subq %rbp, %rcx
movq %r12, %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0xb660
movq 0x10(%rsp), %rdi
movq %r12, %rsi
callq 0x242ea
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x23566
movq 0x28(%rsp), %rsi
incq %rsi
callq 0xb600
movq %r13, %rbp
addq %rbx, %rbp
movq %r15, %rdi
callq 0xb2c0
movq %r14, %rdi
movq %r15, %rsi
movq %rbp, %rdx
movq %rax, %rcx
callq 0xbba0
movq %rax, %r13
cmpq $-0x1, %rax
jne 0x23529
leaq 0x18(%rsp), %rdi
movq %r14, %rsi
movq %rbp, %rdx
movq $-0x1, %rcx
callq 0xb660
leaq 0x18(%rsp), %rsi
movq 0x10(%rsp), %rdi
callq 0x242ea
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x235d0
movq 0x28(%rsp), %rsi
incq %rsi
callq 0xb600
movq 0x10(%rsp), %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %rbx
leaq 0xfb98(%rip), %rsi      # 0x33190
movq %rax, %rdi
callq 0xbcd0
movq 0x239b1(%rip), %rsi     # 0x46fb8
movq 0x23982(%rip), %rdx     # 0x46f90
movq %rbx, %rdi
callq 0xbb60
movq %rax, %r14
movq %rbx, %rdi
callq 0xb4b0
jmp 0x23655
jmp 0x2362c
jmp 0x23627
movq %rax, %r14
jmp 0x2364b
movq %rax, %r14
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x2364b
movq 0x28(%rsp), %rsi
incq %rsi
callq 0xb600
movq 0x10(%rsp), %rdi
callq 0x18772
movq %r14, %rdi
callq 0xbbb0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./http2_socket.h
// Function: void send_http2_goaway<boost::asio::ssl::stream<boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::execution::any_executor<boost::asio::execution::context_as_t<boost::asio::execution_context&>, boost::asio::execution::detail::blocking::never_t<0>, boost::asio::execution::prefer_only<boost::asio::execution::detail::blocking::possibly_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::outstanding_work::tracked_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::outstanding_work::untracked_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::relationship::fork_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::relationship::continuation_t<0>>>>>>(boost::asio::ssl::stream<boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::execution::any_executor<boost::asio::execution::context_as_t<boost::asio::execution_context&>, boost::asio::execution::detail::blocking::never_t<0>, boost::asio::execution::prefer_only<boost::asio::execution::detail::blocking::possibly_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::outstanding_work::tracked_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::outstanding_work::untracked_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::relationship::fork_t<0>>, boost::asio::execution::prefer_only<boost::asio::execution::detail::relationship::continuation_t<0>>>>>&, unsigned int)
void send_http2_goaway(SyncWriteStream& stream, uint32_t stream_id) {
  http2_frame goaway;

  auto& header = goaway.header();
  header.set_length(8);
  header.type = http2_frame_header::TYPE_GOAWAY;
  header.flags = 0x00;
  header.set_stream_id(0);

  auto& payload = goaway.payload();
  payload.resize(8);
  uint32_t value;
  value = htonl(stream_id);   // Last Stream Id
  std::memcpy(&payload[0], &value, 4);
  value = htonl(0);           // Error Code
  std::memcpy(&payload[4], &value, 4);

  write_http2_frame(stream, goaway);
}

// Assembly:
pushq %rbp
pushq %rbx
subq $0x28, %rsp
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x10(%rsp), %rdi
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movb $0x8, -0xe(%rdi)
movw $0x0, -0x10(%rdi)
movw $0x7, -0xd(%rdi)
movl $0x0, -0xb(%rdi)
movl $0x8, %esi
callq 0x23788
bswapl %ebp
movq %rsp, %rsi
movq 0x10(%rsi), %rax
movl %ebp, (%rax)
movq 0x10(%rsi), %rax
movl $0x0, 0x4(%rax)
movq %rbx, %rdi
callq 0x270ec
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x262de
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0xb600
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
jmp 0x262e7
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x26301
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0xb600
movq %rbx, %rdi
callq 0xbbb0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./http2_frame.h
// Function: http2_frame_header::set_stream_id(unsigned int)
void set_stream_id(uint32_t sid) {
    if (sid & 0x80000000) {
      throw std::invalid_argument("sid too large");
    }
    uint32_t value = htonl(sid);
    std::memcpy(psid, &value, 4);
  }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testl %esi, %esi
js 0x2703d
bswapl %esi
movl %esi, 0x5(%rdi)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %rbx
leaq 0xc3e3(%rip), %rsi      # 0x33434
movq %rax, %rdi
callq 0xbcd0
movq 0x1ff58(%rip), %rsi     # 0x46fb8
movq 0x1ff29(%rip), %rdx     # 0x46f90
movq %rbx, %rdi
callq 0xbb60
movq %rax, %r14
movq %rbx, %rdi
callq 0xb4b0
movq %r14, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./http2_frame.h
// Function: http2_frame_header::set_length(unsigned int)
void set_length(uint32_t length) {
    if (length & 0xff000000) {
      throw std::invalid_argument("length too large");
    }
    uint32_t value = htonl(length);
    std::memcpy(plength, (reinterpret_cast<uint8_t*>(&value)) + 1, 3);
  }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
cmpl $0x1000000, %esi        # imm = 0x1000000
jae 0x270a7
bswapl %esi
movl %esi, %eax
shrl $0x8, %eax
shrl $0x18, %esi
movb %sil, 0x2(%rdi)
movw %ax, (%rdi)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %rbx
leaq 0xc387(%rip), %rsi      # 0x33442
movq %rax, %rdi
callq 0xbcd0
movq 0x1feee(%rip), %rsi     # 0x46fb8
movq 0x1febf(%rip), %rdx     # 0x46f90
movq %rbx, %rdi
callq 0xbb60
movq %rax, %r14
movq %rbx, %rdi
callq 0xb4b0
movq %r14, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./hpack_encoder.h
// Function: std::vector<unsigned char, std::allocator<unsigned char>> hpack::hpack_encoder::encode<std::vector<unsigned char, std::allocator<unsigned char>>>(std::vector<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>> const&)
Container encode(const header_list& headers) {
    Container buffer;

    for (const auto& h : headers) {
      buffer.push_back(0x00);    // Literal Header Field without Indexing

      // Name Length
      encode_integer(0x00, h.first.size(), 7, buffer);

      // Name String
      std::copy(h.first.begin(), h.first.end(), std::back_inserter(buffer));

      // Value Length
      encode_integer(0x00, h.second.size(), 7, buffer);

      // Value String
      std::copy(h.second.begin(), h.second.end(), std::back_inserter(buffer));
    }

    return buffer;
  }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq (%rdx), %r13
movq 0x8(%rdx), %rax
movq %rax, 0x10(%rsp)
cmpq %rax, %r13
je 0x27d6f
leaq 0xe(%rsp), %r15
leaq 0xf(%rsp), %r12
movb $0x0, 0xd(%rsp)
movq %rbx, %rdi
leaq 0xd(%rsp), %rsi
callq 0x27f22
movl 0x8(%r13), %esi
movl $0x7, %edx
xorl %edi, %edi
movq %rbx, %rcx
callq 0x27e8d
movq 0x8(%r13), %r14
testq %r14, %r14
jle 0x27d1f
movq (%r13), %rbp
incq %r14
movb (%rbp), %al
movb %al, 0xe(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x27f22
incq %rbp
decq %r14
cmpq $0x1, %r14
ja 0x27d01
movl 0x28(%r13), %esi
movl $0x7, %edx
xorl %edi, %edi
movq %rbx, %rcx
callq 0x27e8d
movq 0x28(%r13), %r14
testq %r14, %r14
jle 0x27d60
movq 0x20(%r13), %rbp
incq %r14
movb (%rbp), %al
movb %al, 0xf(%rsp)
movq %rbx, %rdi
movq %r12, %rsi
callq 0x27f22
incq %rbp
decq %r14
cmpq $0x1, %r14
ja 0x27d42
addq $0x40, %r13
cmpq 0x10(%rsp), %r13
jne 0x27ccc
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x27d87
jmp 0x27d87
jmp 0x27d87
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x27d9e
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0xb600
movq %r14, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./hpack_encoder.h
// Function: void hpack::encode_integer<std::vector<unsigned char, std::allocator<unsigned char>>>(unsigned char, unsigned int, unsigned long, std::vector<unsigned char, std::allocator<unsigned char>>&)
void encode_integer(uint8_t src, unsigned int i, std::size_t n, Container& buffer) {
  // 2 ^ n - 1
  unsigned int mask = (1 << n) - 1;

  if (i < mask) {
    buffer.push_back((src & ~mask) + (i & mask));
  } else {
    buffer.push_back(src | mask);
    i -= mask;
    while (i >= 128) {
      buffer.push_back(i % 128 + 128);
      i /= 128;
    }
    buffer.push_back(i);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %rcx
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
shll %cl, %edx
movl %edx, %eax
notl %eax
movl %esi, %ebp
subl %eax, %ebp
jae 0x27ebe
movzbl %dil, %ecx
andl %ecx, %edx
andl %esi, %eax
orl %edx, %eax
leaq 0x7(%rsp), %rsi
movb %al, (%rsi)
jmp 0x27f0f
orb %dil, %al
leaq 0x6(%rsp), %rsi
movb %al, (%rsi)
movq %rbx, %rdi
callq 0x27f22
cmpl $0x80, %ebp
jb 0x27f04
leaq 0x4(%rsp), %r14
movl %ebp, %r15d
movl %ebp, %eax
orb $-0x80, %al
movb %al, 0x4(%rsp)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x27f22
shrl $0x7, %r15d
cmpl $0x3fff, %ebp           # imm = 0x3FFF
movl %r15d, %ebp
ja 0x27ee0
jmp 0x27f07
movl %ebp, %r15d
leaq 0x5(%rsp), %rsi
movb %r15b, (%rsi)
movq %rbx, %rdi
callq 0x27f22
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/http2_frame.cc
// Function: (anonymous namespace)::dump_headers_payload(std::vector<unsigned char, std::allocator<unsigned char>> const&, unsigned char)
void dump_headers_payload(const http2_frame::payload_type& payload, uint8_t flags) {
  auto buffer = buffer_view(&payload[0], payload.size());

  std::size_t offset = 0;

  if (flags & 0x08) {  // PADDED
    std::cout << "Pad Length: " << buffer.at(offset) << std::endl;
    offset++;
  }
  if (flags & 0x20) {  // PRIORITY
    uint32_t dependency = buffer.at_uint32(offset);
    uint8_t weight =  buffer.at_uint32(offset + 4);
    std::cout << "E: " << ((dependency & 0x80000000) ? 1 : 0) << std::endl
              << "Stream Dependency: " << (dependency & 0x7fffffff) << std::endl
              << "Weight: " << weight << std::endl;
    offset += 5;
  }
  // HEADERSは複数フレームになることがあるので、Header Block Fragmentは
  // ここでは出力できない
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movl %esi, %ebx
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
subq %rax, %rcx
movq %rax, 0x10(%rsp)
movq %rcx, 0x18(%rsp)
testb $0x8, %bl
jne 0x28a8a
xorl %r15d, %r15d
jmp 0x28af5
movq 0x1e4ef(%rip), %r14     # 0x46f80
leaq 0xabba(%rip), %rsi      # 0x33652
movl $0xc, %edx
movq %r14, %rdi
callq 0xb730
leaq 0x10(%rsp), %rdi
xorl %esi, %esi
callq 0x29306
leaq 0xf(%rsp), %rsi
movb %al, (%rsi)
movl $0x1, %r15d
movl $0x1, %edx
movq %r14, %rdi
callq 0xb730
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
testb $0x20, %bl
je 0x28c1d
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x29364
movl %eax, %r14d
orq $0x4, %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x29364
movl %eax, %ebx
movq 0x1e457(%rip), %r15     # 0x46f80
leaq 0xac60(%rip), %rsi      # 0x33790
movl $0x3, %edx
movq %r15, %rdi
callq 0xb730
movl %r14d, %esi
shrl $0x1f, %esi
movq %r15, %rdi
callq 0xbb80
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r15, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq %rax, %r15
leaq 0xaae0(%rip), %rsi      # 0x3365f
movl $0x13, %edx
movq %rax, %rdi
callq 0xb730
andl $0x7fffffff, %r14d      # imm = 0x7FFFFFFF
movq %r15, %rdi
movq %r14, %rsi
callq 0xb440
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq %rax, %r14
leaq 0xaaa1(%rip), %rsi      # 0x33673
movl $0x8, %edx
movq %rax, %rdi
callq 0xb730
leaq 0xf(%rsp), %rsi
movb %bl, (%rsi)
movl $0x1, %edx
movq %r14, %rdi
callq 0xb730
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %rbx, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./string_util_join.h
// Function: std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> string_util::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>>>>>(char const*, 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>>>> const&)
std::string join(const char* delimiter, const Container& c) {
  std::ostringstream os;
  if (!c.empty()) {
    auto last = std::prev(c.cend());
    std::copy(c.cbegin(), last, std::ostream_iterator<std::string>(os, ","));
    os << *last;
  }
  return os.str();
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x190, %rsp            # imm = 0x190
movq %rdx, %r12
movq %rdi, %rbx
leaq 0x18(%rsp), %r15
movq %r15, %rdi
callq 0xb8c0
movq (%r12), %r14
movq 0x8(%r12), %r12
cmpq %r12, %r14
je 0x2929a
movq %r15, 0x8(%rsp)
leaq 0xa3f9(%rip), %rax      # 0x33647
movq %rax, 0x10(%rsp)
movq %r12, %r13
subq %r14, %r13
addq $-0x20, %r13
sarq $0x5, %r13
testq %r13, %r13
jle 0x29286
incq %r13
leaq 0x8(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x2943a
addq $0x20, %r14
decq %r13
cmpq $0x1, %r13
ja 0x2926e
movq -0x20(%r12), %rsi
movq -0x18(%r12), %rdx
leaq 0x18(%rsp), %rdi
callq 0xb730
leaq 0x20(%rsp), %rsi
movq %rbx, %rdi
callq 0xba80
movq 0x1dcb2(%rip), %rsi     # 0x46f60
leaq 0x18(%rsp), %rdi
callq 0xb380
leaq 0x88(%rsp), %rdi
callq 0xb1f0
movq %rbx, %rax
addq $0x190, %rsp            # imm = 0x190
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x292dd
jmp 0x292dd
movq %rax, %rbx
movq 0x1dc79(%rip), %rsi     # 0x46f60
leaq 0x18(%rsp), %rdi
callq 0xb380
leaq 0x88(%rsp), %rdi
callq 0xb1f0
movq %rbx, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./buffer_view.h
// Function: buffer_view<unsigned char>::at_uint32(unsigned long) const
uint32_t at_uint32(std::size_t offset) const {
    std::size_t end = offset + 3;
    if (end < offset || end >= length_) {
      throw std::range_error("invalid offset");
    }
    uint32_t value = 0;
    memcpy(&value, buffer_ + offset, 4);
    return ntohl(value);
  }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
cmpq $-0x4, %rsi
ja 0x29388
leaq 0x3(%rsi), %rax
cmpq 0x8(%rdi), %rax
jae 0x29388
movq (%rdi), %rax
movl (%rax,%rsi), %eax
bswapl %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %rbx
leaq 0xa2e0(%rip), %rsi      # 0x3367c
movq %rax, %rdi
callq 0xbb70
movq 0x1dbed(%rip), %rsi     # 0x46f98
movq 0x1db86(%rip), %rdx     # 0x46f38
movq %rbx, %rdi
callq 0xbb60
movq %rax, %r14
movq %rbx, %rdi
callq 0xb4b0
movq %r14, %rdi
callq 0xbbb0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./buffer_view.h
// Function: buffer_view<unsigned char>::at_uint16(unsigned long) const
uint16_t at_uint16(std::size_t offset) const {
    std::size_t end = offset + 1;
    if (end < offset || end >= length_) {
      throw std::range_error("invalid offset");
    }
    uint16_t value = 0;
    memcpy(&value, buffer_ + offset, 2);
    return ntohs(value);
  }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
cmpq $-0x1, %rsi
je 0x293f5
leaq 0x1(%rsi), %rax
cmpq 0x8(%rdi), %rax
jae 0x293f5
movq (%rdi), %rax
movzwl (%rax,%rsi), %eax
rolw $0x8, %ax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %rbx
leaq 0xa273(%rip), %rsi      # 0x3367c
movq %rax, %rdi
callq 0xbb70
movq 0x1db80(%rip), %rsi     # 0x46f98
movq 0x1db19(%rip), %rdx     # 0x46f38
movq %rbx, %rdi
callq 0xbb60
movq %rax, %r14
movq %rbx, %rdi
callq 0xb4b0
movq %r14, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/hpack_decoder.cc
// Function: hpack::hpack_decoder::decode[abi:cxx11](hpack::decoding_context&)
hpack_decoder::header_list_type hpack_decoder::decode(decoding_context& context) {
  decode_pos_ = 0;

  header_list_type headers;
  while (true) {
    auto result = decode_representation(context);
    // Dynamic Table Size Updateの場合はヘッダはないが
    // result.endはfalseなので処理を続ける。
    if (result.header) {
      headers.push_back(result.header.value());
    }
    if (result.end) {
      break;
    }
  }

  return headers;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x50, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorl %eax, %eax
movq %rax, 0x10(%rsi)
movq %rax, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq %rsp, %r12
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x29584
movb 0x40(%rsp), %al
cmpb $0x1, %al
jne 0x29537
movq %rbx, %rdi
movq %r12, %rsi
callq 0x29c90
movb 0x40(%rsp), %al
movb 0x48(%rsp), %bpl
testb $0x1, %al
je 0x29548
movq %r12, %rdi
callq 0x29de4
testb %bpl, %bpl
je 0x29512
movq %rbx, %rax
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
cmpb $0x1, 0x40(%rsp)
jne 0x29574
movq %rsp, %rdi
callq 0x29de4
jmp 0x29574
movq %rax, %r14
movq %rbx, %rdi
callq 0x19a48
movq %r14, %rdi
callq 0xbbb0
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/hpack_decoder.cc
// Function: hpack::(anonymous namespace)::parse_integer_representation(buffer_view<unsigned char> const&, unsigned long, unsigned long)
std::pair<int, std::size_t>
parse_integer_representation(const buffer_view<unsigned char>& buffer, std::size_t offset, std::size_t n) {
  // 2 ^ n - 1
  int value_mask = (1 << n) - 1;

  int value = buffer.at(offset) & value_mask;
  if (value < value_mask) {
    return std::pair(value, 1);
  }

  // 全bitが立っている

  std::size_t next = offset + 1;

  int m = 0;
  while (true) {
    int octet = buffer.at(next);
    next++;

    value += (octet & 0x7f) << m;
    m += 7;

    if (!(octet & 0x80)) {
      break;
    }
  }

  return std::pair(value, next - offset);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rcx
movq %rsi, %rbx
movq %rdi, %r14
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
shll %cl, %r13d
notl %r13d
callq 0x29306
movzbl %al, %ebp
andl %r13d, %ebp
movl $0x1, %r15d
cmpl %r13d, %ebp
jne 0x298ae
xorl %r12d, %r12d
movl %r13d, %ebp
leaq (%rbx,%r15), %rsi
movq %r14, %rdi
callq 0x29306
movl %eax, %ecx
andb $0x7f, %cl
movzbl %cl, %edx
movl %r12d, %ecx
shll %cl, %edx
addl %edx, %ebp
addl $0x7, %r12d
incq %r15
testb %al, %al
js 0x29888
movl %ebp, %eax
movq %r15, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/hpack_decoder.cc
// Function: hpack::hpack_decoder::fetch_header[abi:cxx11](hpack::decoding_context const&, unsigned long)
header_type hpack_decoder::fetch_header(const decoding_context& context, std::size_t index) {
  if (index) {
    // parse value string literal

    auto h = hpack_table_at(*context.dynamic_table, index);
    if (!h) {
      throw std::runtime_error("header not found in tables.");
    }

    // Value String
    std::string value = fetch_string();

    return header_type(h.value().first, value);
  } else {
    // parse name string literal and value string literal

    // Name String
    std::string name = fetch_string();

    // Value String
    std::string value = fetch_string();

    return header_type(name, value);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x70, %rsp
movq %rsi, %r14
movq %rdi, %rbx
testq %rcx, %rcx
je 0x29b2a
movq (%rdx), %rsi
leaq 0x28(%rsp), %r15
movq %r15, %rdi
movq %rcx, %rdx
callq 0x2a323
cmpb $0x0, 0x40(%r15)
je 0x29b99
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x298c2
cmpb $0x0, 0x68(%rsp)
je 0x29bcb
leaq 0x28(%rsp), %rsi
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x29cbc
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29b17
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xb600
cmpb $0x1, 0x68(%rsp)
jne 0x29b8c
leaq 0x28(%rsp), %rdi
callq 0x29de4
jmp 0x29b8c
leaq 0x28(%rsp), %rdi
movq %r14, %rsi
callq 0x298c2
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x298c2
leaq 0x28(%rsp), %rsi
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x29cbc
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29b71
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xb600
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29b8c
movq 0x38(%rsp), %rsi
incq %rsi
callq 0xb600
movq %rbx, %rax
addq $0x70, %rsp
popq %rbx
popq %r14
popq %r15
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %r14
leaq 0x9cdd(%rip), %rsi      # 0x3388a
movq %rax, %rdi
callq 0xb270
movq 0x1d42c(%rip), %rsi     # 0x46fe8
movq 0x1d385(%rip), %rdx     # 0x46f48
movq %r14, %rdi
callq 0xbb60
callq 0x246cb
jmp 0x29c1f
movq %rax, %rbx
movq %r14, %rdi
callq 0xb4b0
jmp 0x29c42
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29c02
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xb600
jmp 0x29c02
movq %rax, %rbx
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29c53
movq 0x38(%rsp), %rsi
incq %rsi
callq 0xb600
jmp 0x29c53
movq %rax, %rbx
jmp 0x29c42
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29c42
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xb600
cmpb $0x1, 0x68(%rsp)
jne 0x29c53
leaq 0x28(%rsp), %rdi
callq 0x29de4
movq %rbx, %rdi
callq 0xbbb0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/./buffer_view.h
// Function: buffer_view<unsigned char>::subview(unsigned long, unsigned long) const
buffer_view subview(std::size_t offset, std::size_t length) const {
    std::size_t end = offset + length;
    if (end < offset || end > length_) {
      throw std::range_error("invalid offset or length");
    }
    return buffer_view(buffer_ + offset, length);
  }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rax
addq %rsi, %rax
jb 0x29d40
cmpq 0x8(%rdi), %rax
ja 0x29d40
addq (%rdi), %rsi
movq %rsi, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %rbx
leaq 0x9b6a(%rip), %rsi      # 0x338be
movq %rax, %rdi
callq 0xbb70
movq 0x1d235(%rip), %rsi     # 0x46f98
movq 0x1d1ce(%rip), %rdx     # 0x46f38
movq %rbx, %rdi
callq 0xbb60
movq %rax, %r14
movq %rbx, %rdi
callq 0xb4b0
movq %r14, %rdi
callq 0xbbb0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/hpack_table.cc
// Function: hpack::hpack_dynamic_table::dump() const
void hpack_dynamic_table::dump() const {
  std::cout << "Table Size: " << table_size() << " (Maximum:" << max_size_ << ")" << std::endl;

  auto calculated_size = calc_table_size();
  if (table_size() != calculated_size) {
    std::cout << "ERROR: Calculated Table Size mismatched (" << calculated_size << ")" << std::endl;
  }

  int i = 1;
  for (auto e = entries_.rbegin(); e != entries_.rend(); ++e) {
    std::cout << "[" << i << "] " << e->first << " " << e->second << std::endl;
    i++;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x1ce4f(%rip), %r14     # 0x46f80
leaq 0x9a53(%rip), %rsi      # 0x33b8b
movl $0xc, %edx
movq %r14, %rdi
callq 0xb730
movq 0x20(%rbx), %rsi
movq %r14, %rdi
callq 0xb440
movq %rax, %r14
leaq 0x9a3d(%rip), %rsi      # 0x33b98
movl $0xa, %edx
movq %rax, %rdi
callq 0xb730
movq 0x18(%rbx), %rsi
movq %r14, %rdi
callq 0xb440
movq %rax, %r14
leaq 0x6fa1(%rip), %rsi      # 0x3111f
movl $0x1, %edx
movq %rax, %rdi
callq 0xb730
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq (%rbx), %rax
movq 0x8(%rbx), %r12
xorl %r14d, %r14d
cmpq %r12, %rax
je 0x2a1dc
movq %rax, %rcx
addq 0x8(%rcx), %r14
movq 0x28(%rcx), %rdx
addq %rdx, %r14
addq $0x20, %r14
addq $0x40, %rcx
cmpq %r12, %rcx
jne 0x2a1c4
cmpq %r14, 0x20(%rbx)
je 0x2a24d
movq 0x1cd97(%rip), %r15     # 0x46f80
leaq 0x99b3(%rip), %rsi      # 0x33ba3
movl $0x29, %edx
movq %r15, %rdi
callq 0xb730
movq %r15, %rdi
movq %r14, %rsi
callq 0xb440
movq %rax, %r14
leaq 0x6f0d(%rip), %rsi      # 0x3111f
movl $0x1, %edx
movq %rax, %rdi
callq 0xb730
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r14, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
movq (%rbx), %rax
movq 0x8(%rbx), %r12
cmpq %rax, %r12
je 0x2a30f
movl $0x1, %ebp
movq 0x1cd1e(%rip), %r14     # 0x46f80
movl $0x1, %edx
movq %r14, %rdi
leaq 0x995c(%rip), %rsi      # 0x33bcd
callq 0xb730
movq %r14, %rdi
movl %ebp, %esi
callq 0xbb80
movq %rax, %r15
movl $0x2, %edx
movq %rax, %rdi
leaq 0x993d(%rip), %rsi      # 0x33bcf
callq 0xb730
leaq -0x40(%r12), %r13
movq -0x40(%r12), %rsi
movq -0x38(%r12), %rdx
movq %r15, %rdi
callq 0xb730
movq %rax, %r15
movl $0x1, %edx
movq %rax, %rdi
leaq 0x94d2(%rip), %rsi      # 0x33792
callq 0xb730
movq -0x20(%r12), %rsi
movq -0x18(%r12), %rdx
movq %r15, %rdi
callq 0xb730
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0xb5b0
movsbl %al, %esi
movq %r15, %rdi
callq 0xb050
movq %rax, %rdi
callq 0xb450
incl %ebp
movq %r13, %r12
cmpq (%rbx), %r13
jne 0x2a262
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/hpack_table.cc
// Function: hpack::hpack_table_at[abi:cxx11](hpack::hpack_dynamic_table const&, unsigned long)
std::optional<hpack::header_type>
hpack_table_at(const hpack_dynamic_table& dynamic_table, std::size_t index) {
  if (index == 0) {
    return std::nullopt;
  }
  if (index >= 1 && index <= hpack_static_table.size()) {
    return std::make_optional(hpack_static_table_at(index));
  }
  if (index >= hpack_static_table.size() + 1 && index <= hpack_static_table.size() + dynamic_table.size()) {
    return std::make_optional(dynamic_table.at(index - hpack_static_table.size() - 1));
  }
  return std::nullopt;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
testq %rdx, %rdx
je 0x2a369
movq 0x1d98f(%rip), %rax     # 0x47cc8
subq 0x1d980(%rip), %rax     # 0x47cc0
sarq $0x6, %rax
cmpq %rdx, %rax
jae 0x2a36f
leaq 0x1(%rax), %rcx
cmpq %rdx, %rcx
ja 0x2a369
movq 0x8(%rsi), %rcx
subq (%rsi), %rcx
sarq $0x6, %rcx
addq %rax, %rcx
cmpq %rdx, %rcx
jae 0x2a3f2
movb $0x0, 0x40(%rbx)
jmp 0x2a3e7
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movq %rdx, %rsi
callq 0x29f34
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%r14), %rcx
leaq 0x18(%rsp), %rdx
cmpq %rdx, %rcx
je 0x2a3a1
movq %rcx, (%rbx)
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rbx)
jmp 0x2a3a7
movups (%rdx), %xmm0
movups %xmm0, (%rax)
leaq 0x38(%rsp), %rax
movq -0x28(%rax), %rcx
movq %rcx, 0x8(%rbx)
leaq 0x30(%rbx), %rcx
movq %rcx, 0x20(%rbx)
movq -0x10(%rax), %rdx
cmpq %rax, %rdx
je 0x2a3d4
movq %rdx, 0x20(%rbx)
movq 0x38(%rsp), %rax
movq %rax, 0x30(%rbx)
jmp 0x2a3da
movups (%rax), %xmm0
movups %xmm0, (%rcx)
movq 0x30(%rsp), %rax
movq %rax, 0x28(%rbx)
movb $0x1, 0x40(%rbx)
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r14
retq
notq %rax
addq %rdx, %rax
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movq %rax, %rdx
callq 0x2a03a
jmp 0x2a37f
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/hpack_huffman.cc
// Function: hpack::decode_huffman(unsigned char const*, unsigned long)
std::vector<unsigned char> decode_huffman(const unsigned char* start, std::size_t length) {

  unsigned int offset = 0;
  unsigned int offset_end = length * 8;

  std::vector<unsigned char> decoded;

  auto root = treep->get_root();
  auto node = root;

  while (offset < offset_end) {
    // fetch a bit
    unsigned int bit = (start[offset >> 3] & (0x80 >> (offset & 7))) ? 1 : 0;

    if (bit) {
      if (!node->right) {
        throw std::logic_error("decode error.");
      }
      node = node->right.get();
    } else {
      if (!node->left) {
        throw std::logic_error("decode error.");
      }
      node = node->left.get();
    }
    if (node->value != -1) {
      // found
      if (node->value == 256) {
        break;
      }
      decoded.push_back(node->value);
      node = root;
    }

    offset++;
  }

  return decoded;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rdi, %rbx
shll $0x3, %r14d
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
testl %r14d, %r14d
je 0x2b137
movq %rsi, %r15
movq 0x1cc07(%rip), %rax     # 0x47ce0
movq (%rax), %r13
xorl %ebp, %ebp
leaq 0x7(%rsp), %r12
movq %r13, %rax
movl %ebp, %ecx
shrl $0x3, %ecx
movzbl (%r15,%rcx), %edx
movl %ebp, %ecx
andb $0x7, %cl
shll %cl, %edx
testb %dl, %dl
jns 0x2b106
movq 0x8(%rax), %rax
testq %rax, %rax
jne 0x2b10e
jmp 0x2b149
movq (%rax), %rax
testq %rax, %rax
je 0x2b167
movl 0x10(%rax), %ecx
cmpl $-0x1, %ecx
je 0x2b130
cmpl $0x100, %ecx            # imm = 0x100
je 0x2b137
movb %cl, 0x7(%rsp)
movq %rbx, %rdi
movq %r12, %rsi
callq 0x27f22
movq %r13, %rax
incl %ebp
cmpl %ebp, %r14d
jne 0x2b0e6
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0xb300
movq %rax, %r14
leaq 0x8a75(%rip), %rsi      # 0x33bd2
movq %rax, %rdi
callq 0xb990
jmp 0x2b183
movl $0x10, %edi
callq 0xb300
movq %rax, %r14
leaq 0x8a57(%rip), %rsi      # 0x33bd2
movq %rax, %rdi
callq 0xb990
movq 0x1be26(%rip), %rsi     # 0x46fb0
movq 0x1bddf(%rip), %rdx     # 0x46f70
movq %r14, %rdi
callq 0xbb60
jmp 0x2b19b
movq %rax, %r15
movq %r14, %rdi
callq 0xb4b0
jmp 0x2b1ad
jmp 0x2b1aa
movq %rax, %r15
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x2b1c1
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0xb600
movq %r15, %rdi
callq 0xbbb0
nop
// File: /workspace/github_cpp_makefile_star2_O3/kztomita[P]http-dump/sync_stream_wrapper.cc
// Function: ssl_stream::ssl_stream(bool, bool)
ssl_stream::ssl_stream(bool verify_cert, bool http2)
  : ssl_context_(asio::ssl::context::tlsv12_client),
    verify_cert_(verify_cert),
    host_("localhost") {

  ssl_context_.set_default_verify_paths();

  auto native_ctx = ssl_context_.native_handle();

  if (http2) {
    SSL_CTX_set_alpn_protos(native_ctx, (const unsigned char *)"\x02h2", 3);
  }

  if (g_keylog_file) {
    SSL_CTX_set_keylog_callback(native_ctx, ssl_keylog_callback);
  }

  stream_.reset(new socket_type(io_context_, ssl_context_));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %edx, %ebp
movl %esi, %r12d
movq %rdi, %r15
leaq 0x1b1a5(%rip), %rax     # 0x464a8
movq %rax, (%rdi)
leaq 0x8(%rdi), %rbx
movq %rbx, %rdi
callq 0xda10
leaq 0x18(%r15), %r14
movq %r14, %rdi
movl $0x10, %esi
callq 0x2bb12
movb %r12b, 0x30(%r15)
leaq 0x38(%r15), %r12
leaq 0x48(%r15), %rax
movq %rax, (%rsp)
movq %rax, 0x38(%r15)
leaq 0x9136(%rip), %rsi      # 0x34474
leaq 0x9138(%rip), %rdx      # 0x3447d
movq %r12, %rdi
callq 0x1025a
movq $0x0, 0x58(%r15)
addq $0x58, %r15
callq 0xb8b0
movq (%r14), %rdi
callq 0xb6e0
cmpl $0x1, %eax
je 0x2b3a1
callq 0xb890
movq %rax, %r13
movq 0x1c81e(%rip), %rax     # 0x47b98
movabsq $-0x4d54ee85da8120f3, %rcx # imm = 0xB2AB117A257EDF0D
cmpq %rcx, %rax
je 0x2b398
movabsq $-0x70502de1da3a1f65, %rcx # imm = 0x8FAFD21E25C5E09B
cmpq %rcx, %rax
jne 0x2b40a
testl %r13d, %r13d
jne 0x2b426
movq (%r14), %r13
testb %bpl, %bpl
je 0x2b3bd
leaq 0x90ce(%rip), %rsi      # 0x3447e
movq %r13, %rdi
movl $0x3, %edx
callq 0xbbc0
cmpq $0x0, 0x1c7fb(%rip)     # 0x47bc0
je 0x2b3d6
leaq 0x121(%rip), %rsi       # 0x2b4ef
movq %r13, %rdi
callq 0xba10
movl $0x1a0, %edi            # imm = 0x1A0
callq 0xb5e0
movq %rax, %rbp
movq %rax, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x2bf00
movq %r15, %rdi
movq %rbp, %rsi
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2dabe
movq 0x1c77f(%rip), %rax     # 0x47b90
leaq 0x1c778(%rip), %rdi     # 0x47b90
movl %r13d, %esi
callq *0x30(%rax)
testb %al, %al
je 0x2b3a1
leaq 0x905d(%rip), %rsi      # 0x3448a
leaq 0x8(%rsp), %rdi
callq 0xbc90
movl %r13d, %eax
btsq $0x20, %rax
leaq 0x19e9a(%rip), %rcx     # 0x452e0
leaq 0x38(%rsp), %rdx
movq %rcx, -0x30(%rdx)
movq %rax, -0x20(%rdx)
leaq 0x1c736(%rip), %rax     # 0x47b90
movq %rax, -0x18(%rdx)
movq %rdx, -0x10(%rdx)
movq $0x0, -0x8(%rdx)
movb $0x0, (%rdx)
leaq 0x8(%rsp), %rdi
callq 0xe1b4
movq %rax, %r13
leaq 0x8(%rsp), %rdi
callq 0xde38
jmp 0x2b4a7
movq %rax, %r13
movl $0x1a0, %esi            # imm = 0x1A0
movq %rbp, %rdi
callq 0xb600
jmp 0x2b4a7
movq %rax, %r13
jmp 0x2b4d7
movq %rax, %r13
jmp 0x2b4df
jmp 0x2b4a4
movq %rax, %r13
movq (%r15), %rsi
testq %rsi, %rsi
je 0x2b4b7
movq %r15, %rdi
callq 0x2da34
movq $0x0, (%r15)
movq (%r12), %rdi
cmpq (%rsp), %rdi
je 0x2b4d7
movq (%rsp), %rax
movq (%rax), %rsi
incq %rsi
callq 0xb600
movq %r14, %rdi
callq 0x22634
movq %rbx, %rdi
callq 0xdbdc
movq %r13, %rdi
callq 0xbbb0