// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/tools/gt_tagerator.c
// Function: gt_tagerator_arguments_check
static int gt_tagerator_arguments_check(GT_UNUSED int rest_argc,
                                        void *tool_arguments,
                                        GtError *err)
{
  TageratorOptions *arguments = tool_arguments;
  GtUword idx;

  if (!arguments->nowildcards && arguments->userdefinedmaxdistance <= 0)
  {
    arguments->nowildcards = true;
  }
  if (gt_option_is_set(arguments->refoptionesaindex))
  {
    arguments->withesa = true;
  } else
  {
    gt_assert(gt_option_is_set(arguments->refoptionpckindex));
    arguments->withesa = false;
  }
  if (arguments->userdefinedmaxdistance < 0)
  {
    if (arguments->doonline)
    {
      gt_error_set(err,"option -online requires option -e");
      return -1;
    }
    if (arguments->maxintervalwidth == 0)
    {
      gt_error_set(err,
                   "if option -e is not used then option -maxocc is required");
      return -1;
    }
    if (arguments->best)
    {
      gt_error_set(err,"option -best requires option -e");
      return -1;
    }
  } else
  {
    if (arguments->skpp &&
        (arguments->userdefinedmaxdistance == 0 ||
         arguments->maxintervalwidth == 0))
    {
      gt_error_set(err,"option -skpp only works in pdiff mode");
      return -1;
    }
  }
  for (idx=0; idx<gt_str_array_size(arguments->outputspec); idx++)
  {
    if (gt_optionargaddbitmask(outputmodedesctable,
                            sizeof (outputmodedesctable)/
                            sizeof (outputmodedesctable[0]),
                            &arguments->outputmode,
                            "-output",
                            gt_str_array_get(arguments->outputspec,idx),
                            err) != 0)
    {
      return -1;
    }
  }
  if (arguments->outputmode == 0)
  {
    arguments->outputmode = TAGOUT_TAGNUM | TAGOUT_TAGSEQ |
                            TAGOUT_DBLENGTH | TAGOUT_DBSTARTPOS |
                            TAGOUT_STRAND;
    if (arguments->maxintervalwidth > 0)
    {
      arguments->outputmode |= TAGOUT_TAGLENGTH;
    }
  }
  return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
cmpb $0x0, 0x3f(%rsi)
jne 0xd025e
cmpq $0x0, 0x48(%r14)
jg 0xd025e
movb $0x1, 0x3f(%r14)
movq 0x20(%r14), %rdi
callq 0x10fe52
movb $0x1, %cl
testb %al, %al
jne 0xd0280
movq 0x28(%r14), %rdi
callq 0x10fe52
testb %al, %al
je 0xd037e
xorl %ecx, %ecx
movb %cl, 0x39(%r14)
movq 0x48(%r14), %rax
testq %rax, %rax
js 0xd02ac
cmpb $0x1, 0x40(%r14)
jne 0xd02dd
testq %rax, %rax
je 0xd02a0
cmpq $0x0, 0x58(%r14)
jne 0xd02dd
leaq 0x2954aa(%rip), %rsi    # 0x365751
jmp 0xd0360
cmpb $0x1, 0x3a(%r14)
jne 0xd02bf
leaq 0x29541c(%rip), %rsi    # 0x3656d6
jmp 0xd0360
cmpq $0x0, 0x58(%r14)
je 0xd0359
cmpb $0x1, 0x41(%r14)
jne 0xd02dd
leaq 0x295459(%rip), %rsi    # 0x365731
jmp 0xd0360
movq 0x8(%r14), %rdi
callq 0x121e78
testq %rax, %rax
je 0xd033a
leaq 0x54(%r14), %r15
xorl %r12d, %r12d
leaq 0x3ee267(%rip), %r13    # 0x4be560
leaq 0x289a2f(%rip), %rbp    # 0x359d2f
movq 0x8(%r14), %rdi
movq %r12, %rsi
callq 0x121cfa
movl $0xb, %esi
movq %r13, %rdi
movq %r15, %rdx
movq %rbp, %rcx
movq %rax, %r8
movq %rbx, %r9
callq 0x1c094c
testl %eax, %eax
jne 0xd036a
incq %r12
movq 0x8(%r14), %rdi
callq 0x121e78
cmpq %rax, %r12
jb 0xd0300
xorl %eax, %eax
cmpl $0x0, 0x54(%r14)
jne 0xd036f
xorl %ecx, %ecx
cmpq $0x0, 0x58(%r14)
setne %cl
shll $0x9, %ecx
orl $0x4f, %ecx
movl %ecx, 0x54(%r14)
jmp 0xd036f
leaq 0x295398(%rip), %rsi    # 0x3656f8
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1019cf
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x2188b