// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/sfx-linlcp.c
// Function: gt_ENCSEQ_inversesuffixarray2specialranknext
static void gt_ENCSEQ_inversesuffixarray2specialranknext(
                         const GtCompactUlongStore *rightposinverse,
                         GtCompactUlongStore *ranknext,
                         const GtEncseq *encseq,
                         GtReadmode readmode,
                         GtUword partwidth,
                         GtUword totallength)
{
  if (gt_encseq_has_specialranges(encseq))
  {
    GtSpecialrangeiterator *sri;
    GtRange range;
    GtUword idx, *rightofpartwidth = NULL,
                  specialranklistindex, nextrightofpartwidth = 0;

    rightofpartwidth = gt_ENCSEQ_fill_right_of_partwidth(rightposinverse,
                                                         encseq,
                                                         readmode,
                                                         partwidth,
                                                         totallength);
    specialranklistindex = partwidth;
    sri = gt_specialrangeiterator_new(encseq,
                                      GT_ISDIRREVERSE(readmode) ? false : true);
    nextrightofpartwidth = 0;
    while (gt_specialrangeiterator_next(sri, &range))
    {
      if (GT_ISDIRREVERSE(readmode))
      {
        gt_range_reverse(totallength, &range);
      }
      gt_assert(range.end <= totallength);
      for (idx = range.start; idx < range.end-1; idx++)
      {
        gt_assert(specialranklistindex < totallength);
        gt_compact_ulong_store_update(ranknext, specialranklistindex,
                                      specialranklistindex + 1);
        specialranklistindex++;
      }
      gt_assert(specialranklistindex < totallength);
      if (range.end < partwidth)
      {
        gt_compact_ulong_store_update(ranknext, specialranklistindex,
                                      gt_compact_ulong_store_get(
                                             rightposinverse, range.end));
      } else
      {
        gt_compact_ulong_store_update(ranknext, specialranklistindex,
                                      rightofpartwidth[nextrightofpartwidth]);
        nextrightofpartwidth++;
      }
      specialranklistindex++;
    }
    gt_free(rightofpartwidth);
    gt_assert(specialranklistindex == totallength);
    gt_specialrangeiterator_delete(sri);
  }
}

// Assembly:
subq $0x88, %rsp
movq %rdi, 0x80(%rsp)
movq %rsi, 0x78(%rsp)
movq %rdx, 0x70(%rsp)
movl %ecx, 0x6c(%rsp)
movq %r8, 0x60(%rsp)
movq %r9, 0x58(%rsp)
movq 0x70(%rsp), %rdi
callq 0xaf360
testb $0x1, %al
jne 0x2c8aaa
jmp 0x2c8d92
movq $0x0, 0x30(%rsp)
movq $0x0, 0x20(%rsp)
movq 0x80(%rsp), %rdi
movq 0x70(%rsp), %rsi
movl 0x6c(%rsp), %edx
movq 0x60(%rsp), %rcx
movq 0x58(%rsp), %r8
callq 0x2c93e0
movq %rax, 0x30(%rsp)
movq 0x60(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x10(%rsp)
movb $0x1, %al
cmpl $0x1, 0x6c(%rsp)
movb %al, 0x1f(%rsp)
je 0x2c8b0e
cmpl $0x3, 0x6c(%rsp)
sete %al
movb %al, 0x1f(%rsp)
movq 0x10(%rsp), %rdi
movb 0x1f(%rsp), %dl
movl $0x1, %eax
xorl %ecx, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
cmpl $0x0, %eax
setne %al
movzbl %al, %esi
andl $0x1, %esi
callq 0xaf650
movq %rax, 0x50(%rsp)
movq $0x0, 0x20(%rsp)
movq 0x50(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0xaf770
testb $0x1, %al
jne 0x2c8b5b
jmp 0x2c8d2c
cmpl $0x1, 0x6c(%rsp)
je 0x2c8b69
cmpl $0x3, 0x6c(%rsp)
jne 0x2c8b78
movq 0x58(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0xc2f20
jmp 0x2c8b7a
movq 0x48(%rsp), %rax
cmpq 0x58(%rsp), %rax
jbe 0x2c8bbe
movq 0x373413(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x24d47c(%rip), %rsi    # 0x516013
leaq 0x2c2180(%rip), %rdx    # 0x58ad1e
leaq 0x2c2192(%rip), %rcx    # 0x58ad37
leaq 0x2c1fd6(%rip), %r8     # 0x58ab82
movl $0x156, %r9d            # imm = 0x156
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2c8bc0
movq 0x40(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x38(%rsp), %rax
movq 0x48(%rsp), %rcx
subq $0x1, %rcx
cmpq %rcx, %rax
jae 0x2c8c62
jmp 0x2c8be3
movq 0x28(%rsp), %rax
cmpq 0x58(%rsp), %rax
jb 0x2c8c27
movq 0x3733aa(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x24d413(%rip), %rsi    # 0x516013
leaq 0x2c215d(%rip), %rdx    # 0x58ad64
leaq 0x2c2129(%rip), %rcx    # 0x58ad37
leaq 0x2c1f6d(%rip), %r8     # 0x58ab82
movl $0x159, %r9d            # imm = 0x159
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2c8c29
movq 0x78(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x28(%rsp), %rdx
addq $0x1, %rdx
callq 0xa21f0
movq 0x28(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x28(%rsp)
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x38(%rsp)
jmp 0x2c8bca
jmp 0x2c8c64
movq 0x28(%rsp), %rax
cmpq 0x58(%rsp), %rax
jb 0x2c8ca8
movq 0x373329(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x24d392(%rip), %rsi    # 0x516013
leaq 0x2c20dc(%rip), %rdx    # 0x58ad64
leaq 0x2c20a8(%rip), %rcx    # 0x58ad37
leaq 0x2c1eec(%rip), %r8     # 0x58ab82
movl $0x15e, %r9d            # imm = 0x15E
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2c8caa
movq 0x48(%rsp), %rax
cmpq 0x60(%rsp), %rax
jae 0x2c8cee
movq 0x78(%rsp), %rax
movq %rax, (%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x80(%rsp), %rdi
movq 0x48(%rsp), %rsi
callq 0xa20c0
movq (%rsp), %rdi
movq 0x8(%rsp), %rsi
movq %rax, %rdx
callq 0xa21f0
jmp 0x2c8d19
movq 0x78(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rax
movq 0x20(%rsp), %rcx
movq (%rax,%rcx,8), %rdx
callq 0xa21f0
movq 0x20(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x20(%rsp)
movq 0x28(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x28(%rsp)
jmp 0x2c8b43
movq 0x30(%rsp), %rdi
leaq 0x2c1e4a(%rip), %rsi    # 0x58ab82
movl $0x16c, %edx            # imm = 0x16C
callq 0xe88c0
movq 0x28(%rsp), %rax
cmpq 0x58(%rsp), %rax
je 0x2c8d86
movq 0x37324b(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x24d2b4(%rip), %rsi    # 0x516013
leaq 0x2c2021(%rip), %rdx    # 0x58ad87
leaq 0x2c1fca(%rip), %rcx    # 0x58ad37
leaq 0x2c1e0e(%rip), %r8     # 0x58ab82
movl $0x16d, %r9d            # imm = 0x16D
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2c8d88
movq 0x50(%rsp), %rdi
callq 0xafc80
addq $0x88, %rsp
retq
nopw (%rax,%rax)