// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/ltr/ltr_input_check_visitor.c
// Function: gt_ltr_input_check_visitor_feature_node
static int gt_ltr_input_check_visitor_feature_node(GtNodeVisitor *nv,
                                                   GtFeatureNode *fn,
                                                   GtError *err)
{
  GT_UNUSED GtLTRInputCheckVisitor *lv;
  GtFeatureNodeIterator *fni;
  bool seen_left = false;
  GtFeatureNode *curnode = NULL,
                *ltr_retrotrans = NULL,
                *lltr = NULL,
                *rltr = NULL;
  int had_err = 0;
  lv = gt_ltr_input_check_visitor_cast(nv);
  gt_assert(lv);
  gt_error_check(err);

  /* traverse annotation subgraph and find LTR components */
  fni = gt_feature_node_iterator_new(fn);
  while (!had_err && (curnode = gt_feature_node_iterator_next(fni))) {
    if (strcmp(gt_feature_node_get_type(curnode),
               gt_ft_LTR_retrotransposon) == 0) {
      ltr_retrotrans = curnode;
    }
    if (strcmp(gt_feature_node_get_type(curnode),
               gt_ft_long_terminal_repeat) == 0) {
      if (seen_left)
        rltr = curnode;
      else {
        lltr = curnode;
        seen_left = true;
      }
    }
  }
  gt_feature_node_iterator_delete(fni);

  if (lv->only_ltrs) {
    if (!had_err && !ltr_retrotrans) {
      gt_error_set(err, "connected component with %s entry node (%s, line %u) "
                        "does not contain a '%s' node, which is required",
                   gt_feature_node_get_type(fn),
                   gt_genome_node_get_filename((GtGenomeNode*) fn),
                   gt_genome_node_get_line_number((GtGenomeNode*) fn),
                   gt_ft_LTR_retrotransposon);
      had_err = -1;
    }
  }

  if (!had_err && ltr_retrotrans && (!lltr || !rltr)) {
    gt_error_set(err, "LTR_retrotransposon feature (%s, line %u) "
                      "does not contain two %s child features, both of which "
                      "are required",
                 gt_genome_node_get_filename((GtGenomeNode*) ltr_retrotrans),
                 gt_genome_node_get_line_number((GtGenomeNode*) ltr_retrotrans),
                 gt_ft_long_terminal_repeat);
    had_err = -1;
  }

  return had_err;
}

// Assembly:
subq $0x88, %rsp
movq %rdi, 0x80(%rsp)
movq %rsi, 0x78(%rsp)
movq %rdx, 0x70(%rsp)
movb $0x0, 0x5f(%rsp)
movq $0x0, 0x50(%rsp)
movq $0x0, 0x48(%rsp)
movq $0x0, 0x40(%rsp)
movq $0x0, 0x38(%rsp)
movl $0x0, 0x34(%rsp)
callq 0x3009b0
movq %rax, %rdi
movq 0x80(%rsp), %rsi
callq 0x1b2350
movq %rax, 0x68(%rsp)
cmpq $0x0, 0x68(%rsp)
jne 0x300aa4
movq 0x33b52d(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x215596(%rip), %rsi    # 0x516013
leaq 0x2925fe(%rip), %rdx    # 0x593082
leaq 0x291da9(%rip), %rcx    # 0x592834
leaq 0x291d61(%rip), %r8     # 0x5927f3
movl $0x36, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x300aa6
jmp 0x300aa8
cmpq $0x0, 0x70(%rsp)
je 0x300af8
movq 0x70(%rsp), %rdi
callq 0xd8a60
testb $0x1, %al
jne 0x300ac0
jmp 0x300af8
movq 0x33b4d9(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x215542(%rip), %rsi    # 0x516013
leaq 0x2156e7(%rip), %rdx    # 0x5161bf
leaq 0x291d55(%rip), %rcx    # 0x592834
leaq 0x291d0d(%rip), %r8     # 0x5927f3
movl $0x37, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x300afa
movq 0x78(%rsp), %rdi
callq 0x170b00
movq %rax, 0x60(%rsp)
xorl %eax, %eax
cmpl $0x0, 0x34(%rsp)
movb %al, 0x33(%rsp)
jne 0x300b30
movq 0x60(%rsp), %rdi
callq 0x170e30
movq %rax, 0x50(%rsp)
cmpq $0x0, %rax
setne %al
movb %al, 0x33(%rsp)
movb 0x33(%rsp), %al
testb $0x1, %al
jne 0x300b3a
jmp 0x300ba9
movq 0x50(%rsp), %rdi
callq 0x16d430
movq %rax, %rdi
leaq 0x2669ee(%rip), %rsi    # 0x56753c
callq 0x19980
cmpl $0x0, %eax
jne 0x300b62
movq 0x50(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x50(%rsp), %rdi
callq 0x16d430
movq %rax, %rdi
leaq 0x269340(%rip), %rsi    # 0x569eb6
callq 0x19980
cmpl $0x0, %eax
jne 0x300ba4
testb $0x1, 0x5f(%rsp)
je 0x300b93
movq 0x50(%rsp), %rax
movq %rax, 0x38(%rsp)
jmp 0x300ba2
movq 0x50(%rsp), %rax
movq %rax, 0x40(%rsp)
movb $0x1, 0x5f(%rsp)
jmp 0x300ba4
jmp 0x300b09
movq 0x60(%rsp), %rdi
callq 0x170f50
movq 0x68(%rsp), %rax
testb $0x1, 0x10(%rax)
je 0x300c30
cmpl $0x0, 0x34(%rsp)
jne 0x300c2e
cmpq $0x0, 0x48(%rsp)
jne 0x300c2e
movq 0x70(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x78(%rsp), %rdi
callq 0x16d430
movq %rax, 0x20(%rsp)
movq 0x78(%rsp), %rdi
callq 0x171a90
movq %rax, 0x28(%rsp)
movq 0x78(%rsp), %rdi
callq 0x171b20
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rdx
movq 0x28(%rsp), %rcx
movl %eax, %r8d
leaq 0x291c44(%rip), %rsi    # 0x59285c
leaq 0x26691d(%rip), %r9     # 0x56753c
movb $0x0, %al
callq 0xd88c0
movl $0xffffffff, 0x34(%rsp) # imm = 0xFFFFFFFF
jmp 0x300c30
cmpl $0x0, 0x34(%rsp)
jne 0x300c9b
cmpq $0x0, 0x48(%rsp)
je 0x300c9b
cmpq $0x0, 0x40(%rsp)
je 0x300c4f
cmpq $0x0, 0x38(%rsp)
jne 0x300c9b
movq 0x70(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x48(%rsp), %rdi
callq 0x171a90
movq %rax, 0x10(%rsp)
movq 0x48(%rsp), %rdi
callq 0x171b20
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rdx
movl %eax, %ecx
leaq 0x291c3c(%rip), %rsi    # 0x5928c1
leaq 0x26922a(%rip), %r8     # 0x569eb6
movb $0x0, %al
callq 0xd88c0
movl $0xffffffff, 0x34(%rsp) # imm = 0xFFFFFFFF
movl 0x34(%rsp), %eax
addq $0x88, %rsp
retq
nopw (%rax,%rax)