// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/ft-front-generation.c
// Function: front_trace2polished_eoplist
static void front_trace2polished_eoplist(GtEoplist *eoplist,
                                         GtFrontTrace *front_trace,
                                         const GtFtPolished_point *pp,
                                         GtUword pol_size,
                                         GtWord match_score,
                                         GtWord difference_score,
                                         const GtUchar *useq,
                                         GtUword ulen,
                                         const GtUchar *vseq,
                                         GtUword vlen)
{
  GtUword localoffset, globaloffset, remainingvalidfronts;
  GtBacktraceFrontStackelem *stack_top_ptr;
  GtBacktraceFrontInfo bti;
  unsigned int lastlcs;

  bti.ulen = ulen;
  bti.vlen = vlen;
  bti.match_score = match_score;
  bti.difference_score = difference_score;
  bti.on_polsize_suffix = true;
  front_trace->backtracestack.nextfree = 0;
  if (front_trace->backtracepath_allocated < pp->distance+1)
  {
    front_trace->backtracepath_allocated = pp->distance + 1;
    front_trace->backtracepath
      = gt_realloc(front_trace->backtracepath,
                   sizeof *front_trace->backtracepath * (pp->distance+1));
  }
  gt_assert(front_trace != NULL && front_trace->gen_nextfree > 0 && pp != NULL);
  localoffset = polished_point2offset(front_trace,pp);
  remainingvalidfronts = valid_total_fronts(front_trace->gen_table,
                                            pp->distance,
                                            front_trace->gen_nextfree);
  gt_assert(remainingvalidfronts <= front_trace->backref_nextfree);
  globaloffset = front_trace->backref_nextfree - remainingvalidfronts;
  stack_top_ptr = stack_top_ptr_get(&front_trace->backtracestack);
  stack_top_ptr->diagonal
    = (GtWord) pp->alignedlen - (GtWord) GT_MULT2(pp->row);
  stack_top_ptr->distance = pp->distance;
  stack_top_ptr->trace
    = front_trace->backref_table[globaloffset + localoffset].bits;
  stack_top_ptr->row = pp->row;
  stack_top_ptr->eopcode = 0;
  lastlcs = stack_top_ptr->lcs
          = front_trace->backref_table[globaloffset + localoffset].lcs;
  stack_top_ptr->scoresum = stack_top_ptr->lcs * match_score;
  stack_top_ptr->globaloffset = globaloffset;
  stack_top_ptr->trimleft = pp->trimleft;
  stack_top_ptr->lcs_sum = stack_top_ptr->lcs;
  stack_top_ptr->pathlength = 0; /* number of errors */
  while (front_trace->backtracestack.nextfree > 0)
  {
    front_trace->backtracestack.nextfree--;
    stack_top_ptr = front_trace->backtracestack.space +
                    front_trace->backtracestack.nextfree;
    if (bti.on_polsize_suffix &&
        stack_top_ptr->lcs_sum + stack_top_ptr->pathlength >= pol_size)
    {
      bti.on_polsize_suffix = false;
    }
    if (stack_top_ptr->pathlength > 0)
    {
      gt_assert(stack_top_ptr->pathlength - 1 <= pp->distance);
      front_trace->backtracepath[stack_top_ptr->pathlength-1].eopcode
        = stack_top_ptr->eopcode;
      front_trace->backtracepath[stack_top_ptr->pathlength-1].lcs
        = stack_top_ptr->lcs;
    }
    if (stack_top_ptr->trace != 0)
    {
      if (eoplist == NULL)
      {
        gt_check_diagonal_run(useq,
                              vseq,
                              stack_top_ptr->diagonal,
                              stack_top_ptr->row -
                              stack_top_ptr->lcs,
                              stack_top_ptr->row);
      }
      gt_front_trace_backtrace_step(&bti,
                                    front_trace,
                                    stack_top_ptr->diagonal,
                                    stack_top_ptr->scoresum,
                                    stack_top_ptr->distance,
                                    stack_top_ptr->trace,
                                    stack_top_ptr->globaloffset,
                                    stack_top_ptr->trimleft,
                                    stack_top_ptr->row,
                                    stack_top_ptr->lcs,
                                    stack_top_ptr->lcs_sum,
                                    stack_top_ptr->pathlength);
    } else
    { /* trace == 0 */
      break;
    }
  }
  gt_assert(stack_top_ptr != NULL);
  if (eoplist != NULL)
  {
    gt_front_trace_backtracepath2eoplist(eoplist,
                                         lastlcs,
                                         front_trace->backtracepath,
                                         stack_top_ptr->pathlength,
                                         ulen,
                                         vlen);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0xb0, %rsp
movq 0xe8(%rsp), %rax
movq 0xe0(%rsp), %rax
movq 0xd8(%rsp), %rax
movq 0xd0(%rsp), %rax
movq %rdi, 0xa8(%rsp)
movq %rsi, 0xa0(%rsp)
movq %rdx, 0x98(%rsp)
movq %rcx, 0x90(%rsp)
movq %r8, 0x88(%rsp)
movq %r9, 0x80(%rsp)
movq 0xd8(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xe8(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x80(%rsp), %rax
movq %rax, 0x50(%rsp)
movb $0x1, 0x58(%rsp)
movq 0xa0(%rsp), %rax
movq $0x0, 0x38(%rax)
movq 0xa0(%rsp), %rax
movq 0x48(%rax), %rax
movq 0x98(%rsp), %rcx
movq 0x10(%rcx), %rcx
addq $0x1, %rcx
cmpq %rcx, %rax
jae 0x4c7132
movq 0x98(%rsp), %rax
movq 0x10(%rax), %rcx
addq $0x1, %rcx
movq 0xa0(%rsp), %rax
movq %rcx, 0x48(%rax)
movq 0xa0(%rsp), %rax
movq 0x28(%rax), %rdi
movq 0x98(%rsp), %rax
movq 0x10(%rax), %rsi
addq $0x1, %rsi
shlq $0x3, %rsi
leaq 0xf199a(%rip), %rdx     # 0x5b8ab3
movl $0x270, %ecx            # imm = 0x270
callq 0xe8540
movq %rax, %rcx
movq 0xa0(%rsp), %rax
movq %rcx, 0x28(%rax)
jmp 0x4c7134
cmpq $0x0, 0xa0(%rsp)
je 0x4c7159
movq 0xa0(%rsp), %rax
cmpq $0x0, 0x50(%rax)
jbe 0x4c7159
cmpq $0x0, 0x98(%rsp)
jne 0x4c7191
movq 0x174e40(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4eea9(%rip), %rsi     # 0x516013
leaq 0xf1c98(%rip), %rdx     # 0x5b8e09
leaq 0xf1cd4(%rip), %rcx     # 0x5b8e4c
leaq 0xf1934(%rip), %r8      # 0x5b8ab3
movl $0x272, %r9d            # imm = 0x272
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4c7193
movq 0xa0(%rsp), %rdi
movq 0x98(%rsp), %rsi
callq 0x4c8560
movq %rax, 0x78(%rsp)
movq 0xa0(%rsp), %rax
movq 0x20(%rax), %rdi
movq 0x98(%rsp), %rax
movq 0x10(%rax), %rsi
movq 0xa0(%rsp), %rax
movq 0x50(%rax), %rdx
callq 0x4c86f0
movq %rax, 0x68(%rsp)
movq 0x68(%rsp), %rax
movq 0xa0(%rsp), %rcx
cmpq 0x10(%rcx), %rax
jbe 0x4c7226
movq 0x174dab(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ee14(%rip), %rsi     # 0x516013
leaq 0xf1c63(%rip), %rdx     # 0x5b8e69
leaq 0xf1c3f(%rip), %rcx     # 0x5b8e4c
leaq 0xf189f(%rip), %r8      # 0x5b8ab3
movl $0x277, %r9d            # imm = 0x277
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4c7228
movq 0xa0(%rsp), %rax
movq 0x10(%rax), %rax
subq 0x68(%rsp), %rax
movq %rax, 0x70(%rsp)
movq 0xa0(%rsp), %rdi
addq $0x30, %rdi
callq 0x4c87a0
movq %rax, 0x60(%rsp)
movq 0x98(%rsp), %rax
movq (%rax), %rcx
movq 0x98(%rsp), %rax
movq 0x8(%rax), %rax
shlq %rax
subq %rax, %rcx
movq 0x60(%rsp), %rax
movq %rcx, (%rax)
movq 0x98(%rsp), %rax
movq 0x10(%rax), %rcx
movq 0x60(%rsp), %rax
movq %rcx, 0x10(%rax)
movq 0xa0(%rsp), %rax
movq (%rax), %rax
movq 0x70(%rsp), %rcx
addq 0x78(%rsp), %rcx
movl (%rax,%rcx,4), %eax
andl $0x7, %eax
movb %al, %cl
movq 0x60(%rsp), %rax
movb %cl, 0x40(%rax)
movq 0x98(%rsp), %rax
movq 0x8(%rax), %rax
movl %eax, %ecx
movq 0x60(%rsp), %rax
movl %ecx, 0x38(%rax)
movq 0x60(%rsp), %rax
movb $0x0, 0x41(%rax)
movq 0xa0(%rsp), %rax
movq (%rax), %rax
movq 0x70(%rsp), %rcx
addq 0x78(%rsp), %rcx
movl (%rax,%rcx,4), %eax
shrl $0x3, %eax
movq 0x60(%rsp), %rcx
movl %eax, 0x3c(%rcx)
movl %eax, 0x34(%rsp)
movq 0x60(%rsp), %rax
movl 0x3c(%rax), %eax
movl %eax, %ecx
imulq 0x88(%rsp), %rcx
movq 0x60(%rsp), %rax
movq %rcx, 0x8(%rax)
movq 0x70(%rsp), %rcx
movq 0x60(%rsp), %rax
movq %rcx, 0x18(%rax)
movq 0x98(%rsp), %rax
movq 0x18(%rax), %rcx
movq 0x60(%rsp), %rax
movq %rcx, 0x20(%rax)
movq 0x60(%rsp), %rax
movl 0x3c(%rax), %eax
movl %eax, %ecx
movq 0x60(%rsp), %rax
movq %rcx, 0x28(%rax)
movq 0x60(%rsp), %rax
movq $0x0, 0x30(%rax)
movq 0xa0(%rsp), %rax
cmpq $0x0, 0x38(%rax)
jbe 0x4c755e
movq 0xa0(%rsp), %rax
movq 0x38(%rax), %rcx
addq $-0x1, %rcx
movq %rcx, 0x38(%rax)
movq 0xa0(%rsp), %rax
movq 0x30(%rax), %rax
movq 0xa0(%rsp), %rcx
imulq $0x48, 0x38(%rcx), %rcx
addq %rcx, %rax
movq %rax, 0x60(%rsp)
testb $0x1, 0x58(%rsp)
je 0x4c73c8
movq 0x60(%rsp), %rax
movq 0x28(%rax), %rax
movq 0x60(%rsp), %rcx
addq 0x30(%rcx), %rax
cmpq 0x90(%rsp), %rax
jb 0x4c73c8
movb $0x0, 0x58(%rsp)
movq 0x60(%rsp), %rax
cmpq $0x0, 0x30(%rax)
jbe 0x4c7478
jmp 0x4c73da
movq 0x60(%rsp), %rax
movq 0x30(%rax), %rax
subq $0x1, %rax
movq 0x98(%rsp), %rcx
cmpq 0x10(%rcx), %rax
jbe 0x4c742d
movq 0x174ba4(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ec0d(%rip), %rsi     # 0x516013
leaq 0xf1a92(%rip), %rdx     # 0x5b8e9f
leaq 0xf1a38(%rip), %rcx     # 0x5b8e4c
leaq 0xf1698(%rip), %r8      # 0x5b8ab3
movl $0x294, %r9d            # imm = 0x294
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4c742f
movq 0x60(%rsp), %rax
movb 0x41(%rax), %dl
movq 0xa0(%rsp), %rax
movq 0x28(%rax), %rax
movq 0x60(%rsp), %rcx
movq 0x30(%rcx), %rcx
subq $0x1, %rcx
movb %dl, (%rax,%rcx,8)
movq 0x60(%rsp), %rax
movl 0x3c(%rax), %edx
movq 0xa0(%rsp), %rax
movq 0x28(%rax), %rax
movq 0x60(%rsp), %rcx
movq 0x30(%rcx), %rcx
subq $0x1, %rcx
movl %edx, 0x4(%rax,%rcx,8)
movq 0x60(%rsp), %rax
movzbl 0x40(%rax), %eax
cmpl $0x0, %eax
je 0x4c7557
cmpq $0x0, 0xa8(%rsp)
jne 0x4c74cb
movq 0xd0(%rsp), %rdi
movq 0xe0(%rsp), %rsi
movq 0x60(%rsp), %rax
movq (%rax), %rdx
movq 0x60(%rsp), %rax
movl 0x38(%rax), %ecx
movq 0x60(%rsp), %rax
subl 0x3c(%rax), %ecx
movq 0x60(%rsp), %rax
movl 0x38(%rax), %r8d
callq 0x4c8460
movq 0xa0(%rsp), %rsi
movq 0x60(%rsp), %rax
movq (%rax), %rdx
movq 0x60(%rsp), %rax
movq 0x8(%rax), %rcx
movq 0x60(%rsp), %rax
movq 0x10(%rax), %r8
movq 0x60(%rsp), %rax
movb 0x40(%rax), %r9b
movq 0x60(%rsp), %rax
movq 0x18(%rax), %r15
movq 0x60(%rsp), %rax
movq 0x20(%rax), %r14
movq 0x60(%rsp), %rax
movl 0x38(%rax), %ebx
movq 0x60(%rsp), %rax
movl 0x3c(%rax), %r11d
movq 0x60(%rsp), %rax
movq 0x28(%rax), %r10
movq 0x60(%rsp), %rax
movq 0x30(%rax), %rax
leaq 0x38(%rsp), %rdi
movzbl %r9b, %r9d
movq %r15, (%rsp)
movq %r14, 0x8(%rsp)
movl %ebx, 0x10(%rsp)
movl %r11d, 0x18(%rsp)
movq %r10, 0x20(%rsp)
movq %rax, 0x28(%rsp)
callq 0x4c88c0
jmp 0x4c7559
jmp 0x4c755e
jmp 0x4c7358
jmp 0x4c7560
cmpq $0x0, 0x60(%rsp)
jne 0x4c75a0
movq 0x174a31(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ea9a(%rip), %rsi     # 0x516013
leaq 0xf194d(%rip), %rdx     # 0x5b8ecd
leaq 0xf18c5(%rip), %rcx     # 0x5b8e4c
leaq 0xf1525(%rip), %r8      # 0x5b8ab3
movl $0x2b6, %r9d            # imm = 0x2B6
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4c75a2
cmpq $0x0, 0xa8(%rsp)
je 0x4c75e3
movq 0xa8(%rsp), %rdi
movl 0x34(%rsp), %esi
movq 0xa0(%rsp), %rax
movq 0x28(%rax), %rdx
movq 0x60(%rsp), %rax
movq 0x30(%rax), %rcx
movq 0xd8(%rsp), %r8
movq 0xe8(%rsp), %r9
callq 0x4c8c20
addq $0xb0, %rsp
popq %rbx
popq %r14
popq %r15
retq