// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/idxlocalidp.c
// Function: nextcolumn
static void nextcolumn (const Limdfsconstinfo *lci,
                        LocaliColumn *outcol,
                        const GtUchar dbchar,
                        const LocaliColumn *incol)
{
  GtUword i;
#ifndef AFFINE
  Scoretype temp;
#endif

  gt_assert(outcol != incol);
  gt_assert(outcol->colvalues != incol->colvalues);
  gt_assert(incol->lenval >= lci->querylength+1);
  if (outcol->lenval < lci->querylength+1)
  {
    REALLOCMSG(outcol);
    outcol->colvalues = gt_realloc(outcol->colvalues,
                                   sizeof (LocaliMatrixvalue)
                                     * lci->maxcollen);
    outcol->lenval = lci->maxcollen;
    ATADDRESS("",outcol);
  }
  gt_assert(outcol->lenval >= lci->querylength+1);
#ifdef AFFINE
  outcol->colvalues[0].repcell = outcol->colvalues[0].delcell = GT_MINUSINFTY;
  if (incol->colvalues[0].inscell > 0)
  {
    if (incol->colvalues[0].bestcell > 0)
    {
      outcol->colvalues[0].inscell
        = max2 (incol->colvalues[0].inscell + lci->scorevalues.gapextend,
                incol->colvalues[0].bestcell + lci->scorevalues.gapstart +
                                               lci->scorevalues.gapextend);
    } else
    {
      outcol->colvalues[0].inscell = incol->colvalues[0].inscell +
                                     lci->scorevalues.gapextend;
    }
  } else
  {
    if (incol->colvalues[0].bestcell > 0)
    {
      outcol->colvalues[0].inscell = incol->colvalues[0].bestcell +
                                     lci->scorevalues.gapstart +
                                     lci->scorevalues.gapextend;
    } else
    {
      outcol->colvalues[0].inscell = GT_MINUSINFTY;
    }
  }
  outcol->colvalues[0].bestcell = max3 (outcol->colvalues[0].repcell,
                                        outcol->colvalues[0].inscell,
                                        outcol->colvalues[0].delcell);
#else
  outcol->colvalues[0].bestcell = GT_MINUSINFTY;
  outcol->colvalues[0].tracebit = Notraceback;
#endif
  outcol->maxvalue = 0;
  outcol->pprefixlen = 0;
  for (i = 1UL; i <= lci->querylength; i++)
  {
#ifdef AFFINE
    if (incol->colvalues[i-1].bestcell > 0)
    {
      outcol->colvalues[i].repcell = incol->colvalues[i-1].bestcell +
                                     REPLACEMENTSCORE(&lci->scorevalues,
                                                      dbchar,lci->query[i-1]);
    } else
    {
      outcol->colvalues[i].repcell = GT_MINUSINFTY;
    }
    if (incol->colvalues[i].inscell > 0)
    {
      if (incol->colvalues[i].bestcell > 0)
      {
        outcol->colvalues[i].inscell
          = max2 (incol->colvalues[i].inscell + lci->scorevalues.gapextend,
                  incol->colvalues[i].bestcell + lci->scorevalues.gapstart +
                                                 lci->scorevalues.gapextend);
      } else
      {
        outcol->colvalues[i].inscell = incol->colvalues[i].inscell +
                                       lci->scorevalues.gapextend;
      }
    } else
    {
      if (incol->colvalues[i].bestcell > 0)
      {
        outcol->colvalues[i].inscell = incol->colvalues[i].bestcell +
                                       lci->scorevalues.gapstart +
                                       lci->scorevalues.gapextend;
      } else
      {
        outcol->colvalues[i].inscell = GT_MINUSINFTY;
      }
    }
    if (outcol->colvalues[i-1].delcell > 0)
    {
      if (outcol->colvalues[i-1].bestcell > 0)
      {
        outcol->colvalues[i].delcell
          = max2 (outcol->colvalues[i-1].delcell + lci->scorevalues.gapextend,
                  outcol->colvalues[i-1].bestcell + lci->scorevalues.gapstart +
                                                    lci->scorevalues.gapextend);
      } else
      {
        outcol->colvalues[i].delcell = outcol->colvalues[i-1].delcell +
                                       lci->scorevalues.gapextend;
      }
    } else
    {
      if (outcol->colvalues[i-1].bestcell > 0)
      {
        outcol->colvalues[i].delcell = outcol->colvalues[i-1].bestcell +
                                       lci->scorevalues.gapstart +
                                       lci->scorevalues.gapextend;
      } else
      {
        outcol->colvalues[i].delcell = GT_MINUSINFTY;
      }
    }
    outcol->colvalues[i].bestcell = max3 (outcol->colvalues[i].repcell,
                                          outcol->colvalues[i].inscell,
                                          outcol->colvalues[i].delcell);
#else
    outcol->colvalues[i].bestcell = GT_MINUSINFTY;
    outcol->colvalues[i].tracebit = Notraceback;
    if (outcol->colvalues[i-1].bestcell > 0)
    {
      IDXLOCALIDP_UPDATEMAX(outcol->colvalues[i-1].bestcell
                              + lci->scorevalues.gapextend,
                            Deletebit);
    }
    if (incol->colvalues[i-1].bestcell > 0)
    {
      IDXLOCALIDP_UPDATEMAX(incol->colvalues[i-1].bestcell +
                REPLACEMENTSCORE(&lci->scorevalues,
                                 dbchar,lci->query[i-1]),Replacebit);
    }
    if (incol->colvalues[i].bestcell > 0)
    {
      IDXLOCALIDP_UPDATEMAX(incol->colvalues[i].bestcell
                              + lci->scorevalues.gapextend,
                            Insertbit);
    }
#endif
    if (outcol->colvalues[i].bestcell > 0 &&
        outcol->colvalues[i].bestcell > (Scoretype) outcol->maxvalue)
    {
      outcol->maxvalue = (GtUword) outcol->colvalues[i].bestcell;
      outcol->pprefixlen = i;
    }
  }
}

// Assembly:
subq $0x48, %rsp
movb %dl, %al
movq %rdi, 0x40(%rsp)
movq %rsi, 0x38(%rsp)
movb %al, 0x37(%rsp)
movq %rcx, 0x28(%rsp)
movq 0x38(%rsp), %rax
cmpq 0x28(%rsp), %rax
jne 0x259bfd
movq 0x3e23d4(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2bc43d(%rip), %rsi    # 0x516013
leaq 0x320dd5(%rip), %rdx    # 0x57a9b2
leaq 0x320dde(%rip), %rcx    # 0x57a9c2
leaq 0x320c15(%rip), %r8     # 0x57a800
movl $0xe0, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x259bff
jmp 0x259c01
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x28(%rsp), %rcx
cmpq (%rcx), %rax
jne 0x259c4b
movq 0x3e2386(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2bc3ef(%rip), %rsi    # 0x516013
leaq 0x320da2(%rip), %rdx    # 0x57a9cd
leaq 0x320d90(%rip), %rcx    # 0x57a9c2
leaq 0x320bc7(%rip), %r8     # 0x57a800
movl $0xe1, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x259c4d
jmp 0x259c4f
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x40(%rsp), %rcx
movq 0x30(%rcx), %rcx
addq $0x1, %rcx
cmpq %rcx, %rax
jae 0x259ca2
movq 0x3e232f(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2bc398(%rip), %rsi    # 0x516013
leaq 0x320d71(%rip), %rdx    # 0x57a9f3
leaq 0x320d39(%rip), %rcx    # 0x57a9c2
leaq 0x320b70(%rip), %r8     # 0x57a800
movl $0xe2, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x259ca4
movq 0x38(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x40(%rsp), %rcx
movq 0x30(%rcx), %rcx
addq $0x1, %rcx
cmpq %rcx, %rax
jae 0x259d02
movq 0x38(%rsp), %rax
movq (%rax), %rdi
movq 0x40(%rsp), %rax
movq 0x28(%rax), %rsi
shlq $0x4, %rsi
leaq 0x320b25(%rip), %rdx    # 0x57a800
movl $0xe8, %ecx
callq 0xe8540
movq %rax, %rcx
movq 0x38(%rsp), %rax
movq %rcx, (%rax)
movq 0x40(%rsp), %rax
movq 0x28(%rax), %rcx
movq 0x38(%rsp), %rax
movq %rcx, 0x8(%rax)
jmp 0x259d04
movq 0x38(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x40(%rsp), %rcx
movq 0x30(%rcx), %rcx
addq $0x1, %rcx
cmpq %rcx, %rax
jae 0x259d57
movq 0x3e227a(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2bc2e3(%rip), %rsi    # 0x516013
leaq 0x320ce0(%rip), %rdx    # 0x57aa17
leaq 0x320c84(%rip), %rcx    # 0x57a9c2
leaq 0x320abb(%rip), %r8     # 0x57a800
movl $0xec, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x259d59
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq $-0x1, (%rax)
movq 0x38(%rsp), %rax
movq (%rax), %rax
movl $0x0, 0x8(%rax)
movq 0x38(%rsp), %rax
movq $0x0, 0x18(%rax)
movq 0x38(%rsp), %rax
movq $0x0, 0x10(%rax)
movq $0x1, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq 0x40(%rsp), %rcx
cmpq 0x30(%rcx), %rax
ja 0x25a08e
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq $-0x1, (%rax)
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movl $0x0, 0x8(%rax)
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
subq $0x1, %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, (%rax)
jle 0x259e86
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
subq $0x1, %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq 0x40(%rsp), %rcx
addq 0x18(%rcx), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq 0x38(%rsp), %rcx
movq (%rcx), %rcx
movq 0x20(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rcx
cmpq (%rcx), %rax
jle 0x259e84
movq 0x18(%rsp), %rcx
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movl $0x3, 0x8(%rax)
jmp 0x259e86
movq 0x28(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
subq $0x1, %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, (%rax)
jle 0x259f79
movq 0x28(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
subq $0x1, %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, 0x10(%rsp)
movzbl 0x37(%rsp), %eax
movq 0x40(%rsp), %rcx
movq 0x20(%rcx), %rcx
movq 0x20(%rsp), %rdx
subq $0x1, %rdx
movzbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
jne 0x259ef3
movzbl 0x37(%rsp), %eax
cmpl $0xfe, %eax
jl 0x259f03
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x8(%rsp)
jmp 0x259f10
movq 0x40(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rax
movq 0x8(%rsp), %rcx
addq %rcx, %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq 0x38(%rsp), %rcx
movq (%rcx), %rcx
movq 0x20(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rcx
cmpq (%rcx), %rax
jle 0x259f77
movq 0x18(%rsp), %rcx
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movl $0x2, 0x8(%rax)
jmp 0x259f79
movq 0x28(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, (%rax)
jle 0x25a00f
movq 0x28(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq 0x40(%rsp), %rcx
addq 0x18(%rcx), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq 0x38(%rsp), %rcx
movq (%rcx), %rcx
movq 0x20(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rcx
cmpq (%rcx), %rax
jle 0x25a00d
movq 0x18(%rsp), %rcx
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movl $0x1, 0x8(%rax)
jmp 0x25a00f
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, (%rax)
jle 0x25a079
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq 0x38(%rsp), %rcx
cmpq 0x18(%rcx), %rax
jle 0x25a079
movq 0x38(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rcx
movq 0x38(%rsp), %rax
movq %rcx, 0x18(%rax)
movq 0x20(%rsp), %rcx
movq 0x38(%rsp), %rax
movq %rcx, 0x10(%rax)
jmp 0x25a07b
movq 0x20(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x20(%rsp)
jmp 0x259d9a
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)