// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/tools/gt_condenseq_hmmsearch.c
// Function: gt_condenseq_hmmsearch_runner
static int gt_condenseq_hmmsearch_runner(GT_UNUSED int argc,
                                         GT_UNUSED const char **argv,
                                         GT_UNUSED int parsed_args,
                                         void *tool_arguments,
                                         GtError *err)
{
  GtCondenseqHmmsearchArguments *arguments = tool_arguments;
  GtCondenseq *ces = NULL;
  GtStr *table_filename = NULL;
  GtLogger *logger = NULL;
  GtTimer *timer = NULL;
  int had_err = 0;

  logger = gt_logger_new(gt_condenseq_search_arguments_verbose(arguments->csa),
                         GT_LOGGER_DEFLT_PREFIX, stderr);
  if (gt_showtime_enabled()) {
    timer = gt_timer_new_with_progress_description("initialization");
    gt_timer_start(timer);
  }

  gt_error_check(err);
  gt_assert(arguments);

  if (gt_str_length(arguments->outtable_filename) != 0) {
    table_filename = gt_str_clone(arguments->outtable_filename);
    gt_str_append_cstr(table_filename, "tabout.tsv");
  }
  else {
    table_filename = gt_condenseq_search_arguments_db_filename(arguments->csa,
                                                               "_tabout.tsv");
  }
  if (!had_err) {
    struct stat buf;
    if (stat(gt_str_get(table_filename), &buf) == 0 && !arguments->force_ow) {
      gt_error_set(err, "file %s already exists, use option -force_ow to "
                   "overwrite or delete", gt_str_get(table_filename));
      had_err = -1;
    }
  }

  if (timer != NULL)
    gt_timer_show_progress(timer, "read condenseq", stderr);
  if (!had_err) {
    ces = gt_condenseq_search_arguments_read_condenseq(arguments->csa,
                                                       logger, err);
    if (ces == NULL)
      had_err = -1;
  }
  if (!had_err) {
    had_err =
      hmmsearch_call_coarse_search(ces,
                                   gt_str_get(arguments->hmmsearch_path),
                                   gt_str_get(table_filename),
                                   gt_str_get(arguments->hmm),
                                   arguments->hmm_num_threads,
                                   timer, logger, err);
  }
  if (!had_err) {
    had_err = hmmsearch_process_coarse_hits(gt_str_get(table_filename),
                                            ces, arguments,
                                            timer, logger, err);
  }

  if (timer != NULL)
    gt_timer_show_progress(timer, "cleanup", stderr);
  gt_condenseq_delete(ces);
  gt_logger_delete(logger);
  gt_str_delete(table_filename);

  if (timer != NULL)
    gt_timer_show_progress_final(timer, stderr);
  gt_timer_delete(timer);
  return had_err;
}

// Assembly:
subq $0x118, %rsp            # imm = 0x118
movl %edi, 0x114(%rsp)
movq %rsi, 0x108(%rsp)
movl %edx, 0x104(%rsp)
movq %rcx, 0xf8(%rsp)
movq %r8, 0xf0(%rsp)
movq 0xf8(%rsp), %rax
movq %rax, 0xe8(%rsp)
movq $0x0, 0xe0(%rsp)
movq $0x0, 0xd8(%rsp)
movq $0x0, 0xd0(%rsp)
movq $0x0, 0xc8(%rsp)
movl $0x0, 0xc4(%rsp)
movq 0xe8(%rsp), %rax
movq (%rax), %rdi
callq 0x148ad0
movq 0x614141(%rip), %rcx    # 0x63bfa0
movq (%rcx), %rdx
movzbl %al, %edi
andl $0x1, %edi
leaq 0x4efa7d(%rip), %rsi    # 0x5178ec
callq 0xe7870
movq %rax, 0xd0(%rsp)
callq 0x11aa90
testb $0x1, %al
jne 0x27e87
jmp 0x27ea8
leaq 0x501368(%rip), %rdi    # 0x5291f6
callq 0x1213a0
movq %rax, 0xc8(%rsp)
movq 0xc8(%rsp), %rdi
callq 0x1213f0
jmp 0x27eaa
cmpq $0x0, 0xf0(%rsp)
je 0x27f00
movq 0xf0(%rsp), %rdi
callq 0xd8a60
testb $0x1, %al
jne 0x27ec8
jmp 0x27f00
movq 0x6140d1(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ee13a(%rip), %rsi    # 0x516013
leaq 0x4ee2df(%rip), %rdx    # 0x5161bf
leaq 0x4f272e(%rip), %rcx    # 0x51a615
leaq 0x4f241c(%rip), %r8     # 0x51a30a
movl $0x1ff, %r9d            # imm = 0x1FF
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x27f02
jmp 0x27f04
cmpq $0x0, 0xe8(%rsp)
jne 0x27f47
movq 0x61408a(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x4ee0f3(%rip), %rsi    # 0x516013
leaq 0x552c38(%rip), %rdx    # 0x57ab5f
leaq 0x4f26e7(%rip), %rcx    # 0x51a615
leaq 0x4f23d5(%rip), %r8     # 0x51a30a
movl $0x200, %r9d            # imm = 0x200
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x27f49
movq 0xe8(%rsp), %rax
movq 0x18(%rax), %rdi
callq 0x11dfa0
cmpq $0x0, %rax
je 0x27f8f
movq 0xe8(%rsp), %rax
movq 0x18(%rax), %rdi
callq 0x11e280
movq %rax, 0xd8(%rsp)
movq 0xd8(%rsp), %rdi
leaq 0x4f26ac(%rip), %rsi    # 0x51a634
callq 0x11d550
jmp 0x27fae
movq 0xe8(%rsp), %rax
movq (%rax), %rdi
leaq 0x4f2692(%rip), %rsi    # 0x51a633
callq 0x148b60
movq %rax, 0xd8(%rsp)
cmpl $0x0, 0xc4(%rsp)
jne 0x28022
movq 0xd8(%rsp), %rdi
callq 0x11dee0
movq %rax, %rdi
leaq 0x30(%rsp), %rsi
callq 0x19f08
cmpl $0x0, %eax
jne 0x28020
movq 0xe8(%rsp), %rax
testb $0x1, 0x28(%rax)
jne 0x28020
movq 0xf0(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0xd8(%rsp), %rdi
callq 0x11dee0
movq 0x28(%rsp), %rdi
movq %rax, %rdx
leaq 0x4f2631(%rip), %rsi    # 0x51a63f
movb $0x0, %al
callq 0xd88c0
movl $0xffffffff, 0xc4(%rsp) # imm = 0xFFFFFFFF
jmp 0x28022
cmpq $0x0, 0xc8(%rsp)
je 0x2804b
movq 0xc8(%rsp), %rdi
movq 0x613f64(%rip), %rax    # 0x63bfa0
movq (%rax), %rdx
leaq 0x4f263d(%rip), %rsi    # 0x51a683
callq 0x121930
cmpl $0x0, 0xc4(%rsp)
jne 0x28095
movq 0xe8(%rsp), %rax
movq (%rax), %rdi
movq 0xd0(%rsp), %rsi
movq 0xf0(%rsp), %rdx
callq 0x148a90
movq %rax, 0xe0(%rsp)
cmpq $0x0, 0xe0(%rsp)
jne 0x28093
movl $0xffffffff, 0xc4(%rsp) # imm = 0xFFFFFFFF
jmp 0x28095
cmpl $0x0, 0xc4(%rsp)
jne 0x28134
movq 0xe0(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0xe8(%rsp), %rax
movq 0x10(%rax), %rdi
callq 0x11dee0
movq %rax, 0x18(%rsp)
movq 0xd8(%rsp), %rdi
callq 0x11dee0
movq %rax, 0x20(%rsp)
movq 0xe8(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x11dee0
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
movq 0x20(%rsp), %rdx
movq %rax, %rcx
movq 0xe8(%rsp), %rax
movl 0x24(%rax), %r8d
movq 0xc8(%rsp), %r9
movq 0xd0(%rsp), %r10
movq 0xf0(%rsp), %rax
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x28210
movl %eax, 0xc4(%rsp)
cmpl $0x0, 0xc4(%rsp)
jne 0x28182
movq 0xd8(%rsp), %rdi
callq 0x11dee0
movq %rax, %rdi
movq 0xe0(%rsp), %rsi
movq 0xe8(%rsp), %rdx
movq 0xc8(%rsp), %rcx
movq 0xd0(%rsp), %r8
movq 0xf0(%rsp), %r9
callq 0x28570
movl %eax, 0xc4(%rsp)
cmpq $0x0, 0xc8(%rsp)
je 0x281ab
movq 0xc8(%rsp), %rdi
movq 0x613e04(%rip), %rax    # 0x63bfa0
movq (%rax), %rdx
leaq 0x4f215c(%rip), %rsi    # 0x51a302
callq 0x121930
movq 0xe0(%rsp), %rdi
callq 0x13f640
movq 0xd0(%rsp), %rdi
callq 0xe7ed0
movq 0xd8(%rsp), %rdi
callq 0x11f560
cmpq $0x0, 0xc8(%rsp)
je 0x281f4
movq 0xc8(%rsp), %rdi
movq 0x613db4(%rip), %rax    # 0x63bfa0
movq (%rax), %rsi
callq 0x121d70
movq 0xc8(%rsp), %rdi
callq 0x121f00
movl 0xc4(%rsp), %eax
addq $0x118, %rsp            # imm = 0x118
retq