亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? ljitlib.c

?? lua的即時編譯器。支持lua 5.1.2版本
?? C
?? 第 1 頁 / 共 2 頁
字號:
/*** Lua library for the JIT engine.** Copyright (C) 2005-2007 Mike Pall. See Copyright Notice in luajit.h*/#include <stdio.h>#include <string.h>#define ljitlib_c#define LUA_LIB#include "lua.h"#include "lauxlib.h"#include "luajit.h"#include "lualib.h"/* This file is not a pure C API user. Some internals are required. */#include "lobject.h"#include "lstate.h"#include "lstring.h"#include "ltable.h"#include "lfunc.h"#include "lgc.h"#include "lopcodes.h"#include "ljit.h"#include "ljit_hints.h"#define STRING_HINTS#include "ljit_hints.h"/* ------------------------------------------------------------------------ *//* Static pointer addresses used as registry keys. *//* The values do not matter, but must be different to prevent joining. */static const int regkey_frontend = 0x6c6a6c01;static const int regkey_comthread = 0x6c6a6c02;/* Check that the first argument is a Lua function and return its closure. */static Closure *check_LCL(lua_State *L){  StkId o = L->base;  switch (lua_type(L, 1)) {  case LUA_TBOOLEAN:    o = (L->ci-1)->func;  case LUA_TFUNCTION:    if (isLfunction(o))      return clvalue(o);    break;  }  luaL_argerror(L, 1, "Lua function expected");  return NULL;}/* Create a new closure from a prototype. *//* Note: upvalues are assumed to be after first two slots. */static void push_LCL(lua_State *L, Proto *pt, Table *env){  Closure *cl;  int i, nup = pt->nups;  /* Adjust the number of stack slots to the number of upvalues. */  luaL_checkstack(L, nup, "too many upvalues");  lua_settop(L, 2+nup);  /* Create a closure from the subroutine prototype. */  cl = luaF_newLclosure(L, nup, env);  cl->l.p = pt;  /* Allocate new upvalues and close them. */  for (i = 0; i < nup; i++)    cl->l.upvals[i] = luaF_findupval(L, L->base + (2+i));  luaF_close(L, L->base + 2);  lua_settop(L, 2);  /* Remove upvalues. */  setclvalue(L, L->top++, cl);  /* Return closure on top of stack. */  luaC_checkGC(L);}/* ------------------------------------------------------------------------ *//* Set JIT mode for the engine or a closure and/or its subroutines. */static int setmode(lua_State *L, int mode){  int idx = 0;  switch (lua_type(L, 1)) {  case LUA_TNONE:	/* jit.on/off() */  case LUA_TNIL:	/* jit.on/off(nil) */    luaJIT_setmode(L, 0, mode | LUAJIT_MODE_ENGINE);    break;  case LUA_TFUNCTION:	/* jit.on/off(func, nil|true|false) */    idx = 1;  case LUA_TBOOLEAN:	/* jit.on/off(true, nil|true|false) (parent frame) */    if (lua_isboolean(L, 2))      mode |= lua_toboolean(L, 2)?LUAJIT_MODE_ALLFUNC:LUAJIT_MODE_ALLSUBFUNC;    else      mode |= LUAJIT_MODE_FUNC;    if (luaJIT_setmode(L, idx, mode) == 1)  /* Ok? */      break;  default:    luaL_argerror(L, 1, "Lua function expected");    break;  }  return 0;}/* Set JIT mode to on: (re-)enable compilation. */static int j_on(lua_State *L){  return setmode(L, LUAJIT_MODE_ON);}/* Set JIT mode to off: disable compilation. */static int j_off(lua_State *L){  return setmode(L, LUAJIT_MODE_OFF);}/* Set JIT debug level. Defaults to maximum level for use with -j. */static int j_debug(lua_State *L){  luaJIT_setmode(L, luaL_optinteger(L, 1, 100), LUAJIT_MODE_DEBUG);  return 0;}/* ------------------------------------------------------------------------ *//* Report the compilation status. */static int compstatus(lua_State *L, int status){  if (status == -1)    return luaL_argerror(L, 1, "Lua function expected");  else if (status == JIT_S_OK)    return 0;  else {    lua_pushinteger(L, status);    return 1;  }}/* Compile a function. Pass typical args to help the optimizer. */static int j_compile(lua_State *L){  int nargs = lua_gettop(L) - 1;  return compstatus(L, nargs >= 0 ? luaJIT_compile(L, nargs) : -1);}/* Recursively compile all subroutine prototypes. */static int rec_compile(lua_State *L, Proto *pt, Table *env, int stoponerror){  int rstatus = JIT_S_OK;  int i;  for (i = 0; i < pt->sizep; i++) {    Proto *pti = pt->p[i];    int status;    push_LCL(L, pti, env);  /* Assumes stack is at 2 (no upvalues). */    status = luaJIT_compile(L, 0);    lua_settop(L, 2);  /* Clear stack */    if (status != JIT_S_OK) {      rstatus = status;      if (stoponerror) break;    }    status = rec_compile(L, pti, env, stoponerror);    if (status != JIT_S_OK) {      rstatus = status;      if (stoponerror) break;    }  }  return rstatus;}/* Compile all subroutines of a function. *//* Note: the function itself is _not_ compiled (use jit.compile()). */static int j_compilesub(lua_State *L){  Closure *cl = check_LCL(L);  int stoponerror = lua_toboolean(L, 2);  /* Stop on first error? */  lua_settop(L, 2);  return compstatus(L, rec_compile(L, cl->l.p, cl->l.env, stoponerror));}/* jit.* functions. */static const luaL_Reg jitlib[] = {  { "on",		j_on },  { "off",		j_off },  { "debug",		j_debug },  { "compile",		j_compile },  { "compilesub",	j_compilesub },  /* j_attach is added below. */  { NULL, NULL }};/* ------------------------------------------------------------------------ *//* Get the compiler pipeline table from an upvalue (j_attach, j_frontend). */#define COMPIPE		lua_upvalueindex(1)/* Attach/detach handler to/from compiler pipeline. */static int j_attach(lua_State *L){  int pipesz;  luaL_checktype(L, 1, LUA_TFUNCTION);  pipesz = lua_objlen(L, COMPIPE);  if (lua_isnoneornil(L, 2)) {  /* Detach if no priority given. */    int i;    for (i = 1; i <= pipesz; i += 2) {      lua_rawgeti(L, COMPIPE, i);      if (lua_rawequal(L, 1, -1)) {  /* Found: delete from pipeline. */	for (; i+2 <= pipesz; i++) {  /* Shift down. */	  lua_rawgeti(L, COMPIPE, i+2);	  lua_rawseti(L, COMPIPE, i);	}	/* Clear last two elements. */	lua_pushnil(L); lua_rawseti(L, COMPIPE, i);	lua_pushnil(L); lua_rawseti(L, COMPIPE, i+1);	return 0;      }      lua_pop(L, 1);    }    return 0;  /* Not found: ignore detach request. */  } else {  /* Attach if priority given. */    int prio = luaL_checkint(L, 2);    int pos, i;    for (pos = 2; pos <= pipesz; pos += 2) {      lua_rawgeti(L, COMPIPE, pos);      if (prio > (int)lua_tointeger(L, -1)) break; /* Insertion point found. */      lua_pop(L, 1);    }    for (i = pipesz+2; i > pos; i--) {  /* Shift up. */      lua_rawgeti(L, COMPIPE, i-2);      lua_rawseti(L, COMPIPE, i);    }    /* Set handler and priority. */    lua_pushvalue(L, 1); lua_rawseti(L, COMPIPE, i-1);    lua_pushvalue(L, 2); lua_rawseti(L, COMPIPE, i);    return 0;  }}/* Compiler frontend. Runs in the compiler thread. *//* First and only arg is the compiler state table. */static int j_frontend(lua_State *L){  int status = JIT_S_OK;  int pos;  /* Loop through all handlers in the compiler pipeline. */  for (pos = 1; ; pos += 2) {    if (status != JIT_S_OK) {  /* Pending failure? */      int prio;      lua_rawgeti(L, COMPIPE, pos+1);  /* Must check for odd/even priority. */      if (lua_isnil(L, -1)) break;  /* End of pipeline. */      prio = (int)lua_tointeger(L, -1);      lua_pop(L, 1);      if ((prio & 1) == 0) continue;  /* Skip handlers with even priority. */    }    /* Call handler with compiler state table and optional failure status. */    lua_rawgeti(L, COMPIPE, pos);    if (lua_isnil(L, -1)) break;  /* End of pipeline. */    lua_pushvalue(L, 1);    if (status != JIT_S_OK)      lua_pushinteger(L, status);    lua_call(L, status ? 2 : 1, 1);    if (!lua_isnil(L, -1))  /* Remember failure status. */      status = (int)lua_tointeger(L, -1);    lua_pop(L, 1);  }  lua_pushinteger(L, status);  return 1;}/* Compiler frontend wrapper. */static int frontwrap(lua_State *L, Table *st){  jit_State *J = G(L)->jit_state;  lua_State *JL;  int status;  /* Allocate compiler thread on demand. */  if (J->L == NULL) {    if (!lua_checkstack(L, 3)) return JIT_S_COMPILER_ERROR;    sethvalue(L, L->top++, st);  /* Prevent GC of state table. */    lua_pushlightuserdata(L, (void *)&regkey_comthread);    /* Cannot use C stack, since it's deallocated early in Coco. */    /* But we don't need one -- the compiler thread never yields, anyway. */    J->L = lua_newthread(L);    lua_rawset(L, LUA_REGISTRYINDEX);    L->top--;  /* Remove state table from this stack. */  }  JL = J->L;  /* Initialize compiler thread stack with frontend and state table. */  lua_settop(JL, 0);  lua_pushlightuserdata(JL, (void *)&regkey_frontend);  lua_rawget(JL, LUA_REGISTRYINDEX);  sethvalue(JL, JL->top, st);  JL->top++;  /* Start the frontend by resuming the compiler thread. */  if (lua_resume(JL, 1) != 0) {  /* Failed? */    /* Note: LUA_YIELD is treated like any other error. */    J->L = NULL;  /* Get a new thread next time. */    fprintf(stderr, "[LuaJIT frontend failed: %s]\n",      lua_isstring(JL, -1) ? lua_tostring(JL, -1) : "(unknown error)");    return JIT_S_COMPILER_ERROR;  }  /* Get status from terminated thread. */  status = (int)lua_tointeger(JL, -1);  lua_settop(JL, 0);  /* Help the GC. */  return status;}/* Create the compiler pipeline and register it. */static void makepipeline(lua_State *L){  lua_createtable(L, 20, 0);  /* 10 handlers+priorities should be enough. */  lua_pushcfunction(L, luaJIT_backend);  lua_rawseti(L, -2, 1);  lua_pushinteger(L, 0);  /* Fill in the backend at prio 0. */  lua_rawseti(L, -2, 2);  /* Store the compiler frontend in the registry. */  lua_pushlightuserdata(L, (void *)&regkey_frontend);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美一卡二卡三卡| 色综合色狠狠综合色| 亚洲午夜久久久久久久久电影网| 久久无码av三级| 久久精品无码一区二区三区| 日韩你懂的电影在线观看| 欧美一级免费大片| 久久久久国产精品免费免费搜索| 精品国产乱码久久| 1区2区3区国产精品| 亚洲午夜久久久| 丁香婷婷综合激情五月色| 麻豆精品在线视频| 成人sese在线| 91麻豆精品国产91久久久久久久久| 91精品久久久久久久99蜜桃| 久久婷婷成人综合色| 一区二区三区国产精品| 调教+趴+乳夹+国产+精品| 精品一区二区三区免费视频| 国产不卡视频在线播放| 色婷婷国产精品久久包臀| 欧美岛国在线观看| 亚洲精品日日夜夜| 国产精品一卡二| 91久久精品一区二区二区| 日韩视频123| **性色生活片久久毛片| 激情文学综合网| 制服丝袜亚洲网站| 亚洲男人天堂av网| 一本久久精品一区二区| 国产婷婷色一区二区三区四区| 亚洲成人精品一区| 色婷婷精品久久二区二区蜜臂av| 久久―日本道色综合久久| 视频一区免费在线观看| 日韩免费高清电影| 国产精品美女久久久久aⅴ国产馆 国产精品美女久久久久av爽李琼 国产精品美女久久久久高潮 | 丁香婷婷深情五月亚洲| 精品国产乱码久久久久久浪潮 | 欧美日本一区二区在线观看| 欧美va亚洲va| 天天影视网天天综合色在线播放 | 国产精品青草久久| 成人午夜电影久久影院| 中文字幕不卡三区| 99re热视频精品| 亚洲一区二区不卡免费| 欧美精品免费视频| 久久99精品国产.久久久久| 欧美综合色免费| 三级欧美在线一区| 日韩精品一区二区在线| 国产91精品在线观看| 亚洲欧美电影一区二区| 欧美喷潮久久久xxxxx| 日韩精品视频网| 亚洲欧美在线观看| 日韩欧美亚洲国产另类| 国产毛片精品视频| 国产欧美日产一区| 91精品国产91热久久久做人人| 婷婷久久综合九色综合绿巨人| 日韩欧美国产精品一区| 91网站黄www| 成人免费视频app| 亚洲成av人**亚洲成av**| ww久久中文字幕| 欧美精品粉嫩高潮一区二区| 久久精品国产精品亚洲红杏| 亚洲免费观看高清完整版在线观看熊| 国产一区二区在线电影| 中文字幕不卡三区| 日韩一级黄色片| 制服.丝袜.亚洲.中文.综合| 99精品国产热久久91蜜凸| 国产成a人无v码亚洲福利| 热久久免费视频| 亚洲一区二区三区中文字幕在线| 久久午夜老司机| 精品久久久久久久一区二区蜜臀| 欧美理论在线播放| 欧美日韩国产区一| 欧美亚男人的天堂| 欧美日本不卡视频| 欧美日韩另类一区| 色欧美乱欧美15图片| 色婷婷av一区二区三区gif| 丁香婷婷综合网| 91首页免费视频| 欧美日韩在线免费视频| 91精品视频网| 精品欧美一区二区久久| 国产欧美视频一区二区三区| 国产女主播一区| 一区二区久久久久久| 亚洲午夜精品久久久久久久久| 日韩激情一区二区| 黄色资源网久久资源365| 成人午夜av在线| 欧美性猛交xxxx黑人交| 欧美一区二区三区啪啪| 国产亚洲精品超碰| 国产精品美女久久久久久久久久久| 自拍av一区二区三区| 日日夜夜免费精品| 不卡一二三区首页| 欧美一区二区高清| 日韩美女视频19| 久久99精品久久久久久| 在线观看视频91| 精品成人佐山爱一区二区| 日韩欧美色电影| 亚洲乱码精品一二三四区日韩在线| 日本成人在线一区| 91激情五月电影| 亚洲欧美二区三区| 午夜不卡在线视频| 九九**精品视频免费播放| 成人午夜视频福利| 欧美白人最猛性xxxxx69交| 一区二区三区中文字幕精品精品| 国产成人精品影视| 欧美视频三区在线播放| 日本一区二区成人| 国产在线精品免费| 久久久精品日韩欧美| 激情欧美一区二区| 亚洲精品一区在线观看| 久久精品国产网站| 日韩一区二区三区电影在线观看 | 成人免费视频app| 欧美国产激情二区三区| 国产成人午夜电影网| 国产亚洲欧美在线| 国产成人av福利| 国产片一区二区| 在线观看www91| 亚洲综合999| 日韩欧美二区三区| 午夜精品久久久久久久久久久 | 国产精品乱码人人做人人爱 | 国产视频一区二区在线观看| 国产一区不卡视频| 亚洲免费观看高清完整版在线观看熊 | 国产成人8x视频一区二区| 中文字幕亚洲一区二区av在线| 欧美伊人精品成人久久综合97| 秋霞影院一区二区| 18欧美亚洲精品| 欧美成人精品3d动漫h| 国产高清久久久| 亚洲国产精品精华液网站| 欧美精品一区二区三区蜜桃| 国产福利91精品| 亚洲超碰97人人做人人爱| 精品国产91乱码一区二区三区 | 九九精品一区二区| 亚洲欧美一区二区久久| 精品国产乱码久久久久久浪潮| 91网站视频在线观看| 亚洲成a人片在线观看中文| 久久久久久免费网| 日韩一区二区在线观看| 91高清视频在线| bt欧美亚洲午夜电影天堂| 精品无码三级在线观看视频 | 国产在线视频一区二区| 亚洲人妖av一区二区| 久久精品人人做| 久久在线观看免费| 亚洲精品在线电影| 欧美日韩一区视频| 欧美日韩精品高清| 欧美日韩精品久久久| 6080国产精品一区二区| 91黄视频在线观看| 欧美日韩精品一区二区三区蜜桃| 91麻豆123| 欧美老女人在线| 久久一区二区三区四区| 欧美一级精品大片| 欧美精品一区二区久久婷婷| 欧美日韩成人在线| 欧美电影免费观看高清完整版在| 久久嫩草精品久久久久| 2017欧美狠狠色| 国产欧美日韩久久| 亚洲欧洲日韩av| 日韩中文字幕一区二区三区| 麻豆成人久久精品二区三区红| 精品一区二区在线视频| av在线不卡网| 99久久综合色| 久久久亚洲精品石原莉奈| 一区二区三区中文在线观看| 男女视频一区二区| 91香蕉国产在线观看软件| 日韩欧美一区电影|