// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/tools/gt_orffinder.c
// Function: gt_orffinder_runner
static int gt_orffinder_runner(int argc, const char **argv,
                               int parsed_args, void *tool_arguments,
                               GtError *err)
{
  GtOrffinderArguments *arguments = tool_arguments;
  GtNodeStream *gff3_in_stream   = NULL,
               *last_stream      = NULL,
               *orffinder_stream = NULL,
               *gff3_out_stream  = NULL;
  int had_err = 0, i = 0, arg = parsed_args;
  GtLogger *logger = gt_logger_new(arguments->verbose,
                                   GT_LOGGER_DEFLT_PREFIX, stderr);
  GtHashmap *types = NULL;
  GtRegionMapping *rmap = NULL;

  gt_error_check(err);
  gt_assert(arguments);

  types = gt_hashmap_new(GT_HASH_STRING, NULL, NULL);

  if (gt_str_array_size(arguments->types) == 0) {
    gt_hashmap_add(types, (void*) "all", (void*) 1);
  } else {
    for (i = 0; i < gt_str_array_size(arguments->types); i++) {
      gt_hashmap_add(types,
                     (void*) gt_str_array_get(arguments->types, i),
                     (void*) 1);
      gt_hashmap_add(types, (void*) "all", (void*) 0);
    }
  }

  /* create region mapping */
  if (gt_seqid2file_option_used(arguments->s2fi)) {
    /* create region mapping */
    rmap = gt_seqid2file_region_mapping_new(arguments->s2fi, err);
    if (!rmap)
      had_err = -1;
  } else {
    GtEncseqLoader *el;
    GtEncseq *encseq;
    /* no new-style sequence source option given, fall back to legacy syntax */
    if (argc < 3) {
      gt_error_set(err, "missing argument(s)");
      had_err = -1;
    }
    if (!had_err) {
      el = gt_encseq_loader_new();
      gt_encseq_loader_disable_autosupport(el);
      gt_encseq_loader_require_md5_support(el);
      gt_encseq_loader_require_description_support(el);
      encseq = gt_encseq_loader_load(el, argv[arg], err);
      arg++;
      gt_encseq_loader_delete(el);
      if (!encseq)
        had_err = -1;
      else {
        rmap = gt_region_mapping_new_encseq_seqno(encseq);
        gt_encseq_delete(encseq);
      }
    }
  }
  gt_assert(had_err || rmap);

  if (!had_err) {
    last_stream = gff3_in_stream  = gt_gff3_in_stream_new_unsorted(argc - arg,
                                                                   argv + arg);
    last_stream = orffinder_stream = gt_orf_finder_stream_new(last_stream,
                                                             rmap,
                                                             types,
                                                             arguments->min,
                                                             arguments->max,
                                                             arguments->allorfs,
                                                             err);
    if (!orffinder_stream)
      had_err = -1;

    if (!had_err)  {
      last_stream = gff3_out_stream = gt_gff3_out_stream_new(last_stream,
                                                             arguments->outfp);

      /* pull the features through the stream and free them afterwards */
      had_err = gt_node_stream_pull(last_stream, err);
    }

    gt_node_stream_delete(orffinder_stream);
    gt_node_stream_delete(gff3_in_stream);
    gt_node_stream_delete(gff3_out_stream);
  }
  gt_hashmap_delete(types);
  types = NULL;
  gt_logger_delete(logger);
  gt_region_mapping_delete(rmap);

  return had_err;
}

// Assembly:
subq $0xa8, %rsp
movl %edi, 0xa4(%rsp)
movq %rsi, 0x98(%rsp)
movl %edx, 0x94(%rsp)
movq %rcx, 0x88(%rsp)
movq %r8, 0x80(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x78(%rsp)
movq $0x0, 0x70(%rsp)
movq $0x0, 0x68(%rsp)
movq $0x0, 0x60(%rsp)
movq $0x0, 0x58(%rsp)
movl $0x0, 0x54(%rsp)
movl $0x0, 0x50(%rsp)
movl 0x94(%rsp), %eax
movl %eax, 0x4c(%rsp)
movq 0x78(%rsp), %rax
movb 0x21(%rax), %al
movq 0x5f45e8(%rip), %rcx    # 0x63bfa0
movq (%rcx), %rdx
leaq 0x4cff2a(%rip), %rsi    # 0x5178ec
andb $0x1, %al
movzbl %al, %edi
callq 0xe7870
movq %rax, 0x40(%rsp)
movq $0x0, 0x38(%rsp)
movq $0x0, 0x30(%rsp)
cmpq $0x0, 0x80(%rsp)
je 0x47a39
movq 0x80(%rsp), %rdi
callq 0xd8a60
testb $0x1, %al
jne 0x47a01
jmp 0x47a39
movq 0x5f4598(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ce601(%rip), %rsi    # 0x516013
leaq 0x4ce7a6(%rip), %rdx    # 0x5161bf
leaq 0x4daa1d(%rip), %rcx    # 0x52243d
leaq 0x4da87b(%rip), %r8     # 0x5222a2
movl $0x9d, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x47a3b
jmp 0x47a3d
cmpq $0x0, 0x78(%rsp)
jne 0x47a7d
movq 0x5f4554(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ce5bd(%rip), %rsi    # 0x516013
leaq 0x533102(%rip), %rdx    # 0x57ab5f
leaq 0x4da9d9(%rip), %rcx    # 0x52243d
leaq 0x4da837(%rip), %r8     # 0x5222a2
movl $0x9e, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x47a7f
movl $0x1, %edi
xorl %eax, %eax
movl %eax, %edx
movq %rdx, %rsi
callq 0xe0c40
movq %rax, 0x38(%rsp)
movq 0x78(%rsp), %rax
movq 0x10(%rax), %rdi
callq 0x11fcc0
cmpq $0x0, %rax
jne 0x47ac4
movq 0x38(%rsp), %rdi
leaq 0x504a88(%rip), %rsi    # 0x54c53d
movl $0x1, %edx
callq 0xe0fc0
jmp 0x47b44
movl $0x0, 0x50(%rsp)
movslq 0x50(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x78(%rsp), %rax
movq 0x10(%rax), %rdi
callq 0x11fcc0
movq %rax, %rcx
movq 0x18(%rsp), %rax
cmpq %rcx, %rax
jae 0x47b42
movq 0x38(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x78(%rsp), %rax
movq 0x10(%rax), %rdi
movslq 0x50(%rsp), %rsi
callq 0x11f8c0
movq 0x10(%rsp), %rdi
movq %rax, %rsi
movl $0x1, %edx
callq 0xe0fc0
movq 0x38(%rsp), %rdi
leaq 0x504a11(%rip), %rsi    # 0x54c53d
xorl %eax, %eax
movl %eax, %edx
callq 0xe0fc0
movl 0x50(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x50(%rsp)
jmp 0x47acc
jmp 0x47b44
movq 0x78(%rsp), %rax
movq 0x28(%rax), %rdi
callq 0x1d48f0
testb $0x1, %al
jne 0x47b58
jmp 0x47b88
movq 0x78(%rsp), %rax
movq 0x28(%rax), %rdi
movq 0x80(%rsp), %rsi
callq 0x1d4960
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x47b83
movl $0xffffffff, 0x54(%rsp) # imm = 0xFFFFFFFF
jmp 0x47c4f
cmpl $0x3, 0xa4(%rsp)
jge 0x47bb0
movq 0x80(%rsp), %rdi
leaq 0x4da8b0(%rip), %rsi    # 0x522451
movb $0x0, %al
callq 0xd88c0
movl $0xffffffff, 0x54(%rsp) # imm = 0xFFFFFFFF
cmpl $0x0, 0x54(%rsp)
jne 0x47c4d
callq 0xb7a40
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rdi
callq 0xba760
movq 0x28(%rsp), %rdi
callq 0xba700
movq 0x28(%rsp), %rdi
callq 0xbacc0
movq 0x28(%rsp), %rdi
movq 0x98(%rsp), %rax
movslq 0x4c(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
movq 0x80(%rsp), %rdx
callq 0xb7aa0
movq %rax, 0x20(%rsp)
movl 0x4c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4c(%rsp)
movq 0x28(%rsp), %rdi
callq 0xb7e50
cmpq $0x0, 0x20(%rsp)
jne 0x47c32
movl $0xffffffff, 0x54(%rsp) # imm = 0xFFFFFFFF
jmp 0x47c4b
movq 0x20(%rsp), %rdi
callq 0x1c7ea0
movq %rax, 0x30(%rsp)
movq 0x20(%rsp), %rdi
callq 0xae070
jmp 0x47c4d
jmp 0x47c4f
jmp 0x47c51
cmpl $0x0, 0x54(%rsp)
jne 0x47c98
cmpq $0x0, 0x30(%rsp)
jne 0x47c98
movq 0x5f4339(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ce3a2(%rip), %rsi    # 0x516013
leaq 0x4da7ed(%rip), %rdx    # 0x522465
leaq 0x4da7be(%rip), %rcx    # 0x52243d
leaq 0x4da61c(%rip), %r8     # 0x5222a2
movl $0xcb, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x47c9a
cmpl $0x0, 0x54(%rsp)
jne 0x47d86
movl 0xa4(%rsp), %edi
subl 0x4c(%rsp), %edi
movq 0x98(%rsp), %rsi
movslq 0x4c(%rsp), %rax
shlq $0x3, %rax
addq %rax, %rsi
callq 0x1746b0
movq %rax, 0x70(%rsp)
movq %rax, 0x68(%rsp)
movq 0x68(%rsp), %rdi
movq 0x30(%rsp), %rsi
movq 0x38(%rsp), %rdx
movq 0x78(%rsp), %rax
movl 0x8(%rax), %ecx
movq 0x78(%rsp), %rax
movl 0xc(%rax), %r8d
movq 0x78(%rsp), %rax
movb 0x20(%rax), %r9b
movq 0x80(%rsp), %rax
andb $0x1, %r9b
movzbl %r9b, %r9d
movq %rax, (%rsp)
callq 0x1b2bf0
movq %rax, 0x60(%rsp)
movq %rax, 0x68(%rsp)
cmpq $0x0, 0x60(%rsp)
jne 0x47d2f
movl $0xffffffff, 0x54(%rsp) # imm = 0xFFFFFFFF
cmpl $0x0, 0x54(%rsp)
jne 0x47d68
movq 0x68(%rsp), %rdi
movq 0x78(%rsp), %rax
movq (%rax), %rsi
callq 0x176d50
movq %rax, 0x58(%rsp)
movq %rax, 0x68(%rsp)
movq 0x68(%rsp), %rdi
movq 0x80(%rsp), %rsi
callq 0x1b1f90
movl %eax, 0x54(%rsp)
movq 0x60(%rsp), %rdi
callq 0x1b1cb0
movq 0x70(%rsp), %rdi
callq 0x1b1cb0
movq 0x58(%rsp), %rdi
callq 0x1b1cb0
movq 0x38(%rsp), %rdi
callq 0xe1770
movq $0x0, 0x38(%rsp)
movq 0x40(%rsp), %rdi
callq 0xe7ed0
movq 0x30(%rsp), %rdi
callq 0x1c7bd0
movl 0x54(%rsp), %eax
addq $0xa8, %rsp
retq
nopl (%rax)