// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/sfx-diffcov.c
// Function: dc_validate_samplepositions
static void dc_validate_samplepositions(const GtDifferencecover *dcov)
{
  GtUword pos;
  unsigned int modvalue;
  Diffvalue *diffptr, *afterend;
  GtUword idx;
  GtBitsequence *sampleidxused = NULL;

  GT_INITBITTAB(sampleidxused,dcov->samplesize_upperbound);
  diffptr = dcov->diffvalues;
  afterend = dcov->diffvalues + dcov->size;
  for (pos = 0, modvalue = 0; pos <= dcov->totallength; pos++)
  {
    gt_assert((GtUword) modvalue == (GtUword) GT_MODV(pos));
    gt_assert(diffptr == afterend || *diffptr >= (Diffvalue) modvalue);
    if (diffptr < afterend && (Diffvalue) modvalue == *diffptr)
    {
      idx = dc_differencecover_packsamplepos(dcov,pos);
      gt_assert(sampleidxused != NULL);
      if (GT_ISIBITSET(sampleidxused,idx))
      {
        fprintf(stderr,
                "sample index "GT_WU" for pos "GT_WU" already used before\n",
                idx,(GtUword) pos);
        exit(GT_EXIT_PROGRAMMING_ERROR);
      }
      GT_SETIBIT(sampleidxused,idx);
      diffptr++;
    }
    if (modvalue < dcov->vmodmask)
    {
      modvalue++;
    } else
    {
      modvalue = 0;
      diffptr = dcov->diffvalues;
    }
  }
  gt_free(sampleidxused);
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq $0x0, 0x10(%rsp)
movq 0x40(%rsp), %rax
movq 0x80(%rax), %rax
shrq $0x6, %rax
cmpq $0x0, %rax
jne 0x2bfa73
movl $0x1, %eax
movq %rax, (%rsp)
jmp 0x2bfa8f
movq 0x40(%rsp), %rax
movq 0x80(%rax), %rax
subq $0x1, %rax
shrq $0x6, %rax
addq $0x1, %rax
movq %rax, (%rsp)
movq (%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rsi
shlq $0x3, %rsi
xorl %eax, %eax
movl %eax, %edi
leaq 0x2c9d0f(%rip), %rdx    # 0x5897bb
movl $0x297, %ecx            # imm = 0x297
callq 0xe8540
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rdx
shlq $0x3, %rdx
xorl %esi, %esi
callq 0x19360
movq 0x40(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, 0x28(%rsp)
movq 0x40(%rsp), %rax
movq 0x30(%rax), %rax
movq 0x40(%rsp), %rcx
movl 0x8(%rcx), %ecx
shlq %rcx
addq %rcx, %rax
movq %rax, 0x20(%rsp)
movq $0x0, 0x38(%rsp)
movl $0x0, 0x34(%rsp)
movq 0x38(%rsp), %rax
movq 0x40(%rsp), %rcx
cmpq 0x48(%rcx), %rax
ja 0x2bfd2c
jmp 0x2bfb21
movl 0x34(%rsp), %eax
movq 0x38(%rsp), %rcx
movq 0x40(%rsp), %rdx
movl 0xc(%rdx), %edx
andq %rdx, %rcx
cmpq %rcx, %rax
je 0x2bfb72
movq 0x37c45f(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2564c8(%rip), %rsi    # 0x516013
leaq 0x2ca9d1(%rip), %rdx    # 0x58a523
leaq 0x2ca9f7(%rip), %rcx    # 0x58a550
leaq 0x2c9c5b(%rip), %r8     # 0x5897bb
movl $0x29c, %r9d            # imm = 0x29C
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2bfb74
jmp 0x2bfb76
movq 0x28(%rsp), %rax
cmpq 0x20(%rsp), %rax
je 0x2bfbcd
movq 0x28(%rsp), %rax
movzwl (%rax), %eax
movl 0x34(%rsp), %ecx
movzwl %cx, %ecx
cmpl %ecx, %eax
jge 0x2bfbcd
movq 0x37c404(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x25646d(%rip), %rsi    # 0x516013
leaq 0x2ca9bf(%rip), %rdx    # 0x58a56c
leaq 0x2ca99c(%rip), %rcx    # 0x58a550
leaq 0x2c9c00(%rip), %r8     # 0x5897bb
movl $0x29d, %r9d            # imm = 0x29D
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2bfbcf
movq 0x28(%rsp), %rax
cmpq 0x20(%rsp), %rax
jae 0x2bfce6
movl 0x34(%rsp), %eax
movzwl %ax, %eax
movq 0x28(%rsp), %rcx
movzwl (%rcx), %ecx
cmpl %ecx, %eax
jne 0x2bfce6
movq 0x40(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x2c4040
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0x2bfc4a
movq 0x37c387(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x2563f0(%rip), %rsi    # 0x516013
leaq 0x2ca97a(%rip), %rdx    # 0x58a5a4
leaq 0x2ca91f(%rip), %rcx    # 0x58a550
leaq 0x2c9b83(%rip), %r8     # 0x5897bb
movl $0x2a1, %r9d            # imm = 0x2A1
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x2bfc4c
movq 0x10(%rsp), %rax
movq 0x18(%rsp), %rcx
shrq $0x6, %rcx
movq (%rax,%rcx,8), %rax
movq 0x18(%rsp), %rcx
andq $0x3f, %rcx
movabsq $-0x8000000000000000, %rdx # imm = 0x8000000000000000
shrq %cl, %rdx
movq %rdx, %rcx
andq %rcx, %rax
cmpq $0x0, %rax
je 0x2bfcac
movq 0x37c319(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
movq 0x18(%rsp), %rdx
movq 0x38(%rsp), %rcx
leaq 0x2ca91f(%rip), %rsi    # 0x58a5ba
movb $0x0, %al
callq 0x199f0
movl $0x2, %edi
callq 0x19890
movq 0x18(%rsp), %rcx
andq $0x3f, %rcx
movabsq $-0x8000000000000000, %rdx # imm = 0x8000000000000000
shrq %cl, %rdx
movq 0x10(%rsp), %rax
movq 0x18(%rsp), %rcx
shrq $0x6, %rcx
orq (%rax,%rcx,8), %rdx
movq %rdx, (%rax,%rcx,8)
movq 0x28(%rsp), %rax
addq $0x2, %rax
movq %rax, 0x28(%rsp)
movl 0x34(%rsp), %eax
movq 0x40(%rsp), %rcx
cmpl 0xc(%rcx), %eax
jae 0x2bfd01
movl 0x34(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x34(%rsp)
jmp 0x2bfd17
movl $0x0, 0x34(%rsp)
movq 0x40(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, 0x28(%rsp)
jmp 0x2bfd19
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x38(%rsp)
jmp 0x2bfb0b
movq 0x10(%rsp), %rdi
leaq 0x2c9a83(%rip), %rsi    # 0x5897bb
movl $0x2b5, %edx            # imm = 0x2B5
callq 0xe88c0
addq $0x48, %rsp
retq
nopw (%rax,%rax)