// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/match/esa-maxpairs.c
// Function: gt_enumeratemaxpairs_generic
int gt_enumeratemaxpairs_generic(Sequentialsuffixarrayreader *ssar,
                                 GtSainSufLcpIterator *suflcpiterator,
                                 unsigned int searchlength,
                                 GtProcessmaxpairs processmaxpairs,
                                 void *processmaxpairsinfo,
                                 GtError *err)
{
  unsigned int base;
  GtArrayGtUword *ptr;
  GtBUstate_maxpairs *state;
  bool haserr = false;

  state = gt_malloc(sizeof (*state));
  state->searchlength = searchlength;
  state->processmaxpairs = processmaxpairs;
  state->processmaxpairsinfo = processmaxpairsinfo;
  state->nextmaxfreq = 0;
  state->initialized = false;
  if (ssar != NULL)
  {
    const GtEncseq *encseq = gt_encseqSequentialsuffixarrayreader(ssar);

    state->readmode = gt_readmodeSequentialsuffixarrayreader(ssar);
    state->alphabetsize = gt_alphabet_num_of_chars(gt_encseq_alphabet(encseq));
    state->genericencseq.hasencseq = true;
    state->genericencseq.seqptr.encseq = encseq;
    state->sequence = NULL;
    state->maxfreqcollect = (const GtMaxfreqcollect *) ssar->extrainfo;
  } else
  {
    const GtBareEncseq *bare_encseq;

    gt_assert(suflcpiterator != NULL);
    bare_encseq = gt_sain_suf_lcp_iterator_bare_encseq(suflcpiterator);
    state->readmode = gt_sain_suf_lcp_iterator_readmode(suflcpiterator);
    state->alphabetsize = (unsigned int) gt_bare_encseq_numofchars(bare_encseq);
    state->genericencseq.hasencseq = false;
    state->genericencseq.seqptr.bare_encseq = bare_encseq;
    state->sequence = gt_bare_encseq_sequence(bare_encseq);
    state->maxfreqcollect = NULL;
  }
  GT_INITARRAY(&state->uniquechar,GtUword);
  state->poslist = gt_malloc(sizeof (*state->poslist) * state->alphabetsize);
  for (base = 0; base < state->alphabetsize; base++)
  {
    ptr = &state->poslist[base];
    GT_INITARRAY(ptr,GtUword);
  }
  if (gt_esa_bottomup_maxpairs(ssar, suflcpiterator,  state, err) != 0)
  {
    haserr = true;
  }
  GT_FREEARRAY(&state->uniquechar,GtUword);
  for (base = 0; base < state->alphabetsize; base++)
  {
    ptr = &state->poslist[base];
    GT_FREEARRAY(ptr,GtUword);
  }
  gt_free(state->poslist);
  gt_free(state);
  return haserr ? -1 : 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %r9, 0x10(%rsp)
movq %r8, %r14
movq %rcx, %r12
movl %edx, %ebp
movq %rsi, %r13
movq %rdi, %rbx
leaq 0x2021cb(%rip), %rsi    # 0x3a457b
movl $0x70, %edi
movl $0x1ea, %edx            # imm = 0x1EA
callq 0x104226
movq %rax, %r15
movq %rax, 0x18(%rsp)
movl %ebp, 0x4(%rax)
movq %r12, 0x50(%rax)
movq %r14, 0x68(%rax)
movq $0x0, 0x60(%rax)
movb $0x0, (%rax)
testq %rbx, %rbx
movq %rbx, 0x38(%rsp)
je 0x1a243b
movq %rbx, %rdi
callq 0x1a59f6
movq %rax, %r14
movq 0x38(%rsp), %rdi
callq 0x1a5a06
movq 0x18(%rsp), %rcx
movl %eax, 0x48(%rcx)
movq %r14, %rdi
callq 0xebcd9
movq %rax, %rdi
callq 0xd11be
movq 0x18(%rsp), %rdx
movl %eax, 0x8(%rdx)
movb $0x1, 0x30(%rdx)
movq %r14, 0x38(%rdx)
movq 0x38(%rsp), %r14
movq $0x0, 0x40(%rdx)
movq 0x48(%r14), %rcx
movq %rcx, 0x58(%rdx)
jmp 0x1a2491
testq %r13, %r13
je 0x1a2e81
movq %r13, %rdi
callq 0x1f36d0
movq %rax, %r14
movq %r13, %rdi
callq 0x1f3643
movq 0x18(%rsp), %rbx
movl %eax, 0x48(%rbx)
movq %r14, %rdi
callq 0x18ac12
movl %eax, 0x8(%rbx)
movb $0x0, 0x30(%rbx)
movq %r14, 0x38(%rbx)
movq %r14, %rdi
callq 0x18abec
movq %rbx, %rdx
movq %rax, 0x40(%rbx)
movq $0x0, 0x58(%rbx)
movl 0x8(%rbx), %eax
movq 0x38(%rsp), %r14
movl %eax, %eax
shlq $0x3, %rax
leaq (%rax,%rax,2), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdx)
movq $0x0, 0x20(%rdx)
leaq 0x2020ca(%rip), %rsi    # 0x3a457b
movq %rdx, %rbx
movl $0x208, %edx            # imm = 0x208
callq 0x104226
movq %rax, 0x28(%rbx)
movl 0x8(%rbx), %ecx
testq %rcx, %rcx
je 0x1a24dc
shlq $0x3, %rcx
leaq (%rcx,%rcx,2), %rdx
movq %rax, %rdi
xorl %esi, %esi
callq 0x173a0
leaq 0x202074(%rip), %rsi    # 0x3a4557
movl $0x18, %edi
movl $0x60, %edx
callq 0x104226
movq %rax, %r12
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movl $0x20, %edx
xorl %edi, %edi
xorl %esi, %esi
movq 0x18(%rsp), %rcx
callq 0x1a319b
movq %rax, (%r12)
addq $0x20, 0x8(%r12)
testq %rax, %rax
je 0x1a2e68
movq 0x10(%r12), %rcx
imulq $0x38, %rcx, %rdx
incq %rcx
xorps %xmm0, %xmm0
movups %xmm0, (%rax,%rdx)
movq %rcx, 0x10(%r12)
movq $-0x1, 0x10(%rax,%rdx)
testq %r14, %r14
je 0x1a2559
movq %r14, %rdi
callq 0x1a5a46
jmp 0x1a2561
movq %r13, %rdi
callq 0x1f369c
movq %r15, 0x40(%rsp)
movq $0x0, 0x28(%rsp)
testq %rax, %rax
je 0x1a2b6b
movq %rax, 0x50(%rsp)
movq %r13, 0x48(%rsp)
movb $0x1, %dil
xorl %r15d, %r15d
xorl %ebp, %ebp
xorl %ebx, %ebx
testq %r14, %r14
je 0x1a26d3
cmpb $0x1, 0x40(%r14)
jne 0x1a26f0
movq (%r14), %r13
movl 0xd4(%r13), %eax
cmpl 0xd0(%r13), %eax
jb 0x1a2619
movq %r15, 0x30(%rsp)
movl %edi, %r15d
movq 0xd8(%r13), %rdi
movq 0xe0(%r13), %rcx
movl $0x1, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x17b40
movq %rax, %r14
movl %r14d, 0xd0(%r13)
movq 0xe0(%r13), %rdi
callq 0x17f00
testl %eax, %eax
jne 0x1a2e5e
movl $0x0, 0xd4(%r13)
xorl %eax, %eax
testl %r14d, %r14d
movq 0x38(%rsp), %r14
movl %r15d, %edi
movq 0x30(%rsp), %r15
je 0x1a2b8e
movq 0xd8(%r13), %rcx
leal 0x1(%rax), %edx
movl %edx, 0xd4(%r13)
movl %eax, %eax
movzbl (%rcx,%rax), %eax
cmpq $0xff, %rax
jne 0x1a2748
movq (%r14), %r13
movl 0xec(%r13), %eax
cmpl 0xe8(%r13), %eax
jb 0x1a26b5
movq %r15, 0x30(%rsp)
movl %edi, %r15d
movq 0xf0(%r13), %rdi
movq 0xf8(%r13), %rcx
movl $0x10, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x17b40
movq %rax, %r14
movl %r14d, 0xe8(%r13)
movq 0xf8(%r13), %rdi
callq 0x17f00
testl %eax, %eax
jne 0x1a2e7c
movl $0x0, 0xec(%r13)
xorl %eax, %eax
testl %r14d, %r14d
movq 0x38(%rsp), %r14
movl %r15d, %edi
movq 0x30(%rsp), %r15
je 0x1a2c7d
movq 0xf0(%r13), %rcx
leal 0x1(%rax), %edx
movl %edx, 0xec(%r13)
movl %eax, %eax
shlq $0x4, %rax
movq 0x8(%rcx,%rax), %rax
jmp 0x1a2748
movl %edi, %r14d
leaq 0x20(%rsp), %rdi
movq 0x48(%rsp), %rsi
callq 0x1f36d5
movl %r14d, %edi
movq %rax, %r14
jmp 0x1a28da
movq (%r14), %rcx
movq 0x20(%r14), %rax
cmpq 0x10(%r14), %rax
jae 0x1a2b75
movq 0x60(%rcx), %rdx
leaq 0x1(%rax), %rsi
movq %rsi, 0x20(%r14)
movzbl (%rdx,%rax), %edx
cmpq $0xff, %rdx
je 0x1a2721
movq %rdx, 0x20(%rsp)
jmp 0x1a274d
movq 0x68(%rcx), %rcx
movq 0x28(%r14), %rdx
movq %rdx, %rsi
shlq $0x4, %rsi
cmpq %rax, (%rcx,%rsi)
jne 0x1a2e63
addq %rsi, %rcx
incq %rdx
movq %rdx, 0x28(%r14)
movq 0x8(%rcx), %rax
movq %rax, 0x20(%rsp)
movq %r14, %rsi
movq (%r14), %r14
cmpb $0x1, 0x40(%rsi)
jne 0x1a27e5
movq 0xb0(%r14), %rcx
testq %rcx, %rcx
je 0x1a27fe
movl 0xa4(%r14), %eax
cmpl 0xa0(%r14), %eax
jb 0x1a2890
movl %edi, 0x30(%rsp)
movq 0xa8(%r14), %rdi
movl $0x8, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x17b40
movq %rax, %r13
movl %eax, 0xa0(%r14)
movq 0xb0(%r14), %rdi
callq 0x17f00
testl %eax, %eax
je 0x1a2876
movq 0x10(%rsp), %rdi
leaq 0x1b742c(%rip), %rsi    # 0x359bf1
leaq 0x24017f(%rip), %rdx    # 0x3e294b
xorl %eax, %eax
callq 0xfcb67
movl 0xa4(%r14), %eax
movb $0x1, %bl
movl 0x30(%rsp), %edi
jmp 0x1a2890
movq 0x58(%r14), %rax
movq 0x18(%rsi), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0x18(%rsi)
movq (%rax,%rcx,8), %r14
jmp 0x1a28da
movl 0x8c(%r14), %eax
cmpl 0x88(%r14), %eax
jb 0x1a28c3
movl %edi, 0x30(%rsp)
movq 0x90(%r14), %rdi
movq 0x98(%r14), %rcx
movl $0x4, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x17b40
movq %rax, %r13
movl %eax, 0x88(%r14)
movq 0x98(%r14), %rdi
callq 0x17f00
testl %eax, %eax
je 0x1a28a9
movq 0x10(%rsp), %rdi
leaq 0x1b7398(%rip), %rsi    # 0x359bf1
leaq 0x1b779b(%rip), %rdx    # 0x359ffb
xorl %eax, %eax
callq 0xfcb67
movl 0x8c(%r14), %eax
movb $0x1, %bl
movl 0x30(%rsp), %edi
jmp 0x1a28c3
movl $0x0, 0xa4(%r14)
xorl %eax, %eax
testl %r13d, %r13d
movl 0x30(%rsp), %edi
je 0x1a2d01
movq 0xa8(%r14), %rcx
leal 0x1(%rax), %edx
movl %edx, 0xa4(%r14)
movl %eax, %eax
movq (%rcx,%rax,8), %r14
jmp 0x1a28da
movl $0x0, 0x8c(%r14)
xorl %eax, %eax
testl %r13d, %r13d
movl 0x30(%rsp), %edi
je 0x1a2d01
movq 0x90(%r14), %rcx
leal 0x1(%rax), %edx
movl %edx, 0x8c(%r14)
movl %eax, %eax
movl (%rcx,%rax,4), %r14d
movq 0x10(%r12), %rax
testq %rax, %rax
je 0x1a2e54
movq (%r12), %rdx
imulq $0x38, %rax, %rax
movq -0x38(%rdx,%rax), %rsi
cmpq %rsi, 0x20(%rsp)
ja 0x1a2946
addq %rax, %rdx
testq %rsi, %rsi
sete %al
andb %dil, %al
movzbl %dil, %edi
movl $0x0, %ecx
cmovnel %ecx, %edi
addq $-0x20, %rdx
movq %r15, %r13
movl %edi, %r15d
movzbl %al, %edi
movq %r14, %rcx
movq 0x18(%rsp), %r8
movq 0x10(%rsp), %r9
callq 0x1a3210
movl %r15d, %edi
movq %r13, %r15
testl %eax, %eax
movzbl %bl, %ebx
movl $0x1, %eax
cmovnel %eax, %ebx
testq %rbp, %rbp
jne 0x1a2e59
testb $0x1, %bl
je 0x1a295b
xorl %ebp, %ebp
jmp 0x1a2b4a
movq 0x20(%rsp), %r8
movq (%r12), %rax
movq 0x10(%r12), %rsi
imulq $0x38, %rsi, %rcx
cmpq -0x38(%rax,%rcx), %r8
jae 0x1a2a34
addq %rax, %rcx
decq %rsi
movq %rsi, 0x10(%r12)
imulq $0x38, %rsi, %rdx
leaq (%rax,%rdx), %rbp
movq %r15, 0x10(%rax,%rdx)
movq -0x70(%rcx), %rsi
cmpq %rsi, 0x20(%rsp)
ja 0x1a29e8
testq %rsi, %rsi
sete %al
movl $0x0, %r13d
andb %dil, %al
jne 0x1a29b0
movzbl %dil, %r13d
movq -0x30(%rbp), %rdx
leaq -0x20(%rbp), %rcx
addq $0x18, %rbp
movq 0x10(%rsp), %rdi
movq %rdi, (%rsp)
movzbl %al, %edi
movq %rbp, %r8
movq 0x18(%rsp), %r9
callq 0x1a349a
testl %eax, %eax
je 0x1a29e0
movl $0x1, %ebx
jmp 0x1a29e3
movzbl %bl, %ebx
movl %r13d, %edi
xorl %ebp, %ebp
testb $0x1, %bl
jne 0x1a2b4a
movq 0x20(%rsp), %r8
movq (%r12), %rax
movq 0x10(%r12), %rsi
imulq $0x38, %rsi, %rdx
leaq (%rax,%rdx), %rcx
cmpq -0x38(%rax,%rdx), %r8
jb 0x1a297b
jbe 0x1a2b4a
testq %rbp, %rbp
je 0x1a2a3a
movq 0x8(%rbp), %r14
cmpq 0x8(%r12), %rsi
jae 0x1a2abd
movl %edi, %r13d
jmp 0x1a2af4
jbe 0x1a2954
cmpq 0x8(%r12), %rsi
jae 0x1a2a46
movl %edi, %r13d
jmp 0x1a2a7d
jne 0x1a2e72
movl %edi, %r13d
leaq 0x20(%rsi), %rdx
movq %rax, %rdi
movq 0x18(%rsp), %rcx
callq 0x1a319b
movq %rax, (%r12)
addq $0x20, 0x8(%r12)
testq %rax, %rax
je 0x1a2e77
movq 0x20(%rsp), %r8
movq 0x10(%r12), %rsi
imulq $0x38, %rsi, %rcx
leaq (%rax,%rcx), %rdx
addq $0x18, %rdx
movq %r8, -0x18(%rdx)
movq %r15, -0x10(%rdx)
incq %rsi
movq %rsi, 0x10(%r12)
movq $-0x1, -0x8(%rdx)
movl $0x1, %edi
movq %r8, %rsi
movq %r14, %rcx
movq 0x18(%rsp), %r8
movq 0x10(%rsp), %r9
callq 0x1a3210
jmp 0x1a2b38
jne 0x1a2e86
movl %edi, %r13d
leaq 0x20(%rsi), %rdx
movq %rax, %rdi
movq 0x18(%rsp), %rcx
callq 0x1a319b
movq %rax, (%r12)
addq $0x20, 0x8(%r12)
testq %rax, %rax
je 0x1a2e8b
movq 0x20(%rsp), %r8
movq 0x10(%r12), %rsi
imulq $0x38, %rsi, %rcx
addq %rax, %rcx
addq $0x18, %rcx
movq %r8, -0x18(%rcx)
movq %r14, -0x10(%rcx)
incq %rsi
movq %rsi, 0x10(%r12)
movq $-0x1, -0x8(%rcx)
movq 0x10(%rsp), %rax
movq %rax, (%rsp)
movl $0x1, %edi
movq %r8, %rsi
movq %r14, %rdx
xorl %r8d, %r8d
movq 0x18(%rsp), %r9
callq 0x1a349a
testl %eax, %eax
movzbl %bl, %ebx
movl $0x1, %eax
cmovnel %eax, %ebx
xorl %ebp, %ebp
movl %r13d, %edi
incq %r15
testb $0x1, %bl
movq 0x38(%rsp), %r14
jne 0x1a2d1f
cmpq 0x50(%rsp), %r15
jb 0x1a258c
jmp 0x1a2d1f
xorl %r15d, %r15d
xorl %ebx, %ebx
jmp 0x1a2d1f
movq 0x58(%rcx), %rax
movq 0x18(%r14), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0x18(%r14)
movq (%rax,%rcx,8), %rax
jmp 0x1a2cfa
movq (%r14), %r13
movq 0xb0(%r13), %rcx
testq %rcx, %rcx
je 0x1a2c0d
movl 0xa4(%r13), %eax
cmpl 0xa0(%r13), %eax
jb 0x1a2cb9
movq 0xa8(%r13), %rdi
movl $0x8, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x17b40
movq %rax, %r14
movl %r14d, 0xa0(%r13)
movq 0xb0(%r13), %rdi
callq 0x17f00
testl %eax, %eax
je 0x1a2ca7
leaq 0x1b7005(%rip), %rsi    # 0x359bf1
leaq 0x23fd58(%rip), %rdx    # 0x3e294b
movq 0x10(%rsp), %rdi
xorl %eax, %eax
callq 0xfcb67
movl 0xa4(%r13), %eax
movb $0x1, %bl
jmp 0x1a2cb9
movl 0x8c(%r13), %eax
cmpl 0x88(%r13), %eax
jb 0x1a2ce4
movq 0x90(%r13), %rdi
movq 0x98(%r13), %rcx
movl $0x4, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x17b40
movq %rax, %r14
movl %r14d, 0x88(%r13)
movq 0x98(%r13), %rdi
callq 0x17f00
testl %eax, %eax
je 0x1a2cd2
leaq 0x1b6f92(%rip), %rsi    # 0x359bf1
leaq 0x1b7395(%rip), %rdx    # 0x359ffb
movq 0x10(%rsp), %rdi
xorl %eax, %eax
callq 0xfcb67
movl 0x8c(%r13), %eax
movb $0x1, %bl
jmp 0x1a2ce4
leaq 0x1b6ec1(%rip), %rsi    # 0x359b45
leaq 0x2018cc(%rip), %rdx    # 0x3a4557
movq $0x0, 0x28(%rsp)
movq 0x10(%rsp), %rdi
movl $0x9d, %ecx
xorl %eax, %eax
callq 0xfcb67
jmp 0x1a2d1d
movl $0x0, 0xa4(%r13)
xorl %eax, %eax
testl %r14d, %r14d
je 0x1a2d01
movq 0xa8(%r13), %rcx
leal 0x1(%rax), %edx
movl %edx, 0xa4(%r13)
movl %eax, %eax
movq (%rcx,%rax,8), %rax
jmp 0x1a2cfa
movl $0x0, 0x8c(%r13)
xorl %eax, %eax
testl %r14d, %r14d
je 0x1a2d01
movq 0x90(%r13), %rcx
leal 0x1(%rax), %edx
movl %edx, 0x8c(%r13)
movl %eax, %eax
movl (%rcx,%rax,4), %eax
movq %rax, 0x28(%rsp)
jmp 0x1a2d1f
leaq 0x1b72db(%rip), %rsi    # 0x359fe3
movq $0x0, 0x28(%rsp)
movq 0x10(%rsp), %rdi
xorl %eax, %eax
callq 0xfcb67
movb $0x1, %bl
movq 0x10(%r12), %rax
testq %rax, %rax
je 0x1a2e6d
addq $0x10, 0x40(%rsp)
testb $0x1, %bl
jne 0x1a2d7d
movq (%r12), %rdx
imulq $0x38, %rax, %rax
movq -0x38(%rdx,%rax), %rsi
testq %rsi, %rsi
je 0x1a2d7d
addq %rax, %rdx
addq $-0x20, %rdx
xorl %edi, %edi
movq 0x28(%rsp), %rcx
movq 0x18(%rsp), %r8
movq 0x10(%rsp), %r9
callq 0x1a3210
movb $0x1, %bpl
testl %eax, %eax
jne 0x1a2d7f
movq (%r12), %rax
imulq $0x38, 0x10(%r12), %rcx
movq %r15, -0x28(%rax,%rcx)
movl %ebx, %ebp
movq %r12, %rdi
callq 0x1a2313
movq 0x40(%rsp), %rbx
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x1a2db3
leaq 0x2017e0(%rip), %rsi    # 0x3a457b
movl $0x212, %edx            # imm = 0x212
callq 0x1045eb
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq $0x0, 0x10(%rbx)
movq 0x18(%rsp), %rdx
movl 0x8(%rdx), %eax
testl %eax, %eax
je 0x1a2e0f
xorl %ebx, %ebx
leaq 0x2017b3(%rip), %r14    # 0x3a457b
xorl %r15d, %r15d
movq 0x28(%rdx), %r12
movq (%r12,%rbx), %rdi
testq %rdi, %rdi
je 0x1a2e01
addq %rbx, %r12
movq %r14, %rsi
movl $0x216, %edx            # imm = 0x216
callq 0x1045eb
movq 0x18(%rsp), %rdx
xorps %xmm0, %xmm0
movups %xmm0, (%r12)
movq $0x0, 0x10(%r12)
movl 0x8(%rdx), %eax
incq %r15
movl %eax, %ecx
addq $0x18, %rbx
cmpq %rcx, %r15
jb 0x1a2dcb
movq 0x28(%rdx), %rdi
leaq 0x201761(%rip), %r14    # 0x3a457b
movq %r14, %rsi
movq %rdx, %rbx
movl $0x218, %edx            # imm = 0x218
callq 0x1045eb
movq %rbx, %rdi
movq %r14, %rsi
movl $0x219, %edx            # imm = 0x219
callq 0x1045eb
andb $0x1, %bpl
negb %bpl
movsbl %bpl, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x61be2
callq 0x61ac5
callq 0x61a75
callq 0x61a3c
callq 0x61c54
callq 0x61c1b
callq 0x61b70
callq 0x61ba9
callq 0x61a9d
callq 0x61c8d
callq 0x61afe
callq 0x61b37