- Timestamp:
- Apr 4, 2024 10:47:23 AM (10 months ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAllInstPython.py
r104150 r104155 3013 3013 'IEM_MC_CALL_VOID_AIMPL_3': (McBlock.parseMcCallVoidAImpl, True, True, True, ), 3014 3014 'IEM_MC_CALL_VOID_AIMPL_4': (McBlock.parseMcCallVoidAImpl, True, True, True, ), 3015 'IEM_MC_CLEAR_EFL_BIT': (McBlock.parseMcGeneric, True, True, False,),3015 'IEM_MC_CLEAR_EFL_BIT': (McBlock.parseMcGeneric, True, True, True, ), 3016 3016 'IEM_MC_CLEAR_FSW_EX': (McBlock.parseMcGeneric, True, True, False, ), 3017 3017 'IEM_MC_CLEAR_HIGH_GREG_U64': (McBlock.parseMcGeneric, True, True, True, ), … … 3124 3124 'IEM_MC_FETCH_YREG_U32': (McBlock.parseMcGeneric, False, False, g_fNativeSimd), 3125 3125 'IEM_MC_FETCH_YREG_U64': (McBlock.parseMcGeneric, False, False, g_fNativeSimd), 3126 'IEM_MC_FLIP_EFL_BIT': (McBlock.parseMcGeneric, True, True, False,),3126 'IEM_MC_FLIP_EFL_BIT': (McBlock.parseMcGeneric, True, True, True, ), 3127 3127 'IEM_MC_FPU_FROM_MMX_MODE': (McBlock.parseMcGeneric, True, True, False, ), 3128 3128 'IEM_MC_FPU_STACK_DEC_TOP': (McBlock.parseMcGeneric, True, True, False, ), … … 3297 3297 'IEM_MC_SAR_LOCAL_S32': (McBlock.parseMcGeneric, False, False, True, ), 3298 3298 'IEM_MC_SAR_LOCAL_S64': (McBlock.parseMcGeneric, False, False, True, ), 3299 'IEM_MC_SET_EFL_BIT': (McBlock.parseMcGeneric, True, True, False,),3299 'IEM_MC_SET_EFL_BIT': (McBlock.parseMcGeneric, True, True, True, ), 3300 3300 'IEM_MC_SET_FPU_RESULT': (McBlock.parseMcGeneric, True, True, False, ), 3301 3301 'IEM_MC_SET_RIP_U16_AND_FINISH': (McBlock.parseMcGeneric, True, True, False, ), -
trunk/src/VBox/VMM/VMMAll/IEMAllN8veLiveness.cpp
r104150 r104155 646 646 if ((a_fBit) == X86_EFL_CF) IEM_LIVENESS_ONE_EFLAG_INPUT(fEflCf); \ 647 647 else if ((a_fBit) == X86_EFL_DF) IEM_LIVENESS_ONE_EFLAG_INPUT(fEflOther); \ 648 else { AssertFailed(); IEM_LIVENESS_ALL_EFLAG _INPUT(); } \648 else { AssertFailed(); IEM_LIVENESS_ALL_EFLAGS_INPUT(); } \ 649 649 } while (0) 650 650 #define IEM_MC_CLEAR_EFL_BIT(a_fBit) do { \ 651 651 if ((a_fBit) == X86_EFL_CF) IEM_LIVENESS_ONE_EFLAG_INPUT(fEflCf); \ 652 652 else if ((a_fBit) == X86_EFL_DF) IEM_LIVENESS_ONE_EFLAG_INPUT(fEflOther); \ 653 else { AssertFailed(); IEM_LIVENESS_ALL_EFLAG _INPUT(); } \653 else { AssertFailed(); IEM_LIVENESS_ALL_EFLAGS_INPUT(); } \ 654 654 } while (0) 655 655 #define IEM_MC_FLIP_EFL_BIT(a_fBit) do { \ 656 656 if ((a_fBit) == X86_EFL_CF) IEM_LIVENESS_ONE_EFLAG_MODIFY(fEflCf); \ 657 else { AssertFailed(); IEM_LIVENESS_ALL_EFLAG _MODIFY(); } \657 else { AssertFailed(); IEM_LIVENESS_ALL_EFLAGS_MODIFY(); } \ 658 658 } while (0) 659 659 -
trunk/src/VBox/VMM/VMMAll/IEMAllN8veRecompFuncs.h
r104150 r104155 4144 4144 } 4145 4145 4146 4147 typedef enum IEMNATIVEMITEFLOP 4148 { 4149 kIemNativeEmitEflOp_Invalid = 0, 4150 kIemNativeEmitEflOp_Set, 4151 kIemNativeEmitEflOp_Clear, 4152 kIemNativeEmitEflOp_Flip 4153 } IEMNATIVEMITEFLOP; 4154 4155 #define IEM_MC_SET_EFL_BIT(a_fBit) \ 4156 off = iemNativeEmitModifyEFlagsBit(pReNative, off, a_fBit, kIemNativeEmitEflOp_Set); 4157 4158 #define IEM_MC_CLEAR_EFL_BIT(a_fBit) \ 4159 off = iemNativeEmitModifyEFlagsBit(pReNative, off, a_fBit, kIemNativeEmitEflOp_Clear); 4160 4161 #define IEM_MC_FLIP_EFL_BIT(a_fBit) \ 4162 off = iemNativeEmitModifyEFlagsBit(pReNative, off, a_fBit, kIemNativeEmitEflOp_Flip); 4163 4164 /** Handles IEM_MC_SET_EFL_BIT/IEM_MC_CLEAR_EFL_BIT/IEM_MC_FLIP_EFL_BIT. */ 4165 DECL_INLINE_THROW(uint32_t) iemNativeEmitModifyEFlagsBit(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint32_t fEflBit, IEMNATIVEMITEFLOP enmOp) 4166 { 4167 uint8_t const idxEflReg = iemNativeRegAllocTmpForGuestReg(pReNative, &off, kIemNativeGstReg_EFlags, 4168 kIemNativeGstRegUse_ForUpdate, false /*fNoVolatileRegs*/); 4169 4170 switch (enmOp) 4171 { 4172 case kIemNativeEmitEflOp_Set: 4173 off = iemNativeEmitOrGpr32ByImm(pReNative, off, idxEflReg, fEflBit); 4174 break; 4175 case kIemNativeEmitEflOp_Clear: 4176 off = iemNativeEmitAndGpr32ByImm(pReNative, off, idxEflReg, ~fEflBit); 4177 break; 4178 case kIemNativeEmitEflOp_Flip: 4179 off = iemNativeEmitXorGpr32ByImm(pReNative, off, idxEflReg, fEflBit); 4180 break; 4181 default: 4182 AssertFailed(); 4183 break; 4184 } 4185 4186 /** @todo No delayed writeback for EFLAGS right now. */ 4187 off = iemNativeEmitStoreGprToVCpuU32(pReNative, off, idxEflReg, RT_UOFFSETOF(VMCPU, cpum.GstCtx.eflags)); 4188 4189 /* Free but don't flush the EFLAGS register. */ 4190 iemNativeRegFreeTmp(pReNative, idxEflReg); 4191 4192 return off; 4193 } 4146 4194 4147 4195 -
trunk/src/VBox/VMM/include/IEMN8veRecompilerEmit.h
r104133 r104155 5435 5435 5436 5436 5437 /** 5438 * Emits code for XOR'ing two 32-bit GPRs. 5439 */ 5440 DECL_INLINE_THROW(uint32_t) 5441 iemNativeEmitXorGpr32ByImm(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t iGprDst, uint32_t uImm) 5442 { 5443 #if defined(RT_ARCH_AMD64) 5444 off = iemNativeEmitXorGpr32ByImmEx(iemNativeInstrBufEnsure(pReNative, off, 7), off, iGprDst, uImm); 5445 #elif defined(RT_ARCH_ARM64) 5446 off = iemNativeEmitXorGpr32ByImmEx(iemNativeInstrBufEnsure(pReNative, off, 1), off, iGprDst, uImm); 5447 #else 5448 # error "Port me" 5449 #endif 5450 IEMNATIVE_ASSERT_INSTR_BUF_ENSURE(pReNative, off); 5451 return off; 5452 } 5453 5454 5437 5455 /********************************************************************************************************************************* 5438 5456 * Shifting *
Note:
See TracChangeset
for help on using the changeset viewer.