// File: /workspace/github_c_makefile_star2_O0/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_read_symbols_and_comments
static const char *
aiger_read_symbols_and_comments (aiger * public, aiger_reader * reader)
{
  IMPORT_private_FROM (public);
  const char *error, *type;
  unsigned pos, num, count;
  aiger_symbol *symbol;
  
  assert (!reader->buffer);

  for (count = 0;; count++)
    {
      if (reader->ch == EOF)
	return 0;

      if (reader->ch != 'i' && 
	  reader->ch != 'l' && 
	  reader->ch != 'o' &&
	  reader->ch != 'b' &&
	  reader->ch != 'c' &&
	  reader->ch != 'j' &&
	  reader->ch != 'f')
	{
	  if (reader->looks_like_aag)
	    return aiger_error_u (private,
				  "line %u: corrupted symbol table "
				  "('aig' instead of 'aag' header?)",
				  reader->lineno);
	  return aiger_error_u (private,
			        "line %u: expected '[cilobcjf]' or EOF",
			        reader->lineno);
	}

      /* 'c' is a special case as it may be either the start of a comment, 
	 or the start of a constraint symbol */
      if (reader->ch == 'c')
	{	  
	  if ( aiger_next_ch (reader) == '\n' )
	    return aiger_read_comments(public, reader);

	  type = "constraint";
	  num = public->num_constraints;
	  symbol = public->constraints;
	}
      else 
	{
	  if (reader->ch == 'i')
	    {
	      type = "input";
	      num = public->num_inputs;
	      symbol = public->inputs;
	    }
	  else if (reader->ch == 'l')
	    {
	      type = "latch";
	      num = public->num_latches;
	      symbol = public->latches;
	    }
	  else if (reader->ch == 'o')
	    {
	      type = "output";
	      num = public->num_outputs;
	      symbol = public->outputs;
	    }
	  else if (reader->ch == 'b')
	    {
	      type = "bad";
	      num = public->num_bad;
	      symbol = public->bad;
	    }     
	  else if (reader->ch == 'j')
	    {
	      type = "justice";
	      num = public->num_justice;
	      symbol = public->justice;
	    }
	  else
	    {
	      assert (reader->ch == 'f');
	      type = "fairness";
	      num = public->num_fairness;
	      symbol = public->fairness;
	    }

	  aiger_next_ch (reader);
	}

      error = aiger_read_literal (private, reader, &pos, ' ', 0);
      if (error)
	return error;

      if (pos >= num)
	return aiger_error_usu (private,
				"line %u: "
				"%s symbol table entry position %u too large",
				reader->lineno_at_last_token_start, type,
				pos);

      symbol += pos;

      if (symbol->name)
	return aiger_error_usu (private,
				"line %u: %s %u has multiple symbols",
				reader->lineno_at_last_token_start, type,
				symbol->lit);

      while (reader->ch != '\n' && reader->ch != EOF)
	{
	  aiger_reader_push_ch (private, reader, reader->ch);
	  aiger_next_ch (reader);
	}

      if (reader->ch == EOF)
	return aiger_error_u (private,
			      "line %u: new line missing", reader->lineno);

      assert (reader->ch == '\n');
      aiger_next_ch (reader);

      aiger_reader_push_ch (private, reader, 0);
      symbol->name = aiger_copy_str (private, reader->buffer);
      reader->top_buffer = 0;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x50(%rax)
jne 0x9315
jmp 0x9334
leaq 0x410b(%rip), %rdi      # 0xd427
leaq 0x2f86(%rip), %rsi      # 0xc2a9
movl $0x972, %edx            # imm = 0x972
leaq 0x4108(%rip), %rcx      # 0xd437
callq 0x10f0
movl $0x0, -0x3c(%rbp)
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
jne 0x9352
movq $0x0, -0x8(%rbp)
jmp 0x9717
movq -0x18(%rbp), %rax
cmpl $0x69, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x6c, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x6f, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x62, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x63, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x6a, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x66, 0x10(%rax)
je 0x93e6
movq -0x18(%rbp), %rax
cmpl $0x0, 0x24(%rax)
je 0x93c6
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x14(%rax), %edx
leaq 0x40c4(%rip), %rsi      # 0xd47c
callq 0xa150
movq %rax, -0x8(%rbp)
jmp 0x9717
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x14(%rax), %edx
leaq 0x40e5(%rip), %rsi      # 0xd4bd
callq 0xa150
movq %rax, -0x8(%rbp)
jmp 0x9717
movq -0x18(%rbp), %rax
cmpl $0x63, 0x10(%rax)
jne 0x943a
movq -0x18(%rbp), %rdi
callq 0xae30
cmpl $0xa, %eax
jne 0x9414
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0xb3e0
movq %rax, -0x8(%rbp)
jmp 0x9717
leaq 0x3ce4(%rip), %rax      # 0xd0ff
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x18(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x48(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9581
movq -0x18(%rbp), %rax
cmpl $0x69, 0x10(%rax)
jne 0x946a
leaq 0x3be8(%rip), %rax      # 0xd033
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9578
movq -0x18(%rbp), %rax
cmpl $0x6c, 0x10(%rax)
jne 0x949a
leaq 0x3be1(%rip), %rax      # 0xd05c
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x30(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9576
movq -0x18(%rbp), %rax
cmpl $0x6f, 0x10(%rax)
jne 0x94ca
leaq 0x3c05(%rip), %rax      # 0xd0b0
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9574
movq -0x18(%rbp), %rax
cmpl $0x62, 0x10(%rax)
jne 0x94f7
leaq 0x3bfd(%rip), %rax      # 0xd0d8
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x14(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9572
movq -0x18(%rbp), %rax
cmpl $0x6a, 0x10(%rax)
jne 0x9524
leaq 0x3fdb(%rip), %rax      # 0xd4e3
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x1c(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x50(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9570
movq -0x18(%rbp), %rax
cmpl $0x66, 0x10(%rax)
jne 0x9530
jmp 0x954f
leaq 0x3fb4(%rip), %rdi      # 0xd4eb
leaq 0x2d6b(%rip), %rsi      # 0xc2a9
movl $0x9b8, %edx            # imm = 0x9B8
leaq 0x3eed(%rip), %rcx      # 0xd437
callq 0x10f0
leaq 0x3bd5(%rip), %rax      # 0xd12b
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x20(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9572
jmp 0x9574
jmp 0x9576
jmp 0x9578
movq -0x18(%rbp), %rdi
callq 0xae30
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
leaq -0x34(%rbp), %rdx
movl $0x20, %ecx
xorl %eax, %eax
movl %eax, %r8d
callq 0xaf30
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x95b4
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x9717
movl -0x34(%rbp), %eax
cmpl -0x38(%rbp), %eax
jb 0x95e4
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x1c(%rax), %edx
movq -0x30(%rbp), %rcx
movl -0x34(%rbp), %r8d
leaq 0x3f27(%rip), %rsi      # 0xd4fd
callq 0xb4e0
movq %rax, -0x8(%rbp)
jmp 0x9717
movl -0x34(%rbp), %ecx
movq -0x48(%rbp), %rax
movl %ecx, %ecx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rax
cmpq $0x0, 0x18(%rax)
je 0x962e
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x1c(%rax), %edx
movq -0x30(%rbp), %rcx
movq -0x48(%rbp), %rax
movl (%rax), %r8d
leaq 0x3f12(%rip), %rsi      # 0xd532
callq 0xb4e0
movq %rax, -0x8(%rbp)
jmp 0x9717
jmp 0x9630
movq -0x18(%rbp), %rcx
xorl %eax, %eax
cmpl $0xa, 0x10(%rcx)
movb %al, -0x49(%rbp)
je 0x964d
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
setne %al
movb %al, -0x49(%rbp)
movb -0x49(%rbp), %al
testb $0x1, %al
jne 0x9656
jmp 0x9678
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x18(%rbp), %rax
movl 0x10(%rax), %eax
movsbl %al, %edx
callq 0xb670
movq -0x18(%rbp), %rdi
callq 0xae30
jmp 0x9630
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
jne 0x969f
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x14(%rax), %edx
leaq 0x3ec2(%rip), %rsi      # 0xd556
callq 0xa150
movq %rax, -0x8(%rbp)
jmp 0x9717
movq -0x18(%rbp), %rax
cmpl $0xa, 0x10(%rax)
jne 0x96ab
jmp 0x96ca
leaq 0x3ebe(%rip), %rdi      # 0xd570
leaq 0x2bf0(%rip), %rsi      # 0xc2a9
movl $0x9de, %edx            # imm = 0x9DE
leaq 0x3d72(%rip), %rcx      # 0xd437
callq 0x10f0
movq -0x18(%rbp), %rdi
callq 0xae30
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
xorl %edx, %edx
callq 0xb670
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x50(%rax), %rsi
callq 0x2c00
movq %rax, %rcx
movq -0x48(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x58(%rax)
movl -0x3c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x3c(%rbp)
jmp 0x933b
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)