// File: /workspace/github_c_makefile_star2_O2/canboat[P]canboat/analyzer/analyzer-explain.c
// Function: main
int main(int argc, char **argv)
{
  int    ac           = argc;
  char **av           = argv;
  bool   doExplain    = false;
  bool   doExplainXML = false;
  bool   doExplainNGT = false;
  bool   doExplainIK  = false;

  setProgName(argv[0]);

  for (; ac > 1; ac--, av++)
  {
    if (strcasecmp(av[1], "-version") == 0)
    {
      printf("%s\n", VERSION);
      exit(0);
    }
    else if (strcasecmp(av[1], "-camel") == 0)
    {
      camelCase(false);
    }
    else if (strcasecmp(av[1], "-upper-camel") == 0)
    {
      camelCase(true);
    }
    else if (strcasecmp(av[1], "-explain-xml") == 0)
    {
      doExplainXML = true;
    }
    else if (strcasecmp(av[1], "-explain-ngt-xml") == 0)
    {
      doExplainNGT = true;
    }
    else if (strcasecmp(av[1], "-explain-ik-xml") == 0)
    {
      doExplainIK = true;
    }
    else if (strcasecmp(av[1], "-explain") == 0)
    {
      doExplain = true;
    }
    else if (strcasecmp(av[1], "-v1") == 0)
    {
      doV1 = true;
    }
    else if (strcasecmp(av[1], "-d") == 0)
    {
      setLogLevel(LOGLEVEL_DEBUG);
      logDebug("Logging at debug level\n");
    }
    else
    {
      usage(argv, av + 1);
    }
  }

  fillLookups();
  fillFieldType(true);

  if (doExplain)
  {
    explain();
    exit(0);
  }
  if (doExplainXML || doExplainNGT || doExplainIK)
  {
    explainXML(doExplainXML, doExplainNGT, doExplainIK);
    exit(0);
  }
  usage(argv, NULL);
  exit(1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movl %edi, %ebp
movq (%rsi), %rdi
callq 0x1bf7d
movq %rbx, 0x10(%rsp)
leaq 0x8(%rbx), %r14
movl $0x0, 0x8(%rsp)
leaq 0x14650(%rip), %r15     # 0x2217b
leaq 0x1465e(%rip), %r12     # 0x22190
leaq 0x14651(%rip), %r13     # 0x2218a
movl $0x0, 0x4(%rsp)
movl $0x0, 0xc(%rsp)
movl $0x0, (%rsp)
cmpl $0x2, %ebp
jl 0xdc6a
movq (%r14), %rbx
movq %rbx, %rdi
movq %r15, %rsi
callq 0xd060
testl %eax, %eax
je 0xdc85
movq %rbx, %rdi
movq %r12, %rsi
callq 0xd060
testl %eax, %eax
je 0xdc2b
movq %rbx, %rdi
movq %r13, %rsi
callq 0xd060
testl %eax, %eax
je 0xdc2f
movq %rbx, %rdi
leaq 0x145f8(%rip), %rsi     # 0x22197
callq 0xd060
testl %eax, %eax
je 0xdc42
movq %rbx, %rdi
leaq 0x145ee(%rip), %rsi     # 0x221a4
callq 0xd060
testl %eax, %eax
je 0xdc4a
movq %rbx, %rdi
leaq 0x145e8(%rip), %rsi     # 0x221b5
callq 0xd060
testl %eax, %eax
je 0xdc52
movq %rbx, %rdi
leaq 0x145e5(%rip), %rsi     # 0x221c5
callq 0xd060
testl %eax, %eax
je 0xdc59
movq %rbx, %rdi
leaq 0x145db(%rip), %rsi     # 0x221ce
callq 0xd060
testl %eax, %eax
je 0xdc61
movq %rbx, %rdi
leaq 0x145cc(%rip), %rsi     # 0x221d2
callq 0xd060
testl %eax, %eax
jne 0xdce2
pushq $0x3
popq %rdi
callq 0x1bf56
leaq 0x145b3(%rip), %rdi     # 0x221d5
xorl %eax, %eax
callq 0x1bd48
jmp 0xdc37
xorl %edi, %edi
jmp 0xdc32
pushq $0x1
popq %rdi
callq 0xd8fd
decl %ebp
addq $0x8, %r14
jmp 0xdb50
movb $0x1, %al
movl %eax, 0xc(%rsp)
jmp 0xdc37
movb $0x1, %al
movl %eax, 0x8(%rsp)
jmp 0xdc37
movb $0x1, %al
movl %eax, (%rsp)
jmp 0xdc37
movb $0x1, %al
movl %eax, 0x4(%rsp)
jmp 0xdc37
movb $0x1, 0x81a94(%rip)     # 0x8f6fc
jmp 0xdc37
callq 0x178dc
pushq $0x1
popq %rdi
callq 0x1b1a3
testb $0x1, 0x4(%rsp)
je 0xdc93
callq 0xdd96
jmp 0xdccf
leaq 0x144f8(%rip), %rdi     # 0x22184
callq 0xd0c0
jmp 0xdccf
movl 0xc(%rsp), %edx
movl %edx, %eax
movl 0x8(%rsp), %ecx
orb %cl, %al
testb $0x1, %al
je 0xdcae
movl %edx, %eax
xorb $0x1, %al
orb %cl, %al
movl (%rsp), %ecx
jmp 0xdcb8
movl (%rsp), %ecx
testb $0x1, %cl
je 0xdcd6
xorl %eax, %eax
movzbl %dl, %edi
andl $0x1, %edi
movzbl %al, %esi
andl $0x1, %esi
movzbl %cl, %edx
andl $0x1, %edx
callq 0xde49
xorl %edi, %edi
callq 0xd2d0
movq 0x10(%rsp), %rdi
xorl %esi, %esi
callq 0xdcef
movq 0x10(%rsp), %rdi
movq %r14, %rsi
callq 0xdcef