summaryrefslogtreecommitdiff
path: root/src/buildvm_x64win.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/buildvm_x64win.h')
-rw-r--r--src/buildvm_x64win.h647
1 files changed, 323 insertions, 324 deletions
diff --git a/src/buildvm_x64win.h b/src/buildvm_x64win.h
index e4de09ee..2e51c32b 100644
--- a/src/buildvm_x64win.h
+++ b/src/buildvm_x64win.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 char build_actionlist[15785] = { 15static const unsigned char build_actionlist[15787] = {
16 254,1,248,10,252,247,198,237,15,132,244,11,131,230,252,248,41,252,242,72, 16 254,1,248,10,252,247,198,237,15,132,244,11,131,230,252,248,41,252,242,72,
17 141,76,49,252,248,139,114,252,252,199,68,10,4,237,248,12,131,192,1,137,68, 17 141,76,49,252,248,139,114,252,252,199,68,10,4,237,248,12,131,192,1,137,68,
18 36,84,252,247,198,237,15,132,244,13,248,14,129,252,246,239,252,247,198,237, 18 36,84,252,247,198,237,15,132,244,13,248,14,129,252,246,239,252,247,198,237,
@@ -528,46 +528,46 @@ static const unsigned char build_actionlist[15785] = {
528 182,232,131,198,4,193,232,16,252,255,36,252,235,248,7,15,135,244,249,129, 528 182,232,131,198,4,193,232,16,252,255,36,252,235,248,7,15,135,244,249,129,
529 124,253,199,4,239,15,130,244,247,255,252,242,15,42,4,199,255,219,4,199,255, 529 124,253,199,4,239,15,130,244,247,255,252,242,15,42,4,199,255,219,4,199,255,
530 252,233,244,248,248,8,255,252,242,15,42,4,202,102,15,46,4,199,255,219,4,202, 530 252,233,244,248,248,8,255,252,242,15,42,4,202,102,15,46,4,199,255,219,4,202,
531 221,4,194,255,129,252,253,239,15,131,244,249,255,248,1,252,242,15,16,4,199, 531 221,4,199,255,129,252,253,239,15,131,244,249,255,248,1,252,242,15,16,4,199,
532 248,2,102,15,46,4,202,248,4,255,248,1,221,4,199,248,2,221,4,202,255,72,252, 532 248,2,102,15,46,4,202,248,4,255,248,1,221,4,199,248,2,221,4,202,248,4,255,
533 247,208,139,108,202,4,131,198,4,57,197,255,15,133,244,249,15,183,70,252,254, 533 72,252,247,208,139,108,202,4,131,198,4,57,197,255,15,133,244,249,15,183,70,
534 141,180,253,134,233,248,2,139,6,15,182,204,15,182,232,131,198,4,193,232,16, 534 252,254,141,180,253,134,233,248,2,139,6,15,182,204,15,182,232,131,198,4,193,
535 252,255,36,252,235,248,3,129,252,253,239,15,133,244,2,252,233,244,46,255, 535 232,16,252,255,36,252,235,248,3,129,252,253,239,15,133,244,2,252,233,244,
536 15,132,244,248,129,252,253,239,15,132,244,46,15,183,70,252,254,141,180,253, 536 46,255,15,132,244,248,129,252,253,239,15,132,244,46,15,183,70,252,254,141,
537 134,233,248,2,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36, 537 180,253,134,233,248,2,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
538 252,235,255,139,108,194,4,131,198,4,129,252,253,239,255,137,108,202,4,139, 538 255,36,252,235,255,139,108,194,4,131,198,4,129,252,253,239,255,137,108,202,
539 44,194,137,44,202,255,72,139,44,194,72,137,44,202,139,6,15,182,204,15,182, 539 4,139,44,194,137,44,202,255,72,139,44,194,72,137,44,202,139,6,15,182,204,
540 232,131,198,4,193,232,16,252,255,36,252,235,255,49,252,237,129,124,253,194, 540 15,182,232,131,198,4,193,232,16,252,255,36,252,235,255,49,252,237,129,124,
541 4,239,129,213,239,137,108,202,4,139,6,15,182,204,15,182,232,131,198,4,193, 541 253,194,4,239,129,213,239,137,108,202,4,139,6,15,182,204,15,182,232,131,198,
542 232,16,252,255,36,252,235,255,129,124,253,194,4,239,15,133,244,251,139,44, 542 4,193,232,16,252,255,36,252,235,255,129,124,253,194,4,239,15,133,244,251,
543 194,252,247,221,15,128,244,250,199,68,202,4,237,137,44,202,248,9,139,6,15, 543 139,44,194,252,247,221,15,128,244,250,199,68,202,4,237,137,44,202,248,9,139,
544 182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,4,199,68,202, 544 6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,4,199,
545 4,0,0,224,65,199,4,202,0,0,0,0,252,233,244,9,248,5,15,135,244,51,255,129, 545 68,202,4,0,0,224,65,199,4,202,0,0,0,0,252,233,244,9,248,5,15,135,244,51,255,
546 124,253,194,4,239,15,131,244,51,255,252,242,15,16,4,194,72,184,237,237,102, 546 129,124,253,194,4,239,15,131,244,51,255,252,242,15,16,4,194,72,184,237,237,
547 72,15,110,200,15,87,193,252,242,15,17,4,202,255,221,4,194,217,224,221,28, 547 102,72,15,110,200,15,87,193,252,242,15,17,4,202,255,221,4,194,217,224,221,
548 202,255,129,124,253,194,4,239,15,133,244,248,139,4,194,255,139,128,233,248, 548 28,202,255,129,124,253,194,4,239,15,133,244,248,139,4,194,255,139,128,233,
549 1,199,68,202,4,237,137,4,202,255,15,87,192,252,242,15,42,128,233,248,1,252, 549 248,1,199,68,202,4,237,137,4,202,255,15,87,192,252,242,15,42,128,233,248,
550 242,15,17,4,202,255,219,128,233,248,1,221,28,202,255,139,6,15,182,204,15, 550 1,252,242,15,17,4,202,255,219,128,233,248,1,221,28,202,255,139,6,15,182,204,
551 182,232,131,198,4,193,232,16,252,255,36,252,235,248,2,129,124,253,194,4,239, 551 15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,2,129,124,253,194,
552 15,133,244,54,139,12,194,137,213,232,251,1,20,255,252,242,15,42,192,255,137, 552 4,239,15,133,244,54,139,12,194,137,213,232,251,1,20,255,252,242,15,42,192,
553 252,234,15,182,78,252,253,252,233,244,1,255,15,182,252,236,15,182,192,255, 553 255,137,252,234,15,182,78,252,253,252,233,244,1,255,15,182,252,236,15,182,
554 129,124,253,252,234,4,239,15,133,244,48,129,124,253,199,4,239,15,133,244, 554 192,255,129,124,253,252,234,4,239,15,133,244,48,129,124,253,199,4,239,15,
555 48,139,44,252,234,3,44,199,15,128,244,47,255,129,124,253,252,234,4,239,15, 555 133,244,48,139,44,252,234,3,44,199,15,128,244,47,255,129,124,253,252,234,
556 133,244,50,129,124,253,199,4,239,15,133,244,50,139,4,199,3,4,252,234,15,128, 556 4,239,15,133,244,50,129,124,253,199,4,239,15,133,244,50,139,4,199,3,4,252,
557 244,49,255,129,124,253,252,234,4,239,15,133,244,53,129,124,253,194,4,239, 557 234,15,128,244,49,255,129,124,253,252,234,4,239,15,133,244,53,129,124,253,
558 15,133,244,53,139,44,252,234,3,44,194,15,128,244,52,255,199,68,202,4,237, 558 194,4,239,15,133,244,53,139,44,252,234,3,44,194,15,128,244,52,255,199,68,
559 255,129,124,253,252,234,4,239,15,131,244,48,255,129,124,253,199,4,239,15, 559 202,4,237,255,129,124,253,252,234,4,239,15,131,244,48,255,129,124,253,199,
560 131,244,48,255,252,242,15,16,4,252,234,252,242,15,88,4,199,255,221,4,252, 560 4,239,15,131,244,48,255,252,242,15,16,4,252,234,252,242,15,88,4,199,255,221,
561 234,220,4,199,255,129,124,253,252,234,4,239,15,131,244,50,255,129,124,253, 561 4,252,234,220,4,199,255,129,124,253,252,234,4,239,15,131,244,50,255,129,124,
562 199,4,239,15,131,244,50,255,252,242,15,16,4,199,252,242,15,88,4,252,234,255, 562 253,199,4,239,15,131,244,50,255,252,242,15,16,4,199,252,242,15,88,4,252,234,
563 221,4,199,220,4,252,234,255,129,124,253,252,234,4,239,15,131,244,53,129,124, 563 255,221,4,199,220,4,252,234,255,129,124,253,252,234,4,239,15,131,244,53,129,
564 253,194,4,239,15,131,244,53,255,252,242,15,16,4,252,234,252,242,15,88,4,194, 564 124,253,194,4,239,15,131,244,53,255,252,242,15,16,4,252,234,252,242,15,88,
565 255,221,4,252,234,220,4,194,255,129,124,253,252,234,4,239,15,133,244,48,129, 565 4,194,255,221,4,252,234,220,4,194,255,129,124,253,252,234,4,239,15,133,244,
566 124,253,199,4,239,15,133,244,48,139,44,252,234,43,44,199,15,128,244,47,255, 566 48,129,124,253,199,4,239,15,133,244,48,139,44,252,234,43,44,199,15,128,244,
567 129,124,253,252,234,4,239,15,133,244,50,129,124,253,199,4,239,15,133,244, 567 47,255,129,124,253,252,234,4,239,15,133,244,50,129,124,253,199,4,239,15,133,
568 50,139,4,199,43,4,252,234,15,128,244,49,255,129,124,253,252,234,4,239,15, 568 244,50,139,4,199,43,4,252,234,15,128,244,49,255,129,124,253,252,234,4,239,
569 133,244,53,129,124,253,194,4,239,15,133,244,53,139,44,252,234,43,44,194,15, 569 15,133,244,53,129,124,253,194,4,239,15,133,244,53,139,44,252,234,43,44,194,
570 128,244,52,255,252,242,15,16,4,252,234,252,242,15,92,4,199,255,221,4,252, 570 15,128,244,52,255,252,242,15,16,4,252,234,252,242,15,92,4,199,255,221,4,252,
571 234,220,36,199,255,252,242,15,16,4,199,252,242,15,92,4,252,234,255,221,4, 571 234,220,36,199,255,252,242,15,16,4,199,252,242,15,92,4,252,234,255,221,4,
572 199,220,36,252,234,255,252,242,15,16,4,252,234,252,242,15,92,4,194,255,221, 572 199,220,36,252,234,255,252,242,15,16,4,252,234,252,242,15,92,4,194,255,221,
573 4,252,234,220,36,194,255,129,124,253,252,234,4,239,15,133,244,48,129,124, 573 4,252,234,220,36,194,255,129,124,253,252,234,4,239,15,133,244,48,129,124,
@@ -2055,31 +2055,30 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2055 } else { 2055 } else {
2056 dasm_put(Dst, 10063); 2056 dasm_put(Dst, 10063);
2057 } 2057 }
2058 dasm_put(Dst, 4586);
2059 } 2058 }
2060 goto iseqne_fp; 2059 goto iseqne_fp;
2061 case BC_ISEQP: case BC_ISNEP: 2060 case BC_ISEQP: case BC_ISNEP:
2062 vk = op == BC_ISEQP; 2061 vk = op == BC_ISEQP;
2063 dasm_put(Dst, 10655); 2062 dasm_put(Dst, 10657);
2064 if (!LJ_HASFFI) goto iseqne_test; 2063 if (!LJ_HASFFI) goto iseqne_test;
2065 if (vk) { 2064 if (vk) {
2066 dasm_put(Dst, 10669, -BCBIAS_J*4, LJ_TCDATA); 2065 dasm_put(Dst, 10671, -BCBIAS_J*4, LJ_TCDATA);
2067 } else { 2066 } else {
2068 dasm_put(Dst, 10719, LJ_TCDATA, -BCBIAS_J*4); 2067 dasm_put(Dst, 10721, LJ_TCDATA, -BCBIAS_J*4);
2069 } 2068 }
2070 break; 2069 break;
2071 2070
2072 /* -- Unary test and copy ops ------------------------------------------- */ 2071 /* -- Unary test and copy ops ------------------------------------------- */
2073 2072
2074 case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF: 2073 case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
2075 dasm_put(Dst, 10763, LJ_TISTRUECOND); 2074 dasm_put(Dst, 10765, LJ_TISTRUECOND);
2076 if (op == BC_IST || op == BC_ISTC) { 2075 if (op == BC_IST || op == BC_ISTC) {
2077 dasm_put(Dst, 10085); 2076 dasm_put(Dst, 10085);
2078 } else { 2077 } else {
2079 dasm_put(Dst, 10080); 2078 dasm_put(Dst, 10080);
2080 } 2079 }
2081 if (op == BC_ISTC || op == BC_ISFC) { 2080 if (op == BC_ISTC || op == BC_ISFC) {
2082 dasm_put(Dst, 10775); 2081 dasm_put(Dst, 10777);
2083 } 2082 }
2084 dasm_put(Dst, 10090, -BCBIAS_J*4); 2083 dasm_put(Dst, 10090, -BCBIAS_J*4);
2085 break; 2084 break;
@@ -2087,21 +2086,21 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2087 /* -- Unary ops --------------------------------------------------------- */ 2086 /* -- Unary ops --------------------------------------------------------- */
2088 2087
2089 case BC_MOV: 2088 case BC_MOV:
2090 dasm_put(Dst, 10786); 2089 dasm_put(Dst, 10788);
2091 break; 2090 break;
2092 case BC_NOT: 2091 case BC_NOT:
2093 dasm_put(Dst, 10814, LJ_TISTRUECOND, LJ_TTRUE); 2092 dasm_put(Dst, 10816, LJ_TISTRUECOND, LJ_TTRUE);
2094 break; 2093 break;
2095 case BC_UNM: 2094 case BC_UNM:
2096 if (LJ_DUALNUM) { 2095 if (LJ_DUALNUM) {
2097 dasm_put(Dst, 10850, LJ_TISNUM, LJ_TISNUM); 2096 dasm_put(Dst, 10852, LJ_TISNUM, LJ_TISNUM);
2098 } else { 2097 } else {
2099 dasm_put(Dst, 10927, LJ_TISNUM); 2098 dasm_put(Dst, 10929, LJ_TISNUM);
2100 } 2099 }
2101 if (sse) { 2100 if (sse) {
2102 dasm_put(Dst, 10938, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32)); 2101 dasm_put(Dst, 10940, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
2103 } else { 2102 } else {
2104 dasm_put(Dst, 10963); 2103 dasm_put(Dst, 10965);
2105 } 2104 }
2106 if (LJ_DUALNUM) { 2105 if (LJ_DUALNUM) {
2107 dasm_put(Dst, 10361); 2106 dasm_put(Dst, 10361);
@@ -2110,21 +2109,21 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2110 } 2109 }
2111 break; 2110 break;
2112 case BC_LEN: 2111 case BC_LEN:
2113 dasm_put(Dst, 10972, LJ_TSTR); 2112 dasm_put(Dst, 10974, LJ_TSTR);
2114 if (LJ_DUALNUM) { 2113 if (LJ_DUALNUM) {
2115 dasm_put(Dst, 10986, Dt5(->len), LJ_TISNUM); 2114 dasm_put(Dst, 10988, Dt5(->len), LJ_TISNUM);
2116 } else if (sse) { 2115 } else if (sse) {
2117 dasm_put(Dst, 11000, Dt5(->len)); 2116 dasm_put(Dst, 11002, Dt5(->len));
2118 } else { 2117 } else {
2119 dasm_put(Dst, 11018, Dt5(->len)); 2118 dasm_put(Dst, 11020, Dt5(->len));
2120 } 2119 }
2121 dasm_put(Dst, 11027, LJ_TTAB); 2120 dasm_put(Dst, 11029, LJ_TTAB);
2122 if (LJ_DUALNUM) { 2121 if (LJ_DUALNUM) {
2123 } else if (sse) { 2122 } else if (sse) {
2124 dasm_put(Dst, 11068); 2123 dasm_put(Dst, 11070);
2125 } else { 2124 } else {
2126 } 2125 }
2127 dasm_put(Dst, 11074); 2126 dasm_put(Dst, 11076);
2128 break; 2127 break;
2129 2128
2130 /* -- Binary ops -------------------------------------------------------- */ 2129 /* -- Binary ops -------------------------------------------------------- */
@@ -2132,603 +2131,603 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2132 2131
2133 case BC_ADDVN: case BC_ADDNV: case BC_ADDVV: 2132 case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
2134 if (LJ_DUALNUM) { 2133 if (LJ_DUALNUM) {
2135 dasm_put(Dst, 11087); 2134 dasm_put(Dst, 11089);
2136 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2135 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2137 switch (vk) { 2136 switch (vk) {
2138 case 0: 2137 case 0:
2139 dasm_put(Dst, 11095, LJ_TISNUM, LJ_TISNUM); 2138 dasm_put(Dst, 11097, LJ_TISNUM, LJ_TISNUM);
2140 break; 2139 break;
2141 case 1: 2140 case 1:
2142 dasm_put(Dst, 11128, LJ_TISNUM, LJ_TISNUM); 2141 dasm_put(Dst, 11130, LJ_TISNUM, LJ_TISNUM);
2143 break; 2142 break;
2144 default: 2143 default:
2145 dasm_put(Dst, 11161, LJ_TISNUM, LJ_TISNUM); 2144 dasm_put(Dst, 11163, LJ_TISNUM, LJ_TISNUM);
2146 break; 2145 break;
2147 } 2146 }
2148 dasm_put(Dst, 11194, LJ_TISNUM); 2147 dasm_put(Dst, 11196, LJ_TISNUM);
2149 if (vk == 1) { 2148 if (vk == 1) {
2150 dasm_put(Dst, 10996); 2149 dasm_put(Dst, 10998);
2151 } else { 2150 } else {
2152 dasm_put(Dst, 10782); 2151 dasm_put(Dst, 10784);
2153 } 2152 }
2154 dasm_put(Dst, 10102); 2153 dasm_put(Dst, 10102);
2155 } else { 2154 } else {
2156 dasm_put(Dst, 11087); 2155 dasm_put(Dst, 11089);
2157 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2156 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2158 switch (vk) { 2157 switch (vk) {
2159 case 0: 2158 case 0:
2160 dasm_put(Dst, 11200, LJ_TISNUM); 2159 dasm_put(Dst, 11202, LJ_TISNUM);
2161 if (LJ_DUALNUM) { 2160 if (LJ_DUALNUM) {
2162 dasm_put(Dst, 11212, LJ_TISNUM); 2161 dasm_put(Dst, 11214, LJ_TISNUM);
2163 } 2162 }
2164 if (sse) { 2163 if (sse) {
2165 dasm_put(Dst, 11223); 2164 dasm_put(Dst, 11225);
2166 } else { 2165 } else {
2167 dasm_put(Dst, 11237); 2166 dasm_put(Dst, 11239);
2168 } 2167 }
2169 break; 2168 break;
2170 case 1: 2169 case 1:
2171 dasm_put(Dst, 11245, LJ_TISNUM); 2170 dasm_put(Dst, 11247, LJ_TISNUM);
2172 if (LJ_DUALNUM) { 2171 if (LJ_DUALNUM) {
2173 dasm_put(Dst, 11257, LJ_TISNUM); 2172 dasm_put(Dst, 11259, LJ_TISNUM);
2174 } 2173 }
2175 if (sse) { 2174 if (sse) {
2176 dasm_put(Dst, 11268); 2175 dasm_put(Dst, 11270);
2177 } else { 2176 } else {
2178 dasm_put(Dst, 11282); 2177 dasm_put(Dst, 11284);
2179 } 2178 }
2180 break; 2179 break;
2181 default: 2180 default:
2182 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2181 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2183 if (sse) { 2182 if (sse) {
2184 dasm_put(Dst, 11312); 2183 dasm_put(Dst, 11314);
2185 } else { 2184 } else {
2186 dasm_put(Dst, 11326); 2185 dasm_put(Dst, 11328);
2187 } 2186 }
2188 break; 2187 break;
2189 } 2188 }
2190 if (sse) { 2189 if (sse) {
2191 dasm_put(Dst, 10956); 2190 dasm_put(Dst, 10958);
2192 } else { 2191 } else {
2193 dasm_put(Dst, 10968); 2192 dasm_put(Dst, 10970);
2194 } 2193 }
2195 dasm_put(Dst, 10102); 2194 dasm_put(Dst, 10102);
2196 } 2195 }
2197 break; 2196 break;
2198 case BC_SUBVN: case BC_SUBNV: case BC_SUBVV: 2197 case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
2199 if (LJ_DUALNUM) { 2198 if (LJ_DUALNUM) {
2200 dasm_put(Dst, 11087); 2199 dasm_put(Dst, 11089);
2201 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2200 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2202 switch (vk) { 2201 switch (vk) {
2203 case 0: 2202 case 0:
2204 dasm_put(Dst, 11334, LJ_TISNUM, LJ_TISNUM); 2203 dasm_put(Dst, 11336, LJ_TISNUM, LJ_TISNUM);
2205 break; 2204 break;
2206 case 1: 2205 case 1:
2207 dasm_put(Dst, 11367, LJ_TISNUM, LJ_TISNUM); 2206 dasm_put(Dst, 11369, LJ_TISNUM, LJ_TISNUM);
2208 break; 2207 break;
2209 default: 2208 default:
2210 dasm_put(Dst, 11400, LJ_TISNUM, LJ_TISNUM); 2209 dasm_put(Dst, 11402, LJ_TISNUM, LJ_TISNUM);
2211 break; 2210 break;
2212 } 2211 }
2213 dasm_put(Dst, 11194, LJ_TISNUM); 2212 dasm_put(Dst, 11196, LJ_TISNUM);
2214 if (vk == 1) { 2213 if (vk == 1) {
2215 dasm_put(Dst, 10996); 2214 dasm_put(Dst, 10998);
2216 } else { 2215 } else {
2217 dasm_put(Dst, 10782); 2216 dasm_put(Dst, 10784);
2218 } 2217 }
2219 dasm_put(Dst, 10102); 2218 dasm_put(Dst, 10102);
2220 } else { 2219 } else {
2221 dasm_put(Dst, 11087); 2220 dasm_put(Dst, 11089);
2222 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2221 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2223 switch (vk) { 2222 switch (vk) {
2224 case 0: 2223 case 0:
2225 dasm_put(Dst, 11200, LJ_TISNUM); 2224 dasm_put(Dst, 11202, LJ_TISNUM);
2226 if (LJ_DUALNUM) { 2225 if (LJ_DUALNUM) {
2227 dasm_put(Dst, 11212, LJ_TISNUM); 2226 dasm_put(Dst, 11214, LJ_TISNUM);
2228 } 2227 }
2229 if (sse) { 2228 if (sse) {
2230 dasm_put(Dst, 11433); 2229 dasm_put(Dst, 11435);
2231 } else { 2230 } else {
2232 dasm_put(Dst, 11447); 2231 dasm_put(Dst, 11449);
2233 } 2232 }
2234 break; 2233 break;
2235 case 1: 2234 case 1:
2236 dasm_put(Dst, 11245, LJ_TISNUM); 2235 dasm_put(Dst, 11247, LJ_TISNUM);
2237 if (LJ_DUALNUM) { 2236 if (LJ_DUALNUM) {
2238 dasm_put(Dst, 11257, LJ_TISNUM); 2237 dasm_put(Dst, 11259, LJ_TISNUM);
2239 } 2238 }
2240 if (sse) { 2239 if (sse) {
2241 dasm_put(Dst, 11455); 2240 dasm_put(Dst, 11457);
2242 } else { 2241 } else {
2243 dasm_put(Dst, 11469); 2242 dasm_put(Dst, 11471);
2244 } 2243 }
2245 break; 2244 break;
2246 default: 2245 default:
2247 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2246 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2248 if (sse) { 2247 if (sse) {
2249 dasm_put(Dst, 11477); 2248 dasm_put(Dst, 11479);
2250 } else { 2249 } else {
2251 dasm_put(Dst, 11491); 2250 dasm_put(Dst, 11493);
2252 } 2251 }
2253 break; 2252 break;
2254 } 2253 }
2255 if (sse) { 2254 if (sse) {
2256 dasm_put(Dst, 10956); 2255 dasm_put(Dst, 10958);
2257 } else { 2256 } else {
2258 dasm_put(Dst, 10968); 2257 dasm_put(Dst, 10970);
2259 } 2258 }
2260 dasm_put(Dst, 10102); 2259 dasm_put(Dst, 10102);
2261 } 2260 }
2262 break; 2261 break;
2263 case BC_MULVN: case BC_MULNV: case BC_MULVV: 2262 case BC_MULVN: case BC_MULNV: case BC_MULVV:
2264 if (LJ_DUALNUM) { 2263 if (LJ_DUALNUM) {
2265 dasm_put(Dst, 11087); 2264 dasm_put(Dst, 11089);
2266 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2265 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2267 switch (vk) { 2266 switch (vk) {
2268 case 0: 2267 case 0:
2269 dasm_put(Dst, 11499, LJ_TISNUM, LJ_TISNUM); 2268 dasm_put(Dst, 11501, LJ_TISNUM, LJ_TISNUM);
2270 break; 2269 break;
2271 case 1: 2270 case 1:
2272 dasm_put(Dst, 11533, LJ_TISNUM, LJ_TISNUM); 2271 dasm_put(Dst, 11535, LJ_TISNUM, LJ_TISNUM);
2273 break; 2272 break;
2274 default: 2273 default:
2275 dasm_put(Dst, 11567, LJ_TISNUM, LJ_TISNUM); 2274 dasm_put(Dst, 11569, LJ_TISNUM, LJ_TISNUM);
2276 break; 2275 break;
2277 } 2276 }
2278 dasm_put(Dst, 11194, LJ_TISNUM); 2277 dasm_put(Dst, 11196, LJ_TISNUM);
2279 if (vk == 1) { 2278 if (vk == 1) {
2280 dasm_put(Dst, 10996); 2279 dasm_put(Dst, 10998);
2281 } else { 2280 } else {
2282 dasm_put(Dst, 10782); 2281 dasm_put(Dst, 10784);
2283 } 2282 }
2284 dasm_put(Dst, 10102); 2283 dasm_put(Dst, 10102);
2285 } else { 2284 } else {
2286 dasm_put(Dst, 11087); 2285 dasm_put(Dst, 11089);
2287 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2286 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2288 switch (vk) { 2287 switch (vk) {
2289 case 0: 2288 case 0:
2290 dasm_put(Dst, 11200, LJ_TISNUM); 2289 dasm_put(Dst, 11202, LJ_TISNUM);
2291 if (LJ_DUALNUM) { 2290 if (LJ_DUALNUM) {
2292 dasm_put(Dst, 11212, LJ_TISNUM); 2291 dasm_put(Dst, 11214, LJ_TISNUM);
2293 } 2292 }
2294 if (sse) { 2293 if (sse) {
2295 dasm_put(Dst, 11601); 2294 dasm_put(Dst, 11603);
2296 } else { 2295 } else {
2297 dasm_put(Dst, 11615); 2296 dasm_put(Dst, 11617);
2298 } 2297 }
2299 break; 2298 break;
2300 case 1: 2299 case 1:
2301 dasm_put(Dst, 11245, LJ_TISNUM); 2300 dasm_put(Dst, 11247, LJ_TISNUM);
2302 if (LJ_DUALNUM) { 2301 if (LJ_DUALNUM) {
2303 dasm_put(Dst, 11257, LJ_TISNUM); 2302 dasm_put(Dst, 11259, LJ_TISNUM);
2304 } 2303 }
2305 if (sse) { 2304 if (sse) {
2306 dasm_put(Dst, 11623); 2305 dasm_put(Dst, 11625);
2307 } else { 2306 } else {
2308 dasm_put(Dst, 11637); 2307 dasm_put(Dst, 11639);
2309 } 2308 }
2310 break; 2309 break;
2311 default: 2310 default:
2312 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2311 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2313 if (sse) { 2312 if (sse) {
2314 dasm_put(Dst, 11645); 2313 dasm_put(Dst, 11647);
2315 } else { 2314 } else {
2316 dasm_put(Dst, 11659); 2315 dasm_put(Dst, 11661);
2317 } 2316 }
2318 break; 2317 break;
2319 } 2318 }
2320 if (sse) { 2319 if (sse) {
2321 dasm_put(Dst, 10956); 2320 dasm_put(Dst, 10958);
2322 } else { 2321 } else {
2323 dasm_put(Dst, 10968); 2322 dasm_put(Dst, 10970);
2324 } 2323 }
2325 dasm_put(Dst, 10102); 2324 dasm_put(Dst, 10102);
2326 } 2325 }
2327 break; 2326 break;
2328 case BC_DIVVN: case BC_DIVNV: case BC_DIVVV: 2327 case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
2329 dasm_put(Dst, 11087); 2328 dasm_put(Dst, 11089);
2330 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2329 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2331 switch (vk) { 2330 switch (vk) {
2332 case 0: 2331 case 0:
2333 dasm_put(Dst, 11200, LJ_TISNUM); 2332 dasm_put(Dst, 11202, LJ_TISNUM);
2334 if (LJ_DUALNUM) { 2333 if (LJ_DUALNUM) {
2335 dasm_put(Dst, 11212, LJ_TISNUM); 2334 dasm_put(Dst, 11214, LJ_TISNUM);
2336 } 2335 }
2337 if (sse) { 2336 if (sse) {
2338 dasm_put(Dst, 11667); 2337 dasm_put(Dst, 11669);
2339 } else { 2338 } else {
2340 dasm_put(Dst, 11681); 2339 dasm_put(Dst, 11683);
2341 } 2340 }
2342 break; 2341 break;
2343 case 1: 2342 case 1:
2344 dasm_put(Dst, 11245, LJ_TISNUM); 2343 dasm_put(Dst, 11247, LJ_TISNUM);
2345 if (LJ_DUALNUM) { 2344 if (LJ_DUALNUM) {
2346 dasm_put(Dst, 11257, LJ_TISNUM); 2345 dasm_put(Dst, 11259, LJ_TISNUM);
2347 } 2346 }
2348 if (sse) { 2347 if (sse) {
2349 dasm_put(Dst, 11689); 2348 dasm_put(Dst, 11691);
2350 } else { 2349 } else {
2351 dasm_put(Dst, 11703); 2350 dasm_put(Dst, 11705);
2352 } 2351 }
2353 break; 2352 break;
2354 default: 2353 default:
2355 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2354 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2356 if (sse) { 2355 if (sse) {
2357 dasm_put(Dst, 11711); 2356 dasm_put(Dst, 11713);
2358 } else { 2357 } else {
2359 dasm_put(Dst, 11725); 2358 dasm_put(Dst, 11727);
2360 } 2359 }
2361 break; 2360 break;
2362 } 2361 }
2363 if (sse) { 2362 if (sse) {
2364 dasm_put(Dst, 10956); 2363 dasm_put(Dst, 10958);
2365 } else { 2364 } else {
2366 dasm_put(Dst, 10968); 2365 dasm_put(Dst, 10970);
2367 } 2366 }
2368 dasm_put(Dst, 10102); 2367 dasm_put(Dst, 10102);
2369 break; 2368 break;
2370 case BC_MODVN: 2369 case BC_MODVN:
2371 dasm_put(Dst, 11087); 2370 dasm_put(Dst, 11089);
2372 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2371 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2373 switch (vk) { 2372 switch (vk) {
2374 case 0: 2373 case 0:
2375 dasm_put(Dst, 11200, LJ_TISNUM); 2374 dasm_put(Dst, 11202, LJ_TISNUM);
2376 if (LJ_DUALNUM) { 2375 if (LJ_DUALNUM) {
2377 dasm_put(Dst, 11212, LJ_TISNUM); 2376 dasm_put(Dst, 11214, LJ_TISNUM);
2378 } 2377 }
2379 if (sse) { 2378 if (sse) {
2380 dasm_put(Dst, 11733); 2379 dasm_put(Dst, 11735);
2381 } else { 2380 } else {
2382 dasm_put(Dst, 11747); 2381 dasm_put(Dst, 11749);
2383 } 2382 }
2384 break; 2383 break;
2385 case 1: 2384 case 1:
2386 dasm_put(Dst, 11245, LJ_TISNUM); 2385 dasm_put(Dst, 11247, LJ_TISNUM);
2387 if (LJ_DUALNUM) { 2386 if (LJ_DUALNUM) {
2388 dasm_put(Dst, 11257, LJ_TISNUM); 2387 dasm_put(Dst, 11259, LJ_TISNUM);
2389 } 2388 }
2390 if (sse) { 2389 if (sse) {
2391 dasm_put(Dst, 11755); 2390 dasm_put(Dst, 11757);
2392 } else { 2391 } else {
2393 dasm_put(Dst, 11769); 2392 dasm_put(Dst, 11771);
2394 } 2393 }
2395 break; 2394 break;
2396 default: 2395 default:
2397 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2396 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2398 if (sse) { 2397 if (sse) {
2399 dasm_put(Dst, 11777); 2398 dasm_put(Dst, 11779);
2400 } else { 2399 } else {
2401 dasm_put(Dst, 11791); 2400 dasm_put(Dst, 11793);
2402 } 2401 }
2403 break; 2402 break;
2404 } 2403 }
2405 dasm_put(Dst, 11799); 2404 dasm_put(Dst, 11801);
2406 if (sse) { 2405 if (sse) {
2407 dasm_put(Dst, 10956); 2406 dasm_put(Dst, 10958);
2408 } else { 2407 } else {
2409 dasm_put(Dst, 10968); 2408 dasm_put(Dst, 10970);
2410 } 2409 }
2411 dasm_put(Dst, 10102); 2410 dasm_put(Dst, 10102);
2412 break; 2411 break;
2413 case BC_MODNV: case BC_MODVV: 2412 case BC_MODNV: case BC_MODVV:
2414 dasm_put(Dst, 11087); 2413 dasm_put(Dst, 11089);
2415 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2414 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2416 switch (vk) { 2415 switch (vk) {
2417 case 0: 2416 case 0:
2418 dasm_put(Dst, 11200, LJ_TISNUM); 2417 dasm_put(Dst, 11202, LJ_TISNUM);
2419 if (LJ_DUALNUM) { 2418 if (LJ_DUALNUM) {
2420 dasm_put(Dst, 11212, LJ_TISNUM); 2419 dasm_put(Dst, 11214, LJ_TISNUM);
2421 } 2420 }
2422 if (sse) { 2421 if (sse) {
2423 dasm_put(Dst, 11733); 2422 dasm_put(Dst, 11735);
2424 } else { 2423 } else {
2425 dasm_put(Dst, 11747); 2424 dasm_put(Dst, 11749);
2426 } 2425 }
2427 break; 2426 break;
2428 case 1: 2427 case 1:
2429 dasm_put(Dst, 11245, LJ_TISNUM); 2428 dasm_put(Dst, 11247, LJ_TISNUM);
2430 if (LJ_DUALNUM) { 2429 if (LJ_DUALNUM) {
2431 dasm_put(Dst, 11257, LJ_TISNUM); 2430 dasm_put(Dst, 11259, LJ_TISNUM);
2432 } 2431 }
2433 if (sse) { 2432 if (sse) {
2434 dasm_put(Dst, 11755); 2433 dasm_put(Dst, 11757);
2435 } else { 2434 } else {
2436 dasm_put(Dst, 11769); 2435 dasm_put(Dst, 11771);
2437 } 2436 }
2438 break; 2437 break;
2439 default: 2438 default:
2440 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2439 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2441 if (sse) { 2440 if (sse) {
2442 dasm_put(Dst, 11777); 2441 dasm_put(Dst, 11779);
2443 } else { 2442 } else {
2444 dasm_put(Dst, 11791); 2443 dasm_put(Dst, 11793);
2445 } 2444 }
2446 break; 2445 break;
2447 } 2446 }
2448 dasm_put(Dst, 11805); 2447 dasm_put(Dst, 11807);
2449 break; 2448 break;
2450 case BC_POW: 2449 case BC_POW:
2451 dasm_put(Dst, 11087); 2450 dasm_put(Dst, 11089);
2452 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN); 2451 vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
2453 switch (vk) { 2452 switch (vk) {
2454 case 0: 2453 case 0:
2455 dasm_put(Dst, 11200, LJ_TISNUM); 2454 dasm_put(Dst, 11202, LJ_TISNUM);
2456 if (LJ_DUALNUM) { 2455 if (LJ_DUALNUM) {
2457 dasm_put(Dst, 11212, LJ_TISNUM); 2456 dasm_put(Dst, 11214, LJ_TISNUM);
2458 } 2457 }
2459 if (sse) { 2458 if (sse) {
2460 dasm_put(Dst, 11733); 2459 dasm_put(Dst, 11735);
2461 } else { 2460 } else {
2462 dasm_put(Dst, 11747); 2461 dasm_put(Dst, 11749);
2463 } 2462 }
2464 break; 2463 break;
2465 case 1: 2464 case 1:
2466 dasm_put(Dst, 11245, LJ_TISNUM); 2465 dasm_put(Dst, 11247, LJ_TISNUM);
2467 if (LJ_DUALNUM) { 2466 if (LJ_DUALNUM) {
2468 dasm_put(Dst, 11257, LJ_TISNUM); 2467 dasm_put(Dst, 11259, LJ_TISNUM);
2469 } 2468 }
2470 if (sse) { 2469 if (sse) {
2471 dasm_put(Dst, 11755); 2470 dasm_put(Dst, 11757);
2472 } else { 2471 } else {
2473 dasm_put(Dst, 11769); 2472 dasm_put(Dst, 11771);
2474 } 2473 }
2475 break; 2474 break;
2476 default: 2475 default:
2477 dasm_put(Dst, 11290, LJ_TISNUM, LJ_TISNUM); 2476 dasm_put(Dst, 11292, LJ_TISNUM, LJ_TISNUM);
2478 if (sse) { 2477 if (sse) {
2479 dasm_put(Dst, 11777); 2478 dasm_put(Dst, 11779);
2480 } else { 2479 } else {
2481 dasm_put(Dst, 11791); 2480 dasm_put(Dst, 11793);
2482 } 2481 }
2483 break; 2482 break;
2484 } 2483 }
2485 dasm_put(Dst, 11810); 2484 dasm_put(Dst, 11812);
2486 if (sse) { 2485 if (sse) {
2487 dasm_put(Dst, 10956); 2486 dasm_put(Dst, 10958);
2488 } else { 2487 } else {
2489 dasm_put(Dst, 10968); 2488 dasm_put(Dst, 10970);
2490 } 2489 }
2491 dasm_put(Dst, 10102); 2490 dasm_put(Dst, 10102);
2492 break; 2491 break;
2493 2492
2494 case BC_CAT: 2493 case BC_CAT:
2495 dasm_put(Dst, 11814, Dt1(->base), Dt1(->base)); 2494 dasm_put(Dst, 11816, Dt1(->base), Dt1(->base));
2496 break; 2495 break;
2497 2496
2498 /* -- Constant ops ------------------------------------------------------ */ 2497 /* -- Constant ops ------------------------------------------------------ */
2499 2498
2500 case BC_KSTR: 2499 case BC_KSTR:
2501 dasm_put(Dst, 11897, LJ_TSTR); 2500 dasm_put(Dst, 11899, LJ_TSTR);
2502 break; 2501 break;
2503 case BC_KCDATA: 2502 case BC_KCDATA:
2504#if LJ_HASFFI 2503#if LJ_HASFFI
2505 dasm_put(Dst, 11897, LJ_TCDATA); 2504 dasm_put(Dst, 11899, LJ_TCDATA);
2506#endif 2505#endif
2507 break; 2506 break;
2508 case BC_KSHORT: 2507 case BC_KSHORT:
2509 if (LJ_DUALNUM) { 2508 if (LJ_DUALNUM) {
2510 dasm_put(Dst, 11932, LJ_TISNUM); 2509 dasm_put(Dst, 11934, LJ_TISNUM);
2511 } else if (sse) { 2510 } else if (sse) {
2512 dasm_put(Dst, 11944); 2511 dasm_put(Dst, 11946);
2513 } else { 2512 } else {
2514 dasm_put(Dst, 11959); 2513 dasm_put(Dst, 11961);
2515 } 2514 }
2516 dasm_put(Dst, 10102); 2515 dasm_put(Dst, 10102);
2517 break; 2516 break;
2518 case BC_KNUM: 2517 case BC_KNUM:
2519 if (sse) { 2518 if (sse) {
2520 dasm_put(Dst, 11967); 2519 dasm_put(Dst, 11969);
2521 } else { 2520 } else {
2522 dasm_put(Dst, 11980); 2521 dasm_put(Dst, 11982);
2523 } 2522 }
2524 dasm_put(Dst, 10102); 2523 dasm_put(Dst, 10102);
2525 break; 2524 break;
2526 case BC_KPRI: 2525 case BC_KPRI:
2527 dasm_put(Dst, 11987); 2526 dasm_put(Dst, 11989);
2528 break; 2527 break;
2529 case BC_KNIL: 2528 case BC_KNIL:
2530 dasm_put(Dst, 12015, LJ_TNIL); 2529 dasm_put(Dst, 12017, LJ_TNIL);
2531 break; 2530 break;
2532 2531
2533 /* -- Upvalue and function ops ------------------------------------------ */ 2532 /* -- Upvalue and function ops ------------------------------------------ */
2534 2533
2535 case BC_UGET: 2534 case BC_UGET:
2536 dasm_put(Dst, 12062, offsetof(GCfuncL, uvptr), DtA(->v)); 2535 dasm_put(Dst, 12064, offsetof(GCfuncL, uvptr), DtA(->v));
2537 break; 2536 break;
2538 case BC_USETV: 2537 case BC_USETV:
2539#define TV2MARKOFS \ 2538#define TV2MARKOFS \
2540 ((int32_t)offsetof(GCupval, marked)-(int32_t)offsetof(GCupval, tv)) 2539 ((int32_t)offsetof(GCupval, marked)-(int32_t)offsetof(GCupval, tv))
2541 dasm_put(Dst, 12102, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G); 2540 dasm_put(Dst, 12104, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
2542 dasm_put(Dst, 12193); 2541 dasm_put(Dst, 12195);
2543 break; 2542 break;
2544#undef TV2MARKOFS 2543#undef TV2MARKOFS
2545 case BC_USETS: 2544 case BC_USETS:
2546 dasm_put(Dst, 12205, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G); 2545 dasm_put(Dst, 12207, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
2547 break; 2546 break;
2548 case BC_USETN: 2547 case BC_USETN:
2549 dasm_put(Dst, 12298); 2548 dasm_put(Dst, 12300);
2550 if (sse) { 2549 if (sse) {
2551 dasm_put(Dst, 12303); 2550 dasm_put(Dst, 12305);
2552 } else { 2551 } else {
2553 dasm_put(Dst, 11751); 2552 dasm_put(Dst, 10613);
2554 } 2553 }
2555 dasm_put(Dst, 12310, offsetof(GCfuncL, uvptr), DtA(->v)); 2554 dasm_put(Dst, 12312, offsetof(GCfuncL, uvptr), DtA(->v));
2556 if (sse) { 2555 if (sse) {
2557 dasm_put(Dst, 12319); 2556 dasm_put(Dst, 12321);
2558 } else { 2557 } else {
2559 dasm_put(Dst, 12325); 2558 dasm_put(Dst, 12327);
2560 } 2559 }
2561 dasm_put(Dst, 10102); 2560 dasm_put(Dst, 10102);
2562 break; 2561 break;
2563 case BC_USETP: 2562 case BC_USETP:
2564 dasm_put(Dst, 12328, offsetof(GCfuncL, uvptr), DtA(->v)); 2563 dasm_put(Dst, 12330, offsetof(GCfuncL, uvptr), DtA(->v));
2565 break; 2564 break;
2566 case BC_UCLO: 2565 case BC_UCLO:
2567 dasm_put(Dst, 12367, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base)); 2566 dasm_put(Dst, 12369, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
2568 break; 2567 break;
2569 2568
2570 case BC_FNEW: 2569 case BC_FNEW:
2571 dasm_put(Dst, 12422, Dt1(->base), Dt1(->base), LJ_TFUNC); 2570 dasm_put(Dst, 12424, Dt1(->base), Dt1(->base), LJ_TFUNC);
2572 break; 2571 break;
2573 2572
2574 /* -- Table ops --------------------------------------------------------- */ 2573 /* -- Table ops --------------------------------------------------------- */
2575 2574
2576 case BC_TNEW: 2575 case BC_TNEW:
2577 dasm_put(Dst, 12488, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB); 2576 dasm_put(Dst, 12490, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
2578 break; 2577 break;
2579 case BC_TDUP: 2578 case BC_TDUP:
2580 dasm_put(Dst, 12610, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB); 2579 dasm_put(Dst, 12612, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
2581 break; 2580 break;
2582 2581
2583 case BC_GGET: 2582 case BC_GGET:
2584 dasm_put(Dst, 12705, Dt7(->env)); 2583 dasm_put(Dst, 12707, Dt7(->env));
2585 break; 2584 break;
2586 case BC_GSET: 2585 case BC_GSET:
2587 dasm_put(Dst, 12724, Dt7(->env)); 2586 dasm_put(Dst, 12726, Dt7(->env));
2588 break; 2587 break;
2589 2588
2590 case BC_TGETV: 2589 case BC_TGETV:
2591 dasm_put(Dst, 12743, LJ_TTAB); 2590 dasm_put(Dst, 12745, LJ_TTAB);
2592 if (LJ_DUALNUM) { 2591 if (LJ_DUALNUM) {
2593 dasm_put(Dst, 12766, LJ_TISNUM); 2592 dasm_put(Dst, 12768, LJ_TISNUM);
2594 } else { 2593 } else {
2595 dasm_put(Dst, 12780, LJ_TISNUM); 2594 dasm_put(Dst, 12782, LJ_TISNUM);
2596 if (sse) { 2595 if (sse) {
2597 dasm_put(Dst, 12791); 2596 dasm_put(Dst, 12793);
2598 } else { 2597 } else {
2599 } 2598 }
2600 dasm_put(Dst, 12812); 2599 dasm_put(Dst, 12814);
2601 } 2600 }
2602 dasm_put(Dst, 12817, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL); 2601 dasm_put(Dst, 12819, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
2603 dasm_put(Dst, 12908, LJ_TSTR); 2602 dasm_put(Dst, 12910, LJ_TSTR);
2604 break; 2603 break;
2605 case BC_TGETS: 2604 case BC_TGETS:
2606 dasm_put(Dst, 12926, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL); 2605 dasm_put(Dst, 12928, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
2607 dasm_put(Dst, 13010, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index); 2606 dasm_put(Dst, 13012, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
2608 break; 2607 break;
2609 case BC_TGETB: 2608 case BC_TGETB:
2610 dasm_put(Dst, 13081, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index); 2609 dasm_put(Dst, 13083, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
2611 dasm_put(Dst, 13176, LJ_TNIL); 2610 dasm_put(Dst, 13178, LJ_TNIL);
2612 break; 2611 break;
2613 2612
2614 case BC_TSETV: 2613 case BC_TSETV:
2615 dasm_put(Dst, 13193, LJ_TTAB); 2614 dasm_put(Dst, 13195, LJ_TTAB);
2616 if (LJ_DUALNUM) { 2615 if (LJ_DUALNUM) {
2617 dasm_put(Dst, 12766, LJ_TISNUM); 2616 dasm_put(Dst, 12768, LJ_TISNUM);
2618 } else { 2617 } else {
2619 dasm_put(Dst, 12780, LJ_TISNUM); 2618 dasm_put(Dst, 12782, LJ_TISNUM);
2620 if (sse) { 2619 if (sse) {
2621 dasm_put(Dst, 12791); 2620 dasm_put(Dst, 12793);
2622 } else { 2621 } else {
2623 } 2622 }
2624 dasm_put(Dst, 13216); 2623 dasm_put(Dst, 13218);
2625 } 2624 }
2626 dasm_put(Dst, 13221, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex); 2625 dasm_put(Dst, 13223, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
2627 dasm_put(Dst, 13301, LJ_TSTR, Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist)); 2626 dasm_put(Dst, 13303, LJ_TSTR, Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
2628 break; 2627 break;
2629 case BC_TSETS: 2628 case BC_TSETS:
2630 dasm_put(Dst, 13358, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL); 2629 dasm_put(Dst, 13360, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
2631 dasm_put(Dst, 13434, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next)); 2630 dasm_put(Dst, 13436, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
2632 dasm_put(Dst, 13522, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist)); 2631 dasm_put(Dst, 13524, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
2633 break; 2632 break;
2634 case BC_TSETB: 2633 case BC_TSETB:
2635 dasm_put(Dst, 13613, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable)); 2634 dasm_put(Dst, 13615, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
2636 dasm_put(Dst, 13707, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist)); 2635 dasm_put(Dst, 13709, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
2637 break; 2636 break;
2638 2637
2639 case BC_TSETM: 2638 case BC_TSETM:
2640 dasm_put(Dst, 13753, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base)); 2639 dasm_put(Dst, 13755, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
2641 dasm_put(Dst, 13896, Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist)); 2640 dasm_put(Dst, 13898, Dt6(->marked), cast_byte(~LJ_GC_BLACK), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
2642 break; 2641 break;
2643 2642
2644 /* -- Calls and vararg handling ----------------------------------------- */ 2643 /* -- Calls and vararg handling ----------------------------------------- */
2645 2644
2646 case BC_CALL: case BC_CALLM: 2645 case BC_CALL: case BC_CALLM:
2647 dasm_put(Dst, 11091); 2646 dasm_put(Dst, 11093);
2648 if (op == BC_CALLM) { 2647 if (op == BC_CALLM) {
2649 dasm_put(Dst, 13914); 2648 dasm_put(Dst, 13916);
2650 } 2649 }
2651 dasm_put(Dst, 13919, LJ_TFUNC, Dt7(->pc)); 2650 dasm_put(Dst, 13921, LJ_TFUNC, Dt7(->pc));
2652 break; 2651 break;
2653 2652
2654 case BC_CALLMT: 2653 case BC_CALLMT:
2655 dasm_put(Dst, 13914); 2654 dasm_put(Dst, 13916);
2656 break; 2655 break;
2657 case BC_CALLT: 2656 case BC_CALLT:
2658 dasm_put(Dst, 13961, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc)); 2657 dasm_put(Dst, 13963, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
2659 dasm_put(Dst, 14076, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG); 2658 dasm_put(Dst, 14078, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
2660 break; 2659 break;
2661 2660
2662 case BC_ITERC: 2661 case BC_ITERC:
2663 dasm_put(Dst, 14147, LJ_TFUNC, 2+1, Dt7(->pc)); 2662 dasm_put(Dst, 14149, LJ_TFUNC, 2+1, Dt7(->pc));
2664 break; 2663 break;
2665 2664
2666 case BC_ITERN: 2665 case BC_ITERN:
2667#if LJ_HASJIT 2666#if LJ_HASJIT
2668#endif 2667#endif
2669 dasm_put(Dst, 14218, Dt6(->asize), Dt6(->array), LJ_TNIL); 2668 dasm_put(Dst, 14220, Dt6(->asize), Dt6(->array), LJ_TNIL);
2670 if (LJ_DUALNUM) { 2669 if (LJ_DUALNUM) {
2671 dasm_put(Dst, 10991, LJ_TISNUM); 2670 dasm_put(Dst, 10993, LJ_TISNUM);
2672 } else if (sse) { 2671 } else if (sse) {
2673 dasm_put(Dst, 11068); 2672 dasm_put(Dst, 11070);
2674 } else { 2673 } else {
2675 dasm_put(Dst, 14264); 2674 dasm_put(Dst, 14266);
2676 } 2675 }
2677 dasm_put(Dst, 14270); 2676 dasm_put(Dst, 14272);
2678 if (LJ_DUALNUM) { 2677 if (LJ_DUALNUM) {
2679 } else if (sse) { 2678 } else if (sse) {
2680 dasm_put(Dst, 10956); 2679 dasm_put(Dst, 10958);
2681 } else { 2680 } else {
2682 dasm_put(Dst, 10968); 2681 dasm_put(Dst, 10970);
2683 } 2682 }
2684 dasm_put(Dst, 14283, -BCBIAS_J*4); 2683 dasm_put(Dst, 14285, -BCBIAS_J*4);
2685 if (!LJ_DUALNUM && !sse) { 2684 if (!LJ_DUALNUM && !sse) {
2686 dasm_put(Dst, 14335); 2685 dasm_put(Dst, 14337);
2687 } 2686 }
2688 dasm_put(Dst, 14341, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key), DtB(->val)); 2687 dasm_put(Dst, 14343, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key), DtB(->val));
2689 break; 2688 break;
2690 2689
2691 case BC_ISNEXT: 2690 case BC_ISNEXT:
2692 dasm_put(Dst, 14413, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC); 2691 dasm_put(Dst, 14415, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
2693 break; 2692 break;
2694 2693
2695 case BC_VARG: 2694 case BC_VARG:
2696 dasm_put(Dst, 14513, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack)); 2695 dasm_put(Dst, 14515, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
2697 dasm_put(Dst, 14673, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top)); 2696 dasm_put(Dst, 14675, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
2698 break; 2697 break;
2699 2698
2700 /* -- Returns ----------------------------------------------------------- */ 2699 /* -- Returns ----------------------------------------------------------- */
2701 2700
2702 case BC_RETM: 2701 case BC_RETM:
2703 dasm_put(Dst, 13914); 2702 dasm_put(Dst, 13916);
2704 break; 2703 break;
2705 2704
2706 case BC_RET: case BC_RET0: case BC_RET1: 2705 case BC_RET: case BC_RET0: case BC_RET1:
2707 if (op != BC_RET0) { 2706 if (op != BC_RET0) {
2708 dasm_put(Dst, 14739); 2707 dasm_put(Dst, 14741);
2709 } 2708 }
2710 dasm_put(Dst, 14743, FRAME_TYPE); 2709 dasm_put(Dst, 14745, FRAME_TYPE);
2711 switch (op) { 2710 switch (op) {
2712 case BC_RET: 2711 case BC_RET:
2713 dasm_put(Dst, 14762); 2712 dasm_put(Dst, 14764);
2714 break; 2713 break;
2715 case BC_RET1: 2714 case BC_RET1:
2716 dasm_put(Dst, 14814); 2715 dasm_put(Dst, 14816);
2717 /* fallthrough */ 2716 /* fallthrough */
2718 case BC_RET0: 2717 case BC_RET0:
2719 dasm_put(Dst, 14824); 2718 dasm_put(Dst, 14826);
2720 default: 2719 default:
2721 break; 2720 break;
2722 } 2721 }
2723 dasm_put(Dst, 14835, Dt7(->pc), PC2PROTO(k)); 2722 dasm_put(Dst, 14837, Dt7(->pc), PC2PROTO(k));
2724 if (op == BC_RET) { 2723 if (op == BC_RET) {
2725 dasm_put(Dst, 14879, LJ_TNIL); 2724 dasm_put(Dst, 14881, LJ_TNIL);
2726 } else { 2725 } else {
2727 dasm_put(Dst, 14888, LJ_TNIL); 2726 dasm_put(Dst, 14890, LJ_TNIL);
2728 } 2727 }
2729 dasm_put(Dst, 14895, -FRAME_VARG, FRAME_TYPEP); 2728 dasm_put(Dst, 14897, -FRAME_VARG, FRAME_TYPEP);
2730 if (op != BC_RET0) { 2729 if (op != BC_RET0) {
2731 dasm_put(Dst, 14919); 2730 dasm_put(Dst, 14921);
2732 } 2731 }
2733 dasm_put(Dst, 4646); 2732 dasm_put(Dst, 4646);
2734 break; 2733 break;
@@ -2738,7 +2737,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2738 2737
2739 case BC_FORL: 2738 case BC_FORL:
2740#if LJ_HASJIT 2739#if LJ_HASJIT
2741 dasm_put(Dst, 14923, HOTCOUNT_PCMASK, GG_DISP2HOT); 2740 dasm_put(Dst, 14925, HOTCOUNT_PCMASK, GG_DISP2HOT);
2742#endif 2741#endif
2743 break; 2742 break;
2744 2743
@@ -2750,104 +2749,104 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2750 case BC_FORI: 2749 case BC_FORI:
2751 case BC_IFORL: 2750 case BC_IFORL:
2752 vk = (op == BC_IFORL || op == BC_JFORL); 2751 vk = (op == BC_IFORL || op == BC_JFORL);
2753 dasm_put(Dst, 14944); 2752 dasm_put(Dst, 14946);
2754 if (LJ_DUALNUM) { 2753 if (LJ_DUALNUM) {
2755 dasm_put(Dst, 14948, LJ_TISNUM); 2754 dasm_put(Dst, 14950, LJ_TISNUM);
2756 if (!vk) { 2755 if (!vk) {
2757 dasm_put(Dst, 14958, LJ_TISNUM, LJ_TISNUM); 2756 dasm_put(Dst, 14960, LJ_TISNUM, LJ_TISNUM);
2758 } else { 2757 } else {
2759 dasm_put(Dst, 14987); 2758 dasm_put(Dst, 14989);
2760 } 2759 }
2761 dasm_put(Dst, 15006, LJ_TISNUM); 2760 dasm_put(Dst, 15008, LJ_TISNUM);
2762 if (op == BC_FORI) { 2761 if (op == BC_FORI) {
2763 dasm_put(Dst, 15017, -BCBIAS_J*4); 2762 dasm_put(Dst, 15019, -BCBIAS_J*4);
2764 } else if (op == BC_JFORI) { 2763 } else if (op == BC_JFORI) {
2765 dasm_put(Dst, 15031, -BCBIAS_J*4, BC_JLOOP); 2764 dasm_put(Dst, 15033, -BCBIAS_J*4, BC_JLOOP);
2766 } else if (op == BC_IFORL) { 2765 } else if (op == BC_IFORL) {
2767 dasm_put(Dst, 15049, -BCBIAS_J*4); 2766 dasm_put(Dst, 15051, -BCBIAS_J*4);
2768 } else { 2767 } else {
2769 dasm_put(Dst, 15041, BC_JLOOP); 2768 dasm_put(Dst, 15043, BC_JLOOP);
2770 } 2769 }
2771 dasm_put(Dst, 15063); 2770 dasm_put(Dst, 15065);
2772 if (vk) { 2771 if (vk) {
2773 dasm_put(Dst, 15087); 2772 dasm_put(Dst, 15089);
2774 } 2773 }
2775 dasm_put(Dst, 15006, LJ_TISNUM); 2774 dasm_put(Dst, 15008, LJ_TISNUM);
2776 if (op == BC_FORI) { 2775 if (op == BC_FORI) {
2777 dasm_put(Dst, 15096); 2776 dasm_put(Dst, 15098);
2778 } else if (op == BC_JFORI) { 2777 } else if (op == BC_JFORI) {
2779 dasm_put(Dst, 15101, -BCBIAS_J*4, BC_JLOOP); 2778 dasm_put(Dst, 15103, -BCBIAS_J*4, BC_JLOOP);
2780 } else if (op == BC_IFORL) { 2779 } else if (op == BC_IFORL) {
2781 dasm_put(Dst, 15115); 2780 dasm_put(Dst, 15117);
2782 } else { 2781 } else {
2783 dasm_put(Dst, 15111, BC_JLOOP); 2782 dasm_put(Dst, 15113, BC_JLOOP);
2784 } 2783 }
2785 dasm_put(Dst, 15120); 2784 dasm_put(Dst, 15122);
2786 } else if (!vk) { 2785 } else if (!vk) {
2787 dasm_put(Dst, 15127, LJ_TISNUM); 2786 dasm_put(Dst, 15129, LJ_TISNUM);
2788 } 2787 }
2789 if (!vk) { 2788 if (!vk) {
2790 dasm_put(Dst, 15133, LJ_TISNUM); 2789 dasm_put(Dst, 15135, LJ_TISNUM);
2791 } 2790 }
2792 dasm_put(Dst, 15147); 2791 dasm_put(Dst, 15149);
2793 if (!vk) { 2792 if (!vk) {
2794 dasm_put(Dst, 15151, LJ_TISNUM); 2793 dasm_put(Dst, 15153, LJ_TISNUM);
2795 } 2794 }
2796 if (sse) { 2795 if (sse) {
2797 dasm_put(Dst, 15160); 2796 dasm_put(Dst, 15162);
2798 if (vk) { 2797 if (vk) {
2799 dasm_put(Dst, 15172); 2798 dasm_put(Dst, 15174);
2800 } else { 2799 } else {
2801 dasm_put(Dst, 15191); 2800 dasm_put(Dst, 15193);
2802 } 2801 }
2803 dasm_put(Dst, 15196); 2802 dasm_put(Dst, 15198);
2804 } else { 2803 } else {
2805 dasm_put(Dst, 15209); 2804 dasm_put(Dst, 15211);
2806 if (vk) { 2805 if (vk) {
2807 dasm_put(Dst, 15215); 2806 dasm_put(Dst, 15217);
2808 } else { 2807 } else {
2809 dasm_put(Dst, 15231); 2808 dasm_put(Dst, 15233);
2810 } 2809 }
2811 dasm_put(Dst, 15239); 2810 dasm_put(Dst, 15241);
2812 if (cmov) { 2811 if (cmov) {
2813 dasm_put(Dst, 10057); 2812 dasm_put(Dst, 10057);
2814 } else { 2813 } else {
2815 dasm_put(Dst, 10063); 2814 dasm_put(Dst, 10063);
2816 } 2815 }
2817 if (!cmov) { 2816 if (!cmov) {
2818 dasm_put(Dst, 15244); 2817 dasm_put(Dst, 15246);
2819 } 2818 }
2820 } 2819 }
2821 if (op == BC_FORI) { 2820 if (op == BC_FORI) {
2822 if (LJ_DUALNUM) { 2821 if (LJ_DUALNUM) {
2823 dasm_put(Dst, 15250); 2822 dasm_put(Dst, 15252);
2824 } else { 2823 } else {
2825 dasm_put(Dst, 15255, -BCBIAS_J*4); 2824 dasm_put(Dst, 15257, -BCBIAS_J*4);
2826 } 2825 }
2827 } else if (op == BC_JFORI) { 2826 } else if (op == BC_JFORI) {
2828 dasm_put(Dst, 15265, -BCBIAS_J*4, BC_JLOOP); 2827 dasm_put(Dst, 15267, -BCBIAS_J*4, BC_JLOOP);
2829 } else if (op == BC_IFORL) { 2828 } else if (op == BC_IFORL) {
2830 if (LJ_DUALNUM) { 2829 if (LJ_DUALNUM) {
2831 dasm_put(Dst, 15279); 2830 dasm_put(Dst, 15281);
2832 } else { 2831 } else {
2833 dasm_put(Dst, 15284, -BCBIAS_J*4); 2832 dasm_put(Dst, 15286, -BCBIAS_J*4);
2834 } 2833 }
2835 } else { 2834 } else {
2836 dasm_put(Dst, 15275, BC_JLOOP); 2835 dasm_put(Dst, 15277, BC_JLOOP);
2837 } 2836 }
2838 if (LJ_DUALNUM) { 2837 if (LJ_DUALNUM) {
2839 dasm_put(Dst, 9986); 2838 dasm_put(Dst, 9986);
2840 } else { 2839 } else {
2841 dasm_put(Dst, 10741); 2840 dasm_put(Dst, 10743);
2842 } 2841 }
2843 if (sse) { 2842 if (sse) {
2844 dasm_put(Dst, 15294); 2843 dasm_put(Dst, 15296);
2845 } 2844 }
2846 break; 2845 break;
2847 2846
2848 case BC_ITERL: 2847 case BC_ITERL:
2849#if LJ_HASJIT 2848#if LJ_HASJIT
2850 dasm_put(Dst, 14923, HOTCOUNT_PCMASK, GG_DISP2HOT); 2849 dasm_put(Dst, 14925, HOTCOUNT_PCMASK, GG_DISP2HOT);
2851#endif 2850#endif
2852 break; 2851 break;
2853 2852
@@ -2856,18 +2855,18 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2856 break; 2855 break;
2857#endif 2856#endif
2858 case BC_IITERL: 2857 case BC_IITERL:
2859 dasm_put(Dst, 15305, LJ_TNIL); 2858 dasm_put(Dst, 15307, LJ_TNIL);
2860 if (op == BC_JITERL) { 2859 if (op == BC_JITERL) {
2861 dasm_put(Dst, 15320, BC_JLOOP); 2860 dasm_put(Dst, 15322, BC_JLOOP);
2862 } else { 2861 } else {
2863 dasm_put(Dst, 15334, -BCBIAS_J*4); 2862 dasm_put(Dst, 15336, -BCBIAS_J*4);
2864 } 2863 }
2865 dasm_put(Dst, 10100); 2864 dasm_put(Dst, 10100);
2866 break; 2865 break;
2867 2866
2868 case BC_LOOP: 2867 case BC_LOOP:
2869#if LJ_HASJIT 2868#if LJ_HASJIT
2870 dasm_put(Dst, 14923, HOTCOUNT_PCMASK, GG_DISP2HOT); 2869 dasm_put(Dst, 14925, HOTCOUNT_PCMASK, GG_DISP2HOT);
2871#endif 2870#endif
2872 break; 2871 break;
2873 2872
@@ -2877,12 +2876,12 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2877 2876
2878 case BC_JLOOP: 2877 case BC_JLOOP:
2879#if LJ_HASJIT 2878#if LJ_HASJIT
2880 dasm_put(Dst, 15350, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L), 9*16+4*8, -1*16, -2*16, -3*16, -4*16, -5*16, -6*16, -7*16, -8*16, -9*16); 2879 dasm_put(Dst, 15352, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L), 9*16+4*8, -1*16, -2*16, -3*16, -4*16, -5*16, -6*16, -7*16, -8*16, -9*16);
2881#endif 2880#endif
2882 break; 2881 break;
2883 2882
2884 case BC_JMP: 2883 case BC_JMP:
2885 dasm_put(Dst, 15459, -BCBIAS_J*4); 2884 dasm_put(Dst, 15461, -BCBIAS_J*4);
2886 break; 2885 break;
2887 2886
2888 /* -- Function headers -------------------------------------------------- */ 2887 /* -- Function headers -------------------------------------------------- */
@@ -2896,7 +2895,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2896 2895
2897 case BC_FUNCF: 2896 case BC_FUNCF:
2898#if LJ_HASJIT 2897#if LJ_HASJIT
2899 dasm_put(Dst, 15484, HOTCOUNT_PCMASK, GG_DISP2HOT); 2898 dasm_put(Dst, 15486, HOTCOUNT_PCMASK, GG_DISP2HOT);
2900#endif 2899#endif
2901 case BC_FUNCV: /* NYI: compiled vararg functions. */ 2900 case BC_FUNCV: /* NYI: compiled vararg functions. */
2902 break; 2901 break;
@@ -2906,13 +2905,13 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2906 break; 2905 break;
2907#endif 2906#endif
2908 case BC_IFUNCF: 2907 case BC_IFUNCF:
2909 dasm_put(Dst, 15505, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams)); 2908 dasm_put(Dst, 15507, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
2910 if (op == BC_JFUNCF) { 2909 if (op == BC_JFUNCF) {
2911 dasm_put(Dst, 15535, BC_JLOOP); 2910 dasm_put(Dst, 15537, BC_JLOOP);
2912 } else { 2911 } else {
2913 dasm_put(Dst, 10102); 2912 dasm_put(Dst, 10102);
2914 } 2913 }
2915 dasm_put(Dst, 15544, LJ_TNIL); 2914 dasm_put(Dst, 15546, LJ_TNIL);
2916 break; 2915 break;
2917 2916
2918 case BC_JFUNCV: 2917 case BC_JFUNCV:
@@ -2923,30 +2922,30 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
2923 break; /* NYI: compiled vararg functions. */ 2922 break; /* NYI: compiled vararg functions. */
2924 2923
2925 case BC_IFUNCV: 2924 case BC_IFUNCV:
2926 dasm_put(Dst, 15566, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL); 2925 dasm_put(Dst, 15568, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
2927 if (op == BC_JFUNCV) { 2926 if (op == BC_JFUNCV) {
2928 dasm_put(Dst, 15535, BC_JLOOP); 2927 dasm_put(Dst, 15537, BC_JLOOP);
2929 } else { 2928 } else {
2930 dasm_put(Dst, 15657, -4+PC2PROTO(k)); 2929 dasm_put(Dst, 15659, -4+PC2PROTO(k));
2931 } 2930 }
2932 dasm_put(Dst, 15680, LJ_TNIL); 2931 dasm_put(Dst, 15682, LJ_TNIL);
2933 break; 2932 break;
2934 2933
2935 case BC_FUNCC: 2934 case BC_FUNCC:
2936 case BC_FUNCCW: 2935 case BC_FUNCCW:
2937 dasm_put(Dst, 15702, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top)); 2936 dasm_put(Dst, 15704, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
2938 if (op == BC_FUNCC) { 2937 if (op == BC_FUNCC) {
2939 dasm_put(Dst, 2310); 2938 dasm_put(Dst, 2310);
2940 } else { 2939 } else {
2941 dasm_put(Dst, 15732); 2940 dasm_put(Dst, 15734);
2942 } 2941 }
2943 dasm_put(Dst, 15740, DISPATCH_GL(vmstate), ~LJ_VMST_C); 2942 dasm_put(Dst, 15742, DISPATCH_GL(vmstate), ~LJ_VMST_C);
2944 if (op == BC_FUNCC) { 2943 if (op == BC_FUNCC) {
2945 dasm_put(Dst, 15749); 2944 dasm_put(Dst, 15751);
2946 } else { 2945 } else {
2947 dasm_put(Dst, 15753, DISPATCH_GL(wrapf)); 2946 dasm_put(Dst, 15755, DISPATCH_GL(wrapf));
2948 } 2947 }
2949 dasm_put(Dst, 15758, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top)); 2948 dasm_put(Dst, 15760, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
2950 break; 2949 break;
2951 2950
2952 /* ---------------------------------------------------------------------- */ 2951 /* ---------------------------------------------------------------------- */
@@ -2974,7 +2973,7 @@ static int build_backend(BuildCtx *ctx)
2974 2973
2975 build_subroutines(ctx, cmov, sse); 2974 build_subroutines(ctx, cmov, sse);
2976 2975
2977 dasm_put(Dst, 15783); 2976 dasm_put(Dst, 15785);
2978 for (op = 0; op < BC__MAX; op++) 2977 for (op = 0; op < BC__MAX; op++)
2979 build_ins(ctx, (BCOp)op, op, cmov, sse); 2978 build_ins(ctx, (BCOp)op, op, cmov, sse);
2980 2979