LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/mh0fm4[P]SCDC/test/units/dataprov_hook/hook.c
// Function: hook_dataset_close
scdcint_t hook_dataset_close(void *dataprov, void *dataset, scdc_result_t *result)
{
  hook_dataset_t *dataset_hook = (hook_dataset_t *) dataset;


  printf("hook_dataset_close: dataprov: '%p', dataset: '%p' (%p)\n", dataprov, dataset_hook, *dataset_hook);

  free(dataset_hook);

  SCDC_RESULT_SET_STR(result, "result of hook_dataset_close");

  printf("hook_dataset_close: return '%" scdcint_fmt "', result: '%s'\n", SCDC_SUCCESS, SCDC_RESULT_STR(result));
  
  return SCDC_SUCCESS;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %rsi
movq (%r14), %rcx
leaq 0x4eab2(%rip), %rdi     # 0x5b260
movq %r14, %rdx
xorl %eax, %eax
callq 0xb080
movq %r14, %rdi
callq 0xb640
movq (%rbx), %rdx
addq $0x8, %rbx
decq %rdx
leaq 0x4eac7(%rip), %rsi     # 0x5b298
movq %rbx, %rdi
callq 0xb2a0
leaq 0x4ead5(%rip), %rdi     # 0x5b2b5
movl $0x1, %esi
movq %rbx, %rdx
xorl %eax, %eax
callq 0xb080
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/mh0fm4[P]SCDC/test/units/dataprov_hook/hook.c
// Function: hook_dataset_open_read_state
void *hook_dataset_open_read_state(void *dataprov, const void *state, scdcint_t state_size, scdc_result_t *result)
{
  hook_dataset_t *dataset_hook;


  printf("hook_dataset_open_read_state: dataprov: '%p', state: '%.*s'\n", dataprov, (int) state_size, (const char *) state);

  dataset_hook = (hook_dataset_t *) malloc(sizeof(hook_dataset_t));

  z_snscanf(state, state_size, "%p", dataset_hook);

  SCDC_RESULT_SET_STR(result, "result of hook_dataset_open_read_state");

  printf("hook_dataset_open_read_state: return: '%p' (%p), result: '%s'\n", dataset_hook, *dataset_hook, SCDC_RESULT_STR(result));

  return dataset_hook;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rsi
leaq 0x4eacf(%rip), %rdi     # 0x5b2e6
movq %r12, %rcx
xorl %eax, %eax
callq 0xb080
movl $0x8, %edi
callq 0xb6d0
movq %rax, %r14
leaq 0x4ff10(%rip), %rdx     # 0x5c745
movq %r12, %rdi
movq %r15, %rsi
movq %rax, %rcx
xorl %eax, %eax
callq 0x28a97
movq (%rbx), %rdx
addq $0x8, %rbx
decq %rdx
leaq 0x4eacd(%rip), %rsi     # 0x5b323
movq %rbx, %rdi
callq 0xb2a0
movq (%r14), %rdx
leaq 0x4eae2(%rip), %rdi     # 0x5b34a
movq %r14, %rsi
movq %rbx, %rcx
xorl %eax, %eax
callq 0xb080
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/mh0fm4[P]SCDC/test/units/dataprov_hook/hook.c
// Function: hook_dataset_close_write_state
scdcint_t hook_dataset_close_write_state(void *dataprov, void *dataset, void *state, scdcint_t state_size, scdc_result_t *result)
{
  scdcint_t n;
  hook_dataset_t *dataset_hook = (hook_dataset_t *) dataset;


  printf("hook_dataset_close_write_state: dataset: '%p' (%p)\n", dataset_hook, *dataset_hook);

  n = snprintf(state, state_size, "%p", *dataset_hook);

  free(dataset_hook);

  SCDC_RESULT_SET_STR(result, "result of hook_dataset_close_write_state");

  printf("hook_dataset_close_write_state: return: '%" scdcint_fmt "', result: '%s', state: '%.*s'\n", n, SCDC_RESULT_STR(result), (int) state_size, (const char *) state);

  return n;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %r8, %r15
movq %rcx, %r14
movq %rdx, %rbx
movq %rsi, %r12
movq (%rsi), %rdx
leaq 0x4eae6(%rip), %rdi     # 0x5b389
xorl %eax, %eax
callq 0xb080
movq (%r12), %rcx
leaq 0x4fe90(%rip), %rdx     # 0x5c745
movq %rbx, %rdi
movq %r14, %rsi
xorl %eax, %eax
callq 0xb8c0
movslq %eax, %r13
movq %r12, %rdi
callq 0xb640
movq (%r15), %rdx
addq $0x8, %r15
decq %rdx
leaq 0x4eadf(%rip), %rsi     # 0x5b3bd
movq %r15, %rdi
callq 0xb2a0
leaq 0x4eaf9(%rip), %rdi     # 0x5b3e6
movq %r13, %rsi
movq %r15, %rdx
movl %r14d, %ecx
movq %rbx, %r8
xorl %eax, %eax
callq 0xb080
movq %r13, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/mh0fm4[P]SCDC/test/units/dataprov_hook/hook.c
// Function: hook_dataset_get_next
scdcint_t hook_dataset_get_next(scdc_dataset_output_t *output, scdc_result_t *result)
{
  ptrdiff_t x;


  printf("hook_dataset_get_next: output: '%p'\n", output);
  print_dataset_output("hook_dataset_get_next: ", output);

  x = (ptrdiff_t) output->data;

  SCDC_DATASET_INOUT_BUF_CURRENT(output) = z_min(SCDC_DATASET_INOUT_BUF_SIZE(output), DEFAULT_GET_SIZE);

#if 0
  memset(SCDC_DATASET_INOUT_BUF_PTR(output), 'x', SCDC_DATASET_INOUT_BUF_CURRENT(output) - 1);
  ((char *) SCDC_DATASET_INOUT_BUF_PTR(output))[SCDC_DATASET_INOUT_BUF_CURRENT(output) - 1] = '\0';
#else
  memset(SCDC_DATASET_INOUT_BUF_PTR(output), 'x', SCDC_DATASET_INOUT_BUF_CURRENT(output));
#endif

  --x;

  output->next = (x > 0)?hook_dataset_get_next:NULL;
  output->data = (void *) x;

  return SCDC_SUCCESS;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x4eacc(%rip), %rdi     # 0x5b448
xorl %r14d, %r14d
movq %rbx, %rsi
xorl %eax, %eax
callq 0xb080
leaq 0x4eadd(%rip), %rdi     # 0x5b46d
movq %rbx, %rsi
callq 0xc93d
movq 0x40(%rbx), %r15
movq 0x10(%rbx), %rdi
movq 0x18(%rbx), %rax
cmpq $0xd, %rax
movl $0xd, %edx
cmovlq %rax, %rdx
movq %rdx, 0x20(%rbx)
movl $0x78, %esi
callq 0xb2d0
cmpq $0x2, %r15
leaq -0x5d(%rip), %rax       # 0xc96d
cmovgeq %rax, %r14
leaq -0x1(%r15), %rax
movq %r14, 0x38(%rbx)
movq %rax, 0x40(%rbx)
movl $0x1, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/mh0fm4[P]SCDC/test/units/dataprov_hook/hook.c
// Function: consume_input
static void consume_input(const char *prefix, scdc_dataset_input_t *input)
{
  while (input)
  {
    printf("%sinput content: '%.*s'\n", prefix, (int) SCDC_DATASET_INOUT_BUF_CURRENT(input), (char *) SCDC_DATASET_INOUT_BUF_PTR(input));
    if (!input->next) break;
    printf("%snext input\n", prefix);
    input->next(input, 0);
    print_dataset_input(prefix, input);
  }
}

// Assembly:
testq %rdi, %rdi
je 0xccc5
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
leaq 0x4e966(%rip), %r14     # 0x5b5c3
leaq 0x4e88a(%rip), %r15     # 0x5b4ee
leaq 0x4e971(%rip), %r12     # 0x5b5dc
leaq 0x4e7c1(%rip), %r13     # 0x5b433
movl 0x20(%rbx), %edx
movq 0x10(%rbx), %rcx
movq %r14, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0xb080
cmpq $0x0, 0x38(%rbx)
je 0xccbc
movq %r12, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0xb080
movq %rbx, %rdi
xorl %esi, %esi
callq *0x38(%rbx)
movq %r13, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0xb080
movq %rbx, %rdi
callq 0x1e93c
testq %rbx, %rbx
jne 0xcc72
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/kmyk[P]topcoder-marathon-match-100-same-color-pairs/./SameColorPairs.cpp
// Function: with_transpose(int, int, int, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&, std::function<std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>> (int, int, int, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&)>)
vector<array<int, 4> > with_transpose(int H, int W, int C, vector<vector<int> > const & original_board, function<vector<array<int, 4> > (int, int, int, vector<vector<int> > const &)> cont) {
    vector<vector<int> > board(W, vector<int>(H));
    REP (x, W) REP (y, H) {
        board[x][y] = original_board[y][x];
        if (board[x][y] < 0) board[x][y] = -1;
    }
    vector<array<int, 4> > rects = cont(W, H, C, board);
    for (auto & rect : rects) {
        swap(rect[0], rect[1]);
        swap(rect[2], rect[3]);
    }
    return rects;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r9, %r14
movq %r8, %r13
movl %ecx, %ebp
movl %edx, %r12d
movl %esi, %r15d
movq %rdi, %rbx
movslq %esi, %rsi
leaq 0x8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x42ce
movslq %r12d, %rsi
leaq 0x20(%rsp), %rdi
leaq 0x8(%rsp), %rdx
leaq 0x6(%rsp), %rcx
callq 0x4358
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x2a0c
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x2190
testl %r12d, %r12d
jle 0x2a5e
movl %r12d, %eax
movl %r15d, %ecx
xorl %edx, %edx
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
testl %r15d, %r15d
jle 0x2a56
leaq (%rdx,%rdx,2), %rdi
xorl %r8d, %r8d
movq (%r13), %r9
leaq (%r8,%r8,2), %r10
movq (%r9,%r10,8), %r9
movl (%r9,%rdx,4), %r9d
movq 0x20(%rsp), %r10
testl %r9d, %r9d
cmovsl %esi, %r9d
movq (%r10,%rdi,8), %r10
movl %r9d, (%r10,%r8,4)
incq %r8
cmpq %rcx, %r8
jne 0x2a2a
incq %rdx
cmpq %rax, %rdx
jne 0x2a1e
leaq 0x20(%rsp), %r9
movq %rbx, %rdi
movq %r14, %rsi
movl %r12d, %edx
movl %r15d, %ecx
movl %ebp, %r8d
callq 0x43f0
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
cmpq %rcx, %rax
je 0x2a92
rolq $0x20, (%rax)
rolq $0x20, 0x8(%rax)
addq $0x10, %rax
jmp 0x2a7e
leaq 0x20(%rsp), %rdi
callq 0x442c
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x442c
jmp 0x2adc
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x2adc
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x2190
jmp 0x2adc
movq %rax, %rbx
movq %rbx, %rdi
callq 0x2260
// File: /workspace/github_cpp_makefile_star2_O1/kmyk[P]topcoder-marathon-match-100-same-color-pairs/./SameColorPairs.cpp
// Function: with_landscape(int, int, int, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&, std::function<std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>> (int, int, int, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&)>)
vector<array<int, 4> > with_landscape(int H, int W, int C, vector<vector<int> > const & board, function<vector<array<int, 4> > (int, int, int, vector<vector<int> > const &)> cont) {
    if (H > W) {
        return with_transpose(H, W, C, board, cont);
    } else {
        return cont(H, W, C, board);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r8, %r14
movl %ecx, %ebp
movl %edx, %r15d
movl %esi, %r12d
movq %rdi, %rbx
cmpl %edx, %esi
jle 0x2b45
leaq 0x8(%rsp), %r13
movq %r13, %rdi
movq %r9, %rsi
callq 0x447a
movq %rbx, %rdi
movl %r12d, %esi
movl %r15d, %edx
movl %ebp, %ecx
movq %r14, %r8
movq %r13, %r9
callq 0x29ad
movq 0x18(%rsp), %rax
testq %rax, %rax
je 0x2b5c
leaq 0x8(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x2b5c
movq %rbx, %rdi
movq %r9, %rsi
movl %r12d, %edx
movl %r15d, %ecx
movl %ebp, %r8d
movq %r14, %r9
callq 0x43f0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2b94
movq %rax, %rbx
movq 0x18(%rsp), %rax
testq %rax, %rax
je 0x2b8c
leaq 0x8(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rdi
callq 0x2260
movq %rax, %rdi
callq 0x4f5f
// File: /workspace/github_cpp_makefile_star2_O1/kmyk[P]topcoder-marathon-match-100-same-color-pairs/./SameColorPairs.cpp
// Function: with_crop(int, int, int, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&, int, int, int, int, std::function<std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>> (int, int, int, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&)>)
vector<array<int, 4> > with_crop(int H, int W, int C, vector<vector<int> > const & original_board, int ly, int lx, int ry, int rx, function<vector<array<int, 4> > (int, int, int, vector<vector<int> > const &)> cont) {
    int h = ry - ly;
    int w = rx - lx;
    vector<vector<int> > board(h, vector<int>(w));
    REP (y, h) REP (x, w) {
        board[y][x] = original_board[ly + y][lx + x];
    }
    vector<array<int, 4> > rects = cont(h, w, C, board);
    for (auto & rect : rects) {
        rect[0] += ly;
        rect[1] += lx;
        rect[2] += ly;
        rect[3] += lx;
    }
    return rects;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %r9d, %ebp
movq %r8, %r13
movl %ecx, 0xc(%rsp)
movq %rdi, %rbx
movl 0x80(%rsp), %r14d
movl 0x90(%rsp), %r15d
subl %r14d, %r15d
movslq %r15d, %rsi
leaq 0x18(%rsp), %rdi
leaq 0xb(%rsp), %rdx
callq 0x42ce
movl 0x88(%rsp), %r12d
subl %ebp, %r12d
movslq %r12d, %rsi
leaq 0x30(%rsp), %rdi
leaq 0x18(%rsp), %rdx
leaq 0xa(%rsp), %rcx
callq 0x4358
movq %rbx, 0x10(%rsp)
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x2c1a
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x2190
movq 0x98(%rsp), %rsi
testl %r12d, %r12d
jle 0x2c82
movq 0x30(%rsp), %rax
movslq %r14d, %rcx
movslq %ebp, %rdx
leaq (%rdx,%rdx,2), %rdx
shlq $0x3, %rdx
addq (%r13), %rdx
movl %r12d, %edi
movl %r15d, %r8d
xorl %r9d, %r9d
shlq $0x2, %rcx
testl %r15d, %r15d
jle 0x2c7a
leaq (,%r9,8), %r10
leaq (%r10,%r10,2), %r11
movq (%rax,%r11), %r10
movq (%rdx,%r11), %r11
addq %rcx, %r11
xorl %r13d, %r13d
movl (%r11,%r13,4), %ebx
movl %ebx, (%r10,%r13,4)
incq %r13
cmpq %r13, %r8
jne 0x2c6a
incq %r9
cmpq %rdi, %r9
jne 0x2c4b
leaq 0x30(%rsp), %r9
movq 0x10(%rsp), %rbx
movq %rbx, %rdi
movl %r12d, %edx
movl %r15d, %ecx
movl 0xc(%rsp), %r8d
callq 0x43f0
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
cmpq %rcx, %rax
je 0x2cbe
addl %ebp, (%rax)
addl %r14d, 0x4(%rax)
addl %ebp, 0x8(%rax)
addl %r14d, 0xc(%rax)
addq $0x10, %rax
jmp 0x2ca6
leaq 0x30(%rsp), %rdi
callq 0x442c
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x442c
jmp 0x2d08
movq %rax, %rbx
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x2d08
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x2190
jmp 0x2d08
movq %rax, %rbx
movq %rbx, %rdi
callq 0x2260
// File: /workspace/github_cpp_makefile_star2_O1/kmyk[P]topcoder-marathon-match-100-same-color-pairs/./SameColorPairs.cpp
// Function: split_to_chunks(int, int)
vector<int> split_to_chunks(int w, int k) {
    vector<int> ws(k + 1);
    REP (i, k) {
        ws[i + 1] = w * (i + 1) / k;
    }
    return ws;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %edx, %r14d
movl %esi, %ebp
movq %rdi, %rbx
leal 0x1(%r14), %eax
movslq %eax, %rsi
leaq 0xf(%rsp), %rdx
callq 0x42ce
testl %r14d, %r14d
jle 0x2f7b
movl %r14d, %esi
movq (%rbx), %rdi
xorl %r8d, %r8d
movl %ebp, %ecx
movl %ecx, %eax
cltd
idivl %esi
movl %eax, 0x4(%rdi,%r8,4)
leaq 0x1(%r8), %rax
addl %ebp, %ecx
movq %rax, %r8
cmpq %rax, %rsi
jne 0x2f63
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/kmyk[P]topcoder-marathon-match-100-same-color-pairs/main.cpp
// Function: main
int main() {
    SameColorPairs scp;
    int H;
    cin >> H;
    vector<string> board(H);
    getVector(board);

    vector<string> ret = scp.removePairs(board);
    cout << ret.size() << endl;
    for (int i = 0; i < (int)ret.size(); ++i)
        cout << ret[i] << endl;
    cout.flush();
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq 0x9424(%rip), %rdi      # 0xcfd8
leaq 0x24(%rsp), %rbx
movq %rbx, %rsi
callq 0x20d0
movslq (%rbx), %rsi
leaq 0x40(%rsp), %rbx
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x4708
movq %rbx, %rdi
callq 0x4791
leaq 0x28(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0x4e7a
leaq 0x8(%rsp), %rdi
leaq 0x7(%rsp), %rsi
leaq 0x28(%rsp), %rdx
callq 0x47ee
leaq 0x28(%rsp), %rdi
callq 0x4f04
movq 0x10(%rsp), %rsi
subq 0x8(%rsp), %rsi
sarq $0x5, %rsi
movq 0x93a8(%rip), %rdi      # 0xcfc8
callq 0x20f0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x2170
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2100
movq 0x8(%rsp), %rax
movq 0x10(%rsp), %rcx
subq %rax, %rcx
shrq $0x5, %rcx
testl %ecx, %ecx
jle 0x3ccf
movl $0x8, %r15d
xorl %r12d, %r12d
movq 0x9354(%rip), %rbx      # 0xcfc8
movq -0x8(%rax,%r15), %rsi
movq (%rax,%r15), %rdx
movq %rbx, %rdi
callq 0x21a0
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2170
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2100
incq %r12
movq 0x8(%rsp), %rax
movq 0x10(%rsp), %rcx
subq %rax, %rcx
shrq $0x5, %rcx
movslq %ecx, %rcx
addq $0x20, %r15
cmpq %rcx, %r12
jl 0x3c74
movq 0x92f2(%rip), %rdi      # 0xcfc8
callq 0x2100
leaq 0x8(%rsp), %rdi
callq 0x4f04
leaq 0x40(%rsp), %rdi
callq 0x4f04
xorl %eax, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
jmp 0x3d18
jmp 0x3d09
movq %rax, %rbx
jmp 0x3d1d
jmp 0x3d10
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x4f04
leaq 0x40(%rsp), %rdi
callq 0x4f04
movq %rbx, %rdi
callq 0x2260
nop
// File: /workspace/github_cpp_makefile_star2_O1/kmyk[P]topcoder-marathon-match-100-same-color-pairs/./SameColorPairs.cpp
// Function: _gnu_cxx::__normal_iterator<std::array<int, 4ul>*, std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>>> apply_unreliable_rects<__gnu_cxx::__normal_iterator<std::array<int, 4ul>*, std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>>>>(int, std::array<signed char, 10000ul>&, __gnu_cxx::__normal_iterator<std::array<int, 4ul>*, std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>>>, __gnu_cxx::__normal_iterator<std::array<int, 4ul>*, std::vector<std::array<int, 4ul>, std::allocator<std::array<int, 4ul>>>>)
InputIterator apply_unreliable_rects(int W, array<int8_t, MAX_H * MAX_W> & board, InputIterator first, InputIterator last) {
    InputIterator it = first;
    for (; first != last; ++ first) {
        int y1 = (*first)[0];
        int x1 = (*first)[1];
        int y2 = (*first)[2];
        int x2 = (*first)[3];
        // assume all conditions except is_valid_pair()
        if (not is_valid_pair(W, board, make_pair(y1, x1), make_pair(y2, x2))) continue;
        board[y1 * W + x1] = -1;
        board[y2 * W + x2] = -1;
        *(it ++) = *first;
    }
    return it;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, 0x8(%rsp)
cmpq %rcx, %rdx
movq %rdx, (%rsp)
je 0x7293
movq %rsi, %rbp
movl %edi, %r13d
movq %rdx, %rbx
movl (%rbx), %r14d
movl 0x4(%rbx), %r15d
movl 0x8(%rbx), %r12d
movl 0xc(%rbx), %ecx
movq %r15, %rax
shlq $0x20, %rax
orq %r14, %rax
movq %rax, 0x20(%rsp)
movq %rcx, 0x10(%rsp)
movq %rcx, %rax
shlq $0x20, %rax
orq %r12, %rax
movq %rax, 0x18(%rsp)
movl %r13d, %edi
movq %rbp, %rsi
leaq 0x20(%rsp), %rdx
leaq 0x18(%rsp), %rcx
callq 0x2eb7
testb %al, %al
je 0x7284
imull %r13d, %r14d
addl %r15d, %r14d
movslq %r14d, %rax
movb $-0x1, %cl
movb %cl, (%rbp,%rax)
imull %r13d, %r12d
addl 0x10(%rsp), %r12d
movslq %r12d, %rax
movb %cl, (%rbp,%rax)
movups (%rbx), %xmm0
movq (%rsp), %rax
movups %xmm0, (%rax)
addq $0x10, %rax
movq %rax, (%rsp)
addq $0x10, %rbx
cmpq 0x8(%rsp), %rbx
jne 0x7208
movq (%rsp), %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/memmem.cpp
// Function: memmem_arlib(void const*, unsigned long, void const*, unsigned long)
void* memmem_arlib(const void * haystack, size_t haystacklen, const void * needle, size_t needlelen)
{
	if (UNLIKELY(needlelen == 0)) return (void*)haystack;
	
	const void * hay_orig = haystack;
	haystack = memchr(haystack, *(uint8_t*)needle, haystacklen);
	if (!haystack) return NULL;
	if (needlelen == 1) return (void*)haystack;
	
	haystacklen -= (uint8_t*)haystack - (uint8_t*)hay_orig;
	if (UNLIKELY(needlelen > haystacklen)) return NULL;
	
#ifdef runtime__SSE4_2__
	// don't use this for needle length 16, both do one byte per iteration and _mm_cmpestri is slow
	if (needlelen <= 15 && runtime__SSE4_2__) return (void*)memmem_sse42((uint8_t*)haystack, haystacklen, (uint8_t*)needle, needlelen);
#endif
	
#if !defined(_WIN32) && !defined(ARLIB_TEST) // for long needles, use libc; we're roughly equally fast, and code reuse means smaller
	return memmem(haystack, haystacklen, needle, needlelen);
#endif
	
	return (void*)memmem_rollhash((uint8_t*)haystack, haystacklen, (uint8_t*)needle, needlelen);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
testq %rcx, %rcx
je 0x3bc4
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movzbl (%rdx), %esi
movq %rbx, %rdi
movq %r12, %rdx
callq 0x33b0
testq %rax, %rax
je 0x3bc2
cmpq $0x1, %r14
jne 0x3b88
movq %rax, %rbx
jmp 0x3bc4
subq %rax, %rbx
addq %r12, %rbx
cmpq %r14, %rbx
jb 0x3bc2
cmpq $0xf, %r14
ja 0x3ba6
leaq 0x42734(%rip), %rcx     # 0x462d4
testb $0x10, 0x2(%rcx)
jne 0x3bd3
movq %rax, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movq %r14, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x3620
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movq %r14, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x15638
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/string.h
// Function: fromstring_float(cstring, double&, floatinf const*) (.cold.1)
forceinline bool operator==(const cstring& left, const char * right)
{
	size_t len = strlen(right);
	if (__builtin_constant_p(len))
	{
		if (len <= cstring::max_inline())
			return ((uint8_t)left.m_inline_len() == (cstring::max_inline()^len) && memeq(left.m_inline, right, len));
		else
			return (!left.inlined() && left.m_len == len && memeq(left.m_data, right, len));
	}
	else return left.bytes() == arrayview<uint8_t>((uint8_t*)right, len);
}

// Assembly:
cmpb $0xb, %dil
je 0x3d38
movzbl %dil, %eax
cmpl $0xc, %eax
jne 0x3d65
movl $0x6e69, %r8d           # imm = 0x6E69
xorl (%rsi), %r8d
movzbl 0x2(%rsi), %r9d
xorl $0x66, %r9d
orw %r8w, %r9w
je 0x3d69
cmpb $0xc, %dil
je 0x3d52
cmpl $0xb, %eax
jne 0x3d65
cmpl $0x666e692d, (%rsi)     # imm = 0x666E692D
jne 0x3d4c
movabsq $-0x10000000000000, %rax # imm = 0xFFF0000000000000
jmp 0x3d7f
cmpb $0xc, %dil
jne 0x3d65
movl $0x616e, %eax           # imm = 0x616E
xorl (%rsi), %eax
movzbl 0x2(%rsi), %esi
xorl $0x6e, %esi
orw %ax, %si
je 0x3d75
xorl %eax, %eax
jmp 0x3d84
movabsq $0x7ff0000000000000, %rax # imm = 0x7FF0000000000000
jmp 0x3d7f
movabsq $0x7ff8000000000000, %rax # imm = 0x7FF8000000000000
movq %rax, (%rdx)
movb $0x1, %al
movb %al, (%rcx)
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/stringconv.cpp
// Function: bool fromstring_int_inner<unsigned long>(char const*, char const*, unsigned long&)
bool fromstring_int_inner(const char * in, const char * end, Tu& out)
{
	out = 0;
	if (UNLIKELY(in == end)) return false;
	Tu t_max = (Tu)-1;
	while (in != end)
	{
		if (LIKELY(*in >= '0' && *in <= '9'))
		{
			if (UNLIKELY(out >= t_max/10))
			{
				if (out > t_max/10) return false;
				if (*in > (char)(t_max%10+'0')) return false;
			}
			out = out*10 + *in-'0';
		}
		else return false;
		in++;
	}
	return true;
}

// Assembly:
andq $0x0, (%rdx)
cmpq %rsi, %rdi
je 0x3fdd
movabsq $0x1999999999999998, %rcx # imm = 0x1999999999999998
movq (%rdx), %r8
leaq 0x1(%rcx), %r9
movzbl (%rdi), %r10d
leal -0x30(%r10), %eax
cmpb $0x9, %al
ja 0x3fdd
cmpq %rcx, %r8
ja 0x3fce
imulq $0xa, %r8, %rax
leaq (%r10,%rax), %r8
addq $-0x30, %r8
movq %r8, (%rdx)
incq %rdi
cmpq %rsi, %rdi
sete %al
jne 0x3fa1
jmp 0x3fdf
xorl %eax, %eax
cmpb $0x35, %r10b
jg 0x3fdf
cmpq %r9, %r8
je 0x3fb2
jmp 0x3fdf
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/stringconv.cpp
// Function: bool fromstring_int_real<unsigned long, long>(cstring, long&)
bool fromstring_int_real(cstring s, Ts& out)
{
	out = 0;
	const char * start = (char*)s.bytes().ptr();
	const char * end = start + s.length();
	
	if (UNLIKELY(start == end)) return false;
	bool neg = (*start == '-');
	start += neg;
	Tu tmp;
	
	if (UNLIKELY(!fromstring_int_inner<Tu>(start, end, tmp))) return false;
	
	if (neg)
	{
		out = (Ts)-tmp;
		return (out <= 0);
	}
	else
	{
		out = (Ts)tmp;
		return (out >= 0);
	}
}

// Assembly:
pushq %rbx
movq %rdi, -0x10(%rsp)
movq %rsi, -0x8(%rsp)
andq $0x0, (%rdx)
movzbl -0x1(%rsp), %eax
testb %al, %al
jns 0x3ffe
movl -0x8(%rsp), %ecx
jmp 0x4003
movl %eax, %ecx
xorl $0xf, %ecx
testl %ecx, %ecx
je 0x409b
testb %al, %al
leaq -0x10(%rsp), %rax
cmovnsq %rax, %rdi
movl %ecx, %esi
movb (%rdi), %al
xorl %r8d, %r8d
cmpb $0x2d, %al
sete %r8b
cmpq %rsi, %r8
je 0x4074
movabsq $0x1999999999999998, %r9 # imm = 0x1999999999999998
xorl %ecx, %ecx
leaq 0x1(%r9), %r10
movzbl (%rdi,%r8), %ebx
leal -0x30(%rbx), %r11d
cmpb $0x9, %r11b
ja 0x4076
cmpq %r9, %rcx
ja 0x4065
imulq $0xa, %rcx, %rcx
addq %rbx, %rcx
addq $-0x30, %rcx
incq %r8
cmpq %r8, %rsi
sete %r11b
jne 0x4038
jmp 0x4079
xorl %r11d, %r11d
cmpq %r10, %rcx
jne 0x4079
cmpb $0x35, %bl
jle 0x404c
jmp 0x4079
xorl %ecx, %ecx
xorl %r11d, %r11d
testb %r11b, %r11b
je 0x409b
cmpb $0x2d, %al
jne 0x4090
negq %rcx
movq %rcx, (%rdx)
testq %rcx, %rcx
setle %al
jmp 0x4099
movq %rcx, (%rdx)
testq %rcx, %rcx
setns %al
popq %rbx
retq
xorl %eax, %eax
jmp 0x4099
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/stringconv.cpp
// Function: bool fromstring_hex_real<unsigned long>(char const*, unsigned long, unsigned long&)
bool fromstring_hex_real(const char * s, size_t len, Tu& out)
{
	const char * start = s;
	const char * end = s + len;
	
	out = 0;
	if (UNLIKELY(start == end)) return false;
	while (start < end && *start == '0') start++;
	if (UNLIKELY(end-start > (ptrdiff_t)sizeof(Tu)*2)) return false;
	
	while (start != end)
	{
		out <<= 4;
		char upper = *start & ~0x20;
		if (*start >= '0' && *start <= '9') out += *start-'0';
		else if (upper >= 'A' && upper <= 'F') out += upper-'A'+10;
		else return false;
		start++;
	}
	return true;
}

// Assembly:
leaq (%rdi,%rsi), %rcx
andq $0x0, (%rdx)
testq %rsi, %rsi
je 0x4123
jle 0x40bb
cmpb $0x30, (%rdi)
jne 0x40bb
incq %rdi
cmpq %rcx, %rdi
jb 0x40ae
movq %rcx, %rax
subq %rdi, %rax
cmpq $0x10, %rax
jg 0x4123
movq (%rdx), %rsi
cmpq %rcx, %rdi
sete %al
je 0x4122
shlq $0x4, %rsi
movq %rsi, (%rdx)
movb (%rdi), %r8b
leal -0x30(%r8), %r9d
cmpb $0x9, %r9b
ja 0x40ef
movzbl %r9b, %r8d
orq %r8, %rsi
jmp 0x410f
movl %r8d, %r9d
andb $-0x21, %r9b
addb $-0x41, %r9b
cmpb $0x5, %r9b
ja 0x411a
addb $0x9, %r8b
andb $0x1f, %r8b
movzbl %r8b, %r8d
addq %r8, %rsi
movq %rsi, (%rdx)
incq %rdi
movb $0x1, %r8b
jmp 0x411d
xorl %r8d, %r8d
testb %r8b, %r8b
jne 0x40ca
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/argparse.cpp
// Function: argparse::single_arg(cstring, char const*, argparse::arglevel_t, bool*)
void argparse::single_arg(cstring name, const char * value, arglevel_t arglevel, bool* used_value)
{
	for (arg_base& arg : m_args)
	{
		if (arg.name == name)
		{
			single_arg(arg, value, arglevel, used_value);
			return;
		}
	}
	if (name != "") error("unknown argument: --"+name);
	else error("positional arguments not supported");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %r9, 0x30(%rsp)
movl %r8d, 0x14(%rsp)
movq %rcx, 0x28(%rsp)
movq %rsi, 0x18(%rsp)
movq %rdx, 0x20(%rsp)
movq %rdi, 0x8(%rsp)
movq 0x18(%rdi), %r14
testq %r14, %r14
sete %bpl
je 0x4add
movq 0x8(%rsp), %rax
movq 0x10(%rax), %r15
movq (%r15), %r12
leaq 0x8(%r12), %rdi
leaq 0x18(%rsp), %rsi
callq 0x1a3fd
testb %al, %al
jne 0x4aae
shlq $0x3, %r14
movl $0x8, %ebx
leaq 0x18(%rsp), %r13
cmpq %rbx, %r14
sete %bpl
je 0x4add
movq (%r15,%rbx), %r12
leaq 0x8(%r12), %rdi
movq %r13, %rsi
callq 0x1a3fd
addq $0x8, %rbx
testb %al, %al
je 0x4a8c
movq 0x8(%rsp), %rdi
movq %r12, %rsi
movq 0x28(%rsp), %rdx
movl 0x14(%rsp), %ecx
movq 0x30(%rsp), %r8
callq 0x479c
testb %bpl, %bpl
jne 0x4add
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpb $0xf, 0x27(%rsp)
jne 0x4b0d
leaq 0x38(%rsp), %r14
movb $0xf, 0xf(%r14)
movb $0x0, (%r14)
leaq 0x2a5b2(%rip), %rsi     # 0x2f0ab
movl $0x22, %edx
movq %r14, %rdi
movl $0x1, %ecx
callq 0x5040
jmp 0x4b5e
movq 0x18(%rsp), %r15
movq 0x20(%rsp), %rbx
leaq 0x2a578(%rip), %rsi     # 0x2f096
leaq 0x48(%rsp), %r14
movl $0x14, %edx
movq %r14, %rdi
callq 0x19316
leaq 0x58(%rsp), %rax
movq %r15, (%rax)
movq %rbx, 0x8(%rax)
movzbl 0xf(%rax), %ecx
movq %rcx, %rsi
xorq $0xf, %rsi
testb %cl, %cl
movl %ebx, %edx
cmovnsq %rax, %r15
cmovnsq %rsi, %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x19466
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq 0x8(%rsp), %rdi
callq 0x4746
nop
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/argparse.cpp
// Function: argparse::single_arg(char, char const*, argparse::arglevel_t, bool*)
void argparse::single_arg(char sname, const char * value, arglevel_t arglevel, bool* used_value)
{
	for (arg_base& arg : m_args)
	{
		if (arg.sname == sname)
		{
			single_arg(arg, value, arglevel, used_value);
			return;
		}
	}
	string e = "unknown argument: -";
	e += sname; // no operator+(string, char), too high risk it's hit by an accidental operator+(string, int)
	error(e);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movl %esi, %ebp
movq %rdi, %rbx
movq 0x18(%rdi), %rax
testq %rax, %rax
sete %r14b
je 0x4bd2
movq 0x10(%rbx), %rdi
movq (%rdi), %rsi
cmpb %bpl, 0x18(%rsi)
je 0x4bba
shlq $0x3, %rax
movl $0x8, %r9d
cmpq %r9, %rax
sete %r14b
je 0x4bd2
movq (%rdi,%r9), %rsi
addq $0x8, %r9
cmpb %bpl, 0x18(%rsi)
jne 0x4ba3
movq %rbx, %rdi
callq 0x479c
testb %r14b, %r14b
jne 0x4bd2
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2a4f5(%rip), %rsi     # 0x2f0ce
leaq 0x8(%rsp), %r14
movl $0x13, %edx
movq %r14, %rdi
callq 0x19316
movzbl 0xf(%r14), %eax
movl %eax, %r15d
xorl $0xf, %r15d
testb %al, %al
cmovsl 0x8(%r14), %r15d
leal 0x1(%r15), %esi
movq %r14, %rdi
callq 0x191a4
cmpb $0x0, 0xf(%r14)
jns 0x4c16
movq 0x8(%rsp), %r14
movb %bpl, (%r14,%r15)
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
movq %rbx, %rdi
callq 0x4746
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/argparse.cpp
// Function: argparse::parse_pre(char const* const*)
void argparse::parse_pre(const char * const * argv)
{
#ifndef ARLIB_OPT
	if (m_appname)
	{
		error("internal error: argparse::parse called twice");
	}
#endif
	m_appname = argv[0];
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movzbl 0xf(%rdi), %eax
testb %al, %al
jns 0x4c43
movl 0x8(%rbx), %eax
jmp 0x4c46
xorl $0xf, %eax
testl %eax, %eax
jne 0x4c78
movq (%rsi), %rax
testq %rax, %rax
leaq 0x2d775(%rip), %r14     # 0x323cc
cmovneq %rax, %r14
movq %r14, %rdi
callq 0x30f0
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
addq $0x18, %rsp
popq %rbx
popq %r14
jmp 0x193dc
leaq 0x8(%rsp), %r14
movb $0xf, 0xf(%r14)
movb $0x0, (%r14)
leaq 0x2a455(%rip), %rsi     # 0x2f0e2
movl $0x2c, %edx
movq %r14, %rdi
movl $0x1, %ecx
callq 0x5040
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq %rbx, %rdi
callq 0x4746
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/string.h
// Function: cstring::init_from_nocopy(unsigned char const*, unsigned long, bool)
void init_from_nocopy(const uint8_t * str, size_t len, bool has_nul = false)
	{
		if (len <= MAX_INLINE)
		{
			for (uint32_t i=0;i<len;i++) m_inline[i] = str[i]; // memcpy's constant overhead is huge if len is unknown
			m_inline[len] = '\0';
			m_inline_len_w() = MAX_INLINE-len;
		}
		else
		{
			if (len > 0xFFFFFFFF) abort();
			m_inline_len_w() = -1;
			
			m_data = (uint8_t*)str;
			m_len = len;
			m_nul = has_nul;
		}
	}

// Assembly:
cmpq $0xf, %rdx
ja 0x5067
testq %rdx, %rdx
je 0x505b
xorl %eax, %eax
movb (%rsi,%rax), %cl
movb %cl, (%rdi,%rax)
incq %rax
cmpq %rax, %rdx
jne 0x504d
movb $0x0, (%rdi,%rdx)
movb $0xf, %al
subb %dl, %al
movb %al, 0xf(%rdi)
retq
movq %rdx, %rax
shrq $0x20, %rax
jne 0x507e
movb $-0x1, 0xf(%rdi)
movq %rsi, (%rdi)
movl %edx, 0x8(%rdi)
movb %cl, 0xc(%rdi)
retq
pushq %rax
callq 0x3180
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/array.cpp
// Function: bitarray::set_slice(unsigned long, unsigned long, bitarray const&, unsigned long)
void bitarray::set_slice(size_t start, size_t num, const bitarray& other, size_t other_start)
{
	if (&other == this)
	{
		//TODO: optimize
		bitarray copy = other;
		set_slice(start, num, copy, other_start);
		return;
	}
	//TODO: optimize
	for (size_t i=0;i<num;i++)
	{
		set(start+i, other.get(other_start+i));
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %rbx
movq %rcx, %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
cmpq %rdi, %rcx
je 0x511b
testq %r14, %r14
je 0x514d
cmpq $0x41, 0x8(%rax)
movq %rax, %rcx
jb 0x50bb
movq (%rax), %rcx
cmpq $0x41, 0x8(%r12)
movq %r12, %rdx
jb 0x50ca
movq (%r12), %rdx
movq %rbx, %rsi
shrq $0x3, %rsi
movzbl (%rcx,%rsi), %esi
movq %r15, %rdi
shrq $0x3, %rdi
movl %r15d, %ecx
andb $0x7, %cl
movl $0x1, %r8d
shll %cl, %r8d
notb %r8b
andb (%rdx,%rdi), %r8b
movl %ebx, %r9d
andl $0x7, %r9d
xorl %r10d, %r10d
btl %r9d, %esi
setb %r10b
shll %cl, %r10d
orb %r8b, %r10b
movb %r10b, (%rdx,%rdi)
incq %rbx
incq %r15
decq %r14
jne 0x50ae
jmp 0x514d
movq %rsp, %r13
movq %r13, %rdi
movq %rax, %rsi
callq 0x53c6
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %r13, %rcx
movq %rbx, %r8
callq 0x5084
cmpq $0x41, 0x8(%r13)
jb 0x514d
movq (%rsp), %rdi
callq 0x3430
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/array.cpp
// Function: bitarray::clear_unused(unsigned long, unsigned long)
void bitarray::clear_unused(size_t start, size_t nbytes)
{
	size_t low = start;
	size_t high = nbytes*8;
	
	if (low == high) return; // don't wipe bits()[8] if they're both 64
	
	uint8_t* ptr = bits();
	uint8_t& byte = ptr[low/8];
	byte &=~ (0xFF<<(low&7));
	low = (low+7)&~7;
	
	memset(ptr+low/8, 0, (high-low)/8);
}

// Assembly:
shlq $0x3, %rdx
cmpq %rsi, %rdx
jne 0x5166
retq
cmpq $0x41, 0x8(%rdi)
jb 0x5170
movq (%rdi), %rdi
movq %rsi, %rax
shrq $0x3, %rax
movl %esi, %ecx
andb $0x7, %cl
movb $-0x1, %r8b
shlb %cl, %r8b
notb %r8b
andb %r8b, (%rdi,%rax)
addq $0x7, %rsi
movq %rsi, %rax
andq $-0x8, %rax
shrq $0x3, %rsi
addq %rdi, %rsi
subq %rax, %rdx
shrq $0x3, %rdx
movq %rsi, %rdi
xorl %esi, %esi
jmp 0x3170
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/array.cpp
// Function: bitarray::slice(unsigned long, unsigned long) const
bitarray bitarray::slice(size_t first, size_t count) const
{
	if ((first&7) == 0)
	{
		bitarray ret;
		ret.resize(count);
		memcpy(ret.bits(), this->bits() + first/8, (count+7)/8);
		return ret;
	}
	else
	{
		//TODO: optimize
		bitarray ret;
		ret.resize(count);
		for (size_t i=0;i<count;i++) ret.set(i, this->get(first+i));
		return ret;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq %rcx, %rsi
callq 0x51ac
testb $0x7, %r15b
je 0x5381
testq %r14, %r14
je 0x53b6
xorl %eax, %eax
cmpq $0x41, 0x8(%r12)
movq %r12, %rcx
jb 0x5328
movq (%r12), %rcx
cmpq $0x41, 0x8(%rbx)
movq %rbx, %rdx
jb 0x5335
movq (%rbx), %rdx
leaq (%r15,%rax), %rsi
movq %rsi, %rdi
shrq $0x3, %rdi
movzbl (%rcx,%rdi), %edi
movq %rax, %r8
movl %eax, %ecx
andb $0x7, %cl
movl $0x1, %r9d
shll %cl, %r9d
shrq $0x3, %r8
notb %r9b
andb (%rdx,%r8), %r9b
andl $0x7, %esi
xorl %r10d, %r10d
btl %esi, %edi
setb %r10b
shll %cl, %r10d
orb %r9b, %r10b
movb %r10b, (%rdx,%r8)
incq %rax
cmpq %rax, %r14
jne 0x5319
jmp 0x53b6
cmpq $0x41, 0x8(%rbx)
jb 0x538d
movq (%rbx), %rdi
jmp 0x5390
movq %rbx, %rdi
cmpq $0x41, 0x8(%r12)
jb 0x539c
movq (%r12), %r12
shrq $0x3, %r15
addq %r12, %r15
addq $0x7, %r14
shrq $0x3, %r14
movq %r15, %rsi
movq %r14, %rdx
callq 0x3280
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/array.h
// Function: bitarray::construct(bitarray const&)
void construct(const bitarray& other)
	{
		nbits = other.nbits;
		if (nbits > n_inline)
		{
			size_t nbytes = alloc_size(nbits);
			bits_outline = xmalloc(nbytes);
			memcpy(bits_outline, other.bits_outline, nbytes);
		}
		else
		{
			memcpy(bits_inline, other.bits_inline, sizeof(bits_inline));
		}
	}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq 0x8(%rsi), %rax
movq %rax, 0x8(%rdi)
cmpq $0x41, %rax
jb 0x5425
addq $0x7, %rax
movq %rax, %rcx
shrq $0x3, %rcx
decq %rcx
bsrq %rcx, %rcx
movl $0x2, %edx
shlq %cl, %rdx
cmpq $0x10, %rax
movl $0x1, %r15d
cmovaeq %rdx, %r15
movq %r15, %rdi
callq 0x1573c
movq %rax, (%r14)
movq (%rbx), %rsi
movq %rax, %rdi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x3280
movq (%rbx), %rax
movq %rax, (%r14)
popq %rbx
popq %r14
popq %r15
retq
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/base64dec.cpp
// Function: base64_dec(cstring)
array<uint8_t> base64_dec(cstring text)
{
	array<uint8_t> ret;
	ret.resize(base64_dec_len(text.length()));
	size_t actual = base64_dec_raw(ret, text);
	if (!actual) return NULL;
	ret.resize(actual);
	return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rdx, %rax
shrq $0x38, %rax
xorps %xmm0, %xmm0
movq %rsp, %r12
movaps %xmm0, (%r12)
xorl $0xf, %eax
testq %rdx, %rdx
cmovsq %rdx, %rax
movl %eax, %eax
addq $0x3, %rax
shrq $0x2, %rax
leaq (%rax,%rax,2), %rsi
movq %r12, %rdi
callq 0xda72
movaps (%r12), %xmm0
leaq 0x10(%rsp), %rdi
movaps %xmm0, (%rdi)
movq %r15, %rsi
movq %r14, %rdx
callq 0x5434
testq %rax, %rax
je 0x56b8
movq %rsp, %r14
movq %r14, %rdi
movq %rax, %rsi
callq 0xda72
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movaps (%r14), %xmm0
movq $0x0, (%r14)
movq 0x8(%rbx), %rax
movq %rax, 0x8(%r14)
jmp 0x56bb
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq (%rsp), %rdi
callq 0x3430
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/base64enc.cpp
// Function: base64_enc_raw(arrayvieww<unsigned char>, arrayview<unsigned char>)
void base64_enc_raw(arrayvieww<uint8_t> out, arrayview<uint8_t> bytes)
{
	if (!bytes.size()) return;
	
	uint8_t* outp = out.ptr();
	const uint8_t* inp = bytes.ptr();
	const uint8_t* inpe = inp + bytes.size();
	
	while (inp+4 <= inpe)
	{
		uint32_t three = readu_be32(inp) >> 8;
		outp[0] = encode[(three>>18)   ];
		outp[1] = encode[(three>>12)&63];
		outp[2] = encode[(three>>6 )&63];
		outp[3] = encode[(three>>0 )&63];
		inp += 3;
		outp += 4;
	}
	
	uint32_t three = inp[0]<<16;
	if (inp+1 < inpe) three |= inp[1]<<8;
	if (inp+2 < inpe) three |= inp[2]<<0;
	
	outp[0] = encode[(three>>18)   ];
	outp[1] = encode[(three>>12)&63];
	outp[2] = encode[(three>>6 )&63];
	outp[3] = encode[(three>>0 )&63];
	
	if (inp+1 >= inpe) outp[2] = '='; // don't move the outp[2,3] above into elses, it optimizes better this way
	if (inp+2 >= inpe) outp[3] = '=';
}

// Assembly:
testq %rdx, %rdx
je 0x57d4
movq (%rdi), %rax
leaq (%rsi,%rdx), %rcx
cmpq $0x4, %rdx
jl 0x574f
leaq 0x29b0b(%rip), %rdx     # 0x2f200
movq %rsi, %rdi
movl (%rsi), %esi
bswapl %esi
movl %esi, %r8d
shrl $0x8, %r8d
movl %esi, %r9d
shrl $0x1a, %r9d
movb (%r9,%rdx), %r9b
movb %r9b, (%rax)
movl %esi, %r9d
shrl $0x14, %r9d
andl $0x3f, %r9d
movb (%r9,%rdx), %r9b
movb %r9b, 0x1(%rax)
shrl $0xe, %esi
andl $0x3f, %esi
movb (%rsi,%rdx), %sil
movb %sil, 0x2(%rax)
andl $0x3f, %r8d
movb (%r8,%rdx), %sil
movb %sil, 0x3(%rax)
leaq 0x3(%rdi), %rsi
addq $0x4, %rax
addq $0x7, %rdi
cmpq %rcx, %rdi
jbe 0x56f5
movzbl (%rsi), %edi
shll $0x10, %edi
leaq 0x1(%rsi), %rdx
cmpq %rcx, %rdx
jae 0x576c
movzbl (%rdx), %r8d
shll $0x8, %r8d
orl %edi, %r8d
movl %r8d, %edi
addq $0x2, %rsi
cmpq %rcx, %rsi
jae 0x577c
movzbl (%rsi), %r8d
orl %r8d, %edi
movl %edi, %r8d
shrl $0x12, %r8d
movl %edi, %r9d
shrl $0xc, %r9d
andl $0x3f, %r9d
leaq 0x29a6b(%rip), %r10     # 0x2f200
movb (%r8,%r10), %r8b
movb %r8b, (%rax)
movl %edi, %r8d
shrl $0x6, %r8d
andl $0x3f, %r8d
andl $0x3f, %edi
movb (%r9,%r10), %r9b
movb %r9b, 0x1(%rax)
movb (%r8,%r10), %r8b
movb %r8b, 0x2(%rax)
movb (%rdi,%r10), %dil
movb %dil, 0x3(%rax)
cmpq %rcx, %rdx
jb 0x57cb
movb $0x3d, 0x2(%rax)
cmpq %rcx, %rsi
jb 0x57d4
movb $0x3d, 0x3(%rax)
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/bmlparse.cpp
// Function: bml_size_white(cstring const&)
static size_t bml_size_white(const cstring& data)
{
	size_t i = 0;
	while (i < data.length() && (data[i]==' ' || data[i]=='\t')) i++;
	if (i < data.length() && data[i]=='#') return data.length();
	if (i+1 < data.length() && data[i]=='/' && data[i+1]=='/') return data.length();
	else return i;
}

// Assembly:
movzbl 0xf(%rdi), %edx
movl %edx, %ecx
xorl $0xf, %ecx
testb %dl, %dl
movl 0x8(%rdi), %esi
cmovnsl %ecx, %esi
testl %esi, %esi
je 0x62ce
movq %rdi, %r8
testb %dl, %dl
jns 0x6297
movq (%rdi), %r8
xorl %r9d, %r9d
movabsq $0x100000000, %r10      # imm = 0x100000000
xorl %eax, %eax
movq %r9, %r11
sarq $0x20, %r11
movzbl (%r8,%r11), %r11d
cmpl $0x20, %r11d
je 0x62be
cmpl $0x9, %r11d
jne 0x62d0
incq %rax
addq %r10, %r9
cmpq %rax, %rsi
jne 0x62a6
movq %rsi, %rax
jmp 0x62d0
xorl %eax, %eax
testb %dl, %dl
movl 0x8(%rdi), %esi
cmovnsl %ecx, %esi
cmpq %rsi, %rax
jae 0x62f1
movq %rdi, %rsi
testb %dl, %dl
jns 0x62e7
movq (%rdi), %rsi
movslq %eax, %r8
cmpb $0x23, (%rsi,%r8)
je 0x6322
leaq 0x1(%rax), %rsi
testb %dl, %dl
movl 0x8(%rdi), %r8d
cmovnsl %ecx, %r8d
cmpq %r8, %rsi
jae 0x632b
movq %rdi, %r8
testb %dl, %dl
jns 0x630e
movq (%rdi), %r8
movslq %eax, %r9
cmpb $0x2f, (%r8,%r9)
jne 0x632b
movslq %esi, %rsi
cmpb $0x2f, (%r8,%rsi)
jne 0x632b
testb %dl, %dl
cmovsl 0x8(%rdi), %ecx
movq %rcx, %rax
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/bmlparse.cpp
// Function: bmlparser::getline(bool)
inline bool bmlparser::getline(bool allow_empty)
{
nextline:
	if (!m_data)
	{
null:
		m_thisline = "";
		m_indent = "";
		return true;
	}
	
	m_thisline = cutline(m_data);
	size_t indentlen = bml_size_white(m_thisline);
	if (indentlen == m_thisline.length())
	{
		if (allow_empty) goto nextline;
		else goto null;
	}
	
	size_t sharedindent = min(indentlen, m_indent.length());
	bool badwhite = (memcmp(m_thisline.bytes().ptr(), m_indent.bytes().ptr(), sharedindent) != 0);
	
	m_indent = cut(m_thisline, 0, indentlen, 0);
	
	return !badwhite;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %esi, %r14d
movq %rdi, %r15
leaq 0x10(%rdi), %r12
leaq 0x20(%rdi), %rax
movq %rax, 0x18(%rsp)
leaq 0x40(%rdi), %rax
movq %rax, 0x10(%rsp)
xorl $0x3, %r14d
movabsq $0x100000000, %rbp      # imm = 0x100000000
movl %r14d, 0x24(%rsp)
movzbl 0x1f(%r15), %eax
testb %al, %al
jns 0x63fc
movl 0x18(%r15), %edx
jmp 0x6401
movl %eax, %edx
xorl $0xf, %edx
testl %edx, %edx
je 0x6546
movq %r12, %rcx
testb %al, %al
jns 0x6414
movq (%r12), %rcx
movl %edx, %esi
xorl %edi, %edi
xorl %edx, %edx
movq %rdi, %r8
sarq $0x20, %r8
movzbl (%rcx,%r8), %r8d
cmpl $0xa, %r8d
je 0x6440
cmpl $0xd, %r8d
je 0x6440
incq %rdx
addq %rbp, %rdi
cmpq %rdx, %rsi
jne 0x641a
movq %rsi, %rdx
xorl %ecx, %ecx
cmpq %rsi, %rdx
je 0x6468
movq %r12, %rcx
testb %al, %al
jns 0x6452
movq (%r12), %rcx
movslq %edx, %rax
movb (%rcx,%rax), %al
movl $0x2, %ecx
cmpb $0xd, %al
je 0x6468
xorl %ecx, %ecx
cmpb $0xa, %al
sete %cl
movq %r12, %rdi
xorl %esi, %esi
callq 0x632c
movq %rax, %r13
movq %rax, 0x20(%r15)
movq %rdx, 0x28(%r15)
movq 0x18(%rsp), %rdi
callq 0x6278
movzbl 0x2f(%r15), %ecx
movl %ecx, %edx
xorl $0xf, %edx
testb %cl, %cl
cmovsl 0x28(%r15), %edx
movq %rax, %rbx
movl %r14d, %eax
cmpq %rdx, %rbx
je 0x6538
movzbl 0x4f(%r15), %eax
movl %eax, %edi
xorl $0xf, %edi
testb %al, %al
cmovsl 0x48(%r15), %edi
movq 0x40(%r15), %rsi
cmovnsq 0x10(%rsp), %rsi
cmpq %rbx, %rdi
movq %rbx, %rdx
cmovbq %rdi, %rdx
testb %cl, %cl
movq %r12, %r14
movq 0x18(%rsp), %r12
cmovnsq %r12, %r13
movq %r13, %rdi
callq 0x3380
testl %eax, %eax
sete 0xf(%rsp)
movq %r12, %rdi
movq %r14, %r12
xorl %esi, %esi
movl %ebx, %edx
xorl %ecx, %ecx
callq 0x632c
movq %rax, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
movzbl 0x37(%rsp), %ecx
movq %rcx, %rsi
xorq $0xf, %rsi
testb %cl, %cl
movl %edx, %edx
leaq 0x28(%rsp), %rcx
cmovnsq %rcx, %rax
cmovnsq %rsi, %rdx
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %r14d
movq %rax, %rsi
callq 0x193dc
movl $0x1, %eax
cmpl $0x2, %eax
je 0x63ed
cmpl $0x3, %eax
jne 0x6574
leaq 0x2be7f(%rip), %rbx     # 0x323cc
movq 0x18(%rsp), %rdi
movq %rbx, %rsi
xorl %edx, %edx
movl $0x1, %ecx
callq 0x5040
movq 0x10(%rsp), %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x193dc
movb $0x1, %al
jmp 0x6578
movb 0xf(%rsp), %al
andb $0x1, %al
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/bmlwrite.cpp
// Function: bmlwriter::type(cstring, bmlwriter::mode) const
bmlwriter::mode bmlwriter::type(cstring val, mode m) const
{
	bool inlined = (m <= icol);
	if (m <= icol) m = (mode)(m+4);
	
	m = max(type_core(val), m);
	if (inlined && m != multiline && m_caninline) return (mode)(m-4);
	else return m;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %ecx, %ebx
movq %rdi, %r14
leal 0x4(%rbx), %ebp
cmpl $0x4, %ecx
cmovgel %ecx, %ebp
movq %rsi, %rdi
movq %rdx, %rsi
callq 0x6fa0
cmpl %eax, %ebp
cmovgl %ebp, %eax
leal -0x4(%rax), %ecx
testb $0x1, 0x14(%r14)
cmovel %eax, %ecx
cmpl $0x8, %eax
cmovel %eax, %ecx
cmpl $0x4, %ebx
cmovll %ecx, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/Alcaro[P]bridges/arlib/bmlwrite.cpp
// Function: bmlwriter::type_core(cstring)
bmlwriter::mode bmlwriter::type_core(cstring val)
{
	if (val == "") return anon;
	
	char first = val[0];
	char last = val[val.length()-1];
	
	if (val.contains("\n") || first==' ' || first=='\t' || last==' ' || last=='\t') return multiline;
	if (val.contains("\"")) return col;
	if (val.contains(" ") || val.contains("\t")) return quote;
	return eq;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x58, %rsp
movq %rdi, 0x8(%rsp)
movq %rsi, 0x10(%rsp)
movl $0x4, %eax
cmpb $0xf, 0x17(%rsp)
je 0x70f5
leaq 0x8(%rsp), %rbx
movzbl 0xf(%rbx), %eax
movl %eax, %ecx
xorl $0xf, %ecx
testb %al, %al
cmovnsq %rbx, %rdi
cmovsl 0x8(%rbx), %ecx
movb (%rdi), %bpl
decl %ecx
movslq %ecx, %rax
movb (%rdi,%rax), %r15b
leaq 0x2b7dd(%rip), %rsi     # 0x327cc
leaq 0x48(%rsp), %r14
movl $0x1, %edx
movq %r14, %rdi
movl $0x1, %ecx
callq 0x5040
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq %rbx, %rdi
callq 0x748a
movl %eax, %ecx
movl $0x8, %eax
cmpb $0x9, %r15b
je 0x70f5
cmpb $0x20, %r15b
je 0x70f5
cmpb $0x9, %bpl
je 0x70f5
cmpb $0x20, %bpl
je 0x70f5
testb %cl, %cl
jne 0x70f5
leaq 0x28308(%rip), %rsi     # 0x2f35b
leaq 0x38(%rsp), %rbx
movl $0x1, %edx
movq %rbx, %rdi
movl $0x1, %ecx
callq 0x5040
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
leaq 0x8(%rsp), %rdi
callq 0x748a
movl %eax, %ecx
movl $0x7, %eax
testb %cl, %cl
jne 0x70f5
leaq 0x28a6c(%rip), %rsi     # 0x2faf9
leaq 0x28(%rsp), %rbx
movl $0x1, %edx
movq %rbx, %rdi
movl $0x1, %ecx
callq 0x5040
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
leaq 0x8(%rsp), %rdi
callq 0x748a
movl %eax, %ecx
movl $0x6, %eax
testb %cl, %cl
jne 0x70f5
leaq 0x28368(%rip), %rsi     # 0x2f42f
leaq 0x18(%rsp), %rbx
movl $0x1, %edx
movq %rbx, %rdi
movl $0x1, %ecx
callq 0x5040
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
leaq 0x8(%rsp), %rdi
callq 0x748a
movzbl %al, %eax
addl $0x5, %eax
addq $0x58, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq