// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/core/encseq.c
// Function: gt_encseq_get_decoded_char
char gt_encseq_get_decoded_char(const GtEncseq *encseq, GtUword pos,
                                GtReadmode readmode)
{
  char cc;
  GtUchar mycc;
  gt_assert(encseq != NULL && encseq->alpha);
  gt_assert(pos < encseq->logicaltotallength);
  mycc = gt_encseq_get_encoded_char(encseq, pos, readmode);
  if (mycc != (GtUchar) GT_SEPARATOR) {
    if (GT_ISDIRREVERSE(readmode))
      pos = GT_REVERSEPOS(encseq->logicaltotallength, pos);
    if (encseq->has_exceptiontable) {
      GtUword mappos = GT_UNDEF_UWORD;
      if (pos > encseq->totallength) {
        pos = GT_REVERSEPOS(encseq->totallength, pos - encseq->totallength - 1);
        gt_readmode_invert(readmode);
      }
      if (encseq->specialcharinfo.realexceptionranges >  0UL
            && encseq->getexceptionmapping(encseq, &mappos, pos)) {
        /* if the character at this position is not the most frequent in
           its class, look up its exception */
        unsigned char subalphcode = (unsigned char)
                                     bitpackarray_get_uint32(encseq->exceptions,
                                                            (BitOffset) mappos);
        gt_assert(subalphcode < encseq->maxsubalphasize);
        /* and map it back to the original character */
        cc = encseq->allchars[encseq->classstartpositions[mycc] + subalphcode];
        if (GT_ISDIRCOMPLEMENT(readmode))
          (void) gt_complement(&cc, cc, NULL);
      } else {
        /* otherwise return most frequent character */
        cc = encseq->maxchars[mycc];
      }
    } else {
      /* we do not have lossless support, decode to class printable */
      cc = gt_alphabet_decode(encseq->alpha, mycc);
    }
  } else {
    cc = (char) mycc;
  }

  return cc;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movl %edx, 0x14(%rsp)
cmpq $0x0, 0x20(%rsp)
je 0x1146b9
movq 0x20(%rsp), %rax
cmpq $0x0, 0x220(%rax)
jne 0x1146f1
movq 0x9f918(%rip), %rax     # 0x1b3fd8
movq (%rax), %rdi
leaq 0x4999c(%rip), %rsi     # 0x15e066
leaq 0x710a4(%rip), %rdx     # 0x185775
leaq 0x710bd(%rip), %rcx     # 0x185795
leaq 0x70f7f(%rip), %r8      # 0x18565e
movl $0x152, %r9d            # imm = 0x152
movb $0x0, %al
callq 0xb890
callq 0xb2e0
jmp 0x1146f3
jmp 0x1146f5
movq 0x18(%rsp), %rax
movq 0x20(%rsp), %rcx
cmpq 0x38(%rcx), %rax
jb 0x11473d
movq 0x9f8cc(%rip), %rax     # 0x1b3fd8
movq (%rax), %rdi
leaq 0x49950(%rip), %rsi     # 0x15e066
leaq 0x70fab(%rip), %rdx     # 0x1856c8
leaq 0x71071(%rip), %rcx     # 0x185795
leaq 0x70f33(%rip), %r8      # 0x18565e
movl $0x153, %r9d            # imm = 0x153
movb $0x0, %al
callq 0xb890
callq 0xb2e0
jmp 0x11473f
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
movl 0x14(%rsp), %edx
callq 0x113f80
movb %al, 0x12(%rsp)
movzbl 0x12(%rsp), %eax
cmpl $0xff, %eax
je 0x114915
cmpl $0x1, 0x14(%rsp)
je 0x114774
cmpl $0x3, 0x14(%rsp)
jne 0x11478b
movq 0x20(%rsp), %rax
movq 0x38(%rax), %rax
subq $0x1, %rax
subq 0x18(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
testb $0x1, 0x2f0(%rax)
je 0x1148f9
movq $-0x1, 0x8(%rsp)
movq 0x18(%rsp), %rax
movq 0x20(%rsp), %rcx
cmpq 0x30(%rcx), %rax
jbe 0x1147ea
movq 0x20(%rsp), %rax
movq 0x30(%rax), %rax
subq $0x1, %rax
movq 0x18(%rsp), %rcx
movq 0x20(%rsp), %rdx
subq 0x30(%rdx), %rcx
subq $0x1, %rcx
subq %rcx, %rax
movq %rax, 0x18(%rsp)
movl $0x3, %eax
subl 0x14(%rsp), %eax
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
cmpq $0x0, 0x1e0(%rax)
jbe 0x1148df
movq 0x20(%rsp), %rax
movq 0x150(%rax), %rax
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rdx
leaq 0x8(%rsp), %rsi
callq *%rax
testb $0x1, %al
jne 0x114823
jmp 0x1148df
movq 0x20(%rsp), %rax
movq 0x330(%rax), %rdi
movq 0x8(%rsp), %rsi
callq 0x114930
movb %al, 0x7(%rsp)
movzbl 0x7(%rsp), %eax
movq 0x20(%rsp), %rcx
movzbl 0x360(%rcx), %ecx
cmpl %ecx, %eax
jl 0x11488a
movq 0x9f77f(%rip), %rax     # 0x1b3fd8
movq (%rax), %rdi
leaq 0x49803(%rip), %rsi     # 0x15e066
leaq 0x70f46(%rip), %rdx     # 0x1857b0
leaq 0x70f24(%rip), %rcx     # 0x185795
leaq 0x70de6(%rip), %r8      # 0x18565e
movl $0x165, %r9d            # imm = 0x165
movb $0x0, %al
callq 0xb890
callq 0xb2e0
jmp 0x11488c
movq 0x20(%rsp), %rax
movq 0x350(%rax), %rax
movq 0x20(%rsp), %rcx
movq 0x338(%rcx), %rcx
movzbl 0x12(%rsp), %edx
movq (%rcx,%rdx,8), %rcx
movzbl 0x7(%rsp), %edx
addq %rdx, %rcx
movb (%rax,%rcx), %al
movb %al, 0x13(%rsp)
cmpl $0x2, 0x14(%rsp)
je 0x1148ca
cmpl $0x3, 0x14(%rsp)
jne 0x1148dd
leaq 0x13(%rsp), %rdi
xorl %eax, %eax
movl %eax, %edx
movsbl 0x13(%rsp), %esi
callq 0x112480
jmp 0x1148f7
movq 0x20(%rsp), %rax
movq 0x348(%rax), %rax
movzbl 0x12(%rsp), %ecx
movb (%rax,%rcx), %al
movb %al, 0x13(%rsp)
jmp 0x114913
movq 0x20(%rsp), %rax
movq 0x220(%rax), %rdi
movzbl 0x12(%rsp), %esi
callq 0x10ac90
movb %al, 0x13(%rsp)
jmp 0x11491d
movb 0x12(%rsp), %al
movb %al, 0x13(%rsp)
movb 0x13(%rsp), %al
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)