LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_new
ore_context*
ore_new(ore_context* parent) {
  ore_context* ore = (ore_context*) malloc(sizeof(ore_context));
  if (!ore) {
    fprintf(stderr, "failed to allocate memory\n");
    return NULL;
  }
  ore->env = kh_init(value);
  ore->ct = kh_init(value);
  ore->err = ORE_ERROR_NONE;
  ore->parent = parent;
  ore->ast = kh_init(ast);
  return ore;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x30, %edi
callq 0x21a0
testq %rax, %rax
je 0xd8ca
movq %rax, %rbx
movl $0x1, %edi
movl $0x28, %esi
callq 0x2140
movq %rax, (%rbx)
movl $0x1, %edi
movl $0x28, %esi
callq 0x2140
movq %rax, 0x10(%rbx)
movl $0x0, 0x20(%rbx)
movq %r14, 0x8(%rbx)
movl $0x1, %edi
movl $0x28, %esi
callq 0x2140
movq %rax, 0x28(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
callq 0x2375
xorl %ebx, %ebx
jmp 0xd8bf
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: orex_define_method
void
orex_define_method(ore_context* ore, ore_value clazz, const char* name, int num_in, int max_in, ore_cfunc_t c, void* u) {
  ore_value v = { ORE_TYPE_CFUNC };
  v.v.f.ore = clazz.v.x->e;
  v.v.f.num_in = num_in;
  v.v.f.max_in = max_in;
  v.v.f.x.c = c;
  v.v.f.u = u;
  ore_define(clazz.v.x->e, name, v);
}

// Assembly:
subq $0x58, %rsp
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x40(%rsp)
movq $0x0, 0x50(%rsp)
movl $0x9, 0x30(%rsp)
movq 0x68(%rsp), %rax
movq 0x8(%rax), %rdi
movq %rdi, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movl %ecx, 0x44(%rsp)
movq %r8, 0x48(%rsp)
movq %r9, 0x50(%rsp)
movq %r9, 0x20(%rsp)
movaps 0x30(%rsp), %xmm0
movaps 0x40(%rsp), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0xd5d3
addq $0x58, %rsp
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_define_cfunc
void
ore_define_cfunc(ore_context* ore, const char* name, int num_in, int max_in, ore_cfunc_t c, void* u) {
  ore_value v = { ORE_TYPE_CFUNC };
  v.v.f.ore = ore;
  v.v.f.num_in = num_in;
  v.v.f.max_in = max_in;
  v.v.f.x.c = c;
  v.v.f.u = u;
  ore_define(ore, name, v);
}

// Assembly:
subq $0x58, %rsp
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x40(%rsp)
movl $0x9, 0x30(%rsp)
movq %rdi, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movl %ecx, 0x44(%rsp)
movq %r8, 0x48(%rsp)
movq %r9, 0x50(%rsp)
movq %r9, 0x20(%rsp)
movaps 0x30(%rsp), %xmm0
movaps 0x40(%rsp), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0xd5d3
addq $0x58, %rsp
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_value_array_from_klist
static ore_value
ore_value_array_from_klist(ore_context* ore, ore_array_t* p) {
  ore_value v = { ORE_TYPE_ARRAY };
  v.v.a = (ore_array*) malloc(sizeof(ore_array));
  if (!v.v.a) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  v.v.a->ref = 0;
  v.v.a->p = p;
  return v;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movl $0x10, %edi
callq 0x21a0
testq %rax, %rax
je 0xded6
movl $0x0, 0x8(%rax)
movq %r14, (%rax)
movq $0x5, (%rbx)
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq $0x0, 0x20(%rbx)
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2391
jmp 0xdecd
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_err_print
static void
ore_err_print(mpc_err_t* err) {
  if (err->failure)
    fprintf(stderr, "%s: error: %s\n", err->filename, err->failure);
  else
    fprintf(stderr, "%s:%ld:%ld: syntax error\n", err->filename, err->state.row+1, err->state.col+1);
}

// Assembly:
movq %rdi, %rax
movq 0x20(%rdi), %rdx
movq 0x28(%rdi), %rcx
movq 0xc033(%rip), %rsi      # 0x1bff8
movq (%rsi), %rdi
testq %rcx, %rcx
jne 0xffe9
movq 0x8(%rax), %rcx
movq 0x10(%rax), %r8
incq %rcx
incq %r8
leaq 0x61b8(%rip), %rsi      # 0x1619a
xorl %eax, %eax
jmp 0x2160
leaq 0x42a0(%rip), %rsi      # 0x14290
xorl %eax, %eax
jmp 0x2160
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_dump_env
static ore_value
ore_cfunc_dump_env(ore_context* ore, int num_in, ore_value* args, void* u) {
  int i, level = 0;
  while (ore) {
    for (i = 0; i < level; i++) printf(" ");
    ore_hash_t* h = (ore_hash_t*) ore->env;
    ore_hash_iter_t k;
    int n = 0;
    printf("%p : {", ore->env);
    for (k = kh_begin(h); k != kh_end(h); k++) {
      if (!kh_exist(h, k)) continue;
      if (n > 0) {
        printf(",");
      }
      const char* key = kh_key(h, k);
      printf("%s: ", key);
      ore_value pa[] = { kh_val(h, k) };
      ore_cfunc_print(ore, 1, pa, NULL);
      n++;
    }
    printf("}\n");
    ore = ore->parent;
    level++;
  }
  return ore_value_nil();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, (%rsp)
testq %rsi, %rsi
je 0x10102
movq %rsi, %r14
xorl %r12d, %r12d
testl %r12d, %r12d
je 0x1002e
movl %r12d, %ebx
movl $0x20, %edi
callq 0x2040
decl %ebx
jne 0x10020
movq %r14, 0x8(%rsp)
movq (%r14), %r15
leaq 0x6177(%rip), %rdi      # 0x161b4
movq %r15, %rsi
xorl %eax, %eax
callq 0x20e0
cmpl $0x0, (%r15)
je 0x100e1
xorl %r13d, %r13d
xorl %ebp, %ebp
xorl %ebx, %ebx
movq 0x10(%r15), %rax
movl %ebx, %ecx
shrl $0x4, %ecx
movl (%rax,%rcx,4), %eax
movl %r13d, %ecx
andb $0x1e, %cl
shrl %cl, %eax
testb $0x3, %al
jne 0x100d2
testl %ebp, %ebp
jle 0x1007e
movl $0x2c, %edi
callq 0x2040
movq 0x18(%r15), %rax
movl %ebx, %r14d
movq (%rax,%r14,8), %rsi
leaq 0x612b(%rip), %rdi      # 0x161bb
xorl %eax, %eax
callq 0x20e0
movq 0x20(%r15), %rax
leaq (%r14,%r14,4), %rcx
movq 0x20(%rax,%rcx,8), %rdx
movq %rdx, 0x30(%rsp)
movups (%rax,%rcx,8), %xmm0
movups 0x10(%rax,%rcx,8), %xmm1
movaps %xmm1, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
leaq 0x40(%rsp), %rdi
movl $0x1, %edx
leaq 0x10(%rsp), %rcx
callq 0x10170
incl %ebp
incl %ebx
addl $0x2, %r13d
cmpl (%r15), %ebx
jne 0x10058
leaq 0x4651(%rip), %rdi      # 0x14739
callq 0x2070
movq 0x8(%rsp), %r14
movq 0x8(%r14), %r14
incl %r12d
testq %r14, %r14
jne 0x10018
xorps %xmm0, %xmm0
movq (%rsp), %rax
movups %xmm0, 0x10(%rax)
movups %xmm0, (%rax)
movq $0x0, 0x20(%rax)
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_print
static ore_value
ore_cfunc_print(ore_context* ore, int num_in, ore_value* args, void* u) {
  int i;
  for (i = 0; i < num_in; i++) {
    if (i != 0) printf(", ");
    ore_value v = args[i];
    char* s = ore_value_to_str(ore, v);
    printf("%s", s);
    free(s);
  }
  return ore_value_nil();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
testl %edx, %edx
jle 0x101f7
movq %rcx, %r14
movl %edx, %eax
shlq $0x3, %rax
leaq (%rax,%rax,4), %rbp
leaq 0x440a(%rip), %r15      # 0x145a5
leaq 0x4132(%rip), %r12      # 0x142d4
xorl %ebx, %ebx
testq %rbx, %rbx
je 0x101b3
movq %r12, %rdi
xorl %eax, %eax
callq 0x20e0
movq 0x20(%r14,%rbx), %rax
movq %rax, 0x20(%rsp)
movups (%r14,%rbx), %xmm0
movups 0x10(%r14,%rbx), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0x12fd0
movq %rax, %r13
movq %r15, %rdi
movq %rax, %rsi
xorl %eax, %eax
callq 0x20e0
movq %r13, %rdi
callq 0x22c0
addq $0x28, %rbx
cmpq %rbx, %rbp
jne 0x101a4
xorps %xmm0, %xmm0
movq 0x30(%rsp), %rax
movups %xmm0, 0x10(%rax)
movups %xmm0, (%rax)
movq $0x0, 0x20(%rax)
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_len
static ore_value
ore_cfunc_len(ore_context* ore, int num_in, ore_value* args, void* u) {
  ore_value v = { ORE_TYPE_INT };
  switch (args[0].t) {
    case ORE_TYPE_STRING:
      v.v.i = strlen(args[0].v.s->p);
      return v;
    case ORE_TYPE_ARRAY:
      {
        ore_array_t* a = (ore_array_t*) args[0].v.a->p;
        ore_array_iter_t *k;
        int n = 0;
        for (k = kl_begin(a); k != kl_end(a); k = kl_next(k)) n++;
        v.v.i = n;
      }
      return v;
    default:
      break;
  }
  fprintf(stderr, "argument should be string or array\n");
  ore->err = ORE_ERROR_EXCEPTION;
  return ore_value_nil();
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl (%rcx), %eax
cmpl $0x5, %eax
je 0x10245
cmpl $0x4, %eax
jne 0x1027c
movq 0x8(%rcx), %rax
movq (%rax), %rdi
callq 0x20c0
movq $0x2, (%rbx)
movl %eax, 0x8(%rbx)
jmp 0x1026c
movq 0x8(%rcx), %rax
movq (%rax), %rax
movq (%rax), %rcx
movq 0x8(%rax), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
je 0x10262
incl %eax
movq 0x28(%rcx), %rcx
jmp 0x10255
movq $0x2, (%rbx)
movl %eax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0xc(%rbx)
movups %xmm0, 0x18(%rbx)
movq %rbx, %rax
popq %rbx
retq
movq %rsi, %rdi
movq %rbx, %rsi
callq 0x2485
jmp 0x10277
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_range
static ore_value
ore_cfunc_range(ore_context* ore, int num_in, ore_value* args, void* u) {
  if (args[0].t != ORE_TYPE_INT) {
    fprintf(stderr, "argument should be int\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  ore_array_t* a = kl_init(value);
  int from = 0;
  int to = 0;
  if (num_in == 2) {
    if (args[1].t != ORE_TYPE_INT) {
      fprintf(stderr, "argument should be int\n");
      ore->err = ORE_ERROR_EXCEPTION;
      return ore_value_nil();
    }
    from = args[0].v.i;
    to = args[1].v.i;
  } else {
    to = args[0].v.i - 1;
  }
  int j;
  for (j = from; j <= to; j++) {
    ore_value v = { ORE_TYPE_INT };
    v.v.i = j;
    *kl_pushp(value, a) = v;
  }
  return ore_value_array_from_klist(ore, a);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x2, (%rcx)
jne 0x103c3
movq %rcx, %r12
movl %edx, %ebp
movl $0x1, %edi
movl $0x20, %esi
callq 0x2140
movq %rax, %r15
movl $0x1, %edi
movl $0x20, %esi
callq 0x2140
incq (%rax)
movq %rax, 0x10(%r15)
movq 0x8(%rax), %rcx
testq %rcx, %rcx
je 0x102ec
movq 0x18(%rax), %rdx
leaq -0x1(%rcx), %rsi
movq %rsi, 0x8(%rax)
movq -0x8(%rdx,%rcx,8), %rax
jmp 0x102fb
movl $0x1, %edi
movl $0x30, %esi
callq 0x2140
movq %rax, 0x8(%r15)
movq %rax, (%r15)
movq $0x0, 0x28(%rax)
cmpl $0x2, %ebp
jne 0x10327
cmpl $0x2, 0x28(%r12)
jne 0x103d0
movl 0x8(%r12), %r13d
movl 0x30(%r12), %ebp
jmp 0x10331
movl 0x8(%r12), %ebp
decl %ebp
xorl %r13d, %r13d
cmpl %ebp, %r13d
jg 0x103a3
incl %ebp
xorps %xmm0, %xmm0
movq 0x10(%r15), %rax
incq (%rax)
movq 0x8(%rax), %rcx
testq %rcx, %rcx
je 0x1035e
movq 0x18(%rax), %rdx
leaq -0x1(%rcx), %rsi
movq %rsi, 0x8(%rax)
movq -0x8(%rdx,%rcx,8), %rax
jmp 0x10370
movl $0x1, %edi
movl $0x30, %esi
callq 0x2140
xorps %xmm0, %xmm0
movq 0x8(%r15), %rcx
movq $0x0, 0x28(%rax)
movq %rax, 0x28(%rcx)
movq %rax, 0x8(%r15)
incq 0x18(%r15)
movq $0x2, (%rcx)
movl %r13d, 0x8(%rcx)
movups %xmm0, 0xc(%rcx)
movups %xmm0, 0x18(%rcx)
incl %r13d
cmpl %r13d, %ebp
jne 0x1033b
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0xde8c
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
movq %rbx, %rsi
callq 0x24ca
jmp 0x103b1
movq %r14, %rdi
movq %rbx, %rsi
callq 0x250f
jmp 0x103b1
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_load
static ore_value
ore_cfunc_load(ore_context* ore, int num_in, ore_value* args, void* u) {
  ore_parse_context* pctx = (ore_parse_context*) u;

  mpc_result_t result;
  if (args[0].t != ORE_TYPE_STRING) {
    fprintf(stderr, "argument should be string\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  if (!mpc_parse_contents(ore_value_str_ptr(args[0]), pctx->program, &result)) {
    ore_err_print(result.error);
    mpc_err_delete(result.error);
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  if (verbose)
    mpc_ast_print(result.output);
  ore_eval(ore, result.output);
  mpc_ast_add_child(pctx->root, result.output);
  return ore_value_nil();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x4, (%rcx)
jne 0x104ae
movq %r8, %r15
movq 0x8(%rcx), %rax
movq (%rax), %rdi
movq 0x8(%r8), %rsi
movq %rsp, %rdx
callq 0x43d5
testl %eax, %eax
je 0x10475
cmpl $0x0, 0xbdbd(%rip)      # 0x1c208
je 0x10456
movq (%rsp), %rdi
callq 0x7db8
movq (%rsp), %rdx
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0xdee3
movq (%r15), %rdi
movq (%rsp), %rsi
callq 0x7bbc
jmp 0x1048f
movq (%rsp), %rdi
callq 0xffb3
movq (%rsp), %rdi
callq 0x2b1c
movl $0x1, 0x20(%r14)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
movq $0x0, 0x20(%rbx)
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %r14, %rdi
callq 0x2554
jmp 0x1048f
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_environ
static ore_value
ore_cfunc_environ(ore_context* ore, int num_in, ore_value* args, void* u) {
  if (num_in == 1 && args[0].v.s->p) {
    return ore_value_str_from_ptr(ore, (char*) getenv(args[0].v.s->p), -1);
  } else {
    int i;
    ore_hash_t* h = kh_init(value);
    for (i = 0; environ[i]; i++) {
      const char* p = environ[i];
      if (p == NULL) break;
      const char* t = strchr(p, '=');
      if (t) {
        int r = 0;
        char* n = calloc(1, t-p+1);
        memcpy(n, p, t-p);
        ore_value val = ore_value_str_from_ptr(ore, (char*) t+1, -1);
        khint_t k = kh_put(value, h, n, &r);
        kh_value(h, k) = val;
      }
    }
    return ore_value_hash_from_khash(ore, h);
  }
  fprintf(stderr, "invalid argument\n");
  ore->err = ORE_ERROR_EXCEPTION;
  return ore_value_nil();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, 0x8(%rsp)
movq %rdi, %rbx
cmpl $0x1, %edx
jne 0x104fe
movq 0x8(%rcx), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x104fe
callq 0x2030
movq %rbx, %rdi
movq 0x8(%rsp), %rsi
movq %rax, %rdx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0x1062c
jmp 0x105f9
movq %rbx, 0x18(%rsp)
movl $0x1, %edi
movl $0x28, %esi
callq 0x2140
movq %rax, %r15
movq 0xbac4(%rip), %rax      # 0x1bfe0
movq (%rax), %rax
movq (%rax), %rbp
testq %rbp, %rbp
je 0x105e4
movl $0x8, %r14d
movq %rbp, %rdi
movl $0x3d, %esi
callq 0x20d0
testq %rax, %rax
je 0x105c9
movq %rax, %rbx
movl $0x0, 0x14(%rsp)
movq %rax, %r12
subq %rbp, %r12
leaq 0x1(%r12), %rsi
movl $0x1, %edi
callq 0x2140
movq %rax, %r13
movq %rax, %rdi
movq %rbp, %rsi
movq %r12, %rdx
callq 0x2190
incq %rbx
leaq 0x20(%rsp), %rdi
movq 0x8(%rsp), %rsi
movq %rbx, %rdx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0x1062c
movq %r15, %rdi
movq %r13, %rsi
leaq 0x14(%rsp), %rdx
callq 0xd3d4
movq 0x20(%r15), %rcx
movl %eax, %eax
leaq (%rax,%rax,4), %rax
movups 0x20(%rsp), %xmm0
movups 0x30(%rsp), %xmm1
movups %xmm0, (%rcx,%rax,8)
movups %xmm1, 0x10(%rcx,%rax,8)
movq 0x40(%rsp), %rdx
movq %rdx, 0x20(%rcx,%rax,8)
movq 0xba10(%rip), %rax      # 0x1bfe0
movq (%rax), %rax
movq (%rax,%r14), %rbp
addq $0x8, %r14
testq %rbp, %rbp
jne 0x10531
movq 0x18(%rsp), %rbx
movq %rbx, %rdi
movq 0x8(%rsp), %rsi
movq %r15, %rdx
callq 0x10d30
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_cfunc_exit
static ore_value
ore_cfunc_exit(ore_context* ore, int num_in, ore_value* args, void* u) {
  if (args[0].t != ORE_TYPE_INT) {
    fprintf(stderr, "argument should be int\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  exit(args[0].v.i);
  return ore_value_nil();
}

// Assembly:
pushq %rbx
cmpl $0x2, (%rcx)
je 0x10624
movq %rdi, %rbx
movq %rsi, %rdi
movq %rbx, %rsi
callq 0x257d
movq %rbx, %rax
popq %rbx
retq
movl 0x8(%rcx), %edi
callq 0x2250
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_value_str_from_ptr
static ore_value
ore_value_str_from_ptr(ore_context* ore, char* p, int l) {
  if (p == NULL) return ore_value_nil();
  ore_value v = { ORE_TYPE_STRING };
  v.v.s = (ore_string*) malloc(sizeof(ore_string));
  if (!v.v.s) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  v.v.s->ref = 0;
  v.v.s->l = l < 0 ? strlen(p) : l;
  v.v.s->p = p;
  return v;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
testq %rdx, %rdx
je 0x1068c
movl %ecx, %r15d
movq %rdx, %r14
movq %rsi, %r13
movl $0x10, %edi
callq 0x21a0
testq %rax, %rax
je 0x106ab
movq %rax, %r12
movl $0x0, 0xc(%rax)
testl %r15d, %r15d
jns 0x1066f
movq %r14, %rdi
callq 0x20c0
movq %rax, %r15
movl %r15d, 0x8(%r12)
movq %r14, (%r12)
movq $0x4, (%rbx)
movq %r12, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
jmp 0x10696
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
movq $0x0, 0x20(%rbx)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %r13, %rdi
movq %rbx, %rsi
callq 0x25c2
jmp 0x1069e
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_parse_num
static ore_value
ore_parse_num(ore_context* ore, const char* s) {
  ore_value v = {0};
  if (*s == '0' && *(s+1) == 'x') {
    v.t = ORE_TYPE_INT;
    v.v.i = strtol(s, NULL, 16);
  } else if (!strchr(s, '.')) {
    v.t = ORE_TYPE_INT;
    v.v.i = atoi(s);
  } else {
    v.t = ORE_TYPE_FLOAT;
    v.v.d = atof(s);
  }
  return v;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdi)
movups %xmm0, (%rdi)
movq $0x0, 0x20(%rdi)
cmpb $0x30, (%rsi)
jne 0x10a38
cmpb $0x78, 0x1(%r14)
jne 0x10a38
movl $0x2, (%rbx)
movq %r14, %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x2180
movl %eax, 0x8(%rbx)
jmp 0x10a70
movq %r14, %rdi
movl $0x2e, %esi
callq 0x20d0
testq %rax, %rax
je 0x10a5f
movl $0x3, (%rbx)
movq %r14, %rdi
callq 0x20a0
movsd %xmm0, 0x8(%rbx)
jmp 0x10a70
movl $0x2, (%rbx)
movq %r14, %rdi
callq 0x2220
movl %eax, 0x8(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_parse_str
static ore_value
ore_parse_str(ore_context* ore, const char* s) {
  ore_value v = { ORE_TYPE_STRING };
  char* t = strdup(s);
  if (!t) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  char* p = t + 1;
  char* ps = p;
  int n = 0;
  while (*p) {
    if (*p == '\\' && *(p+1)) {
      p++;
      switch (*p) {
        case 'b': *ps = '\b'; break;
        case 'f': *ps = '\f'; break;
        case 'r': *ps = '\r'; break;
        case 'n': *ps = '\n'; break;
        case 't': *ps = '\t'; break;
        default:
         *ps = *p;
      }
    } else
      *ps = *p;
    p++; ps++; n++;
  }
  *p = 0x00;
  size_t l = n - 1;
  v.v.s = (ore_string*) malloc(sizeof(ore_string));
  if (!v.v.s) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  v.v.s->ref = 0;
  v.v.s->l = l;
  v.v.s->p = calloc(1, l + 1);
  strncpy(v.v.s->p, t + 1, l);
  free(t);
  return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movq %rdx, %rdi
callq 0x2270
testq %rax, %rax
je 0x10d16
movq %rax, %r14
movq %rax, %r12
incq %r12
movq $-0x1, %r13
leaq 0x3c2a(%rip), %rax      # 0x14878
movq %r12, %rcx
movzbl (%rcx), %edx
cmpl $0x5c, %edx
je 0x10c5f
testl %edx, %edx
jne 0x10c93
jmp 0x10ca0
movsbl 0x1(%rcx), %esi
testl %esi, %esi
je 0x10c93
incq %rcx
leal -0x62(%rsi), %edx
rorl %edx
cmpl $0x9, %edx
ja 0x10c81
movslq (%rax,%rdx,4), %rdx
addq %rax, %rdx
jmpq *%rdx
movb $0x8, %dl
jmp 0x10c93
movl %esi, %edx
jmp 0x10c93
movb $0xa, %dl
jmp 0x10c93
movb $0xc, %dl
jmp 0x10c93
movb $0xd, %dl
jmp 0x10c93
movb $0x9, %dl
movb %dl, 0x2(%r14,%r13)
incq %rcx
incq %r13
jmp 0x10c51
movb $0x0, (%rcx)
movl $0x10, %edi
callq 0x21a0
testq %rax, %rax
je 0x10d23
movq %rax, %rbp
movl $0x0, 0xc(%rax)
movl %r13d, 0x8(%rax)
leaq 0x1(%r13), %rsi
movl $0x1, %edi
callq 0x2140
movq %rax, (%rbp)
movq %rax, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x2050
movq %r14, %rdi
callq 0x22c0
movq $0x4, (%rbx)
movq %rbp, 0x8(%rbx)
movaps (%rsp), %xmm0
movups %xmm0, 0x10(%rbx)
movq 0x10(%rsp), %rax
movq %rax, 0x20(%rbx)
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
movq %rbx, %rsi
callq 0x264c
jmp 0x10d04
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2607
jmp 0x10d04
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_value_hash_from_khash
static ore_value
ore_value_hash_from_khash(ore_context* ore, ore_hash_t* p) {
  ore_value v = { ORE_TYPE_HASH };
  v.v.h = (ore_hash*) malloc(sizeof(ore_hash));
  if (!v.v.h) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  v.v.h->ref = 0;
  v.v.h->p = p;
  return v;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movl $0x10, %edi
callq 0x21a0
testq %rax, %rax
je 0x10d7a
movl $0x0, 0x8(%rax)
movq %r14, (%rax)
movq $0x6, (%rbx)
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq $0x0, 0x20(%rbx)
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2691
jmp 0x10d71
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_expr
static ore_value
ore_expr(ore_context* ore, mpc_ast_t* t) {
  int i;
  ore_value lhs = ore_eval(ore, t->children[0]);
  for (i = 1; i < t->children_num; i += 2) {
    char* op = t->children[i]->contents;
    ore_value rhs = ore_eval(ore, t->children[i+1]);
    lhs = ore_expr0(ore, lhs, op, rhs);
  }
  return lhs;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movq 0x30(%rdx), %rax
movq (%rax), %rdx
callq 0xdee3
cmpl $0x2, 0x28(%rbx)
jl 0x1146b
movl $0x1, %r12d
leaq 0x58(%rsp), %r13
movq 0x30(%rbx), %rax
movq (%rax,%r12,8), %rcx
movq 0x8(%rcx), %rbp
movq 0x8(%rax,%r12,8), %rdx
leaq 0x80(%rsp), %rdi
movq %r15, %rsi
callq 0xdee3
movq 0xa0(%rsp), %rax
movq %rax, 0x48(%rsp)
movups 0x80(%rsp), %xmm0
movups 0x90(%rsp), %xmm1
movups %xmm1, 0x38(%rsp)
movups %xmm0, 0x28(%rsp)
movq 0x20(%r14), %rax
movq %rax, 0x20(%rsp)
movups (%r14), %xmm0
movups 0x10(%r14), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
movq %r13, %rdi
movq %r15, %rsi
movq %rbp, %rdx
callq 0x11480
movq 0x78(%rsp), %rax
movq %rax, 0x20(%r14)
movups 0x58(%rsp), %xmm0
movups 0x68(%rsp), %xmm1
movups %xmm1, 0x10(%r14)
movups %xmm0, (%r14)
addq $0x2, %r12
cmpl %r12d, 0x28(%rbx)
jg 0x113d0
movq %r14, %rax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_define_class
static ore_value
ore_define_class(ore_context* ore, mpc_ast_t* tn, mpc_ast_t* tb, const char* base) {
  ore_value v = { ORE_TYPE_CLASS };
  v.v.c = (ore_class*) malloc(sizeof(ore_class));
  if (!v.v.c) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  v.v.c->n = strdup(tn->contents);
  if (!v.v.c->n) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  v.v.c->t = tb;
  v.v.c->b = base;
  ore_context* g = ore;
  while (g->parent) g = g->parent;
  ore_define(g, v.v.c->n, v);
  return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %r8, %r15
movq %rcx, %r12
movq %rdx, %rbp
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x40(%rsp)
movq $0x0, 0x50(%rsp)
movl $0xb, 0x30(%rsp)
movl $0x18, %edi
callq 0x21a0
movq %rax, 0x38(%rsp)
testq %rax, %rax
je 0x11d67
movq %rax, %r13
movq 0x8(%rbp), %rdi
callq 0x2270
movq %rax, (%r13)
testq %rax, %rax
je 0x11d74
movq %r12, 0x8(%r13)
movq %r15, 0x10(%r13)
movq %r14, %rdi
movq 0x8(%r14), %r14
testq %r14, %r14
jne 0x11d0a
movq 0x50(%rsp), %rcx
movq %rcx, 0x20(%rsp)
movaps 0x30(%rsp), %xmm0
movaps 0x40(%rsp), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
movq %rax, %rsi
callq 0xd5d3
movq 0x50(%rsp), %rax
movq %rax, 0x20(%rbx)
movaps 0x30(%rsp), %xmm0
movaps 0x40(%rsp), %xmm1
movups %xmm1, 0x10(%rbx)
movups %xmm0, (%rbx)
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2856
jmp 0x11d55
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2811
jmp 0x11d55
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_is_true
static int
ore_is_true(ore_value v) {
  switch (v.t) {
    case ORE_TYPE_BOOL:
      return v.v.b != 0;
    case ORE_TYPE_INT:
      return v.v.i != 0;
    case ORE_TYPE_FLOAT:
      return v.v.d != 0;
    case ORE_TYPE_STRING:
      return v.v.s->l > 0;
    case ORE_TYPE_ARRAY:
      {
        int n = 0;
        ore_array_t* a = (ore_array_t*) v.v.a->p;
        ore_array_iter_t *k;
        for (k = kl_begin(a); k != kl_end(a); k = kl_next(k)) n++;
        return n > 0;
      }
    case ORE_TYPE_HASH:
      {
        ore_hash_t* h = (ore_hash_t*) v.v.h->p;
        ore_hash_iter_t k;
        int n = 0;
        for (k = kh_begin(h); k != kh_end(h); k++) {
          if (!kh_exist(h, k)) continue;
          n++;
        }
        return n > 0;
      }
    case ORE_TYPE_REGEXP:
      return v.v.r->l > 0;
    case ORE_TYPE_ENV:
      return 1; // TODO
    case ORE_TYPE_CLASS:
      return 1; // TODO
    case ORE_TYPE_CCLASS:
      return 1; // TODO
    case ORE_TYPE_OBJECT:
      return 1; // TODO
    default:
      break;
  }
  return 0;
}

// Assembly:
movl 0x8(%rsp), %ecx
decl %ecx
cmpl $0xc, %ecx
ja 0x1250b
leaq 0x8(%rsp), %rax
leaq 0x247b(%rip), %rdx      # 0x148f8
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
movb $0x1, %al
jmp 0x1250d
cmpl $0x0, 0x8(%rax)
jmp 0x12506
movq 0x8(%rax), %rax
cmpl $0x0, 0x8(%rax)
setg %al
jmp 0x1250d
movq 0x8(%rax), %rax
movq (%rax), %rax
movq (%rax), %rcx
cmpq 0x8(%rax), %rcx
jmp 0x12506
xorpd %xmm0, %xmm0
cmpneqsd 0x8(%rax), %xmm0
movq %xmm0, %rax
andl $0x1, %eax
jmp 0x1250d
movq 0x8(%rax), %rax
movq (%rax), %rcx
movl (%rcx), %edx
xorl %eax, %eax
testl %edx, %edx
je 0x1250d
movq 0x10(%rcx), %rsi
xorl %edi, %edi
xorl %r8d, %r8d
movl %r8d, %ecx
shrl $0x4, %ecx
movl (%rsi,%rcx,4), %r9d
movl %eax, %ecx
andb $0x1e, %cl
shrl %cl, %r9d
andl $0x3, %r9d
cmpl $0x1, %r9d
adcl $0x0, %edi
incl %r8d
addl $0x2, %eax
cmpl %r8d, %edx
jne 0x124dc
testl %edi, %edi
setne %al
jmp 0x1250d
xorl %eax, %eax
movzbl %al, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_find_statements
static mpc_ast_t*
ore_find_statements(mpc_ast_t* t) {
  int i;
  if (is_a(t, "template")) return t;
  for (i = 0; i < t->children_num; i++) {
    if (is_a(t->children[i], "char") && t->children[i]->contents[0] == '{') {
      if (t->children[i+1]->contents[0] != '}') {
        return t->children[i+1];
      }
    }
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %r14
movq (%rdi), %rdi
leaq 0x26d6(%rip), %rsi      # 0x14bfd
callq 0x2290
testq %rax, %rax
jne 0x1257e
movslq 0x28(%r14), %r15
testq %r15, %r15
jle 0x1257b
movq 0x30(%r14), %r12
leaq 0x1fb3(%rip), %rbx      # 0x144f8
xorl %r13d, %r13d
movq (%r12,%r13,8), %r14
movq (%r14), %rdi
movq %rbx, %rsi
callq 0x2290
testq %rax, %rax
je 0x12573
movq 0x8(%r14), %rax
cmpb $0x7b, (%rax)
jne 0x12573
movq 0x8(%r12,%r13,8), %r14
movq 0x8(%r14), %rax
cmpb $0x7d, (%rax)
jne 0x1257e
incq %r13
cmpq %r13, %r15
jne 0x12548
xorl %r14d, %r14d
movq %r14, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mattn[P]orelang/ore.c
// Function: ore_class_new
static ore_value
ore_class_new(ore_context* ore, ore_value clazz) {
  ore_value v = { ORE_TYPE_OBJECT };
  ore_context* this = ore_new(ore);
  v.v.o = (ore_object*) malloc(sizeof(ore_object));
  if (!v.v.o) {
    fprintf(stderr, "failed to allocate memory\n");
    ore->err = ORE_ERROR_EXCEPTION;
    return ore_value_nil();
  }
  if (clazz.v.c->b != NULL) {
    ore_value bc = ore_find_global(ore, clazz.v.c->b);
    if (bc.t == ORE_TYPE_CLASS)
      ore_define(this, "super", ore_class_new(this, bc));
  }
  v.v.o->t = clazz.t;
  v.v.o->c = clazz.v.c;
  v.v.o->e = this;
  v.v.o->ref = -1;
  ore_eval(this, ore_find_statements(clazz.v.c->t));
  ore_define(this, "this", v);
  return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rsi, %r12
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x40(%rsp)
movq $0x0, 0x50(%rsp)
movl $0xd, 0x30(%rsp)
movq %rsi, %rdi
callq 0xd863
movq %rax, %r14
movl $0x20, %edi
callq 0x21a0
movq %rax, 0x38(%rsp)
testq %rax, %rax
je 0x12b6f
movq %rax, %r15
leaq 0xe0(%rsp), %rbp
movq 0x8(%rbp), %r13
movq 0x10(%r13), %rdx
testq %rdx, %rdx
je 0x12ae5
movq %r12, %rsi
movq 0x8(%r12), %r12
testq %r12, %r12
jne 0x12a67
leaq 0x58(%rsp), %r12
movq %r12, %rdi
callq 0xcec9
cmpl $0xb, (%r12)
jne 0x12ae5
movq 0x78(%rsp), %rax
movq %rax, 0x20(%rsp)
movups 0x58(%rsp), %xmm0
movups 0x68(%rsp), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
leaq 0x80(%rsp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x129f7
movq 0x20(%r12), %rax
movq %rax, 0x20(%rsp)
movups (%r12), %xmm0
movups 0x10(%r12), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
leaq 0x3665(%rip), %rsi      # 0x16142
movq %r14, %rdi
callq 0xd5d3
movl (%rbp), %eax
movl %eax, (%r15)
movq %r13, 0x8(%r15)
movq %r14, 0x10(%r15)
movl $0xffffffff, 0x18(%r15) # imm = 0xFFFFFFFF
movq 0x8(%r13), %rdi
callq 0x12511
leaq 0x58(%rsp), %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0xdee3
movq 0x50(%rsp), %rax
movq %rax, 0x20(%rsp)
movaps 0x30(%rsp), %xmm0
movaps 0x40(%rsp), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
leaq 0x3610(%rip), %rsi      # 0x16148
movq %r14, %rdi
callq 0xd5d3
movq 0x50(%rsp), %rax
movq %rax, 0x20(%rbx)
movaps 0x30(%rsp), %xmm0
movaps 0x40(%rsp), %xmm1
movups %xmm1, 0x10(%rbx)
movups %xmm0, (%rbx)
movq %rbx, %rax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r12, %rdi
movq %rbx, %rsi
callq 0x29b7
jmp 0x12b5a
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_5/exercise_5_05/strncmp.c
// Function: main
int main(void)
{
  char s[100] = "This is the first string";
  char *t = "This is the second string";
  size_t nr_chars = 13;

  int is_equal = strcmp_ptr(s, t, nr_chars);

  if (is_equal == 0)
  {
    puts("String s is equal with string t.");
  }
  else if (is_equal > 0)
  {
    puts("String s contains more chars than string t.");
  }
  else if (is_equal < 0)
  {
    puts("String s contains less chars than string t.");
  }

  return 0;
}

// Assembly:
movl $0x1, %esi
leaq 0xec8(%rip), %rdx       # 0x2010
leaq 0xf25(%rip), %rdi       # 0x2074
movsbl (%rsi,%rdx), %eax
movsbl (%rsi,%rdi), %ecx
cmpb %cl, %al
jne 0x1168
leaq 0x1(%rsi), %r8
cmpq $0xc, %rsi
movq %r8, %rsi
jne 0x114f
cmpb %cl, %al
jne 0x1175
leaq 0xf1b(%rip), %rdi       # 0x208e
jmp 0x1182
subl %ecx, %eax
testl %eax, %eax
jle 0x118f
leaq 0xf2d(%rip), %rdi       # 0x20af
pushq %rax
callq 0x1030
addq $0x8, %rsp
xorl %eax, %eax
retq
jns 0x118c
leaq 0xf43(%rip), %rdi       # 0x20db
jmp 0x1182
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_5/exercise_5_05/strncmp.c
// Function: strcmp_ptr
int strcmp_ptr(char *s, char *t, size_t n)
{
  while ((*s == *t) && --n)
  {
    if (*s == '\0')
      return 0;

    ++s;
    ++t;
  }

  // If the s string contains more characters than t, then the t char will
  // become '\0' before s char. If this happen then the s char will be its ascii value and
  // t char will be 0, so the final result will be s_ascii_value - 0.

  // If the t string contains more character than s, then the s char will
  // become '\0' before t char. If this happen then the s char will be 0 and
  // t char will be whatever ascii_value is holding, so the final result will be 0 - t_ascii_value.

  return *s - *t;
}

// Assembly:
movb (%rdi), %cl
movb (%rsi), %r8b
cmpb %r8b, %cl
setne %al
cmpq $0x1, %rdx
sete %r9b
orb %al, %r9b
je 0x11bc
movsbl %cl, %eax
movsbl %r8b, %ecx
subl %ecx, %eax
retq
addq $-0x2, %rdx
xorl %eax, %eax
xorl %r9d, %r9d
testb %cl, %cl
je 0x11bb
movb 0x1(%rdi,%r9), %cl
movb 0x1(%rsi,%r9), %r8b
cmpb %r8b, %cl
jne 0x11b2
leaq 0x1(%r9), %r10
cmpq %r9, %rdx
movq %r10, %r9
jne 0x11c5
jmp 0x11b2
// File: /workspace/github_c_makefile_star2_O1/gregtour[P]minimal-compiler/assembler.c
// Function: EMIT
void EMIT(const char* str, 
          ...)
{
    va_list args;
    va_start(args, str);
    if (emit_tabs) fprintf(working_assembler_output, "    ");
    vfprintf(working_assembler_output, str, args);
    fprintf(working_assembler_output, "\r\n");
    va_end(args);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %rbx
leaq -0xd0(%rbp), %rdi
movq %rsi, 0x8(%rdi)
movq %rdx, 0x10(%rdi)
movq %rcx, 0x18(%rdi)
movq %r8, 0x20(%rdi)
movq %r9, 0x28(%rdi)
testb %al, %al
je 0x11c0
movaps %xmm0, -0xa0(%rbp)
movaps %xmm1, -0x90(%rbp)
movaps %xmm2, -0x80(%rbp)
movaps %xmm3, -0x70(%rbp)
movaps %xmm4, -0x60(%rbp)
movaps %xmm5, -0x50(%rbp)
movaps %xmm6, -0x40(%rbp)
movaps %xmm7, -0x30(%rbp)
movq %rdi, -0x10(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x18(%rbp)
movabsq $0x3000000008, %rax     # imm = 0x3000000008
movq %rax, -0x20(%rbp)
cmpl $0x0, 0x2e77(%rip)      # 0x4058
je 0x1200
movq 0x2e66(%rip), %rcx      # 0x4050
leaq 0xe13(%rip), %rdi       # 0x2004
movl $0x4, %esi
movl $0x1, %edx
callq 0x1060
movq 0x2e49(%rip), %rdi      # 0x4050
leaq -0x20(%rbp), %rdx
movq %rbx, %rsi
callq 0x1050
movq 0x2e36(%rip), %rcx      # 0x4050
leaq 0xde8(%rip), %rdi       # 0x2009
movl $0x2, %esi
movl $0x1, %edx
callq 0x1060
addq $0xc8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/gregtour[P]minimal-compiler/assembler.c
// Function: EMIT_HEADER
void EMIT_HEADER()
{
    EMIT("// Beginning of source file");
    EMIT("#include <stdio.h>");
    EMIT("#include <stdlib.h>");
    EMIT("");
    EMIT("int main(int arg_c, char* arg_v[]) \r\n{");
    EMIT("  __asm");
    EMIT("  {");
    emit_tabs = 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0xd22(%rip), %rdi       # 0x200c
xorl %eax, %eax
callq 0x116c
leaq 0xd30(%rip), %rdi       # 0x2028
xorl %eax, %eax
callq 0x116c
leaq 0xd35(%rip), %rdi       # 0x203b
xorl %eax, %eax
callq 0x116c
leaq 0xcf7(%rip), %rdi       # 0x200b
xorl %eax, %eax
callq 0x116c
leaq 0xd2d(%rip), %rdi       # 0x204f
xorl %eax, %eax
callq 0x116c
leaq 0xd46(%rip), %rdi       # 0x2076
xorl %eax, %eax
callq 0x116c
leaq 0xd40(%rip), %rdi       # 0x207e
xorl %eax, %eax
callq 0x116c
movl $0x1, 0x2d09(%rip)      # 0x4058
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/gregtour[P]minimal-compiler/assembler.c
// Function: EMIT_FOOTER
void EMIT_FOOTER()
{
    emit_tabs = 0;
    EMIT("  }");
    EMIT("  ");
    EMIT("  return 0;");
    EMIT("}");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0x0, 0x2cf9(%rip)      # 0x4058
leaq 0xd1c(%rip), %rdi       # 0x2082
xorl %eax, %eax
callq 0x116c
leaq 0xc92(%rip), %rdi       # 0x2006
xorl %eax, %eax
callq 0x116c
leaq 0xd04(%rip), %rdi       # 0x2086
xorl %eax, %eax
callq 0x116c
leaq 0xcf4(%rip), %rdi       # 0x2084
xorl %eax, %eax
popq %rbp
jmp 0x116c
// File: /workspace/github_c_makefile_star2_O1/gregtour[P]minimal-compiler/assembler.c
// Function: assemble_code
void assemble_code(const char* output_src,
                         void* IR)
{
    FILE* output;
    output = fopen(output_src, "wb");
    if (output == NULL)
    {
        ERROR("Could not open output file %s.\n", output_src);
        return;
    } else {
        working_assembler_output = output;
    }
    
    EMIT_HEADER();
  
    EMIT("; Beginning of source assembly");
    GenerateProgram();
    EMIT("_emit 0x90 ;");
    
    EMIT_FOOTER();
    
    fprintf(output, "\r\n");
    fclose(output);
    return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0xced(%rip), %rsi       # 0x2092
callq 0x1040
testq %rax, %rax
je 0x140b
movq %rax, %rbx
movq %rax, 0x2c97(%rip)      # 0x4050
callq 0x12df
leaq 0xcd0(%rip), %rdi       # 0x2095
xorl %eax, %eax
callq 0x116c
callq 0x1478
leaq 0xcdc(%rip), %rdi       # 0x20b4
xorl %eax, %eax
callq 0x116c
callq 0x1351
leaq 0xc1e(%rip), %rdi       # 0x2009
movl $0x2, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x1060
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1030
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/gregtour[P]minimal-compiler/assembler.c
// Function: GenerateProgram
void GenerateProgram()
{
    EMIT("jp start");
    EMIT_L("head:");

    STRINGCONST("World");   // 6    
    STRINGCONST("Hello");   // 6
    STRINGCONST("%s, %s."); // 8

    EMIT_L("start:");
    EMIT("mov eax, head");
    EMIT("push eax");
    EMIT("add eax, 6");
    EMIT("push eax");
    EMIT("add eax, 6");
    EMIT("push eax");
    EMIT("call printf");
    EMIT("pop ebx");
    EMIT("pop ebx");
    EMIT("pop ebx");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0xc54(%rip), %rdi       # 0x20da
xorl %eax, %eax
callq 0x116c
leaq 0xc4f(%rip), %rdi       # 0x20e3
xorl %eax, %eax
callq 0x123a
leaq 0xc47(%rip), %rdi       # 0x20e9
callq 0x1426
leaq 0xc41(%rip), %rdi       # 0x20ef
callq 0x1426
leaq 0xc3b(%rip), %rdi       # 0x20f5
callq 0x1426
leaq 0xc37(%rip), %rdi       # 0x20fd
xorl %eax, %eax
callq 0x123a
leaq 0xc30(%rip), %rdi       # 0x2104
xorl %eax, %eax
callq 0x116c
leaq 0xc30(%rip), %rbx       # 0x2112
movq %rbx, %rdi
xorl %eax, %eax
callq 0x116c
leaq 0xc28(%rip), %r14       # 0x211b
movq %r14, %rdi
xorl %eax, %eax
callq 0x116c
movq %rbx, %rdi
xorl %eax, %eax
callq 0x116c
movq %r14, %rdi
xorl %eax, %eax
callq 0x116c
movq %rbx, %rdi
xorl %eax, %eax
callq 0x116c
leaq 0xc04(%rip), %rdi       # 0x2126
xorl %eax, %eax
callq 0x116c
leaq 0xc02(%rip), %rbx       # 0x2132
movq %rbx, %rdi
xorl %eax, %eax
callq 0x116c
movq %rbx, %rdi
xorl %eax, %eax
callq 0x116c
movq %rbx, %rdi
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
jmp 0x116c
// File: /workspace/github_c_makefile_star2_O1/rajatxjain[P]gpiocfg/gpiocfg.c
// Function: usage
static void usage(char *prog)
{
	printf("\nUsage: %s [options] <command>\n\n", prog);
	printf("Options:\n");
	printf("  -p, --platform=<name>    Platform to use (Default: icelake)\n\n");
	printf("Commands:\n");
	printf("  -r, --read=<gpio pin>    Read and parse DW0/DW1 config for given pin\n");
	printf("  -v, --value=<DW0 value>  Parse the given DW0 register value\n");
	printf("  -l, --list               List the GPIO pins for selected platform\n");
	printf("  -h, --help               Print this help.\n\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rsi
leaq 0x6ea(%rip), %rdi       # 0x2113
xorl %eax, %eax
callq 0x1070
leaq 0xe29(%rip), %rdi       # 0x2860
callq 0x1040
leaq 0xe26(%rip), %rdi       # 0x2869
callq 0x1040
leaq 0xe59(%rip), %rdi       # 0x28a8
callq 0x1040
leaq 0xe57(%rip), %rdi       # 0x28b2
callq 0x1040
leaq 0xe92(%rip), %rdi       # 0x28f9
callq 0x1040
leaq 0xec4(%rip), %rdi       # 0x2937
callq 0x1040
leaq 0xefc(%rip), %rdi       # 0x297b
popq %rbp
jmp 0x1040
// File: /workspace/github_c_makefile_star2_O1/rajatxjain[P]gpiocfg/gpiocfg.c
// Function: lookup_pin
static int lookup_pin(char *pin_name, struct community **community, unsigned *pin_no_in_cmty)
{
	unsigned cmty_num, pin;
	struct community *cmty;

	for (cmty_num = 0; cmty_num < platform->num_communities; cmty_num++) {		
		cmty = &platform->communities[cmty_num];
		for (pin = 0; pin < cmty->num_pins; pin++)
			if (!strcmp(cmty->pin_names[pin], pin_name)) {
				*community = cmty;
				*pin_no_in_cmty = pin;
				return 1;
			}
	}
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq 0x2623(%rip), %rax      # 0x40c0
movl 0x28(%rax), %ecx
movq %rcx, -0x58(%rbp)
testq %rcx, %rcx
je 0x1b1e
movq %rdi, %r15
movq %rsi, -0x48(%rbp)
movq %rdx, -0x50(%rbp)
movq 0x30(%rax), %rax
movq %rax, -0x40(%rbp)
addq $0x10, %rax
movq %rax, -0x38(%rbp)
xorl %r13d, %r13d
imulq $0x1010, %r13, %rcx     # imm = 0x1010
movq -0x40(%rbp), %rax
movq %rcx, -0x30(%rbp)
movl 0xc(%rax,%rcx), %ebx
testq %rbx, %rbx
je 0x1b0d
movq -0x30(%rbp), %rax
addq -0x40(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x38(%rbp), %r12
xorl %r14d, %r14d
movq %r12, %rdi
movq %r15, %rsi
callq 0x1090
testl %eax, %eax
je 0x1b22
incq %r14
addq $0x20, %r12
cmpq %r14, %rbx
jne 0x1af2
incq %r13
addq $0x1010, -0x38(%rbp)    # imm = 0x1010
cmpq -0x58(%rbp), %r13
jne 0x1ac7
xorl %eax, %eax
jmp 0x1b39
movq -0x48(%rbp), %rax
movq -0x30(%rbp), %rcx
movq %rcx, (%rax)
movq -0x50(%rbp), %rax
movl %r14d, (%rax)
movl $0x1, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/rajatxjain[P]gpiocfg/gpiocfg.c
// Function: mmio_read32
static u_int32_t mmio_read32(unsigned long addr)
{
	int fd;
	volatile u_int32_t *ptr;
	u_int32_t val;
	unsigned int pgsize = getpagesize();
	unsigned long aligned_addr = addr & ~(pgsize - 1);
	unsigned long offset = addr & (pgsize - 1);
	
	fd = open("/dev/mem", O_RDONLY | O_SYNC);
	if (fd < 0) {
		printf("Error opening /dev/mem!!!\n");
		return -1;
	}
	ptr = mmap(NULL, pgsize, PROT_READ, MAP_SHARED, fd, aligned_addr);
	if (!ptr || ptr == MAP_FAILED) {
		printf("Error in mmap for addr 0x%X!!!\n", addr);
		return -1;
	}
	val = *(volatile u_int32_t *)((unsigned long)ptr + offset);
	munmap((void*) ptr, pgsize);
	close(fd);
	return val;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
callq 0x10d0
movl %eax, %r15d
leaq 0x6df(%rip), %rdi       # 0x2244
movl $0x101000, %esi         # imm = 0x101000
xorl %eax, %eax
callq 0x10b0
testl %eax, %eax
js 0x1bba
movl %eax, %r14d
movl %r15d, %eax
negl %eax
movl %ebx, %r9d
andl %eax, %r9d
movl %r15d, %r12d
xorl %edi, %edi
movq %r12, %rsi
movl $0x1, %edx
movl $0x1, %ecx
movl %r14d, %r8d
callq 0x1050
leaq 0x1(%rax), %rcx
cmpq $0x1, %rcx
ja 0x1bcd
leaq 0x69f(%rip), %rdi       # 0x224d
movq %rbx, %rsi
xorl %eax, %eax
callq 0x1070
jmp 0x1bc6
leaq 0xf6b(%rip), %rdi       # 0x2b2c
callq 0x1040
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x1be9
decl %r15d
andl %r15d, %ebx
movl (%rbx,%rax), %ebx
movq %rax, %rdi
movq %r12, %rsi
callq 0x10a0
movl %r14d, %edi
callq 0x1080
movl %ebx, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_1/exercise_1_18/trailing_blanks.c
// Function: main
int main(void)
{
  int len;
  char line[MAXLINE];

  while ((len = get_line(line, MAXLINE)) > 0)
  {
    remove_trailing_blanks(line, len);
    printf("%s", line);
  }

  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x3f0, %rsp            # imm = 0x3F0
movq %rsp, %rdi
movl $0x3e8, %esi            # imm = 0x3E8
callq 0x11c6
testl %eax, %eax
jle 0x11b7
leaq 0x2(%rsp), %r15
leaq 0xe8f(%rip), %rbx       # 0x2004
movq %rsp, %r14
addl $-0x2, %eax
cltq
addq %r15, %rax
movzbl -0x2(%rax), %ecx
cmpl $0x20, %ecx
je 0x118e
cmpl $0x9, %ecx
jne 0x1193
decq %rax
jmp 0x1180
movw $0xa, -0x1(%rax)
movq %rbx, %rdi
movq %r14, %rsi
xorl %eax, %eax
callq 0x1030
movq %r14, %rdi
movl $0x3e8, %esi            # imm = 0x3E8
callq 0x11c6
testl %eax, %eax
jg 0x1178
xorl %eax, %eax
addq $0x3f0, %rsp            # imm = 0x3F0
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/hsjoihs[P]c-compiler/codegen.c
// Function: collect_named_labels
static struct Vector /*<SourceLabel>*/
collect_named_labels(const struct Statement *ptr_sta)
{
	struct Statement sta = *ptr_sta;
	struct Vector /*<SourceLabel>*/ ans = init_vector();
	concat_vector(&ans, &sta.labels);
	switch (sta.category) {
	case RETURN_STATEMENT:
	case BREAK_STATEMENT:
	case CONTINUE_STATEMENT:
	case EXPRESSION_STATEMENT:
	case DECLARATION_STATEMENT:
	case GOTO_STATEMENT:
		/* nothing */
		break;

	case SWITCH_STATEMENT: /* do peek labels */
	case IF_STATEMENT:
	case FOR_STATEMENT:
	case WHILE_STATEMENT:
	case DO_WHILE_STATEMENT: {
		const struct Vector /*<SourceLabel>*/ inner_vec =
		    collect_named_labels(sta.inner_statement);
		concat_vector(&ans, &inner_vec);
		break;
	}

	case COMPOUND_STATEMENT:
	case IF_ELSE_STATEMENT: {
		struct Vector /*<Statement>*/ statement_vec = sta.statement_vector;
		for (int counter = 0; counter != statement_vec.length; ++counter) {
			const struct Statement *ptr_ith = statement_vec.vector[counter];
			const struct Vector /*<SourceLabel>*/ inner_vec =
			    collect_named_labels(ptr_ith);
			concat_vector(&ans, &inner_vec);
		}
		break;
	}
	}
	return ans;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3b8, %rsp            # imm = 0x3B8
movq %rdi, %rsi
leaq -0x3d8(%rbp), %rbx
movl $0x390, %edx            # imm = 0x390
movq %rbx, %rdi
callq 0x1100
callq 0x5af4
leaq -0x38(%rbp), %rdi
movq %rax, (%rdi)
movq %rdx, 0x8(%rdi)
leaq -0x60(%rbp), %rsi
callq 0x5bff
movl (%rbx), %eax
cmpl $0xb, %eax
ja 0x2e38
movl $0x83a, %ecx            # imm = 0x83A
btl %eax, %ecx
jae 0x2e52
movq -0xc0(%rbp), %rdi
callq 0x2dc3
leaq -0x48(%rbp), %rsi
movq %rax, (%rsi)
movq %rdx, 0x8(%rsi)
leaq -0x38(%rbp), %rdi
callq 0x5bff
movq -0x38(%rbp), %rax
movq -0x30(%rbp), %rdx
addq $0x3b8, %rsp            # imm = 0x3B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x5, %ecx
btl %eax, %ecx
jae 0x2e38
movl -0x3d0(%rbp), %r15d
testq %r15, %r15
je 0x2e38
movq -0x3c8(%rbp), %r12
xorl %r13d, %r13d
leaq -0x38(%rbp), %rbx
leaq -0x48(%rbp), %r14
movq (%r12,%r13,8), %rdi
callq 0x2dc3
movq %rax, -0x48(%rbp)
movq %rdx, -0x40(%rbp)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x5bff
incq %r13
cmpq %r13, %r15
jne 0x2e7a
jmp 0x2e38
// File: /workspace/github_c_makefile_star2_O1/hsjoihs[P]c-compiler/alignment.c
// Function: get_size_alignment_offsets_for_union
struct SizeAndAlignment get_size_alignment_offsets_for_union(
    const struct SizeAndAlignment *inner_type_vec, int **ptr_offset_vec,
    int length)
{
	struct SizeAndAlignment res;
	res.alignment = 1;

	/* union's alignment is the maximum of the members' alignments */
	for (int i = 0; i < length; i++) {
		if (inner_type_vec[i].alignment > res.alignment) {
			res.alignment = inner_type_vec[i].alignment;
		}
	}

	int max_size_of_member = 1;

	/* union's size is AT LEAST the maximum of the members' sizes */
	for (int i = 0; i < length; i++) {
		if (inner_type_vec[i].size > max_size_of_member) {
			max_size_of_member = inner_type_vec[i].size;
		}
	}

	if (max_size_of_member % res.alignment) {
		max_size_of_member +=
		    res.alignment - (max_size_of_member % res.alignment);
	}

	res.size = max_size_of_member;

	/* calloc; all is zero */
	int *offset_vec = calloc(length, sizeof(int));
	*ptr_offset_vec = offset_vec;
	return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ecx
movq %rsi, %rbx
movl $0x1, %esi
movl %edx, %eax
movl $0x1, %r15d
testl %edx, %edx
jle 0x2edc
movl $0x1, %r15d
xorl %edx, %edx
movl 0x4(%rdi,%rdx,8), %r8d
cmpl %r15d, %r8d
cmovgl %r8d, %r15d
incq %rdx
cmpq %rdx, %rax
jne 0x2ec8
testl %ecx, %ecx
jle 0x2efa
movl $0x1, %esi
xorl %edx, %edx
movl (%rdi,%rdx,8), %r8d
cmpl %esi, %r8d
cmovgl %r8d, %esi
incq %rdx
cmpq %rdx, %rax
jne 0x2ee7
movl %esi, %eax
xorl %edx, %edx
divl %r15d
movl %r15d, %r14d
subl %edx, %r14d
testl %edx, %edx
cmovel %edx, %r14d
addl %esi, %r14d
movslq %ecx, %rdi
movl $0x4, %esi
callq 0x10d0
movq %rax, (%rbx)
shlq $0x20, %r15
orq %r15, %r14
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq