Add LJ_FR2 mode: Two-slot frame info.

This commit is contained in:
Mike Pall
2015-01-03 15:04:38 +01:00
parent a13dfd66c3
commit 054e6abe37
33 changed files with 300 additions and 139 deletions

View File

@@ -47,8 +47,13 @@ LJ_FUNC GCtab *lj_lib_checktabornil(lua_State *L, int narg);
LJ_FUNC int lj_lib_checkopt(lua_State *L, int narg, int def, const char *lst);
/* Avoid including lj_frame.h. */
#if LJ_FR2
#define lj_lib_upvalue(L, n) \
(&gcref((L->base-2)->gcr)->fn.c.upvalue[(n)-1])
#else
#define lj_lib_upvalue(L, n) \
(&gcref((L->base-1)->fr.func)->fn.c.upvalue[(n)-1])
#endif
#if LJ_TARGET_WINDOWS
#define lj_lib_checkfpu(L) \