// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/match/eis-bwtseq-siop.h
// Function: BWTSeqPosPairRangeOcc
static inline void
BWTSeqPosPairRangeOcc(const BWTSeq *bwtSeq, AlphabetRangeID range,
                      GtUword posA, GtUword posB,
                      GtUword *rangeOccs)
{
  gt_assert(bwtSeq && rangeOccs);
  gt_assert(posA <= posB);
  gt_assert(range < MRAEncGetNumRanges(BWTSeqGetAlphabet(bwtSeq)));
  EISPosPairRangeRank(bwtSeq->seqIdx, range, posA, posB, rangeOccs,
                      bwtSeq->hint);
  if (range == bwtSeq->bwtTerminatorFallbackRange)
  {
    const MRAEnc *alphabet = BWTSeqGetAlphabet(bwtSeq);
    AlphabetRangeSize rSize = MRAEncGetRangeSize(alphabet, range),
      termIdx = MRAEncMapSymbol(alphabet, bwtTerminatorSym)
      - MRAEncGetRangeBase(alphabet, range),
      fbIdx = bwtSeq->bwtTerminatorFallback
      - MRAEncGetRangeBase(alphabet, range);
    memmove(rangeOccs + termIdx + 1, rangeOccs + termIdx,
            sizeof (rangeOccs[0]) * (rSize - 1));
    rangeOccs[termIdx] = rangeOccs[termIdx + rSize] = 0;
    if (posB > BWTSeqTerminatorPos(bwtSeq))
    {
      rangeOccs[termIdx + rSize] = 1;
      --(rangeOccs[fbIdx + rSize]);
      if (posA > BWTSeqTerminatorPos(bwtSeq))
      {
        rangeOccs[termIdx] = 1;
        --(rangeOccs[fbIdx]);
      }
      else
        rangeOccs[termIdx] = 0;
    }
    else
      rangeOccs[rSize + termIdx] = rangeOccs[termIdx] = 0;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
testq %rdi, %rdi
je 0x14bab7
movq %r8, %rbx
testq %r8, %r8
je 0x14bab7
movq %rcx, %r12
movq %rdx, %r14
cmpq %rcx, %rdx
ja 0x14bae5
movl %esi, %ebp
movq %rdi, %r15
movq 0x8(%rdi), %rax
cmpl %esi, 0x4(%rax)
jbe 0x14bb13
movq (%r15), %rdi
movq 0x18(%r15), %r9
movq (%rdi), %rax
movl %ebp, %esi
movq %r14, %rdx
movq %r12, %rcx
movq %rbx, %r8
callq *0x20(%rax)
cmpl %ebp, 0x28(%r15)
jne 0x14baa8
movq %r14, 0x20(%rsp)
movq 0x8(%r15), %r13
movq %r13, %rdi
movl %ebp, %esi
callq 0x14b8b2
movw %ax, 0x10(%rsp)
movq %r13, %rdi
movl $0xfc, %esi
callq 0x14c0b2
movzbl %al, %r14d
movq %r13, %rdi
movl %ebp, %esi
callq 0x14bcc7
movzbl %al, %eax
subl %eax, %r14d
movzbl 0x24(%r15), %eax
movl %eax, 0x1c(%rsp)
movq %r13, %rdi
movl %ebp, %esi
callq 0x14bcc7
movb %al, 0xf(%rsp)
movzwl %r14w, %r13d
leaq (%rbx,%r13,8), %rsi
leaq (%rbx,%r13,8), %rbp
addq $0x8, %rbp
movzwl 0x10(%rsp), %r14d
leaq -0x8(,%r14,8), %rdx
movq %rbp, %rdi
movq %rsi, 0x10(%rsp)
callq 0x17c50
addl %r14d, %r13d
andq $0x0, (%rbx,%r13,8)
andq $0x0, -0x8(%rbp)
cmpq %r12, 0x30(%r15)
jae 0x14ba98
movzbl 0xf(%rsp), %eax
movl 0x1c(%rsp), %ecx
subl %eax, %ecx
movq $0x1, (%rbx,%r13,8)
movzwl %cx, %eax
addl %eax, %r14d
decq (%rbx,%r14,8)
movq 0x20(%rsp), %rcx
cmpq %rcx, 0x30(%r15)
jae 0x14ba9f
movq 0x10(%rsp), %rcx
movq $0x1, (%rcx)
decq (%rbx,%rax,8)
jmp 0x14baa8
andq $0x0, (%rbx,%r13,8)
jmp 0x14baa8
movq 0x10(%rsp), %rax
andq $0x0, (%rax)
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x2ec4aa(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x19954b(%rip), %rsi    # 0x2e5013
leaq 0x1f8811(%rip), %rdx    # 0x3442e0
leaq 0x1f881e(%rip), %rcx    # 0x3442f4
leaq 0x1f6b8a(%rip), %r8     # 0x342667
movl $0x93, %r9d
jmp 0x14bb3f
movq 0x2ec47c(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x19951d(%rip), %rsi    # 0x2e5013
leaq 0x1f880d(%rip), %rdx    # 0x34430a
leaq 0x1f87f0(%rip), %rcx    # 0x3442f4
leaq 0x1f6b5c(%rip), %r8     # 0x342667
movl $0x94, %r9d
jmp 0x14bb3f
movq 0x2ec44e(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x1994ef(%rip), %rsi    # 0x2e5013
leaq 0x1f87ec(%rip), %rdx    # 0x344317
leaq 0x1f87c2(%rip), %rcx    # 0x3442f4
leaq 0x1f6b2e(%rip), %r8     # 0x342667
movl $0x95, %r9d
xorl %eax, %eax
callq 0x17a50
callq 0x17390