// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/extended/assembly_stats_calculator.c
// Function: gt_assembly_stats_calculator_show
void gt_assembly_stats_calculator_show(GtAssemblyStatsCalculator *asc,
    GtLogger *logger)
{
  Nstats nstats;
  unsigned int i;

  gt_assert(asc != NULL);

  /* defaults are N50/N80 */
  if (gt_array_size(asc->nstats) == 0) {
    gt_assembly_stats_calculator_register_nstat(asc, 50, NULL);
    gt_assembly_stats_calculator_register_nstat(asc, 80, NULL);
  }

  nstats.nofstats = 0;
  gt_array_sort_stable(asc->nstats, gt_assembly_stats_calculator_cmp_nstat);
  for (i = 0; i < gt_array_size(asc->nstats); i++) {
    GtUword v = *(GtUword*) gt_array_get(asc->nstats, i);
    initNstat(i, "", v, (GtUint64) (asc->sumlength * ((float) v / 100U)));
  }
  if (asc->genome_length > 0) {
    GtUword j;
    for (j = 0; j < gt_array_size(asc->nstats); j++) {
      GtUword v = *(GtUword*) gt_array_get(asc->nstats, j);
      initNstat(i + j, "G", v,
                (GtUint64) (asc->genome_length * ((float) v / 100U)));
    }
  }

  initLimit(0, 500ULL);
  initLimit(1, 1000ULL);
  initLimit(2, 10000ULL);
  initLimit(3, 100000ULL);
  initLimit(4, 1000000ULL);
  nstats.current_len = 0;
  nstats.current_num = 0;
  nstats.half_num = (GtUint64) (asc->numofseq >> 1);
  nstats.fourth_num = nstats.half_num >> 1;
  nstats.three_fourth_num = nstats.fourth_num + nstats.half_num;
  nstats.median = 0;
  nstats.first_quartile = 0;
  nstats.third_quartile = 0;
  gt_disc_distri_foreach_in_reverse_order(asc->lengths, calcNstats, &nstats);

  gt_logger_log(logger, "number of contigs:     "Formatuint64_t"",
                PRINTuint64_tcast(asc->numofseq));
  if (asc->genome_length > 0)
  {
    gt_logger_log(logger, "genome length:         "GT_WU"",
                  PRINTuint64_tcast(asc->genome_length));
  }
  gt_logger_log(logger, "total contigs length:  "Formatuint64_t"",
                PRINTuint64_tcast(asc->sumlength));
  if (asc->genome_length > 0)
  {
    gt_logger_log(logger, "   as %% of genome:     %.2f %%", (double)
                  asc->sumlength * 100 / asc->genome_length);
  }
  gt_logger_log(logger, "mean contig size:      %.2f",
                (double) asc->sumlength / asc->numofseq);
  gt_logger_log(logger, "contig size first quartile: " GT_LLU,
                nstats.first_quartile);
  gt_logger_log(logger, "median contig size:         " GT_LLU, nstats.median);
  gt_logger_log(logger, "contig size third quartile: " GT_LLU,
                nstats.third_quartile);
  gt_logger_log(logger, "longest contig:             " GT_WU, asc->maxlength);
  gt_logger_log(logger, "shortest contig:            " GT_WU, asc->minlength);
  gt_logger_log(logger, "contigs > 500 nt:           " GT_LLU " (%.2f %%)",
                nstats.larger_than_limit[0], (double)
                nstats.larger_than_limit[0] * 100 / asc->numofseq);
  gt_logger_log(logger, "contigs > 1K nt:            " GT_LLU " (%.2f %%)",
                nstats.larger_than_limit[1], (double)
                nstats.larger_than_limit[1] * 100 / asc->numofseq);
  gt_logger_log(logger, "contigs > 10K nt:           " GT_LLU " (%.2f %%)",
                nstats.larger_than_limit[2], (double)
                nstats.larger_than_limit[2] * 100 / asc->numofseq);
  gt_logger_log(logger, "contigs > 100K nt:          " GT_LLU " (%.2f %%)",
                nstats.larger_than_limit[3], (double)
                nstats.larger_than_limit[3] * 100 / asc->numofseq);
  gt_logger_log(logger, "contigs > 1M nt:            " GT_LLU " (%.2f %%)",
                nstats.larger_than_limit[4], (double)
                nstats.larger_than_limit[4] * 100 / asc->numofseq);
  for (i = 0; i < nstats.nofstats ; i++)
  {
    if (nstats.nvalue[i] > 0)
    {
      gt_logger_log(logger, "N%s%02d                "GT_WU"", nstats.name[i],
          (int) nstats.val[i], nstats.nvalue[i]);
      gt_logger_log(logger, "L%s%02d                "GT_WU"", nstats.name[i],
          (int) nstats.val[i], nstats.lvalue[i]);
    }
    else
    {
      gt_logger_log(logger, "N%s%02d                n.a.",
          nstats.name[i], (int) nstats.val[i]);
      gt_logger_log(logger, "L%s%02d                n.a.",
          nstats.name[i], (int) nstats.val[i]);
    }
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x238, %rsp            # imm = 0x238
testq %rdi, %rdi
je 0x12c392
movq %rsi, %rbx
movq %rdi, %r14
movq 0x30(%rdi), %rdi
callq 0xd4a9a
testq %rax, %rax
jne 0x12bc95
movl $0x32, %esi
movq %r14, %rdi
xorl %edx, %edx
callq 0x12bb77
movl $0x50, %esi
movq %r14, %rdi
xorl %edx, %edx
callq 0x12bb77
movl $0x0, 0x230(%rsp)
movq 0x30(%r14), %rdi
leaq 0x6ec(%rip), %rsi       # 0x12c397
callq 0xd4b0d
movq 0x30(%r14), %rdi
callq 0xd4a9a
testq %rax, %rax
je 0x12bdaa
movl $0x1, %ebp
xorl %r12d, %r12d
leaq 0x2a7bbf(%rip), %r13    # 0x3d3890
xorl %r15d, %r15d
movq 0x30(%r14), %rdi
movq %r15, %rsi
callq 0xd47ba
movq (%rax), %rax
movq %r13, (%rsp,%r15,8)
movq %rax, 0x1e0(%rsp,%r15,8)
movq 0x8(%r14), %rcx
testq %rcx, %rcx
js 0x12bd02
xorps %xmm0, %xmm0
cvtsi2ss %rcx, %xmm0
jmp 0x12bd1a
movq %rcx, %rdx
shrq %rdx
andl $0x1, %ecx
orq %rdx, %rcx
xorps %xmm0, %xmm0
cvtsi2ss %rcx, %xmm0
addss %xmm0, %xmm0
testq %rax, %rax
js 0x12bd29
xorps %xmm1, %xmm1
cvtsi2ss %rax, %xmm1
jmp 0x12bd41
movq %rax, %rcx
shrq %rcx
andl $0x1, %eax
orq %rcx, %rax
xorps %xmm1, %xmm1
cvtsi2ss %rax, %xmm1
addss %xmm1, %xmm1
divss 0x2315a7(%rip), %xmm1   # 0x35d2f0
mulss %xmm0, %xmm1
cvttss2si %xmm1, %rax
movq %rax, %rcx
sarq $0x3f, %rcx
subss 0x2546ff(%rip), %xmm1   # 0x380460
cvttss2si %xmm1, %rdx
andq %rcx, %rdx
orq %rax, %rdx
movq %rdx, 0xe0(%rsp,%r15,8)
movq %r12, 0x140(%rsp,%r15,8)
movq %r12, 0x190(%rsp,%r15,8)
movb $0x0, 0x50(%rsp,%r15)
incl 0x230(%rsp)
movl %ebp, %r15d
movq 0x30(%r14), %rdi
callq 0xd4a9a
incl %ebp
cmpq %r15, %rax
ja 0x12bcd4
jmp 0x12bdad
xorl %r15d, %r15d
cmpq $0x0, 0x20(%r14)
je 0x12bebb
movq 0x30(%r14), %rdi
callq 0xd4a9a
testq %rax, %rax
je 0x12bebb
movq %rsp, %rax
leaq (%r15,%rax), %r12
addq $0x50, %r12
leaq (%rsp,%r15,8), %r13
addq $0x1e0, %r13            # imm = 0x1E0
xorl %ebp, %ebp
xorl %r15d, %r15d
movq 0x30(%r14), %rdi
movq %r15, %rsi
callq 0xd47ba
movq (%rax), %rax
leaq 0x288890(%rip), %rcx    # 0x3b468b
movq %rcx, -0x1e0(%r13,%r15,8)
movq %rax, (%r13,%r15,8)
movq 0x20(%r14), %rcx
testq %rcx, %rcx
js 0x12be1b
xorps %xmm0, %xmm0
cvtsi2ss %rcx, %xmm0
jmp 0x12be33
movq %rcx, %rdx
shrq %rdx
andl $0x1, %ecx
orq %rdx, %rcx
xorps %xmm0, %xmm0
cvtsi2ss %rcx, %xmm0
addss %xmm0, %xmm0
testq %rax, %rax
js 0x12be42
xorps %xmm1, %xmm1
cvtsi2ss %rax, %xmm1
jmp 0x12be5a
movq %rax, %rcx
shrq %rcx
andl $0x1, %eax
orq %rcx, %rax
xorps %xmm1, %xmm1
cvtsi2ss %rax, %xmm1
addss %xmm1, %xmm1
divss 0x23148e(%rip), %xmm1   # 0x35d2f0
mulss %xmm0, %xmm1
cvttss2si %xmm1, %rax
movq %rax, %rcx
sarq $0x3f, %rcx
subss 0x2545e6(%rip), %xmm1   # 0x380460
cvttss2si %xmm1, %rdx
andq %rcx, %rdx
orq %rax, %rdx
movq %rdx, -0x100(%r13,%r15,8)
movq %rbp, -0xa0(%r13,%r15,8)
movq %rbp, -0x50(%r13,%r15,8)
movb $0x0, (%r12,%r15)
incl 0x230(%rsp)
incq %r15
movq 0x30(%r14), %rdi
callq 0xd4a9a
cmpq %rax, %r15
jb 0x12bde5
movq %rsp, %rdx
movq $0x1f4, 0xb0(%rdx) # imm = 0x1F4
xorl %eax, %eax
movq %rax, 0x88(%rdx)
movq $0x3e8, 0xb8(%rdx) # imm = 0x3E8
xorps %xmm0, %xmm0
movups %xmm0, 0x90(%rdx)
movq $0x2710, 0xc0(%rdx) # imm = 0x2710
movq $0x186a0, 0xc8(%rdx) # imm = 0x186A0
movups %xmm0, 0xa0(%rdx)
movq $0xf4240, 0xd0(%rdx) # imm = 0xF4240
movups %xmm0, 0x60(%rdx)
movq (%r14), %rcx
movq %rcx, %rsi
shrq %rsi
movq %rsi, 0x80(%rdx)
shrq $0x2, %rcx
movq %rcx, 0x78(%rdx)
addq %rsi, %rcx
movq %rcx, 0x138(%rdx)
movq %rax, 0xd8(%rdx)
movq %rax, 0x70(%rdx)
movq %rax, 0x130(%rdx)
movq 0x28(%r14), %rdi
leaq -0x494(%rip), %rsi      # 0x12babe
callq 0xe9c6b
movq (%r14), %rdx
leaq 0x254668(%rip), %rsi    # 0x3805c9
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x20(%r14), %rdx
testq %rdx, %rdx
je 0x12bf85
leaq 0x254669(%rip), %rsi    # 0x3805e4
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x8(%r14), %rdx
leaq 0x25466f(%rip), %rsi    # 0x3805ff
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x20(%r14), %rax
testq %rax, %rax
je 0x12c002
movsd 0x8(%r14), %xmm1
movsd 0x22492f(%rip), %xmm2   # 0x3508e0
unpcklps %xmm2, %xmm1            # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x224934(%rip), %xmm3   # 0x3508f0
subpd %xmm3, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
mulsd 0x22681c(%rip), %xmm0   # 0x3527f0
movq %rax, %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
leaq 0x254622(%rip), %rsi    # 0x38061a
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
movdqu (%r14), %xmm1
movdqa 0x254411(%rip), %xmm0   # 0x380420
pand %xmm1, %xmm0
por 0x254415(%rip), %xmm0   # 0x380430
psrlq $0x20, %xmm1
por 0x254418(%rip), %xmm1   # 0x380440
subpd 0x254420(%rip), %xmm1   # 0x380450
addpd %xmm0, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
divsd %xmm1, %xmm0
leaq 0x2545f3(%rip), %rsi    # 0x38063a
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
movq 0x70(%rsp), %rdx
leaq 0x2545f9(%rip), %rsi    # 0x380656
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0xd8(%rsp), %rdx
leaq 0x254601(%rip), %rsi    # 0x380677
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x130(%rsp), %rdx
leaq 0x254609(%rip), %rsi    # 0x380698
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x18(%r14), %rdx
leaq 0x254615(%rip), %rsi    # 0x3806b9
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x10(%r14), %rdx
leaq 0x254620(%rip), %rsi    # 0x3806d9
movq %rbx, %rdi
xorl %eax, %eax
callq 0x10906e
movq 0x88(%rsp), %rdx
movq %rdx, %xmm1
movq 0x224808(%rip), %xmm0   # 0x3508e0
punpckldq %xmm0, %xmm1    # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
movdqa %xmm0, %xmm2
movapd 0x224808(%rip), %xmm0   # 0x3508f0
subpd %xmm0, %xmm1
movapd %xmm0, %xmm3
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
mulsd 0x2266ec(%rip), %xmm0   # 0x3527f0
movq (%r14), %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
leaq 0x2545d1(%rip), %rsi    # 0x3806f9
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
movq 0x90(%rsp), %rdx
movq %rdx, %xmm1
movq 0x224799(%rip), %xmm2   # 0x3508e0
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x22479d(%rip), %xmm3   # 0x3508f0
subpd %xmm3, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
mulsd 0x226685(%rip), %xmm0   # 0x3527f0
movq (%r14), %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
leaq 0x254595(%rip), %rsi    # 0x380724
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
movq 0x98(%rsp), %rdx
movq %rdx, %xmm1
movq 0x224732(%rip), %xmm2   # 0x3508e0
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x224736(%rip), %xmm3   # 0x3508f0
subpd %xmm3, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
mulsd 0x22661e(%rip), %xmm0   # 0x3527f0
movq (%r14), %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
leaq 0x254559(%rip), %rsi    # 0x38074f
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
movq 0xa0(%rsp), %rdx
movq %rdx, %xmm1
movq 0x2246cb(%rip), %xmm2   # 0x3508e0
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x2246cf(%rip), %xmm3   # 0x3508f0
subpd %xmm3, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
mulsd 0x2265b7(%rip), %xmm0   # 0x3527f0
movq (%r14), %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
leaq 0x25451d(%rip), %rsi    # 0x38077a
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
movq 0xa8(%rsp), %rdx
movq %rdx, %xmm1
movq 0x224664(%rip), %xmm2   # 0x3508e0
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x224668(%rip), %xmm3   # 0x3508f0
subpd %xmm3, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
mulsd 0x226550(%rip), %xmm0   # 0x3527f0
movq (%r14), %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
leaq 0x2544e1(%rip), %rsi    # 0x3807a5
movq %rbx, %rdi
movb $0x1, %al
callq 0x10906e
cmpl $0x0, 0x230(%rsp)
je 0x12c380
leaq 0x254523(%rip), %r14    # 0x380806
leaq 0x254538(%rip), %r15    # 0x380822
leaq 0x2544df(%rip), %r12    # 0x3807d0
leaq 0x2544f3(%rip), %r13    # 0x3807eb
xorl %ebp, %ebp
movq (%rsp,%rbp,8), %rdx
movq 0x140(%rsp,%rbp,8), %r8
testq %r8, %r8
je 0x12c341
movl 0x1e0(%rsp,%rbp,8), %ecx
movq %rbx, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0x10906e
movl 0x1e0(%rsp,%rbp,8), %ecx
movq (%rsp,%rbp,8), %rdx
movq 0x190(%rsp,%rbp,8), %r8
movq %rbx, %rdi
movq %r13, %rsi
xorl %eax, %eax
callq 0x10906e
jmp 0x12c36d
movl 0x1e0(%rsp,%rbp,8), %ecx
movq %rbx, %rdi
movq %r14, %rsi
xorl %eax, %eax
callq 0x10906e
movq (%rsp,%rbp,8), %rdx
movl 0x1e0(%rsp,%rbp,8), %ecx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x10906e
incq %rbp
movl 0x230(%rsp), %eax
cmpq %rax, %rbp
jb 0x12c2fa
addq $0x238, %rsp            # imm = 0x238
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x3bb9f