// File: /workspace/github_c_makefile_star2_O0/macournoyer[P]peg/leg.c
// Function: main
int main(int argc, char **argv)
{
  Node *n;
  int   c;

  output= stdout;
  input= stdin;
  lineNumber= 1;
  fileName= "<stdin>";

  while (-1 != (c= getopt(argc, argv, "Vho:v")))
    {
      switch (c)
	{
	case 'V':
	  version(basename(argv[0]));
	  exit(0);

	case 'h':
	  usage(basename(argv[0]));
	  break;

	case 'o':
	  if (!(output= fopen(optarg, "w")))
	    {
	      perror(optarg);
	      exit(1);
	    }
	  break;

	case 'v':
	  verboseFlag= 1;
	  break;

	default:
	  fprintf(stderr, "for usage try: %s -h\n", argv[0]);
	  exit(1);
	}
    }
  argc -= optind;
  argv += optind;

  if (argc)
    {
      for (;  argc;  --argc, ++argv)
	{
	  if (!strcmp(*argv, "-"))
	    {
	      input= stdin;
	      fileName= "<stdin>";
	    }
	  else
	    {
	      if (!(input= fopen(*argv, "r")))
		{
		  perror(*argv);
		  exit(1);
		}
	      fileName= *argv;
	    }
	  lineNumber= 1;
	  if (!yyparse())
	    yyerror("syntax error");
	  if (input != stdin)
	    fclose(input);
	}
    }
  else
    if (!yyparse())
      yyerror("syntax error");

  if (verboseFlag)
    for (n= rules;  n;  n= n->any.next)
      Rule_print(n);

  Rule_compile_c_header();

  for (; headers;  headers= headers->next)
    fprintf(output, "%s\n", headers->text);

  if (rules)
    Rule_compile_c(rules);

  if (trailer)
    fprintf(output, "%s\n", trailer);

  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq 0xa8e3(%rip), %rax      # 0xbfc0
movq (%rax), %rcx
leaq 0xaad9(%rip), %rax      # 0xc1c0
movq %rcx, (%rax)
movq 0xa8d7(%rip), %rax      # 0xbfc8
movq (%rax), %rax
movq %rax, 0xaa1d(%rip)      # 0xc118
movl $0x1, 0xaa83(%rip)      # 0xc188
leaq 0x5a8d(%rip), %rax      # 0x7199
movq %rax, 0xaa6d(%rip)      # 0xc180
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
leaq 0x5a80(%rip), %rdx      # 0x71a1
callq 0x1150
movl %eax, %ecx
movl %ecx, -0x1c(%rbp)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpl %ecx, %eax
je 0x180d
movl -0x1c(%rbp), %eax
addl $-0x56, %eax
movl %eax, %ecx
movq %rcx, -0x28(%rbp)
subl $0x20, %eax
ja 0x17df
movq -0x28(%rbp), %rax
leaq 0x58ac(%rip), %rcx      # 0x7004
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x10f0
movq %rax, %rdi
callq 0x1a10
xorl %edi, %edi
callq 0x1170
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x10f0
movq %rax, %rdi
callq 0x1a50
jmp 0x1808
movq 0xa83f(%rip), %rax      # 0xbfd8
movq (%rax), %rdi
leaq 0x5a04(%rip), %rsi      # 0x71a7
callq 0x1130
leaq 0xaa11(%rip), %rcx      # 0xc1c0
movq %rax, (%rcx)
cmpq $0x0, %rax
jne 0x17d1
movq 0xa819(%rip), %rax      # 0xbfd8
movq (%rax), %rdi
callq 0x1140
movl $0x1, %edi
callq 0x1170
jmp 0x1808
movl $0x1, 0xa943(%rip)      # 0xc120
jmp 0x1808
movq 0xa812(%rip), %rax      # 0xbff8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rdx
leaq 0x59b2(%rip), %rsi      # 0x71a9
movb $0x0, %al
callq 0x10c0
movl $0x1, %edi
callq 0x1170
jmp 0x1713
movq 0xa7bc(%rip), %rax      # 0xbfd0
movl (%rax), %ecx
movl -0x8(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x8(%rbp)
movq 0xa7ab(%rip), %rax      # 0xbfd0
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
cmpl $0x0, -0x8(%rbp)
je 0x1929
jmp 0x1845
cmpl $0x0, -0x8(%rbp)
je 0x1927
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x5962(%rip), %rsi      # 0x71bf
callq 0x10b0
cmpl $0x0, %eax
jne 0x1888
movq 0xa75a(%rip), %rax      # 0xbfc8
movq (%rax), %rax
movq %rax, 0xa8a0(%rip)      # 0xc118
leaq 0x591a(%rip), %rax      # 0x7199
movq %rax, 0xa8fa(%rip)      # 0xc180
jmp 0x18cc
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x5936(%rip), %rsi      # 0x71cc
callq 0x1130
movq %rax, 0xa876(%rip)      # 0xc118
cmpq $0x0, %rax
jne 0x18be
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x1140
movl $0x1, %edi
callq 0x1170
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, 0xa8b4(%rip)      # 0xc180
movl $0x1, 0xa8b2(%rip)      # 0xc188
callq 0x1450
cmpl $0x0, %eax
jne 0x18ec
leaq 0x58da(%rip), %rdi      # 0x71c1
callq 0x1470
movq 0xa825(%rip), %rax      # 0xc118
movq 0xa6ce(%rip), %rcx      # 0xbfc8
cmpq (%rcx), %rax
je 0x190b
movq 0xa812(%rip), %rdi      # 0xc118
callq 0x1030
jmp 0x190d
movl -0x8(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x8(%rbp)
movq -0x10(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x10(%rbp)
jmp 0x1845
jmp 0x1941
callq 0x1450
cmpl $0x0, %eax
jne 0x193f
leaq 0x5887(%rip), %rdi      # 0x71c1
callq 0x1470
jmp 0x1941
cmpl $0x0, 0xa7d8(%rip)      # 0xc120
je 0x1978
leaq 0xa857(%rip), %rax      # 0xc1a8
movq (%rax), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0x1976
movq -0x18(%rbp), %rdi
callq 0x50d0
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x18(%rbp)
jmp 0x1958
jmp 0x1978
callq 0x51d0
cmpq $0x0, 0xa80b(%rip)      # 0xc190
je 0x19bd
leaq 0xa832(%rip), %rax      # 0xc1c0
movq (%rax), %rdi
movq 0xa7f8(%rip), %rax      # 0xc190
movq (%rax), %rdx
leaq 0x70e8(%rip), %rsi      # 0x8a8a
movb $0x0, %al
callq 0x10c0
movq 0xa7e0(%rip), %rax      # 0xc190
movq 0x8(%rax), %rax
movq %rax, 0xa7d5(%rip)      # 0xc190
jmp 0x197d
leaq 0xa7e4(%rip), %rax      # 0xc1a8
cmpq $0x0, (%rax)
je 0x19d9
leaq 0xa7d7(%rip), %rax      # 0xc1a8
movq (%rax), %rdi
callq 0x5470
cmpq $0x0, 0xa7b7(%rip)      # 0xc198
je 0x1a02
leaq 0xa7d6(%rip), %rax      # 0xc1c0
movq (%rax), %rdi
movq 0xa7a4(%rip), %rdx      # 0xc198
leaq 0x708f(%rip), %rsi      # 0x8a8a
movb $0x0, %al
callq 0x10c0
xorl %eax, %eax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)