// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/xdrop.c
// Function: gt_calculatedistancesfromscores
static void
gt_calculatedistancesfromscores(const GtXdropArbitraryscores *arbitscores,
                                GtXdropArbitrarydistances *dist)
{
  int mat, mis, ins, del;

  /* if mat is odd double all scores */
  gt_assert(arbitscores->mat > 0);
  if (GT_MOD2((unsigned int) arbitscores->mat) > 0)
  {
    mat = arbitscores->mat * 2;
    mis = arbitscores->mis * 2;
    ins = arbitscores->ins * 2;
    del = arbitscores->del * 2;
  } else
  {
    mat = arbitscores->mat;
    mis = arbitscores->mis;
    ins = arbitscores->ins;
    del = arbitscores->del;
  }
  gt_assert(mat >= mis && mat/2 >= ins && mat/2 >= del);
  dist->gcd = (int) gt_gcd_uint(gt_gcd_uint((unsigned int) (mat-mis),
                                            (unsigned int) (mat/2-ins)),
                                (unsigned int) (mat/2-del));
  dist->mis = (mat - mis) / dist->gcd;
  dist->ins = (mat/2 - ins) / dist->gcd;
  dist->del = (mat/2 - del) / dist->gcd;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rax
cmpl $0x0, (%rax)
jg 0x2f8440
movq 0x343b91(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x21dbfa(%rip), %rsi    # 0x516013
leaq 0x297e39(%rip), %rdx    # 0x590259
leaq 0x297e47(%rip), %rcx    # 0x59026e
leaq 0x297ad4(%rip), %r8     # 0x58ff02
movl $0x87, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2f8442
movq 0x20(%rsp), %rax
movl (%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jbe 0x2f848a
movq 0x20(%rsp), %rax
movl (%rax), %eax
shll %eax
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movl 0x4(%rax), %eax
shll %eax
movl %eax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movl 0x8(%rax), %eax
shll %eax
movl %eax, 0xc(%rsp)
movq 0x20(%rsp), %rax
movl 0xc(%rax), %eax
shll %eax
movl %eax, 0x8(%rsp)
jmp 0x2f84b9
movq 0x20(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movl 0x4(%rax), %eax
movl %eax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movl 0x8(%rax), %eax
movl %eax, 0xc(%rsp)
movq 0x20(%rsp), %rax
movl 0xc(%rax), %eax
movl %eax, 0x8(%rsp)
jmp 0x2f84bb
movl 0x14(%rsp), %eax
cmpl 0x10(%rsp), %eax
jl 0x2f84e9
movl 0x14(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
cmpl 0xc(%rsp), %eax
jl 0x2f84e9
movl 0x14(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
cmpl 0x8(%rsp), %eax
jge 0x2f8521
movq 0x343ab0(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x21db19(%rip), %rsi    # 0x516013
leaq 0x297d8d(%rip), %rdx    # 0x59028e
leaq 0x297d66(%rip), %rcx    # 0x59026e
leaq 0x2979f3(%rip), %r8     # 0x58ff02
movl $0x95, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2f8523
movl 0x14(%rsp), %edi
subl 0x10(%rsp), %edi
movl 0x14(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %esi
subl 0xc(%rsp), %esi
callq 0xeca20
movl %eax, %edi
movl 0x14(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %esi
subl 0x8(%rsp), %esi
callq 0xeca20
movl %eax, %ecx
movq 0x18(%rsp), %rax
movl %ecx, 0xc(%rax)
movl 0x14(%rsp), %eax
subl 0x10(%rsp), %eax
movq 0x18(%rsp), %rcx
cltd
idivl 0xc(%rcx)
movl %eax, %ecx
movq 0x18(%rsp), %rax
movl %ecx, (%rax)
movl 0x14(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
subl 0xc(%rsp), %eax
movq 0x18(%rsp), %rcx
cltd
idivl 0xc(%rcx)
movl %eax, %ecx
movq 0x18(%rsp), %rax
movl %ecx, 0x4(%rax)
movl 0x14(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
subl 0x8(%rsp), %eax
movq 0x18(%rsp), %rcx
cltd
idivl 0xc(%rcx)
movl %eax, %ecx
movq 0x18(%rsp), %rax
movl %ecx, 0x8(%rax)
addq $0x28, %rsp
retq
nopw (%rax,%rax)