// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/extended/genome_node.c
// Function: gt_genome_node_unit_test
int gt_genome_node_unit_test(GtError *err)
{
  int had_err = 0;
  GtGenomeNodeClass *gnc;
  GtGenomeNode *gn;
  void *testptr1 = "foo bar",
       *testptr2 = NULL;
  const char *testkey1 = "key1",
             *testkey2 = "key2";
  gt_error_check(err);

  testptr2 = gt_malloc(sizeof (char)*4);

  /* this is a very simple GtGenomeNodeClass without any callbacks */
  gnc = gt_calloc(1, sizeof (GtGenomeNodeClass));
  gnc->size = sizeof (GtGenomeNode);

  gn = gt_genome_node_create(gnc);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey1) == NULL);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey2) == NULL);
  gt_ensure(gn->userdata_nof_items == 0);
  gt_ensure(gn->userdata == NULL);

  gt_genome_node_add_user_data(gn, testkey1, testptr1, NULL);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey1) != NULL);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey1) == testptr1);
  gt_ensure(gn->userdata_nof_items == 1);
  gt_ensure(gn->userdata != NULL);

  gt_genome_node_add_user_data(gn, testkey2, testptr2, gt_free_func);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey2) != NULL);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey2) == testptr2);
  gt_ensure(gn->userdata_nof_items == 2);

  gt_genome_node_release_user_data(gn, testkey1);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey1) == NULL);
  gt_ensure(gn->userdata_nof_items == 1);

  gt_genome_node_release_user_data(gn, testkey2);
  gt_ensure(gt_genome_node_get_user_data(gn, testkey2) == NULL);
  gt_ensure(gn->userdata_nof_items == 0);
  gt_ensure(gn->userdata == NULL);

  testptr2 = gt_malloc(sizeof (char)*4);
  gt_genome_node_add_user_data(gn, testkey1, testptr1, NULL);
  gt_genome_node_add_user_data(gn, testkey2, testptr2, gt_free_func);
  gt_ensure(gn->userdata != NULL);
  gt_genome_node_delete(gn);

  gt_free(gnc);

  return had_err;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r15
testq %rdi, %rdi
je 0x42556
movq %r15, %rdi
callq 0x3566a
testb %al, %al
jne 0x42ad9
leaq 0xa349b(%rip), %rbx     # 0xe59f8
movl $0x4, %edi
movq %rbx, %rsi
movl $0x1e0, %edx            # imm = 0x1E0
callq 0x35ee2
movq %rax, %r12
movl $0x1, %edi
movl $0x40, %esi
movq %rbx, %rdx
movl $0x1e3, %ecx            # imm = 0x1E3
callq 0x3601f
movq %rax, %rbx
movq $0x30, (%rax)
movq %rax, %rdi
callq 0x41e44
movq %rax, %r14
leaq 0xa37da(%rip), %rsi     # 0xe5d7f
movq %rax, %rdi
callq 0x424ae
testq %rax, %rax
je 0x425dc
leaq 0xa0bc0(%rip), %rsi     # 0xe3179
leaq 0xa37e2(%rip), %rdx     # 0xe5da2
leaq 0xa37c2(%rip), %rcx     # 0xe5d89
leaq 0xa342a(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1e7, %r9d            # imm = 0x1E7
jmp 0x42675
leaq 0xa37a1(%rip), %rsi     # 0xe5d84
movq %r14, %rdi
callq 0x424ae
testq %rax, %rax
je 0x42617
leaq 0xa0b82(%rip), %rsi     # 0xe3179
leaq 0xa37d7(%rip), %rdx     # 0xe5dd5
leaq 0xa3784(%rip), %rcx     # 0xe5d89
leaq 0xa33ec(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1e8, %r9d            # imm = 0x1E8
jmp 0x42675
cmpl $0x0, 0x28(%r14)
je 0x42645
leaq 0xa0b54(%rip), %rsi     # 0xe3179
leaq 0xa37dc(%rip), %rdx     # 0xe5e08
leaq 0xa3756(%rip), %rcx     # 0xe5d89
leaq 0xa33be(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1e9, %r9d            # imm = 0x1E9
jmp 0x42675
cmpq $0x0, 0x10(%r14)
je 0x42749
leaq 0xa0b22(%rip), %rsi     # 0xe3179
leaq 0xa37c6(%rip), %rdx     # 0xe5e24
leaq 0xa3724(%rip), %rcx     # 0xe5d89
leaq 0xa338c(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1ea, %r9d            # imm = 0x1EA
xorl %eax, %eax
callq 0x3559f
leaq 0xa36fc(%rip), %rsi     # 0xe5d7f
leaq 0xaec39(%rip), %rdx     # 0xf12c3
movq %r14, %rdi
xorl %ecx, %ecx
callq 0x423bc
leaq 0xa36e9(%rip), %rsi     # 0xe5d84
leaq -0xc343(%rip), %rcx     # 0x3635f
movq %r14, %rdi
movq %r12, %rdx
callq 0x423bc
leaq 0xa36cb(%rip), %rsi     # 0xe5d7f
movq %r14, %rdi
callq 0x424da
leaq 0xa36c1(%rip), %rsi     # 0xe5d84
movq %r14, %rdi
callq 0x424da
leaq 0xa3326(%rip), %rsi     # 0xe59f8
movl $0x4, %edi
movl $0x200, %edx            # imm = 0x200
callq 0x35ee2
movq %rax, %r15
leaq 0xa3694(%rip), %rsi     # 0xe5d7f
leaq 0xaebd1(%rip), %rdx     # 0xf12c3
movq %r14, %rdi
xorl %ecx, %ecx
callq 0x423bc
leaq 0xa3681(%rip), %rsi     # 0xe5d84
leaq -0xc3ab(%rip), %rcx     # 0x3635f
movq %r14, %rdi
movq %r15, %rdx
callq 0x423bc
movl $0xffffffff, %r12d      # imm = 0xFFFFFFFF
movq %r14, %rdi
callq 0x42ade
leaq 0xa32ce(%rip), %rsi     # 0xe59f8
movq %rbx, %rdi
movl $0x206, %edx            # imm = 0x206
callq 0x362a0
movl %r12d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xa362f(%rip), %rbp     # 0xe5d7f
leaq 0xaeb6c(%rip), %r13     # 0xf12c3
movq %r14, %rdi
movq %rbp, %rsi
movq %r13, %rdx
xorl %ecx, %ecx
callq 0x423bc
movq %r14, %rdi
movq %rbp, %rsi
callq 0x424ae
testq %rax, %rax
je 0x427b5
leaq 0xa3601(%rip), %rsi     # 0xe5d7f
movq %r14, %rdi
callq 0x424ae
cmpq %r13, %rax
je 0x427df
leaq 0xa09e7(%rip), %rsi     # 0xe3179
leaq 0xa36d3(%rip), %rdx     # 0xe5e6c
leaq 0xa35e9(%rip), %rcx     # 0xe5d89
leaq 0xa3251(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1ee, %r9d            # imm = 0x1EE
jmp 0x428af
leaq 0xa09bd(%rip), %rsi     # 0xe3179
leaq 0xa3676(%rip), %rdx     # 0xe5e39
leaq 0xa35bf(%rip), %rcx     # 0xe5d89
leaq 0xa3227(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1ed, %r9d            # imm = 0x1ED
jmp 0x428af
cmpl $0x1, 0x28(%r14)
jne 0x42863
cmpq $0x0, 0x10(%r14)
je 0x4288a
leaq 0xa358c(%rip), %r13     # 0xe5d84
leaq -0xc4a0(%rip), %rcx     # 0x3635f
movq %r14, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x423bc
movq %r14, %rdi
movq %r13, %rsi
callq 0x424ae
testq %rax, %rax
je 0x428bb
leaq 0xa355c(%rip), %rsi     # 0xe5d84
movq %r14, %rdi
callq 0x424ae
cmpq %r12, %rax
je 0x428e2
leaq 0xa0939(%rip), %rsi     # 0xe3179
leaq 0xa36ab(%rip), %rdx     # 0xe5ef2
leaq 0xa353b(%rip), %rcx     # 0xe5d89
leaq 0xa31a3(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1f4, %r9d            # imm = 0x1F4
jmp 0x4295a
leaq 0xa090f(%rip), %rsi     # 0xe3179
leaq 0xa3632(%rip), %rdx     # 0xe5ea3
leaq 0xa3511(%rip), %rcx     # 0xe5d89
leaq 0xa3179(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1ef, %r9d            # imm = 0x1EF
jmp 0x428af
leaq 0xa08e8(%rip), %rsi     # 0xe3179
leaq 0xa3494(%rip), %rdx     # 0xe5d2c
leaq 0xa34ea(%rip), %rcx     # 0xe5d89
leaq 0xa3152(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1f0, %r9d            # imm = 0x1F0
xorl %eax, %eax
callq 0x3559f
jmp 0x42694
leaq 0xa08b7(%rip), %rsi     # 0xe3179
leaq 0xa35f6(%rip), %rdx     # 0xe5ebf
leaq 0xa34b9(%rip), %rcx     # 0xe5d89
leaq 0xa3121(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1f3, %r9d            # imm = 0x1F3
jmp 0x4295a
cmpl $0x2, 0x28(%r14)
jne 0x42935
leaq 0xa348f(%rip), %r12     # 0xe5d7f
movq %r14, %rdi
movq %r12, %rsi
callq 0x424da
movq %r14, %rdi
movq %r12, %rsi
callq 0x424ae
testq %rax, %rax
je 0x42966
leaq 0xa0867(%rip), %rsi     # 0xe3179
leaq 0xa3489(%rip), %rdx     # 0xe5da2
leaq 0xa3469(%rip), %rcx     # 0xe5d89
leaq 0xa30d1(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1f8, %r9d            # imm = 0x1F8
jmp 0x429de
leaq 0xa083d(%rip), %rsi     # 0xe3179
leaq 0xa35e6(%rip), %rdx     # 0xe5f29
leaq 0xa343f(%rip), %rcx     # 0xe5d89
leaq 0xa30a7(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1f5, %r9d            # imm = 0x1F5
xorl %eax, %eax
callq 0x3559f
jmp 0x426ad
cmpl $0x1, 0x28(%r14)
jne 0x429b9
leaq 0xa3410(%rip), %r12     # 0xe5d84
movq %r14, %rdi
movq %r12, %rsi
callq 0x424da
movq %r14, %rdi
movq %r12, %rsi
callq 0x424ae
testq %rax, %rax
je 0x429ea
leaq 0xa07e3(%rip), %rsi     # 0xe3179
leaq 0xa3438(%rip), %rdx     # 0xe5dd5
leaq 0xa33e5(%rip), %rcx     # 0xe5d89
leaq 0xa304d(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1fc, %r9d            # imm = 0x1FC
jmp 0x42a44
leaq 0xa07b9(%rip), %rsi     # 0xe3179
leaq 0xa34dc(%rip), %rdx     # 0xe5ea3
leaq 0xa33bb(%rip), %rcx     # 0xe5d89
leaq 0xa3023(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1f9, %r9d            # imm = 0x1F9
xorl %eax, %eax
callq 0x3559f
jmp 0x426bc
cmpl $0x0, 0x28(%r14)
je 0x42a18
leaq 0xa0781(%rip), %rsi     # 0xe3179
leaq 0xa3409(%rip), %rdx     # 0xe5e08
leaq 0xa3383(%rip), %rcx     # 0xe5d89
leaq 0xa2feb(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1fd, %r9d            # imm = 0x1FD
jmp 0x42a44
cmpq $0x0, 0x10(%r14)
je 0x42a50
leaq 0xa0753(%rip), %rsi     # 0xe3179
leaq 0xa33f7(%rip), %rdx     # 0xe5e24
leaq 0xa3355(%rip), %rcx     # 0xe5d89
leaq 0xa2fbd(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x1fe, %r9d            # imm = 0x1FE
xorl %eax, %eax
callq 0x3559f
jmp 0x426cb
leaq 0xa2fa1(%rip), %rsi     # 0xe59f8
movl $0x4, %edi
movl $0x200, %edx            # imm = 0x200
callq 0x35ee2
movq %rax, %r13
leaq 0xa330f(%rip), %rsi     # 0xe5d7f
leaq 0xae84c(%rip), %rdx     # 0xf12c3
xorl %r12d, %r12d
movq %r14, %rdi
xorl %ecx, %ecx
callq 0x423bc
leaq 0xa32f9(%rip), %rsi     # 0xe5d84
leaq -0xc733(%rip), %rcx     # 0x3635f
movq %r14, %rdi
movq %r13, %rdx
callq 0x423bc
cmpq $0x0, 0x10(%r14)
jne 0x4271b
leaq 0xa06ca(%rip), %rsi     # 0xe3179
leaq 0xa3276(%rip), %rdx     # 0xe5d2c
leaq 0xa32cc(%rip), %rcx     # 0xe5d89
leaq 0xa2f34(%rip), %r8      # 0xe59f8
movq %r15, %rdi
movl $0x203, %r9d            # imm = 0x203
xorl %eax, %eax
callq 0x3559f
jmp 0x42715
callq 0x11450