// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/match/sfx-mappedstr.c
// Function: gt_kmercodeiterator_filetab_new
GtKmercodeiterator *gt_kmercodeiterator_filetab_new(
                                                const GtStrArray *filenametab,
                                                unsigned int numofchars,
                                                unsigned int kmersize,
                                                const GtUchar *symbolmap,
                                                bool plainformat,
                                                GtError *err)
{
  GtKmercodeiterator *kmercodeiterator;
  GtUchar charcode;
  bool haserr = false;
  int retval;

  gt_error_check(err);
  kmercodeiterator = gt_malloc(sizeof (*kmercodeiterator));
  kmercodeiterator->esr = NULL;
  kmercodeiterator->hasprocessedfirst = false;
  kmercodeiterator->inputexhausted = false;
  kmercodeiterator->spwp = gt_kmerstream_new(numofchars,kmersize);
  kmercodeiterator->totallength = 0;
  if (plainformat)
  {
    kmercodeiterator->fb = gt_sequence_buffer_plain_new(filenametab);
  } else
  {
    kmercodeiterator->fb = gt_sequence_buffer_new_guess_type(filenametab, err);
  }
  if (kmercodeiterator->fb == NULL)
  {
    haserr = true;
  }
  if (!haserr)
  {
    gt_sequence_buffer_set_symbolmap(kmercodeiterator->fb, symbolmap);
    for (kmercodeiterator->currentposition = 0;
         kmercodeiterator->currentposition < (GtUword) kmersize;
         kmercodeiterator->currentposition++)
    {
      retval = gt_sequence_buffer_next(kmercodeiterator->fb,&charcode,err);
      if (retval < 0)
      {
        haserr = true;
        break;
      }
      if (retval == 0)
      {
        kmercodeiterator->inputexhausted = true;
        break;
      }
      kmercodeiterator->spwp->windowwidth++;
      gt_kmerstream_updatespecialpositions(kmercodeiterator->spwp,charcode,
                                           false,0);
      kmercodeiterator->spwp->cyclicwindow[kmercodeiterator->
                                           spwp->windowwidth-1] = charcode;
    }
  }
  if (haserr)
  {
    gt_kmercodeiterator_delete(kmercodeiterator);
    return NULL;
  }
  return kmercodeiterator;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, %rbx
movl %r8d, %r13d
movq %rcx, 0x10(%rsp)
movl %edx, %ebp
movl %esi, %r15d
movq %rdi, 0x8(%rsp)
testq %r9, %r9
je 0x1ee9b4
movq %rbx, %rdi
callq 0xfcc32
testb %al, %al
jne 0x1eeaa4
leaq 0x1c97d8(%rip), %rsi    # 0x3b8193
movl $0x58, %edi
movl $0x261, %edx            # imm = 0x261
callq 0x104226
movq %rax, %r14
xorl %r12d, %r12d
movq %r12, 0x28(%rax)
movw $0x0, 0x18(%rax)
movl %r15d, %edi
movl %ebp, %esi
callq 0x1ee73c
movq %rax, 0x38(%r14)
movq %r12, (%r14)
testb %r13b, %r13b
je 0x1ee9fc
movq 0x8(%rsp), %rdi
callq 0x1190f9
jmp 0x1eea09
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
callq 0x115472
movq %rax, 0x50(%r14)
testq %rax, %rax
je 0x1eea80
movq %rax, %rdi
movq 0x10(%rsp), %rsi
callq 0x115607
movq $0x0, 0x10(%r14)
testl %ebp, %ebp
je 0x1eea92
movl %ebp, %r12d
leaq 0x7(%rsp), %r15
movq 0x50(%r14), %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x1156aa
testl %eax, %eax
js 0x1eea80
je 0x1eea8d
movq 0x38(%r14), %rdi
incl 0x48(%rdi)
movzbl 0x7(%rsp), %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x1ee4d1
movb 0x7(%rsp), %al
movq 0x38(%r14), %rcx
movl 0x48(%rcx), %edx
decl %edx
movb %al, 0x20(%rcx,%rdx)
movq 0x10(%r14), %rax
incq %rax
movq %rax, 0x10(%r14)
cmpq %r12, %rax
jb 0x1eea33
jmp 0x1eea92
movq %r14, %rdi
callq 0x1eeaa9
xorl %r14d, %r14d
jmp 0x1eea92
movb $0x1, 0x19(%r14)
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x79442