// File: /workspace/github_cpp_makefile_star2_O3/mh0fm4[P]SCDC/src/components/dataset/dataset_inout.cc
// Function: scdc_args_get_va(void*, long long, void*)
static scdc_arg_ref_t scdc_args_get_va(void *data, scdcint_t type, void *v)
{
  scdc_args_data_va_t *data_va = static_cast<scdc_args_data_va_t *>(data);

  SCDC_TRACE("scdc_args_get_va: data: '" << data_va << "' (arg: '" << data_va->arg << "', ap: '" << data_va->ap << "'), type: '" << type << "', v: " << v);

  switch (type)
  {
    case SCDC_ARGS_TYPE_INT:
      *((int *) v) = va_arg(*data_va->ap, int);
      data_va->arg += 1;
      return SCDC_ARG_REF_NONE;
    case SCDC_ARGS_TYPE_SCDCINT:
      *((scdcint_t *) v) = va_arg(*data_va->ap, scdcint_t);
      data_va->arg += 1;
      return SCDC_ARG_REF_NONE;
    case SCDC_ARGS_TYPE_CSTR:
    case SCDC_ARGS_TYPE_PTR:
    case SCDC_ARGS_TYPE_IN_STREAM:
    case SCDC_ARGS_TYPE_OUT_STREAM:
      *((void **) v) = va_arg(*data_va->ap, void *);
      data_va->arg += 1;
      return SCDC_ARG_REF_NONE;
    case SCDC_ARGS_TYPE_BUF:
      ((scdc_args_buf_t *) v)->buf = va_arg(*data_va->ap, void *);
      ((scdc_args_buf_t *) v)->buf_size = va_arg(*data_va->ap, scdcint_t);
      data_va->arg += 2;
      return SCDC_ARG_REF_NONE;
    case SCDC_ARGS_TYPE_DATASET_INPUT:
    {
      scdc_dataset_input_t *input = va_arg(*data_va->ap, scdc_dataset_input_t *);
      *((scdc_dataset_input_t *) v) = *input;
      data_va->arg += 1;
      return static_cast<scdc_arg_ref_t>(input);
    }
    case SCDC_ARGS_TYPE_DATASET_OUTPUT:
    {
      scdc_dataset_output_t *output = va_arg(*data_va->ap, scdc_dataset_output_t *);
      *((scdc_dataset_output_t *) v) = *output;
      data_va->arg += 1;
      return static_cast<scdc_arg_ref_t>(output);
    }
  }

  SCDC_TRACE("scdc_args_get_va: error: unknown type '" << type << "'");

  return SCDC_ARG_REF_NULL;
}

// Assembly:
xorl %eax, %eax
decq %rsi
cmpq $0x9, %rsi
ja 0x2fdd5
movq %rdi, %r8
leaq 0x3b2ed(%rip), %rcx     # 0x6afc0
movslq (%rcx,%rsi,4), %rsi
addq %rcx, %rsi
jmpq *%rsi
movq 0x8(%r8), %rax
movl (%rax), %esi
cmpq $0x28, %rsi
ja 0x2fcf6
movq %rsi, %rcx
addq 0x10(%rax), %rcx
addl $0x8, %esi
movl %esi, (%rax)
jmp 0x2fd02
movq 0x8(%rax), %rcx
leaq 0x8(%rcx), %rsi
movq %rsi, 0x8(%rax)
movq (%rcx), %rax
movq %rax, (%rdx)
movl $0x1, %ecx
movl $0x1, %eax
jmp 0x2fdd2
movq 0x8(%r8), %rax
movl (%rax), %esi
cmpq $0x28, %rsi
ja 0x2fd65
movq %rsi, %rcx
addq 0x10(%rax), %rcx
addl $0x8, %esi
movl %esi, (%rax)
jmp 0x2fd71
movq 0x8(%r8), %rax
movl (%rax), %esi
cmpq $0x28, %rsi
ja 0x2fd89
movq %rsi, %rcx
addq 0x10(%rax), %rcx
addl $0x8, %esi
movl %esi, (%rax)
jmp 0x2fd95
movq 0x8(%r8), %rax
movl (%rax), %esi
cmpq $0x28, %rsi
ja 0x2fdd6
movq %rsi, %rcx
addq 0x10(%rax), %rcx
addl $0x8, %esi
movl %esi, (%rax)
jmp 0x2fde2
movq 0x8(%rax), %rcx
leaq 0x8(%rcx), %rsi
movq %rsi, 0x8(%rax)
movq (%rcx), %rax
movl $0xb, %ecx
movq %rdx, %rdi
movq %rax, %rsi
rep  movsq (%rsi), %es:(%rdi)
movl $0x1, %ecx
jmp 0x2fdd2
movq 0x8(%rax), %rcx
leaq 0x8(%rcx), %rsi
movq %rsi, 0x8(%rax)
movq (%rcx), %rax
movq %rax, (%rdx)
movq 0x8(%r8), %rax
movl (%rax), %esi
cmpq $0x28, %rsi
ja 0x2fdb5
movq %rsi, %rcx
addq 0x10(%rax), %rcx
addl $0x8, %esi
movl %esi, (%rax)
jmp 0x2fdc1
movq 0x8(%rax), %rcx
leaq 0x8(%rcx), %rsi
movq %rsi, 0x8(%rax)
movq (%rcx), %rax
movq %rax, 0x8(%rdx)
movl $0x1, %eax
movl $0x2, %ecx
addq %rcx, (%r8)
retq
movq 0x8(%rax), %rcx
leaq 0x8(%rcx), %rsi
movq %rsi, 0x8(%rax)
movl (%rcx), %eax
movl %eax, (%rdx)
jmp 0x2fd08