亚洲欧美第一页_禁久久精品乱码_粉嫩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一区二区三区免费野_久草精品视频
日本不卡免费在线视频| 性做久久久久久免费观看欧美| 日韩一区二区三区在线| 日本道精品一区二区三区| 91啪亚洲精品| 91久久精品一区二区三区| 在线观看欧美精品| 在线播放国产精品二区一二区四区 | 日韩视频在线一区二区| 欧美私人免费视频| 欧美日本在线观看| 日韩欧美色综合| 久久亚洲欧美国产精品乐播| 国产区在线观看成人精品| 欧美国产精品中文字幕| 中文字幕一区免费在线观看| 亚洲天天做日日做天天谢日日欢 | 国产成人综合亚洲网站| 粉嫩蜜臀av国产精品网站| 99精品视频在线观看| 91成人国产精品| 日韩欧美在线综合网| 久久久精品综合| 亚洲欧美日韩在线| 免费一级片91| 成人免费av在线| 欧美日韩三级在线| 久久久夜色精品亚洲| 亚洲视频一区二区在线观看| 午夜精品久久久久久久99水蜜桃| 久久97超碰色| 91亚洲大成网污www| 日韩一二在线观看| 国产精品国模大尺度视频| 亚洲国产精品久久久久婷婷884| 免费成人美女在线观看| 成人激情免费电影网址| 欧美性视频一区二区三区| 日韩天堂在线观看| 亚洲激情自拍视频| 韩日精品视频一区| 欧美少妇一区二区| 国产精品一区二区在线观看不卡 | 亚洲一二三四在线观看| 日韩三级在线免费观看| 国产在线精品国自产拍免费| 6080午夜不卡| 欧美精品一区二区精品网| 亚洲欧美偷拍卡通变态| 激情欧美一区二区三区在线观看| 欧美专区日韩专区| 国产精品成人一区二区三区夜夜夜| 免费高清成人在线| 欧美视频日韩视频| 亚洲精品视频在线看| 激情五月激情综合网| 69p69国产精品| 99麻豆久久久国产精品免费优播| 亚洲高清在线精品| 韩国精品主播一区二区在线观看 | 91亚洲精品久久久蜜桃网站 | 精品伦理精品一区| 亚洲一区二区视频| 色八戒一区二区三区| 久久久蜜臀国产一区二区| 蜜桃在线一区二区三区| 欧美男生操女生| 午夜精品一区二区三区三上悠亚| 色噜噜夜夜夜综合网| 亚洲三级小视频| 91视频观看视频| 一区二区三区在线影院| www.性欧美| 精品免费国产一区二区三区四区| 日韩午夜av电影| 久久国产精品一区二区| 91麻豆精品国产91久久久| 午夜伊人狠狠久久| 欧美一区二区成人6969| 秋霞电影网一区二区| 日韩午夜三级在线| 麻豆传媒一区二区三区| 久久综合视频网| 国产成人午夜99999| 亚洲国产激情av| 成人h精品动漫一区二区三区| 国产精品久久毛片a| 91久久国产综合久久| 亚洲大片精品永久免费| 欧美一级一级性生活免费录像| 日本亚洲免费观看| 国产农村妇女毛片精品久久麻豆| 成人av中文字幕| 午夜天堂影视香蕉久久| 欧美精品一区二区三区久久久 | 91麻豆精品国产91久久久久久 | 一区二区三区在线观看动漫| 欧美私模裸体表演在线观看| 日本不卡123| 欧美国产精品专区| 欧美性生活久久| 国产原创一区二区| 亚洲精品午夜久久久| 精品久久国产字幕高潮| 99久久99久久精品免费观看| 日韩综合在线视频| 久久夜色精品国产噜噜av| eeuss鲁一区二区三区| 亚洲h在线观看| 中文字幕欧美激情| 欧美日韩综合在线免费观看| 国产不卡高清在线观看视频| 亚洲一本大道在线| 26uuu精品一区二区| 成人av在线网| 精品在线视频一区| 亚洲精品视频在线看| 久久综合色天天久久综合图片| 色婷婷综合中文久久一本| 国产一区二区福利视频| 午夜久久久久久久久| 中文幕一区二区三区久久蜜桃| 欧美日韩美女一区二区| 99re8在线精品视频免费播放| 毛片av中文字幕一区二区| 一区二区在线免费| 国产欧美日本一区二区三区| 欧美一区二区三区在线观看| 91精彩视频在线| 成人99免费视频| 国产精品自在在线| 天天综合天天做天天综合| 伊人一区二区三区| 国产精品久久久久aaaa| 精品sm捆绑视频| 欧美一区二区三区免费| 欧美性猛交xxxx黑人交| 91色乱码一区二区三区| 成人精品电影在线观看| 韩国三级在线一区| 黄网站免费久久| 看片网站欧美日韩| 麻豆一区二区三| 日本美女一区二区三区| 免费欧美日韩国产三级电影| 亚洲第一二三四区| 亚洲第一精品在线| 亚洲丰满少妇videoshd| 一区二区三区精品| 亚洲午夜电影网| 天天色图综合网| 久久99国产精品久久| 久久精品国产久精国产爱| 久久国产精品色婷婷| 精品亚洲成av人在线观看| 国产制服丝袜一区| 福利电影一区二区| 成人免费看的视频| 91丝袜呻吟高潮美腿白嫩在线观看| 菠萝蜜视频在线观看一区| 99热这里都是精品| 欧美图区在线视频| 91精品啪在线观看国产60岁| 日韩欧美色综合| 中文无字幕一区二区三区| 亚洲欧美一区二区在线观看| 亚洲欧洲成人自拍| 首页国产欧美日韩丝袜| 美国十次综合导航| 成人av免费在线播放| 欧美午夜视频网站| 精品va天堂亚洲国产| 亚洲欧洲日韩av| 奇米色一区二区| 粉嫩av一区二区三区粉嫩| 色婷婷亚洲综合| 亚洲精品在线观看网站| 自拍偷拍欧美激情| 免费在线观看视频一区| 丁香亚洲综合激情啪啪综合| 色综合久久久久久久久久久| 91精品一区二区三区在线观看| 久久久99免费| 亚洲一区二区三区四区在线 | 亚洲视频一二三区| 日韩成人免费电影| av不卡在线观看| 欧美日韩大陆在线| 国产精品色在线| 日日夜夜免费精品| 成人av网站免费| 日韩精品综合一本久道在线视频| 国产精品美女久久久久久久久| 天天综合色天天综合| av在线一区二区三区| 精品福利一区二区三区免费视频| 一区二区高清视频在线观看| 视频一区二区国产| 97精品电影院| 国产午夜精品一区二区三区四区 |