LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lapi.c
// Function: aux_upvalue
static const char *aux_upvalue (StkId fi, int n, TValue **val,
                                GCObject **owner) {
  switch (ttype(fi)) {
    case LUA_TCCL: {  /* C closure */
      CClosure *f = clCvalue(fi);
      if (!(1 <= n && n <= f->nupvalues)) return NULL;
      *val = &f->upvalue[n-1];
      if (owner) *owner = obj2gco(f);
      return "";
    }
    case LUA_TLCL: {  /* Lua closure */
      LClosure *f = clLvalue(fi);
      TString *name;
      Proto *p = f->p;
      if (!(1 <= n && n <= p->sizeupvalues)) return NULL;
      *val = f->upvals[n-1]->v;
      if (owner) *owner = obj2gco(f->upvals[n - 1]);
      name = p->upvalues[n-1].name;
      return (name == NULL) ? "" : getstr(name);
    }
    default: return NULL;  /* not a closure */
  }
}

// Assembly:
movl 0x8(%rdi), %eax
andl $0x3f, %eax
cmpl $0x6, %eax
je 0x8c41
cmpl $0x26, %eax
jne 0x8c51
testl %esi, %esi
jle 0x8c51
movq (%rdi), %rdi
movzbl 0xa(%rdi), %eax
cmpl %esi, %eax
jb 0x8c51
decl %esi
shlq $0x4, %rsi
leaq (%rdi,%rsi), %rax
addq $0x20, %rax
movq %rax, (%rdx)
leaq 0x1831f(%rip), %rax     # 0x20f57
testq %rcx, %rcx
je 0x8c8d
movq %rdi, (%rcx)
retq
testl %esi, %esi
jle 0x8c51
movq (%rdi), %rdi
movq 0x18(%rdi), %rax
cmpl %esi, 0x50(%rax)
jge 0x8c54
xorl %eax, %eax
retq
decl %esi
movq 0x20(%rdi,%rsi,8), %r8
movq 0x10(%r8), %r8
movq %r8, (%rdx)
testq %rcx, %rcx
je 0x8c6f
movq 0x20(%rdi,%rsi,8), %rdx
movq %rdx, (%rcx)
movq 0x38(%rax), %rax
shlq $0x4, %rsi
movq (%rax,%rsi), %rax
leaq 0x18(%rax), %rcx
testq %rax, %rax
leaq 0x182ce(%rip), %rax     # 0x20f57
cmovneq %rcx, %rax
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lapi.c
// Function: lua_setupvalue
LUA_API const char *lua_setupvalue (lua_State *L, int funcindex, int n) {
  const char *name;
  TValue *val = NULL;  /* to avoid warnings */
  GCObject *owner = NULL;  /* to avoid warnings */
  StkId fi;
  lua_lock(L);
  fi = index2addr(L, funcindex);
  api_checknelems(L, 1);
  name = aux_upvalue(fi, n, &val, &owner);
  if (name) {
    L->top--;
    setobj(L, val, L->top);
    luaC_barrier(L, owner, L->top);
  }
  lua_unlock(L);
  return name;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movl %edx, %ebp
movq %rdi, %rbx
xorl %eax, %eax
leaq 0x10(%rsp), %r14
movq %rax, (%r14)
leaq 0x8(%rsp), %r15
movq %rax, (%r15)
callq 0x781c
movq %rax, %rdi
movl %ebp, %esi
movq %r14, %rdx
movq %r15, %rcx
callq 0x8c01
movq %rax, %r14
testq %rax, %rax
je 0x8d10
movq 0x10(%rbx), %rax
leaq -0x10(%rax), %rcx
movq %rcx, 0x10(%rbx)
movq 0x10(%rsp), %rcx
movq -0x10(%rax), %rdx
movq %rdx, (%rcx)
movl -0x8(%rax), %eax
movl %eax, 0x8(%rcx)
movq 0x10(%rbx), %rax
testb $0x40, 0x8(%rax)
je 0x8d10
movq (%rax), %rdx
testb $0x3, 0x9(%rdx)
je 0x8d10
movq 0x8(%rsp), %rsi
testb $0x4, 0x9(%rsi)
je 0x8d10
movq %rbx, %rdi
callq 0xc950
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lapi.c
// Function: lua_upvaluejoin
LUA_API void lua_upvaluejoin (lua_State *L, int fidx1, int n1,
                                            int fidx2, int n2) {
  LClosure *f1;
  UpVal **up1 = getupvalref(L, fidx1, n1, &f1);
  UpVal **up2 = getupvalref(L, fidx2, n2, NULL);
  *up1 = *up2;
  luaC_objbarrier(L, f1, *up2);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r8d, %ebp
movl %ecx, %r15d
movl %edx, %r12d
movq %rdi, %rbx
callq 0x781c
movq (%rax), %r14
movslq %r12d, %r12
movq %rbx, %rdi
movl %r15d, %esi
callq 0x781c
movq (%rax), %rax
movslq %ebp, %rcx
movq 0x18(%rax,%rcx,8), %rdx
movq %rdx, 0x18(%r14,%r12,8)
testb $0x3, 0x9(%rdx)
je 0x8db6
testb $0x4, 0x9(%r14)
jne 0x8dbf
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %rdi
movq %r14, %rsi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0xc950
nop
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_argerror
LUALIB_API int luaL_argerror (lua_State *L, int narg, const char *extramsg) {
  lua_Debug ar;
  if (!lua_getstack(L, 0, &ar))  /* no stack frame? */
    return luaL_error(L, "bad argument #%d (%s)", narg, extramsg);
  lua_getinfo(L, "n", &ar);
  if (strcmp(ar.namewhat, "method") == 0) {
    narg--;  /* do not count `self' */
    if (narg == 0)  /* error is in the self argument itself? */
      return luaL_error(L, "calling " LUA_QS " on bad self (%s)",
                           ar.name, extramsg);
  }
  if (ar.name == NULL)
    ar.name = (pushglobalfuncname(L, &ar)) ? lua_tostring(L, -1) : "?";
  return luaL_error(L, "bad argument #%d to " LUA_QS " (%s)",
                        narg, ar.name, extramsg);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x88, %rsp
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
leaq 0x8(%rsp), %rdx
xorl %esi, %esi
callq 0xa684
testl %eax, %eax
je 0x90e1
leaq 0x18ba3(%rip), %rsi     # 0x21c2d
leaq 0x8(%rsp), %r15
movq %r14, %rdi
movq %r15, %rdx
callq 0xa879
movq 0x10(%r15), %rdi
leaq 0x177bb(%rip), %rsi     # 0x20860
callq 0x62e0
testl %eax, %eax
jne 0x90b2
decl %ebp
je 0x90f9
movq 0x10(%rsp), %rcx
testq %rcx, %rcx
jne 0x9120
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x9200
testl %eax, %eax
je 0x9114
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x7cea
movq %rax, %rcx
jmp 0x911b
leaq 0x17380(%rip), %rsi     # 0x20468
movq %r14, %rdi
movl %ebp, %edx
movq %rbx, %rcx
xorl %eax, %eax
callq 0x9144
jmp 0x9136
movq 0x10(%rsp), %rdx
leaq 0x17379(%rip), %rsi     # 0x2047e
movq %r14, %rdi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x9144
jmp 0x9136
leaq 0x17729(%rip), %rcx     # 0x20844
movq %rcx, 0x10(%rsp)
leaq 0x17375(%rip), %rsi     # 0x2049c
movq %r14, %rdi
movl %ebp, %edx
movq %rbx, %r8
xorl %eax, %eax
callq 0x9144
addq $0x88, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: pushglobalfuncname
static int pushglobalfuncname (lua_State *L, lua_Debug *ar) {
  int top = lua_gettop(L);
  lua_getinfo(L, "f", ar);  /* push function */
  lua_pushglobaltable(L);
  if (findfield(L, top + 1, 2)) {
    lua_copy(L, -1, top + 1);  /* move name to proper place */
    lua_pop(L, 2);  /* remove pushed values */
    return 1;
  }
  else {
    lua_settop(L, top);  /* remove function and global table */
    return 0;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
callq 0x7674
movl %eax, %r14d
leaq 0x173a3(%rip), %rsi     # 0x205bf
movq %rbx, %rdi
movq %r15, %rdx
callq 0xa879
movq %rbx, %rdi
movl $0xfff0b9d8, %esi       # imm = 0xFFF0B9D8
movl $0x2, %edx
callq 0x8249
leal 0x1(%r14), %ebp
movq %rbx, %rdi
movl %ebp, %esi
movl $0x2, %edx
callq 0xa53c
testl %eax, %eax
je 0x926c
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl %ebp, %edx
callq 0x7953
movl $0x1, %ebp
movl $0xfffffffd, %r14d      # imm = 0xFFFFFFFD
jmp 0x926e
xorl %ebp, %ebp
movq %rbx, %rdi
movl %r14d, %esi
callq 0x7688
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_execresult
LUALIB_API int luaL_execresult (lua_State *L, int stat) {
  const char *what = "exit";  /* type of termination */
  if (stat == -1)  /* error? */
    return luaL_fileresult(L, 0, NULL);
  else {
    inspectstat(stat, what);  /* interpret result */
    if (*what == 'e' && stat == 0)  /* successful termination? */
      lua_pushboolean(L, 1);
    else
      lua_pushnil(L);
    lua_pushstring(L, what);
    lua_pushinteger(L, stat);
    return 3;  /* return true/nil,what,code */
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpl $-0x1, %esi
je 0x93b9
movl %esi, %ebp
movl %esi, %eax
andl $0x7f, %eax
je 0x93cf
movl %eax, %ecx
shll $0x18, %ecx
addl $0x1000000, %ecx        # imm = 0x1000000
cmpl $0x2000000, %ecx        # imm = 0x2000000
cmovgel %eax, %ebp
leaq 0x1711e(%rip), %rax     # 0x204ca
leaq 0x17112(%rip), %r14     # 0x204c5
cmovgeq %rax, %r14
jmp 0x93e1
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x92f4
shrl $0x8, %ebp
andl $0xff, %ebp
je 0x9412
leaq 0x170e4(%rip), %r14     # 0x204c5
movq %rbx, %rdi
callq 0x7e6c
movslq %ebp, %r15
movq %rbx, %rdi
movq %r14, %rsi
callq 0x7f1a
movq %rbx, %rdi
movq %r15, %rsi
callq 0x7e95
movl $0x3, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %rdi
movl $0x1, %esi
callq 0x80e5
leaq 0x1709f(%rip), %r14     # 0x204c5
xorl %r15d, %r15d
jmp 0x93ec
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_newmetatable
LUALIB_API int luaL_newmetatable (lua_State *L, const char *tname) {
  luaL_getmetatable(L, tname);  /* try to get metatable */
  if (!lua_isnil(L, -1))  /* name already in use? */
    return 0;  /* leave previous value on top, but return 0 */
  lua_pop(L, 1);
  lua_newtable(L);  /* create metatable */
  lua_pushvalue(L, -1);
  lua_setfield(L, LUA_REGISTRYINDEX, tname);  /* registry.name = metatable */
  return 1;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl $0xfff0b9d8, %esi       # imm = 0xFFF0B9D8
movq %rbx, %rdx
callq 0x81c3
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x7992
movl %eax, %ecx
xorl %eax, %eax
testl %ecx, %ecx
jne 0x9492
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x7688
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x82c4
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x7972
movq %r14, %rdi
movl $0xfff0b9d8, %esi       # imm = 0xFFF0B9D8
movq %rbx, %rdx
callq 0x844e
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_checkoption
LUALIB_API int luaL_checkoption (lua_State *L, int narg, const char *def,
                                 const char *const lst[]) {
  const char *name = (def) ? luaL_optstring(L, narg, def) :
                             luaL_checkstring(L, narg);
  int i;
  for (i=0; lst[i]; i++)
    if (strcmp(lst[i], name) == 0)
      return i;
  return luaL_argerror(L, narg,
                       lua_pushfstring(L, "invalid option " LUA_QS, name));
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %r15
movl %esi, %ebx
movq %rdi, %r14
testq %rdx, %rdx
je 0x95cd
movq %rdx, %r12
movq %r14, %rdi
movl %ebx, %esi
callq 0x7992
testl %eax, %eax
jle 0x95dc
movq %r14, %rdi
movl %ebx, %esi
xorl %edx, %edx
callq 0x9690
movq %rax, %r12
movq (%r15), %rdi
testq %rdi, %rdi
je 0x9600
xorl %r13d, %r13d
movq %r12, %rsi
callq 0x62e0
testl %eax, %eax
je 0x962a
movq 0x8(%r15,%r13,8), %rdi
incq %r13
testq %rdi, %rdi
jne 0x95e7
leaq 0x16eca(%rip), %rsi     # 0x204d1
movq %r14, %rdi
movq %r12, %rdx
xorl %eax, %eax
callq 0x7fb4
movq %r14, %rdi
movl %ebx, %esi
movq %rax, %rdx
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x905e
movl %r13d, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_optlstring
LUALIB_API const char *luaL_optlstring (lua_State *L, int narg,
                                        const char *def, size_t *len) {
  if (lua_isnoneornil(L, narg)) {
    if (len)
      *len = (def ? strlen(def) : 0);
    return def;
  }
  else return luaL_checklstring(L, narg, len);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %r15
callq 0x7992
testl %eax, %eax
jle 0x9669
movq %r15, %rdi
movl %ebp, %esi
movq %rbx, %rdx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x9690
testq %rbx, %rbx
je 0x9682
testq %r14, %r14
je 0x967d
movq %r14, %rdi
callq 0x6170
jmp 0x967f
xorl %eax, %eax
movq %rax, (%rbx)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_checkstack
LUALIB_API void luaL_checkstack (lua_State *L, int space, const char *msg) {
  /* keep some extra space to run error routines, if needed */
  const int extra = LUA_MINSTACK;
  if (!lua_checkstack(L, space + extra)) {
    if (msg)
      luaL_error(L, "stack overflow (%s)", msg);
    else
      luaL_error(L, "stack overflow");
  }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rdi, %rbx
addl $0x14, %esi
callq 0x7550
testl %eax, %eax
je 0x96e8
addq $0x8, %rsp
popq %rbx
popq %r14
retq
testq %r14, %r14
je 0x9708
leaq 0x16df1(%rip), %rsi     # 0x204e5
movq %rbx, %rdi
movq %r14, %rdx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x9144
leaq 0x1717f(%rip), %rsi     # 0x2088e
movq %rbx, %rdi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x9144
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_checknumber
LUALIB_API lua_Number luaL_checknumber (lua_State *L, int narg) {
  int isnum;
  lua_Number d = lua_tonumberx(L, narg, &isnum);
  if (!isnum)
    tag_error(L, narg, LUA_TNUMBER);
  return d;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %ebx
movq %rdi, %r14
leaq 0xc(%rsp), %r15
movq %r15, %rdx
callq 0x7be3
cmpl $0x0, (%r15)
jne 0x97cc
movq %r14, %rdi
movl $0x3, %esi
movsd %xmm0, (%rsp)
callq 0x79b3
movq %r14, %rdi
movl %ebx, %esi
movq %rax, %rdx
callq 0x9563
movsd (%rsp), %xmm0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_checkinteger
LUALIB_API lua_Integer luaL_checkinteger (lua_State *L, int narg) {
  int isnum;
  lua_Integer d = lua_tointegerx(L, narg, &isnum);
  if (!isnum)
    tag_error(L, narg, LUA_TNUMBER);
  return d;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
leaq 0x4(%rsp), %r12
movq %r12, %rdx
callq 0x7c2b
movq %rax, %r15
cmpl $0x0, (%r12)
jne 0x9849
movq %r14, %rdi
movl $0x3, %esi
callq 0x79b3
movq %r14, %rdi
movl %ebx, %esi
movq %rax, %rdx
callq 0x9563
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_checkunsigned
LUALIB_API lua_Unsigned luaL_checkunsigned (lua_State *L, int narg) {
  int isnum;
  lua_Unsigned d = lua_tounsignedx(L, narg, &isnum);
  if (!isnum)
    tag_error(L, narg, LUA_TNUMBER);
  return d;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
leaq 0x4(%rsp), %r15
movq %r15, %rdx
callq 0x7c6e
movl %eax, %ebp
cmpl $0x0, (%r15)
jne 0x9893
movq %r14, %rdi
movl $0x3, %esi
callq 0x79b3
movq %r14, %rdi
movl %ebx, %esi
movq %rax, %rdx
callq 0x9563
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_prepbuffsize
LUALIB_API char *luaL_prepbuffsize (luaL_Buffer *B, size_t sz) {
  lua_State *L = B->L;
  if (B->size - B->n < sz) {  /* not enough space? */
    char *newbuff;
    size_t newsize = B->size * 2;  /* double buffer size */
    if (newsize - B->n < sz)  /* not big enough? */
      newsize = B->n + sz;
    if (newsize < B->n || newsize - B->n < sz)
      luaL_error(L, "buffer too large");
    /* create larger buffer */
    newbuff = (char *)lua_newuserdata(L, newsize * sizeof(char));
    /* move content to new buffer */
    memcpy(newbuff, B->b, B->n * sizeof(char));
    if (buffonstack(B))
      lua_remove(L, -2);  /* remove old buffer */
    B->b = newbuff;
    B->size = newsize;
  }
  return &B->b[B->n];
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rcx
movq 0x10(%rdi), %rax
movq %rcx, %rdx
subq %rax, %rdx
cmpq %rsi, %rdx
jae 0x9993
addq %rcx, %rcx
movq %rcx, %rdx
subq %rax, %rdx
leaq (%rax,%rsi), %r14
cmpq %rsi, %rdx
cmovaeq %rcx, %r14
movq 0x18(%rbx), %r15
movq %r14, %rcx
subq %rax, %rcx
setb %al
notb %al
cmpq %rsi, %rcx
setae %cl
testb %cl, %al
jne 0x9953
leaq 0x16bbf(%rip), %rsi     # 0x20508
movq %r15, %rdi
xorl %eax, %eax
callq 0x9144
movq %r15, %rdi
movq %r14, %rsi
callq 0x8b63
movq %rax, %r12
movq (%rbx), %rsi
movq 0x10(%rbx), %rdx
movq %rax, %rdi
callq 0x6360
leaq 0x20(%rbx), %rax
cmpq %rax, (%rbx)
je 0x9986
movq %r15, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x77ed
movq %r12, (%rbx)
movq %r14, 0x8(%rbx)
movq 0x10(%rbx), %rax
jmp 0x9996
movq (%rbx), %r12
addq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_pushresult
LUALIB_API void luaL_pushresult (luaL_Buffer *B) {
  lua_State *L = B->L;
  lua_pushlstring(L, B->b, B->n);
  if (buffonstack(B))
    lua_remove(L, -2);  /* remove old buffer */
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x18(%rdi), %rbx
movq (%rdi), %rsi
movq 0x10(%rdi), %rdx
movq %rbx, %rdi
callq 0x7ecb
leaq 0x20(%r14), %rax
cmpq %rax, (%r14)
je 0x9a43
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x77ed
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_getmetafield
LUALIB_API int luaL_getmetafield (lua_State *L, int obj, const char *event) {
  if (!lua_getmetatable(L, obj))  /* no metatable? */
    return 0;
  lua_pushstring(L, event);
  lua_rawget(L, -2);
  if (lua_isnil(L, -1)) {
    lua_pop(L, 2);  /* remove metatable and metafield */
    return 0;
  }
  else {
    lua_remove(L, -2);  /* remove only metatable */
    return 1;
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rdi, %r14
callq 0x8323
xorl %ebx, %ebx
testl %eax, %eax
je 0x9fd6
movq %r14, %rdi
movq %r15, %rsi
callq 0x7f1a
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x821d
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x7992
movq %r14, %rdi
testl %eax, %eax
je 0x9fcc
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x77ed
movl $0x1, %ebx
jmp 0x9fd6
movl $0xfffffffd, %esi       # imm = 0xFFFFFFFD
callq 0x7688
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_callmeta
LUALIB_API int luaL_callmeta (lua_State *L, int obj, const char *event) {
  obj = lua_absindex(L, obj);
  if (!luaL_getmetafield(L, obj, event))  /* no metafield? */
    return 0;
  lua_pushvalue(L, obj);
  lua_call(L, 1, 1);
  return 1;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rdi, %rbx
callq 0x7653
movl %eax, %ebp
movq %rbx, %rdi
movl %eax, %esi
movq %r14, %rdx
callq 0x9f79
testl %eax, %eax
je 0xa028
movq %rbx, %rdi
movl %ebp, %esi
callq 0x7972
movl $0x1, %ebp
movq %rbx, %rdi
movl $0x1, %esi
movl $0x1, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x8715
jmp 0xa02a
xorl %ebp, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_len
LUALIB_API int luaL_len (lua_State *L, int idx) {
  int l;
  int isnum;
  lua_len(L, idx);
  l = (int)lua_tointegerx(L, -1, &isnum);
  if (!isnum)
    luaL_error(L, "object length is not a number");
  lua_pop(L, 1);  /* remove object */
  return l;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
callq 0x8b20
leaq 0xc(%rsp), %r15
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movq %r15, %rdx
callq 0x7c2b
movq %rax, %r14
cmpl $0x0, (%r15)
jne 0xa071
leaq 0x164c0(%rip), %rsi     # 0x20527
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9144
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x7688
movl %r14d, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_checkversion_
LUALIB_API void luaL_checkversion_ (lua_State *L, lua_Number ver) {
  const lua_Number *v = lua_version(L);
  if (v != lua_version(NULL))
    luaL_error(L, "multiple Lua VMs detected");
  else if (*v != ver)
    luaL_error(L, "version mismatch: app. needs %f, Lua core provides %f",
                  ver, *v);
  /* check conversions number -> integer types */
  lua_pushnumber(L, -(lua_Number)0x1234);
  if (lua_tointeger(L, -1) != -0x1234 ||
      lua_tounsigned(L, -1) != (lua_Unsigned)-0x1234)
    luaL_error(L, "bad conversion number->int;"
                  " must recompile Lua with proper settings");
  lua_pop(L, 1);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movsd %xmm0, (%rsp)
movq %rdi, %rbx
callq 0x763a
movq %rax, %r14
xorl %edi, %edi
callq 0x763a
cmpq %rax, %r14
je 0xa231
leaq 0x1634c(%rip), %rsi     # 0x20571
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9144
jmp 0xa254
movsd (%r14), %xmm1
movsd (%rsp), %xmm0
ucomisd %xmm0, %xmm1
jne 0xa243
jnp 0xa254
leaq 0x16341(%rip), %rsi     # 0x2058b
movq %rbx, %rdi
movb $0x2, %al
callq 0x9144
movsd 0x161c4(%rip), %xmm0    # 0x20420
movq %rbx, %rdi
callq 0x7e80
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x7c2b
cmpq $-0x1234, %rax          # imm = 0xEDCC
jne 0xa291
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x7c6e
cmpl $0xffffedcc, %eax       # imm = 0xFFFFEDCC
je 0xa2a2
leaq 0x16329(%rip), %rsi     # 0x205c1
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9144
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x7688
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_getsubtable
LUALIB_API int luaL_getsubtable (lua_State *L, int idx, const char *fname) {
  lua_getfield(L, idx, fname);
  if (lua_istable(L, -1)) return 1;  /* table already there */
  else {
    lua_pop(L, 1);  /* remove previous result */
    idx = lua_absindex(L, idx);
    lua_newtable(L);
    lua_pushvalue(L, -1);  /* copy to be left at top */
    lua_setfield(L, idx, fname);  /* assign new table to field */
    return 0;  /* false, because did not find table there */
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
callq 0x81c3
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x7992
movl $0x1, %r15d
cmpl $0x5, %eax
je 0xa324
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x7688
movq %r14, %rdi
movl %ebp, %esi
callq 0x7653
movl %eax, %ebp
xorl %r15d, %r15d
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x82c4
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x7972
movq %r14, %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x844e
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/lauxlib.c
// Function: luaL_requiref
LUALIB_API void luaL_requiref (lua_State *L, const char *modname,
                               lua_CFunction openf, int glb) {
  lua_pushcfunction(L, openf);
  lua_pushstring(L, modname);  /* argument to open function */
  lua_call(L, 1, 1);  /* open module */
  luaL_getsubtable(L, LUA_REGISTRYINDEX, "_LOADED");
  lua_pushvalue(L, -2);  /* make copy of module (call result) */
  lua_setfield(L, -2, modname);  /* _LOADED[modname] = module */
  lua_pop(L, 1);  /* remove _LOADED table */
  if (glb) {
    lua_pushvalue(L, -1);  /* copy of 'mod' */
    lua_setglobal(L, modname);  /* _G[modname] = module */
  }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %ecx, %ebp
movq %rsi, %rbx
movq %rdi, %r14
movq %rdx, %rsi
xorl %edx, %edx
callq 0x8061
movq %r14, %rdi
movq %rbx, %rsi
callq 0x7f1a
movq %r14, %rdi
movl $0x1, %esi
movl $0x1, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x8715
leaq 0x161f8(%rip), %rdx     # 0x20569
movq %r14, %rdi
movl $0xfff0b9d8, %esi       # imm = 0xFFF0B9D8
callq 0xa2b6
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x7972
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %rbx, %rdx
callq 0x844e
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x7688
testl %ebp, %ebp
je 0xa3c8
movq %r14, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x7972
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x83b4
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldebug.c
// Function: lua_setlocal
LUA_API const char *lua_setlocal (lua_State *L, const lua_Debug *ar, int n) {
  StkId pos = 0;  /* to avoid warnings */
  const char *name = findlocal(L, ar->i_ci, n, &pos);
  lua_lock(L);
  if (name)
    setobjs2s(L, pos, L->top - 1);
  L->top--;  /* pop value */
  lua_unlock(L);
  return name;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %rcx
movq $0x0, (%rcx)
movq 0x78(%rsi), %rsi
callq 0xa74c
testq %rax, %rax
je 0xa86e
movq 0x10(%rbx), %rcx
movq 0x8(%rsp), %rdx
movq -0x10(%rcx), %rsi
movq %rsi, (%rdx)
movl -0x8(%rcx), %ecx
movl %ecx, 0x8(%rdx)
addq $-0x10, 0x10(%rbx)
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldebug.c
// Function: luaG_typeerror
l_noret luaG_typeerror (lua_State *L, const TValue *o, const char *op) {
  CallInfo *ci = L->ci;
  const char *name = NULL;
  const char *t = objtypename(o);
  const char *kind = NULL;
  if (isLua(ci)) {
    kind = getupvalname(ci, o, &name);  /* check whether 'o' is an upvalue */
    if (!kind && isinstack(ci, o))  /* no? try a register */
      kind = getobjname(ci_func(ci)->p, currentpc(ci),
                        cast_int(o - ci->u.l.base), &name);
  }
  if (kind)
    luaG_runerror(L, "attempt to %s %s " LUA_QS " (a %s value)",
                op, kind, name, t);
  else
    luaG_runerror(L, "attempt to %s a %s value", op, t);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %rdx
movq %rdi, %r15
movq 0x20(%rdi), %rax
movq $0x0, 0x8(%rsp)
movl 0x8(%rsi), %ecx
andl $0xf, %ecx
leaq 0x21b7c(%rip), %rsi     # 0x2c840
movq 0x8(%rsi,%rcx,8), %r14
testb $0x1, 0x22(%rax)
je 0xad6a
movq (%rax), %rcx
movq (%rcx), %rcx
movzbl 0xa(%rcx), %esi
testq %rsi, %rsi
je 0xacfb
shll $0x3, %esi
xorl %edi, %edi
movq 0x20(%rcx,%rdi), %r8
cmpq %rdx, 0x10(%r8)
je 0xad1b
addq $0x8, %rdi
cmpq %rdi, %rsi
jne 0xace7
movq 0x8(%rax), %rsi
movq 0x30(%rax), %r8
cmpq %rsi, %r8
jae 0xad6a
movq %r8, %rdi
cmpq %rdx, %rdi
je 0xad42
addq $0x10, %rdi
cmpq %rsi, %rdi
jb 0xad0b
jmp 0xad6a
movq 0x18(%rcx), %rax
movq 0x38(%rax), %rax
movq (%rax,%rdi,2), %rax
leaq 0x18(%rax), %rcx
testq %rax, %rax
leaq 0x15b0f(%rip), %r8      # 0x20844
cmovneq %rcx, %r8
leaq 0x17816(%rip), %rcx     # 0x22556
jmp 0xad89
movq 0x18(%rcx), %rdi
movq 0x38(%rax), %rsi
subq 0x18(%rdi), %rsi
shrq $0x2, %rsi
decl %esi
subq %r8, %rdx
shrq $0x4, %rdx
leaq 0x8(%rsp), %rcx
callq 0xada0
testq %rax, %rax
jne 0xad81
leaq 0x15a3a(%rip), %rsi     # 0x207ab
movq %r15, %rdi
movq %rbx, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0xb027
movq %rax, %rcx
movq 0x8(%rsp), %r8
leaq 0x159f8(%rip), %rsi     # 0x20788
movq %r15, %rdi
movq %rbx, %rdx
movq %r14, %r9
xorl %eax, %eax
callq 0xb027
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldebug.c
// Function: luaG_runerror
l_noret luaG_runerror (lua_State *L, const char *fmt, ...) {
  va_list argp;
  va_start(argp, fmt);
  addinfo(L, luaO_pushvfstring(L, fmt, argp));
  va_end(argp);
  luaG_errormsg(L);
}

// Assembly:
pushq %rbx
subq $0xd0, %rsp
movq %rdi, %rbx
leaq 0x20(%rsp), %rdi
movq %rdx, 0x10(%rdi)
movq %rcx, 0x18(%rdi)
movq %r8, 0x20(%rdi)
movq %r9, 0x28(%rdi)
testb %al, %al
je 0xb082
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
movq %rsp, %rdx
movq %rdi, 0x10(%rdx)
leaq 0xe0(%rsp), %rax
movq %rax, 0x8(%rdx)
movabsq $0x3000000010, %rax     # imm = 0x3000000010
movq %rax, (%rdx)
movq %rbx, %rdi
callq 0x10ba1
movq %rbx, %rdi
movq %rax, %rsi
callq 0xb1d2
movq %rbx, %rdi
callq 0xb158
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldebug.c
// Function: luaG_ordererror
l_noret luaG_ordererror (lua_State *L, const TValue *p1, const TValue *p2) {
  const char *t1 = objtypename(p1);
  const char *t2 = objtypename(p2);
  if (t1 == t2)
    luaG_runerror(L, "attempt to compare two %s values", t1);
  else
    luaG_runerror(L, "attempt to compare %s with %s", t1, t2);
}

// Assembly:
pushq %rax
movq %rdx, %rax
movl 0x8(%rsi), %ecx
andl $0xf, %ecx
leaq 0x21719(%rip), %rsi     # 0x2c840
movq 0x8(%rsi,%rcx,8), %rdx
movl 0x8(%rax), %eax
andl $0xf, %eax
movq 0x8(%rsi,%rax,8), %rcx
cmpq %rcx, %rdx
jne 0xb14a
leaq 0x156a3(%rip), %rsi     # 0x207e6
xorl %eax, %eax
callq 0xb027
leaq 0x156b6(%rip), %rsi     # 0x20807
xorl %eax, %eax
callq 0xb027
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldebug.c
// Function: luaG_errormsg
l_noret luaG_errormsg (lua_State *L) {
  if (L->errfunc != 0) {  /* is there an error handling function? */
    StkId errfunc = restorestack(L, L->errfunc);
    if (!ttisfunction(errfunc)) luaD_throw(L, LUA_ERRERR);
    setobjs2s(L, L->top, L->top - 1);  /* move argument */
    setobjs2s(L, L->top - 1, errfunc);  /* push function */
    L->top++;
    luaD_call(L, L->top - 2, 1, 0);  /* call it */
  }
  luaD_throw(L, LUA_ERRRUN);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq 0x78(%rdi), %rax
testq %rax, %rax
je 0xb1b8
movq 0x38(%rbx), %rcx
movl 0x8(%rcx,%rax), %edx
andl $0xf, %edx
cmpl $0x6, %edx
jne 0xb1c5
movq 0x10(%rbx), %rdx
movq -0x10(%rdx), %rsi
movq %rsi, (%rdx)
movl -0x8(%rdx), %esi
movl %esi, 0x8(%rdx)
movq 0x10(%rbx), %rdx
movq (%rcx,%rax), %rsi
movq %rsi, -0x10(%rdx)
movl 0x8(%rcx,%rax), %eax
movl %eax, -0x8(%rdx)
movq 0x10(%rbx), %rsi
leaq 0x10(%rsi), %rax
movq %rax, 0x10(%rbx)
addq $-0x10, %rsi
movq %rbx, %rdi
movl $0x1, %edx
xorl %ecx, %ecx
callq 0xbafd
movq %rbx, %rdi
movl $0x2, %esi
callq 0xb2c0
movq %rbx, %rdi
movl $0x6, %esi
callq 0xb2c0
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldebug.c
// Function: addinfo
static void addinfo (lua_State *L, const char *msg) {
  CallInfo *ci = L->ci;
  if (isLua(ci)) {  /* is Lua code? */
    char buff[LUA_IDSIZE];  /* add file:line information */
    int line = currentline(ci);
    TString *src = ci_func(ci)->p->source;
    if (src)
      luaO_chunkid(buff, getstr(src), LUA_IDSIZE);
    else {  /* no source available; use "?" instead */
      buff[0] = '?'; buff[1] = '\0';
    }
    luaO_pushfstring(L, "%s:%d: %s", buff, line, msg);
  }
}

// Assembly:
movq 0x20(%rdi), %rdx
testb $0x1, 0x22(%rdx)
je 0xb268
pushq %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq (%rdx), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rcx
testq %rcx, %rcx
je 0xb223
movq 0x38(%rdx), %rdx
subq 0x18(%rax), %rdx
shlq $0x1e, %rdx
movabsq $-0x100000000, %rsi     # imm = 0xFFFFFFFF00000000
addq %rdx, %rsi
sarq $0x20, %rsi
movl (%rcx,%rsi,4), %ebp
jmp 0xb225
xorl %ebp, %ebp
movq 0x48(%rax), %rsi
testq %rsi, %rsi
je 0xb241
addq $0x18, %rsi
movq %rsp, %rdi
movl $0x3c, %edx
callq 0x10f5e
jmp 0xb247
movw $0x3f, (%rsp)
leaq 0x15634(%rip), %rsi     # 0x20882
movq %rsp, %rdx
movq %r14, %rdi
movl %ebp, %ecx
movq %rbx, %r8
xorl %eax, %eax
callq 0x10eda
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: luaD_throw
l_noret luaD_throw (lua_State *L, int errcode) {
  if (L->errorJmp) {  /* thread has an error handler? */
    L->errorJmp->status = errcode;  /* set status */
    LUAI_THROW(L, L->errorJmp);  /* jump to it */
  }
  else {  /* thread has no error handler */
    L->status = cast_byte(errcode);  /* mark it as dead */
    if (G(L)->mainthread->errorJmp) {  /* main thread has a handler? */
      setobjs2s(L, G(L)->mainthread->top++, L->top - 1);  /* copy error obj. */
      luaD_throw(G(L)->mainthread, errcode);  /* re-throw in main thread */
    }
    else {  /* no handler at all; abort */
      if (G(L)->panic) {  /* panic function? */
        lua_unlock(L);
        G(L)->panic(L);  /* call it (last chance to jump out) */
      }
      abort();
    }
  }
}

// Assembly:
pushq %rax
movq 0x70(%rdi), %rax
testq %rax, %rax
jne 0xb2f3
movb %sil, 0xa(%rdi)
movq 0x18(%rdi), %rcx
movq 0x108(%rcx), %rax
cmpq $0x0, 0x70(%rax)
jne 0xb30a
movq 0x100(%rcx), %rax
testq %rax, %rax
je 0xb2ee
callq *%rax
callq 0x6070
movl %esi, 0xd0(%rax)
addq $0x8, %rax
movq %rax, %rdi
movl $0x1, %esi
callq 0x6460
movq 0x10(%rdi), %rcx
movq 0x10(%rax), %rdx
leaq 0x10(%rdx), %r8
movq %r8, 0x10(%rax)
movq -0x10(%rcx), %rax
movq %rax, (%rdx)
movl -0x8(%rcx), %eax
movl %eax, 0x8(%rdx)
movq 0x18(%rdi), %rax
movq 0x108(%rax), %rdi
callq 0xb2c0
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: luaD_shrinkstack
static int stackinuse (lua_State *L) {
  CallInfo *ci;
  StkId lim = L->top;
  for (ci = L->ci; ci != NULL; ci = ci->previous) {
    lua_assert(ci->top <= L->stack_last);
    if (lim < ci->top) lim = ci->top;
  }
  return cast_int(lim - L->stack) + 1;  /* part of stack in use */
}

// Assembly:
movq 0x10(%rdi), %rax
movq 0x20(%rdi), %rcx
testq %rcx, %rcx
je 0xb61c
movq 0x8(%rcx), %rdx
movq 0x10(%rcx), %rcx
cmpq %rdx, %rax
cmovbq %rdx, %rax
jmp 0xb606
subq 0x38(%rdi), %rax
shrq $0x4, %rax
leal 0x1(%rax), %ecx
leal 0x8(%rax), %edx
testl %ecx, %ecx
cmovnsl %ecx, %edx
sarl $0x3, %edx
leal (%rdx,%rax), %ecx
incl %ecx
movl $0xf4236, %esi          # imm = 0xF4236
cmpl %esi, %ecx
cmovll %ecx, %esi
cmpl $0xf423f, %eax          # imm = 0xF423F
jg 0xb654
addl $0xa, %esi
cmpl 0x40(%rdi), %esi
jl 0xb3a1
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: luaD_poscall
int luaD_poscall (lua_State *L, StkId firstResult) {
  StkId res;
  int wanted, i;
  CallInfo *ci = L->ci;
  if (L->hookmask & (LUA_MASKRET | LUA_MASKLINE)) {
    if (L->hookmask & LUA_MASKRET) {
      ptrdiff_t fr = savestack(L, firstResult);  /* hook may change stack */
      luaD_hook(L, LUA_HOOKRET, -1);
      firstResult = restorestack(L, fr);
    }
    L->oldpc = ci->previous->u.l.savedpc;  /* 'oldpc' for caller function */
  }
  res = ci->func;  /* res == final position of 1st result */
  wanted = ci->nresults;
  L->ci = ci = ci->previous;  /* back to caller */
  /* move results to correct place */
  for (i = wanted; i != 0 && firstResult < L->top; i--)
    setobjs2s(L, res++, firstResult++);
  while (i-- > 0)
    setnilvalue(res++);
  L->top = res;
  return (wanted - LUA_MULTRET);  /* 0 iff wanted == LUA_MULTRET */
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq 0x20(%rdi), %r15
movzbl 0x48(%rdi), %eax
testb $0x6, %al
je 0xba8d
testb $0x2, %al
je 0xba7f
subq 0x38(%rbx), %r14
movq %rbx, %rdi
movl $0x1, %esi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0xb655
addq 0x38(%rbx), %r14
movq 0x10(%r15), %rcx
movq 0x38(%rcx), %rax
movq %rax, 0x28(%rbx)
jmp 0xba91
movq 0x10(%r15), %rcx
movq (%r15), %rdx
movswl 0x20(%r15), %eax
movq %rcx, 0x20(%rbx)
testl %eax, %eax
je 0xbaee
leal 0x1(%rax), %ecx
xorl %edi, %edi
cmpq 0x10(%rbx), %r14
jae 0xbacd
leaq 0x10(%rdx), %rsi
movq (%r14), %r8
movq %r8, (%rdx)
movl 0x8(%r14), %r8d
movl %r8d, 0x8(%rdx)
incl %edi
addq $0x10, %r14
movq %rsi, %rdx
cmpl %edi, %eax
jne 0xbaa6
jmp 0xbaf1
movl %eax, %esi
subl %edi, %esi
testl %esi, %esi
jle 0xbaee
subl %edi, %ecx
movq %rdx, %rsi
movl $0x0, 0x8(%rsi)
addq $0x10, %rsi
decl %ecx
cmpl $0x1, %ecx
ja 0xbada
jmp 0xbaf1
movq %rdx, %rsi
movq %rsi, 0x10(%rbx)
incl %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: luaD_call
void luaD_call (lua_State *L, StkId func, int nResults, int allowyield) {
  if (++L->nCcalls >= LUAI_MAXCCALLS) {
    if (L->nCcalls == LUAI_MAXCCALLS)
      luaG_runerror(L, "C stack overflow");
    else if (L->nCcalls >= (LUAI_MAXCCALLS + (LUAI_MAXCCALLS>>3)))
      luaD_throw(L, LUA_ERRERR);  /* error while handing stack error */
  }
  if (!allowyield) L->nny++;
  if (!luaD_precall(L, func, nResults))  /* is a Lua function? */
    luaV_execute(L);  /* call it */
  if (!allowyield) L->nny--;
  L->nCcalls--;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %ecx, %ebp
movq %rdi, %rbx
movzwl 0x46(%rdi), %eax
incl %eax
movw %ax, 0x46(%rdi)
movzwl %ax, %eax
cmpl $0xc8, %eax
jb 0xbb22
je 0xbb51
cmpl $0xe1, %eax
jae 0xbb62
testl %ebp, %ebp
jne 0xbb2a
incw 0x44(%rbx)
movq %rbx, %rdi
callq 0xb709
testl %eax, %eax
jne 0xbb3e
movq %rbx, %rdi
callq 0x19714
testl %ebp, %ebp
jne 0xbb46
decw 0x44(%rbx)
decw 0x46(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x14d34(%rip), %rsi     # 0x2088c
movq %rbx, %rdi
xorl %eax, %eax
callq 0xb027
movq %rbx, %rdi
movl $0x6, %esi
callq 0xb2c0
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: lua_resume
LUA_API int lua_resume (lua_State *L, lua_State *from, int nargs) {
  int status;
  int oldnny = L->nny;  /* save 'nny' */
  lua_lock(L);
  luai_userstateresume(L, nargs);
  L->nCcalls = (from) ? from->nCcalls + 1 : 1;
  L->nny = 0;  /* allow yields */
  api_checknelems(L, (L->status == LUA_OK) ? nargs + 1 : nargs);
  status = luaD_rawrunprotected(L, resume, L->top - nargs);
  if (status == -1)  /* error calling 'lua_resume'? */
    status = LUA_ERRRUN;
  else {  /* yield or regular error */
    while (status != LUA_OK && status != LUA_YIELD) {  /* error? */
      if (recover(L, status))  /* recover point? */
        status = luaD_rawrunprotected(L, unroll, NULL);  /* run continuation */
      else {  /* unrecoverable error */
        L->status = cast_byte(status);  /* mark thread as `dead' */
        seterrorobj(L, status, L->top);
        L->ci->top = L->top;
        break;
      }
    }
    lua_assert(status == L->status);
  }
  L->nny = oldnny;  /* restore 'nny' */
  L->nCcalls--;
  lua_assert(L->nCcalls == ((from) ? from->nCcalls : 0));
  lua_unlock(L);
  return status;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
testq %rsi, %rsi
je 0xbb8a
movzwl 0x46(%rsi), %eax
incl %eax
jmp 0xbb8e
movw $0x1, %ax
movzwl 0x44(%rbx), %r12d
movw %ax, 0x46(%rbx)
movw $0x0, 0x44(%rbx)
movq 0x10(%rbx), %rax
movslq %edx, %rcx
shlq $0x4, %rcx
subq %rcx, %rax
leaq 0xdb(%rip), %rsi        # 0xbc8d
movq %rbx, %rdi
movq %rax, %rdx
callq 0xb337
cmpl $-0x1, %eax
je 0xbc4e
movl %eax, %ebp
cmpl $0x2, %eax
jb 0xbc73
leaq 0x188(%rip), %r14       # 0xbd60
movq 0x20(%rbx), %r13
testq %r13, %r13
je 0xbc55
testb $0x10, 0x22(%r13)
jne 0xbbee
movq 0x10(%r13), %r13
jmp 0xbbdc
movq 0x38(%rbx), %r15
addq 0x28(%r13), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0xc7a3
movq %rbx, %rdi
movl %ebp, %esi
movq %r15, %rdx
callq 0xbdf1
movq %r13, 0x20(%rbx)
movb 0x48(%r13), %al
movb %al, 0x49(%rbx)
movw $0x0, 0x44(%rbx)
movq %rbx, %rdi
callq 0xb5fe
movq 0x40(%r13), %rax
movq %rax, 0x78(%rbx)
orb $0x20, 0x22(%r13)
movb %bpl, 0x49(%r13)
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0xb337
movl %eax, %ebp
cmpl $0x1, %eax
ja 0xbbd8
jmp 0xbc73
movl $0x2, %ebp
jmp 0xbc73
movb %bpl, 0xa(%rbx)
movq 0x10(%rbx), %rdx
movq %rbx, %rdi
movl %ebp, %esi
callq 0xbdf1
movq 0x10(%rbx), %rax
movq 0x20(%rbx), %rcx
movq %rax, 0x8(%rcx)
movw %r12w, 0x44(%rbx)
decw 0x46(%rbx)
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: resume
static void resume (lua_State *L, void *ud) {
  int nCcalls = L->nCcalls;
  StkId firstArg = cast(StkId, ud);
  CallInfo *ci = L->ci;
  if (nCcalls >= LUAI_MAXCCALLS)
    resume_error(L, "C stack overflow", firstArg);
  if (L->status == LUA_OK) {  /* may be starting a coroutine */
    if (ci != &L->base_ci)  /* not in base level? */
      resume_error(L, "cannot resume non-suspended coroutine", firstArg);
    /* coroutine is in base level; start running it */
    if (!luaD_precall(L, firstArg - 1, LUA_MULTRET))  /* Lua function? */
      luaV_execute(L);  /* call it */
  }
  else if (L->status != LUA_YIELD)
    resume_error(L, "cannot resume dead coroutine", firstArg);
  else {  /* resuming from previous yield */
    L->status = LUA_OK;
    ci->func = restorestack(L, ci->extra);
    if (isLua(ci))  /* yielded inside a hook? */
      luaV_execute(L);  /* just continue running Lua code */
    else {  /* 'common' yield */
      if (ci->u.c.k != NULL) {  /* does it have a continuation? */
        int n;
        ci->u.c.status = LUA_YIELD;  /* 'default' status */
        ci->callstatus |= CIST_YIELDED;
        lua_unlock(L);
        n = (*ci->u.c.k)(L);  /* call continuation */
        lua_lock(L);
        api_checknelems(L, n);
        firstArg = L->top - n;  /* yield results come from continuation */
      }
      luaD_poscall(L, firstArg);  /* finish 'luaD_precall' */
    }
    unroll(L, NULL);
  }
  lua_assert(nCcalls == L->nCcalls);
}

// Assembly:
pushq %rbx
movq %rsi, %rdx
movq %rdi, %rbx
cmpw $0xc8, 0x46(%rdi)
jae 0xbd3f
movq 0x20(%rbx), %rax
movzbl 0xa(%rbx), %ecx
cmpl $0x1, %ecx
je 0xbcdf
testl %ecx, %ecx
jne 0xbd48
leaq 0x80(%rbx), %rcx
cmpq %rcx, %rax
jne 0xbd51
addq $-0x10, %rdx
movq %rbx, %rdi
movq %rdx, %rsi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0xb709
testl %eax, %eax
je 0xbd36
popq %rbx
retq
movb $0x0, 0xa(%rbx)
movq 0x38(%rbx), %rcx
addq 0x28(%rax), %rcx
movq %rcx, (%rax)
movb 0x22(%rax), %cl
testb $0x1, %cl
jne 0xbd28
movq 0x38(%rax), %rsi
testq %rsi, %rsi
je 0xbd1b
movb $0x1, 0x49(%rax)
orb $0x8, %cl
movb %cl, 0x22(%rax)
movq %rbx, %rdi
callq *%rsi
movq 0x10(%rbx), %rdx
cltq
shlq $0x4, %rax
subq %rax, %rdx
movq %rbx, %rdi
movq %rdx, %rsi
callq 0xba4a
jmp 0xbd30
movq %rbx, %rdi
callq 0x19714
movq %rbx, %rdi
popq %rbx
jmp 0xbd60
movq %rbx, %rdi
popq %rbx
jmp 0x19714
leaq 0x14b46(%rip), %rsi     # 0x2088c
jmp 0xbd58
leaq 0x14bc8(%rip), %rsi     # 0x20917
jmp 0xbd58
leaq 0x14b99(%rip), %rsi     # 0x208f1
movq %rbx, %rdi
callq 0xc0f0
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: unroll
static void unroll (lua_State *L, void *ud) {
  UNUSED(ud);
  for (;;) {
    if (L->ci == &L->base_ci)  /* stack is empty? */
      return;  /* coroutine finished normally */
    if (!isLua(L->ci))  /* C function? */
      finishCcall(L);
    else {  /* Lua function */
      luaV_finishOp(L);  /* finish interrupted instruction */
      luaV_execute(L);  /* execute down to higher C 'boundary' */
    }
  }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x80(%rdi), %r14
movq 0x20(%rdi), %rax
cmpq %r14, %rax
je 0xbde9
movq %rdi, %rbx
movb 0x22(%rax), %cl
testb $0x1, %cl
jne 0xbdd0
testb $0x10, %cl
je 0xbd8c
movq 0x40(%rax), %rdx
movq %rdx, 0x78(%rbx)
cmpw $-0x1, 0x20(%rax)
jne 0xbda1
movq 0x10(%rbx), %rdx
cmpq %rdx, 0x8(%rax)
jae 0xbda1
movq %rdx, 0x8(%rax)
testb $0x20, %cl
jne 0xbdaa
movb $0x1, 0x49(%rax)
andb $-0x3a, %cl
orb $0x8, %cl
movb %cl, 0x22(%rax)
movq %rbx, %rdi
callq *0x38(%rax)
movq 0x10(%rbx), %rsi
cltq
shlq $0x4, %rax
subq %rax, %rsi
movq %rbx, %rdi
callq 0xba4a
jmp 0xbde0
movq %rbx, %rdi
callq 0x195b7
movq %rbx, %rdi
callq 0x19714
movq 0x20(%rbx), %rax
cmpq %r14, %rax
jne 0xbd77
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: f_parser
static void f_parser (lua_State *L, void *ud) {
  int i;
  Closure *cl;
  struct SParser *p = cast(struct SParser *, ud);
  int c = zgetc(p->z);  /* read first character */
  if (c == LUA_SIGNATURE[0]) {
    checkmode(L, p->mode, "binary");
    cl = luaU_undump(L, p->z, &p->buff, p->name);
  }
  else {
    checkmode(L, p->mode, "text");
    cl = luaY_parser(L, p->z, &p->buff, &p->dyd, p->name, c);
  }
  lua_assert(cl->l.nupvalues == cl->l.p->sizeupvalues);
  for (i = 0; i < cl->l.nupvalues; i++) {  /* initialize upvalues */
    UpVal *up = luaF_newupval(L);
    cl->l.upvals[i] = up;
    luaC_objbarrier(L, cl, up);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rdi
subq $0x1, (%rdi)
jae 0xc03d
callq 0x1aa74
movl %eax, %ebp
jmp 0xc04c
movq 0x8(%rdi), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x8(%rdi)
movzbl (%rax), %ebp
leaq 0x8(%r14), %r15
movq 0x50(%r14), %rsi
cmpl $0x1b, %ebp
jne 0xc07c
leaq 0x148ec(%rip), %rdx     # 0x2094c
movq %rbx, %rdi
callq 0xc122
movq (%r14), %rsi
movq 0x58(%r14), %rcx
movq %rbx, %rdi
movq %r15, %rdx
callq 0x18274
jmp 0xc0a4
leaq 0x148d0(%rip), %rdx     # 0x20953
movq %rbx, %rdi
callq 0xc122
leaq 0x20(%r14), %rcx
movq (%r14), %rsi
movq 0x58(%r14), %r8
movq %rbx, %rdi
movq %r15, %rdx
movl %ebp, %r9d
callq 0x118dc
movq %rax, %r14
cmpb $0x0, 0xa(%rax)
je 0xc0e5
xorl %r15d, %r15d
movq %rbx, %rdi
callq 0xc6dc
movq %rax, 0x20(%r14,%r15,8)
testb $0x3, 0x9(%rax)
je 0xc0d8
testb $0x4, 0x9(%r14)
je 0xc0d8
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0xc950
incq %r15
movzbl 0xa(%r14), %eax
cmpq %rax, %r15
jb 0xc0b0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldo.c
// Function: checkmode
static void checkmode (lua_State *L, const char *mode, const char *x) {
  if (mode && strchr(mode, x[0]) == NULL) {
    luaO_pushfstring(L,
       "attempt to load a %s chunk (mode is " LUA_QS ")", x, mode);
    luaD_throw(L, LUA_ERRSYNTAX);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rsi, %rsi
je 0xc145
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movsbl (%rdx), %esi
movq %r14, %rdi
callq 0x6190
testq %rax, %rax
je 0xc14b
popq %rbx
popq %r14
popq %r15
retq
leaq 0x14806(%rip), %rsi     # 0x20958
movq %rbx, %rdi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x10eda
movq %rbx, %rdi
movl $0x3, %esi
callq 0xb2c0
nop
// File: /workspace/github_c_makefile_star2_O3/bhk[P]tooltree/lua/../opensource/lua-5.2.3/src/ldump.c
// Function: luaU_dump
int luaU_dump (lua_State* L, const Proto* f, lua_Writer w, void* data, int strip)
{
 DumpState D;
 D.L=L;
 D.writer=w;
 D.data=data;
 D.strip=strip;
 D.status=0;
 DumpHeader(&D);
 DumpFunction(f,&D);
 return D.status;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
leaq 0x18(%rsp), %r13
movq %rdi, (%r13)
movq %rdx, 0x8(%r13)
movq %rcx, 0x10(%r13)
movl %r8d, 0x18(%r13)
movq %rsp, %rbp
movq %rbp, %rdi
callq 0x189aa
movl $0x12, %edx
movq %r12, %rdi
movq %rbp, %rsi
movq %rbx, %rcx
callq *%r14
movl %eax, 0x1c(%r13)
movq %r15, %rdi
movq %r13, %rsi
callq 0xc1dd
movl 0x1c(%r13), %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq