// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/match/sfx-suftaborder.c
// Function: gt_checkifprefixesareidentical
void gt_checkifprefixesareidentical(const char *filename,
                                    int line,
                                    const GtEncseq *encseq,
                                    GtReadmode readmode,
                                    const GtSuffixsortspace *suffixsortspace,
                                    GtUword subbucketleft,
                                    GtUword width,
                                    GtUword depth)
{
  GtUword idx, maxlcp, pos1, pos2;
  int cmp;
  GtEncseqReader *esr1, *esr2;

  esr1 = gt_encseq_create_reader_with_readmode(encseq, readmode, 0);
  esr2 = gt_encseq_create_reader_with_readmode(encseq, readmode, 0);
  gt_assert(depth > 0);
  for (idx = 0; idx < width-1; idx++)
  {
    pos1 = gt_suffixsortspace_get(suffixsortspace,subbucketleft,idx);
    pos2 = gt_suffixsortspace_get(suffixsortspace,subbucketleft,idx+1);
    cmp = gt_encseq_check_comparetwosuffixes(encseq,
                                             readmode,
                                             &maxlcp,
                                             false, /* specialsareequal */
                                             true,/* specialsareequalatdepth0 */
                                             depth,pos1,
                                             pos2,
                                             esr1,
                                             esr2);
    gt_assert(maxlcp <= depth);
    if (cmp != 0 || maxlcp < depth)
    {
      showcomparisonfailure(filename,
                            line,
                            "checkifprefixesareidentical",
                            encseq,
                            readmode,
                            suffixsortspace,
                            subbucketleft,
                            depth,
                            idx,idx+1,cmp,maxlcp);
      exit(GT_EXIT_PROGRAMMING_ERROR);
    }
  }
  gt_encseq_reader_delete(esr1);
  gt_encseq_reader_delete(esr2);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r9, %rbx
movq %r8, %r15
movl %ecx, %ebp
movq %rdx, %r12
movl %esi, 0xc(%rsp)
movq %rdi, 0x28(%rsp)
movq 0x78(%rsp), %r14
movq %rdx, %rdi
movl %ecx, %esi
xorl %edx, %edx
callq 0xe91b2
movq %rax, 0x20(%rsp)
movq %r12, 0x10(%rsp)
movq %r12, %rdi
movl %ebp, 0x8(%rsp)
movl %ebp, %esi
xorl %edx, %edx
callq 0xe91b2
movq %rax, 0x18(%rsp)
testq %r14, %r14
je 0x1fd13c
movl $0x1, %eax
cmpq %rax, 0x70(%rsp)
je 0x1fd114
movq %rax, %rbp
leaq -0x1(%rax), %r13
movq %r15, %rdi
movq %rbx, %rsi
movq %r13, %rdx
callq 0x1fc965
movq %rax, %r12
movq %r15, %rdi
movq %rbx, %rsi
movq %rbp, %rdx
callq 0x1fc965
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %esi
leaq 0x30(%rsp), %rdx
xorl %ecx, %ecx
movl $0x1, %r8d
movq %r14, %r9
pushq 0x18(%rsp)
pushq 0x28(%rsp)
pushq %rax
pushq %r12
callq 0xedc49
addq $0x20, %rsp
movq 0x30(%rsp), %r10
cmpq %r14, %r10
ja 0x1fd137
testl %eax, %eax
jne 0x1fd0db
leaq 0x1(%rbp), %rax
cmpq %r14, %r10
jae 0x1fd064
xorl %eax, %eax
leaq 0x1be660(%rip), %rdx    # 0x3bb742
movq 0x28(%rsp), %rdi
movl 0xc(%rsp), %esi
movq 0x10(%rsp), %rcx
movl 0x8(%rsp), %r8d
movq %r15, %r9
pushq %r10
pushq %rax
pushq %rbp
pushq %r13
pushq %r14
pushq %rbx
callq 0x7e563
addq $0x30, %rsp
movl $0x2, %edi
callq 0x17940
movq 0x20(%rsp), %rdi
callq 0xe9204
movq 0x18(%rsp), %rdi
callq 0xe9204
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x7e698
callq 0x7e6cf