Lines Matching refs:Xin
567 i->Xin.Alu32R.op = op; in X86Instr_Alu32R()
568 i->Xin.Alu32R.src = src; in X86Instr_Alu32R()
569 i->Xin.Alu32R.dst = dst; in X86Instr_Alu32R()
575 i->Xin.Alu32M.op = op; in X86Instr_Alu32M()
576 i->Xin.Alu32M.src = src; in X86Instr_Alu32M()
577 i->Xin.Alu32M.dst = dst; in X86Instr_Alu32M()
584 i->Xin.Sh32.op = op; in X86Instr_Sh32()
585 i->Xin.Sh32.src = src; in X86Instr_Sh32()
586 i->Xin.Sh32.dst = dst; in X86Instr_Sh32()
592 i->Xin.Test32.imm32 = imm32; in X86Instr_Test32()
593 i->Xin.Test32.dst = dst; in X86Instr_Test32()
599 i->Xin.Unary32.op = op; in X86Instr_Unary32()
600 i->Xin.Unary32.dst = dst; in X86Instr_Unary32()
606 i->Xin.Lea32.am = am; in X86Instr_Lea32()
607 i->Xin.Lea32.dst = dst; in X86Instr_Lea32()
613 i->Xin.MulL.syned = syned; in X86Instr_MulL()
614 i->Xin.MulL.src = src; in X86Instr_MulL()
620 i->Xin.Div.syned = syned; in X86Instr_Div()
621 i->Xin.Div.src = src; in X86Instr_Div()
627 i->Xin.Sh3232.op = op; in X86Instr_Sh3232()
628 i->Xin.Sh3232.amt = amt; in X86Instr_Sh3232()
629 i->Xin.Sh3232.src = src; in X86Instr_Sh3232()
630 i->Xin.Sh3232.dst = dst; in X86Instr_Sh3232()
637 i->Xin.Push.src = src; in X86Instr_Push()
644 i->Xin.Call.cond = cond; in X86Instr_Call()
645 i->Xin.Call.target = target; in X86Instr_Call()
646 i->Xin.Call.regparms = regparms; in X86Instr_Call()
647 i->Xin.Call.rloc = rloc; in X86Instr_Call()
656 i->Xin.XDirect.dstGA = dstGA; in X86Instr_XDirect()
657 i->Xin.XDirect.amEIP = amEIP; in X86Instr_XDirect()
658 i->Xin.XDirect.cond = cond; in X86Instr_XDirect()
659 i->Xin.XDirect.toFastEP = toFastEP; in X86Instr_XDirect()
666 i->Xin.XIndir.dstGA = dstGA; in X86Instr_XIndir()
667 i->Xin.XIndir.amEIP = amEIP; in X86Instr_XIndir()
668 i->Xin.XIndir.cond = cond; in X86Instr_XIndir()
675 i->Xin.XAssisted.dstGA = dstGA; in X86Instr_XAssisted()
676 i->Xin.XAssisted.amEIP = amEIP; in X86Instr_XAssisted()
677 i->Xin.XAssisted.cond = cond; in X86Instr_XAssisted()
678 i->Xin.XAssisted.jk = jk; in X86Instr_XAssisted()
684 i->Xin.CMov32.cond = cond; in X86Instr_CMov32()
685 i->Xin.CMov32.src = src; in X86Instr_CMov32()
686 i->Xin.CMov32.dst = dst; in X86Instr_CMov32()
694 i->Xin.LoadEX.szSmall = szSmall; in X86Instr_LoadEX()
695 i->Xin.LoadEX.syned = syned; in X86Instr_LoadEX()
696 i->Xin.LoadEX.src = src; in X86Instr_LoadEX()
697 i->Xin.LoadEX.dst = dst; in X86Instr_LoadEX()
704 i->Xin.Store.sz = sz; in X86Instr_Store()
705 i->Xin.Store.src = src; in X86Instr_Store()
706 i->Xin.Store.dst = dst; in X86Instr_Store()
713 i->Xin.Set32.cond = cond; in X86Instr_Set32()
714 i->Xin.Set32.dst = dst; in X86Instr_Set32()
720 i->Xin.Bsfr32.isFwds = isFwds; in X86Instr_Bsfr32()
721 i->Xin.Bsfr32.src = src; in X86Instr_Bsfr32()
722 i->Xin.Bsfr32.dst = dst; in X86Instr_Bsfr32()
728 i->Xin.MFence.hwcaps = hwcaps; in X86Instr_MFence()
739 i->Xin.ACAS.addr = addr; in X86Instr_ACAS()
740 i->Xin.ACAS.sz = sz; in X86Instr_ACAS()
747 i->Xin.DACAS.addr = addr; in X86Instr_DACAS()
754 i->Xin.FpUnary.op = op; in X86Instr_FpUnary()
755 i->Xin.FpUnary.src = src; in X86Instr_FpUnary()
756 i->Xin.FpUnary.dst = dst; in X86Instr_FpUnary()
762 i->Xin.FpBinary.op = op; in X86Instr_FpBinary()
763 i->Xin.FpBinary.srcL = srcL; in X86Instr_FpBinary()
764 i->Xin.FpBinary.srcR = srcR; in X86Instr_FpBinary()
765 i->Xin.FpBinary.dst = dst; in X86Instr_FpBinary()
771 i->Xin.FpLdSt.isLoad = isLoad; in X86Instr_FpLdSt()
772 i->Xin.FpLdSt.sz = sz; in X86Instr_FpLdSt()
773 i->Xin.FpLdSt.reg = reg; in X86Instr_FpLdSt()
774 i->Xin.FpLdSt.addr = addr; in X86Instr_FpLdSt()
782 i->Xin.FpLdStI.isLoad = isLoad; in X86Instr_FpLdStI()
783 i->Xin.FpLdStI.sz = sz; in X86Instr_FpLdStI()
784 i->Xin.FpLdStI.reg = reg; in X86Instr_FpLdStI()
785 i->Xin.FpLdStI.addr = addr; in X86Instr_FpLdStI()
792 i->Xin.Fp64to32.src = src; in X86Instr_Fp64to32()
793 i->Xin.Fp64to32.dst = dst; in X86Instr_Fp64to32()
799 i->Xin.FpCMov.cond = cond; in X86Instr_FpCMov()
800 i->Xin.FpCMov.src = src; in X86Instr_FpCMov()
801 i->Xin.FpCMov.dst = dst; in X86Instr_FpCMov()
808 i->Xin.FpLdCW.addr = addr; in X86Instr_FpLdCW()
819 i->Xin.FpCmp.srcL = srcL; in X86Instr_FpCmp()
820 i->Xin.FpCmp.srcR = srcR; in X86Instr_FpCmp()
821 i->Xin.FpCmp.dst = dst; in X86Instr_FpCmp()
827 i->Xin.SseConst.con = con; in X86Instr_SseConst()
828 i->Xin.SseConst.dst = dst; in X86Instr_SseConst()
835 i->Xin.SseLdSt.isLoad = isLoad; in X86Instr_SseLdSt()
836 i->Xin.SseLdSt.reg = reg; in X86Instr_SseLdSt()
837 i->Xin.SseLdSt.addr = addr; in X86Instr_SseLdSt()
844 i->Xin.SseLdzLO.sz = toUChar(sz); in X86Instr_SseLdzLO()
845 i->Xin.SseLdzLO.reg = reg; in X86Instr_SseLdzLO()
846 i->Xin.SseLdzLO.addr = addr; in X86Instr_SseLdzLO()
853 i->Xin.Sse32Fx4.op = op; in X86Instr_Sse32Fx4()
854 i->Xin.Sse32Fx4.src = src; in X86Instr_Sse32Fx4()
855 i->Xin.Sse32Fx4.dst = dst; in X86Instr_Sse32Fx4()
862 i->Xin.Sse32FLo.op = op; in X86Instr_Sse32FLo()
863 i->Xin.Sse32FLo.src = src; in X86Instr_Sse32FLo()
864 i->Xin.Sse32FLo.dst = dst; in X86Instr_Sse32FLo()
871 i->Xin.Sse64Fx2.op = op; in X86Instr_Sse64Fx2()
872 i->Xin.Sse64Fx2.src = src; in X86Instr_Sse64Fx2()
873 i->Xin.Sse64Fx2.dst = dst; in X86Instr_Sse64Fx2()
880 i->Xin.Sse64FLo.op = op; in X86Instr_Sse64FLo()
881 i->Xin.Sse64FLo.src = src; in X86Instr_Sse64FLo()
882 i->Xin.Sse64FLo.dst = dst; in X86Instr_Sse64FLo()
889 i->Xin.SseReRg.op = op; in X86Instr_SseReRg()
890 i->Xin.SseReRg.src = re; in X86Instr_SseReRg()
891 i->Xin.SseReRg.dst = rg; in X86Instr_SseReRg()
897 i->Xin.SseCMov.cond = cond; in X86Instr_SseCMov()
898 i->Xin.SseCMov.src = src; in X86Instr_SseCMov()
899 i->Xin.SseCMov.dst = dst; in X86Instr_SseCMov()
906 i->Xin.SseShuf.order = order; in X86Instr_SseShuf()
907 i->Xin.SseShuf.src = src; in X86Instr_SseShuf()
908 i->Xin.SseShuf.dst = dst; in X86Instr_SseShuf()
916 i->Xin.EvCheck.amCounter = amCounter; in X86Instr_EvCheck()
917 i->Xin.EvCheck.amFailAddr = amFailAddr; in X86Instr_EvCheck()
930 vex_printf("%sl ", showX86AluOp(i->Xin.Alu32R.op)); in ppX86Instr()
931 ppX86RMI(i->Xin.Alu32R.src); in ppX86Instr()
933 ppHRegX86(i->Xin.Alu32R.dst); in ppX86Instr()
936 vex_printf("%sl ", showX86AluOp(i->Xin.Alu32M.op)); in ppX86Instr()
937 ppX86RI(i->Xin.Alu32M.src); in ppX86Instr()
939 ppX86AMode(i->Xin.Alu32M.dst); in ppX86Instr()
942 vex_printf("%sl ", showX86ShiftOp(i->Xin.Sh32.op)); in ppX86Instr()
943 if (i->Xin.Sh32.src == 0) in ppX86Instr()
946 vex_printf("$%d,", (Int)i->Xin.Sh32.src); in ppX86Instr()
947 ppHRegX86(i->Xin.Sh32.dst); in ppX86Instr()
950 vex_printf("testl $%d,", (Int)i->Xin.Test32.imm32); in ppX86Instr()
951 ppX86RM(i->Xin.Test32.dst); in ppX86Instr()
954 vex_printf("%sl ", showX86UnaryOp(i->Xin.Unary32.op)); in ppX86Instr()
955 ppHRegX86(i->Xin.Unary32.dst); in ppX86Instr()
959 ppX86AMode(i->Xin.Lea32.am); in ppX86Instr()
961 ppHRegX86(i->Xin.Lea32.dst); in ppX86Instr()
964 vex_printf("%cmull ", i->Xin.MulL.syned ? 's' : 'u'); in ppX86Instr()
965 ppX86RM(i->Xin.MulL.src); in ppX86Instr()
968 vex_printf("%cdivl ", i->Xin.Div.syned ? 's' : 'u'); in ppX86Instr()
969 ppX86RM(i->Xin.Div.src); in ppX86Instr()
972 vex_printf("%sdl ", showX86ShiftOp(i->Xin.Sh3232.op)); in ppX86Instr()
973 if (i->Xin.Sh3232.amt == 0) in ppX86Instr()
976 vex_printf(" $%d,", (Int)i->Xin.Sh3232.amt); in ppX86Instr()
977 ppHRegX86(i->Xin.Sh3232.src); in ppX86Instr()
979 ppHRegX86(i->Xin.Sh3232.dst); in ppX86Instr()
983 ppX86RMI(i->Xin.Push.src); in ppX86Instr()
987 i->Xin.Call.cond==Xcc_ALWAYS in ppX86Instr()
988 ? "" : showX86CondCode(i->Xin.Call.cond), in ppX86Instr()
989 i->Xin.Call.regparms); in ppX86Instr()
990 ppRetLoc(i->Xin.Call.rloc); in ppX86Instr()
991 vex_printf("] 0x%x", i->Xin.Call.target); in ppX86Instr()
996 showX86CondCode(i->Xin.XDirect.cond)); in ppX86Instr()
997 vex_printf("movl $0x%x,", i->Xin.XDirect.dstGA); in ppX86Instr()
998 ppX86AMode(i->Xin.XDirect.amEIP); in ppX86Instr()
1001 i->Xin.XDirect.toFastEP ? "fast" : "slow"); in ppX86Instr()
1006 showX86CondCode(i->Xin.XIndir.cond)); in ppX86Instr()
1007 ppHRegX86(i->Xin.XIndir.dstGA); in ppX86Instr()
1009 ppX86AMode(i->Xin.XIndir.amEIP); in ppX86Instr()
1015 showX86CondCode(i->Xin.XAssisted.cond)); in ppX86Instr()
1017 ppHRegX86(i->Xin.XAssisted.dstGA); in ppX86Instr()
1019 ppX86AMode(i->Xin.XAssisted.amEIP); in ppX86Instr()
1021 (Int)i->Xin.XAssisted.jk); in ppX86Instr()
1025 vex_printf("cmov%s ", showX86CondCode(i->Xin.CMov32.cond)); in ppX86Instr()
1026 ppX86RM(i->Xin.CMov32.src); in ppX86Instr()
1028 ppHRegX86(i->Xin.CMov32.dst); in ppX86Instr()
1032 i->Xin.LoadEX.syned ? 's' : 'z', in ppX86Instr()
1033 i->Xin.LoadEX.szSmall==1 ? 'b' : 'w'); in ppX86Instr()
1034 ppX86AMode(i->Xin.LoadEX.src); in ppX86Instr()
1036 ppHRegX86(i->Xin.LoadEX.dst); in ppX86Instr()
1039 vex_printf("mov%c ", i->Xin.Store.sz==1 ? 'b' : 'w'); in ppX86Instr()
1040 ppHRegX86(i->Xin.Store.src); in ppX86Instr()
1042 ppX86AMode(i->Xin.Store.dst); in ppX86Instr()
1045 vex_printf("setl%s ", showX86CondCode(i->Xin.Set32.cond)); in ppX86Instr()
1046 ppHRegX86(i->Xin.Set32.dst); in ppX86Instr()
1049 vex_printf("bs%cl ", i->Xin.Bsfr32.isFwds ? 'f' : 'r'); in ppX86Instr()
1050 ppHRegX86(i->Xin.Bsfr32.src); in ppX86Instr()
1052 ppHRegX86(i->Xin.Bsfr32.dst); in ppX86Instr()
1056 LibVEX_ppVexHwCaps(VexArchX86,i->Xin.MFence.hwcaps)); in ppX86Instr()
1060 i->Xin.ACAS.sz==1 ? 'b' in ppX86Instr()
1061 : i->Xin.ACAS.sz==2 ? 'w' : 'l'); in ppX86Instr()
1063 ppX86AMode(i->Xin.ACAS.addr); in ppX86Instr()
1067 ppX86AMode(i->Xin.DACAS.addr); in ppX86Instr()
1070 vex_printf("g%sD ", showX86FpOp(i->Xin.FpUnary.op)); in ppX86Instr()
1071 ppHRegX86(i->Xin.FpUnary.src); in ppX86Instr()
1073 ppHRegX86(i->Xin.FpUnary.dst); in ppX86Instr()
1076 vex_printf("g%sD ", showX86FpOp(i->Xin.FpBinary.op)); in ppX86Instr()
1077 ppHRegX86(i->Xin.FpBinary.srcL); in ppX86Instr()
1079 ppHRegX86(i->Xin.FpBinary.srcR); in ppX86Instr()
1081 ppHRegX86(i->Xin.FpBinary.dst); in ppX86Instr()
1084 if (i->Xin.FpLdSt.isLoad) { in ppX86Instr()
1085 vex_printf("gld%c " , i->Xin.FpLdSt.sz==10 ? 'T' in ppX86Instr()
1086 : (i->Xin.FpLdSt.sz==8 ? 'D' : 'F')); in ppX86Instr()
1087 ppX86AMode(i->Xin.FpLdSt.addr); in ppX86Instr()
1089 ppHRegX86(i->Xin.FpLdSt.reg); in ppX86Instr()
1091 vex_printf("gst%c " , i->Xin.FpLdSt.sz==10 ? 'T' in ppX86Instr()
1092 : (i->Xin.FpLdSt.sz==8 ? 'D' : 'F')); in ppX86Instr()
1093 ppHRegX86(i->Xin.FpLdSt.reg); in ppX86Instr()
1095 ppX86AMode(i->Xin.FpLdSt.addr); in ppX86Instr()
1099 if (i->Xin.FpLdStI.isLoad) { in ppX86Instr()
1100 vex_printf("gild%s ", i->Xin.FpLdStI.sz==8 ? "ll" : in ppX86Instr()
1101 i->Xin.FpLdStI.sz==4 ? "l" : "w"); in ppX86Instr()
1102 ppX86AMode(i->Xin.FpLdStI.addr); in ppX86Instr()
1104 ppHRegX86(i->Xin.FpLdStI.reg); in ppX86Instr()
1106 vex_printf("gist%s ", i->Xin.FpLdStI.sz==8 ? "ll" : in ppX86Instr()
1107 i->Xin.FpLdStI.sz==4 ? "l" : "w"); in ppX86Instr()
1108 ppHRegX86(i->Xin.FpLdStI.reg); in ppX86Instr()
1110 ppX86AMode(i->Xin.FpLdStI.addr); in ppX86Instr()
1115 ppHRegX86(i->Xin.Fp64to32.src); in ppX86Instr()
1117 ppHRegX86(i->Xin.Fp64to32.dst); in ppX86Instr()
1120 vex_printf("gcmov%s ", showX86CondCode(i->Xin.FpCMov.cond)); in ppX86Instr()
1121 ppHRegX86(i->Xin.FpCMov.src); in ppX86Instr()
1123 ppHRegX86(i->Xin.FpCMov.dst); in ppX86Instr()
1127 ppX86AMode(i->Xin.FpLdCW.addr); in ppX86Instr()
1134 ppHRegX86(i->Xin.FpCmp.srcL); in ppX86Instr()
1136 ppHRegX86(i->Xin.FpCmp.srcR); in ppX86Instr()
1138 ppHRegX86(i->Xin.FpCmp.dst); in ppX86Instr()
1141 vex_printf("const $0x%04x,", (Int)i->Xin.SseConst.con); in ppX86Instr()
1142 ppHRegX86(i->Xin.SseConst.dst); in ppX86Instr()
1146 if (i->Xin.SseLdSt.isLoad) { in ppX86Instr()
1147 ppX86AMode(i->Xin.SseLdSt.addr); in ppX86Instr()
1149 ppHRegX86(i->Xin.SseLdSt.reg); in ppX86Instr()
1151 ppHRegX86(i->Xin.SseLdSt.reg); in ppX86Instr()
1153 ppX86AMode(i->Xin.SseLdSt.addr); in ppX86Instr()
1157 vex_printf("movs%s ", i->Xin.SseLdzLO.sz==4 ? "s" : "d"); in ppX86Instr()
1158 ppX86AMode(i->Xin.SseLdzLO.addr); in ppX86Instr()
1160 ppHRegX86(i->Xin.SseLdzLO.reg); in ppX86Instr()
1163 vex_printf("%sps ", showX86SseOp(i->Xin.Sse32Fx4.op)); in ppX86Instr()
1164 ppHRegX86(i->Xin.Sse32Fx4.src); in ppX86Instr()
1166 ppHRegX86(i->Xin.Sse32Fx4.dst); in ppX86Instr()
1169 vex_printf("%sss ", showX86SseOp(i->Xin.Sse32FLo.op)); in ppX86Instr()
1170 ppHRegX86(i->Xin.Sse32FLo.src); in ppX86Instr()
1172 ppHRegX86(i->Xin.Sse32FLo.dst); in ppX86Instr()
1175 vex_printf("%spd ", showX86SseOp(i->Xin.Sse64Fx2.op)); in ppX86Instr()
1176 ppHRegX86(i->Xin.Sse64Fx2.src); in ppX86Instr()
1178 ppHRegX86(i->Xin.Sse64Fx2.dst); in ppX86Instr()
1181 vex_printf("%ssd ", showX86SseOp(i->Xin.Sse64FLo.op)); in ppX86Instr()
1182 ppHRegX86(i->Xin.Sse64FLo.src); in ppX86Instr()
1184 ppHRegX86(i->Xin.Sse64FLo.dst); in ppX86Instr()
1187 vex_printf("%s ", showX86SseOp(i->Xin.SseReRg.op)); in ppX86Instr()
1188 ppHRegX86(i->Xin.SseReRg.src); in ppX86Instr()
1190 ppHRegX86(i->Xin.SseReRg.dst); in ppX86Instr()
1193 vex_printf("cmov%s ", showX86CondCode(i->Xin.SseCMov.cond)); in ppX86Instr()
1194 ppHRegX86(i->Xin.SseCMov.src); in ppX86Instr()
1196 ppHRegX86(i->Xin.SseCMov.dst); in ppX86Instr()
1199 vex_printf("pshufd $0x%x,", (UInt)i->Xin.SseShuf.order); in ppX86Instr()
1200 ppHRegX86(i->Xin.SseShuf.src); in ppX86Instr()
1202 ppHRegX86(i->Xin.SseShuf.dst); in ppX86Instr()
1206 ppX86AMode(i->Xin.EvCheck.amCounter); in ppX86Instr()
1208 ppX86AMode(i->Xin.EvCheck.amFailAddr); in ppX86Instr()
1229 addRegUsage_X86RMI(u, i->Xin.Alu32R.src); in getRegUsage_X86Instr()
1230 if (i->Xin.Alu32R.op == Xalu_MOV) { in getRegUsage_X86Instr()
1231 addHRegUse(u, HRmWrite, i->Xin.Alu32R.dst); in getRegUsage_X86Instr()
1234 if (i->Xin.Alu32R.op == Xalu_CMP) { in getRegUsage_X86Instr()
1235 addHRegUse(u, HRmRead, i->Xin.Alu32R.dst); in getRegUsage_X86Instr()
1238 addHRegUse(u, HRmModify, i->Xin.Alu32R.dst); in getRegUsage_X86Instr()
1241 addRegUsage_X86RI(u, i->Xin.Alu32M.src); in getRegUsage_X86Instr()
1242 addRegUsage_X86AMode(u, i->Xin.Alu32M.dst); in getRegUsage_X86Instr()
1245 addHRegUse(u, HRmModify, i->Xin.Sh32.dst); in getRegUsage_X86Instr()
1246 if (i->Xin.Sh32.src == 0) in getRegUsage_X86Instr()
1250 addRegUsage_X86RM(u, i->Xin.Test32.dst, HRmRead); in getRegUsage_X86Instr()
1253 addHRegUse(u, HRmModify, i->Xin.Unary32.dst); in getRegUsage_X86Instr()
1256 addRegUsage_X86AMode(u, i->Xin.Lea32.am); in getRegUsage_X86Instr()
1257 addHRegUse(u, HRmWrite, i->Xin.Lea32.dst); in getRegUsage_X86Instr()
1260 addRegUsage_X86RM(u, i->Xin.MulL.src, HRmRead); in getRegUsage_X86Instr()
1265 addRegUsage_X86RM(u, i->Xin.Div.src, HRmRead); in getRegUsage_X86Instr()
1270 addHRegUse(u, HRmRead, i->Xin.Sh3232.src); in getRegUsage_X86Instr()
1271 addHRegUse(u, HRmModify, i->Xin.Sh3232.dst); in getRegUsage_X86Instr()
1272 if (i->Xin.Sh3232.amt == 0) in getRegUsage_X86Instr()
1276 addRegUsage_X86RMI(u, i->Xin.Push.src); in getRegUsage_X86Instr()
1298 switch (i->Xin.Call.regparms) { in getRegUsage_X86Instr()
1313 if (i->Xin.Call.regparms == 3) in getRegUsage_X86Instr()
1326 addRegUsage_X86AMode(u, i->Xin.XDirect.amEIP); in getRegUsage_X86Instr()
1329 addHRegUse(u, HRmRead, i->Xin.XIndir.dstGA); in getRegUsage_X86Instr()
1330 addRegUsage_X86AMode(u, i->Xin.XIndir.amEIP); in getRegUsage_X86Instr()
1333 addHRegUse(u, HRmRead, i->Xin.XAssisted.dstGA); in getRegUsage_X86Instr()
1334 addRegUsage_X86AMode(u, i->Xin.XAssisted.amEIP); in getRegUsage_X86Instr()
1337 addRegUsage_X86RM(u, i->Xin.CMov32.src, HRmRead); in getRegUsage_X86Instr()
1338 addHRegUse(u, HRmModify, i->Xin.CMov32.dst); in getRegUsage_X86Instr()
1341 addRegUsage_X86AMode(u, i->Xin.LoadEX.src); in getRegUsage_X86Instr()
1342 addHRegUse(u, HRmWrite, i->Xin.LoadEX.dst); in getRegUsage_X86Instr()
1345 addHRegUse(u, HRmRead, i->Xin.Store.src); in getRegUsage_X86Instr()
1346 addRegUsage_X86AMode(u, i->Xin.Store.dst); in getRegUsage_X86Instr()
1349 addHRegUse(u, HRmWrite, i->Xin.Set32.dst); in getRegUsage_X86Instr()
1352 addHRegUse(u, HRmRead, i->Xin.Bsfr32.src); in getRegUsage_X86Instr()
1353 addHRegUse(u, HRmWrite, i->Xin.Bsfr32.dst); in getRegUsage_X86Instr()
1358 addRegUsage_X86AMode(u, i->Xin.ACAS.addr); in getRegUsage_X86Instr()
1363 addRegUsage_X86AMode(u, i->Xin.DACAS.addr); in getRegUsage_X86Instr()
1370 addHRegUse(u, HRmRead, i->Xin.FpUnary.src); in getRegUsage_X86Instr()
1371 addHRegUse(u, HRmWrite, i->Xin.FpUnary.dst); in getRegUsage_X86Instr()
1374 addHRegUse(u, HRmRead, i->Xin.FpBinary.srcL); in getRegUsage_X86Instr()
1375 addHRegUse(u, HRmRead, i->Xin.FpBinary.srcR); in getRegUsage_X86Instr()
1376 addHRegUse(u, HRmWrite, i->Xin.FpBinary.dst); in getRegUsage_X86Instr()
1379 addRegUsage_X86AMode(u, i->Xin.FpLdSt.addr); in getRegUsage_X86Instr()
1380 addHRegUse(u, i->Xin.FpLdSt.isLoad ? HRmWrite : HRmRead, in getRegUsage_X86Instr()
1381 i->Xin.FpLdSt.reg); in getRegUsage_X86Instr()
1384 addRegUsage_X86AMode(u, i->Xin.FpLdStI.addr); in getRegUsage_X86Instr()
1385 addHRegUse(u, i->Xin.FpLdStI.isLoad ? HRmWrite : HRmRead, in getRegUsage_X86Instr()
1386 i->Xin.FpLdStI.reg); in getRegUsage_X86Instr()
1389 addHRegUse(u, HRmRead, i->Xin.Fp64to32.src); in getRegUsage_X86Instr()
1390 addHRegUse(u, HRmWrite, i->Xin.Fp64to32.dst); in getRegUsage_X86Instr()
1393 addHRegUse(u, HRmRead, i->Xin.FpCMov.src); in getRegUsage_X86Instr()
1394 addHRegUse(u, HRmModify, i->Xin.FpCMov.dst); in getRegUsage_X86Instr()
1397 addRegUsage_X86AMode(u, i->Xin.FpLdCW.addr); in getRegUsage_X86Instr()
1403 addHRegUse(u, HRmRead, i->Xin.FpCmp.srcL); in getRegUsage_X86Instr()
1404 addHRegUse(u, HRmRead, i->Xin.FpCmp.srcR); in getRegUsage_X86Instr()
1405 addHRegUse(u, HRmWrite, i->Xin.FpCmp.dst); in getRegUsage_X86Instr()
1409 addRegUsage_X86AMode(u, i->Xin.SseLdSt.addr); in getRegUsage_X86Instr()
1410 addHRegUse(u, i->Xin.SseLdSt.isLoad ? HRmWrite : HRmRead, in getRegUsage_X86Instr()
1411 i->Xin.SseLdSt.reg); in getRegUsage_X86Instr()
1414 addRegUsage_X86AMode(u, i->Xin.SseLdzLO.addr); in getRegUsage_X86Instr()
1415 addHRegUse(u, HRmWrite, i->Xin.SseLdzLO.reg); in getRegUsage_X86Instr()
1418 addHRegUse(u, HRmWrite, i->Xin.SseConst.dst); in getRegUsage_X86Instr()
1421 vassert(i->Xin.Sse32Fx4.op != Xsse_MOV); in getRegUsage_X86Instr()
1422 unary = toBool( i->Xin.Sse32Fx4.op == Xsse_RCPF in getRegUsage_X86Instr()
1423 || i->Xin.Sse32Fx4.op == Xsse_RSQRTF in getRegUsage_X86Instr()
1424 || i->Xin.Sse32Fx4.op == Xsse_SQRTF ); in getRegUsage_X86Instr()
1425 addHRegUse(u, HRmRead, i->Xin.Sse32Fx4.src); in getRegUsage_X86Instr()
1427 i->Xin.Sse32Fx4.dst); in getRegUsage_X86Instr()
1430 vassert(i->Xin.Sse32FLo.op != Xsse_MOV); in getRegUsage_X86Instr()
1431 unary = toBool( i->Xin.Sse32FLo.op == Xsse_RCPF in getRegUsage_X86Instr()
1432 || i->Xin.Sse32FLo.op == Xsse_RSQRTF in getRegUsage_X86Instr()
1433 || i->Xin.Sse32FLo.op == Xsse_SQRTF ); in getRegUsage_X86Instr()
1434 addHRegUse(u, HRmRead, i->Xin.Sse32FLo.src); in getRegUsage_X86Instr()
1436 i->Xin.Sse32FLo.dst); in getRegUsage_X86Instr()
1439 vassert(i->Xin.Sse64Fx2.op != Xsse_MOV); in getRegUsage_X86Instr()
1440 unary = toBool( i->Xin.Sse64Fx2.op == Xsse_RCPF in getRegUsage_X86Instr()
1441 || i->Xin.Sse64Fx2.op == Xsse_RSQRTF in getRegUsage_X86Instr()
1442 || i->Xin.Sse64Fx2.op == Xsse_SQRTF ); in getRegUsage_X86Instr()
1443 addHRegUse(u, HRmRead, i->Xin.Sse64Fx2.src); in getRegUsage_X86Instr()
1445 i->Xin.Sse64Fx2.dst); in getRegUsage_X86Instr()
1448 vassert(i->Xin.Sse64FLo.op != Xsse_MOV); in getRegUsage_X86Instr()
1449 unary = toBool( i->Xin.Sse64FLo.op == Xsse_RCPF in getRegUsage_X86Instr()
1450 || i->Xin.Sse64FLo.op == Xsse_RSQRTF in getRegUsage_X86Instr()
1451 || i->Xin.Sse64FLo.op == Xsse_SQRTF ); in getRegUsage_X86Instr()
1452 addHRegUse(u, HRmRead, i->Xin.Sse64FLo.src); in getRegUsage_X86Instr()
1454 i->Xin.Sse64FLo.dst); in getRegUsage_X86Instr()
1457 if (i->Xin.SseReRg.op == Xsse_XOR in getRegUsage_X86Instr()
1458 && sameHReg(i->Xin.SseReRg.src, i->Xin.SseReRg.dst)) { in getRegUsage_X86Instr()
1461 addHRegUse(u, HRmWrite, i->Xin.SseReRg.dst); in getRegUsage_X86Instr()
1463 addHRegUse(u, HRmRead, i->Xin.SseReRg.src); in getRegUsage_X86Instr()
1464 addHRegUse(u, i->Xin.SseReRg.op == Xsse_MOV in getRegUsage_X86Instr()
1466 i->Xin.SseReRg.dst); in getRegUsage_X86Instr()
1470 addHRegUse(u, HRmRead, i->Xin.SseCMov.src); in getRegUsage_X86Instr()
1471 addHRegUse(u, HRmModify, i->Xin.SseCMov.dst); in getRegUsage_X86Instr()
1474 addHRegUse(u, HRmRead, i->Xin.SseShuf.src); in getRegUsage_X86Instr()
1475 addHRegUse(u, HRmWrite, i->Xin.SseShuf.dst); in getRegUsage_X86Instr()
1480 addRegUsage_X86AMode(u, i->Xin.EvCheck.amCounter); in getRegUsage_X86Instr()
1481 addRegUsage_X86AMode(u, i->Xin.EvCheck.amFailAddr); in getRegUsage_X86Instr()
1503 mapRegs_X86RMI(m, i->Xin.Alu32R.src); in mapRegs_X86Instr()
1504 mapReg(m, &i->Xin.Alu32R.dst); in mapRegs_X86Instr()
1507 mapRegs_X86RI(m, i->Xin.Alu32M.src); in mapRegs_X86Instr()
1508 mapRegs_X86AMode(m, i->Xin.Alu32M.dst); in mapRegs_X86Instr()
1511 mapReg(m, &i->Xin.Sh32.dst); in mapRegs_X86Instr()
1514 mapRegs_X86RM(m, i->Xin.Test32.dst); in mapRegs_X86Instr()
1517 mapReg(m, &i->Xin.Unary32.dst); in mapRegs_X86Instr()
1520 mapRegs_X86AMode(m, i->Xin.Lea32.am); in mapRegs_X86Instr()
1521 mapReg(m, &i->Xin.Lea32.dst); in mapRegs_X86Instr()
1524 mapRegs_X86RM(m, i->Xin.MulL.src); in mapRegs_X86Instr()
1527 mapRegs_X86RM(m, i->Xin.Div.src); in mapRegs_X86Instr()
1530 mapReg(m, &i->Xin.Sh3232.src); in mapRegs_X86Instr()
1531 mapReg(m, &i->Xin.Sh3232.dst); in mapRegs_X86Instr()
1534 mapRegs_X86RMI(m, i->Xin.Push.src); in mapRegs_X86Instr()
1539 mapRegs_X86AMode(m, i->Xin.XDirect.amEIP); in mapRegs_X86Instr()
1542 mapReg(m, &i->Xin.XIndir.dstGA); in mapRegs_X86Instr()
1543 mapRegs_X86AMode(m, i->Xin.XIndir.amEIP); in mapRegs_X86Instr()
1546 mapReg(m, &i->Xin.XAssisted.dstGA); in mapRegs_X86Instr()
1547 mapRegs_X86AMode(m, i->Xin.XAssisted.amEIP); in mapRegs_X86Instr()
1550 mapRegs_X86RM(m, i->Xin.CMov32.src); in mapRegs_X86Instr()
1551 mapReg(m, &i->Xin.CMov32.dst); in mapRegs_X86Instr()
1554 mapRegs_X86AMode(m, i->Xin.LoadEX.src); in mapRegs_X86Instr()
1555 mapReg(m, &i->Xin.LoadEX.dst); in mapRegs_X86Instr()
1558 mapReg(m, &i->Xin.Store.src); in mapRegs_X86Instr()
1559 mapRegs_X86AMode(m, i->Xin.Store.dst); in mapRegs_X86Instr()
1562 mapReg(m, &i->Xin.Set32.dst); in mapRegs_X86Instr()
1565 mapReg(m, &i->Xin.Bsfr32.src); in mapRegs_X86Instr()
1566 mapReg(m, &i->Xin.Bsfr32.dst); in mapRegs_X86Instr()
1571 mapRegs_X86AMode(m, i->Xin.ACAS.addr); in mapRegs_X86Instr()
1574 mapRegs_X86AMode(m, i->Xin.DACAS.addr); in mapRegs_X86Instr()
1577 mapReg(m, &i->Xin.FpUnary.src); in mapRegs_X86Instr()
1578 mapReg(m, &i->Xin.FpUnary.dst); in mapRegs_X86Instr()
1581 mapReg(m, &i->Xin.FpBinary.srcL); in mapRegs_X86Instr()
1582 mapReg(m, &i->Xin.FpBinary.srcR); in mapRegs_X86Instr()
1583 mapReg(m, &i->Xin.FpBinary.dst); in mapRegs_X86Instr()
1586 mapRegs_X86AMode(m, i->Xin.FpLdSt.addr); in mapRegs_X86Instr()
1587 mapReg(m, &i->Xin.FpLdSt.reg); in mapRegs_X86Instr()
1590 mapRegs_X86AMode(m, i->Xin.FpLdStI.addr); in mapRegs_X86Instr()
1591 mapReg(m, &i->Xin.FpLdStI.reg); in mapRegs_X86Instr()
1594 mapReg(m, &i->Xin.Fp64to32.src); in mapRegs_X86Instr()
1595 mapReg(m, &i->Xin.Fp64to32.dst); in mapRegs_X86Instr()
1598 mapReg(m, &i->Xin.FpCMov.src); in mapRegs_X86Instr()
1599 mapReg(m, &i->Xin.FpCMov.dst); in mapRegs_X86Instr()
1602 mapRegs_X86AMode(m, i->Xin.FpLdCW.addr); in mapRegs_X86Instr()
1607 mapReg(m, &i->Xin.FpCmp.srcL); in mapRegs_X86Instr()
1608 mapReg(m, &i->Xin.FpCmp.srcR); in mapRegs_X86Instr()
1609 mapReg(m, &i->Xin.FpCmp.dst); in mapRegs_X86Instr()
1612 mapReg(m, &i->Xin.SseConst.dst); in mapRegs_X86Instr()
1615 mapReg(m, &i->Xin.SseLdSt.reg); in mapRegs_X86Instr()
1616 mapRegs_X86AMode(m, i->Xin.SseLdSt.addr); in mapRegs_X86Instr()
1619 mapReg(m, &i->Xin.SseLdzLO.reg); in mapRegs_X86Instr()
1620 mapRegs_X86AMode(m, i->Xin.SseLdzLO.addr); in mapRegs_X86Instr()
1623 mapReg(m, &i->Xin.Sse32Fx4.src); in mapRegs_X86Instr()
1624 mapReg(m, &i->Xin.Sse32Fx4.dst); in mapRegs_X86Instr()
1627 mapReg(m, &i->Xin.Sse32FLo.src); in mapRegs_X86Instr()
1628 mapReg(m, &i->Xin.Sse32FLo.dst); in mapRegs_X86Instr()
1631 mapReg(m, &i->Xin.Sse64Fx2.src); in mapRegs_X86Instr()
1632 mapReg(m, &i->Xin.Sse64Fx2.dst); in mapRegs_X86Instr()
1635 mapReg(m, &i->Xin.Sse64FLo.src); in mapRegs_X86Instr()
1636 mapReg(m, &i->Xin.Sse64FLo.dst); in mapRegs_X86Instr()
1639 mapReg(m, &i->Xin.SseReRg.src); in mapRegs_X86Instr()
1640 mapReg(m, &i->Xin.SseReRg.dst); in mapRegs_X86Instr()
1643 mapReg(m, &i->Xin.SseCMov.src); in mapRegs_X86Instr()
1644 mapReg(m, &i->Xin.SseCMov.dst); in mapRegs_X86Instr()
1647 mapReg(m, &i->Xin.SseShuf.src); in mapRegs_X86Instr()
1648 mapReg(m, &i->Xin.SseShuf.dst); in mapRegs_X86Instr()
1653 mapRegs_X86AMode(m, i->Xin.EvCheck.amCounter); in mapRegs_X86Instr()
1654 mapRegs_X86AMode(m, i->Xin.EvCheck.amFailAddr); in mapRegs_X86Instr()
1674 if (i->Xin.Alu32R.op != Xalu_MOV) in isMove_X86Instr()
1676 if (i->Xin.Alu32R.src->tag != Xrmi_Reg) in isMove_X86Instr()
1678 *src = i->Xin.Alu32R.src->Xrmi.Reg.reg; in isMove_X86Instr()
1679 *dst = i->Xin.Alu32R.dst; in isMove_X86Instr()
1684 if (i->Xin.FpUnary.op != Xfp_MOV) in isMove_X86Instr()
1686 *src = i->Xin.FpUnary.src; in isMove_X86Instr()
1687 *dst = i->Xin.FpUnary.dst; in isMove_X86Instr()
1691 if (i->Xin.SseReRg.op != Xsse_MOV) in isMove_X86Instr()
1693 *src = i->Xin.SseReRg.src; in isMove_X86Instr()
1694 *dst = i->Xin.SseReRg.dst; in isMove_X86Instr()
1768 && (i->Xin.Alu32R.op == Xalu_MOV || i->Xin.Alu32R.op == Xalu_OR in directReload_X86()
1769 || i->Xin.Alu32R.op == Xalu_XOR) in directReload_X86()
1770 && i->Xin.Alu32R.src->tag == Xrmi_Reg in directReload_X86()
1771 && sameHReg(i->Xin.Alu32R.src->Xrmi.Reg.reg, vreg)) { in directReload_X86()
1772 vassert(! sameHReg(i->Xin.Alu32R.dst, vreg)); in directReload_X86()
1774 i->Xin.Alu32R.op, in directReload_X86()
1776 i->Xin.Alu32R.dst in directReload_X86()
1784 && (i->Xin.Alu32R.op == Xalu_CMP) in directReload_X86()
1785 && i->Xin.Alu32R.src->tag == Xrmi_Imm in directReload_X86()
1786 && sameHReg(i->Xin.Alu32R.dst, vreg)) { in directReload_X86()
1788 i->Xin.Alu32R.op, in directReload_X86()
1789 X86RI_Imm( i->Xin.Alu32R.src->Xrmi.Imm.imm32 ), in directReload_X86()
1798 && i->Xin.Push.src->tag == Xrmi_Reg in directReload_X86()
1799 && sameHReg(i->Xin.Push.src->Xrmi.Reg.reg, vreg)) { in directReload_X86()
1808 && i->Xin.CMov32.src->tag == Xrm_Reg in directReload_X86()
1809 && sameHReg(i->Xin.CMov32.src->Xrm.Reg.reg, vreg)) { in directReload_X86()
1810 vassert(! sameHReg(i->Xin.CMov32.dst, vreg)); in directReload_X86()
1812 i->Xin.CMov32.cond, in directReload_X86()
1814 i->Xin.CMov32.dst in directReload_X86()
1820 && i->Xin.Test32.dst->tag == Xrm_Reg in directReload_X86()
1821 && sameHReg(i->Xin.Test32.dst->Xrm.Reg.reg, vreg)) { in directReload_X86()
1823 i->Xin.Test32.imm32, in directReload_X86()
2146 if (i->Xin.Alu32R.op == Xalu_MOV) { in emit_X86Instr()
2147 switch (i->Xin.Alu32R.src->tag) { in emit_X86Instr()
2149 *p++ = toUChar(0xB8 + iregEnc(i->Xin.Alu32R.dst)); in emit_X86Instr()
2150 p = emit32(p, i->Xin.Alu32R.src->Xrmi.Imm.imm32); in emit_X86Instr()
2154 p = doAMode_R(p, i->Xin.Alu32R.src->Xrmi.Reg.reg, in emit_X86Instr()
2155 i->Xin.Alu32R.dst); in emit_X86Instr()
2159 p = doAMode_M(p, i->Xin.Alu32R.dst, in emit_X86Instr()
2160 i->Xin.Alu32R.src->Xrmi.Mem.am); in emit_X86Instr()
2167 if (i->Xin.Alu32R.op == Xalu_MUL) { in emit_X86Instr()
2168 switch (i->Xin.Alu32R.src->tag) { in emit_X86Instr()
2172 p = doAMode_R(p, i->Xin.Alu32R.dst, in emit_X86Instr()
2173 i->Xin.Alu32R.src->Xrmi.Reg.reg); in emit_X86Instr()
2178 p = doAMode_M(p, i->Xin.Alu32R.dst, in emit_X86Instr()
2179 i->Xin.Alu32R.src->Xrmi.Mem.am); in emit_X86Instr()
2182 if (fits8bits(i->Xin.Alu32R.src->Xrmi.Imm.imm32)) { in emit_X86Instr()
2184 p = doAMode_R(p, i->Xin.Alu32R.dst, i->Xin.Alu32R.dst); in emit_X86Instr()
2185 *p++ = toUChar(0xFF & i->Xin.Alu32R.src->Xrmi.Imm.imm32); in emit_X86Instr()
2188 p = doAMode_R(p, i->Xin.Alu32R.dst, i->Xin.Alu32R.dst); in emit_X86Instr()
2189 p = emit32(p, i->Xin.Alu32R.src->Xrmi.Imm.imm32); in emit_X86Instr()
2198 switch (i->Xin.Alu32R.op) { in emit_X86Instr()
2217 switch (i->Xin.Alu32R.src->tag) { in emit_X86Instr()
2219 if (sameHReg(i->Xin.Alu32R.dst, hregX86_EAX()) in emit_X86Instr()
2220 && !fits8bits(i->Xin.Alu32R.src->Xrmi.Imm.imm32)) { in emit_X86Instr()
2222 p = emit32(p, i->Xin.Alu32R.src->Xrmi.Imm.imm32); in emit_X86Instr()
2224 if (fits8bits(i->Xin.Alu32R.src->Xrmi.Imm.imm32)) { in emit_X86Instr()
2226 p = doAMode_R_enc_reg(p, subopc_imm, i->Xin.Alu32R.dst); in emit_X86Instr()
2227 *p++ = toUChar(0xFF & i->Xin.Alu32R.src->Xrmi.Imm.imm32); in emit_X86Instr()
2230 p = doAMode_R_enc_reg(p, subopc_imm, i->Xin.Alu32R.dst); in emit_X86Instr()
2231 p = emit32(p, i->Xin.Alu32R.src->Xrmi.Imm.imm32); in emit_X86Instr()
2236 p = doAMode_R(p, i->Xin.Alu32R.src->Xrmi.Reg.reg, in emit_X86Instr()
2237 i->Xin.Alu32R.dst); in emit_X86Instr()
2241 p = doAMode_M(p, i->Xin.Alu32R.dst, in emit_X86Instr()
2242 i->Xin.Alu32R.src->Xrmi.Mem.am); in emit_X86Instr()
2251 if (i->Xin.Alu32M.op == Xalu_MOV) { in emit_X86Instr()
2252 switch (i->Xin.Alu32M.src->tag) { in emit_X86Instr()
2255 p = doAMode_M(p, i->Xin.Alu32M.src->Xri.Reg.reg, in emit_X86Instr()
2256 i->Xin.Alu32M.dst); in emit_X86Instr()
2260 p = doAMode_M_enc(p, 0, i->Xin.Alu32M.dst); in emit_X86Instr()
2261 p = emit32(p, i->Xin.Alu32M.src->Xri.Imm.imm32); in emit_X86Instr()
2270 switch (i->Xin.Alu32M.op) { in emit_X86Instr()
2276 switch (i->Xin.Alu32M.src->tag) { in emit_X86Instr()
2279 p = doAMode_M(p, i->Xin.Alu32M.src->Xri.Reg.reg, in emit_X86Instr()
2280 i->Xin.Alu32M.dst); in emit_X86Instr()
2283 if (fits8bits(i->Xin.Alu32M.src->Xri.Imm.imm32)) { in emit_X86Instr()
2285 p = doAMode_M_enc(p, subopc_imm, i->Xin.Alu32M.dst); in emit_X86Instr()
2286 *p++ = toUChar(0xFF & i->Xin.Alu32M.src->Xri.Imm.imm32); in emit_X86Instr()
2290 p = doAMode_M_enc(p, subopc_imm, i->Xin.Alu32M.dst); in emit_X86Instr()
2291 p = emit32(p, i->Xin.Alu32M.src->Xri.Imm.imm32); in emit_X86Instr()
2301 switch (i->Xin.Sh32.op) { in emit_X86Instr()
2307 if (i->Xin.Sh32.src == 0) { in emit_X86Instr()
2309 p = doAMode_R_enc_reg(p, subopc, i->Xin.Sh32.dst); in emit_X86Instr()
2312 p = doAMode_R_enc_reg(p, subopc, i->Xin.Sh32.dst); in emit_X86Instr()
2313 *p++ = (UChar)(i->Xin.Sh32.src); in emit_X86Instr()
2318 if (i->Xin.Test32.dst->tag == Xrm_Reg) { in emit_X86Instr()
2321 p = doAMode_R_enc_reg(p, 0, i->Xin.Test32.dst->Xrm.Reg.reg); in emit_X86Instr()
2322 p = emit32(p, i->Xin.Test32.imm32); in emit_X86Instr()
2327 p = doAMode_M_enc(p, 0, i->Xin.Test32.dst->Xrm.Mem.am); in emit_X86Instr()
2328 p = emit32(p, i->Xin.Test32.imm32); in emit_X86Instr()
2333 if (i->Xin.Unary32.op == Xun_NOT) { in emit_X86Instr()
2335 p = doAMode_R_enc_reg(p, 2, i->Xin.Unary32.dst); in emit_X86Instr()
2338 if (i->Xin.Unary32.op == Xun_NEG) { in emit_X86Instr()
2340 p = doAMode_R_enc_reg(p, 3, i->Xin.Unary32.dst); in emit_X86Instr()
2347 p = doAMode_M(p, i->Xin.Lea32.dst, i->Xin.Lea32.am); in emit_X86Instr()
2351 subopc = i->Xin.MulL.syned ? 5 : 4; in emit_X86Instr()
2353 switch (i->Xin.MulL.src->tag) { in emit_X86Instr()
2355 p = doAMode_M_enc(p, subopc, i->Xin.MulL.src->Xrm.Mem.am); in emit_X86Instr()
2358 p = doAMode_R_enc_reg(p, subopc, i->Xin.MulL.src->Xrm.Reg.reg); in emit_X86Instr()
2366 subopc = i->Xin.Div.syned ? 7 : 6; in emit_X86Instr()
2368 switch (i->Xin.Div.src->tag) { in emit_X86Instr()
2370 p = doAMode_M_enc(p, subopc, i->Xin.Div.src->Xrm.Mem.am); in emit_X86Instr()
2373 p = doAMode_R_enc_reg(p, subopc, i->Xin.Div.src->Xrm.Reg.reg); in emit_X86Instr()
2381 vassert(i->Xin.Sh3232.op == Xsh_SHL || i->Xin.Sh3232.op == Xsh_SHR); in emit_X86Instr()
2382 if (i->Xin.Sh3232.amt == 0) { in emit_X86Instr()
2385 if (i->Xin.Sh3232.op == Xsh_SHL) { in emit_X86Instr()
2390 p = doAMode_R(p, i->Xin.Sh3232.src, i->Xin.Sh3232.dst); in emit_X86Instr()
2396 switch (i->Xin.Push.src->tag) { in emit_X86Instr()
2399 p = doAMode_M_enc(p, 6, i->Xin.Push.src->Xrmi.Mem.am); in emit_X86Instr()
2403 p = emit32(p, i->Xin.Push.src->Xrmi.Imm.imm32); in emit_X86Instr()
2406 *p++ = toUChar(0x50 + iregEnc(i->Xin.Push.src->Xrmi.Reg.reg)); in emit_X86Instr()
2413 if (i->Xin.Call.cond != Xcc_ALWAYS in emit_X86Instr()
2414 && i->Xin.Call.rloc.pri != RLPri_None) { in emit_X86Instr()
2425 switch (i->Xin.Call.regparms) { in emit_X86Instr()
2434 if (i->Xin.Call.cond != Xcc_ALWAYS) { in emit_X86Instr()
2435 *p++ = toUChar(0x70 + (0xF & (i->Xin.Call.cond ^ 1))); in emit_X86Instr()
2440 p = emit32(p, i->Xin.Call.target); in emit_X86Instr()
2460 if (i->Xin.XDirect.cond != Xcc_ALWAYS) { in emit_X86Instr()
2462 *p++ = toUChar(0x70 + (0xF & (i->Xin.XDirect.cond ^ 1))); in emit_X86Instr()
2470 p = doAMode_M_enc(p, 0, i->Xin.XDirect.amEIP); in emit_X86Instr()
2471 p = emit32(p, i->Xin.XDirect.dstGA); in emit_X86Instr()
2481 = i->Xin.XDirect.toFastEP ? disp_cp_chain_me_to_fastEP in emit_X86Instr()
2490 if (i->Xin.XDirect.cond != Xcc_ALWAYS) { in emit_X86Instr()
2512 if (i->Xin.XIndir.cond != Xcc_ALWAYS) { in emit_X86Instr()
2514 *p++ = toUChar(0x70 + (0xF & (i->Xin.XIndir.cond ^ 1))); in emit_X86Instr()
2521 p = doAMode_M(p, i->Xin.XIndir.dstGA, i->Xin.XIndir.amEIP); in emit_X86Instr()
2531 if (i->Xin.XIndir.cond != Xcc_ALWAYS) { in emit_X86Instr()
2545 if (i->Xin.XAssisted.cond != Xcc_ALWAYS) { in emit_X86Instr()
2547 *p++ = toUChar(0x70 + (0xF & (i->Xin.XAssisted.cond ^ 1))); in emit_X86Instr()
2554 p = doAMode_M(p, i->Xin.XIndir.dstGA, i->Xin.XIndir.amEIP); in emit_X86Instr()
2557 switch (i->Xin.XAssisted.jk) { in emit_X86Instr()
2580 ppIRJumpKind(i->Xin.XAssisted.jk); in emit_X86Instr()
2595 if (i->Xin.XAssisted.cond != Xcc_ALWAYS) { in emit_X86Instr()
2604 vassert(i->Xin.CMov32.cond != Xcc_ALWAYS); in emit_X86Instr()
2622 *p++ = toUChar(0x70 + (i->Xin.CMov32.cond ^ 1)); in emit_X86Instr()
2626 switch (i->Xin.CMov32.src->tag) { in emit_X86Instr()
2630 p = doAMode_R(p, i->Xin.CMov32.src->Xrm.Reg.reg, in emit_X86Instr()
2631 i->Xin.CMov32.dst); in emit_X86Instr()
2639 p = doAMode_M(p, i->Xin.CMov32.dst, in emit_X86Instr()
2640 i->Xin.CMov32.src->Xrm.Mem.am); in emit_X86Instr()
2652 if (i->Xin.LoadEX.szSmall == 1 && !i->Xin.LoadEX.syned) { in emit_X86Instr()
2656 p = doAMode_M(p, i->Xin.LoadEX.dst, i->Xin.LoadEX.src); in emit_X86Instr()
2659 if (i->Xin.LoadEX.szSmall == 2 && !i->Xin.LoadEX.syned) { in emit_X86Instr()
2663 p = doAMode_M(p, i->Xin.LoadEX.dst, i->Xin.LoadEX.src); in emit_X86Instr()
2666 if (i->Xin.LoadEX.szSmall == 1 && i->Xin.LoadEX.syned) { in emit_X86Instr()
2670 p = doAMode_M(p, i->Xin.LoadEX.dst, i->Xin.LoadEX.src); in emit_X86Instr()
2685 if (iregEnc(i->Xin.Set32.dst) >= 4) { in emit_X86Instr()
2687 *p++ = toUChar(0x90 + iregEnc(i->Xin.Set32.dst)); in emit_X86Instr()
2693 *p++ = toUChar(0x90 + (0xF & i->Xin.Set32.cond)); in emit_X86Instr()
2696 *p++ = toUChar(0x90 + iregEnc(i->Xin.Set32.dst)); in emit_X86Instr()
2699 *p++ = toUChar(0xB8 + iregEnc(i->Xin.Set32.dst)); in emit_X86Instr()
2703 *p++ = toUChar(0x90 + (0xF & i->Xin.Set32.cond)); in emit_X86Instr()
2704 p = doAMode_R_enc_reg(p, 0, i->Xin.Set32.dst); in emit_X86Instr()
2710 if (i->Xin.Bsfr32.isFwds) { in emit_X86Instr()
2715 p = doAMode_R(p, i->Xin.Bsfr32.dst, i->Xin.Bsfr32.src); in emit_X86Instr()
2721 if (i->Xin.MFence.hwcaps & (VEX_HWCAPS_X86_SSE3 in emit_X86Instr()
2727 if (i->Xin.MFence.hwcaps & VEX_HWCAPS_X86_MMXEXT) { in emit_X86Instr()
2735 if (i->Xin.MFence.hwcaps == 0/*baseline, no SSE*/) { in emit_X86Instr()
2757 if (i->Xin.ACAS.sz == 2) *p++ = 0x66; in emit_X86Instr()
2759 if (i->Xin.ACAS.sz == 1) *p++ = 0xB0; else *p++ = 0xB1; in emit_X86Instr()
2760 p = doAMode_M(p, hregX86_EBX(), i->Xin.ACAS.addr); in emit_X86Instr()
2771 p = doAMode_M_enc(p, 1, i->Xin.DACAS.addr); in emit_X86Instr()
2775 if (i->Xin.Store.sz == 2) { in emit_X86Instr()
2780 p = doAMode_M(p, i->Xin.Store.src, i->Xin.Store.dst); in emit_X86Instr()
2784 if (i->Xin.Store.sz == 1) { in emit_X86Instr()
2787 if (iregEnc(i->Xin.Store.src) < 4) { in emit_X86Instr()
2790 p = doAMode_M(p, i->Xin.Store.src, i->Xin.Store.dst); in emit_X86Instr()
2804 addRegUsage_X86AMode(&u, i->Xin.Store.dst); in emit_X86Instr()
2812 p = doAMode_R(p, i->Xin.Store.src, swap); in emit_X86Instr()
2815 p = doAMode_M(p, swap, i->Xin.Store.dst); in emit_X86Instr()
2818 p = doAMode_R(p, i->Xin.Store.src, swap); in emit_X86Instr()
2829 p = do_fld_st(p, 0+fregEnc(i->Xin.FpUnary.src)); in emit_X86Instr()
2830 p = do_fop1_st(p, i->Xin.FpUnary.op); in emit_X86Instr()
2831 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpUnary.dst)); in emit_X86Instr()
2835 if (i->Xin.FpBinary.op == Xfp_YL2X in emit_X86Instr()
2836 || i->Xin.FpBinary.op == Xfp_YL2XP1) { in emit_X86Instr()
2841 p = do_fld_st(p, 0+fregEnc(i->Xin.FpBinary.srcL)); in emit_X86Instr()
2843 p = do_fld_st(p, 1+fregEnc(i->Xin.FpBinary.srcR)); in emit_X86Instr()
2845 *p++ = toUChar(i->Xin.FpBinary.op==Xfp_YL2X ? 0xF1 : 0xF9); in emit_X86Instr()
2846 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpBinary.dst)); in emit_X86Instr()
2849 if (i->Xin.FpBinary.op == Xfp_ATAN) { in emit_X86Instr()
2854 p = do_fld_st(p, 0+fregEnc(i->Xin.FpBinary.srcL)); in emit_X86Instr()
2856 p = do_fld_st(p, 1+fregEnc(i->Xin.FpBinary.srcR)); in emit_X86Instr()
2858 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpBinary.dst)); in emit_X86Instr()
2861 if (i->Xin.FpBinary.op == Xfp_PREM in emit_X86Instr()
2862 || i->Xin.FpBinary.op == Xfp_PREM1 in emit_X86Instr()
2863 || i->Xin.FpBinary.op == Xfp_SCALE) { in emit_X86Instr()
2869 p = do_fld_st(p, 0+fregEnc(i->Xin.FpBinary.srcR)); in emit_X86Instr()
2871 p = do_fld_st(p, 1+fregEnc(i->Xin.FpBinary.srcL)); in emit_X86Instr()
2873 switch (i->Xin.FpBinary.op) { in emit_X86Instr()
2879 p = do_fstp_st(p, 2+fregEnc(i->Xin.FpBinary.dst)); in emit_X86Instr()
2889 p = do_fld_st(p, 0+fregEnc(i->Xin.FpBinary.srcL)); in emit_X86Instr()
2890 p = do_fop2_st(p, i->Xin.FpBinary.op, in emit_X86Instr()
2891 1+fregEnc(i->Xin.FpBinary.srcR)); in emit_X86Instr()
2892 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpBinary.dst)); in emit_X86Instr()
2896 if (i->Xin.FpLdSt.isLoad) { in emit_X86Instr()
2901 switch (i->Xin.FpLdSt.sz) { in emit_X86Instr()
2904 p = doAMode_M_enc(p, 0/*subopcode*/, i->Xin.FpLdSt.addr); in emit_X86Instr()
2908 p = doAMode_M_enc(p, 0/*subopcode*/, i->Xin.FpLdSt.addr); in emit_X86Instr()
2912 p = doAMode_M_enc(p, 5/*subopcode*/, i->Xin.FpLdSt.addr); in emit_X86Instr()
2917 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpLdSt.reg)); in emit_X86Instr()
2924 p = do_fld_st(p, 0+fregEnc(i->Xin.FpLdSt.reg)); in emit_X86Instr()
2925 switch (i->Xin.FpLdSt.sz) { in emit_X86Instr()
2928 p = doAMode_M_enc(p, 3/*subopcode*/, i->Xin.FpLdSt.addr); in emit_X86Instr()
2932 p = doAMode_M_enc(p, 3/*subopcode*/, i->Xin.FpLdSt.addr); in emit_X86Instr()
2936 p = doAMode_M_enc(p, 7/*subopcode*/, i->Xin.FpLdSt.addr); in emit_X86Instr()
2946 if (i->Xin.FpLdStI.isLoad) { in emit_X86Instr()
2950 switch (i->Xin.FpLdStI.sz) { in emit_X86Instr()
2958 p = doAMode_M_enc(p, subopc_imm/*subopcode*/, i->Xin.FpLdStI.addr); in emit_X86Instr()
2959 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpLdStI.reg)); in emit_X86Instr()
2965 switch (i->Xin.FpLdStI.sz) { in emit_X86Instr()
2972 p = do_fld_st(p, 0+fregEnc(i->Xin.FpLdStI.reg)); in emit_X86Instr()
2974 p = doAMode_M_enc(p, subopc_imm/*subopcode*/, i->Xin.FpLdStI.addr); in emit_X86Instr()
2982 p = do_fld_st(p, 0+fregEnc(i->Xin.Fp64to32.src)); in emit_X86Instr()
2992 p = do_fstp_st(p, 1+fregEnc(i->Xin.Fp64to32.dst)); in emit_X86Instr()
2997 *p++ = toUChar(0x70 + (i->Xin.FpCMov.cond ^ 1)); in emit_X86Instr()
3003 p = do_fld_st(p, 0+fregEnc(i->Xin.FpCMov.src)); in emit_X86Instr()
3004 p = do_fstp_st(p, 1+fregEnc(i->Xin.FpCMov.dst)); in emit_X86Instr()
3012 p = doAMode_M_enc(p, 5/*subopcode*/, i->Xin.FpLdCW.addr); in emit_X86Instr()
3029 p = do_fld_st(p, 0+fregEnc(i->Xin.FpCmp.srcL)); in emit_X86Instr()
3032 *p++ = toUChar(0xE8 + (7 & (1+fregEnc(i->Xin.FpCmp.srcR)))); in emit_X86Instr()
3038 p = doAMode_R(p, hregX86_EAX(), i->Xin.FpCmp.dst); in emit_X86Instr()
3042 UShort con = i->Xin.SseConst.con; in emit_X86Instr()
3050 *p++ = toUChar(0x04 + 8 * (7 & vregEnc(i->Xin.SseConst.dst))); in emit_X86Instr()
3061 *p++ = toUChar(i->Xin.SseLdSt.isLoad ? 0x10 : 0x11); in emit_X86Instr()
3062 p = doAMode_M_enc(p, vregEnc(i->Xin.SseLdSt.reg), i->Xin.SseLdSt.addr); in emit_X86Instr()
3066 vassert(i->Xin.SseLdzLO.sz == 4 || i->Xin.SseLdzLO.sz == 8); in emit_X86Instr()
3068 *p++ = toUChar(i->Xin.SseLdzLO.sz==4 ? 0xF3 : 0xF2); in emit_X86Instr()
3071 p = doAMode_M_enc(p, vregEnc(i->Xin.SseLdzLO.reg), i->Xin.SseLdzLO.addr); in emit_X86Instr()
3077 switch (i->Xin.Sse32Fx4.op) { in emit_X86Instr()
3093 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.Sse32Fx4.dst), in emit_X86Instr()
3094 vregEnc(i->Xin.Sse32Fx4.src) ); in emit_X86Instr()
3103 switch (i->Xin.Sse64Fx2.op) { in emit_X86Instr()
3119 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.Sse64Fx2.dst), in emit_X86Instr()
3120 vregEnc(i->Xin.Sse64Fx2.src) ); in emit_X86Instr()
3129 switch (i->Xin.Sse32FLo.op) { in emit_X86Instr()
3145 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.Sse32FLo.dst), in emit_X86Instr()
3146 vregEnc(i->Xin.Sse32FLo.src) ); in emit_X86Instr()
3155 switch (i->Xin.Sse64FLo.op) { in emit_X86Instr()
3171 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.Sse64FLo.dst), in emit_X86Instr()
3172 vregEnc(i->Xin.Sse64FLo.src) ); in emit_X86Instr()
3179 switch (i->Xin.SseReRg.op) { in emit_X86Instr()
3236 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.SseReRg.dst), in emit_X86Instr()
3237 vregEnc(i->Xin.SseReRg.src) ); in emit_X86Instr()
3243 *p++ = toUChar(0x70 + (i->Xin.SseCMov.cond ^ 1)); in emit_X86Instr()
3250 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.SseCMov.dst), in emit_X86Instr()
3251 vregEnc(i->Xin.SseCMov.src) ); in emit_X86Instr()
3261 p = doAMode_R_enc_enc(p, vregEnc(i->Xin.SseShuf.dst), in emit_X86Instr()
3262 vregEnc(i->Xin.SseShuf.src) ); in emit_X86Instr()
3263 *p++ = (UChar)(i->Xin.SseShuf.order); in emit_X86Instr()
3286 p = doAMode_M_enc(p, 1, i->Xin.EvCheck.amCounter); in emit_X86Instr()
3295 p = doAMode_M_enc(p, 4, i->Xin.EvCheck.amFailAddr); in emit_X86Instr()