// File: /workspace/github_c_makefile_star2_O0/zhou-lab[P]tbmate/chunk.c
// Function: tbk_print1
void tbk_print1(tbk_data_t *d, int i, view_conf_t *conf, kstring_t *ks) {

  switch(DATA_TYPE(d->dtype)) {
  case DT_INT1: {
    ksprintf(ks, "\t%d", ((uint8_t*)(d->data))[i]);
    break;
  }
  case DT_INT2: {
    ksprintf(ks, "\t%d", ((uint8_t*)(d->data))[i]);
    break;
  }
  case DT_INT32: {
    int data = ((int32_t*) (d->data))[i];
    if (conf->na_for_negative && data < 0) { kputc('\t', ks); kputs(conf->na_token, ks); }
    else ksprintf(ks, "\t%d", data);
    break;
  }
  case DT_FLOAT: {
    float data = ((float*) (d->data))[i];
    if (conf->na_for_negative && data < 0) { kputc('\t', ks); kputs(conf->na_token, ks); }
    else ksprintf(ks, "\t%f", data);
    break;
  }
  case DT_DOUBLE: {
    double data = ((double*) (d->data))[i];
    if (conf->na_for_negative && data < 0) { kputc('\t', ks); kputs(conf->na_token, ks); }
    else ksprintf(ks, "\t%f", data);
    break;
  }
  case DT_STRINGF: {
    char *data = ((char*) (d->data)) + i*STRING_MAX(d->dtype);
    kputc('\t', ks); kputs(data, ks);
    break;
  }
  case DT_STRINGD: {
    char *data = ((char**) (d->data))[i];
    kputc('\t', ks); kputs(data, ks);
    free(data);
    break;
  }
  case DT_ONES: {
    float data = ((float*) (d->data))[i];
    if (conf->na_for_negative && data < 0) { kputc('\t', ks); kputs(conf->na_token, ks); }
    else ksprintf(ks, "\t%.*f", conf->precision, data);
    break;
  }
  case DT_FLOAT_INT: {
    float data = ((float*) (d->data))[i*2];
    int data2 = ((int32_t*) (d->data))[i*2+1];
    if (conf->na_for_negative && data < 0) {
      kputc('\t', ks); kputs(conf->na_token, ks);
    } else {
      if (conf->min_coverage >= 0 && data2 < conf->min_coverage) {
        kputc('\t', ks); kputs(conf->na_token, ks);
      } else {
        ksprintf(ks, "\t%f", data);
      }
    }
    if (conf->print_all_units) ksprintf(ks, "\t%d", data2);
    break;
  }
  case DT_FLOAT_FLOAT: {
    float data = ((float*) (d->data))[i*2];
    float data2 = ((float*) (d->data))[i*2+1];
    if (conf->na_for_negative && data < 0) {
      kputc('\t', ks); kputs(conf->na_token, ks);
    } else {
      if (conf->max_pval >= 0 && data2 > conf->max_pval) {
        kputc('\t', ks); kputs(conf->na_token, ks);
      } else {
        ksprintf(ks, "\t%f", data);
      }
    }
    if (conf->print_all_units) ksprintf(ks, "\t%f", data2);
    break;
  }
  default: wzfatal("Unrecognized data type: %d.\n", DATA_TYPE(d->dtype));
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rax
movzbl (%rax), %eax
decq %rax
movq %rax, -0x60(%rbp)
subq $0x1f, %rax
ja 0x6bad
movq -0x60(%rbp), %rax
leaq 0x6f32e(%rip), %rcx     # 0x75a98
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x20(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movzbl (%rax,%rcx), %edx
leaq 0x6ec24(%rip), %rsi     # 0x753b2
movb $0x0, %al
callq 0xb660
jmp 0x6bc9
movq -0x20(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movzbl (%rax,%rcx), %edx
leaq 0x6ebfd(%rip), %rsi     # 0x753b2
movb $0x0, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x24(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x6804
cmpl $0x0, -0x24(%rbp)
jge 0x6804
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6819
movq -0x20(%rbp), %rdi
movl -0x24(%rbp), %edx
leaq 0x6eba0(%rip), %rsi     # 0x753b2
movb $0x0, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, -0x28(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x6868
xorps %xmm0, %xmm0
ucomiss -0x28(%rbp), %xmm0
jbe 0x6868
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6883
movq -0x20(%rbp), %rdi
movss -0x28(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x6eb3a(%rip), %rsi     # 0x753b6
movb $0x1, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movsd %xmm0, -0x30(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x68d3
xorps %xmm0, %xmm0
ucomisd -0x30(%rbp), %xmm0
jbe 0x68d3
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x68ea
movq -0x20(%rbp), %rdi
movsd -0x30(%rbp), %xmm0
leaq 0x6ead3(%rip), %rsi     # 0x753b6
movb $0x1, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movq -0x8(%rbp), %rdx
movq (%rdx), %rdx
shrq $0x8, %rdx
imulq %rdx, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x38(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
movq -0x40(%rbp), %rdi
callq 0x3370
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0xc(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, -0x44(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x69b8
xorps %xmm0, %xmm0
ucomiss -0x44(%rbp), %xmm0
jbe 0x69b8
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x69d9
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl (%rax), %edx
movss -0x44(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x6e9e8(%rip), %rsi     # 0x753ba
movb $0x1, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movl -0xc(%rbp), %ecx
shll %ecx
movslq %ecx, %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, -0x48(%rbp)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movl -0xc(%rbp), %ecx
shll %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x4c(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x6a45
xorps %xmm0, %xmm0
ucomiss -0x48(%rbp), %xmm0
jbe 0x6a45
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6a99
movq -0x18(%rbp), %rax
cmpl $0x0, 0x34(%rax)
jl 0x6a7c
movl -0x4c(%rbp), %eax
movq -0x18(%rbp), %rcx
cmpl 0x34(%rcx), %eax
jge 0x6a7c
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6a97
movq -0x20(%rbp), %rdi
movss -0x48(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x6e926(%rip), %rsi     # 0x753b6
movb $0x1, %al
callq 0xb660
jmp 0x6a99
movq -0x18(%rbp), %rax
cmpl $0x0, 0xc(%rax)
je 0x6ab8
movq -0x20(%rbp), %rdi
movl -0x4c(%rbp), %edx
leaq 0x6e901(%rip), %rsi     # 0x753b2
movb $0x0, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movl -0xc(%rbp), %ecx
shll %ecx
movslq %ecx, %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, -0x50(%rbp)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movl -0xc(%rbp), %ecx
shll %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, -0x54(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x6b28
xorps %xmm0, %xmm0
ucomiss -0x50(%rbp), %xmm0
jbe 0x6b28
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6b86
movq -0x18(%rbp), %rax
movss 0x30(%rax), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jb 0x6b69
movss -0x54(%rbp), %xmm0
movq -0x18(%rbp), %rax
ucomiss 0x30(%rax), %xmm0
jbe 0x6b69
movq -0x20(%rbp), %rsi
movl $0x9, %edi
callq 0x6bd0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rsi
callq 0x6d20
jmp 0x6b84
movq -0x20(%rbp), %rdi
movss -0x50(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x6e839(%rip), %rsi     # 0x753b6
movb $0x1, %al
callq 0xb660
jmp 0x6b86
movq -0x18(%rbp), %rax
cmpl $0x0, 0xc(%rax)
je 0x6bab
movq -0x20(%rbp), %rdi
movss -0x54(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x6e812(%rip), %rsi     # 0x753b6
movb $0x1, %al
callq 0xb660
jmp 0x6bc9
movq -0x8(%rbp), %rax
movq (%rax), %rsi
andq $0xff, %rsi
leaq 0x6e7fe(%rip), %rdi     # 0x753c0
movb $0x0, %al
callq 0x6d60
addq $0x60, %rsp
popq %rbp
retq
nop