// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/core/encseq.c
// Function: multicharactercompare_withtest
static void multicharactercompare_withtest(const GtEncseq *encseq,
                                           GtReadmode readmode,
                                           GtUword pos1,
                                           GtUword pos2)
{
  GtEndofTwobitencoding ptbe1, ptbe2;
  GtCommonunits commonunits1;
  GtUword commonunits2, twobitencodingstoppos1, twobitencodingstoppos2;
  int ret1, ret2;
  GtEncseqReader *esr1, *esr2;
  bool fwd = GT_ISDIRREVERSE(readmode) ? false : true,
       complement = GT_ISDIRCOMPLEMENT(readmode) ? true : false;

  esr1 = gt_encseq_create_reader_with_readmode(encseq, readmode, pos1);
  if (gt_encseq_has_twobitencoding_stoppos_support(encseq))
    twobitencodingstoppos1 = gt_getnexttwobitencodingstoppos (fwd, esr1);
  else
    twobitencodingstoppos1 = GT_TWOBITENCODINGSTOPPOSUNDEF(encseq);

  ptbe1.referstartpos = esr1->currentpos;
  esr1->currentpos = gt_encseq_extract2bitenc(&ptbe1, encseq, fwd,
                                              esr1->currentpos,
                                              twobitencodingstoppos1);
  esr2 = gt_encseq_create_reader_with_readmode(encseq, readmode, pos2);
  if (gt_encseq_has_twobitencoding_stoppos_support(encseq))
    twobitencodingstoppos2 = gt_getnexttwobitencodingstoppos (fwd, esr2);
  else
    twobitencodingstoppos2 = GT_TWOBITENCODINGSTOPPOSUNDEF(encseq);

  ptbe2.referstartpos = esr2->currentpos;
  esr2->currentpos = gt_encseq_extract2bitenc(&ptbe2, encseq, fwd,
                                              esr2->currentpos,
                                              twobitencodingstoppos2);
  gt_encseq_reader_delete(esr1);
  gt_encseq_reader_delete(esr2);
  ret1 = gt_encseq_compare_pairof_twobitencodings(fwd, complement,
                                                  &commonunits1, &ptbe1,
                                                  &ptbe2);
  commonunits2 = (GtUword) GT_UNITSIN2BITENC;
  if (GT_ISDIRREVERSE(readmode)) {
    pos1 = GT_REVERSEPOS(encseq->totallength, pos1);
    pos2 = GT_REVERSEPOS(encseq->totallength, pos2);
  }
  ret2 = gt_encseq_check_comparetwostrings(encseq, fwd, complement,
                                           &commonunits2, pos1, pos2, 0);
  if (ret1 != ret2 || commonunits2 != (GtUword) commonunits1.common) {
    char buf1[GT_INTWORDSIZE+1], buf2[GT_INTWORDSIZE+1];

    fprintf(stderr, "fwd=%s, complement=%s: "
                   "pos1="GT_WU", pos2="GT_WU"\n",
            fwd ? "true" : "false",
            complement ? "true" : "false",
            pos1, pos2);
    fprintf(stderr, "ret1=%d, ret2=%d\n", ret1, ret2);
    fprintf(stderr, "commonunits1=%u, commonunits2="GT_WU"\n",
            commonunits1.common, commonunits2);
    gt_encseq_showatstartpos(stderr, fwd, complement, encseq, pos1);
    gt_bitsequence_tostring(buf1, ptbe1.tbe);
    fprintf(stderr, "v1=%s(unitsnotspecial=%u)\n", buf1, ptbe1.unitsnotspecial);
    gt_encseq_showatstartpos(stderr, fwd, complement, encseq, pos2);
    gt_bitsequence_tostring(buf2, ptbe2.tbe);
    fprintf(stderr, "v2=%s(unitsnotspecial=%u)\n", buf2, ptbe2.unitsnotspecial);
    exit(GT_EXIT_PROGRAMMING_ERROR);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x128, %rsp            # imm = 0x128
movq %rcx, %r15
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
movl %esi, %eax
andl $-0x3, %eax
movl %eax, 0xc(%rsp)
leaq 0x33dfa(%rip), %rdx     # 0x102a2a
movl $0x1, %edi
movl $0x38, %esi
movl $0xc5e, %ecx            # imm = 0xC5E
callq 0x3601f
movq %rax, %r12
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rax)
movq %rax, %rdi
movq %r14, %rsi
movl %ebp, %edx
movq %rbx, 0x10(%rsp)
movq %rbx, %rcx
callq 0xc0212
movq %r14, %rdi
callq 0xc06bb
testb %al, %al
je 0xcec7e
xorl %edi, %edi
movq %r12, %rsi
callq 0xc3c5e
movq %rax, %r8
jmp 0xcec8b
movzbl 0x3a8(%r14), %eax
movq 0x30(%r14,%rax,8), %r8
movl %ebp, %eax
andl $-0x2, %eax
movl %eax, 0x1c(%rsp)
xorl %edx, %edx
cmpl $0x1, 0xc(%rsp)
setne %dl
movq 0x10(%r12), %rcx
leaq 0x78(%rsp), %rdi
movq %rcx, 0x10(%rdi)
movq %r14, %rsi
callq 0xc3ecd
movq %rax, 0x10(%r12)
leaq 0x33d6a(%rip), %rdx     # 0x102a2a
movl $0x1, %edi
movl $0x38, %esi
movl $0xc5e, %ecx            # imm = 0xC5E
callq 0x3601f
movq %rax, %r13
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rax)
movq %rax, %rdi
movq %r14, %rsi
movl %ebp, %edx
movq %r15, %rcx
callq 0xc0212
movq %r14, %rdi
callq 0xc06bb
testb %al, %al
movq %r12, 0x20(%rsp)
je 0xced0e
xorl %edi, %edi
movq %r13, %rsi
callq 0xc3c5e
movq %rax, %r8
jmp 0xced1b
movzbl 0x3a8(%r14), %eax
movq 0x30(%r14,%rax,8), %r8
xorl %ebx, %ebx
cmpl $0x2, 0x1c(%rsp)
sete %bl
xorl %ebp, %ebp
movl 0xc(%rsp), %r12d
cmpl $0x1, %r12d
setne %bpl
movq 0x10(%r13), %rcx
leaq 0x60(%rsp), %rdi
movq %rcx, 0x10(%rdi)
movq %r14, %rsi
movl %ebp, %edx
callq 0xc3ecd
movq %rax, 0x10(%r13)
movq 0x20(%rsp), %rdi
callq 0xc0543
movq %r13, %rdi
callq 0xc0543
leaq 0x50(%rsp), %rdx
leaq 0x78(%rsp), %rcx
movl %ebp, %edi
movl %ebx, %esi
leaq 0x60(%rsp), %r8
callq 0xc44cc
cmpl $0x1, %r12d
je 0xced86
movq 0x10(%rsp), %r8
jmp 0xced9b
movq 0x30(%r14), %rdx
decq %rdx
movq %rdx, %r8
subq 0x10(%rsp), %r8
subq %r15, %rdx
movq %rdx, %r15
movq 0x38(%r14), %rsi
cmpl $0x1, 0xc(%rsp)
movq %r14, 0x28(%rsp)
movl %eax, 0x18(%rsp)
movq %rsi, 0x48(%rsp)
je 0xcedcd
movq %rsi, %rcx
subq %r8, %rcx
jbe 0xcf01d
movq %rsi, %rdx
subq %r15, %rdx
ja 0xcedd5
callq 0x2f124
leaq 0x1(%r8), %rcx
leaq 0x1(%r15), %rdx
cmpq %rdx, %rcx
cmovbq %rcx, %rdx
cmpq $0x20, %rdx
movl $0x20, %eax
cmovbq %rdx, %rax
movq %rax, 0x30(%rsp)
incq %rax
movq %rax, 0x38(%rsp)
xorl %r12d, %r12d
movq %r15, 0x40(%rsp)
movq 0x28(%rsp), %rbp
movq 0x30(%rsp), %rbx
movq %r12, 0x10(%rsp)
xorl %r13d, %r13d
cmpl $0x2, 0x1c(%rsp)
sete %r13b
xorl %r15d, %r15d
cmpl $0x1, 0xc(%rsp)
setne %r15b
movq 0x48(%rsp), %r12
movq %r12, (%rsp)
movq %rbp, %rdi
movl %r15d, %esi
movl %r13d, %edx
movq %r8, %rcx
movq %r8, %r14
movq %rbx, %r8
movq 0x10(%rsp), %r9
callq 0xcf022
movq %rax, 0x20(%rsp)
movq %r12, (%rsp)
movq 0x10(%rsp), %r12
movq %rbp, %rdi
movl %r15d, %esi
movq 0x40(%rsp), %r15
movl %r13d, %edx
movq %r15, %rcx
movq %rbx, %r8
movq %r12, %r9
callq 0xcf022
movq 0x20(%rsp), %rcx
cmpq %rax, %rcx
jne 0xceeab
xorl %r13d, %r13d
cmpq %r15, %r14
movq %r14, %r8
jne 0xcee92
cmpq $0x100, %rcx            # imm = 0x100
jae 0xceea5
incq %r12
cmpq %r12, 0x38(%rsp)
jne 0xcee08
movq 0x30(%rsp), %r12
movl 0x18(%rsp), %ebp
jmp 0xceedf
cmpl $0x1, 0xc(%rsp)
movl 0x18(%rsp), %ebp
jne 0xceecf
cmpq $0x100, %rcx            # imm = 0x100
jb 0xceecf
cmpq $0x100, %rax            # imm = 0x100
jb 0xceecf
xorl %r13d, %r13d
cmpq %rcx, %rax
jmp 0xceed5
xorl %r13d, %r13d
cmpq %rax, %rcx
sbbl %r13d, %r13d
orl $0x1, %r13d
movq %r14, %r8
cmpl %r13d, %ebp
jne 0xceeff
movl 0x50(%rsp), %eax
cmpq %rax, %r12
jne 0xceeff
addq $0x128, %rsp            # imm = 0x128
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorl %esi, %esi
cmpl $0x1, 0xc(%rsp)
leaq 0x3ca65(%rip), %rax     # 0x10b972
leaq 0x25cfb(%rip), %rcx     # 0xf4c0f
movq %rcx, %rdx
cmovneq %rax, %rdx
setne %sil
movl %esi, 0x10(%rsp)
xorl %esi, %esi
cmpl $0x2, 0x1c(%rsp)
sete %sil
movl %esi, 0x20(%rsp)
movq 0x82087(%rip), %r14     # 0x150fc0
movq (%r14), %rdi
cmoveq %rax, %rcx
leaq 0x37e25(%rip), %rsi     # 0x106d6c
movq %r8, %rbx
movq %r15, %r9
xorl %eax, %eax
callq 0xb8d0
movq (%r14), %rdi
leaq 0x37e39(%rip), %rsi     # 0x106d97
movl %ebp, %edx
movl %r13d, %ecx
xorl %eax, %eax
callq 0xb8d0
movq (%r14), %rdi
movl 0x50(%rsp), %edx
leaq 0x37e31(%rip), %rsi     # 0x106da9
movq %r12, %rcx
xorl %eax, %eax
callq 0xb8d0
movq (%r14), %rdi
movl 0x10(%rsp), %ebp
movl %ebp, %esi
movl 0x20(%rsp), %r13d
movl %r13d, %edx
movq 0x28(%rsp), %r12
movq %r12, %rcx
movq %rbx, %r8
callq 0xc4b2a
movq 0x78(%rsp), %rsi
leaq 0xe0(%rsp), %rbx
movq %rbx, %rdi
callq 0xcebdb
movq (%r14), %rdi
movl 0x80(%rsp), %ecx
leaq 0x37e03(%rip), %rsi     # 0x106dcc
movq %rbx, %rdx
xorl %eax, %eax
callq 0xb8d0
movq (%r14), %rdi
movl %ebp, %esi
movl %r13d, %edx
movq %r12, %rcx
movq %r15, %r8
callq 0xc4b2a
movq 0x60(%rsp), %rsi
leaq 0x90(%rsp), %rbx
movq %rbx, %rdi
callq 0xcebdb
movq (%r14), %rdi
movl 0x68(%rsp), %ecx
leaq 0x37dde(%rip), %rsi     # 0x106de7
movq %rbx, %rdx
xorl %eax, %eax
callq 0xb8d0
movl $0x2, %edi
callq 0xb7b0
callq 0x2f0eb