コミットメタ情報

リビジョンbb50e8adcba1c7ec4d20c147905037854b850999 (tree)
日時2014-03-16 14:44:24
作者hikarupsp <hikarupsp@user...>
コミッターhikarupsp

ログメッセージ

JITCのModR/M関連部分をわかりやすくした。

変更サマリ

差分

--- a/jitc.h
+++ b/jitc.h
@@ -50,6 +50,15 @@ int jitCompCmdLen(const unsigned char *src);
5050 #define IA32_REG6_ESI 6
5151 #define IA32_REG7_EDI 7
5252 //
53+#define IA32_MOD_R_M(mod, reg, rm) ((mod << 6) | reg << 3 | rm)
54+//
55+#define IA32_OP_MOD_INDEXONLY 0
56+#define IA32_OP_MOD_INDEX_AND_DISP_BYTE 1
57+#define IA32_OP_MOD_INDEX_AND_DISP_FULL 2
58+#define IA32_OP_MOD_REGISTER 3
59+//
60+#define IA32_OP_RM32_MOD00_ADDR_DISP32 5
61+//
5362 #define envOffset_DBGINFO0 (2304 + 0)
5463 #define envOffset_DBGINFO1 (2304 + 4)
5564 //
@@ -92,9 +101,9 @@ struct JitCompWork {
92101 // @jitcx86a.c
93102 int jitCompGetImm32(const unsigned char *src);
94103 int jitCompGetLabelNum(struct JitCompWork *w, const unsigned char *src);
95-void jitCompA0001_85DispN(struct JitCompWork *w, int disp, int n);
96-void jitCompA0001_movEbpDispReg32(struct JitCompWork *w, int disp, int reg32);
97-void jitCompA0001_movReg32EbpDisp(struct JitCompWork *w, int reg32, int disp);
104+void jitCompPutModRM_Disp_BaseEBP(struct JitCompWork *w, int disp, int opReg);
105+void jitCompPutOp_MOV_EBPDisp_GReg(struct JitCompWork *w, int disp, int reg32);
106+void jitCompPutOp_MOV_GReg_EBPDisp(struct JitCompWork *w, int reg32, int disp);
98107 void jitCompA0001_movEaxRxx(struct JitCompWork *w, int rxx);
99108 void jitCompA0001_movRxxEax(struct JitCompWork *w, int rxx);
100109 void jitCompA0001_fixPrefix(struct JitCompWork *w);
--- a/jitcx86.c
+++ b/jitcx86.c
@@ -37,10 +37,9 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
3737 // env.debugInfo0 <- 0;
3838 // env.debugInfo1 <- debugInfo1;
3939 jitCompPutOp_MOV_EAX_ZERO(w.dst);
40- // MOV(debugInfo0, EAX);
41- jitCompA0001_movEbpDispReg32(&w, envOffset_DBGINFO0, IA32_REG0_EAX);
40+ jitCompPutOp_MOV_EBPDisp_GReg(&w, envOffset_DBGINFO0, IA32_REG0_EAX);
4241 jitCompPutOp_MOV_GReg_Imm32(w.dst, IA32_REG0_EAX, debugInfo1);
43- jitCompA0001_movEbpDispReg32(&w, envOffset_DBGINFO1, IA32_REG0_EAX); /* MOV(debugInfo1, EAX); */
42+ jitCompPutOp_MOV_EBPDisp_GReg(&w, envOffset_DBGINFO1, IA32_REG0_EAX);
4443 }
4544 while (src < src1) {
4645 w.prefix = 0; //0x04 CND 命令で変更される
@@ -282,20 +281,20 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
282281
283282 // レジスタへの代入をメモリでエミュレーションする場合は、スタックに積む。
284283 if (reg0 == 0)
285- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
284+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
286285
287286 if (level < JITC_LV_FASTEST) {
288- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 8, reg0); /* MOV([EBP+?], reg0); */ /* p0 */
287+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 8, reg0); /* MOV([EBP+?], reg0); */ /* p0 */
289288 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
290289 jitCompPutImm32(w.dst, label[i].typ);
291- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 4, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* typ */
290+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 4, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* typ */
292291 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
293292 jitCompPutImm32(w.dst, (int)label[i].p1);
294- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 12, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* p1 */
295- jitCompPutByte2(w.dst, 0x31, 0xc0); /* XOR(EAX, EAX); */
296- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 16, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* liveSign */
297- jitCompA0001_movReg32EbpDisp(&w, 0, 2320); /* MOV(EAX, ptrCtrl); */
298- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 20, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* pls */
293+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 12, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* p1 */
294+ jitCompPutOp_MOV_EAX_ZERO(w.dst);
295+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 16, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* liveSign */
296+ jitCompPutOp_MOV_GReg_EBPDisp(&w, 0, 2320); /* MOV(EAX, ptrCtrl); */
297+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 20, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */ /* pls */
299298 }
300299 }
301300 break;
@@ -316,7 +315,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
316315 /* TEST命令を発行 */
317316 if (reg0 < 0) { //比較対象のレジスタはメモリ上にある
318317 jitCompPutByte1(w.dst, 0xf7); /* TEST([EBP+?],1); */
319- jitCompA0001_85DispN(&w, src[1] * 4, 0);
318+ jitCompPutModRM_Disp_BaseEBP(&w, src[1] * 4, 0);
320319 }
321320 else {
322321 jitCompPutByte2(w.dst, 0xf7, 0xc0 | reg0); /* TEST(reg0,1); */
@@ -346,7 +345,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
346345 if (reg1 == IA32_REG2_EDX)
347346 jitCompA000_storeRegCacheEdx(&w);
348347 if (reg1 <= 3 /* EAX, EDX */)
349- jitCompA0001_movReg32EbpDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
348+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
350349 if (level < JITC_LV_FASTER)
351350 jitCompA0001_checkLimit(&w, reg1, src[6]);
352351 i = jitCompA000_convTyp(jitCompGetImm32(src + 2));
@@ -390,7 +389,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
390389 if (reg1 == IA32_REG2_EDX)
391390 jitCompA000_storeRegCacheEdx(&w);
392391 if (reg1 <= 3 /* EAX, EDX */)
393- jitCompA0001_movReg32EbpDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
392+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
394393 if (level < JITC_LV_FASTER)
395394 jitCompA0001_checkLimit(&w, reg1, src[6]);
396395 if (reg0 == 0 /* EAX */)
@@ -436,15 +435,15 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
436435 if (reg1 == IA32_REG2_EDX)
437436 jitCompA000_storeRegCacheEdx(&w);
438437 if (reg1 <= 3 /* EAX, EDX */)
439- jitCompA0001_movReg32EbpDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
438+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
440439 if (level < JITC_LV_FASTER)
441440 jitCompA0001_checkLimit(&w, reg1, src[6]);
442441 jitCompPutByte2(w.dst, 0x8b, reg0 << 3 | reg1); /* MOV(reg0, [reg1]); */
443442 if (reg0 == IA32_REG0_EAX)
444- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 0, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
443+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 0, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
445444 for (i = 4; i < 32; i += 4) {
446445 jitCompPutByte3(w.dst, 0x8b, 0x40 | reg1, i); /* MOV(EAX, [reg1+?]); */
447- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
446+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
448447 }
449448 if (reg1 == IA32_REG2_EDX)
450449 jitCompA000_loadRegCacheEdx(&w);
@@ -465,14 +464,14 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
465464 if (reg1 == IA32_REG2_EDX)
466465 jitCompA000_storeRegCacheEdx(&w);
467466 if (reg1 <= 3 /* EAX, EDX */)
468- jitCompA0001_movReg32EbpDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
467+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg1, 256 + src[6] * 32 + 0); /* MOV(reg1, [EBP+?]); */
469468 if (level < JITC_LV_FASTER)
470469 jitCompA0001_checkLimit(&w, reg1, src[6]);
471470 if (reg0 == IA32_REG0_EAX)
472- jitCompA0001_movReg32EbpDisp(&w, reg0, 256 + src[1] * 32 + 0); /* MOV(reg0, [EBP+?]); */
471+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg0, 256 + src[1] * 32 + 0); /* MOV(reg0, [EBP+?]); */
473472 jitCompPutByte2(w.dst, 0x89, reg0 << 3 | reg1); /* MOV([reg1], reg0); */
474473 for (i = 4; i < 32; i += 4) {
475- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + src[1] * 32 + i); /* MOV(EAX, [EBP+?]); */
474+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + src[1] * 32 + i); /* MOV(EAX, [EBP+?]); */
476475 jitCompPutByte3(w.dst, 0x89, 0x40 | reg1, i); /* MOV([reg1+?], EAX); */
477476 }
478477 if (reg1 == IA32_REG2_EDX)
@@ -487,7 +486,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
487486 reg0 = jitCompA000_selectPRegCache(src[1], IA32_REG0_EAX);
488487 reg1 = jitCompA000_selectPRegCache(src[6], -1 /* mem */);
489488 if (reg1 < 0 /* mem */)
490- jitCompA0001_movReg32EbpDisp(&w, reg0, 256 + src[6] * 32 + 0); /* MOV(reg0, [EBP+?]); */
489+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg0, 256 + src[6] * 32 + 0); /* MOV(reg0, [EBP+?]); */
491490 if (reg1 >= 0 && reg0 != reg1) {
492491 jitCompPutByte2(w.dst, 0x89, 0xc0 | reg1 << 3 | reg0); /* MOV(reg0, reg1); */
493492 }
@@ -532,7 +531,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
532531 }
533532 else {
534533 jitCompPutByte1(w.dst, 0x03); /* ADD(reg0, [EBP+?]); */
535- jitCompA0001_85DispN(&w, src[7] * 4, reg0);
534+ jitCompPutModRM_Disp_BaseEBP(&w, src[7] * 4, reg0);
536535 }
537536 }
538537 else {
@@ -540,7 +539,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
540539 reg2 = 2; /* EDX */
541540 jitCompA000_storeRegCacheEdx(&w);
542541 if (reg1 < 0)
543- jitCompA0001_movReg32EbpDisp(&w, reg2, src[7] * 4); /* MOV(reg2, [EBP+?]); */
542+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg2, src[7] * 4); /* MOV(reg2, [EBP+?]); */
544543 if (reg1 >= 0 && reg1 != reg2) {
545544 jitCompPutByte2(w.dst, 0x89, 0xc0 | reg1 << 3 | reg2); /* MOV(reg2, reg1); */
546545 }
@@ -552,11 +551,11 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
552551 padd1:
553552 #endif
554553 if (reg0 == IA32_REG0_EAX)
555- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 0, reg0); /* MOV([EBP+?], reg0); */
554+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 0, reg0); /* MOV([EBP+?], reg0); */
556555 if (src[1] != src[6]) {
557556 for (i = 4; i < 32; i += 4) {
558- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + src[6] * 32 + i); /* MOV(EAX, [EBP+?]); */
559- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + i, 0 /* EAX */); /* MOV([EBP+?], EAX); */
557+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + src[6] * 32 + i); /* MOV(EAX, [EBP+?]); */
558+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + i, 0 /* EAX */); /* MOV([EBP+?], EAX); */
560559 }
561560 }
562561 cmp0reg = -1;
@@ -566,9 +565,9 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
566565 reg0 = jitCompA000_selectRegCache(src[1], IA32_REG0_EAX);
567566 jitCompA000_storePRegCacheAll(&w); // 手抜き.
568567 jitCompA0001_checkCompPtr(&w, src[6], src[7]);
569- jitCompA0001_movReg32EbpDisp(&w, reg0, 256 + src[6] * 32 + 0); /* MOV(reg0, [EBP+?]); */
568+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg0, 256 + src[6] * 32 + 0); /* MOV(reg0, [EBP+?]); */
570569 jitCompPutByte1(w.dst, 0x2b); /* SUB(EAX, [EBP+?]); */
571- jitCompA0001_85DispN(&w, 256 + src[7] * 32 + 0, reg0);
570+ jitCompPutModRM_Disp_BaseEBP(&w, 256 + src[7] * 32 + 0, reg0);
572571 i = jitCompA000_convTyp(jitCompGetImm32(src + 2));
573572 j = -1;
574573 if (0x0002 <= i && i <= 0x0007)
@@ -600,14 +599,14 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
600599 jitCompPutByte1(w.dst, 0xb8 | reg0); /* MOV(reg0, ?); */
601600 jitCompPutImm32(w.dst, w.r3f);
602601 jitCompPutByte1(w.dst, 0x2b);
603- jitCompA0001_85DispN(&w, src[3] * 4, reg0);
602+ jitCompPutModRM_Disp_BaseEBP(&w, src[3] * 4, reg0);
604603 if (reg0 == 0)
605604 jitCompA0001_movRxxEax(&w, src[1]);
606605 break;
607606 }
608607 #endif
609608 if (reg1 < 0) {
610- jitCompA0001_movReg32EbpDisp(&w, reg0, src[2] * 4); /* MOV(reg0, [EBP+?]); */
609+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg0, src[2] * 4); /* MOV(reg0, [EBP+?]); */
611610 }
612611 if (reg1 >= 0 && reg0 != reg1) {
613612 jitCompPutByte2(w.dst, 0x89, 0xc0 | reg1 << 3 | reg0); /* MOV(reg0, reg1); */
@@ -688,7 +687,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
688687 else {
689688 static unsigned char basic_op_table_rm[] = { 0x0b, 0x33, 0x23, 0, 0x03, 0x2b, 0xaf }; /* op(reg,mem); */
690689 jitCompPutByte1(w.dst, basic_op_table_rm[*src - 0x10]);
691- jitCompA0001_85DispN(&w, src[3] * 4, reg0);
690+ jitCompPutModRM_Disp_BaseEBP(&w, src[3] * 4, reg0);
692691 }
693692 }
694693 else {
@@ -697,7 +696,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
697696 }
698697 else {
699698 jitCompPutByte2(w.dst, 0x0f, 0xaf);
700- jitCompA0001_85DispN(&w, src[3] * 4, reg0);
699+ jitCompPutModRM_Disp_BaseEBP(&w, src[3] * 4, reg0);
701700 }
702701 }
703702 }
@@ -715,7 +714,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
715714 reg1 = jitCompA000_selectRegCache(src[2], -1 /* mem */);
716715 if (src[1] >= 0x3f) w.err = JITC_ERR_REGNUM;
717716 if (reg1 == -1)
718- jitCompA0001_movReg32EbpDisp(&w, reg0, src[2] * 4); /* MOV(reg1, [EBP+?]); */
717+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg0, src[2] * 4); /* MOV(reg1, [EBP+?]); */
719718 else {
720719 if (reg0 != reg1) {
721720 jitCompPutByte2(w.dst, 0x89, 0xc0 | reg1 << 3 | reg0); /* MOV(reg0, reg1); */
@@ -731,7 +730,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
731730 }
732731 #endif
733732 jitCompA000_storeRegCacheAll(&w); // 手抜き.
734- jitCompA0001_movReg32EbpDisp(&w, IA32_REG1_ECX, src[3] * 4); /* MOV(ECX, [EBP+?]); */
733+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG1_ECX, src[3] * 4); /* MOV(ECX, [EBP+?]); */
735734 #if (jitCompA0001_USE_R3F_IMM32 != 0)
736735 if (src[2] == 0x3f) {
737736 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
@@ -763,24 +762,24 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
763762 jitCompPutImm32(w.dst, w.r3f);
764763 }
765764 else {
766- jitCompA0001_movReg32EbpDisp(&w, IA32_REG1_ECX, src[3] * 4); /* MOV(ECX, [EBP+?]); */
765+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG1_ECX, src[3] * 4); /* MOV(ECX, [EBP+?]); */
767766 }
768767 if (src[2] == 0x3f) {
769768 jitCompPutByte1(w.dst, 0xb8 | 0); /* MOV(EAX, ?); */
770769 jitCompPutImm32(w.dst, w.r3f);
771770 }
772771 else {
773- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, src[2] * 4); /* MOV(EAX, [EBP+?]); */
772+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, src[2] * 4); /* MOV(EAX, [EBP+?]); */
774773 }
775774 #else
776- jitCompA0001_movReg32EbpDisp(&w, IA32_REG1_ECX, src[3] * 4); /* MOV(ECX, [EBP+?]); */
777- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, src[2] * 4); /* MOV(EAX, [EBP+?]); */
775+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG1_ECX, src[3] * 4); /* MOV(ECX, [EBP+?]); */
776+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, src[2] * 4); /* MOV(EAX, [EBP+?]); */
778777 #endif
779778 jitCompPutByte1(w.dst, 0x99); /* CDQ(); */
780779 /* ECXがゼロではないことを確認すべき */
781780 jitCompPutByte2(w.dst, 0xf7, 0xf9); /* IDIV(ECX); */
782- if (*src == 0x1a) { jitCompA0001_movEbpDispReg32(&w, src[1] * 4, IA32_REG0_EAX); }
783- if (*src == 0x1b) { jitCompA0001_movEbpDispReg32(&w, src[1] * 4, IA32_REG2_EDX); }
781+ if (*src == 0x1a) { jitCompPutOp_MOV_EBPDisp_GReg(&w, src[1] * 4, IA32_REG0_EAX); }
782+ if (*src == 0x1b) { jitCompPutOp_MOV_EBPDisp_GReg(&w, src[1] * 4, IA32_REG2_EDX); }
784783 jitCompA000_loadRegCacheAll(&w); // 手抜き.
785784 cmp0reg = -1;
786785 break;
@@ -807,14 +806,14 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
807806 /* src[2] == 0xff の場合に対応できてない */
808807 jitCompA000_storePRegCacheAll(&w); // 手抜き.
809808 for (i = 0; i < 32; i += 4) {
810- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + src[2] * 32 + i); /* MOV(EAX, [EBP+?]); */
811- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
809+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + src[2] * 32 + i); /* MOV(EAX, [EBP+?]); */
810+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
812811 }
813812 jitCompA000_loadPRegCacheAll(&w); // 手抜き.
814813 }
815814 else {
816815 if (level < JITC_LV_FASTER) {
817- jitCompA0001_movReg32EbpDisp(&w, 0 /* EAX */, 256 + src[2] * 32 + 4); /* MOV(EAX, [EBP+?]); */ /* typ */
816+ jitCompPutOp_MOV_GReg_EBPDisp(&w, 0 /* EAX */, 256 + src[2] * 32 + 4); /* MOV(EAX, [EBP+?]); */ /* typ */
818817 jitCompPutByte3(w.dst, 0x83, 0xf8, 0); /* CMP(EAX, 0); */
819818 jitCompPutByte2(w.dst, 0x0f, 0x85); /* JNE */
820819 jitCompPutImm32(w.dst, errfnc - (w.dst + 4));
@@ -822,10 +821,10 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
822821 }
823822 reg0 = IA32_REG0_EAX;
824823 jitCompA000_storePRegCacheAll(&w); // 手抜き.
825- jitCompA0001_movReg32EbpDisp(&w, reg0, 256 + src[2] * 32 + 0); /* MOV(EAX, [EBP+?]); */
824+ jitCompPutOp_MOV_GReg_EBPDisp(&w, reg0, 256 + src[2] * 32 + 0); /* MOV(EAX, [EBP+?]); */
826825 if (level < JITC_LV_FASTER) {
827826 jitCompPutByte1(w.dst, 0x3b); /* CMP(reg0, [EBP+?]); */
828- jitCompA0001_85DispN(&w, 256 + src[2] * 32 + 8, reg0); /* p0 */
827+ jitCompPutModRM_Disp_BaseEBP(&w, 256 + src[2] * 32 + 8, reg0); /* p0 */
829828 jitCompPutByte2(w.dst, 0x0f, 0x85); /* JNE */
830829 jitCompPutImm32(w.dst, errfnc - (w.dst + 4));
831830 }
@@ -839,16 +838,16 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
839838 jitCompA0001_checkType0(&w, src[6], jitCompGetImm32(src + 7), 2);
840839 jitCompA000_storePRegCacheAll(&w); // 手抜き.
841840 for (i = 0; i < 32 - 4; i += 4) {
842- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + src[6] * 32 + i); /* MOV(EAX, [EBP+?]); */
841+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + src[6] * 32 + i); /* MOV(EAX, [EBP+?]); */
843842 if (i == 4) {
844843 jitCompPutByte1(w.dst, 0x0d); /* OR(EAX, ?); */
845844 jitCompPutImm32(w.dst, 0x80000000);
846845 }
847- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
846+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
848847 }
849848 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
850849 jitCompPutImm32(w.dst, debugInfo1);
851- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 28, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
850+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 28, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
852851 jitCompA000_loadPRegCacheAll(&w); // 手抜き.
853852 cmp0reg = -1;
854853 break;
@@ -856,20 +855,20 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
856855 if (jitCompGetImm32(src + 7) == 0) {
857856 jitCompA000_storePRegCacheAll(&w); // 手抜き.
858857 for (i = 0; i < 32 - 4; i += 4) {
859- jitCompA0001_movReg32EbpDisp(&w, 0 /* EAX */, 256 + src[6] * 32 + i); /* MOV(EAX, [EBP+?]); */
858+ jitCompPutOp_MOV_GReg_EBPDisp(&w, 0 /* EAX */, 256 + src[6] * 32 + i); /* MOV(EAX, [EBP+?]); */
860859 if (i == 4) {
861860 jitCompPutByte1(w.dst, 0x25); /* AND(EAX, ?); */
862861 jitCompPutImm32(w.dst, 0x7fffffff);
863862 }
864- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
863+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + i, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
865864 }
866865 if (level < JITC_LV_FASTER) {
867- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + src[6] * 32 + 28); /* MOV(EAX, [EBP+?]); */
866+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + src[6] * 32 + 28); /* MOV(EAX, [EBP+?]); */
868867 jitCompPutByte1(w.dst, 0x3d); /* CMP(EAX, ?); */
869868 jitCompPutImm32(w.dst, debugInfo1);
870869 jitCompPutByte2(w.dst, 0x74, 8); /* JE */
871870 jitCompPutByte2(w.dst, 0x31, 0xc0); /* XOR(EAX, EAX); (2) */
872- jitCompA0001_movEbpDispReg32(&w, 256 + src[1] * 32 + 0, IA32_REG0_EAX); /* MOV([EBP+?], EAX); (1+1+4) */
871+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 256 + src[1] * 32 + 0, IA32_REG0_EAX); /* MOV([EBP+?], EAX); (1+1+4) */
873872 }
874873 jitCompA000_loadPRegCacheAll(&w); // 手抜き.
875874 cmp0reg = -1;
@@ -942,7 +941,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
942941 else {
943942 if (*src <= 0x25) { jitCompPutByte1(w.dst, 0x3b); }
944943 if (*src >= 0x26) { jitCompPutByte1(w.dst, 0x85); }
945- jitCompA0001_85DispN(&w, src[3] * 4, reg0);
944+ jitCompPutModRM_Disp_BaseEBP(&w, src[3] * 4, reg0);
946945 }
947946 cmpcc1:
948947 if (w.err != 0) goto err_w;
@@ -1004,10 +1003,10 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
10041003 jitCompA000_storePRegCacheAll(&w); // 手抜き.
10051004 if (src[3] != 0xff)
10061005 jitCompA0001_checkCompPtr(&w, src[2], src[3]);
1007- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + src[2] * 32 + 0); /* MOV(EAX, [EBP+?]); */
1006+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + src[2] * 32 + 0); /* MOV(EAX, [EBP+?]); */
10081007 if (src[3] != 0xff) {
10091008 jitCompPutByte1(w.dst, 0x3b); /* CMP(EAX, [EBP+?]); */
1010- jitCompA0001_85DispN(&w, 256 + src[3] * 32 + 0, 0);
1009+ jitCompPutModRM_Disp_BaseEBP(&w, 256 + src[3] * 32 + 0, 0);
10111010 }
10121011 else {
10131012 /* ヌルポインタとの比較はこれでいいのか?たぶんよくない */
@@ -1153,14 +1152,14 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
11531152 if (level <= JITC_LV_SLOWER) {
11541153 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
11551154 jitCompPutImm32(w.dst, debugInfo1);
1156- jitCompA0001_movEbpDispReg32(&w, 2304 + 4, IA32_REG0_EAX); /* MOV(debugInfo1, EAX); */
1155+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 2304 + 4, IA32_REG0_EAX); /* MOV(debugInfo1, EAX); */
11571156 }
11581157 }
11591158 if (src[1] == 0x01 && src[2] == 0x03) { // DBGINFO1CLR
11601159 if (level <= JITC_LV_SLOWER) {
11611160 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
11621161 jitCompPutImm32(w.dst, -1);
1163- jitCompA0001_movEbpDispReg32(&w, 2304 + 4, IA32_REG0_EAX); /* MOV(debugInfo1, EAX); */
1162+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 2304 + 4, IA32_REG0_EAX); /* MOV(debugInfo1, EAX); */
11641163 }
11651164 }
11661165 if (src[1] == 0x05 && src[2] == 0x00) { // DBGINFO0
@@ -1170,7 +1169,7 @@ int jitCompiler(unsigned char *dst, unsigned char *dst1, const unsigned char *sr
11701169 // jitCompPutImm32(&w, debugInfo0);
11711170 jitCompPutByte1(w.dst, 0xb8); /* MOV(EAX, ?); */
11721171 jitCompPutImm32(w.dst, debugInfo0);
1173- jitCompA0001_movEbpDispReg32(&w, 2304 + 0, IA32_REG0_EAX); /* MOV(debugInfo0, EAX); */
1172+ jitCompPutOp_MOV_EBPDisp_GReg(&w, 2304 + 0, IA32_REG0_EAX); /* MOV(debugInfo0, EAX); */
11741173 }
11751174 }
11761175 break;
@@ -1256,7 +1255,7 @@ unsigned char *jitCompCallFunc(unsigned char *dst, void *func)
12561255 jitCompPutOp_POPAD(w.dst);
12571256 jitCompA000_loadRegCacheAll(&w);
12581257 jitCompA000_loadPRegCacheAll(&w);
1259- jitCompA0001_movReg32EbpDisp(&w, IA32_REG0_EAX, 256 + 0x30 * 32 + 0); /* MOV(EAX, [EBP+?]); */
1258+ jitCompPutOp_MOV_GReg_EBPDisp(&w, IA32_REG0_EAX, 256 + 0x30 * 32 + 0); /* MOV(EAX, [EBP+?]); */
12601259 jitCompPutByte2(w.dst, 0xff, 0xe0); /* JMP(EAX); */
12611260 return w.dst;
12621261 }
--- a/jitcx86a.c
+++ b/jitcx86a.c
@@ -20,32 +20,39 @@ int jitCompGetLabelNum(struct JitCompWork *w, const unsigned char *src)
2020 return i;
2121 }
2222
23-void jitCompA0001_85DispN(struct JitCompWork *w, int disp, int n)
23+void jitCompPutModRM_Disp_BaseEBP(struct JitCompWork *w, int disp, int opReg)
2424 {
25+ // EBPをベースとするアドレスオペランドとレジスタオペランドを出力する
2526 disp -= jitCompA0001_EBP128;
2627 if (-128 <= disp && disp <= 127) {
27- jitCompPutByte2(w->dst, 0x45 | (n << 3), disp & 0xff);
28+ // [EBP + Disp08]
29+ jitCompPutByte1(w->dst, IA32_MOD_R_M(IA32_OP_MOD_INDEX_AND_DISP_BYTE, opReg, IA32_REG5_EBP));
30+ jitCompPutByte1(w->dst, disp & 0xff);
2831 } else {
29- // 10 + reg + 101 + disp
30- jitCompPutByte1(w->dst, 0x85 | (n << 3));
32+ // [EBP + Disp32]
33+ jitCompPutByte1(w->dst, IA32_MOD_R_M(IA32_OP_MOD_INDEX_AND_DISP_FULL, opReg, IA32_REG5_EBP));
3134 jitCompPutImm32(w->dst, disp);
3235 }
3336 return;
3437 }
3538
36-void jitCompA0001_movEbpDispReg32(struct JitCompWork *w, int disp, int reg32)
39+void jitCompPutOp_MOV_EBPDisp_GReg(struct JitCompWork *w, int disp, int reg32)
3740 {
41+ // MOV([EBP + disp] <- reg32);
3842 // MOV Ev, Gv
39- // MOV + ModR/M(2Mod + 3Reg + 3R/M)
40- jitCompPutByte1(w->dst, 0x89); /* 1000 1001 MOV(mem, reg32); */
41- jitCompA0001_85DispN(w, disp, reg32);
43+ // [1000 100 1] [mod reg r/m]
44+ jitCompPutByte1(w->dst, 0x89);
45+ jitCompPutModRM_Disp_BaseEBP(w, disp, reg32);
4246 return;
4347 }
4448
45-void jitCompA0001_movReg32EbpDisp(struct JitCompWork *w, int reg32, int disp)
49+void jitCompPutOp_MOV_GReg_EBPDisp(struct JitCompWork *w, int reg32, int disp)
4650 {
47- jitCompPutByte1(w->dst, 0x8b); /* MOV(reg32, mem); */
48- jitCompA0001_85DispN(w, disp, reg32);
51+ // MOV (reg32 <- [EBP + disp])
52+ // MOV Gv, Ev
53+ // [1000 101 1] [mod reg r/m]
54+ jitCompPutByte1(w->dst, 0x8b);
55+ jitCompPutModRM_Disp_BaseEBP(w, disp, reg32);
4956 return;
5057 }
5158
@@ -61,7 +68,7 @@ void jitCompA0001_movEaxRxx(struct JitCompWork *w, int rxx)
6168 if (rxx >= 0x40 || rxx < 0){
6269 w->err = JITC_ERR_REGNUM;
6370 }
64- jitCompA0001_movReg32EbpDisp(w, IA32_REG0_EAX, rxx * 4); /* MOV(EAX, [EBP+?]); */
71+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG0_EAX, rxx * 4);
6572 return;
6673 }
6774
@@ -70,7 +77,7 @@ void jitCompA0001_movRxxEax(struct JitCompWork *w, int rxx)
7077 if (rxx >= 0x40 || rxx < 0){
7178 w->err = JITC_ERR_REGNUM;
7279 }
73- jitCompA0001_movEbpDispReg32(w, rxx * 4, IA32_REG0_EAX); /* MOV([EBP+?], EAX); */
80+ jitCompPutOp_MOV_EBPDisp_GReg(w, rxx * 4, IA32_REG0_EAX);
7481 return;
7582 }
7683
@@ -99,58 +106,59 @@ void jitCompA0001_checkCompPtr(struct JitCompWork *w, int p0, int p1)
99106
100107 void jitCompA000_loadRegCacheAll(struct JitCompWork *w)
101108 {
102- jitCompA0001_movReg32EbpDisp(w, 3 /* EBX */, 0 * 4); /* EBX = R00; */
103- jitCompA0001_movReg32EbpDisp(w, 1 /* ECX */, 1 * 4); /* ECX = R01; */
104- jitCompA0001_movReg32EbpDisp(w, 2 /* EDX */, 2 * 4); /* EDX = R02; */
109+ //保存されたレジスタキャッシュをメモリからロード
110+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG3_EBX, 4 * 0); /* EBX = R00; */
111+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG1_ECX, 4 * 1); /* ECX = R01; */
112+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG2_EDX, 4 * 2); /* EDX = R02; */
105113 return;
106114 }
107115
108116 void jitCompA000_storeRegCacheAll(struct JitCompWork *w)
109117 {
110- jitCompA0001_movEbpDispReg32(w, 0 * 4, 3 /* EBX */); /* R00 = EBX; */
111- jitCompA0001_movEbpDispReg32(w, 1 * 4, 1 /* ECX */); /* R01 = ECX; */
112- jitCompA0001_movEbpDispReg32(w, 2 * 4, 2 /* EDX */); /* R02 = EDX; */
118+ //レジスタキャッシュをメモリに退避
119+ jitCompPutOp_MOV_EBPDisp_GReg(w, 0 * 4, IA32_REG3_EBX); /* R00 = EBX; */
120+ jitCompPutOp_MOV_EBPDisp_GReg(w, 1 * 4, IA32_REG1_ECX); /* R01 = ECX; */
121+ jitCompPutOp_MOV_EBPDisp_GReg(w, 2 * 4, IA32_REG2_EDX); /* R02 = EDX; */
113122 return;
114123 }
115124
116125 void jitCompA000_loadRegCacheEcx(struct JitCompWork *w)
117126 {
118- jitCompA0001_movReg32EbpDisp(w, 1 /* ECX */, 1 * 4); /* ECX = R01; */
127+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG1_ECX, 1 * 4); /* ECX = R01; */
119128 return;
120129 }
121130
122131 void jitCompA000_storeRegCacheEcx(struct JitCompWork *w)
123132 {
124- jitCompA0001_movEbpDispReg32(w, 1 * 4, 1 /* ECX */); /* R01 = ECX; */
133+ jitCompPutOp_MOV_EBPDisp_GReg(w, 1 * 4, IA32_REG1_ECX); /* R01 = ECX; */
125134 return;
126135 }
127136
128137 void jitCompA000_loadRegCacheEdx(struct JitCompWork *w)
129138 {
130- jitCompA0001_movReg32EbpDisp(w, 2 /* EDX */, 2 * 4); /* EDX = R02; */
139+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG2_EDX, 2 * 4); /* EDX = R02; */
131140 return;
132141 }
133142
134143 void jitCompA000_storeRegCacheEdx(struct JitCompWork *w)
135144 {
136- jitCompA0001_movEbpDispReg32(w, 2 * 4, 2 /* EDX */); /* R02 = EDX; */
145+ jitCompPutOp_MOV_EBPDisp_GReg(w, 2 * 4, IA32_REG2_EDX); /* R02 = EDX; */
137146 return;
138147 }
139148
140149 int jitCompA000_selectRegCache(int rxx, int reg)
141150 {
151+ // OSECPUレジスタ番号をIA32レジスタ番号へ変換
152+ // 対応するキャッシュレジスタがない場合regが返る
142153 switch (rxx) {
143154 case 0:
144- //EBX
145- reg = 3;
155+ reg = IA32_REG3_EBX;
146156 break;
147157 case 1:
148- //ECX
149- reg = 1;
158+ reg = IA32_REG1_ECX;
150159 break;
151160 case 2:
152- //EDX
153- reg = 2;
161+ reg = IA32_REG2_EDX;
154162 break;
155163 }
156164 return reg;
@@ -158,17 +166,17 @@ int jitCompA000_selectRegCache(int rxx, int reg)
158166
159167 void jitCompA000_loadPRegCacheAll(struct JitCompWork *w)
160168 {
161- // jitCompA0001_movReg32EbpDisp(w, 5 /* EBP */, 256 + 0 * 32 + 0); /* EBP = P00; */
162- jitCompA0001_movReg32EbpDisp(w, 6 /* ESI */, 256 + 1 * 32 + 0); /* ESI = P01; */
163- jitCompA0001_movReg32EbpDisp(w, 7 /* EDI */, 256 + 2 * 32 + 0); /* EDI = P02; */
169+ // jitCompPutOp_MOV_GReg_EBPDisp(w, 5 /* EBP */, 256 + 0 * 32 + 0); /* EBP = P00; */
170+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG6_ESI, 256 + 1 * 32 + 0); /* ESI = P01; */
171+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG7_EDI, 256 + 2 * 32 + 0); /* EDI = P02; */
164172 return;
165173 }
166174
167175 void jitCompA000_storePRegCacheAll(struct JitCompWork *w)
168176 {
169- // jitCompA0001_movEbpDispReg32(w, 256 + 0 * 32 + 0, 5 /* EBP */); /* P00 = EBP; */
170- jitCompA0001_movEbpDispReg32(w, 256 + 1 * 32 + 0, 6 /* ESI */); /* P01 = ESI; */
171- jitCompA0001_movEbpDispReg32(w, 256 + 2 * 32 + 0, 7 /* EDI */); /* P02 = EDI; */
177+ // jitCompPutOp_MOV_EBPDisp_GReg(w, 256 + 0 * 32 + 0, 5 /* EBP */); /* P00 = EBP; */
178+ jitCompPutOp_MOV_EBPDisp_GReg(w, 256 + 1 * 32 + 0, IA32_REG6_ESI); /* P01 = ESI; */
179+ jitCompPutOp_MOV_EBPDisp_GReg(w, 256 + 2 * 32 + 0, IA32_REG7_EDI); /* P02 = EDI; */
172180 return;
173181 }
174182
@@ -229,7 +237,7 @@ void jitCompA0001_checkType0(struct JitCompWork *w, int pxx, int typ, int ac)
229237 {
230238 if (typ <= 0) { w->err = JITC_ERR_BADTYPE; }
231239 if (typ > 0x7f) { w->err = JITC_ERR_INTERNAL; }
232- jitCompA0001_movReg32EbpDisp(w, 0 /* EAX */, 256 + pxx * 32 + 4); /* MOV(EAX, [EBP+?]); */ /* typ */
240+ jitCompPutOp_MOV_GReg_EBPDisp(w, IA32_REG0_EAX, 256 + pxx * 32 + 4); /* MOV(EAX, [EBP+?]); */ /* typ */
233241 jitCompPutByte3(w->dst, 0x83, 0xf8, typ & 0x7f); /* CMP(EAX, ?); */
234242 jitCompPutByte2(w->dst, 0x0f, 0x85); /* JNE */
235243 jitCompPutImm32(w->dst, errfnc - (w->dst + 4));
@@ -237,9 +245,9 @@ void jitCompA0001_checkType0(struct JitCompWork *w, int pxx, int typ, int ac)
237245 }
238246
239247 void jitCompA0001_checkType(struct JitCompWork *w, int pxx, int typ, int ac)
240-// data用.
241-// 将来的にはaliveやアクセス権チェックも入れる
242248 {
249+ // data用.
250+ // 将来的にはaliveやアクセス権チェックも入れる
243251 jitCompA0001_checkType0(w, pxx, typ, ac);
244252 return;
245253 }
@@ -247,11 +255,11 @@ void jitCompA0001_checkType(struct JitCompWork *w, int pxx, int typ, int ac)
247255 void jitCompA0001_checkLimit(struct JitCompWork *w, int reg, int pxx)
248256 {
249257 jitCompPutByte1(w->dst, 0x3b); /* CMP(reg, [EBP+?]); */
250- jitCompA0001_85DispN(w, 256 + pxx * 32 + 8, reg); /* p0 */
258+ jitCompPutModRM_Disp_BaseEBP(w, 256 + pxx * 32 + 8, reg); /* p0 */
251259 jitCompPutByte2(w->dst, 0x0f, 0x82); /* JB */
252260 jitCompPutImm32(w->dst, errfnc - (w->dst + 4));
253261 jitCompPutByte1(w->dst, 0x3b); /* CMP(reg, [EBP+?]); */
254- jitCompA0001_85DispN(w, 256 + pxx * 32 + 12, reg); /* p1 */
262+ jitCompPutModRM_Disp_BaseEBP(w, 256 + pxx * 32 + 12, reg); /* p1 */
255263 jitCompPutByte2(w->dst, 0x0f, 0x83); /* JAE */
256264 jitCompPutImm32(w->dst, errfnc - (w->dst + 4));
257265 return;
旧リポジトリブラウザで表示