// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/tools/gt_repfind.c
// Function: gt_suffix_prefix_match_with_output
static int gt_suffix_prefix_match_with_output(GT_UNUSED void *info,
                                              const GtGenericEncseq
                                                *genericencseq,
                                              GtUword matchlen,
                                              GtUword pos1,
                                              GtUword pos2,
                                              GT_UNUSED GtError *err)
{
  GtUword seqnum1, relpos1, seqnum2, relpos2, seqstartpos;
  const GtEncseq *encseq;

  gt_assert(pos1 < pos2);
  gt_assert(genericencseq != NULL && genericencseq->hasencseq);
  encseq = genericencseq->seqptr.encseq;
  seqnum1 = gt_encseq_seqnum(encseq,pos1);
  seqstartpos = gt_encseq_seqstartpos(encseq, seqnum1);
  gt_assert(seqstartpos <= pos1);
  relpos1 = pos1 - seqstartpos;
  seqnum2 = gt_encseq_seqnum(encseq,pos2);
  seqstartpos = gt_encseq_seqstartpos(encseq, seqnum2);
  gt_assert(seqstartpos <= pos2);
  relpos2 = pos2 - seqstartpos;
  if (relpos1 == 0)
  {
    GtUword seqlen2 = gt_encseq_seqlength(encseq,seqnum2);

    if (relpos2 + matchlen == seqlen2)
    {
      printf(GT_WU " " GT_WU " " GT_WU "\n",seqnum2,seqnum1,matchlen);
    }
  } else
  {
    if (relpos2 == 0)
    {
      GtUword seqlen1 = gt_encseq_seqlength(encseq,seqnum1);

      if (relpos1 + matchlen == seqlen1)
      {
        printf(GT_WU " " GT_WU " " GT_WU "\n",seqnum1,seqnum2,matchlen);
      }
    }
  }
  return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
cmpq %r8, %rcx
jae 0x407f6
movq %rdx, 0x10(%rsp)
testq %rsi, %rsi
je 0x407c5
cmpb $0x0, (%rsi)
je 0x407c5
movq %r8, %r12
movq %rcx, %r15
movq 0x8(%rsi), %rbp
movq %rbp, %rdi
movq %rcx, %rsi
callq 0x74c9d
movq %rbp, %rdi
movq %rax, 0x8(%rsp)
movq %rax, %rsi
callq 0x74d9c
cmpq %r15, %rax
ja 0x40824
movq %rax, %rbx
movq %rbp, %rdi
movq %r12, %rsi
callq 0x74c9d
movq %rax, %r13
movq %rbp, %rdi
movq %rax, %rsi
callq 0x74d9c
cmpq %r12, %rax
ja 0x40852
movq %rax, %r14
cmpq %r15, %rbx
jne 0x4077c
movq %rbp, %rdi
movq %r13, %rsi
callq 0x75173
movq 0x10(%rsp), %rcx
addq %rcx, %r12
subq %r14, %r12
cmpq %rax, %r12
jne 0x407b4
leaq 0x304204(%rip), %rdi    # 0x344976
movq %r13, %rsi
movq 0x8(%rsp), %rdx
jmp 0x407ad
cmpq %r12, %r14
jne 0x407b4
movq %rbp, %rdi
movq 0x8(%rsp), %rsi
callq 0x75173
movq 0x10(%rsp), %rcx
addq %rcx, %r15
subq %rbx, %r15
cmpq %rax, %r15
jne 0x407b4
leaq 0x3041d1(%rip), %rdi    # 0x344976
movq 0x8(%rsp), %rsi
movq %r13, %rdx
xorl %eax, %eax
callq 0x17070
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x3f779c(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x2a483d(%rip), %rsi    # 0x2e5013
leaq 0x2b4fb7(%rip), %rdx    # 0x2f5794
leaq 0x2b4f01(%rip), %rcx    # 0x2f56e5
leaq 0x2b47e5(%rip), %r8     # 0x2f4fd0
movl $0x99, %r9d
jmp 0x4087e
movq 0x3f776b(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x2a480c(%rip), %rsi    # 0x2e5013
leaq 0x2b4ecb(%rip), %rdx    # 0x2f56d9
leaq 0x2b4ed0(%rip), %rcx    # 0x2f56e5
leaq 0x2b47b4(%rip), %r8     # 0x2f4fd0
movl $0x98, %r9d
jmp 0x4087e
movq 0x3f773d(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x2a47de(%rip), %rsi    # 0x2e5013
leaq 0x2b4ecc(%rip), %rdx    # 0x2f5708
leaq 0x2b4ea2(%rip), %rcx    # 0x2f56e5
leaq 0x2b4786(%rip), %r8     # 0x2f4fd0
movl $0x9d, %r9d
jmp 0x4087e
movq 0x3f770f(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x2a47b0(%rip), %rsi    # 0x2e5013
leaq 0x2b4eb2(%rip), %rdx    # 0x2f571c
leaq 0x2b4e74(%rip), %rcx    # 0x2f56e5
leaq 0x2b4758(%rip), %r8     # 0x2f4fd0
movl $0xa1, %r9d
xorl %eax, %eax
callq 0x17a50
callq 0x17390