Changeset 38077 in vbox for trunk/src/VBox/VMM/VMMAll
- Timestamp:
- Jul 19, 2011 5:15:29 PM (14 years ago)
- Location:
- trunk/src/VBox/VMM/VMMAll
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAll.cpp
r38074 r38077 4630 4630 #define IEM_MC_FETCH_CR0_U64(a_u64Dst) (a_u64Dst) = (pIemCpu)->CTX_SUFF(pCtx)->cr0 4631 4631 #define IEM_MC_FETCH_EFLAGS(a_EFlags) (a_EFlags) = (pIemCpu)->CTX_SUFF(pCtx)->eflags.u 4632 #define IEM_MC_FETCH_EFLAGS_U8(a_EFlags) (a_EFlags) = (uint8_t)(pIemCpu)->CTX_SUFF(pCtx)->eflags.u 4632 4633 #define IEM_MC_FETCH_FSW(a_u16Fsw) (a_u16Fsw) = iemFRegFetchFsw(pIemCpu) 4633 4634 … … 4678 4679 #define IEM_MC_ADD_LOCAL_S64_TO_EFF_ADDR(a_EffAddr, a_i64) do { (a_EffAddr) += (a_i64); } while (0) 4679 4680 4681 #define IEM_MC_AND_LOCAL_U8(a_u8Local, a_u8Mask) do { (a_u8Local) &= (a_u8Mask); } while (0) 4680 4682 #define IEM_MC_AND_LOCAL_U16(a_u16Local, a_u16Mask) do { (a_u16Local) &= (a_u16Mask); } while (0) 4681 4683 #define IEM_MC_AND_LOCAL_U32(a_u32Local, a_u32Mask) do { (a_u32Local) &= (a_u32Mask); } while (0) … … 4686 4688 #define IEM_MC_AND_ARG_U64(a_u64Arg, a_u64Mask) do { (a_u64Arg) &= (a_u64Mask); } while (0) 4687 4689 4690 #define IEM_MC_OR_LOCAL_U8(a_u8Local, a_u8Mask) do { (a_u8Local) |= (a_u8Mask); } while (0) 4691 #define IEM_MC_OR_LOCAL_U32(a_u32Local, a_u32Mask) do { (a_u32Local) |= (a_u32Mask); } while (0) 4692 4688 4693 #define IEM_MC_SAR_LOCAL_S16(a_i16Local, a_cShift) do { (a_i16Local) >>= (a_cShift); } while (0) 4689 4694 #define IEM_MC_SAR_LOCAL_S32(a_i32Local, a_cShift) do { (a_i32Local) >>= (a_cShift); } while (0) … … 4693 4698 #define IEM_MC_SHL_LOCAL_S32(a_i32Local, a_cShift) do { (a_i32Local) <<= (a_cShift); } while (0) 4694 4699 #define IEM_MC_SHL_LOCAL_S64(a_i64Local, a_cShift) do { (a_i64Local) <<= (a_cShift); } while (0) 4700 4701 #define IEM_MC_AND_2LOCS_U32(a_u32Local, a_u32Mask) do { (a_u32Local) &= (a_u32Mask); } while (0) 4702 4703 #define IEM_MC_OR_2LOCS_U32(a_u32Local, a_u32Mask) do { (a_u32Local) |= (a_u32Mask); } while (0) 4695 4704 4696 4705 #define IEM_MC_AND_GREG_U8(a_iGReg, a_u8Value) *(uint8_t *)iemGRegRef(pIemCpu, (a_iGReg)) &= (a_u8Value) -
trunk/src/VBox/VMM/VMMAll/IEMAllInstructions.cpp.h
r38074 r38077 7818 7818 7819 7819 /** Opcode 0x9e. */ 7820 FNIEMOP_STUB(iemOp_sahf); 7820 FNIEMOP_DEF(iemOp_sahf) 7821 { 7822 IEMOP_MNEMONIC("sahf"); 7823 IEMOP_HLP_NO_LOCK_PREFIX(); 7824 IEMOP_HLP_NO_64BIT(); 7825 IEM_MC_BEGIN(0, 2); 7826 IEM_MC_LOCAL(uint32_t, u32Flags); 7827 IEM_MC_LOCAL(uint32_t, EFlags); 7828 IEM_MC_FETCH_EFLAGS(EFlags); 7829 IEM_MC_FETCH_GREG_U8_ZX_U32(u32Flags, X86_GREG_xSP/*=AH*/); 7830 IEM_MC_AND_LOCAL_U32(u32Flags, UINT32_C(0xd7)); 7831 IEM_MC_AND_LOCAL_U32(EFlags, UINT32_C(0xffffff00)); 7832 IEM_MC_OR_LOCAL_U32(u32Flags, UINT32_C(0x00000002)); 7833 IEM_MC_OR_2LOCS_U32(EFlags, u32Flags); 7834 IEM_MC_COMMIT_EFLAGS(EFlags); 7835 IEM_MC_ADVANCE_RIP(); 7836 IEM_MC_END(); 7837 return VINF_SUCCESS; 7838 } 7839 7840 7821 7841 /** Opcode 0x9f. */ 7822 FNIEMOP_STUB(iemOp_lahf); 7842 FNIEMOP_DEF(iemOp_lahf) 7843 { 7844 IEMOP_MNEMONIC("lahf"); 7845 IEMOP_HLP_NO_LOCK_PREFIX(); 7846 IEMOP_HLP_NO_64BIT(); 7847 IEM_MC_BEGIN(0, 1); 7848 IEM_MC_LOCAL(uint8_t, u8Flags); 7849 IEM_MC_FETCH_EFLAGS_U8(u8Flags); 7850 IEM_MC_STORE_GREG_U8(X86_GREG_xSP/*=AH*/, u8Flags); 7851 IEM_MC_ADVANCE_RIP(); 7852 IEM_MC_END(); 7853 return VINF_SUCCESS; 7854 } 7855 7823 7856 7824 7857 /**
Note:
See TracChangeset
for help on using the changeset viewer.