// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/tools/gt_mergeesa.c
// Function: gt_mergeesa
int gt_mergeesa(int argc, const char **argv, GtError *err)
{
  GtStr *storeindex;
  GtStrArray *indexnametab;
  bool haserr = false;
  int parsed_args;

  gt_error_check(err);

  storeindex = gt_str_new();
  indexnametab = gt_str_array_new();
  switch (parse_options(storeindex, indexnametab, &parsed_args, argc, argv,
                        err)) {
    case GT_OPTION_PARSER_OK: break;
    case GT_OPTION_PARSER_ERROR:
         haserr = true; break;
    case GT_OPTION_PARSER_REQUESTS_EXIT: return 0;
  }
  if (!haserr)
  {
    GtUword i;
    GtLogger *logger;

    printf("# storeindex=%s\n",gt_str_get(storeindex));
    for (i=0; i<gt_str_array_size(indexnametab); i++)
    {
      printf("# input=%s\n",gt_str_array_get(indexnametab,i));
    }
    logger = gt_logger_new(false, GT_LOGGER_DEFLT_PREFIX, stdout);
    if (gt_performtheindexmerging(storeindex,
                              indexnametab,
                              logger,
                              err) != 0)
    {
      haserr = true;
    }
    gt_logger_delete(logger);
  }
  gt_str_delete(storeindex);
  gt_str_array_delete(indexnametab);
  return haserr ? -1 : 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %r15
movq %rsi, %rbp
movl %edi, %ebx
testq %rdx, %rdx
je 0xb2eb7
movq %r15, %rdi
callq 0x101a9a
testb %al, %al
jne 0xb3078
movl %ebx, 0x4(%rsp)
callq 0x1208f8
movq %rax, %r13
callq 0x121b54
movq %rax, %r14
testq %r15, %r15
je 0xb2ee0
movq %r15, %rdi
callq 0x101a9a
testb %al, %al
jne 0xb307d
leaq 0x2a6fe5(%rip), %rdi    # 0x359ecc
leaq 0x2a7005(%rip), %rsi    # 0x359ef3
callq 0x10cc4e
movq %rax, %rbx
leaq 0x29c3cf(%rip), %rsi    # 0x34f2cc
movq %rax, %rdi
callq 0x10ceab
leaq 0x309b87(%rip), %rdi    # 0x3bca93
leaq 0x2a6ffe(%rip), %rsi    # 0x359f11
movq %r14, %rdx
callq 0x10f9f6
movq %rax, %r12
movq %rax, %rdi
callq 0x10fa96
movq %rbx, %rdi
movq %r12, %rsi
callq 0x10cd10
leaq 0x2bbdda(%rip), %rdi    # 0x36ed12
leaq 0x2a6ff8(%rip), %rsi    # 0x359f37
xorl %r12d, %r12d
movq %r13, 0x8(%rsp)
movq %r13, %rdx
xorl %ecx, %ecx
callq 0x10f987
movq %rax, %r13
movq %rax, %rdi
callq 0x10fa96
movq %rbx, %rdi
movq %r13, %rsi
callq 0x10cd10
leaq 0x7245a(%rip), %r8      # 0x1253c8
leaq 0x14(%rsp), %rsi
movq %rbx, %rdi
movl 0x4(%rsp), %edx
movq %rbp, %rcx
movq %r15, %r9
callq 0x10d796
movl %eax, %ebp
movq %rbx, %rdi
callq 0x10f2d0
cmpl $0x2, %ebp
je 0xb3066
cmpl $0x1, %ebp
jne 0xb2fa0
movb $0x1, %r12b
testb %r12b, %r12b
movq 0x8(%rsp), %r13
jne 0xb304f
movq %r13, %rdi
callq 0x120d23
leaq 0x2a6ef2(%rip), %rdi    # 0x359eaf
movq %rax, %rsi
xorl %eax, %eax
callq 0x17070
movq %r14, %rdi
callq 0x121e78
testq %rax, %rax
je 0xb3006
leaq 0x2a6ee5(%rip), %rbx    # 0x359ec0
xorl %r13d, %r13d
movq %r14, %rdi
movq %r13, %rsi
callq 0x121cfa
movq %rbx, %rdi
movq %rax, %rsi
xorl %eax, %eax
callq 0x17070
incq %r13
movq %r14, %rdi
callq 0x121e78
cmpq %rax, %r13
jb 0xb2fde
movq 0x410edb(%rip), %rax    # 0x4c3ee8
movq (%rax), %rdx
leaq 0x29c8bd(%rip), %rsi    # 0x34f8d4
xorl %edi, %edi
callq 0x108ed0
movq %rax, %rbx
movq 0x8(%rsp), %r13
movq %r13, %rdi
movq %r14, %rsi
movq %rax, %rdx
movq %r15, %rcx
callq 0x209e58
testl %eax, %eax
movzbl %r12b, %eax
movl $0x1, %r12d
cmovel %eax, %r12d
movq %rbx, %rdi
callq 0x10916a
movq %r13, %rdi
callq 0x121b03
movq %r14, %rdi
callq 0x121e8b
movzbl %r12b, %r12d
negl %r12d
movl %r12d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x1ca27
callq 0x1ca5e
nop