// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/extended/clustered_set_uf.c
// Function: gt_clustered_set_union_find_unit_test
int gt_clustered_set_union_find_unit_test(GtError *err)
{
  int had_err = 0, i = 0, j = 0;
  GtClusteredSet *cs = NULL;
  cs = gt_clustered_set_union_find_new(1, err);
  gt_ensure(
            gt_clustered_set_union_find_num_of_elements(cs, err) ==
            gt_clustered_set_union_find_cluster_num(cs, 0, err));
  gt_ensure(
            gt_clustered_set_union_find_num_of_clusters(cs, err) == 0);
  gt_clustered_set_union_find_delete(cs, err);

  if (!had_err) {
    cs = gt_clustered_set_union_find_new(2, err);
    gt_clustered_set_union_find_merge_clusters(cs, 0, 1, err);

    gt_ensure(
              gt_clustered_set_union_find_num_of_clusters(cs, err) == 1);
    gt_ensure(
              gt_clustered_set_union_find_cluster_num(cs, 0, err) ==
              gt_clustered_set_union_find_cluster_num(cs, 1, err));
    gt_ensure(
              gt_clustered_set_union_find_num_of_clusters(cs, err) == 1);

    gt_clustered_set_union_find_delete(cs, err);
  }

  if (!had_err) {
    cs = gt_clustered_set_union_find_new(3, err);
    gt_clustered_set_union_find_merge_clusters(cs, 0, 1, err);
    gt_clustered_set_union_find_merge_clusters(cs, 1, 2, err);

    gt_ensure(
               gt_clustered_set_union_find_num_of_clusters(cs, err) == 1);
    gt_ensure(
               gt_clustered_set_union_find_cluster_num(cs, 0, err) ==
               gt_clustered_set_union_find_cluster_num(cs, 1, err));

    gt_ensure(
               gt_clustered_set_union_find_cluster_num(cs, 0, err) ==
               gt_clustered_set_union_find_cluster_num(cs, 2, err));

    gt_ensure(
              gt_clustered_set_union_find_cluster_num(cs, 1, err) ==
              gt_clustered_set_union_find_cluster_num(cs, 2, err));

    gt_clustered_set_union_find_delete(cs, err);
  }

  if (!had_err) {
    cs = gt_clustered_set_union_find_new(4, err);
    gt_clustered_set_union_find_merge_clusters(cs, 0, 1, err);
    gt_clustered_set_union_find_merge_clusters(cs, 2, 3, err);

    gt_ensure(
              gt_clustered_set_union_find_num_of_clusters(cs, err) == 2);

    gt_clustered_set_union_find_merge_clusters(cs, 0, 2, err);

    for (i = 0; i < 4 - 1; i++) {
      for (j = i + 1; j < 4; j++) {
        gt_ensure(
                  gt_clustered_set_union_find_cluster_num(cs, i, err) ==
                  gt_clustered_set_union_find_cluster_num(cs, j, err));
      }
    }
    gt_clustered_set_union_find_delete(cs, err);
  }

  if (!had_err) {
    cs = gt_clustered_set_union_find_new(CLUSTERED_SET_UNION_FIND_TEST_SIZE,
                                         err);

    for (i = 0; !had_err && i < CLUSTERED_SET_UNION_FIND_TEST_SIZE; i++) {
      gt_ensure(
                gt_clustered_set_union_find_num_of_elements(cs, err) ==
                gt_clustered_set_union_find_cluster_num(cs, i, err));
    }
    for (i = 1;!had_err && i < CLUSTERED_SET_UNION_FIND_TEST_SIZE; i++) {
      gt_clustered_set_union_find_merge_clusters(cs, 0, i, err);
    }

    for (i = 0; !had_err && i < CLUSTERED_SET_UNION_FIND_TEST_SIZE; i++) {
      gt_ensure(
                gt_clustered_set_union_find_cluster_num(cs, i, err) == 0);
    }
    gt_clustered_set_union_find_delete(cs, err);
  }

  return had_err;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl $0x1, %edi
callq 0x3060d1
movq %rax, %r14
movq %rax, %rdi
callq 0x305cc9
movq %rax, %r15
movq %r14, %rdi
xorl %esi, %esi
callq 0x305cd9
cmpq %rax, %r15
jne 0x3061a2
movq %r14, %rdi
callq 0x305cb9
testq %rax, %rax
je 0x3061ec
leaq 0x613b8(%rip), %rsi     # 0x36753a
leaq 0xe04ca(%rip), %rdx     # 0x3e6653
leaq 0xe049d(%rip), %rcx     # 0x3e662d
leaq 0xe02d1(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x14a, %r9d            # imm = 0x14A
jmp 0x3061c7
leaq 0x61391(%rip), %rsi     # 0x36753a
leaq 0xe0411(%rip), %rdx     # 0x3e65c1
leaq 0xe0476(%rip), %rcx     # 0x3e662d
leaq 0xe02aa(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x148, %r9d            # imm = 0x148
xorl %eax, %eax
callq 0x1019cf
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movq %r14, %rdi
callq 0x305c87
movl %ebp, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
callq 0x305c87
movl $0x2, %edi
callq 0x3060d1
movq %rax, %r14
movl $0x1, %edx
movq %rax, %rdi
xorl %esi, %esi
movq %rbx, %rcx
callq 0x305d16
movq %r14, %rdi
callq 0x305cb9
cmpq $0x1, %rax
jne 0x30657b
movq %r14, %rdi
xorl %esi, %esi
callq 0x305cd9
movq %rax, %r15
movl $0x1, %esi
movq %r14, %rdi
callq 0x305cd9
cmpq %rax, %r15
jne 0x3065a5
movq %r14, %rdi
callq 0x305cb9
cmpq $0x1, %rax
jne 0x3065cf
movq %r14, %rdi
callq 0x305c87
movl $0x3, %edi
callq 0x3060d1
movq %rax, %r14
movl $0x1, %edx
movq %rax, %rdi
xorl %esi, %esi
movq %rbx, %rcx
callq 0x305d16
movl $0x1, %esi
movl $0x2, %edx
movq %r14, %rdi
movq %rbx, %rcx
callq 0x305d16
movq %r14, %rdi
callq 0x305cb9
cmpq $0x1, %rax
jne 0x3065f9
movq %r14, %rdi
xorl %esi, %esi
callq 0x305cd9
movq %rax, %r15
movl $0x1, %esi
movq %r14, %rdi
callq 0x305cd9
cmpq %rax, %r15
jne 0x306623
movq %r14, %rdi
xorl %esi, %esi
callq 0x305cd9
movq %rax, %r15
movl $0x2, %esi
movq %r14, %rdi
callq 0x305cd9
cmpq %rax, %r15
jne 0x30664d
movl $0x1, %esi
movq %r14, %rdi
callq 0x305cd9
movq %rax, %r15
movl $0x2, %esi
movq %r14, %rdi
callq 0x305cd9
cmpq %rax, %r15
jne 0x306677
movq %r14, %rdi
callq 0x305c87
movl $0x4, %edi
callq 0x3060d1
movq %rax, %r14
xorl %ebp, %ebp
movl $0x1, %r12d
movl $0x1, %edx
movq %rax, %rdi
xorl %esi, %esi
movq %rbx, %rcx
callq 0x305d16
movl $0x2, %esi
movl $0x3, %edx
movq %r14, %rdi
movq %rbx, %rcx
callq 0x305d16
movq %r14, %rdi
callq 0x305cb9
cmpq $0x2, %rax
je 0x306397
leaq 0x611cd(%rip), %rsi     # 0x36753a
leaq 0xe0494(%rip), %rdx     # 0x3e6808
leaq 0xe02b2(%rip), %rcx     # 0x3e662d
leaq 0xe00e6(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x178, %r9d            # imm = 0x178
xorl %eax, %eax
callq 0x1019cf
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
xorl %r15d, %r15d
movl $0x2, %edx
movq %r14, %rdi
xorl %esi, %esi
movq %rbx, (%rsp)
movq %rbx, %rcx
callq 0x305d16
leaq 0x1(%r15), %rax
movq %rax, 0x8(%rsp)
movq %r12, 0x10(%rsp)
movl %ebp, %eax
xorl %ebp, %ebp
testl %eax, %eax
je 0x3063ca
xorl %ebx, %ebx
jmp 0x306419
movq %r14, %rdi
movq %r15, %rsi
callq 0x305cd9
movq %rax, %r13
movq %r14, %rdi
movq %r12, %rsi
callq 0x305cd9
movb $0x1, %bl
cmpq %rax, %r13
je 0x30641e
xorl %ebx, %ebx
movq (%rsp), %rdi
leaq 0x61143(%rip), %rsi     # 0x36753a
leaq 0xe0444(%rip), %rdx     # 0x3e6842
leaq 0xe0228(%rip), %rcx     # 0x3e662d
leaq 0xe005c(%rip), %r8      # 0x3e6468
movl $0x180, %r9d            # imm = 0x180
xorl %eax, %eax
callq 0x1019cf
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
incq %r12
cmpq $0x4, %r12
jne 0x3063be
movq 0x10(%rsp), %r12
incq %r12
movq 0x8(%rsp), %r15
cmpq $0x3, %r15
jne 0x3063b0
movq %r14, %rdi
callq 0x305c87
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testb %bl, %bl
je 0x3061db
movl $0x400, %edi            # imm = 0x400
callq 0x3060d1
movq %rax, %r14
xorl %r13d, %r13d
movq (%rsp), %rbx
movq %r14, %rdi
callq 0x305cc9
movq %rax, %r15
movq %r14, %rdi
movq %r13, %rsi
callq 0x305cd9
movq %rax, %r12
movl $0x0, %ebp
cmpq %rax, %r15
je 0x3064bb
movq %rbx, %rdi
leaq 0x610a6(%rip), %rsi     # 0x36753a
leaq 0xe0412(%rip), %rdx     # 0x3e68ad
leaq 0xe018b(%rip), %rcx     # 0x3e662d
leaq 0xdffbf(%rip), %r8      # 0x3e6468
movl $0x18d, %r9d            # imm = 0x18D
xorl %eax, %eax
callq 0x1019cf
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmpq %r12, %r15
jne 0x3064d0
leaq 0x1(%r13), %rax
cmpq $0x3ff, %r13            # imm = 0x3FF
movq %rax, %r13
jb 0x306467
cmpq %r12, %r15
jne 0x3061d3
movl $0x1, %r13d
movq %r14, %rdi
xorl %esi, %esi
movq %r13, %rdx
movq %rbx, %rcx
callq 0x305d16
cmpq %r12, %r15
jne 0x306504
leaq 0x1(%r13), %rax
cmpq $0x3ff, %r13            # imm = 0x3FF
movq %rax, %r13
jb 0x3064df
cmpq %r12, %r15
jne 0x3061d3
leaq 0xdff54(%rip), %r15     # 0x3e6468
xorl %r12d, %r12d
movq %r14, %rdi
movq %r12, %rsi
callq 0x305cd9
movq %rax, %r13
movl $0x0, %ebp
testq %rax, %rax
je 0x30655c
movq %rbx, %rdi
leaq 0x61001(%rip), %rsi     # 0x36753a
leaq 0xe03d9(%rip), %rdx     # 0x3e6919
leaq 0xe00e6(%rip), %rcx     # 0x3e662d
movq %r15, %r8
movl $0x195, %r9d            # imm = 0x195
xorl %eax, %eax
callq 0x1019cf
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %r13, %r13
jne 0x3061d3
leaq 0x1(%r12), %rax
cmpq $0x3ff, %r12            # imm = 0x3FF
movq %rax, %r12
jb 0x306517
jmp 0x3061d3
leaq 0x60fb8(%rip), %rsi     # 0x36753a
leaq 0xe0104(%rip), %rdx     # 0x3e668d
leaq 0xe009d(%rip), %rcx     # 0x3e662d
leaq 0xdfed1(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x152, %r9d            # imm = 0x152
jmp 0x3061c7
leaq 0x60f8e(%rip), %rsi     # 0x36753a
leaq 0xe0114(%rip), %rdx     # 0x3e66c7
leaq 0xe0073(%rip), %rcx     # 0x3e662d
leaq 0xdfea7(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x155, %r9d            # imm = 0x155
jmp 0x3061c7
leaq 0x60f64(%rip), %rsi     # 0x36753a
leaq 0xe00b0(%rip), %rdx     # 0x3e668d
leaq 0xe0049(%rip), %rcx     # 0x3e662d
leaq 0xdfe7d(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x157, %r9d            # imm = 0x157
jmp 0x3061c7
leaq 0x60f3a(%rip), %rsi     # 0x36753a
leaq 0xe0086(%rip), %rdx     # 0x3e668d
leaq 0xe001f(%rip), %rcx     # 0x3e662d
leaq 0xdfe53(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x162, %r9d            # imm = 0x162
jmp 0x3061c7
leaq 0x60f10(%rip), %rsi     # 0x36753a
leaq 0xe0096(%rip), %rdx     # 0x3e66c7
leaq 0xdfff5(%rip), %rcx     # 0x3e662d
leaq 0xdfe29(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x165, %r9d            # imm = 0x165
jmp 0x3061c7
leaq 0x60ee6(%rip), %rsi     # 0x36753a
leaq 0xe00d7(%rip), %rdx     # 0x3e6732
leaq 0xdffcb(%rip), %rcx     # 0x3e662d
leaq 0xdfdff(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x169, %r9d            # imm = 0x169
jmp 0x3061c7
leaq 0x60ebc(%rip), %rsi     # 0x36753a
leaq 0xe0118(%rip), %rdx     # 0x3e679d
leaq 0xdffa1(%rip), %rcx     # 0x3e662d
leaq 0xdfdd5(%rip), %r8      # 0x3e6468
movq %rbx, %rdi
movl $0x16d, %r9d            # imm = 0x16D
jmp 0x3061c7
nopl (%rax)