// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/match/rdj-contigs-writer.c
// Function: gt_contigs_writer_append
void gt_contigs_writer_append(GtContigsWriter *contigs_writer,
    GtUword seqnum, GtUword nofchars)
{
  GtUword pos, i;
  gt_assert(contigs_writer != NULL);
  pos = gt_encseq_seqstartpos(contigs_writer->reads, seqnum) +
      gt_encseq_seqlength(contigs_writer->reads, seqnum) - nofchars;
  for (i = 0; i < nofchars; i++, pos++)
  {
    char *c;
    GT_GETNEXTFREEINARRAY(c, &contigs_writer->contig, char,
        GT_CONTIGS_WRITER_CONTIG_INC);
    *c = gt_encseq_get_encoded_char_nospecial(contigs_writer->reads, pos,
        GT_READMODE_FORWARD)["acgt"];
  }
  contigs_writer->depthinfo.depth++;
  if (contigs_writer->rcn != NULL)
  {
    contigs_writer->depthinfo.internal_copynum += contigs_writer->rcn[
      GT_CONTIGS_WRITER_READNUM(seqnum, contigs_writer->nofseqs)];
  }
  if (contigs_writer->show_paths)
  {
    gt_str_append_cstr(contigs_writer->path_desc, "-(");
    gt_str_append_uword(contigs_writer->path_desc, nofchars);
    gt_str_append_cstr(contigs_writer->path_desc, ")->");
    gt_str_append_uword(contigs_writer->path_desc,
        GT_CONTIGS_WRITER_READNUM(seqnum, contigs_writer->nofseqs));
    gt_str_append_char(contigs_writer->path_desc,
        GT_CONTIGS_WRITER_LETTER(seqnum, contigs_writer->nofseqs));
  }
  else
  {
    contigs_writer->lastseqnum = seqnum;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
testq %rdi, %rdi
je 0x1c8659
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %rdi
callq 0xeb6ee
movq %rax, %r12
movq (%rbx), %rdi
movq %r14, 0x10(%rsp)
movq %r14, %rsi
callq 0xeb9d2
movq %r15, 0x8(%rsp)
testq %r15, %r15
je 0x1c857a
addq %rax, %r12
movq 0x8(%rsp), %r15
negq %r15
leaq 0x195d71(%rip), %r14    # 0x35e280
movq 0x30(%rbx), %rsi
cmpq %rsi, 0x38(%rbx)
jae 0x1c851f
movq 0x28(%rbx), %rbp
jmp 0x1c8546
addq $0x4000, %rsi           # imm = 0x4000
movq %rsi, 0x30(%rbx)
movq 0x28(%rbx), %rdi
leaq 0x1e5995(%rip), %rdx    # 0x3adeca
movl $0xfa, %ecx
callq 0x104461
movq %rax, %rbp
movq %rax, 0x28(%rbx)
testq %rbp, %rbp
je 0x1c8654
leaq (%r12,%r15), %rsi
movq (%rbx), %rdi
movq 0x38(%rbx), %r13
leaq 0x1(%r13), %rax
movq %rax, 0x38(%rbx)
xorl %edx, %edx
callq 0xe7fcb
movzbl %al, %eax
movb (%rax,%r14), %al
movb %al, (%rbp,%r13)
incq %r15
jne 0x1c850f
incq 0x78(%rbx)
movq 0x98(%rbx), %rax
movq 0x10(%rsp), %r14
movq %r14, %r12
notq %r12
testq %rax, %rax
je 0x1c85c1
movq 0x60(%rbx), %rcx
movq %rcx, %rdx
shrq %rdx
addq %r12, %rcx
cmpq %r14, %rdx
cmovaq %r14, %rcx
movzbl (%rax,%rcx), %eax
cvtsi2ss %eax, %xmm0
addss 0x8c(%rbx), %xmm0
movss %xmm0, 0x8c(%rbx)
cmpb $0x1, 0x10(%rbx)
movq 0x8(%rsp), %r15
jne 0x1c8641
movq 0x48(%rbx), %rdi
leaq 0x1e59e2(%rip), %rsi    # 0x3adfb9
callq 0x11acf3
movq 0x48(%rbx), %rdi
movq %r15, %rsi
callq 0x11ae72
movq 0x48(%rbx), %rdi
leaq 0x1e59c9(%rip), %rsi    # 0x3adfbc
callq 0x11acf3
movq 0x48(%rbx), %rdi
movq 0x60(%rbx), %rax
addq %rax, %r12
shrq %rax
cmpq %r14, %rax
cmovaq %r14, %r12
movq %r12, %rsi
callq 0x11ae72
movq 0x60(%rbx), %rax
shrq %rax
xorl %ecx, %ecx
cmpq %r14, %rax
seta %cl
movq 0x48(%rbx), %rdi
leal (%rcx,%rcx,2), %esi
addl $0x42, %esi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x11af23
movq %r14, 0x58(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x6a5b7
callq 0x6a5f0