// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/extended/stream_evaluator.c
// Function: determine_true_exon
static void determine_true_exon(GtFeatureNode *fn, GtStrand predicted_strand,
                                bool exondiff, bool exondiffcollapsed,
                                GtRange *predicted_range,
                                GtArray *exons_forward,
                                GtArray *exons_reverse,
                                GtArray *true_exons_forward,
                                GtArray *true_exons_reverse,
                                GtBittab *true_exons_forward_collapsed,
                                GtBittab *true_exons_reverse_collapsed,
                                GtEvaluator *exon_evaluator,
                                GtEvaluator *exon_evaluator_collapsed)
{
  GtRange *actual_range;
  GtUword num, *ctr_ptr;

  if ((actual_range = bsearch(predicted_range,
                              predicted_strand == GT_STRAND_FORWARD
                              ? gt_array_get_space(exons_forward)
                              : gt_array_get_space(exons_reverse),
                              predicted_strand == GT_STRAND_FORWARD
                              ? gt_array_size(exons_forward)
                              : gt_array_size(exons_reverse), sizeof (GtRange),
                              (GtCompare) gt_range_compare))) {
    if (predicted_strand == GT_STRAND_FORWARD) {
      num = actual_range - (GtRange*) gt_array_get_space(exons_forward);
      ctr_ptr = gt_array_get(true_exons_forward, num);
      if (*ctr_ptr) {
        (*ctr_ptr)--;
        gt_evaluator_add_true(exon_evaluator);
      }
      else
        mark_and_show_false_exon(fn, exondiff);
      if (true_exons_forward_collapsed &&
          !gt_bittab_bit_is_set(true_exons_forward_collapsed, num)) {
        gt_bittab_set_bit(true_exons_forward_collapsed, num);
        gt_evaluator_add_true(exon_evaluator_collapsed);
      }
    }
    else {
      num = actual_range - (GtRange*) gt_array_get_space(exons_reverse);
      ctr_ptr = gt_array_get(true_exons_reverse, num);
      if (*ctr_ptr) {
        (*ctr_ptr)--;
        gt_evaluator_add_true(exon_evaluator);
      }
      else
        mark_and_show_false_exon(fn, exondiff);
      if (true_exons_reverse_collapsed &&
          !gt_bittab_bit_is_set(true_exons_reverse_collapsed, num)) {
        gt_bittab_set_bit(true_exons_reverse_collapsed, num);
        gt_evaluator_add_true(exon_evaluator_collapsed);
      }
    }
  }
  else {
    mark_and_show_false_exon(fn, exondiff);
    if (exondiffcollapsed) {
      gt_gff3_output_leading(fn, NULL);
      printf(".\n");
    }
  }
}

// Assembly:
subq $0x68, %rsp
movb %cl, %al
movb %dl, %cl
movq 0xa0(%rsp), %rdx
movq 0x98(%rsp), %rdx
movq 0x90(%rsp), %rdx
movq 0x88(%rsp), %rdx
movq 0x80(%rsp), %rdx
movq 0x78(%rsp), %rdx
movq 0x70(%rsp), %rdx
movq %rdi, 0x60(%rsp)
movl %esi, 0x5c(%rsp)
andb $0x1, %cl
movb %cl, 0x5b(%rsp)
andb $0x1, %al
movb %al, 0x5a(%rsp)
movq %r8, 0x50(%rsp)
movq %r9, 0x48(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x28(%rsp)
cmpl $0x0, 0x5c(%rsp)
jne 0xf195c
movq 0x48(%rsp), %rdi
callq 0x761a0
movq %rax, 0x20(%rsp)
jmp 0xf196b
movq 0x70(%rsp), %rdi
callq 0x761a0
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x18(%rsp)
cmpl $0x0, 0x5c(%rsp)
jne 0xf198d
movq 0x48(%rsp), %rdi
callq 0x76490
movq %rax, 0x10(%rsp)
jmp 0xf199c
movq 0x70(%rsp), %rdi
callq 0x76490
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rsi
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rdx
movl $0x10, %ecx
leaq -0x5e167(%rip), %r8     # 0x93850
callq 0xb7b0
movq %rax, 0x40(%rsp)
cmpq $0x0, %rax
je 0xf1b50
cmpl $0x0, 0x5c(%rsp)
jne 0xf1a93
movq 0x40(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x48(%rsp), %rdi
callq 0x761a0
movq %rax, %rcx
movq 0x8(%rsp), %rax
subq %rcx, %rax
sarq $0x4, %rax
movq %rax, 0x38(%rsp)
movq 0x78(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x75c80
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
cmpq $0x0, (%rax)
je 0xf1a3b
movq 0x30(%rsp), %rax
movq (%rax), %rcx
addq $-0x1, %rcx
movq %rcx, (%rax)
movq 0x98(%rsp), %rdi
callq 0x150880
jmp 0xf1a4e
movq 0x60(%rsp), %rdi
movb 0x5b(%rsp), %al
andb $0x1, %al
movzbl %al, %esi
callq 0xf1b90
cmpq $0x0, 0x88(%rsp)
je 0xf1a8e
movq 0x88(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x79c60
testb $0x1, %al
jne 0xf1a8e
movq 0x88(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x78fe0
movq 0xa0(%rsp), %rdi
callq 0x150880
jmp 0xf1b4e
movq 0x40(%rsp), %rax
movq %rax, (%rsp)
movq 0x70(%rsp), %rdi
callq 0x761a0
movq %rax, %rcx
movq (%rsp), %rax
subq %rcx, %rax
sarq $0x4, %rax
movq %rax, 0x38(%rsp)
movq 0x80(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x75c80
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
cmpq $0x0, (%rax)
je 0xf1af9
movq 0x30(%rsp), %rax
movq (%rax), %rcx
addq $-0x1, %rcx
movq %rcx, (%rax)
movq 0x98(%rsp), %rdi
callq 0x150880
jmp 0xf1b0c
movq 0x60(%rsp), %rdi
movb 0x5b(%rsp), %al
andb $0x1, %al
movzbl %al, %esi
callq 0xf1b90
cmpq $0x0, 0x90(%rsp)
je 0xf1b4c
movq 0x90(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x79c60
testb $0x1, %al
jne 0xf1b4c
movq 0x90(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x78fe0
movq 0xa0(%rsp), %rdi
callq 0x150880
jmp 0xf1b4e
jmp 0xf1b88
movq 0x60(%rsp), %rdi
movb 0x5b(%rsp), %al
andb $0x1, %al
movzbl %al, %esi
callq 0xf1b90
testb $0x1, 0x5a(%rsp)
je 0xf1b86
movq 0x60(%rsp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xa7b50
leaq 0x7cfc9(%rip), %rdi     # 0x16eb48
movb $0x0, %al
callq 0xb070
jmp 0xf1b88
addq $0x68, %rsp
retq
nopl (%rax)