// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/tools/gt_compreads_refdecompress.c
// Function: gt_compreads_refdecompress_runner
static int gt_compreads_refdecompress_runner(GT_UNUSED int argc,
                                    GT_UNUSED const char **argv,
                                    GT_UNUSED int parsed_args,
                                    void *tool_arguments, GtError *err)
{
  GtCsrRcrDecodeArguments *arguments = tool_arguments;
  int had_err = 0;
  GtRcrDecoder *rcrd = NULL;
  GtTimer *timer = NULL;
  GtEncseq *encseq = NULL;
  GtEncseqLoader *el = NULL;

  gt_error_check(err);
  gt_assert(arguments);

  if (gt_showtime_enabled()) {
    timer = gt_timer_new_with_progress_description("start");
    gt_timer_start(timer);
    gt_assert(timer);
  }

  if (gt_str_length(arguments->name) == 0) {
    char *basename = gt_basename(gt_str_get(arguments->file));
    gt_str_set(arguments->name, basename);
    gt_free(basename);
  }
  if (timer != NULL)
    gt_timer_show_progress(timer, "load encseq", stdout);
  el = gt_encseq_loader_new();
  gt_encseq_loader_enable_autosupport(el);
  gt_encseq_loader_require_description_support(el);
  encseq = gt_encseq_loader_load(el, gt_str_get(arguments->ref), err);
  gt_encseq_loader_delete(el);
  if (!encseq) {
    gt_error_set(err, "Could not load GtEncseq %s", gt_str_get(arguments->ref));
    had_err = -1;
  }

  if (!had_err) {
    if (!gt_alphabet_is_dna(gt_encseq_alphabet(encseq))) {
      gt_error_set(err, "Alphabet in %s has to be DNA",
                   gt_str_get(arguments->ref));
      had_err = -1;
    }
  }

  if (!had_err) {
    rcrd = gt_rcr_decoder_new(gt_str_get(arguments->file), encseq, timer,
                              err);
    if (rcrd == NULL)
      had_err = -1;
  }
  if (!had_err &&
      arguments->qnames)
    had_err = gt_rcr_decoder_enable_description_support(rcrd, err);
  if (!had_err)
    had_err = gt_rcr_decoder_decode(rcrd,
                                    gt_str_get(arguments->name), timer, err);
  if (timer != NULL) {
    gt_timer_show_progress_final(timer, stdout);
    gt_timer_delete(timer);
  }
  gt_rcr_decoder_delete(rcrd);
  gt_encseq_delete(encseq);
  return had_err;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r8, %rbx
movq %rcx, %r14
testq %r8, %r8
je 0x9e446
movq %rbx, %rdi
callq 0x101a9a
testb %al, %al
jne 0x9e60a
testq %r14, %r14
je 0x9e605
callq 0x11ed94
testb %al, %al
je 0x9e479
leaq 0x30d292(%rip), %rdi    # 0x3ab6f1
callq 0x1226d6
movq %rax, %r15
movq %rax, %rdi
callq 0x122733
testq %r15, %r15
jne 0x9e47c
callq 0x18c06
xorl %r15d, %r15d
movq 0x10(%r14), %rdi
callq 0x120d4c
testq %rax, %rax
jne 0x9e4bd
movq (%r14), %rdi
callq 0x120d23
movq %rax, %rdi
callq 0xd6450
movq %rax, %r12
movq 0x10(%r14), %rdi
movq %rax, %rsi
callq 0x1209e4
leaq 0x2b229e(%rip), %rsi    # 0x35074e
movq %r12, %rdi
movl $0x80, %edx
callq 0x109670
testq %r15, %r15
je 0x9e4db
movq 0x425a1f(%rip), %rax    # 0x4c3ee8
movq (%rax), %rdx
leaq 0x2b23c8(%rip), %rsi    # 0x35089b
movq %r15, %rdi
callq 0x1229c8
callq 0xf36ef
movq %rax, %r13
movq %rax, %rdi
callq 0xf6932
movq %r13, %rdi
callq 0xf6ac6
movq 0x8(%r14), %rdi
callq 0x120d23
movq %r13, %rdi
movq %rax, %rsi
movq %rbx, %rdx
callq 0xf374b
movq %rax, %r12
movq %r13, %rdi
callq 0xf424d
testq %r12, %r12
je 0x9e552
movq %r12, %rdi
callq 0xf02da
movq %rax, %rdi
callq 0xd3c75
testb %al, %al
je 0x9e564
movq (%r14), %rdi
callq 0x120d23
movq %rax, %rdi
movq %r12, %rsi
movq %r15, %rdx
movq %rbx, %rcx
callq 0x1722a4
movq %rax, %r13
testq %rax, %rax
setne %al
jmp 0x9e586
movq 0x8(%r14), %rdi
callq 0x120d23
leaq 0x2b2345(%rip), %rsi    # 0x3508a7
jmp 0x9e574
movq 0x8(%r14), %rdi
callq 0x120d23
leaq 0x2b234e(%rip), %rsi    # 0x3508c2
xorl %r13d, %r13d
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0x1019cf
xorl %eax, %eax
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testb %al, %al
je 0x9e5a5
xorl %ebp, %ebp
cmpb $0x1, 0x19(%r14)
jne 0x9e5a5
movq %r13, %rdi
movq %rbx, %rsi
callq 0x1728f6
movl %eax, %ebp
testl %ebp, %ebp
jne 0x9e5c5
movq 0x10(%r14), %rdi
callq 0x120d23
movq %r13, %rdi
movq %rax, %rsi
movq %r15, %rdx
movq %rbx, %rcx
callq 0x17293e
movl %eax, %ebp
testq %r15, %r15
je 0x9e5e4
movq 0x425917(%rip), %rax    # 0x4c3ee8
movq (%rax), %rsi
movq %r15, %rdi
callq 0x122c67
movq %r15, %rdi
callq 0x122d79
movq %r13, %rdi
callq 0x17380d
movq %r12, %rdi
callq 0xee90c
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x18c3d
callq 0x18bcf
nop