LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_direct.cc
// Function: scdc_compcoup_direct::start(long long)
bool scdc_compcoup_direct::start(scdcint_t mode)
{
  SCDC_TRACE("start: mode: '" << mode << "'");

  if (running) return false;

  if (mode == SCDC_NODEPORT_START_LOOP_UNTIL_CANCEL)
  {
    pthread_mutex_t lock = PTHREAD_MUTEX_INITIALIZER;
    pthread_mutex_lock(&lock);

    running = true;

    pthread_cond_t cond = PTHREAD_COND_INITIALIZER;

    data = static_cast<void *>(&cond);
    pthread_cond_wait(&cond, &lock);
    data = 0;

    pthread_cond_destroy(&cond);

    running = false;

    pthread_mutex_unlock(&lock);
    pthread_mutex_destroy(&lock);

  } else if (mode == SCDC_NODEPORT_START_ASYNC_UNTIL_CANCEL)
  {
    running = true;

  } else
  {
    SCDC_ERROR("start: mode '" << mode << "' not supported");
    return false;
  }

  return true;
}

// Assembly:
cmpb $0x0, 0x18(%rdi)
je 0x4bf8b
xorl %eax, %eax
retq
pushq %r15
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rsi, %rbx
movq %rdi, %r14
cmpq $0x4, %rsi
je 0x4c00e
cmpq $0x1, %rbx
jne 0x4c017
xorps %xmm0, %xmm0
movq %rsp, %rbx
movaps %xmm0, 0x10(%rbx)
movaps %xmm0, (%rbx)
andq $0x0, 0x20(%rbx)
movq %rbx, %rdi
callq 0xb800
movb $0x1, 0x18(%r14)
leaq 0x30(%rsp), %r15
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%r15)
movaps %xmm0, 0x10(%r15)
movaps %xmm0, (%r15)
movq %r15, 0x10(%r14)
movq %r15, %rdi
movq %rbx, %rsi
callq 0xb860
andq $0x0, 0x10(%r14)
movq %r15, %rdi
callq 0xba60
movb $0x0, 0x18(%r14)
movq %rbx, %rdi
callq 0xb3e0
movq %rbx, %rdi
callq 0xb640
jmp 0x4c013
movb $0x1, 0x18(%r14)
movb $0x1, %al
jmp 0x4c092
leaq 0x29562(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4c090
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x5449(%rip), %rsi      # 0x51488
callq 0xb520
leaq 0x8d61(%rip), %rsi      # 0x54dac
movq %rax, %rdi
callq 0xb520
leaq 0x8d64(%rip), %rsi      # 0x54dbe
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb1d0
leaq 0x89ef(%rip), %rsi      # 0x54a63
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %eax, %eax
addq $0x60, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_direct.cc
// Function: scdc_compcoup_direct::cancel(bool)
bool scdc_compcoup_direct::cancel(bool interrupt)
{
  SCDC_TRACE("cancel: interrupt: '" << interrupt << "'");

  if (!running) return false;

  if (data)
  {
    pthread_cond_t *cond = static_cast<pthread_cond_t *>(data);
    pthread_cond_signal(cond);
  }

  running = false;

  return true;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movb 0x18(%rdi), %bl
cmpb $0x1, %bl
jne 0x4c0d4
movq %rdi, %r14
movq 0x10(%rdi), %rdi
testq %rdi, %rdi
je 0x4c0cf
callq 0xb030
movb $0x0, 0x18(%r14)
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::dataset_input_outgoing_produce(scdc_transport_connection_t*, _scdc_dataset_inout_t*)
bool scdc_compcoup_transport::dataset_input_outgoing_produce(scdc_transport_connection_t *conn, scdc_dataset_input_t *input)
{
  while (1)
  {
    SCDC_TRACE("dataset_input_outgoing_produce: outgoing produce");
    if (!dataset_input_outgoing_send(conn, input))
    {
      SCDC_FAIL("dataset_input_outgoing_produce: send failed");
      return false;
    }

    if (!input || !input->next) break;

    SCDC_TRACE("dataset_input_outgoing_produce: next");
    if (!input->next(input, 0))
    {
      SCDC_FAIL("dataset_input_outgoing_produce: next failed");
      return false;
    }
  }

  return true;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x4e762
testb %al, %al
je 0x4d767
movb $0x1, %al
testq %rbx, %rbx
je 0x4d7d2
movq 0x38(%rbx), %rcx
testq %rcx, %rcx
je 0x4d7d2
movq %rbx, %rdi
xorl %esi, %esi
callq *%rcx
testq %rax, %rax
jne 0x4d71a
leaq 0x27e2c(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4d7d0
leaq 0x7b96(%rip), %rbx      # 0x552fb
jmp 0x4d77f
leaq 0x27e12(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4d7d0
leaq 0x7b50(%rip), %rbx      # 0x552cf
addq $0x20, %rdi
callq 0xb800
leaq 0x27df1(%rip), %r14     # 0x75580
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x39eb(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x7656(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::dataset_output_incoming_consume(scdc_transport_connection_t*, _scdc_dataset_inout_t*, bool*)
bool scdc_compcoup_transport::dataset_output_incoming_consume(scdc_transport_connection_t *conn, scdc_dataset_output_t *output, bool *next)
{
  scdc_dataset_output_t output_null;

  /* use null output for consuming all output */
  if (!output)
  {
    scdc_dataset_output_unset(&output_null);
    output = &output_null;
  }

  *next = true;

  while (*next)
  {
    SCDC_TRACE("dataset_output_incoming_consume: incoming receive");
    if (!dataset_output_incoming_recv(conn, output, next))
    {
      SCDC_FAIL("dataset_output_incoming_consume: receive failed");
      return false;
    }

    if (output == &output_null) continue; 

    if (!output->next) break;

    SCDC_TRACE("dataset_output_incoming_consume: next");
    if (!output->next(output, 0))
    {
      SCDC_FAIL("dataset_output_incoming_consume: next failed");
      return false;
    }
  }

  return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %r15
leaq 0x8(%rsp), %r12
testq %rsi, %rsi
jne 0x4d805
movq %r12, %rdi
callq 0x24cd8
movq %r12, %r13
movb $0x1, (%r14)
movb $0x1, %bl
movb $0x1, %al
testb $0x1, %al
je 0x4d8cf
movq %r15, %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0x4e828
testb %al, %al
je 0x4d84a
cmpq %r12, %r13
je 0x4d845
movq 0x38(%r13), %rax
testq %rax, %rax
je 0x4d8cf
movq %r13, %rdi
xorl %esi, %esi
callq *%rax
testq %rax, %rax
je 0x4d864
movb (%r14), %al
jmp 0x4d80d
leaq 0x27d2f(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4d8cd
leaq 0x7ac5(%rip), %rbx      # 0x55327
jmp 0x4d87c
leaq 0x27d15(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4d8cd
leaq 0x7adb(%rip), %rbx      # 0x55357
addq $0x20, %rdi
callq 0xb800
leaq 0x27cf4(%rip), %r14     # 0x75580
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x38ee(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x7559(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: read_output_next(_scdc_dataset_inout_t*, _scdc_result_t*)
static scdcint_t read_output_next(scdc_dataset_output_t *output, scdc_result_t *result)
{
  SCDC_TRACE("read_output_next:");

  scdc_transport_connection_t *transport_connection = static_cast<scdc_transport_connection_t *>(output->data);

  bool next = false, ret = true;

  if (transport_connection->current_incoming_output_next || transport_connection->current_incoming_output_size > 0) ret = scdc_compcoup_transport::dataset_output_incoming_recv(transport_connection, output, &next);
  else SCDC_DATASET_INOUT_BUF_CURRENT(output) = 0;

  if (next)
  {
    /* continue with current output->next and output->data */

  } else
  {
    if (transport_connection->current_incoming_output_intern)
    {
      /* continue with current output->next and output->data */

      /* unset internal buffer usage for next 'next' */
      transport_connection->current_incoming_output_intern = false;

    } else
    {
      /* stop and release connection */
      output->next = 0;
      output->data = 0;

      transport_connection->release();
    }
  }

  return (ret)?SCDC_SUCCESS:SCDC_FAILURE;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x40(%rdi), %rbx
movb $0x0, 0x7(%rsp)
cmpb $0x0, 0x2d1(%rbx)
jne 0x4d906
cmpq $0x0, 0x2c8(%rbx)
jle 0x4d926
leaq 0x7(%rsp), %r12
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
callq 0x4e828
movzbl %al, %r15d
testb $0x1, (%r12)
je 0x4d92f
jmp 0x4d951
andq $0x0, 0x20(%r14)
pushq $0x1
popq %r15
cmpb $0x1, 0x2d3(%rbx)
jne 0x4d941
movb $0x0, 0x2d3(%rbx)
jmp 0x4d951
xorps %xmm0, %xmm0
movups %xmm0, 0x38(%r14)
movq %rbx, %rdi
callq 0x49568
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::on_dataset_close(scdc_transport_connection_t*)
void scdc_compcoup_transport::on_dataset_close(scdc_transport_connection_t *conn)
{
  SCDC_TRACE("on_dataset_close:");

  /* read request: DATASET_CLOSE <state> */

  scdc_result result;

  scdc_dataset_transport::read_state_begin(conn);
  scdc_dataset *dataset = dataprovs->dataset_open_read_state(conn->get_incoming(), result);
  scdc_dataset_transport::read_state_end(conn);

  /* send answer: DATASET_CLOSE (OK|FAILED) RESULT <string> */

  scdc_dataset_transport::write_delim(conn, "DATASET_CLOSE", -1, default_delim);

  if (dataset)
  {
    scdc_dataset_transport::write_delim(conn, "OK", -1, default_delim);
    dataprovs->dataset_close(dataset, result);

  } else
  {
    SCDC_FAIL("on_dataset_close: failed");
    scdc_dataset_transport::write_delim(conn, "FAILED", -1, default_delim);
  }

  scdc_dataset_transport::write_delim(conn, "RESULT", -1, default_delim);
  scdc_dataset_transport::write_string(conn, result.c_str(), result.size());

  transport->send_outgoing(conn);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x10(%rsp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq %rsi, %rdi
callq 0x4f370
movq 0x8(%r14), %rdi
leaq 0x30(%rbx), %rsi
movq %rsp, %rdx
callq 0x1c46e
movq %rax, %r15
movq %rbx, %rdi
callq 0x4f422
leaq 0x7094(%rip), %rsi      # 0x54ef6
pushq $-0x1
popq %rdx
pushq $0x20
popq %rcx
movq %rbx, %rdi
callq 0x4ed78
testq %r15, %r15
je 0x4de9b
leaq 0x26b8(%rip), %rsi      # 0x50534
pushq $-0x1
popq %rdx
pushq $0x20
popq %rcx
movq %rbx, %rdi
callq 0x4ed78
movq 0x8(%r14), %rdi
movq %rsp, %rdx
movq %r15, %rsi
callq 0x1c460
jmp 0x4df0f
leaq 0x276de(%rip), %r15     # 0x75580
movq (%r15), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4defa
addq $0x20, %rdi
callq 0xb800
movq (%r15), %rax
movq 0x8(%rax), %rdi
leaq 0x32c5(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x6f30(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
leaq 0x74f8(%rip), %rsi      # 0x553d6
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r15), %rdi
addq $0x20, %rdi
callq 0xb3e0
leaq 0x6f72(%rip), %rsi      # 0x54e73
pushq $-0x1
popq %rdx
pushq $0x20
popq %rcx
movq %rbx, %rdi
callq 0x4ed78
leaq 0x6f8f(%rip), %rsi      # 0x54ea5
pushq $-0x1
popq %rdx
pushq $0x20
popq %rcx
movq %rbx, %rdi
callq 0x4ed78
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x4f2ce
movq 0x10(%r14), %rdi
movq (%rdi), %rax
movq %rbx, %rsi
callq *0xd0(%rax)
movq %rsp, %rdi
callq 0xb230
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
jmp 0x4df59
movq %rax, %rbx
movq %rsp, %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::on_cmd_handler(char const*, scdc_data*)
bool scdc_compcoup_transport::on_cmd_handler(const char *cmd, scdc_data *incoming)
{
  if (!cmd_handler) return false;
  
  if (cmd[0] == '\0') return true;

  scdcint_t n = cmd_handler(cmd_handler_data, cmd, incoming->get_read_pos_buf(), incoming->get_read_pos_buf_size());

  return (n >= 0);
}

// Assembly:
movq 0x20(%rdi), %rax
testq %rax, %rax
je 0x4e524
cmpb $0x0, (%rsi)
je 0x4e527
pushq %rax
movq 0x28(%rdi), %rdi
movq 0x20(%rdx), %rcx
movq 0x28(%rdx), %r8
movq 0x8(%rdx), %rdx
addq %r8, %rdx
subq %r8, %rcx
callq *%rax
testq %rax, %rax
setns %al
addq $0x8, %rsp
retq
xorl %eax, %eax
retq
movb $0x1, %al
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::dataset_input_outgoing_send(scdc_transport_connection_t*, _scdc_dataset_inout_t*)
bool scdc_compcoup_transport::dataset_input_outgoing_send(scdc_transport_connection_t *conn, scdc_dataset_input_t *input)
{
  SCDC_TRACE("dataset_input_outgoing_send:");

  if (!scdc_dataset_transport::write_input_info(conn, input))
  {
    SCDC_FAIL("dataset_input_outgoing_send: write input info failed");
    return false;
  }

  if (input)
  {
    if (!conn->transport->send_outgoing_dataset_input(conn, input))
    {
      SCDC_FAIL("dataset_input_outgoing_send: send dataset input failed");
      return false;
    }
  }

  return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
callq 0x4f798
testb %al, %al
je 0x4e7b5
movb $0x1, %bl
testq %r14, %r14
je 0x4e820
movq (%r15), %rdi
movq (%rdi), %rax
movq %r15, %rsi
movq %r14, %rdx
callq *0xb8(%rax)
testb %al, %al
jne 0x4e820
leaq 0x26dde(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4e81e
leaq 0x697d(%rip), %rbx      # 0x55130
jmp 0x4e7cd
leaq 0x26dc4(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4e81e
leaq 0x692e(%rip), %rbx      # 0x550fb
addq $0x20, %rdi
callq 0xb800
leaq 0x26da3(%rip), %r14     # 0x75580
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x299d(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x6608(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::dataset_output_outgoing_send(scdc_transport_connection_t*, _scdc_dataset_inout_t*)
bool scdc_compcoup_transport::dataset_output_outgoing_send(scdc_transport_connection_t *conn, scdc_dataset_output_t *output)
{
  SCDC_TRACE("dataset_output_outgoing_send:");

  if (!scdc_dataset_transport::write_output_info(conn, output))
  {
    SCDC_FAIL("dataset_output_outgoing_send: write output info failed");
    return false;
  }

  if (output)
  {
    if (!conn->transport->send_outgoing_dataset_output(conn, output))
    {
      SCDC_FAIL("dataset_output_outgoing_send: send dataset output failed");
      return false;
    }
  }

  return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
callq 0x4f798
testb %al, %al
je 0x4eab1
movb $0x1, %bl
testq %r14, %r14
je 0x4eb1c
movq (%r15), %rdi
movq (%rdi), %rax
movq %r15, %rsi
movq %r14, %rdx
callq *0xc0(%rax)
testb %al, %al
jne 0x4eb1c
leaq 0x26ae2(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4eb1a
leaq 0x678c(%rip), %rbx      # 0x5523b
jmp 0x4eac9
leaq 0x26ac8(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4eb1a
leaq 0x673b(%rip), %rbx      # 0x55204
addq $0x20, %rdi
callq 0xb800
leaq 0x26aa7(%rip), %r14     # 0x75580
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x26a1(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x630c(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::dataset_input_incoming_consume(scdc_transport_connection_t*, _scdc_dataset_inout_t*, bool*)
bool scdc_compcoup_transport::dataset_input_incoming_consume(scdc_transport_connection_t *conn, scdc_dataset_input_t *input, bool *next)
{
  scdc_dataset_input_t input_null;

  /* use null input for consuming all input */
  if (!input)
  {
    scdc_dataset_input_unset(&input_null);
    input = &input_null;
  }

  *next = true;

  while (*next)
  {
    SCDC_TRACE("dataset_input_incoming_consume: incoming receive");
    if (!dataset_input_incoming_recv(conn, input, next))
    {
      SCDC_FAIL("dataset_input_incoming_consume: receive failed");
      return false;
    }

    if (input == &input_null) continue; 

    if (!input->next) break;

    SCDC_TRACE("dataset_input_incoming_consume: next");
    if (!input->next(input, 0))
    {
      SCDC_FAIL("dataset_input_incoming_consume: next failed");
      return false;
    }
  }

  return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %r15
leaq 0x8(%rsp), %r12
testq %rsi, %rsi
jne 0x4eb4f
movq %r12, %rdi
callq 0x24cb8
movq %r12, %r13
movb $0x1, (%r14)
movb $0x1, %bl
movb $0x1, %al
testb $0x1, %al
je 0x4ec19
movq %r15, %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0x4e52c
testb %al, %al
je 0x4eb94
cmpq %r12, %r13
je 0x4eb8f
movq 0x38(%r13), %rax
testq %rax, %rax
je 0x4ec19
movq %r13, %rdi
xorl %esi, %esi
callq *%rax
testq %rax, %rax
je 0x4ebae
movb (%r14), %al
jmp 0x4eb57
leaq 0x269e5(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4ec17
leaq 0x66c8(%rip), %rbx      # 0x55274
jmp 0x4ebc6
leaq 0x269cb(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4ec17
leaq 0x66dd(%rip), %rbx      # 0x552a3
addq $0x20, %rdi
callq 0xb800
leaq 0x269aa(%rip), %r14     # 0x75580
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x25a4(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x620f(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_compcoup_transport::dataset_output_outgoing_produce(scdc_transport_connection_t*, _scdc_dataset_inout_t*)
bool scdc_compcoup_transport::dataset_output_outgoing_produce(scdc_transport_connection_t *conn, scdc_dataset_output_t *output)
{
  while (1)
  {
    SCDC_TRACE("dataset_output_outgoing_produce: outgoing produce");
    dataset_output_outgoing_send(conn, output);

    if (!output || !output->next) break;

    SCDC_TRACE("dataset_output_outgoing_produce: next");
    if (!output->next(output, 0))
    {
      SCDC_FAIL("dataset_output_outgoing_produce: next failed");
      return false;
    }
  }

  return true;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x4ea5e
movb $0x1, %al
testq %rbx, %rbx
je 0x4ecbc
movq 0x38(%rbx), %rcx
testq %rcx, %rcx
je 0x4ecbc
movq %rbx, %rdi
xorl %esi, %esi
callq *%rcx
testq %rax, %rax
jne 0x4ec34
leaq 0x2691e(%rip), %rbx     # 0x75580
movq (%rbx), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4ecba
addq $0x20, %rdi
callq 0xb800
movq (%rbx), %rax
movq 0x8(%rax), %rdi
leaq 0x2505(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x6170(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
leaq 0x66e6(%rip), %rsi      # 0x55384
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%rbx), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: write_output_next(_scdc_dataset_inout_t*, _scdc_result_t*)
static scdcint_t write_output_next(scdc_dataset_output_t *output, scdc_result_t *result)
{
  scdc_transport_connection_t *transport_connection = static_cast<scdc_transport_connection_t *>(output->data);

  bool ret = true;

  ret = ret && scdc_dataset_transport::write_output_info(transport_connection, output);
  ret = ret && transport_connection->transport->send_outgoing_dataset_output(transport_connection, output);

  return (ret)?SCDC_SUCCESS:SCDC_FAILURE;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x40(%rdi), %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x4f798
testb %al, %al
je 0x4ed69
movq (%r14), %rdi
movq (%rdi), %rax
movq %r14, %rsi
movq %rbx, %rdx
callq *0xc0(%rax)
movzbl %al, %eax
jmp 0x4ed6b
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::write_delim(scdc_transport_connection_t*, char const*, long long, char)
static bool write_delim(scdc_transport_connection_t *transport_connection_, const char *s, scdcint_t n, char delim)
    {
      if (n < 0) n = strlen(s);

      bool ret = true;

      ret = ret && write_bytes(transport_connection_, s, n);
      ret = ret && write_bytes(transport_connection_, &delim, 1);

      if (!ret) SCDC_FAIL("write_delim: failed");

      return ret;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movb %cl, 0x7(%rsp)
testq %rdx, %rdx
jns 0x4ed96
movq %r14, %rdi
callq 0xb210
movq %rax, %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4f58a
testb %al, %al
je 0x4edbd
leaq 0x7(%rsp), %rsi
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x4f58a
movl %eax, %ecx
movb $0x1, %al
testb %cl, %cl
jne 0x4ee1e
leaq 0x267bc(%rip), %rbx     # 0x75580
movq (%rbx), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4ee1c
addq $0x20, %rdi
callq 0xb800
movq (%rbx), %rax
movq 0x8(%rax), %rdi
leaq 0x23a3(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x600e(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
leaq 0x6636(%rip), %rsi      # 0x55436
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%rbx), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_delim(scdc_transport_connection_t*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*, char, bool*)
static bool read_delim(scdc_transport_connection_t *transport_connection_, std::string *s, char delim, bool *stop_at_delim = 0)
    {
      scdc_data *incoming = transport_connection_->get_incoming();
      bool ret = true;

      (*s).clear();

      while (ret)
      {
        const char *src = incoming->get_read_pos_buf();
        scdcint_t src_size = incoming->get_read_pos_buf_size();

/*        SCDC_TRACE("read_delim: '" << string(src, src_size) << "'");*/

        const char *end = memchr(src, delim, src_size);

        scdcint_t n = (end)?(end - src):src_size;

        *s += string(src, n);

        if (end) n += 1;
        incoming->inc_read_pos(n);

        if (stop_at_delim && n > 0)
        {
          *stop_at_delim = (end != 0);
          break;
        }

        if (end) break;

        ret = incoming->do_next();
      }

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rcx, 0x10(%rsp)
movl %edx, 0xc(%rsp)
movq %rdi, %r15
leaq 0x30(%rdi), %rax
movq %rax, 0x18(%rsp)
andq $0x0, 0x8(%rsi)
movq %rsi, 0x20(%rsp)
movq (%rsi), %rax
movb $0x0, (%rax)
leaq 0x28(%rsp), %r12
movq 0x50(%r15), %rbx
movq 0x58(%r15), %rax
movq 0x38(%r15), %r14
addq %rax, %r14
subq %rax, %rbx
movq %r14, %rdi
movl 0xc(%rsp), %esi
movq %rbx, %rdx
callq 0xb5f0
movq %rax, %r13
movq %rax, %rbp
subq %r14, %rbp
testq %rax, %rax
setne 0xb(%rsp)
movq %rbx, %rdx
cmovneq %rbp, %rdx
leaq 0x38(%rsp), %rax
movq %rax, 0x28(%rsp)
addq %r14, %rdx
movq %r12, %rdi
movq %r14, %rsi
callq 0x1a1f2
movq 0x20(%rsp), %rdi
movq %r12, %rsi
callq 0xba90
movq %r12, %rdi
callq 0xb230
incq %rbp
testq %r13, %r13
cmovneq %rbp, %rbx
addq %rbx, 0x58(%r15)
cmpq $0x0, 0x10(%rsp)
je 0x4eeef
testq %rbx, %rbx
jg 0x4ef0e
testq %r13, %r13
jne 0x4ef1e
movq 0x68(%r15), %rax
testq %rax, %rax
je 0x4ef1e
movq 0x18(%rsp), %rdi
callq *%rax
testb %al, %al
jne 0x4ee6e
jmp 0x4ef1e
testq %r13, %r13
movq 0x10(%rsp), %rax
setne (%rax)
movb $0x1, 0xb(%rsp)
movb 0xb(%rsp), %al
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_state()
bool read_state()
    {
      bool ret = true;

      ret = ret && read_state_begin(transport_connection);
      ret = ret && read_delim(transport_connection, &state, state_end);

      char c;
      ret = ret && read_bytes(transport_connection, &c, 1);
      SCDC_ASSERT(c == default_delim);

      return ret;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x60(%rdi), %rdi
callq 0x4f370
testb %al, %al
je 0x4efcf
movq 0x60(%r14), %rdi
leaq 0x38(%r14), %rsi
xorl %ebx, %ebx
pushq $0x3e
popq %rdx
xorl %ecx, %ecx
callq 0x4ee36
testb %al, %al
je 0x4efd1
movq 0x60(%r14), %rdi
leaq 0x7(%rsp), %r14
pushq $0x1
popq %rdx
movq %r14, %rsi
callq 0x4f65c
movl %eax, %ebx
cmpb $0x20, (%r14)
jne 0x4efd1
jmp 0x4f059
xorl %ebx, %ebx
leaq 0x265a8(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4f059
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x2550(%rip), %rsi      # 0x51549
callq 0xb520
leaq 0x5e38(%rip), %rsi      # 0x54e3d
movq %rax, %rdi
callq 0xb520
leaq 0x2330(%rip), %rsi      # 0x51344
movq %rax, %rdi
callq 0xb520
pushq $0x7d
popq %rsi
movq %rax, %rdi
callq 0xb990
leaq 0x641c(%rip), %rsi      # 0x5544a
movq %rax, %rdi
callq 0xb520
leaq 0x3e53(%rip), %rsi      # 0x52e90
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_string(scdc_transport_connection_t*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)
static bool read_string(scdc_transport_connection_t *transport_connection_, std::string *s)
    {
      bool ret = true;

      string t;
      ret = ret && read_delim(transport_connection_, &t, string_begin);

      scdcint_t n;
      sscanf(t.c_str(), "%" scdcint_fmt, &n);

      ret = ret && read_bytes(transport_connection_, s, n);

      char c;
      ret = ret && read_bytes(transport_connection_, &c, 1);
      SCDC_ASSERT(c == string_end);

      ret = ret && read_bytes(transport_connection_, &c, 1);
      SCDC_ASSERT(c == default_delim);

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x20(%rsp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x10(%rsp), %rsi
pushq $0x27
popq %rdx
xorl %ecx, %ecx
callq 0x4ee36
movl %eax, %ebp
movq 0x10(%rsp), %rdi
leaq 0x4c20(%rip), %rsi      # 0x53cc0
leaq 0x8(%rsp), %rdx
xorl %eax, %eax
callq 0xb510
testb %bpl, %bpl
je 0x4f0e3
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4f6d6
testb %al, %al
je 0x4f0e3
leaq 0x7(%rsp), %rsi
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x4f65c
movl %eax, %ebp
cmpb $0x27, 0x7(%rsp)
jne 0x4f0e5
jmp 0x4f16f
xorl %ebp, %ebp
leaq 0x26494(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4f16f
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x243c(%rip), %rsi      # 0x51549
callq 0xb520
leaq 0x5d24(%rip), %rsi      # 0x54e3d
movq %rax, %rdi
callq 0xb520
leaq 0x221c(%rip), %rsi      # 0x51344
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movl $0xa8, %esi
callq 0xb990
leaq 0x631c(%rip), %rsi      # 0x55460
movq %rax, %rdi
callq 0xb520
leaq 0x3d3d(%rip), %rsi      # 0x52e90
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
testb %bpl, %bpl
je 0x4f188
leaq 0x7(%rsp), %rsi
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x4f65c
movl %eax, %ebx
jmp 0x4f18a
xorl %ebx, %ebx
cmpb $0x20, 0x7(%rsp)
je 0x4f21f
leaq 0x263e4(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4f21f
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x238c(%rip), %rsi      # 0x51549
callq 0xb520
leaq 0x5c74(%rip), %rsi      # 0x54e3d
movq %rax, %rdi
callq 0xb520
leaq 0x216c(%rip), %rsi      # 0x51344
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movl $0xab, %esi
callq 0xb990
leaq 0x6256(%rip), %rsi      # 0x5544a
movq %rax, %rdi
callq 0xb520
leaq 0x3c8d(%rip), %rsi      # 0x52e90
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
leaq 0x10(%rsp), %rdi
callq 0xb230
movl %ebx, %eax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
jmp 0x4f238
jmp 0x4f238
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::write_state()
bool write_state()
    {
      bool ret = true;

      ret = ret && write_state_begin(transport_connection);
      ret = ret && write_delim(transport_connection, state.data(), state.size(), state_end);

      ret = ret && write_bytes(transport_connection, &default_delim, 1);

      return ret;
    }

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq 0x60(%rdi), %rdi
callq 0x4f290
testb %al, %al
je 0x4f28b
movq 0x60(%rbx), %rdi
movq 0x38(%rbx), %rsi
movq 0x40(%rbx), %rdx
pushq $0x3e
popq %rcx
callq 0x4ed78
testb %al, %al
je 0x4f28b
movq 0x60(%rbx), %rdi
leaq 0x6280(%rip), %rsi      # 0x55502
pushq $0x1
popq %rdx
popq %rbx
jmp 0x4f58a
xorl %eax, %eax
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::write_string(scdc_transport_connection_t*, char const*, long long)
static bool write_string(scdc_transport_connection_t *transport_connection_, const char *s, scdcint_t n)
    {
      if (n < 0) n = strlen(s);

      char t[16];
      scdcint_t nt = sprintf(t, "%" scdcint_fmt, n);

      bool ret = true;

      ret = ret && write_delim(transport_connection_, t, nt, string_begin);
      ret = ret && write_bytes(transport_connection_, s, n);
      ret = ret && write_bytes(transport_connection_, &string_end, 1);
      ret = ret && write_bytes(transport_connection_, &default_delim, 1);

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
testq %rdx, %rdx
jns 0x4f2f3
movq %r14, %rdi
callq 0xb210
movq %rax, %r15
leaq 0x49c6(%rip), %rsi      # 0x53cc0
xorl %ebp, %ebp
movq %rsp, %r12
movq %r12, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0xb0c0
movslq %eax, %rdx
pushq $0x27
popq %rcx
movq %rbx, %rdi
movq %r12, %rsi
callq 0x4ed78
testb %al, %al
je 0x4f361
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x4f58a
testb %al, %al
je 0x4f35f
leaq 0x61cb(%rip), %rsi      # 0x55505
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x4f58a
testb %al, %al
je 0x4f35f
leaq 0x61b2(%rip), %rsi      # 0x55502
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x4f58a
movl %eax, %ebp
jmp 0x4f361
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_state_begin(scdc_transport_connection_t*)
static bool read_state_begin(scdc_transport_connection_t *transport_connection_)
    {
      char c;
      bool ret = read_bytes(transport_connection_, &c, 1);

      SCDC_ASSERT(c == state_begin);

      return ret;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x7(%rsp), %r14
pushq $0x1
popq %rdx
movq %r14, %rsi
callq 0x4f65c
movl %eax, %ebx
cmpb $0x3c, (%r14)
je 0x4f418
leaq 0x261e9(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4f418
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x2191(%rip), %rsi      # 0x51549
callq 0xb520
leaq 0x5a79(%rip), %rsi      # 0x54e3d
movq %rax, %rdi
callq 0xb520
leaq 0x1f71(%rip), %rsi      # 0x51344
movq %rax, %rdi
callq 0xb520
pushq $0x47
popq %rsi
movq %rax, %rdi
callq 0xb990
leaq 0x60d5(%rip), %rsi      # 0x554c2
movq %rax, %rdi
callq 0xb520
leaq 0x3a94(%rip), %rsi      # 0x52e90
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_state_end(scdc_transport_connection_t*)
static bool read_state_end(scdc_transport_connection_t *transport_connection_)
    {
      bool ret = true;

      char c;
      ret = ret && read_bytes(transport_connection_, &c, 1);
      SCDC_ASSERT(c == state_end);

      ret = ret && read_bytes(transport_connection_, &c, 1);
      SCDC_ASSERT(c == default_delim);

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0xf(%rsp), %r14
pushq $0x1
popq %rdx
movq %r14, %rsi
callq 0x4f65c
movl %eax, %ebp
cmpb $0x3e, (%r14)
je 0x4f4d1
leaq 0x26130(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4f4d1
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x20d8(%rip), %rsi      # 0x51549
callq 0xb520
leaq 0x59c0(%rip), %rsi      # 0x54e3d
movq %rax, %rdi
callq 0xb520
leaq 0x1eb8(%rip), %rsi      # 0x51344
movq %rax, %rdi
callq 0xb520
pushq $0x5e
popq %rsi
movq %rax, %rdi
callq 0xb990
leaq 0x6030(%rip), %rsi      # 0x554d6
movq %rax, %rdi
callq 0xb520
leaq 0x39db(%rip), %rsi      # 0x52e90
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
testb %bpl, %bpl
je 0x4f4ea
leaq 0xf(%rsp), %rsi
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x4f65c
movl %eax, %ebx
jmp 0x4f4ec
xorl %ebx, %ebx
cmpb $0x20, 0xf(%rsp)
je 0x4f57f
leaq 0x26082(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x18(%rdi)
je 0x4f57f
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x18(%rax), %rdi
leaq 0x202a(%rip), %rsi      # 0x51549
callq 0xb520
leaq 0x5912(%rip), %rsi      # 0x54e3d
movq %rax, %rdi
callq 0xb520
leaq 0x1e0a(%rip), %rsi      # 0x51344
movq %rax, %rdi
callq 0xb520
pushq $0x61
popq %rsi
movq %rax, %rdi
callq 0xb990
leaq 0x5ef6(%rip), %rsi      # 0x5544a
movq %rax, %rdi
callq 0xb520
leaq 0x392d(%rip), %rsi      # 0x52e90
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::write_bytes(scdc_transport_connection_t*, void const*, long long)
static bool write_bytes(scdc_transport_connection_t *transport_connection_, const void *buf, scdcint_t nbytes)
    {
      scdc_data *outgoing = transport_connection_->get_outgoing();
      bool ret = true;

      const char *src = static_cast<const char*>(buf);

      while (ret)
      {
        scdcint_t n = min(nbytes, outgoing->get_write_pos_buf_size());

        memcpy(outgoing->get_write_pos_buf(), src, n);

        src += n;
        outgoing->inc_write_pos(n);
        nbytes -= n;

        if (nbytes <= 0) break;

        ret = outgoing->do_next();
      }

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x70(%rdi), %r12
movb $0x1, %bpl
testb $0x1, %bpl
je 0x4f5f8
movq 0x80(%r15), %r13
movq 0x90(%r15), %rdi
subq %rdi, %r13
cmpq %rbx, %r13
cmovgeq %rbx, %r13
addq 0x78(%r15), %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0xb420
addq %r13, 0x90(%r15)
subq %r13, %rbx
jle 0x4f5f8
addq %r13, %r14
movq 0xa8(%r15), %rax
xorl %ebp, %ebp
testq %rax, %rax
je 0x4f5a5
movq %r12, %rdi
callq *%rax
movl %eax, %ebp
jmp 0x4f5a5
andb $0x1, %bpl
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_bytes(scdc_transport_connection_t*, void*, long long)
static bool read_bytes(scdc_transport_connection_t *transport_connection_, void *buf, scdcint_t nbytes)
    {
      scdc_data *incoming = transport_connection_->get_incoming();
      bool ret = true;

      char *dst = static_cast<char *>(buf);

      while (ret)
      {
        const char *src = incoming->get_read_pos_buf();
        scdcint_t src_size = incoming->get_read_pos_buf_size();

        scdcint_t n = min(nbytes, src_size);

        memcpy(dst, src, n);
        dst += n;

        incoming->inc_read_pos(n);
        nbytes -= n;

        if (nbytes <= 0) break;

        ret = incoming->do_next();
      }

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x30(%rdi), %r12
movb $0x1, %bpl
testb $0x1, %bpl
je 0x4f6c1
movq 0x50(%r15), %r13
movq 0x58(%r15), %rax
movq 0x38(%r15), %rsi
addq %rax, %rsi
subq %rax, %r13
cmpq %rbx, %r13
cmovgeq %rbx, %r13
movq %r14, %rdi
movq %r13, %rdx
callq 0xb420
addq %r13, 0x58(%r15)
subq %r13, %rbx
jle 0x4f6c1
addq %r13, %r14
movq 0x68(%r15), %rax
xorl %ebp, %ebp
testq %rax, %rax
je 0x4f677
movq %r12, %rdi
callq *%rax
movl %eax, %ebp
jmp 0x4f677
andb $0x1, %bpl
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_bytes(scdc_transport_connection_t*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*, long long)
static bool read_bytes(scdc_transport_connection_t *transport_connection_, string *s, scdcint_t nbytes)
    {
      scdc_data *incoming = transport_connection_->get_incoming();
      bool ret = true;

      (*s).clear();

      while (ret)
      {
        const char *src = incoming->get_read_pos_buf();
        scdcint_t src_size = incoming->get_read_pos_buf_size();

        scdcint_t n = min(nbytes, src_size);

        *s += string(src, n);

        incoming->inc_read_pos(n);
        nbytes -= n;

        if (nbytes <= 0) break;

        ret = incoming->do_next();
      }

      return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x30(%rdi), %rax
movq %rax, (%rsp)
andq $0x0, 0x8(%rsi)
movq (%rsi), %rax
movb $0x0, (%rax)
movb $0x1, %bpl
leaq 0x8(%rsp), %r13
testb $0x1, %bpl
je 0x4f76e
movq 0x50(%r15), %r12
movq 0x58(%r15), %rax
movq 0x38(%r15), %rsi
addq %rax, %rsi
subq %rax, %r12
cmpq %rbx, %r12
cmovgeq %rbx, %r12
leaq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
leaq (%rsi,%r12), %rdx
movq %r13, %rdi
callq 0x1a1f2
movq %r14, %rdi
movq %r13, %rsi
callq 0xba90
movq %r13, %rdi
callq 0xb230
addq %r12, 0x58(%r15)
subq %r12, %rbx
jle 0x4f76e
movq 0x68(%r15), %rax
xorl %ebp, %ebp
testq %rax, %rax
je 0x4f708
movq (%rsp), %rdi
callq *%rax
movl %eax, %ebp
jmp 0x4f708
andb $0x1, %bpl
movl %ebp, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::write_inout_info(scdc_transport_connection_t*, _scdc_dataset_inout_t*)
static bool write_inout_info(scdc_transport_connection_t *transport_connection_, scdc_dataset_inout_t *inout)
    {
      scdc_dataset_inout_t inout_null;
      if (!inout)
      {
        scdc_dataset_inout_unset(&inout_null);
        inout = &inout_null;
      }

      scdcint_t inout_buf_current = 0;
#if SCDC_DATASET_INOUT_BUF_MULTIPLE
      if (SCDC_DATASET_INOUT_MBUF_ISSET(inout))
      {
        scdcint_t i;
        for (i = 0; i < SCDC_DATASET_INOUT_MBUF_GET_C(inout); ++i) inout_buf_current += SCDC_DATASET_INOUT_MBUF_M_CURRENT(inout, i);

      } else
#endif
      {
        inout_buf_current = SCDC_DATASET_INOUT_BUF_CURRENT(inout);
      }

      char info[256];
      scdcint_t n = sprintf(info, "%s|%" scdcint_fmt "|%c|%" scdcint_fmt "|%d", inout->format, inout->total_size, inout->total_size_given, inout_buf_current, (inout->next)?1:0);

      if (!write_delim(transport_connection_, info, n, default_delim))
      {
        SCDC_FAIL("write_inout_info: write failed");
        return false;
      }

      return true;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x160, %rsp            # imm = 0x160
movq %rsi, %r14
movq %rdi, %rbx
testq %rsi, %rsi
jne 0x4f7bc
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x24c68
cmpq $0x0, 0x18(%r14)
movq 0x20(%r14), %r9
js 0x4f87f
movq 0x28(%r14), %rcx
movsbl 0x30(%r14), %r8d
xorl %eax, %eax
cmpq $0x0, 0x38(%r14)
setne %al
movl %eax, (%rsp)
leaq 0x5c8b(%rip), %rsi      # 0x55473
leaq 0x60(%rsp), %r15
movq %r15, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0xb0c0
movslq %eax, %rdx
pushq $0x20
popq %rcx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4ed78
movl %eax, %ebx
testb %al, %al
jne 0x4f870
leaq 0x25d68(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4f870
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x194f(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x55ba(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
leaq 0x5c32(%rip), %rsi      # 0x55486
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
movl %ebx, %eax
addq $0x160, %rsp            # imm = 0x160
popq %rbx
popq %r14
popq %r15
retq
negq %r9
xorl %eax, %eax
testq %r9, %r9
cmovleq %rax, %r9
pushq $0x10
popq %rax
movq %r9, %rcx
xorl %r9d, %r9d
subq $0x1, %rcx
jb 0x4f7cb
movq 0x10(%r14), %rdx
addq (%rdx,%rax), %r9
addq $0x18, %rax
jmp 0x4f894
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/compcoup/compcoup_transport.cc
// Function: scdc_dataset_transport::read_inout_info(scdc_transport_connection_t*, _scdc_dataset_inout_t*, bool&)
static bool read_inout_info(scdc_transport_connection_t *transport_connection_, scdc_dataset_inout_t *inout, bool &next)
    {
      scdc_dataset_inout_t inout_null;
      if (!inout) inout = &inout_null;

      string s;
      if (!read_delim(transport_connection_, &s, default_delim))
      {
        SCDC_FAIL("read_inout_info: read failed");
        return false;
      }

      /* parse format separately to allow empty format strings */
      size_t end = s.find('|');
      strncpy(inout->format, s.c_str(), end);
      inout->format[end] = '\0';

      int inext;
      int r = sscanf(s.c_str() + end, "|%" scdcint_fmt "|%c|%" scdcint_fmt "|%d", &inout->total_size, &inout->total_size_given, &SCDC_DATASET_INOUT_BUF_CURRENT(inout), &inext);

      if (r != 4)
      {
        SCDC_FAIL("read_inout_info: read failed");
        return false;
      }

      next = (inext != 0);

      return true;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rdx, %r14
movq %rsi, %r15
testq %rsi, %rsi
leaq 0x30(%rsp), %rbx
movq %rsi, %r12
cmoveq %rbx, %r12
leaq 0x20(%rsp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x10(%rsp), %rsi
pushq $0x20
popq %rdx
xorl %ecx, %ecx
callq 0x4ee36
testb %al, %al
je 0x4f967
leaq 0x10(%rsp), %r13
pushq $0x7c
popq %rsi
movq %r13, %rdi
xorl %edx, %edx
callq 0xb710
movq %rax, %rbp
movq (%r13), %r13
movq %r12, %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0xb2c0
addq %rbp, %r13
testq %r15, %r15
cmovneq %r15, %rbx
movb $0x0, (%r12,%rbp)
leaq 0x28(%rbx), %rdx
leaq 0x30(%rbx), %rcx
addq $0x20, %rbx
leaq 0x5b36(%rip), %rsi      # 0x55475
leaq 0xc(%rsp), %r9
movq %r13, %rdi
movq %rbx, %r8
xorl %eax, %eax
callq 0xb510
cmpl $0x4, %eax
sete %bl
jne 0x4f9ca
cmpl $0x0, 0xc(%rsp)
setne (%r14)
jmp 0x4fa29
leaq 0x25c12(%rip), %rbx     # 0x75580
movq (%rbx), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4f9c6
addq $0x20, %rdi
callq 0xb800
movq (%rbx), %rax
movq 0x8(%rax), %rdi
leaq 0x17f9(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x5464(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
leaq 0x5afb(%rip), %rsi      # 0x554a5
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%rbx), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %ebx, %ebx
jmp 0x4fa29
leaq 0x25baf(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x4fa29
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x1796(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0x5401(%rip), %rsi      # 0x54dff
movq %rax, %rdi
callq 0xb520
leaq 0x5a98(%rip), %rsi      # 0x554a5
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
leaq 0x10(%rsp), %rdi
callq 0xb230
movl %ebx, %eax
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4fa49
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0
nop
// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/common/data.cc
// Function: scdc_data::compact()
void scdc_data::compact()
{
  if (read_pos <= 0) return;

  SCDC_TRACE("compact: " << write_pos - read_pos << " bytes at offset " << read_pos);

  if (read_pos < write_pos) memmove(buf, buf + read_pos, write_pos - read_pos);

  write_pos -= read_pos;
  read_pos = 0;
}

// Assembly:
movq 0x28(%rdi), %rsi
testq %rsi, %rsi
jle 0x4fa9a
pushq %rbx
movq %rdi, %rbx
movq 0x20(%rdi), %rax
movq %rax, %rdx
subq %rsi, %rdx
jle 0x4fa8d
movq 0x8(%rbx), %rdi
addq %rdi, %rsi
callq 0xb940
movq 0x20(%rbx), %rax
movq 0x28(%rbx), %rsi
subq %rsi, %rax
movq %rax, 0x20(%rbx)
andq $0x0, 0x28(%rbx)
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/Andrea-Guerrieri[P]LEOSoC/LEOSoC/LEOSoC.cpp
// Function: interrupt_thread(void*)
void* interrupt_thread( void *i )
{
    
    uint32_t interrupts_pendings;
    unsigned char indx;


  while ( app_run )
    {
      usleep ( 1 );
      //printf ( "Checking interrupts \n\r" );

      interrupts_pendings = leosoc_read_reg ( AIC_INTERRUPTS_REG_0 );

      //interrupts_pendings = 0x01; //
      
      if ( interrupts_pendings )
        {
          for ( indx = 0; indx < 4; indx++ )
            {
              if ( interrupts_pendings & ( 1 << ( indx - 1 ) ) )
                {
                    pl.aaw[indx].pr.status = STATUS_ENDED;
                    printf ( "thread %d terminate \n\r", indx );
                    interrupts_pendings = 0x00; //

                }
            }
        }

    }
    
    
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
pushq $0x1
popq %rbx
pushq $0x8
popq %rbp
leaq 0x181a34(%rip), %r14    # 0x586004
movl %ebx, %edi
callq 0x534370
movl %ebp, %edi
callq 0x404842
testl %eax, %eax
je 0x4045d0
movl %eax, %r15d
leaq 0x1f0fd0(%rip), %r13    # 0x5f55bc
xorl %r12d, %r12d
cmpq $0x4, %r12
je 0x4045d0
leal -0x1(%r12), %eax
movzbl %al, %eax
btl %eax, %r15d
jae 0x40461b
movl $0x4, (%r13)
xorl %r15d, %r15d
movq %r14, %rdi
movl %r12d, %esi
xorl %eax, %eax
callq 0x4cc000
incq %r12
addq $0x30, %r13
jmp 0x4045ef