// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/tools/gt_snpper.c
// Function: gt_snpper_runner
static int gt_snpper_runner(GT_UNUSED int argc, const char **argv,
                                 int parsed_args, void *tool_arguments,
                                 GtError *err)
{
  GtNodeStream *gff3_in_stream = NULL,
               *gvf_in_stream = NULL,
               *gvf_out_stream = NULL,
               *snp_annotator_stream = NULL;
  GtSnpperArguments *arguments = tool_arguments;
  GtRegionMapping *region_mapping = NULL;
  GtTransTable *tt = NULL;
  int had_err = 0;

  gt_error_check(err);
  gt_assert(arguments);

  if (!(tt = gt_trans_table_new(arguments->ttable, err)))
    had_err = -1;

  if (!had_err) {
    /* create GFF3 input stream */
    gff3_in_stream = gt_gff3_in_stream_new_sorted(argv[parsed_args]);
    if (!gff3_in_stream)
      had_err = -1;
  }

  if (!had_err) {
    /* create GVF input stream */
    gvf_in_stream = gt_gff3_in_stream_new_sorted(argv[parsed_args+1]);
    if (!gvf_in_stream)
      had_err = -1;
  }

  if (!had_err) {
    /* create region mapping */
    region_mapping = gt_seqid2file_region_mapping_new(arguments->s2fi, err);
    if (!region_mapping)
      had_err = -1;
  }

  if (!had_err) {
    gt_assert(tt);
    snp_annotator_stream = gt_snp_annotator_stream_new(gvf_in_stream,
                                                       gff3_in_stream,
                                                       tt,
                                                       region_mapping);
    if (!snp_annotator_stream)
      had_err = -1;
  }

  if (!had_err) {
    gvf_out_stream = gt_gff3_out_stream_new(snp_annotator_stream,
                                            arguments->outfp);
    if (!gvf_out_stream)
      had_err = -1;
  }

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

  /* free */
  gt_node_stream_delete(snp_annotator_stream);
  gt_node_stream_delete(gff3_in_stream);
  gt_node_stream_delete(gvf_in_stream);
  gt_node_stream_delete(gvf_out_stream);
  gt_trans_table_delete(tt);
  gt_region_mapping_delete(region_mapping);

  return had_err;
}

// Assembly:
subq $0x68, %rsp
movl %edi, 0x64(%rsp)
movq %rsi, 0x58(%rsp)
movl %edx, 0x54(%rsp)
movq %rcx, 0x48(%rsp)
movq %r8, 0x40(%rsp)
movq $0x0, 0x38(%rsp)
movq $0x0, 0x30(%rsp)
movq $0x0, 0x28(%rsp)
movq $0x0, 0x20(%rsp)
movq 0x48(%rsp), %rax
movq %rax, 0x18(%rsp)
movq $0x0, 0x10(%rsp)
movq $0x0, 0x8(%rsp)
movl $0x0, 0x4(%rsp)
cmpq $0x0, 0x40(%rsp)
je 0x71403
movq 0x40(%rsp), %rdi
callq 0xd8a60
testb $0x1, %al
jne 0x713cb
jmp 0x71403
movq 0x5cabce(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4a4c37(%rip), %rsi    # 0x516013
leaq 0x4a4ddc(%rip), %rdx    # 0x5161bf
leaq 0x4bae32(%rip), %rcx    # 0x52c21c
leaq 0x4bad4e(%rip), %r8     # 0x52c13f
movl $0x6f, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x71405
jmp 0x71407
cmpq $0x0, 0x18(%rsp)
jne 0x71447
movq 0x5cab8a(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4a4bf3(%rip), %rsi    # 0x516013
leaq 0x509738(%rip), %rdx    # 0x57ab5f
leaq 0x4badee(%rip), %rcx    # 0x52c21c
leaq 0x4bad0a(%rip), %r8     # 0x52c13f
movl $0x70, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x71449
movq 0x18(%rsp), %rax
movl 0x18(%rax), %edi
movq 0x40(%rsp), %rsi
callq 0x123ef0
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
jne 0x7146e
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
cmpl $0x0, 0x4(%rsp)
jne 0x7149f
movq 0x58(%rsp), %rax
movslq 0x54(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x1747b0
movq %rax, 0x38(%rsp)
cmpq $0x0, 0x38(%rsp)
jne 0x7149d
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
jmp 0x7149f
cmpl $0x0, 0x4(%rsp)
jne 0x714d5
movq 0x58(%rsp), %rax
movl 0x54(%rsp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rdi
callq 0x1747b0
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x714d3
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
jmp 0x714d5
cmpl $0x0, 0x4(%rsp)
jne 0x71505
movq 0x18(%rsp), %rax
movq (%rax), %rdi
movq 0x40(%rsp), %rsi
callq 0x1d4960
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0x71503
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
jmp 0x71505
cmpl $0x0, 0x4(%rsp)
jne 0x71580
jmp 0x7150e
cmpq $0x0, 0x8(%rsp)
jne 0x7154e
movq 0x5caa83(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4a4aec(%rip), %rsi    # 0x516013
leaq 0x4d45c0(%rip), %rdx    # 0x545aee
leaq 0x4bace7(%rip), %rcx    # 0x52c21c
leaq 0x4bac03(%rip), %r8     # 0x52c13f
movl $0x8b, %r9d
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x71550
movq 0x30(%rsp), %rdi
movq 0x38(%rsp), %rsi
movq 0x8(%rsp), %rdx
movq 0x10(%rsp), %rcx
callq 0x1d8750
movq %rax, 0x20(%rsp)
cmpq $0x0, 0x20(%rsp)
jne 0x7157e
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
jmp 0x71580
cmpl $0x0, 0x4(%rsp)
jne 0x715b1
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rax
movq 0x10(%rax), %rsi
callq 0x176d50
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
jne 0x715af
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
jmp 0x715b1
cmpl $0x0, 0x4(%rsp)
jne 0x715cb
movq 0x28(%rsp), %rdi
movq 0x40(%rsp), %rsi
callq 0x1b1f90
movl %eax, 0x4(%rsp)
movq 0x20(%rsp), %rdi
callq 0x1b1cb0
movq 0x38(%rsp), %rdi
callq 0x1b1cb0
movq 0x30(%rsp), %rdi
callq 0x1b1cb0
movq 0x28(%rsp), %rdi
callq 0x1b1cb0
movq 0x8(%rsp), %rdi
callq 0x1246a0
movq 0x10(%rsp), %rdi
callq 0x1c7bd0
movl 0x4(%rsp), %eax
addq $0x68, %rsp
retq