Changeset 102011 in vbox
- Timestamp:
- Nov 8, 2023 10:10:48 PM (15 months ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAllInstCommon.cpp.h
r101958 r102011 952 952 IEM_MC_ARG_CONST(uint8_t, iGRegArg, /*=*/iGReg, 3); 953 953 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/pVCpu->iem.s.enmEffOpSize, 4); 954 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(iGReg); 955 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); 956 IEM_MC_CALL_CIMPL_5( 0, iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 954 IEM_MC_CALL_CIMPL_5( 0, 955 RT_BIT_64(kIemNativeGstReg_GprFirst + iGReg) 956 | RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) 957 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) 958 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), 959 iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 957 960 IEM_MC_END(); 958 961 } … … 970 973 IEM_MC_ARG_CONST(uint8_t, iGRegArg, /*=*/iGReg, 3); 971 974 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/pVCpu->iem.s.enmEffOpSize, 4); 972 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(iGReg); 973 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); 974 IEM_MC_CALL_CIMPL_5(IEM_CIMPL_F_MODE, iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 975 IEM_MC_CALL_CIMPL_5(IEM_CIMPL_F_MODE, 976 RT_BIT_64(kIemNativeGstReg_GprFirst + iGReg) 977 | RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) 978 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) 979 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), 980 iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 975 981 IEM_MC_END(); 976 982 } … … 990 996 IEM_MC_ARG_CONST(uint8_t, iGRegArg, /*=*/iGReg, 3); 991 997 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/pVCpu->iem.s.enmEffOpSize, 4); 992 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(iGReg); 993 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); 994 IEM_MC_CALL_CIMPL_5( 0, iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 998 IEM_MC_CALL_CIMPL_5( 0, 999 RT_BIT_64(kIemNativeGstReg_GprFirst + iGReg) 1000 | RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) 1001 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) 1002 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), 1003 iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 995 1004 IEM_MC_END(); 996 1005 } … … 1008 1017 IEM_MC_ARG_CONST(uint8_t, iGRegArg, /*=*/iGReg, 3); 1009 1018 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/pVCpu->iem.s.enmEffOpSize, 4); 1010 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(iGReg); 1011 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); 1012 IEM_MC_CALL_CIMPL_5(IEM_CIMPL_F_MODE, iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 1019 IEM_MC_CALL_CIMPL_5(IEM_CIMPL_F_MODE, 1020 RT_BIT_64(kIemNativeGstReg_GprFirst + iGReg) 1021 | RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) 1022 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) 1023 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), 1024 iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 1013 1025 IEM_MC_END(); 1014 1026 } … … 1029 1041 IEM_MC_ARG_CONST(uint8_t, iGRegArg, /*=*/iGReg, 3); 1030 1042 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/pVCpu->iem.s.enmEffOpSize, 4); 1031 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(iGReg); 1032 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); 1033 IEM_MC_CALL_CIMPL_5(0, iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 1043 IEM_MC_CALL_CIMPL_5(0, 1044 RT_BIT_64(kIemNativeGstReg_GprFirst + iGReg) 1045 | RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) 1046 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) 1047 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), 1048 iemCImpl_load_SReg_Greg, uSel, offSeg, iSegRegArg, iGRegArg, enmEffOpSize); 1034 1049 IEM_MC_END(); 1035 1050 -
trunk/src/VBox/VMM/VMMAll/IEMAllInstOneByte.cpp.h
r101984 r102011 2653 2653 IEM_MC_FETCH_MEM_U16_DISP(u16UpperBounds, pVCpu->iem.s.iEffSeg, GCPtrEffSrc, 2); 2654 2654 2655 IEM_MC_CALL_CIMPL_3(0, iemCImpl_bound_16, u16Index, u16LowerBounds, u16UpperBounds); /* returns */2655 IEM_MC_CALL_CIMPL_3(0, 0, iemCImpl_bound_16, u16Index, u16LowerBounds, u16UpperBounds); /* returns */ 2656 2656 IEM_MC_END(); 2657 2657 } … … 2671 2671 IEM_MC_FETCH_MEM_U32_DISP(u32UpperBounds, pVCpu->iem.s.iEffSeg, GCPtrEffSrc, 4); 2672 2672 2673 IEM_MC_CALL_CIMPL_3(0, iemCImpl_bound_32, u32Index, u32LowerBounds, u32UpperBounds); /* returns */2673 IEM_MC_CALL_CIMPL_3(0, 0, iemCImpl_bound_32, u32Index, u32LowerBounds, u32UpperBounds); /* returns */ 2674 2674 IEM_MC_END(); 2675 2675 } … … 5898 5898 IEM_MC_ARG(uint16_t, u16Value, 1); \ 5899 5899 IEM_MC_FETCH_GREG_U16(u16Value, IEM_GET_MODRM_RM(pVCpu, bRm)); \ 5900 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); \ 5901 IEM_MC_CALL_CIMPL_2(a_fCImplFlags, iemCImpl_load_SReg, iSRegArg, u16Value); \ 5900 IEM_MC_CALL_CIMPL_2(a_fCImplFlags, \ 5901 RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) \ 5902 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) \ 5903 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), \ 5904 iemCImpl_load_SReg, iSRegArg, u16Value); \ 5902 5905 IEM_MC_END() 5903 5906 … … 5937 5940 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); \ 5938 5941 IEM_MC_FETCH_MEM_U16(u16Value, pVCpu->iem.s.iEffSeg, GCPtrEffDst); \ 5939 IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(iSegReg); \ 5940 IEM_MC_CALL_CIMPL_2(a_fCImplFlags, iemCImpl_load_SReg, iSRegArg, u16Value); \ 5942 IEM_MC_CALL_CIMPL_2(a_fCImplFlags, \ 5943 RT_BIT_64(kIemNativeGstReg_SegSelFirst + iSegReg) \ 5944 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + iSegReg) \ 5945 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + iSegReg), \ 5946 iemCImpl_load_SReg, iSRegArg, u16Value); \ 5941 5947 IEM_MC_END() 5942 5948 … … 6006 6012 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 6007 6013 IEM_MC_ARG_CONST(uint8_t, iEffSeg, pVCpu->iem.s.iEffSeg, 0); 6008 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xSP); 6009 IEM_MC_CALL_CIMPL_2(0, iemCImpl_pop_mem16, iEffSeg, GCPtrEffDst); 6014 IEM_MC_CALL_CIMPL_2(0, RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xSP), iemCImpl_pop_mem16, iEffSeg, GCPtrEffDst); 6010 6015 IEM_MC_END(); 6011 6016 break; … … 6017 6022 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 6018 6023 IEM_MC_ARG_CONST(uint8_t, iEffSeg, pVCpu->iem.s.iEffSeg, 0); 6019 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xSP); 6020 IEM_MC_CALL_CIMPL_2(0, iemCImpl_pop_mem32, iEffSeg, GCPtrEffDst); 6024 IEM_MC_CALL_CIMPL_2(0, RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xSP), iemCImpl_pop_mem32, iEffSeg, GCPtrEffDst); 6021 6025 IEM_MC_END(); 6022 6026 break; … … 6028 6032 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 6029 6033 IEM_MC_ARG_CONST(uint8_t, iEffSeg, pVCpu->iem.s.iEffSeg, 0); 6030 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xSP); 6031 IEM_MC_CALL_CIMPL_2(0, iemCImpl_pop_mem64, iEffSeg, GCPtrEffDst); 6034 IEM_MC_CALL_CIMPL_2(0, RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xSP), iemCImpl_pop_mem64, iEffSeg, GCPtrEffDst); 6032 6035 IEM_MC_END(); 6033 6036 break; … … 9723 9726 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/ pVCpu->iem.s.enmEffOpSize, 0); 9724 9727 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 1); 9725 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_fldenv, enmEffOpSize, iEffSeg, GCPtrEffSrc);9728 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_fldenv, enmEffOpSize, iEffSeg, GCPtrEffSrc); 9726 9729 IEM_MC_END(); 9727 9730 } … … 9743 9746 IEM_MC_FETCH_MEM_U16(u16Fsw, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 9744 9747 9745 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_FPU, iemCImpl_fldcw, u16Fsw);9748 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_FPU, 0, iemCImpl_fldcw, u16Fsw); 9746 9749 IEM_MC_END(); 9747 9750 } … … 9762 9765 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/ pVCpu->iem.s.enmEffOpSize, 0); 9763 9766 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 1); 9764 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_fnstenv, enmEffOpSize, iEffSeg, GCPtrEffDst);9767 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_fnstenv, enmEffOpSize, iEffSeg, GCPtrEffDst); 9765 9768 IEM_MC_END(); 9766 9769 } … … 9850 9853 IEM_MC_STORE_FPU_RESULT(FpuRes, 0, pVCpu->iem.s.uFpuOpcode); 9851 9854 } IEM_MC_ELSE() { 9852 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, iemCImpl_fxch_underflow, iStReg, uFpuOpcode);9855 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, 0, iemCImpl_fxch_underflow, iStReg, uFpuOpcode); 9853 9856 } IEM_MC_ENDIF(); 9854 9857 … … 11604 11607 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/ pVCpu->iem.s.enmEffOpSize, 0); 11605 11608 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 1); 11606 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_frstor, enmEffOpSize, iEffSeg, GCPtrEffSrc);11609 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_frstor, enmEffOpSize, iEffSeg, GCPtrEffSrc); 11607 11610 IEM_MC_END(); 11608 11611 } … … 11623 11626 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/ pVCpu->iem.s.enmEffOpSize, 0); 11624 11627 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 1); 11625 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_fnsave, enmEffOpSize, iEffSeg, GCPtrEffDst);11628 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_fnsave, enmEffOpSize, iEffSeg, GCPtrEffDst); 11626 11629 IEM_MC_END(); 11627 11630 } … … 13830 13833 IEM_MC_ARG(uint16_t, u16Target, 0); 13831 13834 IEM_MC_FETCH_GREG_U16(u16Target, IEM_GET_MODRM_RM(pVCpu, bRm)); 13832 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, iemCImpl_call_16, u16Target);13835 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, 0, iemCImpl_call_16, u16Target); 13833 13836 IEM_MC_END(); 13834 13837 break; … … 13839 13842 IEM_MC_ARG(uint32_t, u32Target, 0); 13840 13843 IEM_MC_FETCH_GREG_U32(u32Target, IEM_GET_MODRM_RM(pVCpu, bRm)); 13841 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, iemCImpl_call_32, u32Target);13844 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, 0, iemCImpl_call_32, u32Target); 13842 13845 IEM_MC_END(); 13843 13846 break; … … 13848 13851 IEM_MC_ARG(uint64_t, u64Target, 0); 13849 13852 IEM_MC_FETCH_GREG_U64(u64Target, IEM_GET_MODRM_RM(pVCpu, bRm)); 13850 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, iemCImpl_call_64, u64Target);13853 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, 0, iemCImpl_call_64, u64Target); 13851 13854 IEM_MC_END(); 13852 13855 break; … … 13867 13870 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 13868 13871 IEM_MC_FETCH_MEM_U16(u16Target, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 13869 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, iemCImpl_call_16, u16Target);13872 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, 0, iemCImpl_call_16, u16Target); 13870 13873 IEM_MC_END(); 13871 13874 break; … … 13878 13881 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 13879 13882 IEM_MC_FETCH_MEM_U32(u32Target, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 13880 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, iemCImpl_call_32, u32Target);13883 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, 0, iemCImpl_call_32, u32Target); 13881 13884 IEM_MC_END(); 13882 13885 break; … … 13889 13892 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 13890 13893 IEM_MC_FETCH_MEM_U64(u64Target, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 13891 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, iemCImpl_call_64, u64Target);13894 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_STACK, 0, iemCImpl_call_64, u64Target); 13892 13895 IEM_MC_END(); 13893 13896 break; … … 13925 13928 IEM_MC_FETCH_MEM_U16(offSeg, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); \ 13926 13929 IEM_MC_FETCH_MEM_U16_DISP(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc, 2); \ 13927 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xSP); \13928 13930 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_FAR | (a_fCImplExtra) \ 13929 | IEM_CIMPL_F_MODE | IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, \13931 | IEM_CIMPL_F_MODE | IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, 0, \ 13930 13932 a_fnCImpl, u16Sel, offSeg, enmEffOpSize); \ 13931 13933 IEM_MC_END(); \ … … 13942 13944 IEM_MC_FETCH_MEM_U32(offSeg, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); \ 13943 13945 IEM_MC_FETCH_MEM_U16_DISP(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc, 4); \ 13944 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xSP); \13945 13946 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_FAR | (a_fCImplExtra) \ 13946 | IEM_CIMPL_F_MODE | IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, \13947 | IEM_CIMPL_F_MODE | IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, 0, \ 13947 13948 a_fnCImpl, u16Sel, offSeg, enmEffOpSize); \ 13948 13949 IEM_MC_END(); \ … … 13960 13961 IEM_MC_FETCH_MEM_U64(offSeg, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); \ 13961 13962 IEM_MC_FETCH_MEM_U16_DISP(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc, 8); \ 13962 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xSP); \13963 13963 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_BRANCH_INDIRECT | IEM_CIMPL_F_BRANCH_FAR | (a_fCImplExtra) \ 13964 | IEM_CIMPL_F_MODE /* no gates */, \13964 | IEM_CIMPL_F_MODE /* no gates */, 0, \ 13965 13965 a_fnCImpl, u16Sel, offSeg, enmEffOpSize); \ 13966 13966 IEM_MC_END(); \ -
trunk/src/VBox/VMM/VMMAll/IEMAllInstPython.py
r101984 r102011 2232 2232 """ IEM_MC_CALL_CIMPL_0|1|2|3|4|5 """ 2233 2233 cArgs = int(sName[-1]); 2234 oSelf.checkStmtParamCount(sName, asParams, 2+ cArgs);2234 oSelf.checkStmtParamCount(sName, asParams, 3 + cArgs); 2235 2235 oSelf.parseCImplFlags(sName, asParams[0]); 2236 return McStmtCall(sName, asParams, 1);2236 return McStmtCall(sName, asParams, 2); 2237 2237 2238 2238 @staticmethod … … 2903 2903 'IEM_MC_FPU_STACK_UNDERFLOW_THEN_POP_POP': (McBlock.parseMcGeneric, True, False, ), 2904 2904 'IEM_MC_FPU_TO_MMX_MODE': (McBlock.parseMcGeneric, True, False, ), 2905 'IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG': (McBlock.parseMcGeneric, True, True, ), 2906 'IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG': (McBlock.parseMcGeneric, True, True, ), 2905 'IEM_MC_HINT_FLUSH_GUEST_SHADOW': (McBlock.parseMcGeneric, True, True, ), 2907 2906 'IEM_MC_IF_CX_IS_NZ': (McBlock.parseMcGenericCond, True, True, ), 2908 2907 'IEM_MC_IF_CX_IS_NZ_AND_EFL_BIT_NOT_SET': (McBlock.parseMcGenericCond, True, True, ), -
trunk/src/VBox/VMM/VMMAll/IEMAllInstThree0f38.cpp.h
r101951 r102011 1326 1326 IEM_MC_ARG(uint64_t, uInveptType, 2); 1327 1327 IEM_MC_FETCH_GREG_U64(uInveptType, IEM_GET_MODRM_REG(pVCpu, bRm)); 1328 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 1328 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 1329 1329 iemCImpl_invept, iEffSeg, GCPtrInveptDesc, uInveptType); 1330 1330 IEM_MC_END(); … … 1341 1341 IEM_MC_ARG(uint32_t, uInveptType, 2); 1342 1342 IEM_MC_FETCH_GREG_U32(uInveptType, IEM_GET_MODRM_REG(pVCpu, bRm)); 1343 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 1343 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 1344 1344 iemCImpl_invept, iEffSeg, GCPtrInveptDesc, uInveptType); 1345 1345 IEM_MC_END(); … … 1375 1375 IEM_MC_ARG(uint64_t, uInvvpidType, 2); 1376 1376 IEM_MC_FETCH_GREG_U64(uInvvpidType, IEM_GET_MODRM_REG(pVCpu, bRm)); 1377 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 1377 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 1378 1378 iemCImpl_invvpid, iEffSeg, GCPtrInvvpidDesc, uInvvpidType); 1379 1379 IEM_MC_END(); … … 1390 1390 IEM_MC_ARG(uint32_t, uInvvpidType, 2); 1391 1391 IEM_MC_FETCH_GREG_U32(uInvvpidType, IEM_GET_MODRM_REG(pVCpu, bRm)); 1392 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 1392 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 1393 1393 iemCImpl_invvpid, iEffSeg, GCPtrInvvpidDesc, uInvvpidType); 1394 1394 IEM_MC_END(); … … 1420 1420 IEM_MC_ARG(uint64_t, uInvpcidType, 2); 1421 1421 IEM_MC_FETCH_GREG_U64(uInvpcidType, IEM_GET_MODRM_REG(pVCpu, bRm)); 1422 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, iemCImpl_invpcid, iEffSeg, GCPtrInvpcidDesc, uInvpcidType);1422 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_invpcid, iEffSeg, GCPtrInvpcidDesc, uInvpcidType); 1423 1423 IEM_MC_END(); 1424 1424 } … … 1432 1432 IEM_MC_ARG(uint32_t, uInvpcidType, 2); 1433 1433 IEM_MC_FETCH_GREG_U32(uInvpcidType, IEM_GET_MODRM_REG(pVCpu, bRm)); 1434 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, iemCImpl_invpcid, iEffSeg, GCPtrInvpcidDesc, uInvpcidType);1434 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_invpcid, iEffSeg, GCPtrInvpcidDesc, uInvpcidType); 1435 1435 IEM_MC_END(); 1436 1436 } -
trunk/src/VBox/VMM/VMMAll/IEMAllInstTwoByte0f.cpp.h
r101984 r102011 1210 1210 IEMOP_HLP_DECODED_NL_1(OP_SLDT, IEMOPFORM_M_MEM, OP_PARM_Ew, DISOPTYPE_DANGEROUS | DISOPTYPE_PRIVILEGED_NOTRAP); 1211 1211 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1212 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_sldt_mem, iEffSeg, GCPtrEffDst);1212 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_sldt_mem, iEffSeg, GCPtrEffDst); 1213 1213 IEM_MC_END(); 1214 1214 } … … 1236 1236 IEMOP_HLP_DECODED_NL_1(OP_STR, IEMOPFORM_M_MEM, OP_PARM_Ew, DISOPTYPE_DANGEROUS | DISOPTYPE_PRIVILEGED_NOTRAP); 1237 1237 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1238 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_str_mem, iEffSeg, GCPtrEffDst);1238 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_str_mem, iEffSeg, GCPtrEffDst); 1239 1239 IEM_MC_END(); 1240 1240 } … … 1254 1254 IEM_MC_ARG(uint16_t, u16Sel, 0); 1255 1255 IEM_MC_FETCH_GREG_U16(u16Sel, IEM_GET_MODRM_RM(pVCpu, bRm)); 1256 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, iemCImpl_lldt, u16Sel);1256 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_lldt, u16Sel); 1257 1257 IEM_MC_END(); 1258 1258 } … … 1266 1266 IEM_MC_RAISE_GP0_IF_CPL_NOT_ZERO(); /** @todo test order */ 1267 1267 IEM_MC_FETCH_MEM_U16(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 1268 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, iemCImpl_lldt, u16Sel);1268 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_lldt, u16Sel); 1269 1269 IEM_MC_END(); 1270 1270 } … … 1285 1285 IEM_MC_ARG(uint16_t, u16Sel, 0); 1286 1286 IEM_MC_FETCH_GREG_U16(u16Sel, IEM_GET_MODRM_RM(pVCpu, bRm)); 1287 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, iemCImpl_ltr, u16Sel);1287 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_ltr, u16Sel); 1288 1288 IEM_MC_END(); 1289 1289 } … … 1297 1297 IEM_MC_RAISE_GP0_IF_CPL_NOT_ZERO(); /** @todo test order */ 1298 1298 IEM_MC_FETCH_MEM_U16(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 1299 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, iemCImpl_ltr, u16Sel);1299 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_ltr, u16Sel); 1300 1300 IEM_MC_END(); 1301 1301 } … … 1316 1316 IEM_MC_ARG_CONST(bool, fWriteArg, fWrite, 1); 1317 1317 IEM_MC_FETCH_GREG_U16(u16Sel, IEM_GET_MODRM_RM(pVCpu, bRm)); 1318 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_VerX, u16Sel, fWriteArg);1318 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_VerX, u16Sel, fWriteArg); 1319 1319 IEM_MC_END(); 1320 1320 } … … 1328 1328 IEMOP_HLP_DECODED_NL_1(fWrite ? OP_VERW : OP_VERR, IEMOPFORM_M_MEM, OP_PARM_Ew, DISOPTYPE_DANGEROUS | DISOPTYPE_PRIVILEGED_NOTRAP); 1329 1329 IEM_MC_FETCH_MEM_U16(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 1330 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_VerX, u16Sel, fWriteArg);1330 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_VerX, u16Sel, fWriteArg); 1331 1331 IEM_MC_END(); 1332 1332 } … … 1384 1384 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1385 1385 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1386 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_sgdt, iEffSeg, GCPtrEffSrc);1386 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_sgdt, iEffSeg, GCPtrEffSrc); 1387 1387 IEM_MC_END(); 1388 1388 } … … 1475 1475 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1476 1476 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1477 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_sidt, iEffSeg, GCPtrEffSrc);1477 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_sidt, iEffSeg, GCPtrEffSrc); 1478 1478 IEM_MC_END(); 1479 1479 } … … 1509 1509 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1510 1510 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSizeArg,/*=*/pVCpu->iem.s.enmEffOpSize, 2); 1511 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, iemCImpl_lgdt, iEffSeg, GCPtrEffSrc, enmEffOpSizeArg);1511 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_lgdt, iEffSeg, GCPtrEffSrc, enmEffOpSizeArg); 1512 1512 IEM_MC_END(); 1513 1513 } … … 1564 1564 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1565 1565 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSizeArg, /*=*/ enmEffOpSize, 2); 1566 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, iemCImpl_lidt, iEffSeg, GCPtrEffSrc, enmEffOpSizeArg);1566 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_lidt, iEffSeg, GCPtrEffSrc, enmEffOpSizeArg); 1567 1567 IEM_MC_END(); 1568 1568 } … … 1695 1695 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1696 1696 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 1697 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_smsw_mem, iEffSeg, GCPtrEffDst);1697 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_smsw_mem, iEffSeg, GCPtrEffDst); 1698 1698 IEM_MC_END(); 1699 1699 } … … 1714 1714 IEM_MC_ARG_CONST(RTGCPTR, GCPtrEffDst, NIL_RTGCPTR, 1); 1715 1715 IEM_MC_FETCH_GREG_U16(u16Tmp, IEM_GET_MODRM_RM(pVCpu, bRm)); 1716 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_MODE | IEM_CIMPL_F_VMEXIT, iemCImpl_lmsw, u16Tmp, GCPtrEffDst);1716 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_MODE | IEM_CIMPL_F_VMEXIT, 0, iemCImpl_lmsw, u16Tmp, GCPtrEffDst); 1717 1717 IEM_MC_END(); 1718 1718 } … … 1725 1725 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1726 1726 IEM_MC_FETCH_MEM_U16(u16Tmp, pVCpu->iem.s.iEffSeg, GCPtrEffDst); 1727 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_MODE | IEM_CIMPL_F_VMEXIT, iemCImpl_lmsw, u16Tmp, GCPtrEffDst);1727 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_MODE | IEM_CIMPL_F_VMEXIT, 0, iemCImpl_lmsw, u16Tmp, GCPtrEffDst); 1728 1728 IEM_MC_END(); 1729 1729 } … … 1740 1740 IEM_MC_CALC_RM_EFF_ADDR(GCPtrEffDst, bRm, 0); 1741 1741 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1742 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, iemCImpl_invlpg, GCPtrEffDst);1742 IEM_MC_CALL_CIMPL_1(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_invlpg, GCPtrEffDst); 1743 1743 IEM_MC_END(); 1744 1744 } … … 1873 1873 IEM_MC_FETCH_GREG_U16(u16Sel, IEM_GET_MODRM_RM(pVCpu, bRm)); 1874 1874 IEM_MC_REF_GREG_U16(pu16Dst, IEM_GET_MODRM_REG(pVCpu, bRm)); 1875 IEM_MC_ HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_REG(pVCpu, bRm));1876 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS,iemCImpl_LarLsl_u16, pu16Dst, u16Sel, fIsLarArg);1875 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS, RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_REG(pVCpu, bRm)), 1876 iemCImpl_LarLsl_u16, pu16Dst, u16Sel, fIsLarArg); 1877 1877 1878 1878 IEM_MC_END(); … … 1889 1889 IEM_MC_FETCH_GREG_U16(u16Sel, IEM_GET_MODRM_RM(pVCpu, bRm)); 1890 1890 IEM_MC_REF_GREG_U64(pu64Dst, IEM_GET_MODRM_REG(pVCpu, bRm)); 1891 IEM_MC_ HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_REG(pVCpu, bRm));1892 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS,iemCImpl_LarLsl_u64, pu64Dst, u16Sel, fIsLarArg);1891 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS, RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_REG(pVCpu, bRm)), 1892 iemCImpl_LarLsl_u64, pu64Dst, u16Sel, fIsLarArg); 1893 1893 1894 1894 IEM_MC_END(); … … 1914 1914 IEM_MC_FETCH_MEM_U16(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 1915 1915 IEM_MC_REF_GREG_U16(pu16Dst, IEM_GET_MODRM_REG(pVCpu, bRm)); 1916 IEM_MC_ HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_REG(pVCpu, bRm));1917 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS,iemCImpl_LarLsl_u16, pu16Dst, u16Sel, fIsLarArg);1916 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS, RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_REG(pVCpu, bRm)), 1917 iemCImpl_LarLsl_u16, pu16Dst, u16Sel, fIsLarArg); 1918 1918 1919 1919 IEM_MC_END(); … … 1934 1934 IEM_MC_FETCH_MEM_U16(u16Sel, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 1935 1935 IEM_MC_REF_GREG_U64(pu64Dst, IEM_GET_MODRM_REG(pVCpu, bRm)); 1936 IEM_MC_ HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_REG(pVCpu, bRm));1937 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS,iemCImpl_LarLsl_u64, pu64Dst, u16Sel, fIsLarArg);1936 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_STATUS_FLAGS, RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_REG(pVCpu, bRm)), 1937 iemCImpl_LarLsl_u64, pu64Dst, u16Sel, fIsLarArg); 1938 1938 1939 1939 IEM_MC_END(); … … 7134 7134 IEM_MC_FETCH_GREG_U64(u64Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7135 7135 IEM_MC_REF_GREG_U64(pu64Dst, IEM_GET_MODRM_RM(pVCpu, bRm)); 7136 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_RM(pVCpu, bRm)); 7137 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmread_reg64, pu64Dst, u64Enc); 7136 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 7137 RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_RM(pVCpu, bRm)), 7138 iemCImpl_vmread_reg64, pu64Dst, u64Enc); 7138 7139 IEM_MC_END(); 7139 7140 } … … 7146 7147 IEM_MC_FETCH_GREG_U32(u32Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7147 7148 IEM_MC_REF_GREG_U64(pu64Dst, IEM_GET_MODRM_RM(pVCpu, bRm)); 7148 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_RM(pVCpu, bRm)); 7149 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmread_reg32, pu64Dst, u32Enc); 7149 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 7150 RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_RM(pVCpu, bRm)), 7151 iemCImpl_vmread_reg32, pu64Dst, u32Enc); 7150 7152 IEM_MC_END(); 7151 7153 } … … 7165 7167 IEM_MC_ARG(uint64_t, u64Enc, 2); 7166 7168 IEM_MC_FETCH_GREG_U64(u64Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7167 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 7169 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 7168 7170 iemCImpl_vmread_mem_reg64, iEffSeg, GCPtrVal, u64Enc); 7169 7171 IEM_MC_END(); … … 7178 7180 IEM_MC_ARG(uint32_t, u32Enc, 2); 7179 7181 IEM_MC_FETCH_GREG_U32(u32Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7180 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 7182 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 7181 7183 iemCImpl_vmread_mem_reg32, iEffSeg, GCPtrVal, u32Enc); 7182 7184 IEM_MC_END(); … … 7216 7218 IEM_MC_FETCH_GREG_U64(u64Val, IEM_GET_MODRM_RM(pVCpu, bRm)); 7217 7219 IEM_MC_FETCH_GREG_U64(u64Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7218 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmwrite_reg, u64Val, u64Enc);7220 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_vmwrite_reg, u64Val, u64Enc); 7219 7221 IEM_MC_END(); 7220 7222 } … … 7227 7229 IEM_MC_FETCH_GREG_U32(u32Val, IEM_GET_MODRM_RM(pVCpu, bRm)); 7228 7230 IEM_MC_FETCH_GREG_U32(u32Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7229 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmwrite_reg, u32Val, u32Enc);7231 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_vmwrite_reg, u32Val, u32Enc); 7230 7232 IEM_MC_END(); 7231 7233 } … … 7245 7247 IEM_MC_ARG(uint64_t, u64Enc, 2); 7246 7248 IEM_MC_FETCH_GREG_U64(u64Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7247 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 7249 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 7248 7250 iemCImpl_vmwrite_mem, iEffSeg, GCPtrVal, u64Enc); 7249 7251 IEM_MC_END(); … … 7258 7260 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 7259 7261 IEM_MC_FETCH_GREG_U32(u32Enc, IEM_GET_MODRM_REG(pVCpu, bRm)); 7260 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 7262 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, 7261 7263 iemCImpl_vmwrite_mem, iEffSeg, GCPtrVal, u32Enc); 7262 7264 IEM_MC_END(); … … 9792 9794 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9793 9795 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/pVCpu->iem.s.enmEffOpSize, 2); 9794 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_fxsave, iEffSeg, GCPtrEff, enmEffOpSize);9796 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_fxsave, iEffSeg, GCPtrEff, enmEffOpSize); 9795 9797 IEM_MC_END(); 9796 9798 } … … 9811 9813 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9812 9814 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/pVCpu->iem.s.enmEffOpSize, 2); 9813 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_fxrstor, iEffSeg, GCPtrEff, enmEffOpSize);9815 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_fxrstor, iEffSeg, GCPtrEff, enmEffOpSize); 9814 9816 IEM_MC_END(); 9815 9817 } … … 9847 9849 IEM_MC_ACTUALIZE_SSE_STATE_FOR_READ(); 9848 9850 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9849 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, iemCImpl_ldmxcsr, iEffSeg, GCPtrEff);9851 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, 0, iemCImpl_ldmxcsr, iEffSeg, GCPtrEff); 9850 9852 IEM_MC_END(); 9851 9853 } … … 9882 9884 IEM_MC_ACTUALIZE_SSE_STATE_FOR_READ(); 9883 9885 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9884 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, iemCImpl_stmxcsr, iEffSeg, GCPtrEff);9886 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, 0, iemCImpl_stmxcsr, iEffSeg, GCPtrEff); 9885 9887 IEM_MC_END(); 9886 9888 } … … 9908 9910 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9909 9911 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/ pVCpu->iem.s.enmEffOpSize, 2); 9910 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_xsave, iEffSeg, GCPtrEff, enmEffOpSize);9912 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_xsave, iEffSeg, GCPtrEff, enmEffOpSize); 9911 9913 IEM_MC_END(); 9912 9914 } … … 9934 9936 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9935 9937 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize, /*=*/ pVCpu->iem.s.enmEffOpSize, 2); 9936 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, iemCImpl_xrstor, iEffSeg, GCPtrEff, enmEffOpSize);9938 IEM_MC_CALL_CIMPL_3(IEM_CIMPL_F_FPU, 0, iemCImpl_xrstor, iEffSeg, GCPtrEff, enmEffOpSize); 9937 9939 IEM_MC_END(); 9938 9940 } … … 9960 9962 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 9961 9963 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9962 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_clflush_clflushopt, iEffSeg, GCPtrEff);9964 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_clflush_clflushopt, iEffSeg, GCPtrEff); 9963 9965 IEM_MC_END(); 9964 9966 } … … 9983 9985 IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 9984 9986 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 9985 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, iemCImpl_clflush_clflushopt, iEffSeg, GCPtrEff);9987 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT, 0, iemCImpl_clflush_clflushopt, iEffSeg, GCPtrEff); 9986 9988 IEM_MC_END(); 9987 9989 } … … 12497 12499 IEM_MC_REF_LOCAL(pu128RbxRcx, u128RbxRcx); \ 12498 12500 \ 12499 IEM_MC_FETCH_EFLAGS(EFlags); \ 12500 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xAX); \ 12501 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(X86_GREG_xDX) 12501 IEM_MC_FETCH_EFLAGS(EFlags) 12502 12502 12503 12503 #define BODY_CMPXCHG16B_TAIL \ … … 12540 12540 BODY_CMPXCHG16B_HEAD; 12541 12541 IEM_MC_CALL_CIMPL_4(IEM_CIMPL_F_STATUS_FLAGS, 12542 RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xAX) 12543 | RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xDX), 12542 12544 iemCImpl_cmpxchg16b_fallback_rendezvous, pu128MemDst, pu128RaxRdx, pu128RbxRcx, pEFlags); 12543 12545 IEM_MC_END(); … … 12574 12576 { 12575 12577 BODY_CMPXCHG16B_HEAD; 12576 IEM_MC_CALL_CIMPL_4(IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_cmpxchg16b_fallback_rendezvous, 12578 IEM_MC_CALL_CIMPL_4(IEM_CIMPL_F_STATUS_FLAGS, 12579 RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xAX) 12580 | RT_BIT_64(kIemNativeGstReg_GprFirst + X86_GREG_xDX), 12581 iemCImpl_cmpxchg16b_fallback_rendezvous, 12577 12582 pu128MemDst, pu128RaxRdx, pu128RbxRcx, pEFlags); 12578 12583 IEM_MC_END(); … … 12607 12612 IEM_MC_ARG_CONST(uint8_t, iReg, /*=*/ IEM_GET_MODRM_RM(pVCpu, bRm), 0); 12608 12613 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/ pVCpu->iem.s.enmEffOpSize, 1); 12609 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_RM(pVCpu, bRm)); 12610 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, iemCImpl_rdrand, iReg, enmEffOpSize); 12614 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, 12615 RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_RM(pVCpu, bRm)), 12616 iemCImpl_rdrand, iReg, enmEffOpSize); 12611 12617 IEM_MC_END(); 12612 12618 } … … 12628 12634 IEMOP_HLP_DONE_DECODING_NO_SIZE_OP_REPZ_OR_REPNZ_PREFIXES(); 12629 12635 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 12630 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmptrld, iEffSeg, GCPtrEffSrc);12636 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_vmptrld, iEffSeg, GCPtrEffSrc); 12631 12637 IEM_MC_END(); 12632 12638 } … … 12647 12653 IEMOP_HLP_DONE_DECODING(); 12648 12654 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 12649 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmclear, iEffSeg, GCPtrEffDst);12655 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_vmclear, iEffSeg, GCPtrEffDst); 12650 12656 IEM_MC_END(); 12651 12657 } … … 12665 12671 IEMOP_HLP_DONE_DECODING(); 12666 12672 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 12667 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmxon, iEffSeg, GCPtrEffSrc);12673 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_vmxon, iEffSeg, GCPtrEffSrc); 12668 12674 IEM_MC_END(); 12669 12675 } … … 12684 12690 IEMOP_HLP_DONE_DECODING_NO_SIZE_OP_REPZ_OR_REPNZ_PREFIXES(); 12685 12691 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 12686 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, iemCImpl_vmptrst, iEffSeg, GCPtrEffDst);12692 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_VMEXIT | IEM_CIMPL_F_STATUS_FLAGS, 0, iemCImpl_vmptrst, iEffSeg, GCPtrEffDst); 12687 12693 IEM_MC_END(); 12688 12694 } … … 12704 12710 IEM_MC_ARG_CONST(uint8_t, iReg, /*=*/ IEM_GET_MODRM_RM(pVCpu, bRm), 0); 12705 12711 IEM_MC_ARG_CONST(IEMMODE, enmEffOpSize,/*=*/ pVCpu->iem.s.enmEffOpSize, 1); 12706 IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(IEM_GET_MODRM_RM(pVCpu, bRm)); 12707 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, iemCImpl_rdseed, iReg, enmEffOpSize); 12712 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_RFLAGS | IEM_CIMPL_F_VMEXIT, 12713 RT_BIT_64(kIemNativeGstReg_GprFirst + IEM_GET_MODRM_RM(pVCpu, bRm)), 12714 iemCImpl_rdseed, iReg, enmEffOpSize); 12708 12715 IEM_MC_END(); 12709 12716 } -
trunk/src/VBox/VMM/VMMAll/IEMAllInstVexMap1.cpp.h
r101953 r102011 4293 4293 IEM_MC_ACTUALIZE_SSE_STATE_FOR_READ(); 4294 4294 IEM_MC_ARG_CONST(uint8_t, iEffSeg, /*=*/ pVCpu->iem.s.iEffSeg, 0); 4295 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, iemCImpl_vstmxcsr, iEffSeg, GCPtrEff);4295 IEM_MC_CALL_CIMPL_2(IEM_CIMPL_F_FPU, 0, iemCImpl_vstmxcsr, iEffSeg, GCPtrEff); 4296 4296 IEM_MC_END(); 4297 4297 } -
trunk/src/VBox/VMM/VMMAll/IEMAllN8veRecompiler.cpp
r102010 r102011 5537 5537 DECL_HIDDEN_THROW(uint32_t) 5538 5538 iemNativeEmitCallCImplCommon(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, 5539 uint ptr_t pfnCImpl, uint8_t cArgs)5539 uint64_t fGstShwFlush, uintptr_t pfnCImpl, uint8_t cArgs) 5540 5540 5541 5541 { … … 5569 5569 off = iemNativeEmitLoadGprByBpU32(pReNative, off, X86_GREG_xAX, IEMNATIVE_FP_OFF_IN_SHADOW_ARG0); /* rcStrict (see above) */ 5570 5570 #endif 5571 uint64_t fGstShwFlush = iemNativeCImplFlagsToGuestShadowFlushMask(pReNative->fCImpl,RT_BIT_64(kIemNativeGstReg_Pc));5571 fGstShwFlush = iemNativeCImplFlagsToGuestShadowFlushMask(pReNative->fCImpl, fGstShwFlush | RT_BIT_64(kIemNativeGstReg_Pc)); 5572 5572 if (!(pReNative->fMc & IEM_MC_F_WITHOUT_FLAGS)) /** @todo We don't emit with-flags/without-flags variations for CIMPL calls. */ 5573 5573 fGstShwFlush |= RT_BIT_64(kIemNativeGstReg_EFlags); … … 5578 5578 5579 5579 5580 #define IEM_MC_CALL_CIMPL_1_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0) \5581 off = iemNativeEmitCallCImpl1(pReNative, off, a_cbInstr, pCallEntry->idxInstr, (uintptr_t)a_pfnCImpl, a0)5580 #define IEM_MC_CALL_CIMPL_1_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0) \ 5581 off = iemNativeEmitCallCImpl1(pReNative, off, a_cbInstr, pCallEntry->idxInstr, a_fGstShwFlush, (uintptr_t)a_pfnCImpl, a0) 5582 5582 5583 5583 /** Emits code for IEM_MC_CALL_CIMPL_1. */ 5584 5584 DECL_INLINE_THROW(uint32_t) 5585 iemNativeEmitCallCImpl1(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, 5585 iemNativeEmitCallCImpl1(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, uint64_t fGstShwFlush, 5586 5586 uintptr_t pfnCImpl, uint8_t idxArg0) 5587 5587 { … … 5590 5590 RT_NOREF_PV(idxArg0); 5591 5591 5592 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, pfnCImpl, 1);5593 } 5594 5595 5596 #define IEM_MC_CALL_CIMPL_2_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0, a1) \5597 off = iemNativeEmitCallCImpl2(pReNative, off, a_cbInstr, pCallEntry->idxInstr, (uintptr_t)a_pfnCImpl, a0, a1)5592 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, fGstShwFlush, pfnCImpl, 1); 5593 } 5594 5595 5596 #define IEM_MC_CALL_CIMPL_2_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1) \ 5597 off = iemNativeEmitCallCImpl2(pReNative, off, a_cbInstr, pCallEntry->idxInstr, a_fGstShwFlush, (uintptr_t)a_pfnCImpl, a0, a1) 5598 5598 5599 5599 /** Emits code for IEM_MC_CALL_CIMPL_2. */ 5600 5600 DECL_INLINE_THROW(uint32_t) 5601 iemNativeEmitCallCImpl2(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, 5601 iemNativeEmitCallCImpl2(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, uint64_t fGstShwFlush, 5602 5602 uintptr_t pfnCImpl, uint8_t idxArg0, uint8_t idxArg1) 5603 5603 { … … 5610 5610 RT_NOREF_PV(idxArg1); 5611 5611 5612 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, pfnCImpl, 2); 5613 } 5614 5615 5616 #define IEM_MC_CALL_CIMPL_3_THREADED(a_cbInstr, a_fFlags, a_pfnCImpl, a0, a1, a2) \ 5617 off = iemNativeEmitCallCImpl3(pReNative, off, a_cbInstr, pCallEntry->idxInstr, (uintptr_t)a_pfnCImpl, a0, a1, a2) 5612 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, fGstShwFlush, pfnCImpl, 2); 5613 } 5614 5615 5616 #define IEM_MC_CALL_CIMPL_3_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2) \ 5617 off = iemNativeEmitCallCImpl3(pReNative, off, a_cbInstr, pCallEntry->idxInstr, a_fGstShwFlush, \ 5618 (uintptr_t)a_pfnCImpl, a0, a1, a2) 5618 5619 5619 5620 /** Emits code for IEM_MC_CALL_CIMPL_3. */ 5620 5621 DECL_INLINE_THROW(uint32_t) 5621 iemNativeEmitCallCImpl3(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, 5622 iemNativeEmitCallCImpl3(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, uint64_t fGstShwFlush, 5622 5623 uintptr_t pfnCImpl, uint8_t idxArg0, uint8_t idxArg1, uint8_t idxArg2) 5623 5624 { … … 5635 5636 RT_NOREF_PV(idxArg2); 5636 5637 5637 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, pfnCImpl, 3); 5638 } 5639 5640 5641 #define IEM_MC_CALL_CIMPL_4_THREADED(a_cbInstr, a_fFlags, a_pfnCImpl, a0, a1, a2, a3) \ 5642 off = iemNativeEmitCallCImpl4(pReNative, off, a_cbInstr, pCallEntry->idxInstr, (uintptr_t)a_pfnCImpl, a0, a1, a2, a3) 5638 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, fGstShwFlush, pfnCImpl, 3); 5639 } 5640 5641 5642 #define IEM_MC_CALL_CIMPL_4_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3) \ 5643 off = iemNativeEmitCallCImpl4(pReNative, off, a_cbInstr, pCallEntry->idxInstr, a_fGstShwFlush, \ 5644 (uintptr_t)a_pfnCImpl, a0, a1, a2, a3) 5643 5645 5644 5646 /** Emits code for IEM_MC_CALL_CIMPL_4. */ 5645 5647 DECL_INLINE_THROW(uint32_t) 5646 iemNativeEmitCallCImpl4(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, 5648 iemNativeEmitCallCImpl4(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, uint64_t fGstShwFlush, 5647 5649 uintptr_t pfnCImpl, uint8_t idxArg0, uint8_t idxArg1, uint8_t idxArg2, uint8_t idxArg3) 5648 5650 { … … 5664 5666 RT_NOREF_PV(idxArg3); 5665 5667 5666 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, pfnCImpl, 4); 5667 } 5668 5669 5670 #define IEM_MC_CALL_CIMPL_5_THREADED(a_cbInstr, a_fFlags, a_pfnCImpl, a0, a1, a2, a3, a4) \ 5671 off = iemNativeEmitCallCImpl5(pReNative, off, a_cbInstr, pCallEntry->idxInstr, (uintptr_t)a_pfnCImpl, a0, a1, a2, a3, a4) 5668 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, fGstShwFlush, pfnCImpl, 4); 5669 } 5670 5671 5672 #define IEM_MC_CALL_CIMPL_5_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3, a4) \ 5673 off = iemNativeEmitCallCImpl5(pReNative, off, a_cbInstr, pCallEntry->idxInstr, a_fGstShwFlush, \ 5674 (uintptr_t)a_pfnCImpl, a0, a1, a2, a3, a4) 5672 5675 5673 5676 /** Emits code for IEM_MC_CALL_CIMPL_4. */ 5674 5677 DECL_INLINE_THROW(uint32_t) 5675 iemNativeEmitCallCImpl5(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, 5678 iemNativeEmitCallCImpl5(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t cbInstr, uint8_t idxInstr, uint64_t fGstShwFlush, 5676 5679 uintptr_t pfnCImpl, uint8_t idxArg0, uint8_t idxArg1, uint8_t idxArg2, uint8_t idxArg3, uint8_t idxArg4) 5677 5680 { … … 5697 5700 RT_NOREF_PV(idxArg4); 5698 5701 5699 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, pfnCImpl, 5); 5700 } 5701 5702 5703 /** Flush guest GPR shadow copy. */ 5704 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(a_iGReg) \ 5705 iemNativeRegFlushGuestShadows(pReNative, RT_BIT_64(kIemNativeGstReg_GprFirst + (a_iGReg)) ) 5706 5707 /** Flush guest segment register (hidden and non-hidden bits) shadow copy. */ 5708 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(a_iSReg) \ 5709 iemNativeRegFlushGuestShadows(pReNative, \ 5710 RT_BIT_64(kIemNativeGstReg_SegSelFirst + (a_iSReg)) \ 5711 | RT_BIT_64(kIemNativeGstReg_SegBaseFirst + (a_iSReg)) \ 5712 | RT_BIT_64(kIemNativeGstReg_SegLimitFirst + (a_iSReg)) ) 5702 return iemNativeEmitCallCImplCommon(pReNative, off, cbInstr, idxInstr, fGstShwFlush, pfnCImpl, 5); 5703 } 5704 5705 5706 /** Recompiler debugging: Flush guest register shadow copies. */ 5707 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW(g_fGstShwFlush) iemNativeRegFlushGuestShadows(pReNative, g_fGstShwFlush) 5708 5713 5709 5714 5710 -
trunk/src/VBox/VMM/VMMAll/IEMAllThrdFuncs.cpp
r101984 r102011 251 251 252 252 /** Variant of IEM_MC_CALL_CIMPL_1 with explicit instruction length parameter. */ 253 #define IEM_MC_CALL_CIMPL_1_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0) \253 #define IEM_MC_CALL_CIMPL_1_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0) \ 254 254 return (a_pfnCImpl)(pVCpu, (a_cbInstr), a0) 255 255 #undef IEM_MC_CALL_CIMPL_1 256 256 257 257 /** Variant of IEM_MC_CALL_CIMPL_2 with explicit instruction length parameter. */ 258 #define IEM_MC_CALL_CIMPL_2_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0, a1) \258 #define IEM_MC_CALL_CIMPL_2_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1) \ 259 259 return (a_pfnCImpl)(pVCpu, (a_cbInstr), a0, a1) 260 260 #undef IEM_MC_CALL_CIMPL_2 261 261 262 262 /** Variant of IEM_MC_CALL_CIMPL_3 with explicit instruction length parameter. */ 263 #define IEM_MC_CALL_CIMPL_3_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0, a1, a2) \263 #define IEM_MC_CALL_CIMPL_3_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2) \ 264 264 return (a_pfnCImpl)(pVCpu, (a_cbInstr), a0, a1, a2) 265 265 #undef IEM_MC_CALL_CIMPL_3 266 266 267 267 /** Variant of IEM_MC_CALL_CIMPL_4 with explicit instruction length parameter. */ 268 #define IEM_MC_CALL_CIMPL_4_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0, a1, a2, a3) \268 #define IEM_MC_CALL_CIMPL_4_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3) \ 269 269 return (a_pfnCImpl)(pVCpu, (a_cbInstr), a0, a1, a2, a3) 270 270 #undef IEM_MC_CALL_CIMPL_4 271 271 272 272 /** Variant of IEM_MC_CALL_CIMPL_5 with explicit instruction length parameter. */ 273 #define IEM_MC_CALL_CIMPL_5_THREADED(a_cbInstr, a_fFlags, a_ pfnCImpl, a0, a1, a2, a3, a4) \273 #define IEM_MC_CALL_CIMPL_5_THREADED(a_cbInstr, a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3, a4) \ 274 274 return (a_pfnCImpl)(pVCpu, (a_cbInstr), a0, a1, a2, a3, a4) 275 275 #undef IEM_MC_CALL_CIMPL_5 -
trunk/src/VBox/VMM/VMMAll/IEMAllThrdPython.py
r102010 r102011 1040 1040 # Skip the hint parameter (first) for IEM_MC_CALL_CIMPL_X. 1041 1041 if oStmt.sName.startswith('IEM_MC_CALL_CIMPL_'): 1042 assert oStmt.idxFn == 1;1042 assert oStmt.idxFn == 2; 1043 1043 aiSkipParams[0] = True; 1044 1044 -
trunk/src/VBox/VMM/include/IEMMc.h
r101984 r102011 2023 2023 * 2024 2024 * @param a_fFlags IEM_CIMPL_F_XXX. 2025 * @param a_fGstShwFlush Guest shadow register copies needing to be flushed 2026 * in the native recompiler. 2025 2027 * @param a_pfnCImpl The pointer to the C routine. 2026 2028 * @sa IEM_DECL_IMPL_C_TYPE_0 and IEM_CIMPL_DEF_0. 2027 2029 */ 2028 #define IEM_MC_CALL_CIMPL_0(a_fFlags, a_ pfnCImpl) \2030 #define IEM_MC_CALL_CIMPL_0(a_fFlags, a_fGstShwFlush, a_pfnCImpl) \ 2029 2031 IEM_MC_CALL_CIMPL_HLP_RET(a_fFlags, (a_pfnCImpl)(pVCpu, IEM_GET_INSTR_LEN(pVCpu))) 2030 2032 … … 2034 2036 * 2035 2037 * @param a_fFlags IEM_CIMPL_F_XXX. 2038 * @param a_fGstShwFlush Guest shadow register copies needing to be flushed 2039 * in the native recompiler. 2036 2040 * @param a_pfnCImpl The pointer to the C routine. 2037 2041 * @param a0 The argument. 2038 2042 */ 2039 #define IEM_MC_CALL_CIMPL_1(a_fFlags, a_ pfnCImpl, a0) \2043 #define IEM_MC_CALL_CIMPL_1(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0) \ 2040 2044 IEM_MC_CALL_CIMPL_HLP_RET(a_fFlags, (a_pfnCImpl)(pVCpu, IEM_GET_INSTR_LEN(pVCpu), a0)) 2041 2045 … … 2045 2049 * 2046 2050 * @param a_fFlags IEM_CIMPL_F_XXX. 2051 * @param a_fGstShwFlush Guest shadow register copies needing to be flushed 2052 * in the native recompiler. 2047 2053 * @param a_pfnCImpl The pointer to the C routine. 2048 2054 * @param a0 The first extra argument. 2049 2055 * @param a1 The second extra argument. 2050 2056 */ 2051 #define IEM_MC_CALL_CIMPL_2(a_fFlags, a_ pfnCImpl, a0, a1) \2057 #define IEM_MC_CALL_CIMPL_2(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1) \ 2052 2058 IEM_MC_CALL_CIMPL_HLP_RET(a_fFlags, (a_pfnCImpl)(pVCpu, IEM_GET_INSTR_LEN(pVCpu), a0, a1)) 2053 2059 … … 2057 2063 * 2058 2064 * @param a_fFlags IEM_CIMPL_F_XXX. 2065 * @param a_fGstShwFlush Guest shadow register copies needing to be flushed 2066 * in the native recompiler. 2059 2067 * @param a_pfnCImpl The pointer to the C routine. 2060 2068 * @param a0 The first extra argument. … … 2062 2070 * @param a2 The third extra argument. 2063 2071 */ 2064 #define IEM_MC_CALL_CIMPL_3(a_fFlags, a_ pfnCImpl, a0, a1, a2) \2072 #define IEM_MC_CALL_CIMPL_3(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2) \ 2065 2073 IEM_MC_CALL_CIMPL_HLP_RET(a_fFlags, (a_pfnCImpl)(pVCpu, IEM_GET_INSTR_LEN(pVCpu), a0, a1, a2)) 2066 2074 … … 2070 2078 * 2071 2079 * @param a_fFlags IEM_CIMPL_F_XXX. 2080 * @param a_fGstShwFlush Guest shadow register copies needing to be flushed 2081 * in the native recompiler. 2072 2082 * @param a_pfnCImpl The pointer to the C routine. 2073 2083 * @param a0 The first extra argument. … … 2076 2086 * @param a3 The fourth extra argument. 2077 2087 */ 2078 #define IEM_MC_CALL_CIMPL_4(a_fFlags, a_ pfnCImpl, a0, a1, a2, a3) \2088 #define IEM_MC_CALL_CIMPL_4(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3) \ 2079 2089 IEM_MC_CALL_CIMPL_HLP_RET(a_fFlags, (a_pfnCImpl)(pVCpu, IEM_GET_INSTR_LEN(pVCpu), a0, a1, a2, a3)) 2080 2090 … … 2084 2094 * 2085 2095 * @param a_fFlags IEM_CIMPL_F_XXX. 2096 * @param a_fGstShwFlush Guest shadow register copies needing to be flushed 2097 * in the native recompiler. 2086 2098 * @param a_pfnCImpl The pointer to the C routine. 2087 2099 * @param a0 The first extra argument. … … 2091 2103 * @param a4 The fifth extra argument. 2092 2104 */ 2093 #define IEM_MC_CALL_CIMPL_5(a_fFlags, a_ pfnCImpl, a0, a1, a2, a3, a4) \2105 #define IEM_MC_CALL_CIMPL_5(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3, a4) \ 2094 2106 IEM_MC_CALL_CIMPL_HLP_RET(a_fFlags, (a_pfnCImpl)(pVCpu, IEM_GET_INSTR_LEN(pVCpu), a0, a1, a2, a3, a4)) 2095 2107 … … 2503 2515 2504 2516 2505 /** Native recompiler GREG shadow copy flush hint related to CIMPL calls. */ 2506 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(a_iGReg) ((void)0) 2507 /** Native recompiler SREG shadow copy flush hint related to CIMPL calls. */ 2508 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(a_iSReg) ((void)0) 2517 /** Recompiler debugging: Flush guest register shadow copies. */ 2518 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW(g_fGstShwFlush) ((void)0) 2509 2519 2510 2520 /** @} */ -
trunk/src/VBox/VMM/testcase/tstIEMCheckMc.cpp
r101984 r102011 930 930 #define IEM_MC_CALL_AIMPL_4(a_rc, a_pfn, a0, a1, a2, a3) \ 931 931 do { CHK_CALL_ARG(a0, 0); CHK_CALL_ARG(a1, 1); CHK_CALL_ARG(a2, 2); CHK_CALL_ARG(a3, 3); (a_rc) = VINF_SUCCESS; (void)fMcBegin; } while (0) 932 #define IEM_MC_CALL_CIMPL_0(a_fFlags, a_ pfnCImpl) do { (void)fMcBegin; } while (0)933 #define IEM_MC_CALL_CIMPL_1(a_fFlags, a_ pfnCImpl, a0) \932 #define IEM_MC_CALL_CIMPL_0(a_fFlags, a_fGstShwFlush, a_pfnCImpl) do { (void)fMcBegin; } while (0) 933 #define IEM_MC_CALL_CIMPL_1(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0) \ 934 934 do { CHK_CALL_ARG(a0, 0); (void)fMcBegin; return VINF_SUCCESS; } while (0) 935 #define IEM_MC_CALL_CIMPL_2(a_fFlags, a_ pfnCImpl, a0, a1) \935 #define IEM_MC_CALL_CIMPL_2(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1) \ 936 936 do { CHK_CALL_ARG(a0, 0); CHK_CALL_ARG(a1, 1); (void)fMcBegin; return VINF_SUCCESS; } while (0) 937 #define IEM_MC_CALL_CIMPL_3(a_fFlags, a_ pfnCImpl, a0, a1, a2) \937 #define IEM_MC_CALL_CIMPL_3(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2) \ 938 938 do { CHK_CALL_ARG(a0, 0); CHK_CALL_ARG(a1, 1); CHK_CALL_ARG(a2, 2); (void)fMcBegin; return VINF_SUCCESS; } while (0) 939 #define IEM_MC_CALL_CIMPL_4(a_fFlags, a_ pfnCImpl, a0, a1, a2, a3) \939 #define IEM_MC_CALL_CIMPL_4(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3) \ 940 940 do { CHK_CALL_ARG(a0, 0); CHK_CALL_ARG(a1, 1); CHK_CALL_ARG(a2, 2); CHK_CALL_ARG(a3, 3); (void)fMcBegin; return VINF_SUCCESS; } while (0) 941 #define IEM_MC_CALL_CIMPL_5(a_fFlags, a_ pfnCImpl, a0, a1, a2, a3, a4) \941 #define IEM_MC_CALL_CIMPL_5(a_fFlags, a_fGstShwFlush, a_pfnCImpl, a0, a1, a2, a3, a4) \ 942 942 do { CHK_CALL_ARG(a0, 0); CHK_CALL_ARG(a1, 1); CHK_CALL_ARG(a2, 2); CHK_CALL_ARG(a3, 3); CHK_CALL_ARG(a4, 4); (void)fMcBegin; return VINF_SUCCESS; } while (0) 943 943 #define IEM_MC_DEFER_TO_CIMPL_0_RET(a_fFlags, a_fGstShwFlush, a_pfnCImpl) return VINF_SUCCESS … … 1043 1043 #define IEM_MC_ENDIF() } do { (void)fMcBegin; } while (0) 1044 1044 1045 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW_GREG(a_iGReg) ((void)fMcBegin) 1046 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW_SREG(a_iSReg) ((void)fMcBegin) 1045 #define IEM_MC_HINT_FLUSH_GUEST_SHADOW(g_fGstShwFlush) ((void)fMcBegin) 1047 1046 1048 1047 /** @} */
Note:
See TracChangeset
for help on using the changeset viewer.