summaryrefslogtreecommitdiff
path: root/src/buildvm_arm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/buildvm_arm.h')
-rw-r--r--src/buildvm_arm.h849
1 files changed, 428 insertions, 421 deletions
diff --git a/src/buildvm_arm.h b/src/buildvm_arm.h
index ca94ed18..aec421dd 100644
--- a/src/buildvm_arm.h
+++ b/src/buildvm_arm.h
@@ -12,7 +12,7 @@
12#define DASM_SECTION_CODE_OP 0 12#define DASM_SECTION_CODE_OP 0
13#define DASM_SECTION_CODE_SUB 1 13#define DASM_SECTION_CODE_SUB 1
14#define DASM_MAXSECTION 2 14#define DASM_MAXSECTION 2
15static const unsigned int build_actionlist[5777] = { 15static const unsigned int build_actionlist[5784] = {
160x00010001, 160x00010001,
170x00060014, 170x00060014,
180xe3160000, 180xe3160000,
@@ -1421,6 +1421,8 @@ static const unsigned int build_actionlist[5777] = {
14210xea000000, 14210xea000000,
14220x00050049, 14220x00050049,
14230x0006000c, 14230x0006000c,
14240x2a000000,
14250x00050049,
14240xe1822000, 14260xe1822000,
14250xe1120fc1, 14270xe1120fc1,
14260x03a00000, 14280x03a00000,
@@ -1484,6 +1486,8 @@ static const unsigned int build_actionlist[5777] = {
14840xea000000, 14860xea000000,
14850x00050049, 14870x00050049,
14860x0006000c, 14880x0006000c,
14890x2a000000,
14900x00050049,
14870xe1822000, 14910xe1822000,
14880xe1d22fc1, 14920xe1d22fc1,
14890x03a00000, 14930x03a00000,
@@ -1501,9 +1505,9 @@ static const unsigned int build_actionlist[5777] = {
15010x4a000000, 15050x4a000000,
15020x0005000b, 15060x0005000b,
15030x0006000e, 15070x0006000e,
15080x00000000,
15040xeb000000, 15090xeb000000,
15050x0005005c, 15100x0005005c,
15060x00000000,
15070xea000000, 15110xea000000,
15080x00050049, 15120x00050049,
15090x00040007, 15130x00040007,
@@ -1563,11 +1567,11 @@ static const unsigned int build_actionlist[5777] = {
15630xea000000, 15670xea000000,
15640x0005000f, 15680x0005000f,
15650x0006005f, 15690x0006005f,
15700x00000000,
15660xe1c900d0, 15710xe1c900d0,
15670xe35b0008, 15720xe35b0008,
15680x3a000000, 15730x3a000000,
15690x00050046, 15740x00050046,
15700x00000000,
15710xe3710000, 15750xe3710000,
15720x000a0000, 15760x000a0000,
15730x2a000000, 15770x2a000000,
@@ -2711,6 +2715,7 @@ static const unsigned int build_actionlist[5777] = {
27110x0516e004, 27150x0516e004,
27120x00020000, 27160x00020000,
27130x000412ae, 27170x000412ae,
27180x02811008,
27140xe049c001, 27190xe049c001,
27150xea000000, 27200xea000000,
27160x00050024, 27210x00050024,
@@ -2995,6 +3000,7 @@ static const unsigned int build_actionlist[5777] = {
29950xe0c11002, 30000xe0c11002,
29960xe12fff1e, 30010xe12fff1e,
29970x0006000c, 30020x0006000c,
30030x212fff1e,
29980xe1822000, 30040xe1822000,
29990xe1120fc1, 30050xe1120fc1,
30000xe3a00000, 30060xe3a00000,
@@ -3030,6 +3036,7 @@ static const unsigned int build_actionlist[5777] = {
30300xe0c11002, 30360xe0c11002,
30310xe12fff1e, 30370xe12fff1e,
30320x0006000c, 30380x0006000c,
30390x212fff1e,
30330xe1822000, 30400xe1822000,
30340xe1d22fc1, 30410xe1d22fc1,
30350xe3a00000, 30420xe3a00000,
@@ -6299,235 +6306,235 @@ static void build_subroutines(BuildCtx *ctx)
6299 dasm_put(Dst, 1246, Dt8(->upvalue[0].gcr), Dt1(->base), Dt1(->top), Dt1(->status), Dt1(->base), Dt1(->maxstack), Dt1(->cframe), LUA_YIELD, Dt1(->top), Dt1(->top), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), LUA_YIELD); 6306 dasm_put(Dst, 1246, Dt8(->upvalue[0].gcr), Dt1(->base), Dt1(->top), Dt1(->status), Dt1(->base), Dt1(->maxstack), Dt1(->cframe), LUA_YIELD, Dt1(->top), Dt1(->top), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), LUA_YIELD);
6300 dasm_put(Dst, 1302, Dt1(->base), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, Dt1(->cframe), Dt1(->base), CFRAME_RESUME, Dt1(->top)); 6307 dasm_put(Dst, 1302, Dt1(->base), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, Dt1(->cframe), Dt1(->base), CFRAME_RESUME, Dt1(->top));
6301 dasm_put(Dst, 1361, LUA_YIELD, Dt1(->cframe), Dt1(->status), -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM); 6308 dasm_put(Dst, 1361, LUA_YIELD, Dt1(->cframe), Dt1(->status), -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM);
6302 dasm_put(Dst, 1427, -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM); 6309 dasm_put(Dst, 1429, -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM);
6303 dasm_put(Dst, 1491, -LJ_TISNUM, (1+1)*8, FRAME_TYPE, ~LJ_TNIL); 6310 dasm_put(Dst, 1493, -LJ_TISNUM, (1+1)*8, FRAME_TYPE, ~LJ_TNIL);
6304 dasm_put(Dst, 1555, -LJ_TISNUM); 6311 dasm_put(Dst, 1555, -LJ_TISNUM);
6305 if (LJ_TARGET_OSX) { 6312 if (LJ_TARGET_OSX) {
6306 dasm_put(Dst, 1560); 6313 dasm_put(Dst, 1564);
6307 } 6314 }
6308 dasm_put(Dst, 1562); 6315 dasm_put(Dst, 1566);
6309 if (LJ_TARGET_OSX) { 6316 if (LJ_TARGET_OSX) {
6310 dasm_put(Dst, 1565); 6317 dasm_put(Dst, 1569);
6311 } 6318 }
6312 dasm_put(Dst, 1567, -LJ_TISNUM); 6319 dasm_put(Dst, 1571, -LJ_TISNUM);
6313 if (LJ_TARGET_OSX) { 6320 if (LJ_TARGET_OSX) {
6314 dasm_put(Dst, 1579); 6321 dasm_put(Dst, 1583);
6315 } 6322 }
6316 dasm_put(Dst, 1581); 6323 dasm_put(Dst, 1585);
6317 if (LJ_TARGET_OSX) { 6324 if (LJ_TARGET_OSX) {
6318 dasm_put(Dst, 1584); 6325 dasm_put(Dst, 1588);
6319 } 6326 }
6320 dasm_put(Dst, 1586, -LJ_TISNUM); 6327 dasm_put(Dst, 1590, -LJ_TISNUM);
6321 if (LJ_TARGET_OSX) { 6328 if (LJ_TARGET_OSX) {
6322 dasm_put(Dst, 1598); 6329 dasm_put(Dst, 1602);
6323 } 6330 }
6324 dasm_put(Dst, 1600); 6331 dasm_put(Dst, 1604);
6325 if (LJ_TARGET_OSX) { 6332 if (LJ_TARGET_OSX) {
6326 dasm_put(Dst, 1603); 6333 dasm_put(Dst, 1607);
6327 } 6334 }
6328 dasm_put(Dst, 1605, -LJ_TISNUM); 6335 dasm_put(Dst, 1609, -LJ_TISNUM);
6329 if (LJ_TARGET_OSX) { 6336 if (LJ_TARGET_OSX) {
6330 dasm_put(Dst, 1617); 6337 dasm_put(Dst, 1621);
6331 } 6338 }
6332 dasm_put(Dst, 1619); 6339 dasm_put(Dst, 1623);
6333 if (LJ_TARGET_OSX) { 6340 if (LJ_TARGET_OSX) {
6334 dasm_put(Dst, 1622); 6341 dasm_put(Dst, 1626);
6335 } 6342 }
6336 dasm_put(Dst, 1624, -LJ_TISNUM); 6343 dasm_put(Dst, 1628, -LJ_TISNUM);
6337 if (LJ_TARGET_OSX) { 6344 if (LJ_TARGET_OSX) {
6338 dasm_put(Dst, 1636); 6345 dasm_put(Dst, 1640);
6339 } 6346 }
6340 dasm_put(Dst, 1638); 6347 dasm_put(Dst, 1642);
6341 if (LJ_TARGET_OSX) { 6348 if (LJ_TARGET_OSX) {
6342 dasm_put(Dst, 1641); 6349 dasm_put(Dst, 1645);
6343 } 6350 }
6344 dasm_put(Dst, 1643, -LJ_TISNUM); 6351 dasm_put(Dst, 1647, -LJ_TISNUM);
6345 if (LJ_TARGET_OSX) { 6352 if (LJ_TARGET_OSX) {
6346 dasm_put(Dst, 1655); 6353 dasm_put(Dst, 1659);
6347 } 6354 }
6348 dasm_put(Dst, 1657); 6355 dasm_put(Dst, 1661);
6349 if (LJ_TARGET_OSX) { 6356 if (LJ_TARGET_OSX) {
6350 dasm_put(Dst, 1660); 6357 dasm_put(Dst, 1664);
6351 } 6358 }
6352 dasm_put(Dst, 1662, -LJ_TISNUM); 6359 dasm_put(Dst, 1666, -LJ_TISNUM);
6353 if (LJ_TARGET_OSX) { 6360 if (LJ_TARGET_OSX) {
6354 dasm_put(Dst, 1674); 6361 dasm_put(Dst, 1678);
6355 } 6362 }
6356 dasm_put(Dst, 1676); 6363 dasm_put(Dst, 1680);
6357 if (LJ_TARGET_OSX) { 6364 if (LJ_TARGET_OSX) {
6358 dasm_put(Dst, 1679); 6365 dasm_put(Dst, 1683);
6359 } 6366 }
6360 dasm_put(Dst, 1681, -LJ_TISNUM); 6367 dasm_put(Dst, 1685, -LJ_TISNUM);
6361 if (LJ_TARGET_OSX) { 6368 if (LJ_TARGET_OSX) {
6362 dasm_put(Dst, 1693); 6369 dasm_put(Dst, 1697);
6363 } 6370 }
6364 dasm_put(Dst, 1695); 6371 dasm_put(Dst, 1699);
6365 if (LJ_TARGET_OSX) { 6372 if (LJ_TARGET_OSX) {
6366 dasm_put(Dst, 1698); 6373 dasm_put(Dst, 1702);
6367 } 6374 }
6368 dasm_put(Dst, 1700, -LJ_TISNUM); 6375 dasm_put(Dst, 1704, -LJ_TISNUM);
6369 if (LJ_TARGET_OSX) { 6376 if (LJ_TARGET_OSX) {
6370 dasm_put(Dst, 1712); 6377 dasm_put(Dst, 1716);
6371 } 6378 }
6372 dasm_put(Dst, 1714); 6379 dasm_put(Dst, 1718);
6373 if (LJ_TARGET_OSX) { 6380 if (LJ_TARGET_OSX) {
6374 dasm_put(Dst, 1717); 6381 dasm_put(Dst, 1721);
6375 } 6382 }
6376 dasm_put(Dst, 1719, -LJ_TISNUM); 6383 dasm_put(Dst, 1723, -LJ_TISNUM);
6377 if (LJ_TARGET_OSX) { 6384 if (LJ_TARGET_OSX) {
6378 dasm_put(Dst, 1731); 6385 dasm_put(Dst, 1735);
6379 } 6386 }
6380 dasm_put(Dst, 1733); 6387 dasm_put(Dst, 1737);
6381 if (LJ_TARGET_OSX) { 6388 if (LJ_TARGET_OSX) {
6382 dasm_put(Dst, 1736); 6389 dasm_put(Dst, 1740);
6383 } 6390 }
6384 dasm_put(Dst, 1738, -LJ_TISNUM); 6391 dasm_put(Dst, 1742, -LJ_TISNUM);
6385 if (LJ_TARGET_OSX) { 6392 if (LJ_TARGET_OSX) {
6386 dasm_put(Dst, 1750); 6393 dasm_put(Dst, 1754);
6387 } 6394 }
6388 dasm_put(Dst, 1752); 6395 dasm_put(Dst, 1756);
6389 if (LJ_TARGET_OSX) { 6396 if (LJ_TARGET_OSX) {
6390 dasm_put(Dst, 1755); 6397 dasm_put(Dst, 1759);
6391 } 6398 }
6392 dasm_put(Dst, 1757, -LJ_TISNUM); 6399 dasm_put(Dst, 1761, -LJ_TISNUM);
6393 if (LJ_TARGET_OSX) { 6400 if (LJ_TARGET_OSX) {
6394 dasm_put(Dst, 1769); 6401 dasm_put(Dst, 1773);
6395 } 6402 }
6396 dasm_put(Dst, 1771); 6403 dasm_put(Dst, 1775);
6397 if (LJ_TARGET_OSX) { 6404 if (LJ_TARGET_OSX) {
6398 dasm_put(Dst, 1774); 6405 dasm_put(Dst, 1778);
6399 } 6406 }
6400 dasm_put(Dst, 1776, -LJ_TISNUM); 6407 dasm_put(Dst, 1780, -LJ_TISNUM);
6401 if (LJ_TARGET_OSX) { 6408 if (LJ_TARGET_OSX) {
6402 dasm_put(Dst, 1788); 6409 dasm_put(Dst, 1792);
6403 } 6410 }
6404 dasm_put(Dst, 1790); 6411 dasm_put(Dst, 1794);
6405 if (LJ_TARGET_OSX) { 6412 if (LJ_TARGET_OSX) {
6406 dasm_put(Dst, 1793); 6413 dasm_put(Dst, 1797);
6407 } 6414 }
6408 dasm_put(Dst, 1795, -LJ_TISNUM, -LJ_TISNUM); 6415 dasm_put(Dst, 1799, -LJ_TISNUM, -LJ_TISNUM);
6409 if (LJ_TARGET_OSX) { 6416 if (LJ_TARGET_OSX) {
6410 dasm_put(Dst, 1810); 6417 dasm_put(Dst, 1814);
6411 } 6418 }
6412 dasm_put(Dst, 1812); 6419 dasm_put(Dst, 1816);
6413 if (LJ_TARGET_OSX) { 6420 if (LJ_TARGET_OSX) {
6414 dasm_put(Dst, 1815); 6421 dasm_put(Dst, 1819);
6415 } 6422 }
6416 dasm_put(Dst, 1817, -LJ_TISNUM, -LJ_TISNUM); 6423 dasm_put(Dst, 1821, -LJ_TISNUM, -LJ_TISNUM);
6417 if (LJ_TARGET_OSX) { 6424 if (LJ_TARGET_OSX) {
6418 dasm_put(Dst, 1832); 6425 dasm_put(Dst, 1836);
6419 } 6426 }
6420 dasm_put(Dst, 1834); 6427 dasm_put(Dst, 1838);
6421 if (LJ_TARGET_OSX) { 6428 if (LJ_TARGET_OSX) {
6422 dasm_put(Dst, 1837); 6429 dasm_put(Dst, 1841);
6423 } 6430 }
6424 dasm_put(Dst, 1839, -LJ_TISNUM, -LJ_TISNUM); 6431 dasm_put(Dst, 1843, -LJ_TISNUM, -LJ_TISNUM);
6425 if (LJ_TARGET_OSX) { 6432 if (LJ_TARGET_OSX) {
6426 dasm_put(Dst, 1854); 6433 dasm_put(Dst, 1858);
6427 } 6434 }
6428 dasm_put(Dst, 1856); 6435 dasm_put(Dst, 1860);
6429 if (LJ_TARGET_OSX) { 6436 if (LJ_TARGET_OSX) {
6430 dasm_put(Dst, 1859); 6437 dasm_put(Dst, 1863);
6431 } 6438 }
6432 dasm_put(Dst, 1861, -LJ_TISNUM, Dt8(->upvalue[0]), -LJ_TISNUM, -LJ_TISNUM); 6439 dasm_put(Dst, 1865, -LJ_TISNUM, Dt8(->upvalue[0]), -LJ_TISNUM, -LJ_TISNUM);
6433 if (LJ_TARGET_OSX) { 6440 if (LJ_TARGET_OSX) {
6434 dasm_put(Dst, 1894); 6441 dasm_put(Dst, 1898);
6435 } 6442 }
6436 dasm_put(Dst, 1896); 6443 dasm_put(Dst, 1900);
6437 if (LJ_TARGET_OSX) { 6444 if (LJ_TARGET_OSX) {
6438 dasm_put(Dst, 1899); 6445 dasm_put(Dst, 1903);
6439 } 6446 }
6440 dasm_put(Dst, 1901, -LJ_TISNUM); 6447 dasm_put(Dst, 1905, -LJ_TISNUM);
6441 if (LJ_TARGET_OSX) { 6448 if (LJ_TARGET_OSX) {
6442 dasm_put(Dst, 1914); 6449 dasm_put(Dst, 1918);
6443 } 6450 }
6444 dasm_put(Dst, 1916); 6451 dasm_put(Dst, 1920);
6445 if (LJ_TARGET_OSX) { 6452 if (LJ_TARGET_OSX) {
6446 dasm_put(Dst, 1919); 6453 dasm_put(Dst, 1923);
6447 } 6454 }
6448 dasm_put(Dst, 1921, ~LJ_TISNUM, (2+1)*8, -LJ_TISNUM); 6455 dasm_put(Dst, 1925, ~LJ_TISNUM, (2+1)*8, -LJ_TISNUM);
6449 if (LJ_TARGET_OSX) { 6456 if (LJ_TARGET_OSX) {
6450 dasm_put(Dst, 1943); 6457 dasm_put(Dst, 1947);
6451 } 6458 }
6452 dasm_put(Dst, 1945); 6459 dasm_put(Dst, 1949);
6453 if (LJ_TARGET_OSX) { 6460 if (LJ_TARGET_OSX) {
6454 dasm_put(Dst, 1948); 6461 dasm_put(Dst, 1952);
6455 } 6462 }
6456 dasm_put(Dst, 1950, (2+1)*8, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM); 6463 dasm_put(Dst, 1954, (2+1)*8, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
6457 dasm_put(Dst, 2001, -LJ_TISNUM, -LJ_TISNUM); 6464 dasm_put(Dst, 2005, -LJ_TISNUM, -LJ_TISNUM);
6458 dasm_put(Dst, 2055, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TSTR, Dt5(->len), Dt5([1])); 6465 dasm_put(Dst, 2059, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TSTR, Dt5(->len), Dt5([1]));
6459 dasm_put(Dst, 2109, ~LJ_TISNUM, (0+1)*8, (1+1)*8, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TISNUM, Dt1(->base), Dt1(->base), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold)); 6466 dasm_put(Dst, 2113, ~LJ_TISNUM, (0+1)*8, (1+1)*8, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TISNUM, Dt1(->base), Dt1(->base), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
6460 dasm_put(Dst, 2168, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), -LJ_TISNUM, sizeof(GCstr)-1, -DISPATCH_GL(strempty), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, -LJ_TISNUM, Dt5(->len)); 6467 dasm_put(Dst, 2172, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), -LJ_TISNUM, sizeof(GCstr)-1, -DISPATCH_GL(strempty), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, -LJ_TISNUM, Dt5(->len));
6461 dasm_put(Dst, 2230, DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), Dt5([1]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr)); 6468 dasm_put(Dst, 2234, DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), Dt5([1]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr));
6462 dasm_put(Dst, 2283, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold)); 6469 dasm_put(Dst, 2287, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
6463 dasm_put(Dst, 2343, -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), -LJ_TTAB); 6470 dasm_put(Dst, 2347, -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), -LJ_TTAB);
6464 if (LJ_TARGET_OSX) { 6471 if (LJ_TARGET_OSX) {
6465 dasm_put(Dst, 2381); 6472 dasm_put(Dst, 2385);
6466 } 6473 }
6467 dasm_put(Dst, 2383); 6474 dasm_put(Dst, 2387);
6468 if (LJ_TARGET_OSX) { 6475 if (LJ_TARGET_OSX) {
6469 dasm_put(Dst, 2386); 6476 dasm_put(Dst, 2390);
6470 } 6477 }
6471 dasm_put(Dst, 2388, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM); 6478 dasm_put(Dst, 2392, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
6472 dasm_put(Dst, 2459, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM); 6479 dasm_put(Dst, 2463, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM);
6473 dasm_put(Dst, 2519, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM); 6480 dasm_put(Dst, 2523, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM);
6474 dasm_put(Dst, 2575, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM); 6481 dasm_put(Dst, 2579, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM);
6475 dasm_put(Dst, 2632, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, Dt1(->maxstack), Dt1(->top), Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->base), Dt1(->top), Dt7(->field_pc), FRAME_TYPE, FRAME_TYPEP); 6482 dasm_put(Dst, 2636, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, Dt1(->maxstack), Dt1(->top), Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->base), Dt1(->top), Dt7(->field_pc), FRAME_TYPE, FRAME_TYPEP);
6476 dasm_put(Dst, 2695, LUA_MINSTACK, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base)); 6483 dasm_put(Dst, 2699, LUA_MINSTACK, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base));
6477#if LJ_HASJIT 6484#if LJ_HASJIT
6478 dasm_put(Dst, 2729, DISPATCH_GL(hookmask), HOOK_VMEVENT, DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount)); 6485 dasm_put(Dst, 2734, DISPATCH_GL(hookmask), HOOK_VMEVENT, DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
6479#endif 6486#endif
6480 dasm_put(Dst, 2749, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE, Dt1(->base), Dt1(->base)); 6487 dasm_put(Dst, 2754, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE, Dt1(->base), Dt1(->base));
6481 dasm_put(Dst, 2795, GG_DISP2STATIC); 6488 dasm_put(Dst, 2800, GG_DISP2STATIC);
6482#if LJ_HASJIT 6489#if LJ_HASJIT
6483 dasm_put(Dst, 2811, -GG_DISP2J, Dt7(->field_pc), DISPATCH_J(L), PC2PROTO(framesize), Dt1(->base), Dt1(->top)); 6490 dasm_put(Dst, 2816, -GG_DISP2J, Dt7(->field_pc), DISPATCH_J(L), PC2PROTO(framesize), Dt1(->base), Dt1(->top));
6484#endif 6491#endif
6485 dasm_put(Dst, 2832); 6492 dasm_put(Dst, 2837);
6486#if LJ_HASJIT 6493#if LJ_HASJIT
6487 dasm_put(Dst, 2835); 6494 dasm_put(Dst, 2840);
6488#endif 6495#endif
6489 dasm_put(Dst, 2838); 6496 dasm_put(Dst, 2843);
6490#if LJ_HASJIT 6497#if LJ_HASJIT
6491 dasm_put(Dst, 2840); 6498 dasm_put(Dst, 2845);
6492#endif 6499#endif
6493 dasm_put(Dst, 2843, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top)); 6500 dasm_put(Dst, 2848, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
6494#if LJ_HASJIT 6501#if LJ_HASJIT
6495 dasm_put(Dst, 2866, LJ_VMST_EXIT, DISPATCH_GL(vmstate), DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(exitno), DISPATCH_J(L), Dt1(->base), DISPATCH_GL(jit_L), -GG_DISP2J, Dt1(->cframe), Dt1(->base), ~CFRAME_RAWMASK); 6502 dasm_put(Dst, 2871, LJ_VMST_EXIT, DISPATCH_GL(vmstate), DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(exitno), DISPATCH_J(L), Dt1(->base), DISPATCH_GL(jit_L), -GG_DISP2J, Dt1(->cframe), Dt1(->base), ~CFRAME_RAWMASK);
6496#endif 6503#endif
6497 dasm_put(Dst, 2914); 6504 dasm_put(Dst, 2919);
6498#if LJ_HASJIT 6505#if LJ_HASJIT
6499 dasm_put(Dst, 2916, Dt7(->field_pc), DISPATCH_GL(jit_L), LJ_VMST_INTERP, PC2PROTO(k), DISPATCH_GL(vmstate), BC_FUNCF); 6506 dasm_put(Dst, 2921, Dt7(->field_pc), DISPATCH_GL(jit_L), LJ_VMST_INTERP, PC2PROTO(k), DISPATCH_GL(vmstate), BC_FUNCF);
6500#endif 6507#endif
6501 dasm_put(Dst, 2953); 6508 dasm_put(Dst, 2958);
6502#if LJ_HASJIT 6509#if LJ_HASJIT
6503 dasm_put(Dst, 3027); 6510 dasm_put(Dst, 3034);
6504#endif 6511#endif
6505 dasm_put(Dst, 3041); 6512 dasm_put(Dst, 3048);
6506 { 6513 {
6507 int i; 6514 int i;
6508 for (i = 31; i >= 0; i--) { 6515 for (i = 31; i >= 0; i--) {
6509 dasm_put(Dst, 3077, i, i); 6516 dasm_put(Dst, 3084, i, i);
6510 } 6517 }
6511 } 6518 }
6512 dasm_put(Dst, 3082); 6519 dasm_put(Dst, 3089);
6513#if LJ_HASJIT 6520#if LJ_HASJIT
6514 dasm_put(Dst, 3111); 6521 dasm_put(Dst, 3118);
6515#else 6522#else
6516 dasm_put(Dst, 3136); 6523 dasm_put(Dst, 3143);
6517#endif 6524#endif
6518 dasm_put(Dst, 3138); 6525 dasm_put(Dst, 3145);
6519#if LJ_HASFFI 6526#if LJ_HASFFI
6520#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V) 6527#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V)
6521 dasm_put(Dst, 3140, Dt2(->ctype_state), GG_G2DISP, DtE(->cb.gpr[0]), DtE(->cb.gpr[2]), CFRAME_SIZE, DtE(->cb.stack), DtE(->cb.slot), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), Dt7(->field_pc)); 6528 dasm_put(Dst, 3147, Dt2(->ctype_state), GG_G2DISP, DtE(->cb.gpr[0]), DtE(->cb.gpr[2]), CFRAME_SIZE, DtE(->cb.stack), DtE(->cb.slot), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), Dt7(->field_pc));
6522#endif 6529#endif
6523 dasm_put(Dst, 3183); 6530 dasm_put(Dst, 3190);
6524#if LJ_HASFFI 6531#if LJ_HASFFI
6525 dasm_put(Dst, 3185, DISPATCH_GL(ctype_state), Dt1(->base), Dt1(->top), DtE(->L), DtE(->cb.gpr[0])); 6532 dasm_put(Dst, 3192, DISPATCH_GL(ctype_state), Dt1(->base), Dt1(->top), DtE(->L), DtE(->cb.gpr[0]));
6526#endif 6533#endif
6527 dasm_put(Dst, 3202); 6534 dasm_put(Dst, 3209);
6528#if LJ_HASFFI 6535#if LJ_HASFFI
6529#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V) 6536#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
6530 dasm_put(Dst, 3204, DtF(->spadj), DtF(->nsp), offsetof(CCallState, stack), DtF(->func), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->gpr[2]), DtF(->gpr[3]), DtF(->gpr[0]), DtF(->gpr[1])); 6537 dasm_put(Dst, 3211, DtF(->spadj), DtF(->nsp), offsetof(CCallState, stack), DtF(->func), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->gpr[2]), DtF(->gpr[3]), DtF(->gpr[0]), DtF(->gpr[1]));
6531#endif 6538#endif
6532} 6539}
6533 6540
@@ -6535,7 +6542,7 @@ static void build_subroutines(BuildCtx *ctx)
6535static void build_ins(BuildCtx *ctx, BCOp op, int defop) 6542static void build_ins(BuildCtx *ctx, BCOp op, int defop)
6536{ 6543{
6537 int vk = 0; 6544 int vk = 0;
6538 dasm_put(Dst, 3242, defop); 6545 dasm_put(Dst, 3249, defop);
6539 6546
6540 switch (op) { 6547 switch (op) {
6541 6548
@@ -6544,174 +6551,174 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
6544 /* Remember: all ops branch for a true comparison, fall through otherwise. */ 6551 /* Remember: all ops branch for a true comparison, fall through otherwise. */
6545 6552
6546 case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT: 6553 case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
6547 dasm_put(Dst, 3244, -LJ_TISNUM, -LJ_TISNUM); 6554 dasm_put(Dst, 3251, -LJ_TISNUM, -LJ_TISNUM);
6548 if (op == BC_ISLT) { 6555 if (op == BC_ISLT) {
6549 dasm_put(Dst, 3260); 6556 dasm_put(Dst, 3267);
6550 } else if (op == BC_ISGE) { 6557 } else if (op == BC_ISGE) {
6551 dasm_put(Dst, 3262); 6558 dasm_put(Dst, 3269);
6552 } else if (op == BC_ISLE) { 6559 } else if (op == BC_ISLE) {
6553 dasm_put(Dst, 3264); 6560 dasm_put(Dst, 3271);
6554 } else { 6561 } else {
6555 dasm_put(Dst, 3266); 6562 dasm_put(Dst, 3273);
6556 } 6563 }
6557 dasm_put(Dst, 3268, -LJ_TISNUM); 6564 dasm_put(Dst, 3275, -LJ_TISNUM);
6558 if (op == BC_ISLT) { 6565 if (op == BC_ISLT) {
6559 dasm_put(Dst, 3304); 6566 dasm_put(Dst, 3311);
6560 } else if (op == BC_ISGE) { 6567 } else if (op == BC_ISGE) {
6561 dasm_put(Dst, 3306); 6568 dasm_put(Dst, 3313);
6562 } else if (op == BC_ISLE) { 6569 } else if (op == BC_ISLE) {
6563 dasm_put(Dst, 3308); 6570 dasm_put(Dst, 3315);
6564 } else { 6571 } else {
6565 dasm_put(Dst, 3310); 6572 dasm_put(Dst, 3317);
6566 } 6573 }
6567 dasm_put(Dst, 3312); 6574 dasm_put(Dst, 3319);
6568 break; 6575 break;
6569 6576
6570 case BC_ISEQV: case BC_ISNEV: 6577 case BC_ISEQV: case BC_ISNEV:
6571 vk = op == BC_ISEQV; 6578 vk = op == BC_ISEQV;
6572 dasm_put(Dst, 3315, -LJ_TISNUM, -LJ_TISNUM); 6579 dasm_put(Dst, 3322, -LJ_TISNUM, -LJ_TISNUM);
6573 if (vk) { 6580 if (vk) {
6574 dasm_put(Dst, 3326); 6581 dasm_put(Dst, 3333);
6575 } else { 6582 } else {
6576 dasm_put(Dst, 3329); 6583 dasm_put(Dst, 3336);
6577 } 6584 }
6578 if (LJ_HASFFI) { 6585 if (LJ_HASFFI) {
6579 dasm_put(Dst, 3332, -LJ_TCDATA, -LJ_TCDATA); 6586 dasm_put(Dst, 3339, -LJ_TCDATA, -LJ_TCDATA);
6580 } 6587 }
6581 dasm_put(Dst, 3339, -LJ_TISPRI); 6588 dasm_put(Dst, 3346, -LJ_TISPRI);
6582 if (vk) { 6589 if (vk) {
6583 dasm_put(Dst, 3348, -LJ_TISTABUD); 6590 dasm_put(Dst, 3355, -LJ_TISTABUD);
6584 } else { 6591 } else {
6585 dasm_put(Dst, 3365, -LJ_TISTABUD); 6592 dasm_put(Dst, 3372, -LJ_TISTABUD);
6586 } 6593 }
6587 dasm_put(Dst, 3372, Dt6(->metatable)); 6594 dasm_put(Dst, 3379, Dt6(->metatable));
6588 if (vk) { 6595 if (vk) {
6589 dasm_put(Dst, 3376); 6596 dasm_put(Dst, 3383);
6590 } else { 6597 } else {
6591 dasm_put(Dst, 3379); 6598 dasm_put(Dst, 3386);
6592 } 6599 }
6593 dasm_put(Dst, 3382, Dt6(->nomm), 1-vk, 1<<MM_eq); 6600 dasm_put(Dst, 3389, Dt6(->nomm), 1-vk, 1<<MM_eq);
6594 if (vk) { 6601 if (vk) {
6595 dasm_put(Dst, 3392); 6602 dasm_put(Dst, 3399);
6596 } else { 6603 } else {
6597 dasm_put(Dst, 3395); 6604 dasm_put(Dst, 3402);
6598 } 6605 }
6599 break; 6606 break;
6600 6607
6601 case BC_ISEQS: case BC_ISNES: 6608 case BC_ISEQS: case BC_ISNES:
6602 vk = op == BC_ISEQS; 6609 vk = op == BC_ISEQS;
6603 dasm_put(Dst, 3405, -LJ_TSTR); 6610 dasm_put(Dst, 3412, -LJ_TSTR);
6604 if (LJ_HASFFI) { 6611 if (LJ_HASFFI) {
6605 dasm_put(Dst, 3414); 6612 dasm_put(Dst, 3421);
6606 } else { 6613 } else {
6607 dasm_put(Dst, 3418); 6614 dasm_put(Dst, 3425);
6608 } 6615 }
6609 if (vk) { 6616 if (vk) {
6610 dasm_put(Dst, 3420); 6617 dasm_put(Dst, 3427);
6611 } else { 6618 } else {
6612 dasm_put(Dst, 3423); 6619 dasm_put(Dst, 3430);
6613 } 6620 }
6614 dasm_put(Dst, 3426); 6621 dasm_put(Dst, 3433);
6615 if (LJ_HASFFI) { 6622 if (LJ_HASFFI) {
6616 dasm_put(Dst, 3433, -LJ_TCDATA); 6623 dasm_put(Dst, 3440, -LJ_TCDATA);
6617 } 6624 }
6618 break; 6625 break;
6619 6626
6620 case BC_ISEQN: case BC_ISNEN: 6627 case BC_ISEQN: case BC_ISNEN:
6621 vk = op == BC_ISEQN; 6628 vk = op == BC_ISEQN;
6622 dasm_put(Dst, 3441); 6629 dasm_put(Dst, 3448);
6623 if (vk) { 6630 if (vk) {
6624 dasm_put(Dst, 3448); 6631 dasm_put(Dst, 3455);
6625 } else { 6632 } else {
6626 dasm_put(Dst, 3450); 6633 dasm_put(Dst, 3457);
6627 } 6634 }
6628 dasm_put(Dst, 3452, -LJ_TISNUM, -LJ_TISNUM); 6635 dasm_put(Dst, 3459, -LJ_TISNUM, -LJ_TISNUM);
6629 if (vk) { 6636 if (vk) {
6630 dasm_put(Dst, 3462); 6637 dasm_put(Dst, 3469);
6631 } else { 6638 } else {
6632 dasm_put(Dst, 3465); 6639 dasm_put(Dst, 3472);
6633 } 6640 }
6634 dasm_put(Dst, 3468); 6641 dasm_put(Dst, 3475);
6635 if (LJ_HASFFI) { 6642 if (LJ_HASFFI) {
6636 dasm_put(Dst, 3477); 6643 dasm_put(Dst, 3484);
6637 } else { 6644 } else {
6638 if (!vk) { 6645 if (!vk) {
6639 dasm_put(Dst, 3480); 6646 dasm_put(Dst, 3487);
6640 } 6647 }
6641 dasm_put(Dst, 3482); 6648 dasm_put(Dst, 3489);
6642 } 6649 }
6643 dasm_put(Dst, 3485, -LJ_TISNUM); 6650 dasm_put(Dst, 3492, -LJ_TISNUM);
6644 if (vk) { 6651 if (vk) {
6645 dasm_put(Dst, 3501); 6652 dasm_put(Dst, 3508);
6646 } else { 6653 } else {
6647 dasm_put(Dst, 3503); 6654 dasm_put(Dst, 3510);
6648 } 6655 }
6649 dasm_put(Dst, 3505); 6656 dasm_put(Dst, 3512);
6650 if (LJ_HASFFI) { 6657 if (LJ_HASFFI) {
6651 dasm_put(Dst, 3508, -LJ_TCDATA); 6658 dasm_put(Dst, 3515, -LJ_TCDATA);
6652 } 6659 }
6653 break; 6660 break;
6654 6661
6655 case BC_ISEQP: case BC_ISNEP: 6662 case BC_ISEQP: case BC_ISNEP:
6656 vk = op == BC_ISEQP; 6663 vk = op == BC_ISEQP;
6657 dasm_put(Dst, 3516); 6664 dasm_put(Dst, 3523);
6658 if (LJ_HASFFI) { 6665 if (LJ_HASFFI) {
6659 dasm_put(Dst, 3522, -LJ_TCDATA); 6666 dasm_put(Dst, 3529, -LJ_TCDATA);
6660 } 6667 }
6661 dasm_put(Dst, 3527); 6668 dasm_put(Dst, 3534);
6662 if (vk) { 6669 if (vk) {
6663 dasm_put(Dst, 3529); 6670 dasm_put(Dst, 3536);
6664 } else { 6671 } else {
6665 dasm_put(Dst, 3531); 6672 dasm_put(Dst, 3538);
6666 } 6673 }
6667 dasm_put(Dst, 3533); 6674 dasm_put(Dst, 3540);
6668 break; 6675 break;
6669 6676
6670 /* -- Unary test and copy ops ------------------------------------------- */ 6677 /* -- Unary test and copy ops ------------------------------------------- */
6671 6678
6672 case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF: 6679 case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
6673 dasm_put(Dst, 3540, -LJ_TTRUE); 6680 dasm_put(Dst, 3547, -LJ_TTRUE);
6674 if (op == BC_ISTC || op == BC_IST) { 6681 if (op == BC_ISTC || op == BC_IST) {
6675 dasm_put(Dst, 3548); 6682 dasm_put(Dst, 3555);
6676 if (op == BC_ISTC) { 6683 if (op == BC_ISTC) {
6677 dasm_put(Dst, 3550); 6684 dasm_put(Dst, 3557);
6678 } 6685 }
6679 } else { 6686 } else {
6680 dasm_put(Dst, 3552); 6687 dasm_put(Dst, 3559);
6681 if (op == BC_ISFC) { 6688 if (op == BC_ISFC) {
6682 dasm_put(Dst, 3554); 6689 dasm_put(Dst, 3561);
6683 } 6690 }
6684 } 6691 }
6685 dasm_put(Dst, 3556); 6692 dasm_put(Dst, 3563);
6686 break; 6693 break;
6687 6694
6688 /* -- Unary ops --------------------------------------------------------- */ 6695 /* -- Unary ops --------------------------------------------------------- */
6689 6696
6690 case BC_MOV: 6697 case BC_MOV:
6691 dasm_put(Dst, 3563); 6698 dasm_put(Dst, 3570);
6692 break; 6699 break;
6693 case BC_NOT: 6700 case BC_NOT:
6694 dasm_put(Dst, 3573, -LJ_TTRUE, ~LJ_TFALSE, ~LJ_TTRUE); 6701 dasm_put(Dst, 3580, -LJ_TTRUE, ~LJ_TFALSE, ~LJ_TTRUE);
6695 break; 6702 break;
6696 case BC_UNM: 6703 case BC_UNM:
6697 dasm_put(Dst, 3590, -LJ_TISNUM); 6704 dasm_put(Dst, 3597, -LJ_TISNUM);
6698 break; 6705 break;
6699 case BC_LEN: 6706 case BC_LEN:
6700 dasm_put(Dst, 3616, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TTAB); 6707 dasm_put(Dst, 3623, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TTAB);
6701#ifdef LUAJIT_ENABLE_LUA52COMPAT 6708#ifdef LUAJIT_ENABLE_LUA52COMPAT
6702 dasm_put(Dst, 3640, Dt6(->metatable)); 6709 dasm_put(Dst, 3647, Dt6(->metatable));
6703#endif 6710#endif
6704 dasm_put(Dst, 3647); 6711 dasm_put(Dst, 3654);
6705 if (LJ_TARGET_OSX) { 6712 if (LJ_TARGET_OSX) {
6706 dasm_put(Dst, 3649); 6713 dasm_put(Dst, 3656);
6707 } 6714 }
6708 dasm_put(Dst, 3651); 6715 dasm_put(Dst, 3658);
6709 if (LJ_TARGET_OSX) { 6716 if (LJ_TARGET_OSX) {
6710 dasm_put(Dst, 3654); 6717 dasm_put(Dst, 3661);
6711 } 6718 }
6712 dasm_put(Dst, 3656); 6719 dasm_put(Dst, 3663);
6713#ifdef LUAJIT_ENABLE_LUA52COMPAT 6720#ifdef LUAJIT_ENABLE_LUA52COMPAT
6714 dasm_put(Dst, 3659, Dt6(->nomm), 1<<MM_len); 6721 dasm_put(Dst, 3666, Dt6(->nomm), 1<<MM_len);
6715#endif 6722#endif
6716 break; 6723 break;
6717 6724
@@ -6719,403 +6726,403 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
6719 6726
6720 6727
6721 case BC_ADDVN: case BC_ADDNV: case BC_ADDVV: 6728 case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
6722 dasm_put(Dst, 3669); 6729 dasm_put(Dst, 3676);
6723 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 6730 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
6724 switch (vk) { 6731 switch (vk) {
6725 case 0: 6732 case 0:
6726 dasm_put(Dst, 3672); 6733 dasm_put(Dst, 3679);
6727 break; 6734 break;
6728 case 1: 6735 case 1:
6729 dasm_put(Dst, 3675); 6736 dasm_put(Dst, 3682);
6730 break; 6737 break;
6731 default: 6738 default:
6732 dasm_put(Dst, 3678); 6739 dasm_put(Dst, 3685);
6733 break; 6740 break;
6734 } 6741 }
6735 dasm_put(Dst, 3681); 6742 dasm_put(Dst, 3688);
6736 if (vk == 1) { 6743 if (vk == 1) {
6737 dasm_put(Dst, 3683, -LJ_TISNUM, -LJ_TISNUM); 6744 dasm_put(Dst, 3690, -LJ_TISNUM, -LJ_TISNUM);
6738 } else { 6745 } else {
6739 dasm_put(Dst, 3688, -LJ_TISNUM, -LJ_TISNUM); 6746 dasm_put(Dst, 3695, -LJ_TISNUM, -LJ_TISNUM);
6740 } 6747 }
6741 dasm_put(Dst, 3693); 6748 dasm_put(Dst, 3700);
6742 switch (vk) { 6749 switch (vk) {
6743 case 0: 6750 case 0:
6744 dasm_put(Dst, 3697); 6751 dasm_put(Dst, 3704);
6745 break; 6752 break;
6746 case 1: 6753 case 1:
6747 dasm_put(Dst, 3700); 6754 dasm_put(Dst, 3707);
6748 break; 6755 break;
6749 default: 6756 default:
6750 dasm_put(Dst, 3703); 6757 dasm_put(Dst, 3710);
6751 break; 6758 break;
6752 } 6759 }
6753 dasm_put(Dst, 3706); 6760 dasm_put(Dst, 3713);
6754 switch (vk) { 6761 switch (vk) {
6755 case 0: 6762 case 0:
6756 if (vk == 1) { 6763 if (vk == 1) {
6757 dasm_put(Dst, 3715, -LJ_TISNUM, -LJ_TISNUM); 6764 dasm_put(Dst, 3722, -LJ_TISNUM, -LJ_TISNUM);
6758 } else { 6765 } else {
6759 dasm_put(Dst, 3720, -LJ_TISNUM, -LJ_TISNUM); 6766 dasm_put(Dst, 3727, -LJ_TISNUM, -LJ_TISNUM);
6760 } 6767 }
6761 dasm_put(Dst, 3725); 6768 dasm_put(Dst, 3732);
6762 break; 6769 break;
6763 case 1: 6770 case 1:
6764 if (vk == 1) { 6771 if (vk == 1) {
6765 dasm_put(Dst, 3728, -LJ_TISNUM, -LJ_TISNUM); 6772 dasm_put(Dst, 3735, -LJ_TISNUM, -LJ_TISNUM);
6766 } else { 6773 } else {
6767 dasm_put(Dst, 3733, -LJ_TISNUM, -LJ_TISNUM); 6774 dasm_put(Dst, 3740, -LJ_TISNUM, -LJ_TISNUM);
6768 } 6775 }
6769 dasm_put(Dst, 3738); 6776 dasm_put(Dst, 3745);
6770 break; 6777 break;
6771 default: 6778 default:
6772 if (vk == 1) { 6779 if (vk == 1) {
6773 dasm_put(Dst, 3741, -LJ_TISNUM, -LJ_TISNUM); 6780 dasm_put(Dst, 3748, -LJ_TISNUM, -LJ_TISNUM);
6774 } else { 6781 } else {
6775 dasm_put(Dst, 3746, -LJ_TISNUM, -LJ_TISNUM); 6782 dasm_put(Dst, 3753, -LJ_TISNUM, -LJ_TISNUM);
6776 } 6783 }
6777 dasm_put(Dst, 3751); 6784 dasm_put(Dst, 3758);
6778 break; 6785 break;
6779 } 6786 }
6780 dasm_put(Dst, 3754); 6787 dasm_put(Dst, 3761);
6781 break; 6788 break;
6782 case BC_SUBVN: case BC_SUBNV: case BC_SUBVV: 6789 case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
6783 dasm_put(Dst, 3760); 6790 dasm_put(Dst, 3767);
6784 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 6791 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
6785 switch (vk) { 6792 switch (vk) {
6786 case 0: 6793 case 0:
6787 dasm_put(Dst, 3763); 6794 dasm_put(Dst, 3770);
6788 break; 6795 break;
6789 case 1: 6796 case 1:
6790 dasm_put(Dst, 3766); 6797 dasm_put(Dst, 3773);
6791 break; 6798 break;
6792 default: 6799 default:
6793 dasm_put(Dst, 3769); 6800 dasm_put(Dst, 3776);
6794 break; 6801 break;
6795 } 6802 }
6796 dasm_put(Dst, 3772); 6803 dasm_put(Dst, 3779);
6797 if (vk == 1) { 6804 if (vk == 1) {
6798 dasm_put(Dst, 3774, -LJ_TISNUM, -LJ_TISNUM); 6805 dasm_put(Dst, 3781, -LJ_TISNUM, -LJ_TISNUM);
6799 } else { 6806 } else {
6800 dasm_put(Dst, 3779, -LJ_TISNUM, -LJ_TISNUM); 6807 dasm_put(Dst, 3786, -LJ_TISNUM, -LJ_TISNUM);
6801 } 6808 }
6802 dasm_put(Dst, 3784); 6809 dasm_put(Dst, 3791);
6803 switch (vk) { 6810 switch (vk) {
6804 case 0: 6811 case 0:
6805 dasm_put(Dst, 3788); 6812 dasm_put(Dst, 3795);
6806 break; 6813 break;
6807 case 1: 6814 case 1:
6808 dasm_put(Dst, 3791); 6815 dasm_put(Dst, 3798);
6809 break; 6816 break;
6810 default: 6817 default:
6811 dasm_put(Dst, 3794); 6818 dasm_put(Dst, 3801);
6812 break; 6819 break;
6813 } 6820 }
6814 dasm_put(Dst, 3797); 6821 dasm_put(Dst, 3804);
6815 switch (vk) { 6822 switch (vk) {
6816 case 0: 6823 case 0:
6817 if (vk == 1) { 6824 if (vk == 1) {
6818 dasm_put(Dst, 3806, -LJ_TISNUM, -LJ_TISNUM); 6825 dasm_put(Dst, 3813, -LJ_TISNUM, -LJ_TISNUM);
6819 } else { 6826 } else {
6820 dasm_put(Dst, 3811, -LJ_TISNUM, -LJ_TISNUM); 6827 dasm_put(Dst, 3818, -LJ_TISNUM, -LJ_TISNUM);
6821 } 6828 }
6822 dasm_put(Dst, 3816); 6829 dasm_put(Dst, 3823);
6823 break; 6830 break;
6824 case 1: 6831 case 1:
6825 if (vk == 1) { 6832 if (vk == 1) {
6826 dasm_put(Dst, 3819, -LJ_TISNUM, -LJ_TISNUM); 6833 dasm_put(Dst, 3826, -LJ_TISNUM, -LJ_TISNUM);
6827 } else { 6834 } else {
6828 dasm_put(Dst, 3824, -LJ_TISNUM, -LJ_TISNUM); 6835 dasm_put(Dst, 3831, -LJ_TISNUM, -LJ_TISNUM);
6829 } 6836 }
6830 dasm_put(Dst, 3829); 6837 dasm_put(Dst, 3836);
6831 break; 6838 break;
6832 default: 6839 default:
6833 if (vk == 1) { 6840 if (vk == 1) {
6834 dasm_put(Dst, 3832, -LJ_TISNUM, -LJ_TISNUM); 6841 dasm_put(Dst, 3839, -LJ_TISNUM, -LJ_TISNUM);
6835 } else { 6842 } else {
6836 dasm_put(Dst, 3837, -LJ_TISNUM, -LJ_TISNUM); 6843 dasm_put(Dst, 3844, -LJ_TISNUM, -LJ_TISNUM);
6837 } 6844 }
6838 dasm_put(Dst, 3842); 6845 dasm_put(Dst, 3849);
6839 break; 6846 break;
6840 } 6847 }
6841 dasm_put(Dst, 3845); 6848 dasm_put(Dst, 3852);
6842 break; 6849 break;
6843 case BC_MULVN: case BC_MULNV: case BC_MULVV: 6850 case BC_MULVN: case BC_MULNV: case BC_MULVV:
6844 dasm_put(Dst, 3851); 6851 dasm_put(Dst, 3858);
6845 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 6852 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
6846 switch (vk) { 6853 switch (vk) {
6847 case 0: 6854 case 0:
6848 dasm_put(Dst, 3854); 6855 dasm_put(Dst, 3861);
6849 break; 6856 break;
6850 case 1: 6857 case 1:
6851 dasm_put(Dst, 3857); 6858 dasm_put(Dst, 3864);
6852 break; 6859 break;
6853 default: 6860 default:
6854 dasm_put(Dst, 3860); 6861 dasm_put(Dst, 3867);
6855 break; 6862 break;
6856 } 6863 }
6857 dasm_put(Dst, 3863); 6864 dasm_put(Dst, 3870);
6858 if (vk == 1) { 6865 if (vk == 1) {
6859 dasm_put(Dst, 3865, -LJ_TISNUM, -LJ_TISNUM); 6866 dasm_put(Dst, 3872, -LJ_TISNUM, -LJ_TISNUM);
6860 } else { 6867 } else {
6861 dasm_put(Dst, 3870, -LJ_TISNUM, -LJ_TISNUM); 6868 dasm_put(Dst, 3877, -LJ_TISNUM, -LJ_TISNUM);
6862 } 6869 }
6863 dasm_put(Dst, 3875); 6870 dasm_put(Dst, 3882);
6864 switch (vk) { 6871 switch (vk) {
6865 case 0: 6872 case 0:
6866 dasm_put(Dst, 3880); 6873 dasm_put(Dst, 3887);
6867 break; 6874 break;
6868 case 1: 6875 case 1:
6869 dasm_put(Dst, 3883); 6876 dasm_put(Dst, 3890);
6870 break; 6877 break;
6871 default: 6878 default:
6872 dasm_put(Dst, 3886); 6879 dasm_put(Dst, 3893);
6873 break; 6880 break;
6874 } 6881 }
6875 dasm_put(Dst, 3889); 6882 dasm_put(Dst, 3896);
6876 switch (vk) { 6883 switch (vk) {
6877 case 0: 6884 case 0:
6878 if (vk == 1) { 6885 if (vk == 1) {
6879 dasm_put(Dst, 3898, -LJ_TISNUM, -LJ_TISNUM); 6886 dasm_put(Dst, 3905, -LJ_TISNUM, -LJ_TISNUM);
6880 } else { 6887 } else {
6881 dasm_put(Dst, 3903, -LJ_TISNUM, -LJ_TISNUM); 6888 dasm_put(Dst, 3910, -LJ_TISNUM, -LJ_TISNUM);
6882 } 6889 }
6883 dasm_put(Dst, 3908); 6890 dasm_put(Dst, 3915);
6884 break; 6891 break;
6885 case 1: 6892 case 1:
6886 if (vk == 1) { 6893 if (vk == 1) {
6887 dasm_put(Dst, 3911, -LJ_TISNUM, -LJ_TISNUM); 6894 dasm_put(Dst, 3918, -LJ_TISNUM, -LJ_TISNUM);
6888 } else { 6895 } else {
6889 dasm_put(Dst, 3916, -LJ_TISNUM, -LJ_TISNUM); 6896 dasm_put(Dst, 3923, -LJ_TISNUM, -LJ_TISNUM);
6890 } 6897 }
6891 dasm_put(Dst, 3921); 6898 dasm_put(Dst, 3928);
6892 break; 6899 break;
6893 default: 6900 default:
6894 if (vk == 1) { 6901 if (vk == 1) {
6895 dasm_put(Dst, 3924, -LJ_TISNUM, -LJ_TISNUM); 6902 dasm_put(Dst, 3931, -LJ_TISNUM, -LJ_TISNUM);
6896 } else { 6903 } else {
6897 dasm_put(Dst, 3929, -LJ_TISNUM, -LJ_TISNUM); 6904 dasm_put(Dst, 3936, -LJ_TISNUM, -LJ_TISNUM);
6898 } 6905 }
6899 dasm_put(Dst, 3934); 6906 dasm_put(Dst, 3941);
6900 break; 6907 break;
6901 } 6908 }
6902 dasm_put(Dst, 3937); 6909 dasm_put(Dst, 3944);
6903 break; 6910 break;
6904 case BC_DIVVN: case BC_DIVNV: case BC_DIVVV: 6911 case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
6905 dasm_put(Dst, 3943); 6912 dasm_put(Dst, 3950);
6906 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 6913 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
6907 switch (vk) { 6914 switch (vk) {
6908 case 0: 6915 case 0:
6909 dasm_put(Dst, 3946); 6916 dasm_put(Dst, 3953);
6910 break; 6917 break;
6911 case 1: 6918 case 1:
6912 dasm_put(Dst, 3949); 6919 dasm_put(Dst, 3956);
6913 break; 6920 break;
6914 default: 6921 default:
6915 dasm_put(Dst, 3952); 6922 dasm_put(Dst, 3959);
6916 break; 6923 break;
6917 } 6924 }
6918 switch (vk) { 6925 switch (vk) {
6919 case 0: 6926 case 0:
6920 if (vk == 1) { 6927 if (vk == 1) {
6921 dasm_put(Dst, 3955, -LJ_TISNUM, -LJ_TISNUM); 6928 dasm_put(Dst, 3962, -LJ_TISNUM, -LJ_TISNUM);
6922 } else { 6929 } else {
6923 dasm_put(Dst, 3960, -LJ_TISNUM, -LJ_TISNUM); 6930 dasm_put(Dst, 3967, -LJ_TISNUM, -LJ_TISNUM);
6924 } 6931 }
6925 dasm_put(Dst, 3965); 6932 dasm_put(Dst, 3972);
6926 break; 6933 break;
6927 case 1: 6934 case 1:
6928 if (vk == 1) { 6935 if (vk == 1) {
6929 dasm_put(Dst, 3968, -LJ_TISNUM, -LJ_TISNUM); 6936 dasm_put(Dst, 3975, -LJ_TISNUM, -LJ_TISNUM);
6930 } else { 6937 } else {
6931 dasm_put(Dst, 3973, -LJ_TISNUM, -LJ_TISNUM); 6938 dasm_put(Dst, 3980, -LJ_TISNUM, -LJ_TISNUM);
6932 } 6939 }
6933 dasm_put(Dst, 3978); 6940 dasm_put(Dst, 3985);
6934 break; 6941 break;
6935 default: 6942 default:
6936 if (vk == 1) { 6943 if (vk == 1) {
6937 dasm_put(Dst, 3981, -LJ_TISNUM, -LJ_TISNUM); 6944 dasm_put(Dst, 3988, -LJ_TISNUM, -LJ_TISNUM);
6938 } else { 6945 } else {
6939 dasm_put(Dst, 3986, -LJ_TISNUM, -LJ_TISNUM); 6946 dasm_put(Dst, 3993, -LJ_TISNUM, -LJ_TISNUM);
6940 } 6947 }
6941 dasm_put(Dst, 3991); 6948 dasm_put(Dst, 3998);
6942 break; 6949 break;
6943 } 6950 }
6944 dasm_put(Dst, 3994); 6951 dasm_put(Dst, 4001);
6945 break; 6952 break;
6946 case BC_MODVN: case BC_MODNV: case BC_MODVV: 6953 case BC_MODVN: case BC_MODNV: case BC_MODVV:
6947 dasm_put(Dst, 4004); 6954 dasm_put(Dst, 4011);
6948 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 6955 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
6949 switch (vk) { 6956 switch (vk) {
6950 case 0: 6957 case 0:
6951 dasm_put(Dst, 4007); 6958 dasm_put(Dst, 4014);
6952 break; 6959 break;
6953 case 1: 6960 case 1:
6954 dasm_put(Dst, 4010); 6961 dasm_put(Dst, 4017);
6955 break; 6962 break;
6956 default: 6963 default:
6957 dasm_put(Dst, 4013); 6964 dasm_put(Dst, 4020);
6958 break; 6965 break;
6959 } 6966 }
6960 if (vk == 1) { 6967 if (vk == 1) {
6961 dasm_put(Dst, 4016, -LJ_TISNUM, -LJ_TISNUM); 6968 dasm_put(Dst, 4023, -LJ_TISNUM, -LJ_TISNUM);
6962 } else { 6969 } else {
6963 dasm_put(Dst, 4021, -LJ_TISNUM, -LJ_TISNUM); 6970 dasm_put(Dst, 4028, -LJ_TISNUM, -LJ_TISNUM);
6964 } 6971 }
6965 dasm_put(Dst, 4026); 6972 dasm_put(Dst, 4033);
6966 switch (vk) { 6973 switch (vk) {
6967 case 0: 6974 case 0:
6968 dasm_put(Dst, 4030); 6975 dasm_put(Dst, 4037);
6969 break; 6976 break;
6970 case 1: 6977 case 1:
6971 dasm_put(Dst, 4033); 6978 dasm_put(Dst, 4040);
6972 break; 6979 break;
6973 default: 6980 default:
6974 dasm_put(Dst, 4036); 6981 dasm_put(Dst, 4043);
6975 break; 6982 break;
6976 } 6983 }
6977 dasm_put(Dst, 4039, ~LJ_TISNUM); 6984 dasm_put(Dst, 4046, ~LJ_TISNUM);
6978 switch (vk) { 6985 switch (vk) {
6979 case 0: 6986 case 0:
6980 if (vk == 1) { 6987 if (vk == 1) {
6981 dasm_put(Dst, 4053, -LJ_TISNUM, -LJ_TISNUM); 6988 dasm_put(Dst, 4060, -LJ_TISNUM, -LJ_TISNUM);
6982 } else { 6989 } else {
6983 dasm_put(Dst, 4058, -LJ_TISNUM, -LJ_TISNUM); 6990 dasm_put(Dst, 4065, -LJ_TISNUM, -LJ_TISNUM);
6984 } 6991 }
6985 dasm_put(Dst, 4063); 6992 dasm_put(Dst, 4070);
6986 break; 6993 break;
6987 case 1: 6994 case 1:
6988 if (vk == 1) { 6995 if (vk == 1) {
6989 dasm_put(Dst, 4066, -LJ_TISNUM, -LJ_TISNUM); 6996 dasm_put(Dst, 4073, -LJ_TISNUM, -LJ_TISNUM);
6990 } else { 6997 } else {
6991 dasm_put(Dst, 4071, -LJ_TISNUM, -LJ_TISNUM); 6998 dasm_put(Dst, 4078, -LJ_TISNUM, -LJ_TISNUM);
6992 } 6999 }
6993 dasm_put(Dst, 4076); 7000 dasm_put(Dst, 4083);
6994 break; 7001 break;
6995 default: 7002 default:
6996 if (vk == 1) { 7003 if (vk == 1) {
6997 dasm_put(Dst, 4079, -LJ_TISNUM, -LJ_TISNUM); 7004 dasm_put(Dst, 4086, -LJ_TISNUM, -LJ_TISNUM);
6998 } else { 7005 } else {
6999 dasm_put(Dst, 4084, -LJ_TISNUM, -LJ_TISNUM); 7006 dasm_put(Dst, 4091, -LJ_TISNUM, -LJ_TISNUM);
7000 } 7007 }
7001 dasm_put(Dst, 4089); 7008 dasm_put(Dst, 4096);
7002 break; 7009 break;
7003 } 7010 }
7004 dasm_put(Dst, 4092); 7011 dasm_put(Dst, 4099);
7005 break; 7012 break;
7006 case BC_POW: 7013 case BC_POW:
7007 dasm_put(Dst, 4097); 7014 dasm_put(Dst, 4104);
7008 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 7015 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
7009 switch (vk) { 7016 switch (vk) {
7010 case 0: 7017 case 0:
7011 dasm_put(Dst, 4100); 7018 dasm_put(Dst, 4107);
7012 break; 7019 break;
7013 case 1: 7020 case 1:
7014 dasm_put(Dst, 4103); 7021 dasm_put(Dst, 4110);
7015 break; 7022 break;
7016 default: 7023 default:
7017 dasm_put(Dst, 4106); 7024 dasm_put(Dst, 4113);
7018 break; 7025 break;
7019 } 7026 }
7020 switch (vk) { 7027 switch (vk) {
7021 case 0: 7028 case 0:
7022 if (vk == 1) { 7029 if (vk == 1) {
7023 dasm_put(Dst, 4109, -LJ_TISNUM, -LJ_TISNUM); 7030 dasm_put(Dst, 4116, -LJ_TISNUM, -LJ_TISNUM);
7024 } else { 7031 } else {
7025 dasm_put(Dst, 4114, -LJ_TISNUM, -LJ_TISNUM); 7032 dasm_put(Dst, 4121, -LJ_TISNUM, -LJ_TISNUM);
7026 } 7033 }
7027 dasm_put(Dst, 4119); 7034 dasm_put(Dst, 4126);
7028 break; 7035 break;
7029 case 1: 7036 case 1:
7030 if (vk == 1) { 7037 if (vk == 1) {
7031 dasm_put(Dst, 4122, -LJ_TISNUM, -LJ_TISNUM); 7038 dasm_put(Dst, 4129, -LJ_TISNUM, -LJ_TISNUM);
7032 } else { 7039 } else {
7033 dasm_put(Dst, 4127, -LJ_TISNUM, -LJ_TISNUM); 7040 dasm_put(Dst, 4134, -LJ_TISNUM, -LJ_TISNUM);
7034 } 7041 }
7035 dasm_put(Dst, 4132); 7042 dasm_put(Dst, 4139);
7036 break; 7043 break;
7037 default: 7044 default:
7038 if (vk == 1) { 7045 if (vk == 1) {
7039 dasm_put(Dst, 4135, -LJ_TISNUM, -LJ_TISNUM); 7046 dasm_put(Dst, 4142, -LJ_TISNUM, -LJ_TISNUM);
7040 } else { 7047 } else {
7041 dasm_put(Dst, 4140, -LJ_TISNUM, -LJ_TISNUM); 7048 dasm_put(Dst, 4147, -LJ_TISNUM, -LJ_TISNUM);
7042 } 7049 }
7043 dasm_put(Dst, 4145); 7050 dasm_put(Dst, 4152);
7044 break; 7051 break;
7045 } 7052 }
7046 if (LJ_TARGET_OSX) { 7053 if (LJ_TARGET_OSX) {
7047 dasm_put(Dst, 4148); 7054 dasm_put(Dst, 4155);
7048 } 7055 }
7049 dasm_put(Dst, 4150); 7056 dasm_put(Dst, 4157);
7050 if (LJ_TARGET_OSX) { 7057 if (LJ_TARGET_OSX) {
7051 dasm_put(Dst, 4153); 7058 dasm_put(Dst, 4160);
7052 } 7059 }
7053 dasm_put(Dst, 4155); 7060 dasm_put(Dst, 4162);
7054 break; 7061 break;
7055 7062
7056 case BC_CAT: 7063 case BC_CAT:
7057 dasm_put(Dst, 4163, Dt1(->base), Dt1(->base)); 7064 dasm_put(Dst, 4170, Dt1(->base), Dt1(->base));
7058 break; 7065 break;
7059 7066
7060 /* -- Constant ops ------------------------------------------------------ */ 7067 /* -- Constant ops ------------------------------------------------------ */
7061 7068
7062 case BC_KSTR: 7069 case BC_KSTR:
7063 dasm_put(Dst, 4189, ~LJ_TSTR); 7070 dasm_put(Dst, 4196, ~LJ_TSTR);
7064 break; 7071 break;
7065 case BC_KCDATA: 7072 case BC_KCDATA:
7066#if LJ_HASFFI 7073#if LJ_HASFFI
7067 dasm_put(Dst, 4201, ~LJ_TCDATA); 7074 dasm_put(Dst, 4208, ~LJ_TCDATA);
7068#endif 7075#endif
7069 break; 7076 break;
7070 case BC_KSHORT: 7077 case BC_KSHORT:
7071 dasm_put(Dst, 4213, ~LJ_TISNUM); 7078 dasm_put(Dst, 4220, ~LJ_TISNUM);
7072 break; 7079 break;
7073 case BC_KNUM: 7080 case BC_KNUM:
7074 dasm_put(Dst, 4224); 7081 dasm_put(Dst, 4231);
7075 break; 7082 break;
7076 case BC_KPRI: 7083 case BC_KPRI:
7077 dasm_put(Dst, 4234); 7084 dasm_put(Dst, 4241);
7078 break; 7085 break;
7079 case BC_KNIL: 7086 case BC_KNIL:
7080 dasm_put(Dst, 4244, ~LJ_TNIL); 7087 dasm_put(Dst, 4251, ~LJ_TNIL);
7081 break; 7088 break;
7082 7089
7083 /* -- Upvalue and function ops ------------------------------------------ */ 7090 /* -- Upvalue and function ops ------------------------------------------ */
7084 7091
7085 case BC_UGET: 7092 case BC_UGET:
7086 dasm_put(Dst, 4263, offsetof(GCfuncL, uvptr), DtA(->v)); 7093 dasm_put(Dst, 4270, offsetof(GCfuncL, uvptr), DtA(->v));
7087 break; 7094 break;
7088 case BC_USETV: 7095 case BC_USETV:
7089 dasm_put(Dst, 4279, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->closed), DtA(->v), LJ_GC_BLACK, -LJ_TISGCV, -(LJ_TISNUM - LJ_TISGCV), Dt4(->gch.marked), -GG_DISP2G, LJ_GC_WHITES); 7096 dasm_put(Dst, 4286, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->closed), DtA(->v), LJ_GC_BLACK, -LJ_TISGCV, -(LJ_TISNUM - LJ_TISGCV), Dt4(->gch.marked), -GG_DISP2G, LJ_GC_WHITES);
7090 if (LJ_TARGET_OSX) { 7097 if (LJ_TARGET_OSX) {
7091 dasm_put(Dst, 4319);
7092 } else {
7093 dasm_put(Dst, 4326); 7098 dasm_put(Dst, 4326);
7099 } else {
7100 dasm_put(Dst, 4333);
7094 } 7101 }
7095 dasm_put(Dst, 4329); 7102 dasm_put(Dst, 4336);
7096 break; 7103 break;
7097 case BC_USETS: 7104 case BC_USETS:
7098 dasm_put(Dst, 4332, offsetof(GCfuncL, uvptr), ~LJ_TSTR, DtA(->marked), DtA(->v), DtA(->closed), LJ_GC_BLACK, Dt5(->marked), LJ_GC_WHITES, -GG_DISP2G); 7105 dasm_put(Dst, 4339, offsetof(GCfuncL, uvptr), ~LJ_TSTR, DtA(->marked), DtA(->v), DtA(->closed), LJ_GC_BLACK, Dt5(->marked), LJ_GC_WHITES, -GG_DISP2G);
7099 if (LJ_TARGET_OSX) { 7106 if (LJ_TARGET_OSX) {
7100 dasm_put(Dst, 4368);
7101 } else {
7102 dasm_put(Dst, 4375); 7107 dasm_put(Dst, 4375);
7108 } else {
7109 dasm_put(Dst, 4382);
7103 } 7110 }
7104 dasm_put(Dst, 4378); 7111 dasm_put(Dst, 4385);
7105 break; 7112 break;
7106 case BC_USETN: 7113 case BC_USETN:
7107 dasm_put(Dst, 4381, offsetof(GCfuncL, uvptr), DtA(->v)); 7114 dasm_put(Dst, 4388, offsetof(GCfuncL, uvptr), DtA(->v));
7108 break; 7115 break;
7109 case BC_USETP: 7116 case BC_USETP:
7110 dasm_put(Dst, 4398, offsetof(GCfuncL, uvptr), DtA(->v)); 7117 dasm_put(Dst, 4405, offsetof(GCfuncL, uvptr), DtA(->v));
7111 break; 7118 break;
7112 7119
7113 case BC_UCLO: 7120 case BC_UCLO:
7114 dasm_put(Dst, 4414, Dt1(->openupval), Dt1(->base), Dt1(->base)); 7121 dasm_put(Dst, 4421, Dt1(->openupval), Dt1(->base), Dt1(->base));
7115 break; 7122 break;
7116 7123
7117 case BC_FNEW: 7124 case BC_FNEW:
7118 dasm_put(Dst, 4437, Dt1(->base), Dt1(->base), ~LJ_TFUNC); 7125 dasm_put(Dst, 4444, Dt1(->base), Dt1(->base), ~LJ_TFUNC);
7119 break; 7126 break;
7120 7127
7121 /* -- Table ops --------------------------------------------------------- */ 7128 /* -- Table ops --------------------------------------------------------- */
@@ -7123,115 +7130,115 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
7123 case BC_TNEW: 7130 case BC_TNEW:
7124 case BC_TDUP: 7131 case BC_TDUP:
7125 if (op == BC_TDUP) { 7132 if (op == BC_TDUP) {
7126 dasm_put(Dst, 4458); 7133 dasm_put(Dst, 4465);
7127 } 7134 }
7128 dasm_put(Dst, 4460, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base)); 7135 dasm_put(Dst, 4467, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base));
7129 if (op == BC_TNEW) { 7136 if (op == BC_TNEW) {
7130 dasm_put(Dst, 4473); 7137 dasm_put(Dst, 4480);
7131 } else { 7138 } else {
7132 dasm_put(Dst, 4482); 7139 dasm_put(Dst, 4489);
7133 } 7140 }
7134 dasm_put(Dst, 4486, Dt1(->base), ~LJ_TTAB); 7141 dasm_put(Dst, 4493, Dt1(->base), ~LJ_TTAB);
7135 break; 7142 break;
7136 7143
7137 case BC_GGET: 7144 case BC_GGET:
7138 case BC_GSET: 7145 case BC_GSET:
7139 dasm_put(Dst, 4504, Dt7(->env)); 7146 dasm_put(Dst, 4511, Dt7(->env));
7140 if (op == BC_GGET) { 7147 if (op == BC_GGET) {
7141 dasm_put(Dst, 4510); 7148 dasm_put(Dst, 4517);
7142 } else { 7149 } else {
7143 dasm_put(Dst, 4513); 7150 dasm_put(Dst, 4520);
7144 } 7151 }
7145 break; 7152 break;
7146 7153
7147 case BC_TGETV: 7154 case BC_TGETV:
7148 dasm_put(Dst, 4516, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index, -LJ_TSTR); 7155 dasm_put(Dst, 4523, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index, -LJ_TSTR);
7149 break; 7156 break;
7150 case BC_TGETS: 7157 case BC_TGETS:
7151 dasm_put(Dst, 4573, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), DtB(->key), DtB(->val), DtB(->next), -LJ_TSTR, -LJ_TNIL, Dt6(->metatable), ~LJ_TNIL, Dt6(->nomm)); 7158 dasm_put(Dst, 4580, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), DtB(->key), DtB(->val), DtB(->next), -LJ_TSTR, -LJ_TNIL, Dt6(->metatable), ~LJ_TNIL, Dt6(->nomm));
7152 dasm_put(Dst, 4633, 1<<MM_index); 7159 dasm_put(Dst, 4640, 1<<MM_index);
7153 break; 7160 break;
7154 case BC_TGETB: 7161 case BC_TGETB:
7155 dasm_put(Dst, 4640, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index); 7162 dasm_put(Dst, 4647, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
7156 break; 7163 break;
7157 7164
7158 case BC_TSETV: 7165 case BC_TSETV:
7159 dasm_put(Dst, 4683, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex); 7166 dasm_put(Dst, 4690, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
7160 dasm_put(Dst, 4743, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), -LJ_TSTR); 7167 dasm_put(Dst, 4750, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), -LJ_TSTR);
7161 break; 7168 break;
7162 case BC_TSETS: 7169 case BC_TSETS:
7163 dasm_put(Dst, 4764, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), DtB(->key), DtB(->val.it), DtB(->next), -LJ_TSTR, Dt6(->marked), -LJ_TNIL, LJ_GC_BLACK, DtB(->val)); 7170 dasm_put(Dst, 4771, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), DtB(->key), DtB(->val.it), DtB(->next), -LJ_TSTR, Dt6(->marked), -LJ_TNIL, LJ_GC_BLACK, DtB(->val));
7164 dasm_put(Dst, 4822, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->metatable), Dt1(->base), Dt6(->nomm), 1<<MM_newindex, ~LJ_TSTR, Dt1(->base), DISPATCH_GL(gc.grayagain), LJ_GC_BLACK); 7171 dasm_put(Dst, 4829, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->metatable), Dt1(->base), Dt6(->nomm), 1<<MM_newindex, ~LJ_TSTR, Dt1(->base), DISPATCH_GL(gc.grayagain), LJ_GC_BLACK);
7165 dasm_put(Dst, 4875, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist)); 7172 dasm_put(Dst, 4882, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
7166 break; 7173 break;
7167 case BC_TSETB: 7174 case BC_TSETB:
7168 dasm_put(Dst, 4884, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK); 7175 dasm_put(Dst, 4891, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK);
7169 dasm_put(Dst, 4942, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist)); 7176 dasm_put(Dst, 4949, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
7170 break; 7177 break;
7171 7178
7172 case BC_TSETM: 7179 case BC_TSETM:
7173 dasm_put(Dst, 4951, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_GC_BLACK, Dt1(->base)); 7180 dasm_put(Dst, 4958, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_GC_BLACK, Dt1(->base));
7174 if (LJ_TARGET_OSX) { 7181 if (LJ_TARGET_OSX) {
7175 dasm_put(Dst, 4996, Dt1(->base)); 7182 dasm_put(Dst, 5003, Dt1(->base));
7176 } 7183 }
7177 dasm_put(Dst, 4999, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist)); 7184 dasm_put(Dst, 5006, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
7178 break; 7185 break;
7179 7186
7180 /* -- Calls and vararg handling ----------------------------------------- */ 7187 /* -- Calls and vararg handling ----------------------------------------- */
7181 7188
7182 case BC_CALLM: 7189 case BC_CALLM:
7183 dasm_put(Dst, 5015); 7190 dasm_put(Dst, 5022);
7184 break; 7191 break;
7185 case BC_CALL: 7192 case BC_CALL:
7186 dasm_put(Dst, 5021, -LJ_TFUNC, Dt7(->field_pc)); 7193 dasm_put(Dst, 5028, -LJ_TFUNC, Dt7(->field_pc));
7187 break; 7194 break;
7188 7195
7189 case BC_CALLMT: 7196 case BC_CALLMT:
7190 dasm_put(Dst, 5041); 7197 dasm_put(Dst, 5048);
7191 break; 7198 break;
7192 case BC_CALLT: 7199 case BC_CALLT:
7193 dasm_put(Dst, 5046, -LJ_TFUNC, Dt7(->ffid), FRAME_TYPE, Dt7(->field_pc), Dt7(->field_pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP); 7200 dasm_put(Dst, 5053, -LJ_TFUNC, Dt7(->ffid), FRAME_TYPE, Dt7(->field_pc), Dt7(->field_pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP);
7194 dasm_put(Dst, 5107, FRAME_TYPE); 7201 dasm_put(Dst, 5114, FRAME_TYPE);
7195 break; 7202 break;
7196 7203
7197 case BC_ITERC: 7204 case BC_ITERC:
7198 dasm_put(Dst, 5118, -LJ_TFUNC, Dt7(->field_pc)); 7205 dasm_put(Dst, 5125, -LJ_TFUNC, Dt7(->field_pc));
7199 break; 7206 break;
7200 7207
7201 case BC_ITERN: 7208 case BC_ITERN:
7202#if LJ_HASJIT 7209#if LJ_HASJIT
7203#endif 7210#endif
7204 dasm_put(Dst, 5142, Dt6(->asize), Dt6(->array), -LJ_TNIL, ~LJ_TISNUM, Dt6(->hmask), Dt6(->node), DtB(->val), -LJ_TNIL, DtB(->key)); 7211 dasm_put(Dst, 5149, Dt6(->asize), Dt6(->array), -LJ_TNIL, ~LJ_TISNUM, Dt6(->hmask), Dt6(->node), DtB(->val), -LJ_TNIL, DtB(->key));
7205 break; 7212 break;
7206 7213
7207 case BC_ISNEXT: 7214 case BC_ISNEXT:
7208 dasm_put(Dst, 5207, -LJ_TFUNC, Dt8(->ffid), -LJ_TTAB, -LJ_TNIL, FF_next_N, BC_JMP, BC_ITERC); 7215 dasm_put(Dst, 5214, -LJ_TFUNC, Dt8(->ffid), -LJ_TTAB, -LJ_TNIL, FF_next_N, BC_JMP, BC_ITERC);
7209 break; 7216 break;
7210 7217
7211 case BC_VARG: 7218 case BC_VARG:
7212 dasm_put(Dst, 5246, FRAME_VARG, ~LJ_TNIL, Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->base)); 7219 dasm_put(Dst, 5253, FRAME_VARG, ~LJ_TNIL, Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->base));
7213 break; 7220 break;
7214 7221
7215 /* -- Returns ----------------------------------------------------------- */ 7222 /* -- Returns ----------------------------------------------------------- */
7216 7223
7217 case BC_RETM: 7224 case BC_RETM:
7218 dasm_put(Dst, 5318); 7225 dasm_put(Dst, 5325);
7219 break; 7226 break;
7220 7227
7221 case BC_RET: 7228 case BC_RET:
7222 dasm_put(Dst, 5325, FRAME_TYPE, FRAME_VARG, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL, FRAME_TYPEP); 7229 dasm_put(Dst, 5332, FRAME_TYPE, FRAME_VARG, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL, FRAME_TYPEP);
7223 break; 7230 break;
7224 7231
7225 case BC_RET0: case BC_RET1: 7232 case BC_RET0: case BC_RET1:
7226 dasm_put(Dst, 5390, FRAME_TYPE, FRAME_VARG); 7233 dasm_put(Dst, 5397, FRAME_TYPE, FRAME_VARG);
7227 if (op == BC_RET1) { 7234 if (op == BC_RET1) {
7228 dasm_put(Dst, 5401); 7235 dasm_put(Dst, 5408);
7229 } 7236 }
7230 dasm_put(Dst, 5403); 7237 dasm_put(Dst, 5410);
7231 if (op == BC_RET1) { 7238 if (op == BC_RET1) {
7232 dasm_put(Dst, 5406); 7239 dasm_put(Dst, 5413);
7233 } 7240 }
7234 dasm_put(Dst, 5408, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL); 7241 dasm_put(Dst, 5415, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL);
7235 break; 7242 break;
7236 7243
7237 /* -- Loops and branches ------------------------------------------------ */ 7244 /* -- Loops and branches ------------------------------------------------ */
@@ -7239,7 +7246,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
7239 7246
7240 case BC_FORL: 7247 case BC_FORL:
7241#if LJ_HASJIT 7248#if LJ_HASJIT
7242 dasm_put(Dst, 5434, -GG_DISP2HOT, HOTCOUNT_LOOP); 7249 dasm_put(Dst, 5441, -GG_DISP2HOT, HOTCOUNT_LOOP);
7243#endif 7250#endif
7244 break; 7251 break;
7245 7252
@@ -7251,68 +7258,68 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
7251 case BC_FORI: 7258 case BC_FORI:
7252 case BC_IFORL: 7259 case BC_IFORL:
7253 vk = (op == BC_IFORL || op == BC_JFORL); 7260 vk = (op == BC_IFORL || op == BC_JFORL);
7254 dasm_put(Dst, 5445); 7261 dasm_put(Dst, 5452);
7255 if (op != BC_JFORL) { 7262 if (op != BC_JFORL) {
7256 dasm_put(Dst, 5447); 7263 dasm_put(Dst, 5454);
7257 } 7264 }
7258 if (!vk) { 7265 if (!vk) {
7259 dasm_put(Dst, 5449, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM); 7266 dasm_put(Dst, 5456, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
7260 } else { 7267 } else {
7261 dasm_put(Dst, 5467, -LJ_TISNUM); 7268 dasm_put(Dst, 5474, -LJ_TISNUM);
7262 if (op == BC_IFORL) { 7269 if (op == BC_IFORL) {
7263 dasm_put(Dst, 5475); 7270 dasm_put(Dst, 5482);
7264 } else { 7271 } else {
7265 dasm_put(Dst, 5477); 7272 dasm_put(Dst, 5484);
7266 } 7273 }
7267 dasm_put(Dst, 5480); 7274 dasm_put(Dst, 5487);
7268 } 7275 }
7269 dasm_put(Dst, 5485); 7276 dasm_put(Dst, 5492);
7270 if (op == BC_FORI) { 7277 if (op == BC_FORI) {
7271 dasm_put(Dst, 5487); 7278 dasm_put(Dst, 5494);
7272 } else if (op == BC_JFORI) { 7279 } else if (op == BC_JFORI) {
7273 dasm_put(Dst, 5489); 7280 dasm_put(Dst, 5496);
7274 } else if (op == BC_IFORL) { 7281 } else if (op == BC_IFORL) {
7275 dasm_put(Dst, 5492); 7282 dasm_put(Dst, 5499);
7276 } 7283 }
7277 if (vk) { 7284 if (vk) {
7278 dasm_put(Dst, 5494); 7285 dasm_put(Dst, 5501);
7279 } 7286 }
7280 dasm_put(Dst, 5496); 7287 dasm_put(Dst, 5503);
7281 if (op == BC_JFORI || op == BC_JFORL) { 7288 if (op == BC_JFORI || op == BC_JFORL) {
7282 dasm_put(Dst, 5501, BC_JLOOP); 7289 dasm_put(Dst, 5508, BC_JLOOP);
7283 } 7290 }
7284 dasm_put(Dst, 5504); 7291 dasm_put(Dst, 5511);
7285 if (!vk) { 7292 if (!vk) {
7286 dasm_put(Dst, 5511); 7293 dasm_put(Dst, 5518);
7287 } else { 7294 } else {
7288 dasm_put(Dst, 5513); 7295 dasm_put(Dst, 5520);
7289 } 7296 }
7290 dasm_put(Dst, 5515); 7297 dasm_put(Dst, 5522);
7291 if (!vk) { 7298 if (!vk) {
7292 dasm_put(Dst, 5519, -LJ_TISNUM, -LJ_TISNUM); 7299 dasm_put(Dst, 5526, -LJ_TISNUM, -LJ_TISNUM);
7293 } else { 7300 } else {
7294 dasm_put(Dst, 5531); 7301 dasm_put(Dst, 5538);
7295 } 7302 }
7296 dasm_put(Dst, 5540); 7303 dasm_put(Dst, 5547);
7297 if (op == BC_FORI) { 7304 if (op == BC_FORI) {
7298 dasm_put(Dst, 5544); 7305 dasm_put(Dst, 5551);
7299 } else if (op == BC_JFORI) { 7306 } else if (op == BC_JFORI) {
7300 dasm_put(Dst, 5546, BC_JLOOP); 7307 dasm_put(Dst, 5553, BC_JLOOP);
7301 } else if (op == BC_IFORL) { 7308 } else if (op == BC_IFORL) {
7302 dasm_put(Dst, 5551); 7309 dasm_put(Dst, 5558);
7303 } else { 7310 } else {
7304 dasm_put(Dst, 5553, BC_JLOOP); 7311 dasm_put(Dst, 5560, BC_JLOOP);
7305 } 7312 }
7306 dasm_put(Dst, 5556); 7313 dasm_put(Dst, 5563);
7307 if (vk) { 7314 if (vk) {
7308 dasm_put(Dst, 5562); 7315 dasm_put(Dst, 5569);
7309 } 7316 }
7310 dasm_put(Dst, 5567); 7317 dasm_put(Dst, 5574);
7311 break; 7318 break;
7312 7319
7313 case BC_ITERL: 7320 case BC_ITERL:
7314#if LJ_HASJIT 7321#if LJ_HASJIT
7315 dasm_put(Dst, 5573, -GG_DISP2HOT, HOTCOUNT_LOOP); 7322 dasm_put(Dst, 5580, -GG_DISP2HOT, HOTCOUNT_LOOP);
7316#endif 7323#endif
7317 break; 7324 break;
7318 7325
@@ -7321,40 +7328,40 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
7321 break; 7328 break;
7322#endif 7329#endif
7323 case BC_IITERL: 7330 case BC_IITERL:
7324 dasm_put(Dst, 5584); 7331 dasm_put(Dst, 5591);
7325 if (op == BC_JITERL) { 7332 if (op == BC_JITERL) {
7326 dasm_put(Dst, 5586, -LJ_TNIL, BC_JLOOP); 7333 dasm_put(Dst, 5593, -LJ_TNIL, BC_JLOOP);
7327 } else { 7334 } else {
7328 dasm_put(Dst, 5592, -LJ_TNIL); 7335 dasm_put(Dst, 5599, -LJ_TNIL);
7329 } 7336 }
7330 dasm_put(Dst, 5598); 7337 dasm_put(Dst, 5605);
7331 break; 7338 break;
7332 7339
7333 case BC_LOOP: 7340 case BC_LOOP:
7334#if LJ_HASJIT 7341#if LJ_HASJIT
7335 dasm_put(Dst, 5605, -GG_DISP2HOT, HOTCOUNT_LOOP); 7342 dasm_put(Dst, 5612, -GG_DISP2HOT, HOTCOUNT_LOOP);
7336#endif 7343#endif
7337 break; 7344 break;
7338 7345
7339 case BC_ILOOP: 7346 case BC_ILOOP:
7340 dasm_put(Dst, 5616); 7347 dasm_put(Dst, 5623);
7341 break; 7348 break;
7342 7349
7343 case BC_JLOOP: 7350 case BC_JLOOP:
7344#if LJ_HASJIT 7351#if LJ_HASJIT
7345 dasm_put(Dst, 5623, DISPATCH_J(trace), DISPATCH_GL(vmstate), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L)); 7352 dasm_put(Dst, 5630, DISPATCH_J(trace), DISPATCH_GL(vmstate), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
7346#endif 7353#endif
7347 break; 7354 break;
7348 7355
7349 case BC_JMP: 7356 case BC_JMP:
7350 dasm_put(Dst, 5637); 7357 dasm_put(Dst, 5644);
7351 break; 7358 break;
7352 7359
7353 /* -- Function headers -------------------------------------------------- */ 7360 /* -- Function headers -------------------------------------------------- */
7354 7361
7355 case BC_FUNCF: 7362 case BC_FUNCF:
7356#if LJ_HASJIT 7363#if LJ_HASJIT
7357 dasm_put(Dst, 5646, -GG_DISP2HOT, HOTCOUNT_CALL); 7364 dasm_put(Dst, 5653, -GG_DISP2HOT, HOTCOUNT_CALL);
7358#endif 7365#endif
7359 case BC_FUNCV: /* NYI: compiled vararg functions. */ 7366 case BC_FUNCV: /* NYI: compiled vararg functions. */
7360 break; 7367 break;
@@ -7364,42 +7371,42 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
7364 break; 7371 break;
7365#endif 7372#endif
7366 case BC_IFUNCF: 7373 case BC_IFUNCF:
7367 dasm_put(Dst, 5657, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k)); 7374 dasm_put(Dst, 5664, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k));
7368 if (op != BC_JFUNCF) { 7375 if (op != BC_JFUNCF) {
7369 dasm_put(Dst, 5667); 7376 dasm_put(Dst, 5674);
7370 } 7377 }
7371 dasm_put(Dst, 5670, ~LJ_TNIL); 7378 dasm_put(Dst, 5677, ~LJ_TNIL);
7372 if (op == BC_JFUNCF) { 7379 if (op == BC_JFUNCF) {
7373 dasm_put(Dst, 5677, BC_JLOOP); 7380 dasm_put(Dst, 5684, BC_JLOOP);
7374 } else { 7381 } else {
7375 dasm_put(Dst, 5681); 7382 dasm_put(Dst, 5688);
7376 } 7383 }
7377 dasm_put(Dst, 5686); 7384 dasm_put(Dst, 5693);
7378 break; 7385 break;
7379 7386
7380 case BC_JFUNCV: 7387 case BC_JFUNCV:
7381#if !LJ_HASJIT 7388#if !LJ_HASJIT
7382 break; 7389 break;
7383#endif 7390#endif
7384 dasm_put(Dst, 5692); 7391 dasm_put(Dst, 5699);
7385 break; /* NYI: compiled vararg functions. */ 7392 break; /* NYI: compiled vararg functions. */
7386 7393
7387 case BC_IFUNCV: 7394 case BC_IFUNCV:
7388 dasm_put(Dst, 5694, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams), ~LJ_TNIL); 7395 dasm_put(Dst, 5701, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams), ~LJ_TNIL);
7389 break; 7396 break;
7390 7397
7391 case BC_FUNCC: 7398 case BC_FUNCC:
7392 case BC_FUNCCW: 7399 case BC_FUNCCW:
7393 if (op == BC_FUNCC) { 7400 if (op == BC_FUNCC) {
7394 dasm_put(Dst, 5735, Dt8(->f)); 7401 dasm_put(Dst, 5742, Dt8(->f));
7395 } else { 7402 } else {
7396 dasm_put(Dst, 5738, DISPATCH_GL(wrapf)); 7403 dasm_put(Dst, 5745, DISPATCH_GL(wrapf));
7397 } 7404 }
7398 dasm_put(Dst, 5741, Dt1(->maxstack), Dt1(->base), Dt1(->top)); 7405 dasm_put(Dst, 5748, Dt1(->maxstack), Dt1(->base), Dt1(->top));
7399 if (op == BC_FUNCCW) { 7406 if (op == BC_FUNCCW) {
7400 dasm_put(Dst, 5751, Dt8(->f)); 7407 dasm_put(Dst, 5758, Dt8(->f));
7401 } 7408 }
7402 dasm_put(Dst, 5754, LJ_VMST_C, DISPATCH_GL(vmstate), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate)); 7409 dasm_put(Dst, 5761, LJ_VMST_C, DISPATCH_GL(vmstate), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate));
7403 break; 7410 break;
7404 7411
7405 /* ---------------------------------------------------------------------- */ 7412 /* ---------------------------------------------------------------------- */
@@ -7419,7 +7426,7 @@ static int build_backend(BuildCtx *ctx)
7419 7426
7420 build_subroutines(ctx); 7427 build_subroutines(ctx);
7421 7428
7422 dasm_put(Dst, 5776); 7429 dasm_put(Dst, 5783);
7423 for (op = 0; op < BC__MAX; op++) 7430 for (op = 0; op < BC__MAX; op++)
7424 build_ins(ctx, (BCOp)op, op); 7431 build_ins(ctx, (BCOp)op, op);
7425 7432