// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/core/encseq.c
// Function: countnumberofexceptionranges
static int countnumberofexceptionranges(const GtAlphabet *alpha,
                                        bool plainformat,
                                        const GtStrArray *filenametab,
                                        GtSpecialcharinfo *specialcharinfo,
                                        char *maxchars,
                                        GtError *err)
{
  int had_err = 0;
  GtSequenceBuffer *fb;
  if (plainformat)
    fb = gt_sequence_buffer_plain_new(filenametab);
  else
    fb = gt_sequence_buffer_new_guess_type(filenametab, err);
  if (!fb) {
    gt_assert(gt_error_is_set(err));
    had_err = -1;
  }
  if (!had_err) {
    int retval;
    char cc;
    bool in_range = false;
    GtUchar charcode;

    gt_sequence_buffer_set_symbolmap(fb, gt_alphabet_symbolmap(alpha));
    for (/*Nothing*/; /* Nothing */; /*Nothing*/) {
      retval = gt_sequence_buffer_next_with_original_raw(fb, &charcode, &cc,
                                                          err);
      if (retval > 0) {
        if (charcode != (GtUchar) GT_SEPARATOR) {
          if (cc != maxchars[charcode]) {
            if (!in_range) {
              in_range = true;
            }
            specialcharinfo->exceptioncharacters++;
          } else {
            if (in_range) {
              specialcharinfo->realexceptionranges++;
              in_range = false;
            }
          }
        }
      }
      else {
        if (retval == 0) {
          if (in_range) {
            specialcharinfo->realexceptionranges++;
          }
        }
        else /* retval < 0 */ {
          gt_assert(gt_error_is_set(err));
          had_err = -1;
        }
        break;
      }
    }
  }
  gt_sequence_buffer_delete(fb);
  return had_err;
}

// Assembly:
subq $0x58, %rsp
movb %sil, %al
movq %rdi, 0x50(%rsp)
andb $0x1, %al
movb %al, 0x4f(%rsp)
movq %rdx, 0x40(%rsp)
movq %rcx, 0x38(%rsp)
movq %r8, 0x30(%rsp)
movq %r9, 0x28(%rsp)
movl $0x0, 0x24(%rsp)
testb $0x1, 0x4f(%rsp)
je 0x136b56
movq 0x40(%rsp), %rdi
callq 0x14b300
movq %rax, 0x18(%rsp)
jmp 0x136b6a
movq 0x40(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x9b6a0
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
jne 0x136bc4
jmp 0x136b74
movq 0x28(%rsp), %rdi
callq 0xc270
testb $0x1, %al
jne 0x136bba
movq 0x7d44f(%rip), %rax     # 0x1b3fd8
movq (%rax), %rdi
leaq 0x274d3(%rip), %rsi     # 0x15e066
leaq 0x53e9e(%rip), %rdx     # 0x18aa38
leaq 0x53466(%rip), %rcx     # 0x18a007
leaq 0x4eab6(%rip), %r8      # 0x18565e
movl $0x1508, %r9d           # imm = 0x1508
movb $0x0, %al
callq 0xb890
callq 0xb2e0
jmp 0x136bbc
movl $0xffffffff, 0x24(%rsp) # imm = 0xFFFFFFFF
cmpl $0x0, 0x24(%rsp)
jne 0x136cfa
movb $0x0, 0x12(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x50(%rsp), %rdi
callq 0x109d50
movq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0x9ba60
movq 0x18(%rsp), %rdi
movq 0x28(%rsp), %rcx
leaq 0x11(%rsp), %rsi
leaq 0x13(%rsp), %rdx
callq 0x9be40
movl %eax, 0x14(%rsp)
cmpl $0x0, 0x14(%rsp)
jle 0x136c7e
movzbl 0x11(%rsp), %eax
cmpl $0xff, %eax
je 0x136c7c
movsbl 0x13(%rsp), %eax
movq 0x30(%rsp), %rcx
movzbl 0x11(%rsp), %edx
movsbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
je 0x136c5b
testb $0x1, 0x12(%rsp)
jne 0x136c48
movb $0x1, 0x12(%rsp)
movq 0x38(%rsp), %rax
movq 0x58(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x58(%rax)
jmp 0x136c7a
testb $0x1, 0x12(%rsp)
je 0x136c78
movq 0x38(%rsp), %rax
movq 0x68(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x68(%rax)
movb $0x0, 0x12(%rsp)
jmp 0x136c7a
jmp 0x136c7c
jmp 0x136cf3
cmpl $0x0, 0x14(%rsp)
jne 0x136c9f
testb $0x1, 0x12(%rsp)
je 0x136c9d
movq 0x38(%rsp), %rax
movq 0x68(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x68(%rax)
jmp 0x136cf1
jmp 0x136ca1
movq 0x28(%rsp), %rdi
callq 0xc270
testb $0x1, %al
jne 0x136ce7
movq 0x7d322(%rip), %rax     # 0x1b3fd8
movq (%rax), %rdi
leaq 0x273a6(%rip), %rsi     # 0x15e066
leaq 0x53d71(%rip), %rdx     # 0x18aa38
leaq 0x53339(%rip), %rcx     # 0x18a007
leaq 0x4e989(%rip), %r8      # 0x18565e
movl $0x152b, %r9d           # imm = 0x152B
movb $0x0, %al
callq 0xb890
callq 0xb2e0
jmp 0x136ce9
movl $0xffffffff, 0x24(%rsp) # imm = 0xFFFFFFFF
jmp 0x136cf8
jmp 0x136bf5
jmp 0x136cfa
movq 0x18(%rsp), %rdi
callq 0x9b570
movl 0x24(%rsp), %eax
addq $0x58, %rsp
retq
nopl (%rax)