// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/fmi-fwduni.c
// Function: gt_skfmmstats
GtUword gt_skfmmstats (const void *genericindex,
                          GT_UNUSED GtUword offset,
                          GT_UNUSED GtUword left,
                          GT_UNUSED GtUword right,
                          GtUword *witnessposition,
                          const GtUchar *qstart,
                          const GtUchar *qend)
{
  GtUchar cc;
  const GtUchar *qptr;
  GtUword prevlbound;
  GtUword matchlength;
  GtUwordBound bwtbound;
  const Fmindex *fmindex = (Fmindex *) genericindex;

  gt_assert(qstart < qend);
  qptr = qstart;
  cc = *qptr;
  if (GT_ISSPECIAL(cc))
  {
    return 0;
  }
  bwtbound.lbound = fmindex->tfreq[cc];
  bwtbound.ubound = fmindex->tfreq[cc+1];
  if (bwtbound.lbound >= bwtbound.ubound)
  {
    return 0;
  }
  prevlbound = bwtbound.lbound;
  for (qptr++; qptr < qend; qptr++)
  {
    cc = *qptr;
    if (GT_ISSPECIAL (cc))
    {
      break;
    }
    bwtbound.lbound = fmindex->tfreq[cc] +
                      fmoccurrence (fmindex, cc, bwtbound.lbound);
    bwtbound.ubound = fmindex->tfreq[cc] +
                      fmoccurrence (fmindex, cc, bwtbound.ubound);
    if (bwtbound.lbound >= bwtbound.ubound)
    {
      break;
    }
    prevlbound = bwtbound.lbound;
  }
  matchlength = (GtUword) (qptr - qstart);
  if (witnessposition != NULL)
  {
    GtUword startpos = gt_fmfindtextpos (fmindex,prevlbound);
    gt_assert((fmindex->bwtlength-1) >= (startpos + matchlength));
    *witnessposition = (fmindex->bwtlength-1) - (startpos + matchlength);
  }
  return matchlength;
}

// Assembly:
subq $0x88, %rsp
movq 0x90(%rsp), %rax
movq %rdi, 0x78(%rsp)
movq %rsi, 0x70(%rsp)
movq %rdx, 0x68(%rsp)
movq %rcx, 0x60(%rsp)
movq %r8, 0x58(%rsp)
movq %r9, 0x50(%rsp)
movq 0x78(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x50(%rsp), %rax
cmpq 0x90(%rsp), %rax
jb 0x24ba0e
movq 0x3f05c3(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2ca62c(%rip), %rsi    # 0x516013
leaq 0x329b29(%rip), %rdx    # 0x575517
leaq 0x32d332(%rip), %rcx    # 0x578d27
leaq 0x32d314(%rip), %r8     # 0x578d10
movl $0x55, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x24ba10
movq 0x50(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x40(%rsp), %rax
movb (%rax), %al
movb %al, 0x4f(%rsp)
movzbl 0x4f(%rsp), %eax
cmpl $0xfe, %eax
jl 0x24ba42
movq $0x0, 0x80(%rsp)
jmp 0x24bc34
movq 0x18(%rsp), %rax
movq 0x18(%rax), %rax
movzbl 0x4f(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x20(%rsp)
movq 0x18(%rsp), %rax
movq 0x18(%rax), %rax
movzbl 0x4f(%rsp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x28(%rsp)
movq 0x20(%rsp), %rax
cmpq 0x28(%rsp), %rax
jb 0x24ba93
movq $0x0, 0x80(%rsp)
jmp 0x24bc34
movq 0x20(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x40(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x40(%rsp)
movq 0x40(%rsp), %rax
cmpq 0x90(%rsp), %rax
jae 0x24bb7d
movq 0x40(%rsp), %rax
movb (%rax), %al
movb %al, 0x4f(%rsp)
movzbl 0x4f(%rsp), %eax
cmpl $0xfe, %eax
jl 0x24bada
jmp 0x24bb7d
movq 0x18(%rsp), %rax
movq 0x18(%rax), %rax
movzbl 0x4f(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, (%rsp)
movq 0x18(%rsp), %rdi
movb 0x4f(%rsp), %al
movq 0x20(%rsp), %rdx
movzbl %al, %esi
callq 0x24b3f0
movq %rax, %rcx
movq (%rsp), %rax
addq %rcx, %rax
movq %rax, 0x20(%rsp)
movq 0x18(%rsp), %rax
movq 0x18(%rax), %rax
movzbl 0x4f(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movb 0x4f(%rsp), %al
movq 0x28(%rsp), %rdx
movzbl %al, %esi
callq 0x24b3f0
movq %rax, %rcx
movq 0x8(%rsp), %rax
addq %rcx, %rax
movq %rax, 0x28(%rsp)
movq 0x20(%rsp), %rax
cmpq 0x28(%rsp), %rax
jb 0x24bb60
jmp 0x24bb7d
movq 0x20(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x40(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x40(%rsp)
jmp 0x24baab
movq 0x40(%rsp), %rax
movq 0x50(%rsp), %rcx
subq %rcx, %rax
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x58(%rsp)
je 0x24bc27
movq 0x18(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x24bc50
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rax
movq 0x10(%rax), %rax
subq $0x1, %rax
movq 0x10(%rsp), %rcx
addq 0x30(%rsp), %rcx
cmpq %rcx, %rax
jae 0x24bc03
movq 0x3f03ce(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2ca437(%rip), %rsi    # 0x516013
leaq 0x32d152(%rip), %rdx    # 0x578d35
leaq 0x32d13d(%rip), %rcx    # 0x578d27
leaq 0x32d11f(%rip), %r8     # 0x578d10
movl $0x78, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x24bc05
movq 0x18(%rsp), %rax
movq 0x10(%rax), %rcx
subq $0x1, %rcx
movq 0x10(%rsp), %rax
addq 0x30(%rsp), %rax
subq %rax, %rcx
movq 0x58(%rsp), %rax
movq %rcx, (%rax)
movq 0x30(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x80(%rsp), %rax
addq $0x88, %rsp
retq
nopw %cs:(%rax,%rax)
nop