// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/eis-seqranges.c
// Function: gt_SRLAppendNewRange
void
gt_SRLAppendNewRange(struct seqRangeList *rangeList,
                  GtUword pos,
                  GtUword len,
                  Symbol esym)
{
  gt_assert(rangeList);
  if (len)
  {
    Symbol sym = MRAEncMapSymbol(rangeList->alphabet, esym);
    struct seqRange *p;
    GtUword *pSums;
    size_t numRanges = rangeList->numRanges,
      numSyms = gt_MRAEncGetSize(rangeList->alphabet),
      numNewRanges = len/rangeList->maxRangeLen
      + ((len%rangeList->maxRangeLen)?1:0);
    unsigned symBits = rangeList->symBits;
    if (numRanges + numNewRanges > rangeList->numRangesStorable)
    {
      size_t newSize = numRanges + 2 * numNewRanges;
      rangeList->ranges = gt_realloc(rangeList->ranges,
                                     sizeof (struct seqRange) * newSize);
      if (rangeList->partialSymSums)
        rangeList->partialSymSums =
          gt_realloc(rangeList->partialSymSums, sizeof (GtUword)
                     * numSyms * newSize);
      rangeList->numRangesStorable = newSize;
    }
    p = rangeList->ranges + numRanges;
    if (rangeList->partialSymSums)
      pSums = rangeList->partialSymSums + numSyms * numRanges;
    else
      pSums = NULL;
    while (len > rangeList->maxRangeLen)
    {
      p->startPos = pos;
      seqRangeSetSym(p, sym, symBits);
      seqRangeSetLen(p, rangeList->maxRangeLen, symBits);
      pos += rangeList->maxRangeLen;
      len -= rangeList->maxRangeLen;
      if (numRanges && pSums)
      {
        GtUword *spDest = pSums, *spSrc = pSums - numSyms;
        size_t i;
        for (i = 0; i < numSyms; ++i)
        {
          *spDest++ = *spSrc++;
        }
        pSums[seqRangeSym(p - 1, symBits)] += seqRangeLen(p - 1, symBits);
        pSums += numSyms;
      }
      else if (pSums)
      {
        memset(pSums, 0, sizeof (GtUword) * numSyms);
        pSums += numSyms;
      }
      ++p;
      ++numRanges;
    }
    if (len)
    {
      p->startPos = pos;
      seqRangeSetSym(p, sym, symBits);
      seqRangeSetLen(p, len, symBits);
      if (numRanges && pSums)
      {
        GtUword *spDest = pSums, *spSrc = pSums - numSyms;
        size_t i;
        for (i = 0; i < numSyms; ++i)
        {
          *spDest++ = *spSrc++;
        }
        pSums[seqRangeSym(p - 1, symBits)] += seqRangeLen(p - 1, symBits);
        pSums += numSyms;
      }
      else if (pSums)
      {
        memset(pSums, 0, sizeof (GtUword) * numSyms);
        pSums += numSyms;
      }
      ++numRanges;
    }
    gt_assert(numRanges == rangeList->numRanges + numNewRanges);
    rangeList->numRanges = numRanges;
  }
}

// Assembly:
subq $0xb8, %rsp
movb %cl, %al
movq %rdi, 0xb0(%rsp)
movq %rsi, 0xa8(%rsp)
movq %rdx, 0xa0(%rsp)
movb %al, 0x9f(%rsp)
cmpq $0x0, 0xb0(%rsp)
jne 0x4affbb
movq 0x18c016(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x6607f(%rip), %rsi     # 0x516013
leaq 0x10722b(%rip), %rdx    # 0x5b71c6
leaq 0x107252(%rip), %rcx    # 0x5b71f4
leaq 0x107203(%rip), %r8     # 0x5b71ac
movl $0x56, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4affbd
cmpq $0x0, 0xa0(%rsp)
je 0x4b05cd
movq 0xb0(%rsp), %rax
movq 0x20(%rax), %rdi
movzbl 0x9f(%rsp), %esi
callq 0x4b05e0
movb %al, 0x9e(%rsp)
movq 0xb0(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x80(%rsp)
movq 0xb0(%rsp), %rax
movq 0x20(%rax), %rdi
callq 0x22aeb0
movzwl %ax, %eax
movq %rax, 0x78(%rsp)
movq 0xa0(%rsp), %rax
movq 0xb0(%rsp), %rcx
xorl %edx, %edx
divq 0x30(%rcx)
movq %rax, 0x28(%rsp)
movq 0xa0(%rsp), %rax
movq 0xb0(%rsp), %rcx
xorl %edx, %edx
divq 0x30(%rcx)
movq 0x28(%rsp), %rax
movq %rdx, %rsi
xorl %ecx, %ecx
movl $0x1, %edx
cmpq $0x0, %rsi
cmovnel %edx, %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, 0x70(%rsp)
movq 0xb0(%rsp), %rax
movl 0x28(%rax), %eax
movl %eax, 0x6c(%rsp)
movq 0x80(%rsp), %rax
addq 0x70(%rsp), %rax
movq 0xb0(%rsp), %rcx
cmpq (%rcx), %rax
jbe 0x4b013f
movq 0x80(%rsp), %rax
movq 0x70(%rsp), %rcx
shlq %rcx
addq %rcx, %rax
movq %rax, 0x60(%rsp)
movq 0xb0(%rsp), %rax
movq 0x10(%rax), %rdi
movq 0x60(%rsp), %rsi
shlq $0x4, %rsi
leaq 0x1070e0(%rip), %rdx    # 0x5b71ac
movl $0x65, %ecx
callq 0xe8540
movq %rax, %rcx
movq 0xb0(%rsp), %rax
movq %rcx, 0x10(%rax)
movq 0xb0(%rsp), %rax
cmpq $0x0, 0x18(%rax)
je 0x4b012f
movq 0xb0(%rsp), %rax
movq 0x18(%rax), %rdi
movq 0x78(%rsp), %rsi
shlq $0x3, %rsi
imulq 0x60(%rsp), %rsi
leaq 0x107096(%rip), %rdx    # 0x5b71ac
movl $0x69, %ecx
callq 0xe8540
movq %rax, %rcx
movq 0xb0(%rsp), %rax
movq %rcx, 0x18(%rax)
movq 0x60(%rsp), %rcx
movq 0xb0(%rsp), %rax
movq %rcx, (%rax)
movq 0xb0(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x80(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, 0x90(%rsp)
movq 0xb0(%rsp), %rax
cmpq $0x0, 0x18(%rax)
je 0x4b019c
movq 0xb0(%rsp), %rax
movq 0x18(%rax), %rax
movq 0x78(%rsp), %rcx
imulq 0x80(%rsp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x88(%rsp)
jmp 0x4b01a8
movq $0x0, 0x88(%rsp)
jmp 0x4b01aa
movq 0xa0(%rsp), %rax
movq 0xb0(%rsp), %rcx
cmpq 0x30(%rcx), %rax
jbe 0x4b03b6
movq 0xa8(%rsp), %rcx
movq 0x90(%rsp), %rax
movq %rcx, (%rax)
movq 0x90(%rsp), %rdi
movb 0x9e(%rsp), %al
movl 0x6c(%rsp), %edx
movzbl %al, %esi
callq 0x4b0620
movq 0x90(%rsp), %rdi
movq 0xb0(%rsp), %rax
movq 0x30(%rax), %rsi
movl 0x6c(%rsp), %edx
callq 0x4b0660
movq 0xb0(%rsp), %rax
movq 0x30(%rax), %rax
addq 0xa8(%rsp), %rax
movq %rax, 0xa8(%rsp)
movq 0xb0(%rsp), %rax
movq 0x30(%rax), %rcx
movq 0xa0(%rsp), %rax
subq %rcx, %rax
movq %rax, 0xa0(%rsp)
cmpq $0x0, 0x80(%rsp)
je 0x4b034b
cmpq $0x0, 0x88(%rsp)
je 0x4b034b
movq 0x88(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0x88(%rsp), %rax
xorl %ecx, %ecx
subq 0x78(%rsp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x50(%rsp)
movq $0x0, 0x48(%rsp)
movq 0x48(%rsp), %rax
cmpq 0x78(%rsp), %rax
jae 0x4b02dd
movq 0x50(%rsp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, 0x50(%rsp)
movq (%rax), %rcx
movq 0x58(%rsp), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x58(%rsp)
movq %rcx, (%rax)
movq 0x48(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x48(%rsp)
jmp 0x4b0299
movq 0x90(%rsp), %rdi
addq $-0x10, %rdi
movl 0x6c(%rsp), %esi
callq 0x4b06a0
movq %rax, 0x18(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x90(%rsp), %rdi
addq $-0x10, %rdi
movl 0x6c(%rsp), %esi
callq 0x4b06d0
movq 0x18(%rsp), %rdx
movb %al, %cl
movq 0x20(%rsp), %rax
movzbl %cl, %ecx
addq (%rax,%rcx,8), %rdx
movq %rdx, (%rax,%rcx,8)
movq 0x78(%rsp), %rax
shlq $0x3, %rax
addq 0x88(%rsp), %rax
movq %rax, 0x88(%rsp)
jmp 0x4b0389
cmpq $0x0, 0x88(%rsp)
je 0x4b0387
movq 0x88(%rsp), %rdi
movq 0x78(%rsp), %rdx
shlq $0x3, %rdx
xorl %esi, %esi
callq 0x19360
movq 0x78(%rsp), %rax
shlq $0x3, %rax
addq 0x88(%rsp), %rax
movq %rax, 0x88(%rsp)
jmp 0x4b0389
movq 0x90(%rsp), %rax
addq $0x10, %rax
movq %rax, 0x90(%rsp)
movq 0x80(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x80(%rsp)
jmp 0x4b01aa
cmpq $0x0, 0xa0(%rsp)
je 0x4b055f
movq 0xa8(%rsp), %rcx
movq 0x90(%rsp), %rax
movq %rcx, (%rax)
movq 0x90(%rsp), %rdi
movb 0x9e(%rsp), %al
movl 0x6c(%rsp), %edx
movzbl %al, %esi
callq 0x4b0620
movq 0x90(%rsp), %rdi
movq 0xa0(%rsp), %rsi
movl 0x6c(%rsp), %edx
callq 0x4b0660
cmpq $0x0, 0x80(%rsp)
je 0x4b050d
cmpq $0x0, 0x88(%rsp)
je 0x4b050d
movq 0x88(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x88(%rsp), %rax
xorl %ecx, %ecx
subq 0x78(%rsp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x38(%rsp)
movq $0x0, 0x30(%rsp)
movq 0x30(%rsp), %rax
cmpq 0x78(%rsp), %rax
jae 0x4b049f
movq 0x38(%rsp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, 0x38(%rsp)
movq (%rax), %rcx
movq 0x40(%rsp), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x40(%rsp)
movq %rcx, (%rax)
movq 0x30(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x30(%rsp)
jmp 0x4b045b
movq 0x90(%rsp), %rdi
addq $-0x10, %rdi
movl 0x6c(%rsp), %esi
callq 0x4b06a0
movq %rax, 0x8(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x90(%rsp), %rdi
addq $-0x10, %rdi
movl 0x6c(%rsp), %esi
callq 0x4b06d0
movq 0x8(%rsp), %rdx
movb %al, %cl
movq 0x10(%rsp), %rax
movzbl %cl, %ecx
addq (%rax,%rcx,8), %rdx
movq %rdx, (%rax,%rcx,8)
movq 0x78(%rsp), %rax
shlq $0x3, %rax
addq 0x88(%rsp), %rax
movq %rax, 0x88(%rsp)
jmp 0x4b054b
cmpq $0x0, 0x88(%rsp)
je 0x4b0549
movq 0x88(%rsp), %rdi
movq 0x78(%rsp), %rdx
shlq $0x3, %rdx
xorl %esi, %esi
callq 0x19360
movq 0x78(%rsp), %rax
shlq $0x3, %rax
addq 0x88(%rsp), %rax
movq %rax, 0x88(%rsp)
jmp 0x4b054b
movq 0x80(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x80(%rsp)
jmp 0x4b0561
movq 0x80(%rsp), %rax
movq 0xb0(%rsp), %rcx
movq 0x8(%rcx), %rcx
addq 0x70(%rsp), %rcx
cmpq %rcx, %rax
je 0x4b05b7
movq 0x18ba1a(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x65a83(%rip), %rsi     # 0x516013
leaq 0x106c72(%rip), %rdx    # 0x5b7209
leaq 0x106c56(%rip), %rcx    # 0x5b71f4
leaq 0x106c07(%rip), %r8     # 0x5b71ac
movl $0xa2, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4b05b9
movq 0x80(%rsp), %rcx
movq 0xb0(%rsp), %rax
movq %rcx, 0x8(%rax)
addq $0xb8, %rsp
retq
nopw %cs:(%rax,%rax)