// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/ft-front-prune.c
// Function: ft_update_trace_and_polished
static void ft_update_trace_and_polished(
                                      GtFtPolished_point *best_polished_point,
                                      GtFrontTrace *front_trace,
                                      const GtFtPolishing_info *pol_info,
                                      GtUword distance,
                                      GtUword trimleft,
                                      GtFtFrontvalue *midfront,
                                      GtFtFrontvalue *lowfront,
                                      GtFtFrontvalue *highfront,
                                      GT_UNUSED bool showfrontinfo)
{
  const GtFtFrontvalue *frontptr;

  for (frontptr = lowfront; frontptr <= highfront; frontptr++)
  {
    GtUword alignedlen = GT_MULT2(frontptr->row) + GT_FRONT_DIAGONAL(frontptr);

    gt_assert(GT_FRONT_DIAGONAL(frontptr) >= 0 ||
              frontptr->row >= -GT_FRONT_DIAGONAL(frontptr));
    if (alignedlen > best_polished_point->alignedlen)
    {
      uint64_t filled_matchhistory_bits = frontptr->matchhistory_bits;

      if (frontptr->matchhistory_size < pol_info->pol_size)
      {
        const int shift = pol_info->pol_size - frontptr->matchhistory_size;
        const uint64_t fill_bits = ((uint64_t) 1 << shift) - 1;
        filled_matchhistory_bits |= (fill_bits << frontptr->matchhistory_size);
      }
      if  (GT_HISTORY_IS_POLISHED(pol_info,filled_matchhistory_bits))
      {
        best_polished_point->alignedlen = alignedlen;
        best_polished_point->row = frontptr->row;
        best_polished_point->distance = distance;
        best_polished_point->trimleft = trimleft;
        best_polished_point->max_mismatches
          = (GtUword) frontptr->max_mismatches;
      }
    }
    if (front_trace != NULL)
    {
      front_trace_add_trace(front_trace,frontptr->backreference,
                            frontptr->localmatch_count);
    }
  }
}

// Assembly:
subq $0x78, %rsp
movb 0x90(%rsp), %al
movq 0x88(%rsp), %r10
movq 0x80(%rsp), %r10
movq %rdi, 0x70(%rsp)
movq %rsi, 0x68(%rsp)
movq %rdx, 0x60(%rsp)
movq %rcx, 0x58(%rsp)
movq %r8, 0x50(%rsp)
movq %r9, 0x48(%rsp)
andb $0x1, %al
movb %al, 0x47(%rsp)
movq 0x80(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x38(%rsp), %rax
cmpq 0x88(%rsp), %rax
ja 0x4cfbb7
movq 0x38(%rsp), %rax
movl 0x8(%rax), %eax
shll %eax
movl %eax, %eax
movq %rax, 0x10(%rsp)
movq 0x38(%rsp), %rax
movq 0x48(%rsp), %rcx
subq %rcx, %rax
movl $0x18, %ecx
cqto
idivq %rcx
movq %rax, %rcx
movq 0x10(%rsp), %rax
addq %rcx, %rax
movq %rax, 0x30(%rsp)
movq 0x38(%rsp), %rax
movq 0x48(%rsp), %rcx
subq %rcx, %rax
movl $0x18, %ecx
cqto
idivq %rcx
cmpq $0x0, %rax
jge 0x4cfa32
movq 0x38(%rsp), %rax
movl 0x8(%rax), %eax
movq %rax, 0x8(%rsp)
movq 0x38(%rsp), %rax
movq 0x48(%rsp), %rcx
subq %rcx, %rax
movl $0x18, %ecx
cqto
idivq %rcx
movq %rax, %rdx
movq 0x8(%rsp), %rax
xorl %ecx, %ecx
subq %rdx, %rcx
cmpq %rcx, %rax
jge 0x4cfa32
movq 0x16c59f(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x46608(%rip), %rsi     # 0x516013
leaq 0xe9e00(%rip), %rdx     # 0x5b9812
leaq 0xe9e4b(%rip), %rcx     # 0x5b9864
leaq 0xe9932(%rip), %r8      # 0x5b9352
movl $0x256, %r9d            # imm = 0x256
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x4cfa34
movq 0x30(%rsp), %rax
movq 0x70(%rsp), %rcx
cmpq (%rcx), %rax
jbe 0x4cfb7d
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x28(%rsp)
movq 0x38(%rsp), %rax
movzbl 0x10(%rax), %eax
movq 0x60(%rsp), %rcx
cmpq 0x10(%rcx), %rax
jae 0x4cfab5
movq 0x60(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x38(%rsp), %rcx
movzbl 0x10(%rcx), %ecx
subq %rcx, %rax
movl %eax, 0x24(%rsp)
movl 0x24(%rsp), %eax
movl %eax, %ecx
movl $0x1, %eax
shlq %cl, %rax
subq $0x1, %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq 0x38(%rsp), %rcx
movzbl 0x10(%rcx), %ecx
movl %ecx, %ecx
shlq %cl, %rax
orq 0x28(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0x60(%rsp), %rax
movq 0x30(%rax), %rax
movq 0x28(%rsp), %rcx
movq 0x60(%rsp), %rdx
andq 0x18(%rdx), %rcx
movswl 0x2(%rax,%rcx,4), %eax
cmpl $0x0, %eax
jl 0x4cfb7b
movq 0x60(%rsp), %rax
movq 0x30(%rax), %rax
movq 0x28(%rsp), %rcx
movq 0x60(%rsp), %rdx
andq 0x18(%rdx), %rcx
movswl (%rax,%rcx,4), %eax
movq 0x60(%rsp), %rcx
movq 0x30(%rcx), %rcx
movq %rcx, (%rsp)
movq 0x28(%rsp), %rdx
movq 0x60(%rsp), %rcx
movq 0x8(%rcx), %rcx
shrq %cl, %rdx
movq (%rsp), %rcx
movq 0x60(%rsp), %rsi
andq 0x18(%rsi), %rdx
movswl 0x2(%rcx,%rdx,4), %ecx
addl %ecx, %eax
cmpl $0x0, %eax
jl 0x4cfb7b
movq 0x30(%rsp), %rcx
movq 0x70(%rsp), %rax
movq %rcx, (%rax)
movq 0x38(%rsp), %rax
movl 0x8(%rax), %eax
movl %eax, %ecx
movq 0x70(%rsp), %rax
movq %rcx, 0x8(%rax)
movq 0x58(%rsp), %rcx
movq 0x70(%rsp), %rax
movq %rcx, 0x10(%rax)
movq 0x50(%rsp), %rcx
movq 0x70(%rsp), %rax
movq %rcx, 0x18(%rax)
movq 0x38(%rsp), %rax
movl 0x14(%rax), %eax
movl %eax, %ecx
movq 0x70(%rsp), %rax
movq %rcx, 0x20(%rax)
jmp 0x4cfb7d
cmpq $0x0, 0x68(%rsp)
je 0x4cfba2
movq 0x68(%rsp), %rdi
movq 0x38(%rsp), %rax
movb 0x11(%rax), %al
movq 0x38(%rsp), %rcx
movl 0xc(%rcx), %edx
movzbl %al, %esi
callq 0x4c6cf0
jmp 0x4cfba4
movq 0x38(%rsp), %rax
addq $0x18, %rax
movq %rax, 0x38(%rsp)
jmp 0x4cf95c
addq $0x78, %rsp
retq
nopl (%rax)