// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/extended/squarealign.c
// Function: gt_squarealign_ctab
GtUword gt_squarealign_ctab(GtLinspaceManagement *spacemanager,
                            const GtScoreHandler *scorehandler,
                            GtUword *Ctab,
                            const GtUchar *useq,
                            GtUword ustart,
                            GtUword ulen,
                            const GtUchar *vseq,
                            GtUword vstart,
                            GtUword vlen,
                            GtUword rowoffset)
{
  GtUword **E, distance;

  gt_assert(Ctab && spacemanager && scorehandler);

  E = gt_linspace_management_change_to_square(spacemanager,ulen,vlen);
  E = gt_linspace_management_change_to_square(spacemanager,ulen, vlen);

  fillDPtab_in_square_space(E, useq, ustart, ulen,
                            vseq, vstart, vlen, scorehandler);
  distance = E[ulen][vlen];

  evaluate_crosspoints_from_2dimtab(E, Ctab, scorehandler, useq, ustart, ulen,
                                    vseq, vstart, vlen,  rowoffset);
  return distance;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, 0x8(%rsp)
movq %rsi, 0x10(%rsp)
testq %rsi, %rsi
je 0x179e12
movq %rdi, %r13
testq %rdi, %rdi
je 0x179e12
cmpq $0x0, 0x8(%rsp)
je 0x179e12
movq %r9, %rbx
movq %r8, %r15
movq %rcx, %r14
movq 0x70(%rsp), %r12
movq 0x60(%rsp), %rbp
movq %r13, %rdi
movq %r9, %rsi
movq %r12, %rdx
callq 0x15be6b
movq %r13, %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq 0x15be6b
movq %rax, %r13
movq %rax, %rdi
movq %r14, %rsi
movq %r15, %rdx
movq %rbx, %rcx
movq %rbp, %r8
movq 0x68(%rsp), %r9
movq %r14, (%rsp)
movq 0x10(%rsp), %r14
pushq %r14
pushq %r12
callq 0x1798f9
addq $0x10, %rsp
movq (%r13,%rbx,8), %rax
movq (%rax,%r12,8), %rax
movq %rax, 0x18(%rsp)
movq %r14, %rdi
callq 0x171437
movq %rax, %rbp
cmpq $0x2, %r12
setb %cl
testq %rbx, %rbx
setne %al
sete %dl
testb %cl, %dl
jne 0x179df9
movq (%rsp), %rcx
addq %r15, %rcx
decq %rcx
movq %rcx, (%rsp)
movq 0x68(%rsp), %rcx
movq 0x60(%rsp), %rdx
addq %rdx, %rcx
decq %rcx
movq %rcx, 0x20(%rsp)
testq %r12, %r12
sete %cl
movl %eax, %edx
notb %dl
orb %cl, %dl
testb $0x1, %dl
jne 0x179d97
movq -0x8(%r13,%rbx,8), %rax
movq (%r13,%rbx,8), %rcx
movq (%rcx,%r12,8), %r15
movq -0x8(%rax,%r12,8), %r14
movq (%rsp), %rax
movzbl (%rax,%rbx), %esi
movq 0x20(%rsp), %rax
movzbl (%rax,%r12), %edx
movq 0x10(%rsp), %rdi
callq 0x171466
addq %r14, %rax
cmpq %rax, %r15
jne 0x179d9b
movq 0x78(%rsp), %rax
addq %rbx, %rax
decq %rax
decq %rbx
jmp 0x179dd7
testb $0x1, %al
je 0x179db7
movq -0x8(%r13,%rbx,8), %rax
movq (%r13,%rbx,8), %rcx
movq (%rax,%r12,8), %rax
addq %rbp, %rax
cmpq %rax, (%rcx,%r12,8)
jne 0x179db7
decq %rbx
jmp 0x179de4
testq %r12, %r12
je 0x179e0d
movq (%r13,%rbx,8), %rax
movq -0x8(%rax,%r12,8), %rcx
addq %rbp, %rcx
cmpq %rcx, (%rax,%r12,8)
jne 0x179e0d
movq 0x78(%rsp), %rax
addq %rbx, %rax
movq 0x8(%rsp), %rcx
movq %rax, -0x8(%rcx,%r12,8)
decq %r12
cmpq $0x2, %r12
setae %cl
testq %rbx, %rbx
setne %al
orb %al, %cl
jne 0x179d3f
movq 0x18(%rsp), %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x55def
callq 0x55db6