// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/extended/condenseq.c
// Function: gt_condenseq_add_unique_to_db
void gt_condenseq_add_unique_to_db(GtCondenseq *condenseq,
                                   GtUword orig_startpos,
                                   ces_unsigned len)
{
  gt_assert(len != 0);
  /* if previous unique and this one are not consecutive, add the new one */
  if (condenseq->uds_nelems == 0 ||
      condenseq->uniques[condenseq->uds_nelems - 1].orig_startpos +
      condenseq->uniques[condenseq->uds_nelems - 1].len != orig_startpos) {
    gt_assert(condenseq->uds_nelems == 0 ||
              condenseq->uniques[condenseq->uds_nelems - 1].orig_startpos +
              condenseq->uniques[condenseq->uds_nelems - 1].len <
              orig_startpos);
    gt_assert(condenseq->lds_nelems == 0 ||
              condenseq->links[condenseq->lds_nelems - 1].orig_startpos +
              condenseq->links[condenseq->lds_nelems - 1].len <=
              orig_startpos);
    condenseq_uds_resize(condenseq);
    condenseq->uniques[condenseq->uds_nelems].orig_startpos = orig_startpos;
    condenseq->uniques[condenseq->uds_nelems].len = len;
    condenseq->uniques[condenseq->uds_nelems].links.spaceuint32_t = NULL;
    condenseq->uds_nelems++;
  }
  else {
    condenseq->uniques[condenseq->uds_nelems - 1].len += len;
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testl %edx, %edx
je 0xc18f6
movl %edx, %ebx
movq %rsi, %r15
movq %rdi, %r14
movq 0x98(%rdi), %rcx
testq %rcx, %rcx
je 0xc1825
movq 0x10(%r14), %rax
imulq $0x28, %rcx, %rsi
movl -0x8(%rax,%rsi), %edx
movq -0x10(%rax,%rsi), %rdi
addq %rdx, %rdi
cmpq %r15, %rdi
jne 0xc181f
addq %rsi, %rax
addl %ebx, %edx
movl %edx, -0x8(%rax)
jmp 0xc18f0
jae 0xc1952
movq 0x70(%r14), %rax
testq %rax, %rax
je 0xc1848
movq 0x8(%r14), %rdx
shlq $0x5, %rax
movl -0x10(%rdx,%rax), %esi
addq -0x18(%rdx,%rax), %rsi
cmpq %r15, %rsi
ja 0xc1924
cmpq 0x90(%r14), %rcx
jne 0xc18d0
movq %rcx, %xmm0
punpckldq 0x226082(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1]
subpd 0x22608a(%rip), %xmm0   # 0x2e78f0
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
addsd %xmm0, %xmm1
mulsd 0x22649e(%rip), %xmm1   # 0x2e7d18
cvttsd2si %xmm1, %rax
movq %rax, %rdx
sarq $0x3f, %rdx
subsd 0x226492(%rip), %xmm1   # 0x2e7d20
cvttsd2si %xmm1, %rsi
andq %rdx, %rsi
orq %rax, %rsi
testq %rcx, %rcx
pushq $0x64
popq %rax
cmovneq %rsi, %rax
movq %rax, 0x90(%r14)
movq 0x10(%r14), %rdi
imulq $0x28, %rax, %rsi
leaq 0x2576bb(%rip), %rdx    # 0x318f74
movl $0x13f, %ecx            # imm = 0x13F
callq 0x93472
movq %rax, 0x10(%r14)
movq 0x98(%r14), %rcx
jmp 0xc18d4
movq 0x10(%r14), %rax
imulq $0x28, %rcx, %rdx
movq %r15, 0x18(%rax,%rdx)
movl %ebx, 0x20(%rax,%rdx)
andq $0x0, (%rax,%rdx)
incq %rcx
movq %rcx, 0x98(%r14)
popq %rbx
popq %r14
popq %r15
retq
movq 0x37666b(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x22370c(%rip), %rsi    # 0x2e5013
leaq 0x258d99(%rip), %rdx    # 0x31a6a7
leaq 0x2576b6(%rip), %rcx    # 0x318fcb
leaq 0x257658(%rip), %r8     # 0x318f74
movl $0x152, %r9d            # imm = 0x152
jmp 0xc197e
movq 0x37663d(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x2236de(%rip), %rsi    # 0x2e5013
leaq 0x25774b(%rip), %rdx    # 0x319087
leaq 0x257688(%rip), %rcx    # 0x318fcb
leaq 0x25762a(%rip), %r8     # 0x318f74
movl $0x15e, %r9d            # imm = 0x15E
jmp 0xc197e
movq 0x37660f(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x2236b0(%rip), %rsi    # 0x2e5013
leaq 0x25767f(%rip), %rdx    # 0x318fe9
leaq 0x25765a(%rip), %rcx    # 0x318fcb
leaq 0x2575fc(%rip), %r8     # 0x318f74
movl $0x15a, %r9d            # imm = 0x15A
xorl %eax, %eax
callq 0x17a50
callq 0x17390