// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/randomcodes-hpcorrect.c
// Function: gt_randomcodes_hpcorrect_cluster_union_find
static inline GtUword gt_randomcodes_hpcorrect_cluster_union_find(
    bool *allidentical, GtUword nofsuffixes, GtWord clustering_minscore,
    GtRandomcodesHpcorrectData *sdata)
{
  gt_rchc_score_t hscore;
  GtUword i, j, nofclusters;
  bool identical = false;
  gt_assert(allidentical != NULL);
  *allidentical = true;
  gt_assert(sdata->union_find != NULL);
  gt_union_find_reset(sdata->union_find, nofsuffixes);
  gt_assert(sdata->skip != NULL);
  (void)memset(sdata->skip, 0, sizeof (sdata->skip) * nofsuffixes);
  for (i = 0; i < nofsuffixes; i++)
  {
    if (sdata->skip[i])
      continue;
    for (j = i+1; j < nofsuffixes; j++)
    {
      if (sdata->skip[j])
        continue;
      hscore = (sdata->pw_scores == NULL) ?
        gt_randomcodes_hpcorrect_compute_hscore(
            &identical, GT_RANDOMCODES_HPCORRECT_HMER(sdata,i),
            GT_RANDOMCODES_HPCORRECT_HMER(sdata,j), sdata->k
            /*,sdata->manhattan, clustering_minscore*/)
        : GT_RANDOMCODES_HPCORRECT_PW_SCORE(sdata,i,j);
      if (!identical)
        *allidentical = false;
      if (hscore >= clustering_minscore)
      {
        gt_union_find_union(sdata->union_find, i, j);
        if (identical)
          sdata->skip[j] = true;
      }
    }
  }
  (void)memset(sdata->cluster_size, 0, sizeof (sdata->cluster_size) *
      nofsuffixes);
  for (i = 0; i < nofsuffixes; i++)
    sdata->cluster_size[gt_union_find_find(sdata->union_find, i)]++;
  nofclusters = 0;
  for (i = 0; i < nofsuffixes; i++)
    if (sdata->cluster_size[i] > 0)
      nofclusters++;
  return nofclusters;
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movq %rdx, 0x50(%rsp)
movq %rcx, 0x48(%rsp)
movb $0x0, 0x27(%rsp)
cmpq $0x0, 0x60(%rsp)
jne 0x34341d
movq 0x2b8bdc(%rip), %rax    # 0x5fbfc8
movq (%rax), %rdi
leaq 0x1b81a7(%rip), %rsi    # 0x4fb59d
leaq 0x214144(%rip), %rdx    # 0x557541
leaq 0x2141b3(%rip), %rcx    # 0x5575b7
leaq 0x213fd1(%rip), %r8     # 0x5573dc
movl $0x1ab, %r9d            # imm = 0x1AB
movb $0x0, %al
callq 0x33960
callq 0x2f830
jmp 0x34341f
movq 0x60(%rsp), %rax
movb $0x1, (%rax)
movq 0x48(%rsp), %rax
cmpq $0x0, 0x98(%rax)
jne 0x34346e
movq 0x2b8b8b(%rip), %rax    # 0x5fbfc8
movq (%rax), %rdi
leaq 0x1b8156(%rip), %rsi    # 0x4fb59d
leaq 0x214195(%rip), %rdx    # 0x5575e3
leaq 0x214162(%rip), %rcx    # 0x5575b7
leaq 0x213f80(%rip), %r8     # 0x5573dc
movl $0x1ad, %r9d            # imm = 0x1AD
movb $0x0, %al
callq 0x33960
callq 0x2f830
jmp 0x343470
movq 0x48(%rsp), %rax
movq 0x98(%rax), %rdi
movq 0x58(%rsp), %rsi
callq 0x28e420
movq 0x48(%rsp), %rax
cmpq $0x0, 0x90(%rax)
jne 0x3434cd
movq 0x2b8b2c(%rip), %rax    # 0x5fbfc8
movq (%rax), %rdi
leaq 0x1b80f7(%rip), %rsi    # 0x4fb59d
leaq 0x214150(%rip), %rdx    # 0x5575fd
leaq 0x214103(%rip), %rcx    # 0x5575b7
leaq 0x213f21(%rip), %r8     # 0x5573dc
movl $0x1af, %r9d            # imm = 0x1AF
movb $0x0, %al
callq 0x33960
callq 0x2f830
jmp 0x3434cf
movq 0x48(%rsp), %rax
movq 0x90(%rax), %rdi
movq 0x58(%rsp), %rdx
shlq $0x3, %rdx
xorl %esi, %esi
callq 0x2f4c0
movq $0x0, 0x38(%rsp)
movq 0x38(%rsp), %rax
cmpq 0x58(%rsp), %rax
jae 0x3436d4
movq 0x48(%rsp), %rax
movq 0x90(%rax), %rax
movq 0x38(%rsp), %rcx
testb $0x1, (%rax,%rcx)
je 0x343520
jmp 0x3436c1
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
cmpq 0x58(%rsp), %rax
jae 0x3436bf
movq 0x48(%rsp), %rax
movq 0x90(%rax), %rax
movq 0x30(%rsp), %rcx
testb $0x1, (%rax,%rcx)
je 0x34355a
jmp 0x3436ac
movq 0x48(%rsp), %rax
cmpq $0x0, 0xa8(%rax)
jne 0x3435bc
movq 0x48(%rsp), %rax
movq 0x30(%rax), %rsi
movq 0x38(%rsp), %rax
movq 0x48(%rsp), %rcx
imulq 0x48(%rcx), %rax
addq %rax, %rsi
movq 0x48(%rsp), %rax
movq 0x30(%rax), %rdx
movq 0x30(%rsp), %rax
movq 0x48(%rsp), %rcx
imulq 0x48(%rcx), %rax
addq %rax, %rdx
movq 0x48(%rsp), %rax
movq 0x20(%rax), %rcx
leaq 0x27(%rsp), %rdi
callq 0x343b30
movq %rax, 0x18(%rsp)
jmp 0x34364c
movq 0x48(%rsp), %rax
movq 0xa8(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x30(%rsp), %rax
cmpq 0x38(%rsp), %rax
jb 0x34360a
movq 0x38(%rsp), %rax
movq 0x48(%rsp), %rcx
movq 0x40(%rcx), %rcx
shlq %rcx
subq $0x3, %rcx
subq 0x38(%rsp), %rcx
imulq %rcx, %rax
shrq %rax
addq 0x30(%rsp), %rax
subq $0x1, %rax
movq %rax, 0x8(%rsp)
jmp 0x343639
movq 0x30(%rsp), %rax
movq 0x48(%rsp), %rcx
movq 0x40(%rcx), %rcx
shlq %rcx
subq $0x3, %rcx
subq 0x30(%rsp), %rcx
imulq %rcx, %rax
shrq %rax
addq 0x38(%rsp), %rax
subq $0x1, %rax
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rax
movq 0x8(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x40(%rsp)
testb $0x1, 0x27(%rsp)
jne 0x343665
movq 0x60(%rsp), %rax
movb $0x0, (%rax)
movq 0x40(%rsp), %rax
cmpq 0x50(%rsp), %rax
jl 0x3436aa
movq 0x48(%rsp), %rax
movq 0x98(%rax), %rdi
movq 0x38(%rsp), %rsi
movq 0x30(%rsp), %rdx
callq 0x28e610
testb $0x1, 0x27(%rsp)
je 0x3436a8
movq 0x48(%rsp), %rax
movq 0x90(%rax), %rax
movq 0x30(%rsp), %rcx
movb $0x1, (%rax,%rcx)
jmp 0x3436aa
jmp 0x3436ac
movq 0x30(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x30(%rsp)
jmp 0x34352e
jmp 0x3436c1
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x38(%rsp)
jmp 0x3434f4
movq 0x48(%rsp), %rax
movq 0x38(%rax), %rdi
movq 0x58(%rsp), %rdx
shlq $0x3, %rdx
xorl %esi, %esi
callq 0x2f4c0
movq $0x0, 0x38(%rsp)
movq 0x38(%rsp), %rax
cmpq 0x58(%rsp), %rax
jae 0x343748
movq 0x48(%rsp), %rax
movq 0x38(%rax), %rax
movq %rax, (%rsp)
movq 0x48(%rsp), %rax
movq 0x98(%rax), %rdi
movq 0x38(%rsp), %rsi
callq 0x28e550
movq %rax, %rcx
movq (%rsp), %rax
movq (%rax,%rcx,8), %rdx
addq $0x1, %rdx
movq %rdx, (%rax,%rcx,8)
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x38(%rsp)
jmp 0x3436f6
movq $0x0, 0x28(%rsp)
movq $0x0, 0x38(%rsp)
movq 0x38(%rsp), %rax
cmpq 0x58(%rsp), %rax
jae 0x34379b
movq 0x48(%rsp), %rax
movq 0x38(%rax), %rax
movq 0x38(%rsp), %rcx
cmpq $0x0, (%rax,%rcx,8)
jbe 0x343789
movq 0x28(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x28(%rsp)
jmp 0x34378b
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x38(%rsp)
jmp 0x34375a
movq 0x28(%rsp), %rax
addq $0x68, %rsp
retq
nopw %cs:(%rax,%rax)