- Timestamp:
- Apr 5, 2024 12:55:25 PM (10 months ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAllInstPython.py
r104177 r104183 3162 3162 'IEM_MC_IF_GREG_BIT_SET': (McBlock.parseMcGenericCond, True, False, True, ), 3163 3163 'IEM_MC_IF_LOCAL_IS_Z': (McBlock.parseMcGenericCond, True, False, True, ), 3164 'IEM_MC_IF_MXCSR_XCPT_PENDING': (McBlock.parseMcGenericCond, True, True, g_fNativeSimd),3165 3164 'IEM_MC_IF_RCX_IS_NZ': (McBlock.parseMcGenericCond, True, False, True, ), 3166 3165 'IEM_MC_IF_RCX_IS_NOT_ONE': (McBlock.parseMcGenericCond, True, False, True, ), … … 3261 3260 'IEM_MC_RAISE_GP0_IF_CPL_NOT_ZERO': (McBlock.parseMcGeneric, True, True, False, ), 3262 3261 'IEM_MC_RAISE_GP0_IF_EFF_ADDR_UNALIGNED': (McBlock.parseMcGeneric, True, True, True, ), 3263 'IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT': (McBlock.parseMcGeneric, True, True, True, ),3264 3262 'IEM_MC_REF_EFLAGS': (McBlock.parseMcGeneric, False, False, True, ), 3265 3263 'IEM_MC_REF_FPUREG': (McBlock.parseMcGeneric, False, False, False, ), -
trunk/src/VBox/VMM/VMMAll/IEMAllInstTwoByte0f.cpp.h
r104177 r104183 3487 3487 3488 3488 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtpi2ps_u128, pDst, u64Src); 3489 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3490 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3491 } IEM_MC_ELSE() { 3492 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3493 } IEM_MC_ENDIF(); 3489 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3490 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3494 3491 3495 3492 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3517 3514 3518 3515 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtpi2ps_u128, pDst, u64Src); 3519 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3520 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3521 } IEM_MC_ELSE() { 3522 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3523 } IEM_MC_ENDIF(); 3516 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3517 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3524 3518 3525 3519 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3552 3546 3553 3547 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtpi2pd_u128, pDst, u64Src); 3554 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3555 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3556 } IEM_MC_ELSE() { 3557 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3558 } IEM_MC_ENDIF(); 3548 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3549 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3559 3550 3560 3551 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3582 3573 3583 3574 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtpi2pd_u128, pDst, u64Src); 3584 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3585 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3586 } IEM_MC_ELSE() { 3587 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3588 } IEM_MC_ENDIF(); 3575 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3576 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 3589 3577 3590 3578 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3616 3604 IEM_MC_REF_GREG_I64_CONST(pi64Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 3617 3605 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2ss_r32_i64, pr32Dst, pi64Src); 3618 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3619 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3620 } IEM_MC_ELSE() { 3621 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3622 } IEM_MC_ENDIF(); 3606 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3607 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3623 3608 3624 3609 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3642 3627 IEM_MC_FETCH_MEM_I64(i64Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 3643 3628 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2ss_r32_i64, pr32Dst, pi64Src); 3644 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3645 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3646 } IEM_MC_ELSE() { 3647 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3648 } IEM_MC_ENDIF(); 3629 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3630 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3649 3631 3650 3632 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3668 3650 IEM_MC_REF_GREG_I32_CONST(pi32Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 3669 3651 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2ss_r32_i32, pr32Dst, pi32Src); 3670 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3671 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3672 } IEM_MC_ELSE() { 3673 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3674 } IEM_MC_ENDIF(); 3652 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3653 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3675 3654 3676 3655 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3694 3673 IEM_MC_FETCH_MEM_I32(i32Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 3695 3674 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2ss_r32_i32, pr32Dst, pi32Src); 3696 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3697 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3698 } IEM_MC_ELSE() { 3699 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3700 } IEM_MC_ENDIF(); 3675 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3676 IEM_MC_STORE_XREG_R32(IEM_GET_MODRM_REG(pVCpu, bRm), r32Dst); 3701 3677 3702 3678 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3729 3705 IEM_MC_REF_GREG_I64_CONST(pi64Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 3730 3706 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2sd_r64_i64, pr64Dst, pi64Src); 3731 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3732 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3733 } IEM_MC_ELSE() { 3734 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3735 } IEM_MC_ENDIF(); 3707 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3708 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3736 3709 3737 3710 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3755 3728 IEM_MC_FETCH_MEM_I64(i64Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 3756 3729 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2sd_r64_i64, pr64Dst, pi64Src); 3757 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3758 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3759 } IEM_MC_ELSE() { 3760 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3761 } IEM_MC_ENDIF(); 3730 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3731 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3762 3732 3763 3733 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3781 3751 IEM_MC_REF_GREG_I32_CONST(pi32Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 3782 3752 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2sd_r64_i32, pr64Dst, pi32Src); 3783 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3784 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3785 } IEM_MC_ELSE() { 3786 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3787 } IEM_MC_ENDIF(); 3753 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3788 3754 3789 3755 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3807 3773 IEM_MC_FETCH_MEM_I32(i32Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 3808 3774 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsi2sd_r64_i32, pr64Dst, pi32Src); 3809 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3810 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3811 } IEM_MC_ELSE() { 3812 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3813 } IEM_MC_ENDIF(); 3775 IEM_MC_STORE_XREG_R64(IEM_GET_MODRM_REG(pVCpu, bRm), r64Dst); 3814 3776 3815 3777 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3923 3885 3924 3886 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttps2pi_u128, pu64Dst, u64Src); 3925 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3926 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3927 } IEM_MC_ELSE() { 3928 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 3929 } IEM_MC_ENDIF(); 3887 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3888 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 3930 3889 3931 3890 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3952 3911 3953 3912 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttps2pi_u128, pu64Dst, u64Src); 3954 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3955 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3956 } IEM_MC_ELSE() { 3957 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 3958 } IEM_MC_ENDIF(); 3913 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3914 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 3959 3915 3960 3916 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 3986 3942 3987 3943 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttpd2pi_u128, pu64Dst, pSrc); 3988 IEM_MC_IF_MXCSR_XCPT_PENDING() { 3989 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3990 } IEM_MC_ELSE() { 3991 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 3992 } IEM_MC_ENDIF(); 3944 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3945 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 3993 3946 3994 3947 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4016 3969 4017 3970 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttpd2pi_u128, pu64Dst, pSrc); 4018 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4019 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4020 } IEM_MC_ELSE() { 4021 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4022 } IEM_MC_ENDIF(); 3971 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 3972 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4023 3973 4024 3974 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4050 4000 IEM_MC_REF_XREG_U32_CONST(pu32Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4051 4001 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttss2si_i64_r32, pi64Dst, pu32Src); 4052 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4053 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4054 } IEM_MC_ELSE() { 4055 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4056 } IEM_MC_ENDIF(); 4002 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4003 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4057 4004 4058 4005 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4076 4023 IEM_MC_FETCH_MEM_U32(u32Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4077 4024 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttss2si_i64_r32, pi64Dst, pu32Src); 4078 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4079 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4080 } IEM_MC_ELSE() { 4081 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4082 } IEM_MC_ENDIF(); 4025 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4026 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4083 4027 4084 4028 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4102 4046 IEM_MC_REF_XREG_U32_CONST(pu32Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4103 4047 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttss2si_i32_r32, pi32Dst, pu32Src); 4104 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4105 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4106 } IEM_MC_ELSE() { 4107 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4108 } IEM_MC_ENDIF(); 4048 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4049 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4109 4050 4110 4051 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4128 4069 IEM_MC_FETCH_MEM_U32(u32Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4129 4070 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttss2si_i32_r32, pi32Dst, pu32Src); 4130 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4131 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4132 } IEM_MC_ELSE() { 4133 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4134 } IEM_MC_ENDIF(); 4071 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4072 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4135 4073 4136 4074 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4163 4101 IEM_MC_REF_XREG_U64_CONST(pu64Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4164 4102 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttsd2si_i64_r64, pi64Dst, pu64Src); 4165 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4166 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4167 } IEM_MC_ELSE() { 4168 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4169 } IEM_MC_ENDIF(); 4103 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4104 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4170 4105 4171 4106 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4189 4124 IEM_MC_FETCH_MEM_U64(u64Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4190 4125 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttsd2si_i64_r64, pi64Dst, pu64Src); 4191 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4192 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4193 } IEM_MC_ELSE() { 4194 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4195 } IEM_MC_ENDIF(); 4126 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4127 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4196 4128 4197 4129 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4215 4147 IEM_MC_REF_XREG_U64_CONST(pu64Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4216 4148 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttsd2si_i32_r64, pi32Dst, pu64Src); 4217 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4218 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4219 } IEM_MC_ELSE() { 4220 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4221 } IEM_MC_ENDIF(); 4149 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4150 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4222 4151 4223 4152 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4241 4170 IEM_MC_FETCH_MEM_U64(u64Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4242 4171 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvttsd2si_i32_r64, pi32Dst, pu64Src); 4243 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4244 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4245 } IEM_MC_ELSE() { 4246 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4247 } IEM_MC_ENDIF(); 4172 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4173 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4248 4174 4249 4175 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4277 4203 4278 4204 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtps2pi_u128, pu64Dst, u64Src); 4279 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4280 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4281 } IEM_MC_ELSE() { 4282 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4283 } IEM_MC_ENDIF(); 4205 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4206 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4284 4207 4285 4208 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4306 4229 4307 4230 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtps2pi_u128, pu64Dst, u64Src); 4308 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4309 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4310 } IEM_MC_ELSE() { 4311 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4312 } IEM_MC_ENDIF(); 4231 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4232 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4313 4233 4314 4234 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4341 4261 4342 4262 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtpd2pi_u128, pu64Dst, pSrc); 4343 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4344 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4345 } IEM_MC_ELSE() { 4346 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4347 } IEM_MC_ENDIF(); 4263 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4264 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4348 4265 4349 4266 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4371 4288 4372 4289 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtpd2pi_u128, pu64Dst, pSrc); 4373 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4374 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4375 } IEM_MC_ELSE() { 4376 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4377 } IEM_MC_ENDIF(); 4290 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4291 IEM_MC_STORE_MREG_U64(IEM_GET_MODRM_REG_8(bRm), u64Dst); 4378 4292 4379 4293 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4405 4319 IEM_MC_REF_XREG_U32_CONST(pu32Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4406 4320 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtss2si_i64_r32, pi64Dst, pu32Src); 4407 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4408 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4409 } IEM_MC_ELSE() { 4410 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4411 } IEM_MC_ENDIF(); 4321 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4322 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4412 4323 4413 4324 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4431 4342 IEM_MC_FETCH_MEM_U32(u32Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4432 4343 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtss2si_i64_r32, pi64Dst, pu32Src); 4433 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4434 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4435 } IEM_MC_ELSE() { 4436 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4437 } IEM_MC_ENDIF(); 4344 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4345 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4438 4346 4439 4347 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4457 4365 IEM_MC_REF_XREG_U32_CONST(pu32Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4458 4366 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtss2si_i32_r32, pi32Dst, pu32Src); 4459 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4460 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4461 } IEM_MC_ELSE() { 4462 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4463 } IEM_MC_ENDIF(); 4367 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4368 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4464 4369 4465 4370 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4483 4388 IEM_MC_FETCH_MEM_U32(u32Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4484 4389 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtss2si_i32_r32, pi32Dst, pu32Src); 4485 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4486 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4487 } IEM_MC_ELSE() { 4488 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4489 } IEM_MC_ENDIF(); 4390 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4391 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4490 4392 4491 4393 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4518 4420 IEM_MC_REF_XREG_U64_CONST(pu64Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4519 4421 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsd2si_i64_r64, pi64Dst, pu64Src); 4520 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4521 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4522 } IEM_MC_ELSE() { 4523 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4524 } IEM_MC_ENDIF(); 4422 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4423 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4525 4424 4526 4425 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4544 4443 IEM_MC_FETCH_MEM_U64(u64Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4545 4444 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsd2si_i64_r64, pi64Dst, pu64Src); 4546 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4547 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4548 } IEM_MC_ELSE() { 4549 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4550 } IEM_MC_ENDIF(); 4445 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4446 IEM_MC_STORE_GREG_I64(IEM_GET_MODRM_REG(pVCpu, bRm), i64Dst); 4551 4447 4552 4448 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4570 4466 IEM_MC_REF_XREG_U64_CONST(pu64Src, IEM_GET_MODRM_RM(pVCpu, bRm)); 4571 4467 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsd2si_i32_r64, pi32Dst, pu64Src); 4572 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4573 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4574 } IEM_MC_ELSE() { 4575 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4576 } IEM_MC_ENDIF(); 4468 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4469 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4577 4470 4578 4471 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4596 4489 IEM_MC_FETCH_MEM_U64(u64Src, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 4597 4490 IEM_MC_CALL_SSE_AIMPL_2(iemAImpl_cvtsd2si_i32_r64, pi32Dst, pu64Src); 4598 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4599 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4600 } IEM_MC_ELSE() { 4601 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4602 } IEM_MC_ENDIF(); 4491 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4492 IEM_MC_STORE_GREG_U32(IEM_GET_MODRM_REG(pVCpu, bRm), i32Dst); 4603 4493 4604 4494 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4636 4526 IEM_MC_FETCH_XREG_R32(uSrc2, IEM_GET_MODRM_RM(pVCpu, bRm), 0 /*a_iDWord*/); 4637 4527 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_ucomiss_u128, pEFlags, uSrc1, uSrc2); 4638 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4639 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4640 } IEM_MC_ELSE() { 4641 IEM_MC_COMMIT_EFLAGS(fEFlags); 4642 } IEM_MC_ENDIF(); 4528 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4529 IEM_MC_COMMIT_EFLAGS(fEFlags); 4643 4530 4644 4531 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4666 4553 IEM_MC_FETCH_XREG_R32(uSrc1, IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iDWord*/); 4667 4554 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_ucomiss_u128, pEFlags, uSrc1, uSrc2); 4668 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4669 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4670 } IEM_MC_ELSE() { 4671 IEM_MC_COMMIT_EFLAGS(fEFlags); 4672 } IEM_MC_ENDIF(); 4555 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4556 IEM_MC_COMMIT_EFLAGS(fEFlags); 4673 4557 4674 4558 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4705 4589 IEM_MC_FETCH_XREG_R64(uSrc2, IEM_GET_MODRM_RM(pVCpu, bRm), 0 /*a_iQWord*/); 4706 4590 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_ucomisd_u128, pEFlags, uSrc1, uSrc2); 4707 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4708 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4709 } IEM_MC_ELSE() { 4710 IEM_MC_COMMIT_EFLAGS(fEFlags); 4711 } IEM_MC_ENDIF(); 4591 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4592 IEM_MC_COMMIT_EFLAGS(fEFlags); 4712 4593 4713 4594 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4735 4616 IEM_MC_FETCH_XREG_R64(uSrc1, IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iQWord*/); 4736 4617 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_ucomisd_u128, pEFlags, uSrc1, uSrc2); 4737 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4738 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4739 } IEM_MC_ELSE() { 4740 IEM_MC_COMMIT_EFLAGS(fEFlags); 4741 } IEM_MC_ENDIF(); 4618 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4619 IEM_MC_COMMIT_EFLAGS(fEFlags); 4742 4620 4743 4621 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4778 4656 IEM_MC_FETCH_XREG_R32(uSrc2, IEM_GET_MODRM_RM(pVCpu, bRm), 0 /*a_iDWord*/); 4779 4657 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_comiss_u128, pEFlags, uSrc1, uSrc2); 4780 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4781 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4782 } IEM_MC_ELSE() { 4783 IEM_MC_COMMIT_EFLAGS(fEFlags); 4784 } IEM_MC_ENDIF(); 4658 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4659 IEM_MC_COMMIT_EFLAGS(fEFlags); 4785 4660 4786 4661 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4808 4683 IEM_MC_FETCH_XREG_R32(uSrc1, IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iDWord*/); 4809 4684 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_comiss_u128, pEFlags, uSrc1, uSrc2); 4810 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4811 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4812 } IEM_MC_ELSE() { 4813 IEM_MC_COMMIT_EFLAGS(fEFlags); 4814 } IEM_MC_ENDIF(); 4685 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4686 IEM_MC_COMMIT_EFLAGS(fEFlags); 4815 4687 4816 4688 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4847 4719 IEM_MC_FETCH_XREG_R64(uSrc2, IEM_GET_MODRM_RM(pVCpu, bRm), 0 /*a_iQWord*/); 4848 4720 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_comisd_u128, pEFlags, uSrc1, uSrc2); 4849 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4850 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4851 } IEM_MC_ELSE() { 4852 IEM_MC_COMMIT_EFLAGS(fEFlags); 4853 } IEM_MC_ENDIF(); 4721 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4722 IEM_MC_COMMIT_EFLAGS(fEFlags); 4854 4723 4855 4724 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 4877 4746 IEM_MC_FETCH_XREG_R64(uSrc1, IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iQWord*/); 4878 4747 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_comisd_u128, pEFlags, uSrc1, uSrc2); 4879 IEM_MC_IF_MXCSR_XCPT_PENDING() { 4880 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4881 } IEM_MC_ELSE() { 4882 IEM_MC_COMMIT_EFLAGS(fEFlags); 4883 } IEM_MC_ENDIF(); 4748 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 4749 IEM_MC_COMMIT_EFLAGS(fEFlags); 4884 4750 4885 4751 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11792 11658 IEM_MC_FETCH_XREG_PAIR_XMM(Src, IEM_GET_MODRM_REG(pVCpu, bRm), IEM_GET_MODRM_RM(pVCpu, bRm)); 11793 11659 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmpps_u128, pDst, pSrc, bImmArg); 11794 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11795 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11796 } IEM_MC_ELSE() { 11797 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11798 } IEM_MC_ENDIF(); 11660 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11661 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11799 11662 11800 11663 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11822 11685 IEM_MC_FETCH_MEM_XMM_ALIGN_SSE_AND_XREG_XMM(Src, IEM_GET_MODRM_REG(pVCpu, bRm), pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 11823 11686 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmpps_u128, pDst, pSrc, bImmArg); 11824 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11825 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11826 } IEM_MC_ELSE() { 11827 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11828 } IEM_MC_ENDIF(); 11687 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11688 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11829 11689 11830 11690 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11857 11717 IEM_MC_FETCH_XREG_PAIR_XMM(Src, IEM_GET_MODRM_REG(pVCpu, bRm), IEM_GET_MODRM_RM(pVCpu, bRm)); 11858 11718 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmppd_u128, pDst, pSrc, bImmArg); 11859 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11860 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11861 } IEM_MC_ELSE() { 11862 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11863 } IEM_MC_ENDIF(); 11719 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11720 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11864 11721 11865 11722 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11887 11744 IEM_MC_FETCH_MEM_XMM_ALIGN_SSE_AND_XREG_XMM(Src, IEM_GET_MODRM_REG(pVCpu, bRm), pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 11888 11745 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmppd_u128, pDst, pSrc, bImmArg); 11889 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11890 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11891 } IEM_MC_ELSE() { 11892 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11893 } IEM_MC_ENDIF(); 11746 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11747 IEM_MC_STORE_XREG_XMM(IEM_GET_MODRM_REG(pVCpu, bRm), Dst); 11894 11748 11895 11749 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11922 11776 IEM_MC_FETCH_XREG_PAIR_XMM(Src, IEM_GET_MODRM_REG(pVCpu, bRm), IEM_GET_MODRM_RM(pVCpu, bRm)); 11923 11777 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmpss_u128, pDst, pSrc, bImmArg); 11924 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11925 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11926 } IEM_MC_ELSE() { 11927 IEM_MC_STORE_XREG_XMM_U32(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iDword*/, Dst); 11928 } IEM_MC_ENDIF(); 11778 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11779 IEM_MC_STORE_XREG_XMM_U32(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iDword*/, Dst); 11929 11780 11930 11781 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11953 11804 0 /*a_iDword*/, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 11954 11805 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmpss_u128, pDst, pSrc, bImmArg); 11955 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11956 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11957 } IEM_MC_ELSE() { 11958 IEM_MC_STORE_XREG_XMM_U32(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iDword*/, Dst); 11959 } IEM_MC_ENDIF(); 11806 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11807 IEM_MC_STORE_XREG_XMM_U32(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iDword*/, Dst); 11960 11808 11961 11809 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 11988 11836 IEM_MC_FETCH_XREG_PAIR_XMM(Src, IEM_GET_MODRM_REG(pVCpu, bRm), IEM_GET_MODRM_RM(pVCpu, bRm)); 11989 11837 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmpsd_u128, pDst, pSrc, bImmArg); 11990 IEM_MC_IF_MXCSR_XCPT_PENDING() { 11991 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11992 } IEM_MC_ELSE() { 11993 IEM_MC_STORE_XREG_XMM_U64(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iQword*/, Dst); 11994 } IEM_MC_ENDIF(); 11838 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11839 IEM_MC_STORE_XREG_XMM_U64(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iQword*/, Dst); 11995 11840 11996 11841 IEM_MC_ADVANCE_RIP_AND_FINISH(); … … 12019 11864 0 /*a_iQword */, pVCpu->iem.s.iEffSeg, GCPtrEffSrc); 12020 11865 IEM_MC_CALL_SSE_AIMPL_3(iemAImpl_cmpsd_u128, pDst, pSrc, bImmArg); 12021 IEM_MC_IF_MXCSR_XCPT_PENDING() { 12022 IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 12023 } IEM_MC_ELSE() { 12024 IEM_MC_STORE_XREG_XMM_U64(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iQword*/, Dst); 12025 } IEM_MC_ENDIF(); 11866 IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT(); 11867 IEM_MC_STORE_XREG_XMM_U64(IEM_GET_MODRM_REG(pVCpu, bRm), 0 /*a_iQword*/, Dst); 12026 11868 12027 11869 IEM_MC_ADVANCE_RIP_AND_FINISH(); -
trunk/src/VBox/VMM/VMMAll/IEMAllN8veLiveness.cpp
r104177 r104183 466 466 #define IEM_MC_MAYBE_RAISE_NON_CANONICAL_ADDR_GP0(a_u64Addr) IEM_LIVENESS_MARK_XCPT_OR_CALL() 467 467 #define IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT() IEM_LIVENESS_MARK_XCPT_OR_CALL(); IEM_LIVENESS_CR4_INPUT() /** @todo revisit when implemented. */ 468 #define IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT() IEM_LIVENESS_MARK_XCPT_OR_CALL(); IEM_LIVENESS_CR4_INPUT()469 468 470 469 #define IEM_MC_LOCAL(a_Type, a_Name) NOP() … … 1172 1171 #define IEM_MC_IF_TWO_FPUREGS_NOT_EMPTY_REF_R80_FIRST(a_pr80Dst0, a_iSt0, a_iSt1) { 1173 1172 #define IEM_MC_IF_FCW_IM() { 1174 #define IEM_MC_IF_MXCSR_XCPT_PENDING() {1175 1173 1176 1174 #define IEM_MC_ELSE() } /*else*/ { -
trunk/src/VBox/VMM/VMMAll/IEMAllN8veRecompFuncs.h
r104177 r104183 1194 1194 1195 1195 1196 #define IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT() \1197 off = iemNativeEmitRaiseSseAvxSimdFpXcpt(pReNative, off, pCallEntry->idxInstr)1198 1199 /**1200 * Emits code to raise a SIMD floating point (either \#UD or \#XF) should be raised.1201 *1202 * @returns New code buffer offset, UINT32_MAX on failure.1203 * @param pReNative The native recompile state.1204 * @param off The code buffer offset.1205 * @param idxInstr The current instruction.1206 */1207 DECL_INLINE_THROW(uint32_t)1208 iemNativeEmitRaiseSseAvxSimdFpXcpt(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t idxInstr)1209 {1210 /*1211 * Make sure we don't have any outstanding guest register writes as we may1212 * raise an \#UD or \#NM and all guest register must be up to date in CPUMCTX.1213 */1214 off = iemNativeRegFlushPendingWrites(pReNative, off);1215 1216 #ifdef IEMNATIVE_WITH_INSTRUCTION_COUNTING1217 off = iemNativeEmitStoreImmToVCpuU8(pReNative, off, idxInstr, RT_UOFFSETOF(VMCPUCC, iem.s.idxTbCurInstr));1218 #else1219 RT_NOREF(idxInstr);1220 #endif1221 1222 /* Allocate a temporary CR4 register. */1223 uint8_t const idxCr4Reg = iemNativeRegAllocTmpForGuestReg(pReNative, &off, kIemNativeGstReg_Cr4, kIemNativeGstRegUse_ReadOnly);1224 uint8_t const idxLabelRaiseXf = iemNativeLabelCreate(pReNative, kIemNativeLabelType_RaiseXf);1225 uint8_t const idxLabelRaiseUd = iemNativeLabelCreate(pReNative, kIemNativeLabelType_RaiseUd);1226 1227 /*1228 * if (!(cr4 & X86_CR4_OSXMMEEXCPT))1229 * return raisexcpt();1230 */1231 off = iemNativeEmitTestBitInGprAndJmpToLabelIfNotSet(pReNative, off, idxCr4Reg, X86_CR4_OSXMMEEXCPT_BIT, idxLabelRaiseXf);1232 1233 /* raise \#UD exception unconditionally. */1234 off = iemNativeEmitJmpToLabel(pReNative, off, idxLabelRaiseUd);1235 1236 /* Free but don't flush the CR4 register. */1237 iemNativeRegFreeTmp(pReNative, idxCr4Reg);1238 1239 return off;1240 }1241 1242 1243 1196 #define IEM_MC_RAISE_DIVIDE_ERROR() \ 1244 1197 off = iemNativeEmitRaiseDivideError(pReNative, off, pCallEntry->idxInstr) … … 2089 2042 } 2090 2043 2091 2092 #ifdef IEMNATIVE_WITH_SIMD_REG_ALLOCATOR2093 2094 #define IEM_MC_IF_MXCSR_XCPT_PENDING() \2095 off = iemNativeEmitIfMxcsrXcptPending(pReNative, off); \2096 do {2097 2098 /** Emits code for IEM_MC_IF_MXCSR_XCPT_PENDING. */2099 DECL_INLINE_THROW(uint32_t)2100 iemNativeEmitIfMxcsrXcptPending(PIEMRECOMPILERSTATE pReNative, uint32_t off)2101 {2102 PIEMNATIVECOND const pEntry = iemNativeCondPushIf(pReNative, &off);2103 2104 uint8_t const idxGstMxcsrReg = iemNativeRegAllocTmpForGuestReg(pReNative, &off, kIemNativeGstReg_MxCsr,2105 kIemNativeGstRegUse_Calculation);2106 uint8_t const idxRegTmp = iemNativeRegAllocTmp(pReNative, &off);2107 2108 /* mov tmp0, mxcsr */2109 off = iemNativeEmitLoadGprFromGpr(pReNative, off, idxRegTmp, idxGstMxcsrReg);2110 /* tmp0 &= X86_MXCSR_XCPT_FLAGS */2111 off = iemNativeEmitAndGprByImm(pReNative, off, idxRegTmp, X86_MXCSR_XCPT_FLAGS);2112 /* mxcsr &= X86_MXCSR_XCPT_MASK */2113 off = iemNativeEmitAndGprByImm(pReNative, off, idxGstMxcsrReg, X86_MXCSR_XCPT_MASK);2114 /* mxcsr ~= mxcsr */2115 off = iemNativeEmitInvBitsGpr(pReNative, off, idxGstMxcsrReg, idxGstMxcsrReg);2116 /* mxcsr >>= X86_MXCSR_XCPT_MASK_SHIFT */2117 off = iemNativeEmitShiftGprRight(pReNative, off, idxGstMxcsrReg, X86_MXCSR_XCPT_MASK_SHIFT);2118 /* tmp0 &= mxcsr */2119 off = iemNativeEmitAndGprByGpr(pReNative, off, idxRegTmp, idxGstMxcsrReg);2120 2121 off = iemNativeEmitTestIfGprIsZeroAndJmpToLabel(pReNative, off, idxRegTmp, true /*f64Bit*/, pEntry->idxLabelElse);2122 iemNativeRegFreeTmp(pReNative, idxGstMxcsrReg);2123 iemNativeRegFreeTmp(pReNative, idxRegTmp);2124 2125 iemNativeCondStartIfBlock(pReNative, off);2126 return off;2127 }2128 2129 #endif2130 2044 2131 2045 -
trunk/src/VBox/VMM/include/IEMMc.h
r104177 r104183 187 187 return iemRaiseUndefinedOpcode(pVCpu); \ 188 188 } \ 189 } while (0)190 #define IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT() \191 do { \192 if (pVCpu->cpum.GstCtx.cr4 & X86_CR4_OSXMMEEXCPT)\193 return iemRaiseSimdFpException(pVCpu); \194 return iemRaiseUndefinedOpcode(pVCpu); \195 189 } while (0) 196 190 … … 3161 3155 #define IEM_MC_IF_FCW_IM() \ 3162 3156 if (pVCpu->cpum.GstCtx.XState.x87.FCW & X86_FCW_IM) { 3163 #define IEM_MC_IF_MXCSR_XCPT_PENDING() \3164 if (( ~((pVCpu->cpum.GstCtx.XState.x87.MXCSR & X86_MXCSR_XCPT_MASK) >> X86_MXCSR_XCPT_MASK_SHIFT) \3165 & (pVCpu->cpum.GstCtx.XState.x87.MXCSR & X86_MXCSR_XCPT_FLAGS)) != 0) {3166 3157 3167 3158 #define IEM_MC_ELSE() } else { -
trunk/src/VBox/VMM/testcase/tstIEMCheckMc.cpp
r104177 r104183 617 617 #define IEM_MC_MAYBE_RAISE_NON_CANONICAL_ADDR_GP0(a_u64Addr) do { (void)fMcBegin; } while (0) 618 618 #define IEM_MC_MAYBE_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT() do { (void)fMcBegin; } while (0) 619 #define IEM_MC_RAISE_SSE_AVX_SIMD_FP_OR_UD_XCPT() do { (void)fMcBegin; } while (0)620 619 621 620 #define CHK_VAR(a_Name) do { RT_CONCAT(iVarCheck_,a_Name) = 1; } while (0) … … 1119 1118 if (g_fRandom != fFpuRead) { 1120 1119 #define IEM_MC_IF_FCW_IM() (void)fMcBegin; if (g_fRandom != fFpuRead) { 1121 #define IEM_MC_IF_MXCSR_XCPT_PENDING() (void)fMcBegin; if (g_fRandom != fSseRead) {1122 1120 #define IEM_MC_ELSE() } else { 1123 1121 #define IEM_MC_ENDIF() } do { (void)fMcBegin; } while (0)
Note:
See TracChangeset
for help on using the changeset viewer.