LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: AddStone(search_game_info_t*, int, int, int)
static void
AddStone( search_game_info_t *game, const int pos, const int color, const int id )
{
  const char *board = game->board;
  string_t *string = game->string;
  string_t *add_str;
  int *string_id = game->string_id;
  int lib_add = 0;
  int other = GetOppositeColor(color);
  int neighbor, neighbor4[4];

  // IDを更新
  string_id[pos] = id;

  // 追加先の連を取り出す
  add_str = &string[id];

  // 石を追加する
  AddStoneToString(game, add_str, pos);

  // 上下左右の座標の導出
  GetNeighbor4(neighbor4, pos);

  // 空点なら呼吸点を追加し
  // 敵の石があれば隣接する敵連の情報を更新
  for (int i = 0; i < 4; i++) {
    if (board[neighbor4[i]] == S_EMPTY) {
      lib_add = AddLiberty(add_str, neighbor4[i], lib_add);
    } else if (board[neighbor4[i]] == other) {
      neighbor = string_id[neighbor4[i]];
      AddNeighbor(&string[neighbor], id);
      AddNeighbor(&string[id], neighbor);
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl %ecx, -0x14(%rbp)
movq -0x8(%rbp), %rax
addq $0x43cc, %rax           # imm = 0x43CC
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
addq $0x95f0, %rax           # imm = 0x95F0
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
addq $0x956f0, %rax          # imm = 0x956F0
movq %rax, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movl -0x10(%rbp), %edi
callq 0x25810
movl %eax, -0x40(%rbp)
movl -0x14(%rbp), %edx
movq -0x38(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movq -0x28(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x7c8, %rcx, %rcx      # imm = 0x7C8
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq -0x30(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0x99960
leaq -0x60(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x9bc90
movl $0x0, -0x64(%rbp)
cmpl $0x4, -0x64(%rbp)
jge 0x992f0
movq -0x20(%rbp), %rax
movslq -0x64(%rbp), %rcx
movslq -0x60(%rbp,%rcx,4), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x0, %eax
jne 0x99281
movq -0x30(%rbp), %rdi
movslq -0x64(%rbp), %rax
movl -0x60(%rbp,%rax,4), %esi
movl -0x3c(%rbp), %edx
callq 0x99a30
movl %eax, -0x3c(%rbp)
jmp 0x992e0
movq -0x20(%rbp), %rax
movslq -0x64(%rbp), %rcx
movslq -0x60(%rbp,%rcx,4), %rcx
movsbl (%rax,%rcx), %eax
cmpl -0x40(%rbp), %eax
jne 0x992de
movq -0x38(%rbp), %rax
movslq -0x64(%rbp), %rcx
movslq -0x60(%rbp,%rcx,4), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x44(%rbp)
movq -0x28(%rbp), %rdi
movslq -0x44(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rdi
movl -0x14(%rbp), %esi
callq 0x99ad0
movq -0x28(%rbp), %rdi
movslq -0x14(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rdi
movl -0x44(%rbp), %esi
callq 0x99ad0
jmp 0x992e0
jmp 0x992e2
movl -0x64(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x64(%rbp)
jmp 0x99248
addq $0x70, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: AddStoneToString(search_game_info_t*, string_t*, int)
static void
AddStoneToString( search_game_info_t *game, string_t *string, const int pos )
{
  int *string_next = game->string_next;
  int str_pos;

  if (pos == STRING_END) return;

  // 追加先の連の先頭の前ならば先頭に追加
  // そうでなければ挿入位置を探し出し追加
  if (string->origin > pos) {
    string_next[pos] = string->origin;
    string->origin = pos;
  } else {
    str_pos = string->origin;
    while (string_next[str_pos] < pos) {
      str_pos = string_next[str_pos];
    }
    string_next[pos] = string_next[str_pos];
    string_next[str_pos] = pos;
  }
  string->size++;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
addq $0x961d0, %rax          # imm = 0x961D0
movq %rax, -0x20(%rbp)
cmpl $0x2b7, -0x14(%rbp)     # imm = 0x2B7
jne 0x9998b
jmp 0x99a22
movq -0x10(%rbp), %rax
movl 0x7bc(%rax), %eax
cmpl -0x14(%rbp), %eax
jle 0x999be
movq -0x10(%rbp), %rax
movl 0x7bc(%rax), %edx
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x14(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x7bc(%rax)
jmp 0x99a0f
movq -0x10(%rbp), %rax
movl 0x7bc(%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %eax
cmpl -0x14(%rbp), %eax
jge 0x999eb
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x24(%rbp)
jmp 0x999cb
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x14(%rbp), %edx
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movq -0x10(%rbp), %rax
movl 0x7c0(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x7c0(%rax)
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: AddLiberty(string_t*, int, int)
static int
AddLiberty( string_t *string, const int pos, const int head )
{
  int lib;
  
  // 既に追加されている場合は何もしない
  if (string->lib[pos] != 0) return pos;

  // 探索対象の先頭のインデックスを代入
  lib = head;

  // 追加する場所を見つけるまで進める
  while (string->lib[lib] < pos) {
    lib = string->lib[lib];
  }

  // 呼吸点の座標を追加する
  string->lib[pos] = string->lib[lib];
  string->lib[lib] = (short)pos;

  // 呼吸点の数を1つ増やす
  string->libs++;

  // 追加した呼吸点の座標を返す
  return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl $0x0, %eax
je 0x99a58
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x99ac2
movl -0x18(%rbp), %eax
movl %eax, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl -0x14(%rbp), %eax
jge 0x99a82
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
movl %eax, -0x1c(%rbp)
jmp 0x99a5e
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movw 0x8(%rax,%rcx,2), %dx
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movl -0x14(%rbp), %eax
movw %ax, %dx
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw (%rax,%rax)
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: AddNeighbor(string_t*, int)
static void
AddNeighbor( string_t *string, const int id )
{
  int neighbor = 0;

  // 既に追加されている場合は何もしない
  if (string->neighbor[id] != 0) return;

  // 追加場所を見つけるまで進める
  while (string->neighbor[neighbor] < id) {
    neighbor = string->neighbor[neighbor];
  }

  // 隣接する連IDを追加する
  string->neighbor[id] = string->neighbor[neighbor];
  string->neighbor[neighbor] = (short)id;

  // 隣接する連の数を1つ増やす
  string->neighbors++;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl $0x0, -0x10(%rbp)
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl $0x0, %eax
je 0x99af9
jmp 0x99b6e
jmp 0x99afb
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl -0xc(%rbp), %eax
jge 0x99b25
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
movl %eax, -0x10(%rbp)
jmp 0x99afb
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movw 0x57c(%rax,%rcx,2), %dx
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movl -0xc(%rbp), %eax
movw %ax, %dx
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movq -0x8(%rbp), %rax
movl 0x578(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x578(%rax)
popq %rbp
retq
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: MergeString(search_game_info_t*, string_t*, string_t**, int)
static void
MergeString( search_game_info_t *game, string_t *dst, string_t *src[3], const int n )
{
  int *string_id = game->string_id;
  int id = string_id[dst->origin], rm_id;
  string_t *string = game->string;

  for (int i = 0; i < n; i++) {
    // 接続で消える連のID
    rm_id = string_id[src[i]->origin];
    // 呼吸点をマージ
    MergeLiberty(dst, src[i]);
    // 連の石の繋がりと連のIDを更新
    MergeStones(game, id, rm_id);
    // 隣接する敵連の情報をマージ
    MergeNeighbor(string, dst, src[i], id, rm_id);
    // 使用済みフラグをオフ
    src[i]->flag = false;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rax
addq $0x956f0, %rax          # imm = 0x956F0
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
movslq 0x7bc(%rcx), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x2c(%rbp)
movq -0x8(%rbp), %rax
addq $0x95f0, %rax           # imm = 0x95F0
movq %rax, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jge 0x99c4d
movq -0x28(%rbp), %rax
movq -0x18(%rbp), %rcx
movslq -0x3c(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movslq 0x7bc(%rcx), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x30(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movslq -0x3c(%rbp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x99c60
movq -0x8(%rbp), %rdi
movl -0x2c(%rbp), %esi
movl -0x30(%rbp), %edx
callq 0x99d10
movq -0x38(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rax
movslq -0x3c(%rbp), %rcx
movq (%rax,%rcx,8), %rdx
movl -0x2c(%rbp), %ecx
movl -0x30(%rbp), %r8d
callq 0x99ea0
movq -0x18(%rbp), %rax
movslq -0x3c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movb $0x0, 0x7c4(%rax)
movl -0x3c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x3c(%rbp)
jmp 0x99bbf
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: MergeLiberty(string_t*, string_t*)
static void
MergeLiberty( string_t *dst, string_t *src )
{
  int dst_lib = 0, src_lib = 0;

  while (src_lib != LIBERTY_END) {
    // 既に呼吸点に含まれていれば次の座標へ
    if (dst->lib[src_lib] == 0) {
      // 該当する場所を見つけるまで進める
      while (dst->lib[dst_lib] < src_lib) {
        dst_lib = dst->lib[dst_lib];
      }
      // 呼吸点の座標を挿入する
      dst->lib[src_lib] = dst->lib[dst_lib];
      dst->lib[dst_lib] = src_lib;
      // 呼吸点を1つ増やす
      dst->libs++;
    }
    src_lib = src->lib[src_lib];
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
movl $0x0, -0x18(%rbp)
cmpl $0x2b7, -0x18(%rbp)     # imm = 0x2B7
je 0x99d0e
movq -0x8(%rbp), %rax
movslq -0x18(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl $0x0, %eax
jne 0x99cf9
jmp 0x99c9b
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl -0x18(%rbp), %eax
jge 0x99cbf
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
movl %eax, -0x14(%rbp)
jmp 0x99c9b
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw 0x8(%rax,%rcx,2), %dx
movq -0x8(%rbp), %rax
movslq -0x18(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movl -0x18(%rbp), %eax
movw %ax, %dx
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movq -0x8(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x4(%rax)
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
movl %eax, -0x18(%rbp)
jmp 0x99c7a
popq %rbp
retq
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: MergeNeighbor(string_t*, string_t*, string_t*, int, int)
static void
MergeNeighbor( string_t *string, string_t *dst, string_t *src, const int id, const int rm_id )
{
  int src_neighbor = 0, dst_neighbor = 0;
  int neighbor = src->neighbor[0];

  while (src_neighbor != NEIGHBOR_END) {
    // 既に隣接する敵連のIDが含まれていれば次の座標へ
    if (dst->neighbor[src_neighbor] == 0) {
      // 該当する場所を見つけるまで進める
      while (dst->neighbor[dst_neighbor] < src_neighbor) {
        dst_neighbor = dst->neighbor[dst_neighbor];
      }
      // 隣接する敵連のIDを挿入する
      dst->neighbor[src_neighbor] = dst->neighbor[dst_neighbor];
      dst->neighbor[dst_neighbor] = src_neighbor;
      // 隣接する敵連の個数を1つ増やす
      dst->neighbors++;
    }
    src_neighbor = src->neighbor[src_neighbor];
  }

  // 元あった連srcに隣接する敵連の
  // 隣接情報からrm_idを除去
  while (neighbor != NEIGHBOR_END) {
    RemoveNeighborString(&string[neighbor], rm_id);
    AddNeighbor(&string[neighbor], id);
    neighbor = src->neighbor[neighbor];
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl %r8d, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movl $0x0, -0x28(%rbp)
movq -0x18(%rbp), %rax
movswl 0x57c(%rax), %eax
movl %eax, -0x2c(%rbp)
cmpl $0x11f, -0x24(%rbp)     # imm = 0x11F
je 0x99f86
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl $0x0, %eax
jne 0x99f6e
jmp 0x99efb
movq -0x10(%rbp), %rax
movslq -0x28(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl -0x24(%rbp), %eax
jge 0x99f25
movq -0x10(%rbp), %rax
movslq -0x28(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
movl %eax, -0x28(%rbp)
jmp 0x99efb
movq -0x10(%rbp), %rax
movslq -0x28(%rbp), %rcx
movw 0x57c(%rax,%rcx,2), %dx
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movl -0x24(%rbp), %eax
movw %ax, %dx
movq -0x10(%rbp), %rax
movslq -0x28(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movl 0x578(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x578(%rax)
movq -0x18(%rbp), %rax
movslq -0x24(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
movl %eax, -0x24(%rbp)
jmp 0x99ed7
jmp 0x99f88
cmpl $0x11f, -0x2c(%rbp)     # imm = 0x11F
je 0x99fda
movq -0x8(%rbp), %rdi
movslq -0x2c(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rdi
movl -0x20(%rbp), %esi
callq 0x99fe0
movq -0x8(%rbp), %rdi
movslq -0x2c(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rdi
movl -0x1c(%rbp), %esi
callq 0x99ad0
movq -0x18(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
movl %eax, -0x2c(%rbp)
jmp 0x99f88
addq $0x30, %rsp
popq %rbp
retq
// File: kobanium[P]Ray/src/board/SearchBoard.cpp
// Function: RemoveNeighborString(string_t*, int)
static void
RemoveNeighborString( string_t *string, const int id )
{
  int neighbor = 0;

  // 既に除外されていれば何もしない
  if (string->neighbor[id] == 0) return;

  // 取り除く隣接する連IDを見つけるまで進める
  while (string->neighbor[neighbor] != id) {
    neighbor = string->neighbor[neighbor];
  }

  // 隣接する連IDを取り除く
  string->neighbor[neighbor] = string->neighbor[string->neighbor[neighbor]];
  string->neighbor[id] = 0;

  // 隣接する連の数を1つ減らす
  string->neighbors--;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl $0x0, -0x10(%rbp)
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl $0x0, %eax
jne 0x9a009
jmp 0x9a087
jmp 0x9a00b
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl -0xc(%rbp), %eax
je 0x9a035
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
movl %eax, -0x10(%rbp)
jmp 0x9a00b
movq -0x8(%rbp), %rax
movq -0x8(%rbp), %rcx
movslq -0x10(%rbp), %rdx
movswq 0x57c(%rcx,%rdx,2), %rcx
movw 0x57c(%rax,%rcx,2), %dx
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movw $0x0, 0x57c(%rax,%rcx,2)
movq -0x8(%rbp), %rax
movl 0x578(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x578(%rax)
popq %rbp
retq
nopl (%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: AddLiberty(string_t*, int, int)
static int
AddLiberty( string_t *string, const int pos, const int head )
{
  int lib;

  // 既に追加されている場合は何もしない
  if (string->lib[pos] != 0) return pos;

  // 探索対象の先頭のインデックスを代入
  lib = head;

  // 追加する場所を見つけるまで進める
  while (string->lib[lib] < pos) {
    lib = string->lib[lib];
  }

  // 呼吸点の座標を追加する
  string->lib[pos] = string->lib[lib];
  string->lib[lib] = static_cast<short>(pos);

  // 呼吸点の数を1つ増やす
  string->libs++;

  // 追加した呼吸点の座標を返す
  return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl $0x0, %eax
je 0x9a408
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x9a472
movl -0x18(%rbp), %eax
movl %eax, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl -0x14(%rbp), %eax
jge 0x9a432
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
movl %eax, -0x1c(%rbp)
jmp 0x9a40e
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movw 0x8(%rax,%rcx,2), %dx
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movl -0x14(%rbp), %eax
movw %ax, %dx
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw (%rax,%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: AddNeighbor(string_t*, int, int)
static void
AddNeighbor( string_t *string, const int id, const int head )
{
  int neighbor = 0;

  // 既に追加されている場合は何もしない
  if (string->neighbor[id] != 0) return;

  // 探索対象の先頭のインデックスを代入
  neighbor = head;

  // 追加場所を見つけるまで進める
  while (string->neighbor[neighbor] < id) {
    neighbor = string->neighbor[neighbor];
  }

  // 隣接する連IDを追加する
  string->neighbor[id] = string->neighbor[neighbor];
  string->neighbor[neighbor] = static_cast<short>(id);

  // 隣接する連の数を1つ増やす
  string->neighbors++;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl $0x0, %eax
je 0x9a4ac
jmp 0x9a525
movl -0x10(%rbp), %eax
movl %eax, -0x14(%rbp)
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
cmpl -0xc(%rbp), %eax
jge 0x9a4dc
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x57c(%rax,%rcx,2), %eax
movl %eax, -0x14(%rbp)
jmp 0x9a4b2
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw 0x57c(%rax,%rcx,2), %dx
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movl -0xc(%rbp), %eax
movw %ax, %dx
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw %dx, 0x57c(%rax,%rcx,2)
movq -0x8(%rbp), %rax
movl 0x578(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x578(%rax)
popq %rbp
retq
nopw (%rax,%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: AddStone(game_info_t*, int, int, int)
void
AddStone( game_info_t *game, const int pos, const int color, const int id )
{
  const int other = GetOppositeColor(color);
  string_t *string = game->string;
  string_t *add_str;
  char *board = game->board;
  int *string_id = game->string_id;
  int lib_add = 0;
  int neighbor, neighbor4[4];

  // IDを更新
  string_id[pos] = id;

  // 追加先の連を取り出す
  add_str = &string[id];

  // 石を追加する
  AddStoneToString(game, add_str, pos, 0);

  // 上下左右の座標の導出
  GetNeighbor4(neighbor4, pos);

  // 空点なら呼吸点を追加し
  // 敵の石があれば隣接する敵連の情報を更新
  for (int i = 0; i < 4; i++) {
    if (board[neighbor4[i]] == S_EMPTY) {
      lib_add = AddLiberty(add_str, neighbor4[i], lib_add);
    } else if (board[neighbor4[i]] == other) {
      neighbor = string_id[neighbor4[i]];
      AddNeighbor(&string[neighbor], id, 0);
      AddNeighbor(&string[id], neighbor, 0);
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl %ecx, -0x14(%rbp)
movl -0x10(%rbp), %edi
callq 0x25810
movl %eax, -0x18(%rbp)
movq -0x8(%rbp), %rax
addq $0x9620, %rax           # imm = 0x9620
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
addq $0x43f8, %rax           # imm = 0x43F8
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
addq $0x95720, %rax          # imm = 0x95720
movq %rax, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movl -0x14(%rbp), %edx
movq -0x38(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x7c8, %rcx, %rcx      # imm = 0x7C8
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rdi
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
xorl %ecx, %ecx
callq 0x9a680
leaq -0x50(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x9bc90
movl $0x0, -0x54(%rbp)
cmpl $0x4, -0x54(%rbp)
jge 0x9a676
movq -0x30(%rbp), %rax
movslq -0x54(%rbp), %rcx
movslq -0x50(%rbp,%rcx,4), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x0, %eax
jne 0x9a603
movq -0x28(%rbp), %rdi
movslq -0x54(%rbp), %rax
movl -0x50(%rbp,%rax,4), %esi
movl -0x3c(%rbp), %edx
callq 0x9a3e0
movl %eax, -0x3c(%rbp)
jmp 0x9a666
movq -0x30(%rbp), %rax
movslq -0x54(%rbp), %rcx
movslq -0x50(%rbp,%rcx,4), %rcx
movsbl (%rax,%rcx), %eax
cmpl -0x18(%rbp), %eax
jne 0x9a664
movq -0x38(%rbp), %rax
movslq -0x54(%rbp), %rcx
movslq -0x50(%rbp,%rcx,4), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x40(%rbp)
movq -0x20(%rbp), %rdi
movslq -0x40(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rdi
movl -0x14(%rbp), %esi
xorl %edx, %edx
callq 0x9a480
movq -0x20(%rbp), %rdi
movslq -0x14(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rdi
movl -0x40(%rbp), %esi
xorl %edx, %edx
callq 0x9a480
jmp 0x9a666
jmp 0x9a668
movl -0x54(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
jmp 0x9a5ca
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: AddStoneToString(game_info_t*, string_t*, int, int)
static void
AddStoneToString( game_info_t *game, string_t *string, const int pos, const int head )
{
  int *string_next = game->string_next;
  int str_pos;

  if (pos == STRING_END) return;

  // 追加先の連の先頭の前ならば先頭に追加
  // そうでなければ挿入位置を探し出し追加
  if (string->origin > pos) {
    string_next[pos] = string->origin;
    string->origin = pos;
  } else {
    if (head != 0) {
      str_pos = head;
    } else {
      str_pos = string->origin;
    }
    while (string_next[str_pos] < pos){
      str_pos = string_next[str_pos];
    }
    string_next[pos] = string_next[str_pos];
    string_next[str_pos] = pos;
  }
  string->size++;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movq -0x8(%rbp), %rax
addq $0x96200, %rax          # imm = 0x96200
movq %rax, -0x20(%rbp)
cmpl $0x2b7, -0x14(%rbp)     # imm = 0x2B7
jne 0x9a6ae
jmp 0x9a755
movq -0x10(%rbp), %rax
movl 0x7bc(%rax), %eax
cmpl -0x14(%rbp), %eax
jle 0x9a6e1
movq -0x10(%rbp), %rax
movl 0x7bc(%rax), %edx
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x14(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x7bc(%rax)
jmp 0x9a742
cmpl $0x0, -0x18(%rbp)
je 0x9a6ef
movl -0x18(%rbp), %eax
movl %eax, -0x24(%rbp)
jmp 0x9a6fc
movq -0x10(%rbp), %rax
movl 0x7bc(%rax), %eax
movl %eax, -0x24(%rbp)
jmp 0x9a6fe
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %eax
cmpl -0x14(%rbp), %eax
jge 0x9a71e
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x24(%rbp)
jmp 0x9a6fe
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x14(%rbp), %edx
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movq -0x10(%rbp), %rax
movl 0x7c0(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x7c0(%rax)
popq %rbp
retq
nopw (%rax,%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: ConnectString(game_info_t*, int, int, int, int const*)
void
ConnectString( game_info_t *game, const int pos, const int color, const int connection, const int id[] )
{
  int min = id[0];
  string_t *string = game->string;
  string_t *str[3];
  int connections = 0;
  bool flag = true;

  // 接続する連の個数を厳密に確認
  for (int i = 1; i < connection; i++) {
    flag = true;
    for (int j = 0; j < i; j++) {
      if (id[j] == id[i]) {
        flag = false;
        break;
      }
    }
    if (flag) {
      if (min > id[i]) {
        str[connections] = &string[min];
        min = id[i];
      } else {
        str[connections] = &string[id[i]];
      }
      connections++;
    }
  }

  // 石を追加
  AddStone(game, pos, color, min);

  // 複数の連が接続するときの処理
  if (connections > 0) {
    MergeString(game, &game->string[min], str, connections);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl %ecx, -0x14(%rbp)
movq %r8, -0x20(%rbp)
movq -0x20(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x8(%rbp), %rax
addq $0x9620, %rax           # imm = 0x9620
movq %rax, -0x30(%rbp)
movl $0x0, -0x54(%rbp)
movb $0x1, -0x55(%rbp)
movl $0x1, -0x5c(%rbp)
movl -0x5c(%rbp), %eax
cmpl -0x14(%rbp), %eax
jge 0x9a869
movb $0x1, -0x55(%rbp)
movl $0x0, -0x60(%rbp)
movl -0x60(%rbp), %eax
cmpl -0x5c(%rbp), %eax
jge 0x9a7ec
movq -0x20(%rbp), %rax
movslq -0x60(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movq -0x20(%rbp), %rcx
movslq -0x5c(%rbp), %rdx
cmpl (%rcx,%rdx,4), %eax
jne 0x9a7df
movb $0x0, -0x55(%rbp)
jmp 0x9a7ec
jmp 0x9a7e1
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x9a7b9
testb $0x1, -0x55(%rbp)
je 0x9a859
movl -0x24(%rbp), %eax
movq -0x20(%rbp), %rcx
movslq -0x5c(%rbp), %rdx
cmpl (%rcx,%rdx,4), %eax
jle 0x9a82d
movq -0x30(%rbp), %rcx
movslq -0x24(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rcx
movslq -0x54(%rbp), %rax
movq %rcx, -0x50(%rbp,%rax,8)
movq -0x20(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x24(%rbp)
jmp 0x9a850
movq -0x30(%rbp), %rcx
movq -0x20(%rbp), %rax
movslq -0x5c(%rbp), %rdx
movslq (%rax,%rdx,4), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rcx
movslq -0x54(%rbp), %rax
movq %rcx, -0x50(%rbp,%rax,8)
movl -0x54(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
jmp 0x9a85b
movl -0x5c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x5c(%rbp)
jmp 0x9a7a2
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
movl -0x24(%rbp), %ecx
callq 0x9a530
cmpl $0x0, -0x54(%rbp)
jle 0x9a8aa
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0x9620, %rsi           # imm = 0x9620
movslq -0x24(%rbp), %rax
imulq $0x7c8, %rax, %rax      # imm = 0x7C8
addq %rax, %rsi
leaq -0x50(%rbp), %rdx
movl -0x54(%rbp), %ecx
callq 0x9a8b0
addq $0x60, %rsp
popq %rbp
retq
// File: kobanium[P]Ray/src/board/String.cpp
// Function: RemoveLiberty(game_info_t*, string_t*, int)
void
RemoveLiberty( game_info_t *game, string_t *string, const int pos )
{
  int lib = 0;

  // 既に取り除かれている場合は何もしない
  if (string->lib[pos] == 0) return;

  // 取り除く呼吸点の座標を見つけるまで進める
  while (string->lib[lib] != pos) {
    lib = string->lib[lib];
  }

  // 呼吸点の座標の情報を取り除く
  string->lib[lib] = string->lib[string->lib[lib]];
  string->lib[pos] = static_cast<short>(0);

  // 連の呼吸点の数を1つ減らす
  string->libs--;

  // 呼吸点が1つならば, その連の呼吸点を候補手に追加
  if (string->libs == 1) {
    game->candidates[string->lib[0]] = true;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl $0x0, -0x18(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl $0x0, %eax
jne 0x9aacd
jmp 0x9ab52
jmp 0x9aacf
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl -0x14(%rbp), %eax
je 0x9aaf3
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
movl %eax, -0x18(%rbp)
jmp 0x9aacf
movq -0x10(%rbp), %rax
movq -0x10(%rbp), %rcx
movslq -0x18(%rbp), %rdx
movswq 0x8(%rcx,%rdx,2), %rcx
movw 0x8(%rax,%rcx,2), %dx
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw $0x0, 0x8(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x4(%rax)
movq -0x10(%rbp), %rax
cmpl $0x1, 0x4(%rax)
jne 0x9ab52
movq -0x8(%rbp), %rax
movq -0x10(%rbp), %rcx
movswq 0x8(%rcx), %rcx
movb $0x1, 0x96ce0(%rax,%rcx)
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: PoRemoveLiberty(game_info_t*, string_t*, int, int)
void
PoRemoveLiberty( game_info_t *game, string_t *string, const int pos, const int color )
{
  int lib = 0;

  // 既に取り除かれている場合は何もしない
  if (string->lib[pos] == 0) return;

  // 取り除く呼吸点の座標を見つけるまで進める
  while (string->lib[lib] != pos) {
    lib = string->lib[lib];
  }

  // 呼吸点の座標の情報を取り除く
  string->lib[lib] = string->lib[string->lib[lib]];
  string->lib[pos] = 0;

  // 呼吸点の数を1つ減らす
  string->libs--;

  // 連の呼吸点の数を確認
  // 呼吸点が1つならば, その呼吸点を候補手に戻して, レートの更新対象に加える
  // 呼吸点が2つならば, レートの更新対象に加える
  if (string->libs == 1) {
    game->candidates[string->lib[0]] = true;
    game->update_pos[color - 1][game->update_num[color - 1]++] = string->lib[0];
    game->seki[string->lib[0]] = false;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl $0x0, %eax
jne 0x9ab90
jmp 0x9ac78
jmp 0x9ab92
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
cmpl -0x14(%rbp), %eax
je 0x9abb6
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movswl 0x8(%rax,%rcx,2), %eax
movl %eax, -0x1c(%rbp)
jmp 0x9ab92
movq -0x10(%rbp), %rax
movq -0x10(%rbp), %rcx
movslq -0x1c(%rbp), %rdx
movswq 0x8(%rcx,%rdx,2), %rcx
movw 0x8(%rax,%rcx,2), %dx
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movw %dx, 0x8(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movw $0x0, 0x8(%rax,%rcx,2)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x4(%rax)
movq -0x10(%rbp), %rax
cmpl $0x1, 0x4(%rax)
jne 0x9ac78
movq -0x8(%rbp), %rax
movq -0x10(%rbp), %rcx
movswq 0x8(%rcx), %rcx
movb $0x1, 0x96ce0(%rax,%rcx)
movq -0x10(%rbp), %rax
movswl 0x8(%rax), %edx
movq -0x8(%rbp), %rax
addq $0x99d00, %rax          # imm = 0x99D00
movl -0x18(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
imulq $0x5a4, %rcx, %rcx      # imm = 0x5A4
addq %rcx, %rax
movq -0x8(%rbp), %rsi
movl -0x18(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rdi
movl 0x99cf8(%rsi,%rdi,4), %ecx
movl %ecx, %r8d
addl $0x1, %r8d
movl %r8d, 0x99cf8(%rsi,%rdi,4)
movslq %ecx, %rcx
movl %edx, (%rax,%rcx,4)
movq -0x8(%rbp), %rax
movq -0x10(%rbp), %rcx
movswq 0x8(%rcx), %rcx
movb $0x0, 0x97029(%rax,%rcx)
popq %rbp
retq
nopw (%rax,%rax)
// File: kobanium[P]Ray/src/board/String.cpp
// Function: AddCapture(int*, int, int)
static int
AddCapture( int capture[], const int pos, const int head )
{
  int cap = head;

  if (capture[pos] != 0) return pos;

  while (capture[cap] < pos) {
    cap = capture[cap];
  }

  capture[pos] = capture[cap];
  capture[cap] = pos;

  return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movl -0x18(%rbp), %eax
movl %eax, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
cmpl $0x0, (%rax,%rcx,4)
je 0x9b02a
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x9b076
jmp 0x9b02c
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %eax
cmpl -0x14(%rbp), %eax
jge 0x9b04c
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x1c(%rbp)
jmp 0x9b02c
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x14(%rbp), %edx
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax,%rax)
// File: kobanium[P]Ray/src/board/GoBoard.cpp
// Function: SetKomi(double)
void
SetKomi( const double new_komi )
{
  default_komi = new_komi;
  komi[0] = dynamic_komi[0] = default_komi;
  komi[S_BLACK] = dynamic_komi[S_BLACK] = default_komi + 1;
  komi[S_WHITE] = dynamic_komi[S_WHITE] = default_komi - 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movsd %xmm0, -0x8(%rbp)
movsd -0x8(%rbp), %xmm0
movsd %xmm0, 0x4be32(%rip)    # 0xe7a58
movsd 0x4be2a(%rip), %xmm0    # 0xe7a58
movsd %xmm0, 0x1aae247a(%rip) # 0x1ab7e0b0
movsd %xmm0, 0x1aae2452(%rip) # 0x1ab7e090
movsd 0x103c2(%rip), %xmm0    # 0xac008
addsd 0x4be0a(%rip), %xmm0    # 0xe7a58
movsd %xmm0, 0x1aae2462(%rip) # 0x1ab7e0b8
movsd %xmm0, 0x1aae243a(%rip) # 0x1ab7e098
movsd 0x4bdf2(%rip), %xmm0    # 0xe7a58
movsd 0x1039a(%rip), %xmm1    # 0xac008
subsd %xmm1, %xmm0
movsd %xmm0, 0x1aae2446(%rip) # 0x1ab7e0c0
movsd %xmm0, 0x1aae241e(%rip) # 0x1ab7e0a0
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/GoBoard.cpp
// Function: GetNeighbor4(int*, int)
void
GetNeighbor4( int neighbor4[4], const int pos )
{
  neighbor4[0] = NORTH(pos);
  neighbor4[1] =  WEST(pos);
  neighbor4[2] =  EAST(pos);
  neighbor4[3] = SOUTH(pos);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl -0xc(%rbp), %ecx
subl 0x4bda8(%rip), %ecx     # 0xe7a4c
movq -0x8(%rbp), %rax
movl %ecx, (%rax)
movl -0xc(%rbp), %ecx
subl $0x1, %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x4(%rax)
movl -0xc(%rbp), %ecx
addl $0x1, %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x8(%rax)
movl -0xc(%rbp), %ecx
addl 0x4bd7f(%rip), %ecx     # 0xe7a4c
movq -0x8(%rbp), %rax
movl %ecx, 0xc(%rax)
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/GoBoard.cpp
// Function: InitializeNeighbor()
static void
InitializeNeighbor( void )
{
  for (int i = 0; i < PAT3_MAX; i++) {
    char empty = 0;

    if (((i >>  2) & 0x3) == S_EMPTY) empty++;
    if (((i >>  6) & 0x3) == S_EMPTY) empty++;
    if (((i >>  8) & 0x3) == S_EMPTY) empty++;
    if (((i >> 12) & 0x3) == S_EMPTY) empty++;

    nb4_empty[i] = empty;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0x0, -0x4(%rbp)
cmpl $0x10000, -0x4(%rbp)    # imm = 0x10000
jge 0x9c16f
movb $0x0, -0x5(%rbp)
movl -0x4(%rbp), %eax
sarl $0x2, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9c10e
movb -0x5(%rbp), %al
addb $0x1, %al
movb %al, -0x5(%rbp)
movl -0x4(%rbp), %eax
sarl $0x6, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9c124
movb -0x5(%rbp), %al
addb $0x1, %al
movb %al, -0x5(%rbp)
movl -0x4(%rbp), %eax
sarl $0x8, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9c13a
movb -0x5(%rbp), %al
addb $0x1, %al
movb %al, -0x5(%rbp)
movl -0x4(%rbp), %eax
sarl $0xc, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9c150
movb -0x5(%rbp), %al
addb $0x1, %al
movb %al, -0x5(%rbp)
movb -0x5(%rbp), %dl
movslq -0x4(%rbp), %rcx
leaq 0x1ab14702(%rip), %rax  # 0x1abb0860
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x9c0eb
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/GoBoard.cpp
// Function: InitializeTerritory()
static void
InitializeTerritory( void )
{
  for (int i = 0; i < PAT3_MAX; i++) {
    if ((i & 0x1144) == 0x1144) {
      territory[i] = S_BLACK;
    } else if ((i & 0x2288) == 0x2288) {
      territory[i] = S_WHITE;
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0x0, -0x4(%rbp)
cmpl $0x10000, -0x4(%rbp)    # imm = 0x10000
jge 0x9d0a1
movl -0x4(%rbp), %eax
andl $0x1144, %eax           # imm = 0x1144
cmpl $0x1144, %eax           # imm = 0x1144
jne 0x9d074
movslq -0x4(%rbp), %rcx
leaq 0x1ab037f2(%rip), %rax  # 0x1aba0860
movb $0x1, (%rax,%rcx)
jmp 0x9d094
movl -0x4(%rbp), %eax
andl $0x2288, %eax           # imm = 0x2288
cmpl $0x2288, %eax           # imm = 0x2288
jne 0x9d092
movslq -0x4(%rbp), %rcx
leaq 0x1ab037d2(%rip), %rax  # 0x1aba0860
movb $0x2, (%rax,%rcx)
jmp 0x9d094
jmp 0x9d096
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x9d04b
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/GoBoard.cpp
// Function: CalculateScore(game_info_t*)
int
CalculateScore( game_info_t *game )
{
  const char *board = game->board;
  int color;
  int scores[S_MAX] = { 0 };

  // 地の数え上げ
  for (int i = 0; i < pure_board_max; i++) {
    const int pos = onboard_pos[i];
    color = board[pos];
    if (color == S_EMPTY) color = territory[Pat3(game->pat, pos)];
    scores[color]++;
  }

  //  黒−白を返す(コミなし)
  return (scores[S_BLACK] - scores[S_WHITE]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x43f8, %rax           # imm = 0x43F8
movq %rax, -0x10(%rbp)
leaq -0x30(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x72b0
movl $0x0, -0x34(%rbp)
movl -0x34(%rbp), %eax
cmpl 0x48fe6(%rip), %eax     # 0xe7a40
jge 0x9eac1
movslq -0x34(%rbp), %rcx
leaq 0x1ab33e09(%rip), %rax  # 0x1abd2870
movl (%rax,%rcx,4), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movslq -0x38(%rbp), %rcx
movsbl (%rax,%rcx), %eax
movl %eax, -0x14(%rbp)
cmpl $0x0, -0x14(%rbp)
jne 0x9eaa7
movq -0x8(%rbp), %rdi
addq $0x4748, %rdi           # imm = 0x4748
movl -0x38(%rbp), %esi
callq 0x93d30
movl %eax, %eax
movl %eax, %ecx
leaq 0x1ab01dc0(%rip), %rax  # 0x1aba0860
movzbl (%rax,%rcx), %eax
movl %eax, -0x14(%rbp)
movslq -0x14(%rbp), %rax
movl -0x30(%rbp,%rax,4), %ecx
addl $0x1, %ecx
movl %ecx, -0x30(%rbp,%rax,4)
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x9ea51
movl -0x2c(%rbp), %eax
subl -0x28(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: kobanium[P]Ray/src/board/Point.cpp
// Function: StringToInteger(char const*)
int
StringToInteger( const char *cpos )
{
  char alphabet;
  int x, y, pos;

  if (strcmp(cpos, "pass") == 0 || 
      strcmp(cpos, "PASS") == 0){
    pos = PASS;
  } else {
    alphabet = (char)toupper(cpos[0]);
    x = 0;
    for (int i = 1; i <= pure_board_size; i++) {
      if (gogui_x[i] == alphabet) {
        x = i;
      }
    }
    y = pure_board_size - atoi(&cpos[1]) + 1;
    pos = POS(x + (OB_SIZE - 1), y + (OB_SIZE - 1));
  }

  return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
leaq 0x110e9(%rip), %rsi     # 0xaff80
callq 0x77a0
cmpl $0x0, %eax
je 0x9eeb6
movq -0x8(%rbp), %rdi
leaq 0xd275(%rip), %rsi      # 0xac121
callq 0x77a0
cmpl $0x0, %eax
jne 0x9eec2
movl $0x0, -0x18(%rbp)
jmp 0x9ef58
movq -0x8(%rbp), %rax
movsbl (%rax), %edi
callq 0x7a10
movb %al, -0x9(%rbp)
movl $0x0, -0x10(%rbp)
movl $0x1, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
leaq 0x48b5b(%rip), %rcx     # 0xe7a44
cmpl (%rcx), %eax
jg 0x9ef17
movslq -0x1c(%rbp), %rcx
leaq 0x11098(%rip), %rax     # 0xaff90
movsbl (%rax,%rcx), %eax
movsbl -0x9(%rbp), %ecx
cmpl %ecx, %eax
jne 0x9ef0a
movl -0x1c(%rbp), %eax
movl %eax, -0x10(%rbp)
jmp 0x9ef0c
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x9eedf
leaq 0x48b26(%rip), %rax     # 0xe7a44
movl (%rax), %eax
movl %eax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
addq $0x1, %rdi
callq 0x7840
movl %eax, %ecx
movl -0x20(%rbp), %eax
subl %ecx, %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
movl -0x10(%rbp), %eax
addl $0x4, %eax
movl -0x14(%rbp), %ecx
addl $0x4, %ecx
leaq 0x48afc(%rip), %rdx     # 0xe7a4c
imull (%rdx), %ecx
addl %ecx, %eax
movl %eax, -0x18(%rbp)
movl -0x18(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/Point.cpp
// Function: IntegerToString(int, char*)
void
IntegerToString( const int pos, char *cpos )
{
  int x, y;

  if (pos == PASS) {
#if defined (_WIN32)
    sprintf_s(cpos, 5, "%s", pass);
#else
    snprintf(cpos, 5, "%s", pass);
#endif
  } else if (pos == RESIGN) {
#if defined (_WIN32)
    sprintf_s(cpos, 7, "%s", resign);
#else
    snprintf(cpos, 7, "%s", resign);
#endif
  } else {
    x = X(pos) - (OB_SIZE - 1);
    y = pure_board_size - (Y(pos) - OB_SIZE);
    cpos[0] = gogui_x[x];
    if (y / 10 == 0) {
      cpos[1] = static_cast<char>('0' + y % 10);
      cpos[2] = '\0';
    } else {
      cpos[1] = static_cast<char>('0' + y / 10);
      cpos[2] = static_cast<char>('0' + y % 10);
      cpos[3] = '\0';
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
cmpl $0x0, -0x4(%rbp)
jne 0x9efa8
movq -0x10(%rbp), %rdi
movl $0x5, %esi
leaq 0xd3b5(%rip), %rdx      # 0xac34a
leaq 0x1100e(%rip), %rcx     # 0xaffaa
movb $0x0, %al
callq 0x78a0
jmp 0x9f089
cmpl $-0x1, -0x4(%rbp)
jne 0x9efd1
movq -0x10(%rbp), %rdi
movl $0x7, %esi
leaq 0xd38c(%rip), %rdx      # 0xac34a
leaq 0x10fea(%rip), %rcx     # 0xaffaf
movb $0x0, %al
callq 0x78a0
jmp 0x9f087
movl -0x4(%rbp), %eax
leaq 0x48a71(%rip), %rcx     # 0xe7a4c
cltd
idivl (%rcx)
subl $0x4, %edx
movl %edx, -0x14(%rbp)
leaq 0x48a59(%rip), %rax     # 0xe7a44
movl (%rax), %eax
movl %eax, -0x1c(%rbp)
movl -0x4(%rbp), %eax
leaq 0x48a52(%rip), %rcx     # 0xe7a4c
cltd
idivl (%rcx)
movl %eax, %ecx
movl -0x1c(%rbp), %eax
subl $0x5, %ecx
subl %ecx, %eax
movl %eax, -0x18(%rbp)
movslq -0x14(%rbp), %rcx
leaq 0x10f7b(%rip), %rax     # 0xaff90
movb (%rax,%rcx), %cl
movq -0x10(%rbp), %rax
movb %cl, (%rax)
movl -0x18(%rbp), %eax
movl $0xa, %ecx
cltd
idivl %ecx
cmpl $0x0, %eax
jne 0x9f04f
movl -0x18(%rbp), %eax
movl $0xa, %ecx
cltd
idivl %ecx
addl $0x30, %edx
movb %dl, %cl
movq -0x10(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0x10(%rbp), %rax
movb $0x0, 0x2(%rax)
jmp 0x9f085
movl -0x18(%rbp), %eax
movl $0xa, %ecx
cltd
idivl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movb %cl, 0x1(%rax)
movl -0x18(%rbp), %eax
movl $0xa, %ecx
cltd
idivl %ecx
addl $0x30, %edx
movb %dl, %cl
movq -0x10(%rbp), %rax
movb %cl, 0x2(%rax)
movq -0x10(%rbp), %rax
movb $0x0, 0x3(%rax)
jmp 0x9f087
jmp 0x9f089
addq $0x20, %rsp
popq %rbp
retq
nop
// File: kobanium[P]Ray/src/board/Point.cpp
// Function: ParsePoint[abi:cxx11](int)
std::string
ParsePoint( const int pos )
{
  if (pos == PASS) {
    return std::string(pass);
  } else if (pos == RESIGN) {
    return std::string(resign);
  } else {
    return std::string(1, GOGUI_X(pos)) + std::to_string(GOGUI_Y(pos));
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x78(%rbp)
movq %rdi, %rax
movq %rax, -0x70(%rbp)
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
cmpl $0x0, -0xc(%rbp)
jne 0x9f0fe
leaq -0xd(%rbp), %rdi
movq %rdi, -0x80(%rbp)
callq 0x79c0
movq -0x78(%rbp), %rdi
movq -0x80(%rbp), %rdx
leaq 0x10edb(%rip), %rsi     # 0xaffaa
callq 0x256b0
jmp 0x9f0d6
leaq -0xd(%rbp), %rdi
callq 0x75d0
jmp 0x9f24d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0xd(%rbp), %rdi
callq 0x75d0
jmp 0x9f25a
cmpl $-0x1, -0xc(%rbp)
jne 0x9f155
leaq -0x1d(%rbp), %rdi
movq %rdi, -0x88(%rbp)
callq 0x79c0
movq -0x78(%rbp), %rdi
movq -0x88(%rbp), %rdx
leaq 0x10e89(%rip), %rsi     # 0xaffaf
callq 0x256b0
jmp 0x9f12d
leaq -0x1d(%rbp), %rdi
callq 0x75d0
jmp 0x9f24d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0x1d(%rbp), %rdi
callq 0x75d0
jmp 0x9f25a
movl -0xc(%rbp), %eax
leaq 0x488ed(%rip), %rcx     # 0xe7a4c
movl (%rcx), %ecx
cltd
idivl %ecx
addl $-0x5, %edx
movslq %edx, %rax
leaq 0x10e1f(%rip), %rcx     # 0xaff90
movsbl 0x1(%rax,%rcx), %eax
movl %eax, -0x94(%rbp)
leaq -0x41(%rbp), %rdi
movq %rdi, -0x90(%rbp)
callq 0x79c0
movl -0x94(%rbp), %edx
movq -0x90(%rbp), %rcx
leaq -0x40(%rbp), %rdi
movl $0x1, %esi
callq 0x39eb0
jmp 0x9f1a9
leaq 0x48894(%rip), %rax     # 0xe7a44
movl (%rax), %ecx
movl -0xc(%rbp), %eax
leaq 0x48890(%rip), %rdx     # 0xe7a4c
movl (%rdx), %esi
cltd
idivl %esi
movl %eax, %edx
movl %ecx, %eax
negl %edx
movl %edx, %ecx
leal 0x5(%rax,%rcx), %esi
leaq -0x68(%rbp), %rdi
callq 0x669f0
jmp 0x9f1d8
movq -0x78(%rbp), %rdi
leaq -0x40(%rbp), %rsi
leaq -0x68(%rbp), %rdx
callq 0x66810
jmp 0x9f1eb
leaq -0x68(%rbp), %rdi
callq 0x7ae8
leaq -0x40(%rbp), %rdi
callq 0x7ae8
leaq -0x41(%rbp), %rdi
callq 0x75d0
jmp 0x9f24d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x9f242
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x9f239
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x7ae8
leaq -0x40(%rbp), %rdi
callq 0x7ae8
leaq -0x41(%rbp), %rdi
callq 0x75d0
jmp 0x9f25a
movq -0x70(%rbp), %rax
addq $0xa0, %rsp
popq %rbp
retq
movq -0x18(%rbp), %rdi
callq 0x79b0
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/Point.cpp
// Function: ParseSgfPoint[abi:cxx11](int, int)
std::string
ParseSgfPoint( const int x, const int y )
{
  std::string sgf_pos;

  if ((x ==  0 && y ==  0) ||
      (x == -1 && y == -1)) {
    sgf_pos = std::string("tt");
  } else {
    sgf_pos  = static_cast<char>(x - 1 + 'a');
    sgf_pos += static_cast<char>(y - 1 + 'a');
  }

  return sgf_pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x60(%rbp)
movq %rdi, %rax
movq %rax, -0x58(%rbp)
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movb $0x0, -0x11(%rbp)
callq 0x7770
cmpl $0x0, -0xc(%rbp)
jne 0x9f2a2
cmpl $0x0, -0x10(%rbp)
je 0x9f2ae
cmpl $-0x1, -0xc(%rbp)
jne 0x9f309
cmpl $-0x1, -0x10(%rbp)
jne 0x9f309
leaq -0x39(%rbp), %rdi
movq %rdi, -0x68(%rbp)
callq 0x79c0
movq -0x68(%rbp), %rdx
leaq 0x10cbf(%rip), %rsi     # 0xaff85
leaq -0x38(%rbp), %rdi
callq 0x256b0
jmp 0x9f2d1
movq -0x60(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x76b0
leaq -0x38(%rbp), %rdi
callq 0x7ae8
leaq -0x39(%rbp), %rdi
callq 0x75d0
jmp 0x9f341
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x39(%rbp), %rdi
callq 0x75d0
jmp 0x9f35e
movq -0x60(%rbp), %rdi
movl -0xc(%rbp), %eax
addl $0x60, %eax
movsbl %al, %esi
callq 0x78f0
jmp 0x9f31d
movq -0x60(%rbp), %rdi
movl -0x10(%rbp), %eax
addl $0x60, %eax
movsbl %al, %esi
callq 0x7320
jmp 0x9f331
jmp 0x9f341
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x9f35e
movb $0x1, -0x11(%rbp)
testb $0x1, -0x11(%rbp)
jne 0x9f354
movq -0x60(%rbp), %rdi
callq 0x7ae8
movq -0x58(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
movq -0x60(%rbp), %rdi
callq 0x7ae8
movq -0x48(%rbp), %rdi
callq 0x79b0
// File: kobanium[P]Ray/src/board/ZobristHash.cpp
// Function: SetHashSize(unsigned int)
void
SetHashSize( const unsigned int new_size )
{
  if (!(new_size & (new_size - 1))) {
    uct_hash_size = new_size;
    uct_hash_limit = new_size * 9 / 10;
  } else {
    std::cerr << "Hash size must be 2 ^ n" << std::endl;
    for (int i = 1; i <= 20; i++) {
      std::cerr << "2^" << i << ":" << (1 << i) << std::endl;
    }
    exit(1);
  }

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x4(%rbp)
movl -0x4(%rbp), %eax
movl -0x4(%rbp), %ecx
subl $0x1, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
jne 0x9f3ac
movl -0x4(%rbp), %eax
movl %eax, 0x486cc(%rip)     # 0xe7a60
imull $0x9, -0x4(%rbp), %eax
movl $0xa, %ecx
xorl %edx, %edx
divl %ecx
movl %eax, 0x486bd(%rip)     # 0xe7a64
jmp 0x9f43e
movq 0x47c3d(%rip), %rdi     # 0xe6ff0
leaq 0x10bfc(%rip), %rsi     # 0xaffb6
callq 0x7530
movq %rax, %rdi
movq 0x47b9f(%rip), %rsi     # 0xe6f68
callq 0x75b0
movl $0x1, -0x8(%rbp)
cmpl $0x14, -0x8(%rbp)
jg 0x9f434
movq 0x47c0e(%rip), %rdi     # 0xe6ff0
leaq 0x10be5(%rip), %rsi     # 0xaffce
callq 0x7530
movq %rax, %rdi
movl -0x8(%rbp), %esi
callq 0x7980
movq %rax, %rdi
leaq 0xcc93(%rip), %rsi      # 0xac096
callq 0x7530
movq %rax, %rdi
movl -0x8(%rbp), %ecx
movl $0x1, %esi
shll %cl, %esi
callq 0x7980
movq %rax, %rdi
movq 0x47b44(%rip), %rsi     # 0xe6f68
callq 0x75b0
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x9f3d5
movl $0x1, %edi
callq 0x76a0
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: kobanium[P]Ray/src/board/ZobristHash.cpp
// Function: InitializeUctHash()
void
InitializeUctHash( void )
{
  used = 0;
  enough_size = true;
  oldest_move = 1;
  
  for (unsigned int i = 0; i < uct_hash_size; i++) {
    node_hash[i].flag = false;
    node_hash[i].hash = 0;
    node_hash[i].color = 0;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0x0, 0x1c7079c6(%rip)  # 0x1c7a7214
movb $0x1, 0x1c7079bb(%rip)  # 0x1c7a7210
movl $0x1, 0x1c7079b9(%rip)  # 0x1c7a7218
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
cmpl 0x481f1(%rip), %eax     # 0xe7a60
jae 0x9f8c1
movq 0x1c707990(%rip), %rax  # 0x1c7a7208
movl -0x4(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movb $0x0, 0x10(%rax)
movq 0x1c70797b(%rip), %rax  # 0x1c7a7208
movl -0x4(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq $0x0, (%rax)
movq 0x1c707963(%rip), %rax  # 0x1c7a7208
movl -0x4(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movl $0x0, 0x8(%rax)
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x9f866
popq %rbp
retq
nopw %cs:(%rax,%rax)