LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/parser.c
// Function: ParseInitDecltor
struct Node *ParseInitDecltor() {
  struct Node *decltor = ParseDecltor();
  if (!decltor) return NULL;
  struct Node *t;
  if (!(t = ConsumePunctuator("="))) return decltor;
  struct Node *init_expr = ParseAssignExpr();
  assert(init_expr);
  decltor->decltor_init_expr = CreateASTBinOp(t, NULL, init_expr);
  return decltor;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
callq 0x7dd0
testq %rax, %rax
je 0x7e6d
movq %rax, %rbx
leaq 0x3f4e(%rip), %rdi      # 0xbd91
callq 0x94f8
testq %rax, %rax
je 0x7e6f
movq %rax, %r14
callq 0x76ab
testq %rax, %rax
je 0x7e7a
movq %r14, %rdi
xorl %esi, %esi
movq %rax, %rdx
callq 0x3f1b
movq %rax, 0x58(%rbx)
jmp 0x7e6f
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x444d(%rip), %rdi      # 0xc2ce
leaq 0x4382(%rip), %rsi      # 0xc20a
movl $0x1e1, %edx            # imm = 0x1E1
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/parser.c
// Function: ParseParamDecl
struct Node *ParseParamDecl() {
  struct Node *decl_specs = ParseDeclSpecs();
  if (!decl_specs) return NULL;
  struct Node *n = AllocNode(kASTDecl);
  n->op = decl_specs;
  n->right = ParseDecltor();
  return n;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
callq 0x7a8a
testq %rax, %rax
je 0x7ebf
movq %rax, %r14
movl $0xd, %edi
callq 0x3f05
movq %rax, %rbx
movq %r14, 0x10(%rax)
callq 0x7dd0
movq %rax, 0x20(%rbx)
jmp 0x7ec1
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/parser.c
// Function: ParseDeclBody
struct Node *ParseDeclBody() {
  struct Node *decl_specs = ParseDeclSpecs();
  if (!decl_specs) return NULL;
  struct Node *n = AllocNode(kASTDecl);
  n->op = decl_specs;
  n->right = ParseInitDecltor();
  return n;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
callq 0x7a8a
testq %rax, %rax
je 0x7ef9
movq %rax, %r14
movl $0xd, %edi
callq 0x3f05
movq %rax, %rbx
movq %r14, 0x10(%rax)
callq 0x7e2b
movq %rax, 0x20(%rbx)
jmp 0x7efb
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/parser.c
// Function: ParseDecl
struct Node *ParseDecl() {
  struct Node *decl_body = ParseDeclBody();
  if (!decl_body) return NULL;
  ExpectPunctuator(";");
  return decl_body;
}

// Assembly:
pushq %rbx
callq 0x7ecc
testq %rax, %rax
je 0x7f22
movq %rax, %rbx
leaq 0x4d8e(%rip), %rdi      # 0xcca9
callq 0x953c
jmp 0x7f24
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/parser.c
// Function: ParseCompStmt
struct Node *ParseCompStmt() {
  struct Node *t;
  if (!(t = ConsumePunctuator("{"))) return NULL;
  struct Node *list = AllocList();
  list->op = t;
  struct Node *stmt;
  while ((stmt = ParseDecl()) || (stmt = ParseStmt())) {
    PushToList(list, stmt);
  }
  ExpectPunctuator("}");
  return list;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x4374(%rip), %rdi      # 0xc2a9
callq 0x94f8
testq %rax, %rax
je 0x7f9e
movq %rax, %r14
xorl %eax, %eax
callq 0x4806
movq %rax, %rbx
movq %r14, 0x10(%rax)
leaq 0x4d52(%rip), %r14      # 0xcca9
callq 0x7ecc
testq %rax, %rax
je 0x7f6e
movq %rax, %r15
movq %r14, %rdi
callq 0x953c
jmp 0x7f71
xorl %r15d, %r15d
testq %r15, %r15
jne 0x7f83
callq 0x7a59
movq %rax, %r15
testq %rax, %rax
je 0x7f90
movq %rbx, %rdi
movq %r15, %rsi
callq 0x488e
jmp 0x7f57
leaq 0x4314(%rip), %rdi      # 0xc2ab
callq 0x953c
jmp 0x7fa0
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/parser.c
// Function: Parse
struct Node *Parse(struct Node **head_token) {
  InitParser(head_token);
  struct Node *list = AllocList();
  struct Node *decl_body;
  while ((decl_body = ParseDeclBody())) {
    if (ConsumePunctuator(";")) {
      PushToList(list, decl_body);
      assert(IsASTList(decl_body->op));
      if (IsASTDeclOfTypedef(decl_body)) {
        // typedef case
        struct Node *typedef_type = CreateTypeFromDecl(decl_body);
        struct Node *typedef_name =
            GetIdentifierTokenFromTypeAttr(typedef_type);
        PrintASTNode(typedef_name);
        PushKeyValueToList(ord_idents, CreateTokenStr(typedef_name),
                           GetTypeWithoutAttr(typedef_type));
      }
      continue;
    }
    struct Node *func_def = ParseFuncDef(decl_body);
    if (!func_def) {
      ErrorWithToken(NextToken(), "Unexpected token");
    }
    PushToList(list, func_def);
  }
  struct Node *t;
  if (!(t = NextToken())) return list;
  ErrorWithToken(t, "Unexpected token");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
callq 0x989c
movq %rax, %rdi
callq 0x93be
xorl %eax, %eax
callq 0x4806
movq %rax, 0x9377(%rip)      # 0x11380
xorl %eax, %eax
callq 0x4806
movq %rax, %rbx
callq 0x7ecc
testq %rax, %rax
je 0x80e2
movq %rax, %r15
leaq 0x4c7e(%rip), %r14      # 0xcca9
movq %r14, %rdi
callq 0x94f8
testq %rax, %rax
je 0x80a8
movq %rbx, %rdi
movq %r15, %rsi
callq 0x488e
movq 0x10(%r15), %rdi
callq 0x3ea8
testb %al, %al
je 0x80f9
movq %r15, %rdi
callq 0x3eb7
testb %al, %al
je 0x80d1
movq %r15, %rdi
callq 0xa67c
movq %rax, %r15
movq %rax, %rdi
callq 0xa121
movq %rax, %r12
movq %rax, %rdi
callq 0x440e
movq 0x92fb(%rip), %r13      # 0x11380
movq %r12, %rdi
callq 0x923f
movq %rax, %r12
movq %r15, %rdi
callq 0xa104
movq %r13, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x48c1
jmp 0x80d1
callq 0x7f29
testq %rax, %rax
je 0x80c2
movq %r15, %rdi
movq %rax, %rsi
callq 0x4043
movq %rax, %rsi
jmp 0x80c4
xorl %esi, %esi
testq %rsi, %rsi
je 0x8111
movq %rbx, %rdi
callq 0x488e
callq 0x7ecc
movq %rax, %r15
testq %rax, %rax
jne 0x802b
callq 0x958f
testq %rax, %rax
jne 0x8116
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0x41d8(%rip), %rdi      # 0xc2d8
leaq 0x4103(%rip), %rsi      # 0xc20a
movl $0x21e, %edx            # imm = 0x21E
callq 0x4704
callq 0x958f
leaq 0x41d4(%rip), %rsi      # 0xc2f1
movq %rax, %rdi
xorl %eax, %eax
callq 0x4740
nop
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/preprocessor.c
// Function: CreateJoinedString
static char *CreateJoinedString(const char *s1, const char *s2) {
  assert(s1 && s2);
  char *s = malloc(strlen(s1) + strlen(s2) + 1);
  assert(s);
  strcpy(s, s1);
  strcat(s, s2);
  return s;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x8a2e
movq %rsi, %rbx
testq %rsi, %rsi
je 0x8a2e
movq %rdi, %r14
callq 0x2080
movq %rax, %r15
movq %rbx, %rdi
callq 0x2080
leaq (%r15,%rax), %rdi
incq %rdi
callq 0x2140
testq %rax, %rax
je 0x8a46
movq %rax, %r15
movq %rax, %rdi
movq %r14, %rsi
callq 0x2050
movq %r15, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x2190
leaq 0x3a77(%rip), %rdi      # 0xc4ac
leaq 0x38d1(%rip), %rsi      # 0xc30d
movl $0x40, %edx
callq 0x4704
leaq 0x399a(%rip), %rdi      # 0xc3e7
leaq 0x38b9(%rip), %rsi      # 0xc30d
movl $0x42, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/preprocessor.c
// Function: CreateStrFromTokenRange
static const char *CreateStrFromTokenRange(struct Node *begin,
                                           struct Node *end) {
  assert(begin);
  int len = 0;
  for (struct Node *t = begin; t && t != end; t = t->next_token) {
    len += t->length;
  }
  return strndup(begin->begin, len);
}

// Assembly:
pushq %rax
testq %rdi, %rdi
je 0x8a9c
movq %rsi, %rax
xorl %esi, %esi
cmpq %rax, %rdi
je 0x8a8f
movq %rdi, %rcx
movslq 0x120(%rcx), %rdx
movslq %esi, %rsi
addq %rdx, %rsi
movq 0x110(%rcx), %rcx
testq %rcx, %rcx
je 0x8a8f
cmpq %rax, %rcx
jne 0x8a71
movq 0x118(%rdi), %rdi
popq %rax
jmp 0x20e0
leaq 0x3a12(%rip), %rdi      # 0xc4b5
leaq 0x3863(%rip), %rsi      # 0xc30d
movl $0xc, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/preprocessor.c
// Function: PreprocessRemoveBlock
static void PreprocessRemoveBlock(void) {
  for (struct Node *t = PeekToken(); t; t = t->next_token) {
    if (!IsEqualTokenWithCStr(t, "#")) {
      continue;
    }
    t = SkipDelimiterTokensInLogicalLine(t->next_token);
    if (!IsEqualTokenWithCStr(t, "endif") && !IsEqualTokenWithCStr(t, "else")) {
      continue;
    }
    RemoveTokensTo(t);
    break;
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
callq 0x93e4
testq %rax, %rax
je 0x8b26
movq %rax, %rbx
leaq 0x383b(%rip), %r14      # 0xc30b
leaq 0x391d(%rip), %r15      # 0xc3f4
leaq 0x3911(%rip), %r12      # 0xc3ef
movq %rbx, %rdi
movq %r14, %rsi
callq 0x9278
testl %eax, %eax
je 0x8b1a
movq 0x110(%rbx), %rdi
callq 0x8998
movq %rax, %rbx
movq %rax, %rdi
movq %r15, %rsi
callq 0x9278
testl %eax, %eax
jne 0x8b32
movq %rbx, %rdi
movq %r12, %rsi
callq 0x9278
testl %eax, %eax
jne 0x8b32
movq 0x110(%rbx), %rbx
testq %rbx, %rbx
jne 0x8ade
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x95c7
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/struct.c
// Function: AddMemberOfStructFromDecl
void AddMemberOfStructFromDecl(struct Node *struct_spec, struct Node *decl) {
  struct Node *struct_member = AllocNode(kNodeStructMember);
  struct_member->struct_member_decl = decl;
  struct Node *type = CreateTypeFromDecl(decl);
  assert(type && type->left);
  const char *name = CreateTokenStr(type->left);
  struct Node *dict = struct_spec->struct_member_dict;
  PushKeyValueToList(dict, name, struct_member);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r15
movq %rdi, %rbx
movl $0x2, %edi
callq 0x3f05
movq %rax, %r14
movq %r15, 0x78(%rax)
movq %r15, %rdi
callq 0xa67c
testq %rax, %rax
je 0x8cc5
movq 0x18(%rax), %rdi
testq %rdi, %rdi
je 0x8cc5
callq 0x923f
movq 0x68(%rbx), %rdi
movq %rax, %rsi
movq %r14, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x48c1
leaq 0x381d(%rip), %rdi      # 0xc4e9
leaq 0x380d(%rip), %rsi      # 0xc4e0
movl $0x2c, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/struct.c
// Function: FindStructMember
struct Node *FindStructMember(struct Node *struct_type,
                              struct Node *key_token) {
  assert(key_token->type == kNodeToken);
  struct_type = GetTypeWithoutAttr(struct_type);
  assert(struct_type && struct_type->type == kTypeStruct);
  assert(struct_type->type_struct_spec);
  assert(struct_type->type_struct_spec->struct_member_dict);
  assert(struct_type->type_struct_spec->struct_member_dict->type == kASTList);
  return GetNodeByTokenKey(struct_type->type_struct_spec->struct_member_dict,
                           key_token);
}

// Assembly:
pushq %rbx
cmpl $0x1, (%rsi)
jne 0x8d30
movq %rsi, %rbx
callq 0xa104
testq %rax, %rax
je 0x8d18
cmpl $0x19, (%rax)
jne 0x8d18
movq 0xf0(%rax), %rax
testq %rax, %rax
je 0x8d48
movq 0x68(%rax), %rdi
testq %rdi, %rdi
je 0x8d60
cmpl $0x6, (%rdi)
jne 0x8d78
movq %rbx, %rsi
popq %rbx
jmp 0x49a2
leaq 0x37fb(%rip), %rdi      # 0xc51a
leaq 0x37ba(%rip), %rsi      # 0xc4e0
movl $0x36, %edx
callq 0x4704
leaq 0x37c5(%rip), %rdi      # 0xc4fc
leaq 0x37a2(%rip), %rsi      # 0xc4e0
movl $0x34, %edx
callq 0x4704
leaq 0x37fb(%rip), %rdi      # 0xc54a
leaq 0x378a(%rip), %rsi      # 0xc4e0
movl $0x37, %edx
callq 0x4704
leaq 0x3801(%rip), %rdi      # 0xc568
leaq 0x3772(%rip), %rsi      # 0xc4e0
movl $0x38, %edx
callq 0x4704
leaq 0x381b(%rip), %rdi      # 0xc59a
leaq 0x375a(%rip), %rsi      # 0xc4e0
movl $0x39, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: GetLastLocalVarOffset
int GetLastLocalVarOffset(struct SymbolEntry *e) {
  for (; e; e = e->prev) {
    if (e->type != kSymbolLocalVar) continue;
    assert(e->value && e->value->type == kASTLocalVar);
    return e->value->byte_offset;
  }
  return 0;
}

// Assembly:
pushq %rax
xorl %eax, %eax
testq %rdi, %rdi
je 0x8dd3
cmpl $0x0, (%rdi)
je 0x8dbf
movq 0x8(%rdi), %rdi
jmp 0x8daf
movq 0x18(%rdi), %rax
testq %rax, %rax
je 0x8dd5
cmpl $0x12, (%rax)
jne 0x8dd5
movl 0xa8(%rax), %eax
popq %rcx
retq
leaq 0x3863(%rip), %rdi      # 0xc63f
leaq 0x3887(%rip), %rsi      # 0xc66a
movl $0x15, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: AddLocalVar
struct Node *AddLocalVar(struct SymbolEntry **ctx, const char *key,
                         struct Node *var_type) {
  assert(ctx);
  int ofs = GetLastLocalVarOffset(*ctx);
  ofs += GetSizeOfType(var_type);
  int align = GetSizeOfType(var_type);
  ofs = (ofs + align - 1) / align * align;
  struct Node *local_var = CreateASTLocalVar(ofs, var_type);
  struct SymbolEntry *e = AllocSymbolEntry(kSymbolLocalVar, key, local_var);
  PushSymbol(ctx, e);
  return local_var;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rdi, %rdi
je 0x8e70
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %rdi
callq 0x8dac
movl %eax, %ebp
movq %r15, %rdi
callq 0xa222
movl %eax, %r12d
addl %ebp, %r12d
movq %r15, %rdi
callq 0xa222
movl %eax, %ecx
leal (%rcx,%r12), %edi
decl %edi
movl %edi, %eax
cltd
idivl %ecx
subl %edx, %edi
movq %r15, %rsi
callq 0x418d
movq %rax, %r15
movl $0x1, %edi
movl $0x20, %esi
callq 0x20f0
movl $0x0, (%rax)
movq %r14, 0x10(%rax)
movq %r15, 0x18(%rax)
movq (%rbx), %rcx
movq %rcx, 0x8(%rax)
movq %rax, (%rbx)
movq %r15, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x37fc(%rip), %rdi      # 0xc673
leaq 0x37ec(%rip), %rsi      # 0xc66a
movl $0x1d, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: FindExternVar
struct Node *FindExternVar(struct SymbolEntry *e, struct Node *key_token) {
  // returns ASTNode which represents Type
  for (; e; e = e->prev) {
    if (e->type != kSymbolExternVar) continue;
    if (!IsEqualTokenWithCStr(key_token, e->key)) continue;
    return e->value;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x8ebb
movq %rsi, %r15
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0x2, (%r14)
jne 0x8eb0
movq 0x10(%r14), %rsi
movq %r15, %rdi
callq 0x9278
testl %eax, %eax
jne 0x8ebf
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x8e9a
jmp 0x8ec3
xorl %ebx, %ebx
jmp 0x8ec3
movq 0x18(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: FindGlobalVar
struct Node *FindGlobalVar(struct SymbolEntry *e, struct Node *key_token) {
  // returns ASTNode which represents Type
  for (; e; e = e->prev) {
    if (e->type != kSymbolGlobalVar) continue;
    if (!IsEqualTokenWithCStr(key_token, e->key)) continue;
    return e->value;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x8eff
movq %rsi, %r15
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0x1, (%r14)
jne 0x8ef4
movq 0x10(%r14), %rsi
movq %r15, %rdi
callq 0x9278
testl %eax, %eax
jne 0x8f03
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x8ede
jmp 0x8f07
xorl %ebx, %ebx
jmp 0x8f07
movq 0x18(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: FindLocalVar
struct Node *FindLocalVar(struct SymbolEntry *e, struct Node *key_token) {
  for (; e; e = e->prev) {
    if (e->type != kSymbolLocalVar) continue;
    if (!IsEqualTokenWithCStr(key_token, e->key)) continue;
    return e->value;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x8f43
movq %rsi, %r15
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0x0, (%r14)
jne 0x8f38
movq 0x10(%r14), %rsi
movq %r15, %rdi
callq 0x9278
testl %eax, %eax
jne 0x8f47
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x8f22
jmp 0x8f4b
xorl %ebx, %ebx
jmp 0x8f4b
movq 0x18(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: FindFuncDef
struct Node *FindFuncDef(struct SymbolEntry *e, struct Node *key_token) {
  for (; e; e = e->prev) {
    if (e->type != kSymbolFuncDef) continue;
    if (!IsEqualTokenWithCStr(key_token, e->key)) continue;
    return e->value;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x8fdf
movq %rsi, %r15
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0x3, (%r14)
jne 0x8fd4
movq 0x10(%r14), %rsi
movq %r15, %rdi
callq 0x9278
testl %eax, %eax
jne 0x8fe3
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x8fbe
jmp 0x8fe7
xorl %ebx, %ebx
jmp 0x8fe7
movq 0x18(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: FindFuncDeclType
struct Node *FindFuncDeclType(struct SymbolEntry *e, struct Node *key_token) {
  for (; e; e = e->prev) {
    if (e->type != kSymbolFuncDeclType) continue;
    if (!IsEqualTokenWithCStr(key_token, e->key)) continue;
    return e->value;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x907b
movq %rsi, %r15
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0x4, (%r14)
jne 0x9070
movq 0x10(%r14), %rsi
movq %r15, %rdi
callq 0x9278
testl %eax, %eax
jne 0x907f
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x905a
jmp 0x9083
xorl %ebx, %ebx
jmp 0x9083
movq 0x18(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: AddStructType
void AddStructType(struct SymbolEntry **ctx, const char *key,
                   struct Node *type) {
  assert(ctx);
  struct SymbolEntry *e = AllocSymbolEntry(kSymbolStructType, key, type);
  PushSymbol(ctx, e);
  PrintASTNode(type);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x90d3
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movl $0x1, %edi
movl $0x20, %esi
callq 0x20f0
movl $0x5, (%rax)
movq %r15, 0x10(%rax)
movq %rbx, 0x18(%rax)
movq (%r14), %rcx
movq %rcx, 0x8(%rax)
movq %rax, (%r14)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x440e
leaq 0x3599(%rip), %rdi      # 0xc673
leaq 0x3589(%rip), %rsi      # 0xc66a
movl $0x7a, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/symbol.c
// Function: FindStructType
struct Node *FindStructType(struct SymbolEntry *e, struct Node *key_token) {
  for (; e; e = e->prev) {
    if (e->type != kSymbolStructType) continue;
    if (!IsEqualTokenWithCStr(key_token, e->key)) continue;
    return e->value;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x911e
movq %rsi, %r15
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0x5, (%r14)
jne 0x9113
movq 0x10(%r14), %rsi
movq %r15, %rdi
callq 0x9278
testl %eax, %eax
jne 0x9122
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x90fd
jmp 0x9126
xorl %ebx, %ebx
jmp 0x9126
movq 0x18(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: AllocToken
struct Node *AllocToken(const char *src_str, int line, const char *begin,
                        int length, enum TokenType type) {
  struct Node *t = AllocNode(kNodeToken);
  t->begin = begin;
  t->length = length;
  t->token_type = type;
  t->src_str = src_str;
  t->line = line;
  return t;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r8d, %ebx
movl %ecx, %ebp
movq %rdx, %r14
movl %esi, %r15d
movq %rdi, %r12
movl $0x1, %edi
callq 0x3f05
movq %r14, 0x118(%rax)
movl %ebp, 0x120(%rax)
movl %ebx, 0x108(%rax)
movq %r12, 0x128(%rax)
movl %r15d, 0x130(%rax)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: DuplicateToken
struct Node *DuplicateToken(struct Node *base_token) {
  assert(IsToken(base_token));
  struct Node *t = AllocNode(kNodeToken);
  memcpy(t, base_token, sizeof(*t));
  t->next_token = NULL;
  return t;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x91e4
movq %rdi, %rbx
cmpl $0x1, (%rdi)
jne 0x91e4
movl $0x1, %edi
callq 0x3f05
movq %rax, %r14
movl $0x138, %edx            # imm = 0x138
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2130
movq $0x0, 0x110(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x34a2(%rip), %rdi      # 0xc68d
leaq 0x34af(%rip), %rsi      # 0xc6a1
movl $0x15, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: DuplicateTokenSequence
struct Node *DuplicateTokenSequence(struct Node *base_head) {
  struct Node *dup_head = NULL;
  struct Node **dup_head_holder = &dup_head;
  while (base_head) {
    *dup_head_holder = DuplicateToken(base_head);
    dup_head_holder = &(*dup_head_holder)->next_token;
    base_head = base_head->next_token;
  }
  return dup_head;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq $0x0, (%rsp)
testq %rdi, %rdi
je 0x9233
movq %rdi, %rbx
movq %rsp, %r14
movq %rbx, %rdi
callq 0x91a0
movq %rax, (%r14)
addq $0x110, %rax            # imm = 0x110
movq 0x110(%rbx), %rbx
movq %rax, %r14
testq %rbx, %rbx
jne 0x9213
movq (%rsp), %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: PrintTokenSequence
void PrintTokenSequence(struct Node *t) {
  if (!t) return;
  assert(IsToken(t));
  for (; t; t = t->next_token) {
    if (t->token_type == kTokenZeroWidthNoBreakSpace) {
      continue;
    }
    fprintf(stderr, "%.*s", t->length, t->begin);
  }
}

// Assembly:
pushq %rbx
testq %rdi, %rdi
je 0x9309
movq %rdi, %rbx
cmpl $0x1, (%rdi)
je 0x92f4
leaq 0x20d3(%rip), %rdi      # 0xb3ac
leaq 0x33c1(%rip), %rsi      # 0xc6a1
movl $0x33, %edx
callq 0x4704
movq %rbx, %rdi
callq 0x2df8
jmp 0x92fd
cmpl $0x2, 0x108(%rbx)
jne 0x92ea
movq 0x110(%rbx), %rbx
testq %rbx, %rbx
jne 0x92f4
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: OutputTokenSequenceAsCSource
void OutputTokenSequenceAsCSource(struct Node *t) {
  if (!t) return;
  assert(IsToken(t));
  for (; t; t = t->next_token) {
    if (t->token_type == kTokenZeroWidthNoBreakSpace) {
      continue;
    }
    fprintf(stdout, "%.*s", t->length, t->begin);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x935a
movq %rdi, %rbx
cmpl $0x1, (%rdi)
jne 0x9360
movq 0x7cac(%rip), %r15      # 0x10fd0
leaq 0x337e(%rip), %r14      # 0xc6a9
cmpl $0x2, 0x108(%rbx)
je 0x934e
movq (%r15), %rdi
movl 0x120(%rbx), %edx
movq 0x118(%rbx), %rcx
movq %r14, %rsi
xorl %eax, %eax
callq 0x2110
movq 0x110(%rbx), %rbx
testq %rbx, %rbx
jne 0x932b
popq %rbx
popq %r14
popq %r15
retq
leaq 0x2045(%rip), %rdi      # 0xb3ac
leaq 0x3333(%rip), %rsi      # 0xc6a1
movl $0x3e, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: PrintTokenBrief
void PrintTokenBrief(struct Node *t) {
  assert(t);
  if (t->token_type == kTokenStringLiteral ||
      t->token_type == kTokenCharLiteral) {
    fprintf(stderr, "%.*s", t->length, t->begin);
    return;
  }
  fprintf(stderr, "<%.*s>", t->length, t->begin);
}

// Assembly:
pushq %rax
testq %rdi, %rdi
je 0x9385
callq 0x2e20
popq %rax
retq
leaq 0x320c(%rip), %rdi      # 0xc598
leaq 0x330e(%rip), %rsi      # 0xc6a1
movl $0x4c, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: ConsumeToken
struct Node *ConsumeToken(enum TokenType type) {
  struct Node *t = *next_token_holder;
  if (!t || !IsTokenWithType(t, type)) return NULL;
  AdvanceTokenStream();
  return t;
}

// Assembly:
movq 0x7f50(%rip), %rax      # 0x11388
movq (%rax), %rax
testq %rax, %rax
je 0x945c
cmpl $0x1, (%rax)
jne 0x945c
cmpl %edi, 0x108(%rax)
jne 0x945c
leaq 0x110(%rax), %rcx
movq %rcx, 0x7f2d(%rip)      # 0x11388
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: ConsumeTokenStr
struct Node *ConsumeTokenStr(const char *s) {
  struct Node *t = *next_token_holder;
  if (!t || !IsEqualTokenWithCStr(t, s)) return NULL;
  AdvanceTokenStream();
  return t;
}

// Assembly:
pushq %rbx
movq 0x7f21(%rip), %rax      # 0x11388
movq (%rax), %rbx
testq %rbx, %rbx
je 0x948e
movq %rdi, %rsi
movq %rbx, %rdi
callq 0x9278
testl %eax, %eax
je 0x948e
leaq 0x110(%rbx), %rax
movq %rax, 0x7efc(%rip)      # 0x11388
jmp 0x9490
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: ExpectTokenStr
struct Node *ExpectTokenStr(const char *s) {
  struct Node *t = *next_token_holder;
  if (!t) Error("Expect token %s but got EOF", s);
  if (!ConsumeTokenStr(s)) ErrorWithToken(t, "Expected token %s here", s);
  return t;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x7ee5(%rip), %rax      # 0x11388
movq (%rax), %r14
testq %r14, %r14
je 0x94d3
movq %r14, %rdi
movq %rbx, %rsi
callq 0x9278
testl %eax, %eax
je 0x94e4
leaq 0x110(%r14), %rax
movq %rax, 0x7ec0(%rip)      # 0x11388
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x3214(%rip), %rdi      # 0xc6ee
movq %rbx, %rsi
xorl %eax, %eax
callq 0x4630
leaq 0x321f(%rip), %rsi      # 0xc70a
movq %r14, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x4740
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: ConsumePunctuator
struct Node *ConsumePunctuator(const char *s) {
  struct Node *t = *next_token_holder;
  if (!t || !IsTokenWithType(t, kTokenPunctuator) ||
      !IsEqualTokenWithCStr(t, s))
    return NULL;
  AdvanceTokenStream();
  return t;
}

// Assembly:
pushq %rbx
movq 0x7e88(%rip), %rax      # 0x11388
movq (%rax), %rbx
testq %rbx, %rbx
je 0x9535
cmpl $0x1, (%rbx)
jne 0x9535
cmpl $0x19, 0x108(%rbx)
jne 0x9535
movq %rdi, %rsi
movq %rbx, %rdi
callq 0x9278
testl %eax, %eax
je 0x9535
leaq 0x110(%rbx), %rax
movq %rax, 0x7e55(%rip)      # 0x11388
jmp 0x9537
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: ExpectPunctuator
struct Node *ExpectPunctuator(const char *s) {
  struct Node *t = *next_token_holder;
  if (!t) Error("Expect token %s but got EOF", s);
  if (!ConsumePunctuator(s)) ErrorWithToken(t, "Expected token %s here", s);
  return t;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x7e3e(%rip), %rax      # 0x11388
movq (%rax), %r14
testq %r14, %r14
je 0x956a
movq %rbx, %rdi
callq 0x94f8
testq %rax, %rax
je 0x957b
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x317d(%rip), %rdi      # 0xc6ee
movq %rbx, %rsi
xorl %eax, %eax
callq 0x4630
leaq 0x3188(%rip), %rsi      # 0xc70a
movq %r14, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x4740
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: InsertTokens
void InsertTokens(struct Node *seq_first) {
  // Insert token sequece (seq) at current cursor pos.
  if (!IsToken(seq_first)) return;
  struct Node *seq_last = seq_first;
  while (seq_last->next_token) seq_last = seq_last->next_token;
  seq_last->next_token = PeekToken();
  *next_token_holder = seq_first;
}

// Assembly:
pushq %rax
testq %rdi, %rdi
je 0x962e
cmpl $0x1, (%rdi)
jne 0x962e
movq %rdi, %rcx
movq %rcx, %rax
movq 0x110(%rcx), %rcx
testq %rcx, %rcx
jne 0x9606
movq 0x7d6c(%rip), %rcx      # 0x11388
testq %rcx, %rcx
je 0x9630
movq (%rcx), %rdx
movq %rdx, 0x110(%rax)
movq %rdi, (%rcx)
popq %rax
retq
leaq 0x30a5(%rip), %rdi      # 0xc6dc
leaq 0x3063(%rip), %rsi      # 0xc6a1
movl $0x6d, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/token.c
// Function: RemoveDelimiterTokens
struct Node **RemoveDelimiterTokens(struct Node **head_holder) {
  InitTokenStream(head_holder);
  for (;;) {
    struct Node *t = PeekToken();
    if (!t) break;
    if (ShouldRemoveToken(t)) {
      RemoveCurrentToken();
      continue;
    }
    AdvanceTokenStream();
  }
  return head_holder;
}

// Assembly:
pushq %rax
testq %rdi, %rdi
je 0x98e4
movq %rdi, 0x7adf(%rip)      # 0x11388
movq %rdi, %rax
movq (%rax), %rcx
testq %rcx, %rcx
je 0x98df
movl 0x108(%rcx), %esi
decl %esi
leaq 0x110(%rcx), %rdx
cmpl $0x1, %esi
ja 0x98d0
movq (%rdx), %rdx
movq %rdx, (%rax)
jmp 0x98da
movq %rdx, 0x7ab1(%rip)      # 0x11388
movq %rdx, %rax
testq %rcx, %rcx
jne 0x98ac
movq %rdi, %rax
popq %rcx
retq
leaq 0x2ddf(%rip), %rdi      # 0xc6ca
leaq 0x2daf(%rip), %rsi      # 0xc6a1
movl $0x63, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/tokenizer.c
// Function: Tokenize
struct Node *Tokenize(const char *input) {
  // returns head of tokens.
  struct Node *token_head = NULL;
  struct Node **last_next_token = &token_head;
  const char *p = input;
  struct Node *t;
  int line = 1;
  while ((t = CreateNextToken(p, input, &line))) {
    *last_next_token = t;
    last_next_token = &t->next_token;
    p = t->begin + t->length;
  }
  return token_head;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq $0x0, 0x8(%rsp)
leaq 0x4(%rsp), %rdx
movl $0x1, (%rdx)
movq %rdi, %rsi
callq 0x9912
testq %rax, %rax
je 0x9f7b
leaq 0x8(%rsp), %r15
leaq 0x4(%rsp), %r14
movq %rax, (%r15)
leaq 0x110(%rax), %r15
movslq 0x120(%rax), %rdi
addq 0x118(%rax), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x9912
testq %rax, %rax
jne 0x9f53
movq 0x8(%rsp), %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/type.c
// Function: IsSameTypeExceptAttr
int IsSameTypeExceptAttr(struct Node *a, struct Node *b) {
  assert(a && b);
  a = GetTypeWithoutAttr(a);
  b = GetTypeWithoutAttr(b);
  if (a->type != b->type) return 0;
  if (a->type == kTypeBase) {
    assert(a->op && b->op);
    return a->op->type == b->op->type;
  } else if (a->type == kTypePointer) {
    return IsSameTypeExceptAttr(a->right, b->right);
  } else if (a->type == kTypeFunction) {
    if (!IsSameTypeExceptAttr(a->left, b->left)) return 0;
    if (GetSizeOfList(a->right) != GetSizeOfList(b->right)) return 0;
    for (int i = 0; i < GetSizeOfList(a->right); i++) {
      if (!IsSameTypeExceptAttr(GetNodeAt(a->right, i), GetNodeAt(b->right, i)))
        return 0;
    }
    return 1;
  }
  Error("IsSameTypeExceptAttr: Comparing non-type nodes");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
xorl %ebp, %ebp
testq %rdi, %rdi
je 0xa0c6
testq %rbx, %rbx
je 0xa0c6
callq 0xa104
movq %rax, %r14
movq %rbx, %rdi
callq 0xa104
movq %rax, %rbx
movl (%r14), %eax
cmpl (%rbx), %eax
jne 0xa0bb
cmpl $0x16, %eax
jne 0x9fd8
movq 0x20(%r14), %rdi
movq 0x20(%rbx), %rbx
jmp 0x9f99
cmpl $0x17, %eax
je 0xa00f
cmpl $0x14, %eax
jne 0xa0de
movq 0x10(%r14), %rax
testq %rax, %rax
je 0xa0ec
movq 0x10(%rbx), %rcx
testq %rcx, %rcx
je 0xa0ec
movl (%rax), %eax
xorl %ebp, %ebp
cmpl (%rcx), %eax
sete %bpl
jmp 0xa0bb
movq 0x18(%r14), %rdi
movq 0x18(%rbx), %rsi
callq 0x9f8c
testl %eax, %eax
je 0xa0bb
movq 0x20(%r14), %rdi
callq 0x4922
movl %eax, %r15d
movq 0x20(%rbx), %rdi
callq 0x4922
cmpl %eax, %r15d
jne 0xa0bb
movq 0x20(%r14), %rdi
callq 0x4922
testl %eax, %eax
setle %r12b
jle 0xa0b7
movq 0x20(%r14), %rdi
xorl %esi, %esi
callq 0x494c
movq %rax, %r15
movq 0x20(%rbx), %rdi
xorl %esi, %esi
callq 0x494c
movq %r15, %rdi
movq %rax, %rsi
callq 0x9f8c
testl %eax, %eax
je 0xa0b7
movl $0x1, %ebp
movq 0x20(%r14), %rdi
callq 0x4922
cmpl %eax, %ebp
setge %r12b
jge 0xa0b7
movq 0x20(%r14), %rdi
movl %ebp, %esi
callq 0x494c
movq %rax, %r15
movq 0x20(%rbx), %rdi
movl %ebp, %esi
callq 0x494c
movq %r15, %rdi
movq %rax, %rsi
callq 0x9f8c
incl %ebp
testl %eax, %eax
jne 0xa07c
movzbl %r12b, %ebp
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x27cb(%rip), %rdi      # 0xc898
leaq 0x27cb(%rip), %rsi      # 0xc89f
movl $0x4, %edx
callq 0x4704
leaq 0x27d0(%rip), %rdi      # 0xc8b5
xorl %eax, %eax
callq 0x4630
leaq 0x27b3(%rip), %rdi      # 0xc8a6
leaq 0x27a5(%rip), %rsi      # 0xc89f
movl $0x9, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/type.c
// Function: EvalExprAsInt
int EvalExprAsInt(struct Node *n) {
  assert(n);
  if (IsTokenWithType(n->op, kTokenIntegerConstant)) {
    return strtol(n->op->begin, NULL, 0);
  }
  if (n->type == kASTExpr && IsEqualTokenWithCStr(n->op, "+")) {
    return EvalExprAsInt(n->left) + EvalExprAsInt(n->right);
  }
  assert(false);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
xorl %ebp, %ebp
leaq 0x100e(%rip), %r14      # 0xb1a8
testq %rbx, %rbx
je 0xa20a
movq 0x10(%rbx), %rdi
movl $0x3, %esi
callq 0x913f
testb %al, %al
jne 0xa1d7
cmpl $0x4, (%rbx)
jne 0xa1f2
movq 0x10(%rbx), %rdi
movq %r14, %rsi
callq 0x9278
testl %eax, %eax
je 0xa1f2
movq 0x18(%rbx), %rdi
callq 0xa18a
movq 0x20(%rbx), %rbx
addl %eax, %ebp
jmp 0xa19a
movq 0x10(%rbx), %rax
movq 0x118(%rax), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x2120
addl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
leaq 0xe8e(%rip), %rdi       # 0xb087
leaq 0x269f(%rip), %rsi      # 0xc89f
movl $0x3a, %edx
callq 0x4704
leaq 0x2307(%rip), %rdi      # 0xc518
leaq 0x2687(%rip), %rsi      # 0xc89f
movl $0x33, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/type.c
// Function: GetSizeOfType
int GetSizeOfType(struct Node *t) {
  t = GetTypeWithoutAttr(t);
  assert(t);
  if (t->type == kTypeBase) {
    assert(IsToken(t->op));
    switch (t->op->token_type) {
      case kTokenKwInt:
      case kTokenKwLong:
        return 4;
      case kTokenKwChar:
        return 1;
      case kTokenKwVoid:
        return 0;
      default:
        PrintASTNode(t->op);
        assert(false);
    }
  } else if (t->type == kTypePointer) {
    return 8;
  } else if (t->type == kTypeStruct) {
    if (!t->type_struct_spec) {
      ErrorWithToken(t->tag, "Cannot take sizeof incomplete struct");
    }
    return CalcStructSize(t->type_struct_spec);
  } else if (t->type == kTypeArray) {
    return GetSizeOfType(t->type_array_type_of) *
           EvalExprAsInt(t->type_array_index_decl);
  }
  PrintASTNode(t);
  assert(false);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
callq 0xa104
testq %rax, %rax
je 0xa2d7
movq %rax, %rbx
movl (%rax), %eax
addl $-0x14, %eax
cmpl $0x6, %eax
ja 0xa2ef
leaq 0x2631(%rip), %rcx      # 0xc87c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq 0x10(%rbx), %rdi
callq 0x9130
testb %al, %al
je 0xa324
movq 0x10(%rbx), %rdi
movl 0x108(%rdi), %ecx
movl $0x4, %eax
leal -0xd(%rcx), %edx
cmpl $0x2, %edx
jb 0xa2cc
cmpl $0x15, %ecx
je 0xa2d3
cmpl $0x6, %ecx
jne 0xa33c
movl $0x1, %eax
jmp 0xa2cc
movq 0xf0(%rbx), %rdi
testq %rdi, %rdi
je 0xa30f
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x8b48
movq 0xf8(%rbx), %rdi
callq 0xa222
movl %eax, %ebp
movq 0x100(%rbx), %rdi
callq 0xa18a
imull %ebp, %eax
jmp 0xa2cc
movl $0x8, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
xorl %eax, %eax
jmp 0xa2cc
leaq 0x22ba(%rip), %rdi      # 0xc598
leaq 0x25ba(%rip), %rsi      # 0xc89f
movl $0x3f, %edx
callq 0x4704
movq %rbx, %rdi
callq 0x440e
leaq 0xd89(%rip), %rdi       # 0xb087
leaq 0x259a(%rip), %rsi      # 0xc89f
movl $0x5a, %edx
callq 0x4704
movq 0xe8(%rbx), %rdi
leaq 0x25e1(%rip), %rsi      # 0xc8fe
xorl %eax, %eax
callq 0x4740
leaq 0x25c4(%rip), %rdi      # 0xc8ef
leaq 0x256d(%rip), %rsi      # 0xc89f
movl $0x41, %edx
callq 0x4704
callq 0x440e
leaq 0xd3f(%rip), %rdi       # 0xb087
leaq 0x2550(%rip), %rsi      # 0xc89f
movl $0x4c, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/hikalium[P]compilium/type.c
// Function: GetAlignOfType
int GetAlignOfType(struct Node *t) {
  t = GetTypeWithoutAttr(t);
  assert(t);
  if (t->type == kTypeBase) {
    assert(IsToken(t->op));
    switch (t->op->token_type) {
      case kTokenKwInt:
        return 4;
      case kTokenKwChar:
        return 1;
      default:
        assert(false);
    }
  } else if (t->type == kTypePointer) {
    return 8;
  } else if (t->type == kTypeStruct) {
    return CalcStructAlign(t->type_struct_spec);
  }
  PrintASTNode(t);
  assert(false);
}

// Assembly:
pushq %rbx
callq 0xa104
testq %rax, %rax
je 0xa3b7
movq %rax, %rbx
movl (%rax), %ecx
cmpl $0x19, %ecx
je 0xa3aa
movl $0x8, %eax
cmpl $0x16, %ecx
je 0xa3a8
cmpl $0x14, %ecx
jne 0xa3cf
movq 0x10(%rbx), %rdi
callq 0x9130
testb %al, %al
je 0xa3ef
movq 0x10(%rbx), %rax
movl 0x108(%rax), %ecx
movl $0x4, %eax
cmpl $0xd, %ecx
je 0xa3a8
cmpl $0x6, %ecx
jne 0xa407
movl $0x1, %eax
popq %rbx
retq
movq 0xf0(%rbx), %rdi
popq %rbx
jmp 0x8baf
leaq 0x21da(%rip), %rdi      # 0xc598
leaq 0x24da(%rip), %rsi      # 0xc89f
movl $0x5f, %edx
callq 0x4704
movq %rbx, %rdi
callq 0x440e
leaq 0xca9(%rip), %rdi       # 0xb087
leaq 0x24ba(%rip), %rsi      # 0xc89f
movl $0x70, %edx
callq 0x4704
leaq 0x24f9(%rip), %rdi      # 0xc8ef
leaq 0x24a2(%rip), %rsi      # 0xc89f
movl $0x61, %edx
callq 0x4704
leaq 0xc79(%rip), %rdi       # 0xb087
leaq 0x248a(%rip), %rsi      # 0xc89f
movl $0x68, %edx
callq 0x4704
// File: /workspace/github_c_makefile_star2_O1/jiribenes[P]scheme/src/core.c
// Function: arity_check
bool arity_check(vm_t *vm, const char *fn_name, value_t args, int n,
                 bool at_least) {
    int argc = cons_len(args);
    if (!at_least) {  // exactly
        if (argc != n) {
            error_runtime(vm, "%s: not enough args: %d expected, %d given!",
                          fn_name, n, argc);
            return false;
        }
    } else {  // at least
        if (argc < n) {
            error_runtime(vm, "%s: not enough args: >= %d expected, %d given!",
                          fn_name, n, argc);
            return false;
        }
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %r8d, %ebp
movl %ecx, %ebx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x4bae
testl %ebp, %ebp
je 0x13aa
movb $0x1, %bpl
cmpl %ebx, %eax
jge 0x13cc
leaq 0x5ccc(%rip), %rsi      # 0x7074
jmp 0x13b8
movb $0x1, %bpl
cmpl %ebx, %eax
je 0x13cc
leaq 0x5c90(%rip), %rsi      # 0x7048
xorl %ebp, %ebp
movq %r15, %rdi
movq %r14, %rdx
movl %ebx, %ecx
movl %eax, %r8d
xorl %eax, %eax
callq 0x4e18
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jiribenes[P]scheme/src/core.c
// Function: eq
static value_t eq(vm_t *vm, env_t *env, value_t args) {
    if (IS_NIL(args)) {
        return TRUE_VAL;
    }
    value_t eargs = eval_list(vm, env, args);
    value_t prev = NIL_VAL;
    value_t arg, iter;
    SCM_FOREACH (arg, AS_CONS(eargs), iter) {
        if (!IS_NIL(prev)) {
            // if we find a pair where the 'eq?' relation doesn't hold,
            // return false
            if (!val_eq(prev, arg)) {
                return FALSE_VAL;
            }
        }
        prev = arg;
    }
    return TRUE_VAL;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movabsq $0x7ffc000000000001, %r14 # imm = 0x7FFC000000000001
leaq 0x1(%r14), %rbx
cmpq %r14, %rdx
je 0x202c
callq 0x5568
movabsq $0x3ffffffffffff, %rdx  # imm = 0x3FFFFFFFFFFFF
leaq 0x2(%r14), %rcx
movq %r14, %rdi
andq %rdx, %rax
movq 0x10(%rax), %rsi
cmpq %r14, %rdi
sete %r8b
cmpq %rsi, %rdi
sete %dil
orb %r8b, %dil
cmpb $0x1, %dil
jne 0x2029
movq 0x18(%rax), %rax
movq %rsi, %rdi
cmpq %r14, %rax
jne 0x1ffd
jmp 0x202c
movq %rcx, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jiribenes[P]scheme/src/core.c
// Function: equal
static value_t equal(vm_t *vm, env_t *env, value_t args) {
    if (IS_NIL(args)) {
        return TRUE_VAL;
    }
    value_t eargs = eval_list(vm, env, args);
    value_t prev = NIL_VAL;
    value_t arg, iter;
    SCM_FOREACH (arg, AS_CONS(eargs), iter) {
        if (!IS_NIL(prev)) {
            // if we find a pair where the 'equal?' relation doesn't hold,
            // return false
            if (!val_equal(prev, arg)) {
                return FALSE_VAL;
            }
        }
        prev = arg;
    }
    return TRUE_VAL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movabsq $0x7ffc000000000001, %r12 # imm = 0x7FFC000000000001
leaq 0x1(%r12), %rbx
cmpq %r12, %rdx
je 0x2099
callq 0x5568
movq %rax, %r14
movabsq $0x3ffffffffffff, %rbp  # imm = 0x3FFFFFFFFFFFF
leaq 0x2(%r12), %r13
movq %r12, %rdi
andq %rbp, %r14
movq 0x10(%r14), %r15
cmpq %r12, %rdi
je 0x2088
movq %r15, %rsi
callq 0x4cbf
testb %al, %al
je 0x2096
movq 0x18(%r14), %r14
movq %r15, %rdi
cmpq %r12, %r14
jne 0x2070
jmp 0x2099
movq %r13, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jiribenes[P]scheme/src/core.c
// Function: builtin_define
static value_t builtin_define(vm_t *vm, env_t *env, value_t args) {
    cons_t *rest = AS_CONS(args);

    if (IS_SYMBOL(rest->car)) {  // (define <name> <body>)
        symbol_t *sym = AS_SYMBOL(rest->car);
        value_t body = AS_CONS(rest->cdr)->car;
        value_t val = eval(vm, env, body);

        if (IS_FUNCTION(val)) {
            // If <body> is a nameless function, set its name to <name>
            // (we won't do any renaming...)
            function_t *func = AS_FUNCTION(val);
            if (func->name == NULL) {
                func->name = sym;
            }
        }
        variable_add(vm, env, sym, val);

        return VOID_VAL;
    } else if (IS_CONS(rest->car)) {  // (define (<name> <params...>) <body...>)
        symbol_t *sym = AS_SYMBOL(AS_CONS(rest->car)->car);
        value_t params = AS_CONS(rest->car)->cdr;
        cons_t *body = AS_CONS(rest->cdr);

        function_t *func = function_new(vm, env, params, PTR_VAL(body));
        func->name = sym;

        variable_add(vm, env, sym, PTR_VAL(func));

        return VOID_VAL;
    } else {
        error_runtime(vm, "define: is wrong - first argument has to be"
                          "either a list or a symbol!");
        return NIL_VAL;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movabsq $0x7ffc000000000005, %rbx # imm = 0x7FFC000000000005
movabsq $0x3ffffffffffff, %r12  # imm = 0x3FFFFFFFFFFFF
andq %r12, %rdx
movq 0x10(%rdx), %rax
movq %rax, %rcx
shrq $0x32, %rcx
cmpl $0x3fff, %ecx           # imm = 0x3FFF
jb 0x2571
movq %rsi, %r15
movabsq $-0x4000000000001, %r13 # imm = 0xFFFBFFFFFFFFFFFF
movq %rax, %rbp
andq %r12, %rbp
cmpl $0x2, (%rbp)
jne 0x2566
movq 0x18(%rdx), %rax
andq %r12, %rax
movq 0x10(%rax), %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x5781
cmpq %r13, %rax
jbe 0x2553
movq %rax, %rcx
andq %r12, %rcx
cmpl $0x4, (%rcx)
jne 0x2553
cmpq $0x0, 0x10(%rcx)
jne 0x2553
movq %rbp, 0x10(%rcx)
movq %r14, %rdi
movq %r15, %rsi
movq %rbp, %rdx
movq %rax, %rcx
callq 0x529e
jmp 0x2586
cmpq %r13, %rax
jbe 0x2571
cmpl $0x0, (%rbp)
je 0x2598
leaq 0x4de3(%rip), %rsi      # 0x735b
movq %r14, %rdi
xorl %eax, %eax
callq 0x4e18
addq $-0x4, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
andq 0x10(%rbp), %r12
movq 0x18(%rbp), %rax
incq %r13
movq 0x18(%rdx), %rcx
orq %r13, %rcx
movq %r14, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x49a5
movq %r12, 0x10(%rax)
orq %rax, %r13
movq %r14, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %r13, %rcx
jmp 0x255f
// File: /workspace/github_c_makefile_star2_O1/jiribenes[P]scheme/src/core.c
// Function: lambda
static value_t lambda(vm_t *vm, env_t *env, value_t args) {
    // (lambda (<params...>) <body...>)

    if (IS_NIL(AS_CONS(args)->car)) {
        // no parameters -> (lambda () <body...>)
        value_t body = AS_CONS(args)->cdr;
        function_t *func = function_new(vm, env, NIL_VAL, body);
        return PTR_VAL(func);
    }

    if (IS_SYMBOL(AS_CONS(args)->car)) {
        // variadic -> (lambda param <body...>)
        value_t param = AS_CONS(args)->car;
        value_t body = AS_CONS(args)->cdr;
        function_t *func = function_new(vm, env, param, body);
        return PTR_VAL(func);
    }

    // TODO: Rewrite using SCM_FOREACH macro
    for (cons_t *cons = AS_CONS(AS_CONS(args)->car);;
         cons = AS_CONS(cons->cdr)) {
        if (!IS_CONS(cons->cdr) && !IS_NIL(cons->cdr) && IS_SYMBOL(cons->cdr)) {
            // variadic (lambda (a b . rest) <body...>)
            break;
        }

        if (!IS_SYMBOL(cons->car)) {
            error_runtime(vm, "lambda: all parameters must be symbols!");
            return NIL_VAL;
        }


        if (IS_NIL(cons->cdr)) {
            break;
        }
    }

    value_t params = AS_CONS(args)->car;
    value_t body = AS_CONS(args)->cdr;
    function_t *func = function_new(vm, env, params, body);
    return PTR_VAL(func);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movabsq $-0x4000000000000, %r14 # imm = 0xFFFC000000000000
movabsq $0x7ffc000000000001, %rbx # imm = 0x7FFC000000000001
movabsq $0x3ffffffffffff, %rcx  # imm = 0x3FFFFFFFFFFFF
andq %rcx, %rdx
movq 0x10(%rdx), %rax
cmpq %rbx, %rax
jne 0x2604
movq 0x18(%rdx), %rcx
movq %rbx, %rdx
jmp 0x265e
leaq -0x1(%r14), %r8
cmpq %r8, %rax
jbe 0x2619
movq %rax, %r9
andq %rcx, %r9
cmpl $0x2, (%r9)
je 0x2657
movq %rax, %r9
andq %rcx, %r9
movq 0x18(%r9), %rax
cmpq %r14, %rax
jb 0x263c
jb 0x263c
movq %rax, %r10
andq %rcx, %r10
cmpl $0x0, (%r10)
je 0x263c
cmpl $0x2, (%r10)
je 0x2653
movq 0x10(%r9), %r9
cmpq %r8, %r9
jbe 0x266b
andq %rcx, %r9
cmpl $0x2, (%r9)
jne 0x266b
cmpq %rbx, %rax
jne 0x2619
movq 0x10(%rdx), %rax
movq 0x18(%rdx), %rcx
movq %rax, %rdx
callq 0x49a5
movq %rax, %rbx
orq %r14, %rbx
jmp 0x2679
leaq 0x4d2f(%rip), %rsi      # 0x73a1
xorl %eax, %eax
callq 0x4e18
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jiribenes[P]scheme/src/core.c
// Function: builtin_if
static value_t builtin_if(vm_t *vm, env_t *env, value_t args) {
    arity_check(vm, "if", args, 2, true);

    // First evaluate <condition>
    value_t condition = eval(vm, env, AS_CONS(args)->car);

    // if it's true, return <then>
    if (AS_BOOL(condition)) {
        value_t then = AS_CONS(AS_CONS(args)->cdr)->car;
        return eval(vm, env, then);
    }

    // If missing <otherwise> and <condition> is false, return false
    if (IS_NIL(AS_CONS(AS_CONS(args)->cdr)->cdr)) {
        return FALSE_VAL;
    }

    // Else do <otherwise>
    value_t otherwise = AS_CONS(AS_CONS(args)->cdr)->cdr;
    return begin(vm, env, otherwise);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movq %rdx, %rdi
callq 0x4bae
cmpl $0x1, %eax
jg 0x26c3
leaq 0x49ca(%rip), %rsi      # 0x7074
leaq 0x4ab7(%rip), %rdx      # 0x7168
movq %r14, %rdi
movl $0x2, %ecx
movl %eax, %r8d
xorl %eax, %eax
callq 0x4e18
movabsq $0x7ffc000000000001, %r12 # imm = 0x7FFC000000000001
movabsq $0x3ffffffffffff, %r13  # imm = 0x3FFFFFFFFFFFF
andq %r13, %r15
movq 0x10(%r15), %rdx
movq %r14, %rdi
movq %rbx, %rsi
callq 0x5781
andq $-0x3, %rax
andq 0x18(%r15), %r13
cmpq %r12, %rax
jne 0x2710
movq 0x18(%r13), %rdx
cmpq %r12, %rdx
jne 0x2728
addq $0x2, %r12
movq %r12, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq 0x10(%r13), %rdx
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x5781
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x59d0