// File: /workspace/github_c_makefile_star2_O3/mabdi[P]bunney/bunny-gcc.c
// Function: get_item
static _u8* get_item(FILE* f) {
  _s32 c;
  static _u8 obuf[MAXTOKEN];
  _u32 olen = 0;
  _u8  qopen;
  
  if ((c = getc(f)) == EOF) return 0;

  /* Cluster whitespaces together */
  if (isspace(c)) {
    obuf[olen++] = c;
    while ((c=getc(f)) != EOF && isspace(c) && olen < MAXTOKEN - 1) obuf[olen++] = c;
    obuf[olen] = 0;
    if (olen != MAXTOKEN - 1 && c != EOF) ungetc(c,f);
    return obuf;
  }  

  /* Dump all text between "..." or '...' as a single token; watch for \, though */
  if (c == '"' || c == '\'') {
    _u8 escnext = 0;
    qopen = obuf[olen++] = c;
    while ((c=getc(f)) != EOF && (escnext || c != qopen) && olen < MAXTOKEN - 2) {
      if (!escnext) escnext = (c == '\\'); else escnext = 0;
      obuf[olen++] = c;
    }
    if (olen == MAXTOKEN - 2) fatal("string too long: '%.32s...'",obuf);
    if (c == EOF) fatal("unterminated string: '%.32s...'",obuf);
    obuf[olen++] = qopen;
    obuf[olen] = 0;

    return obuf;
  }
  
  /* Special handling for compiler directives (#) - copy whole line */
  if (c == '#') {
    obuf[olen++] = c;
    while ((c=getc(f)) != EOF && c != '\n' && olen < MAXTOKEN - 2) obuf[olen++] = c;
    if (olen == MAXTOKEN - 2) fatal("compiler directive too long: '%.32s...'",obuf);
    obuf[olen++] = '\n';
    obuf[olen] = 0;
    return obuf;
  }
  
  /* If found a run of [A-Za-z0-9_], consume it all. Everything else, return char-by-char. */
     
  while (olen < MAXTOKEN - 1) {
  
    if (!isalnum(c) && c != '_') {
      if (olen) ungetc(c,f); else obuf[olen++] = c;
      obuf[olen] = 0;
      return obuf;
    }
    
    obuf[olen++] = c;
    
    if ((c = getc(f)) == EOF) {
      obuf[olen] = 0;
      return obuf;
    }
    
  }
  
  fatal("line too long: '%.30s...'",obuf);

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
callq 0x1070
cmpl $-0x1, %eax
je 0x4517
movl %eax, %ebp
callq 0x1140
movq %rax, %r15
movq (%rax), %rax
movslq %ebp, %rcx
testb $0x20, 0x1(%rax,%rcx,2)
jne 0x451f
cmpl $0x22, %ebp
je 0x448c
cmpl $0x23, %ebp
je 0x45b0
cmpl $0x27, %ebp
jne 0x45f4
movb %bpl, 0x4cfd(%rip)      # 0x9190
movq %rbx, %rdi
callq 0x1070
cmpl $-0x1, %eax
je 0x467c
movl $0x2, %r15d
xorl %r12d, %r12d
leaq 0x4cdc(%rip), %r14      # 0x9190
leaq -0x1(%r15), %rcx
testb %r12b, %r12b
je 0x44cb
cmpq $0xffd, %rcx            # imm = 0xFFD
jbe 0x44e0
jmp 0x4573
cmpl %ebp, %eax
je 0x4573
cmpq $0xffe, %rcx            # imm = 0xFFE
jae 0x4573
testb %r12b, %r12b
sete %cl
cmpl $0x5c, %eax
sete %r12b
andb %cl, %r12b
movb %al, -0x1(%r15,%r14)
movq %rbx, %rdi
callq 0x1070
incq %r15
cmpl $-0x1, %eax
jne 0x44b4
cmpq $0xfff, %r15            # imm = 0xFFF
jne 0x467c
callq 0x14a2
xorl %r14d, %r14d
jmp 0x4670
movb %bpl, 0x4c6a(%rip)      # 0x9190
movq %rbx, %rdi
callq 0x1070
movl $0x1, %r12d
cmpl $-0x1, %eax
je 0x4664
leaq 0x4c4c(%rip), %r14      # 0x9190
movq (%r15), %rcx
movslq %eax, %rdx
testb $0x20, 0x1(%rcx,%rdx,2)
je 0x458f
cmpq $0xffe, %r12            # imm = 0xFFE
ja 0x458f
movb %al, (%r12,%r14)
incq %r12
movq %rbx, %rdi
callq 0x1070
cmpl $-0x1, %eax
jne 0x4544
jmp 0x4664
cmpq $0xfff, %r15            # imm = 0xFFF
je 0x4512
movl %ecx, %eax
movb %bpl, (%rax,%r14)
movl %r15d, %eax
movb $0x0, (%rax,%r14)
jmp 0x4670
movb $0x0, (%r12,%r14)
cmpq $0xfff, %r12            # imm = 0xFFF
je 0x4670
movl %eax, %edi
movq %rbx, %rsi
callq 0x1030
jmp 0x4670
movb $0x23, 0x4bd9(%rip)     # 0x9190
movq %rbx, %rdi
callq 0x1070
movl $0x2, %r15d
leaq 0x4bc4(%rip), %r14      # 0x9190
cmpl $-0x1, %eax
je 0x4633
cmpl $0xa, %eax
je 0x4633
movb %al, -0x1(%r15,%r14)
movq %rbx, %rdi
callq 0x1070
incq %r15
cmpq $0xfff, %r15            # imm = 0xFFF
jne 0x45cc
callq 0x1455
xorl %r12d, %r12d
leaq 0x4b92(%rip), %r14      # 0x9190
cmpq $0xfff, %r12            # imm = 0xFFF
je 0x4681
cmpl $0x5f, %ebp
je 0x461b
movq (%r15), %rax
movslq %ebp, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x8, %eax
je 0x4646
movb %bpl, (%r12,%r14)
incq %r12
movq %rbx, %rdi
callq 0x1070
movl %eax, %ebp
cmpl $-0x1, %eax
jne 0x45fe
jmp 0x466b
cmpq $0xfff, %r15            # imm = 0xFFF
je 0x45ef
movw $0xa, -0x1(%r15,%r14)
jmp 0x4670
testq %r12, %r12
je 0x4657
movl %ebp, %edi
movq %rbx, %rsi
callq 0x1030
jmp 0x4664
movb %bpl, 0x4b32(%rip)      # 0x9190
movl $0x1, %r12d
leaq 0x4b25(%rip), %r14      # 0x9190
movb $0x0, (%r12,%r14)
movq %r14, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
callq 0x14ef
callq 0x153c