Changeset 42056 in vbox for trunk/src/VBox/VMM/VMMR0
- Timestamp:
- Jul 9, 2012 12:52:22 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp
r42046 r42056 3098 3098 3099 3099 TMNotifyStartOfExecution(pVCpu); 3100 3101 /* 3102 * Save the current Host TSC_AUX and write the guest TSC_AUX to the host, so that 3103 * RDTSCPs (that don't cause exits) reads the guest MSR. See @bugref{3324}. 3104 */ 3105 if ( (pVCpu->hwaccm.s.vmx.proc_ctls2 & VMX_VMCS_CTRL_PROC_EXEC2_RDTSCP) 3106 && !(pVCpu->hwaccm.s.vmx.proc_ctls & VMX_VMCS_CTRL_PROC_EXEC_CONTROLS_RDTSC_EXIT)) 3107 { 3108 pVCpu->hwaccm.s.vmx.u64HostTSCAux = ASMRdMsr(MSR_K8_TSC_AUX); 3109 uint64_t u64GuestTSCAux = 0; 3110 rc2 = CPUMQueryGuestMsr(pVCpu, MSR_K8_TSC_AUX, &u64GuestTSCAux); 3111 AssertRC(rc2); 3112 ASMWrMsr(MSR_K8_TSC_AUX, u64GuestTSCAux); 3113 } 3114 3100 3115 #ifdef VBOX_WITH_KERNEL_USING_XMM 3101 3116 rc = hwaccmR0VMXStartVMWrapXMM(pVCpu->hwaccm.s.fResumeVM, pCtx, &pVCpu->hwaccm.s.vmx.VMCSCache, pVM, pVCpu, pVCpu->hwaccm.s.vmx.pfnStartVM); … … 3105 3120 ASMAtomicWriteBool(&pVCpu->hwaccm.s.fCheckedTLBFlush, false); 3106 3121 ASMAtomicIncU32(&pVCpu->hwaccm.s.cWorldSwitchExits); 3122 3123 /* 3124 * Restore host's TSC_AUX. 3125 */ 3126 if ( (pVCpu->hwaccm.s.vmx.proc_ctls2 & VMX_VMCS_CTRL_PROC_EXEC2_RDTSCP) 3127 && !(pVCpu->hwaccm.s.vmx.proc_ctls & VMX_VMCS_CTRL_PROC_EXEC_CONTROLS_RDTSC_EXIT)) 3128 { 3129 ASMWrMsr(MSR_K8_TSC_AUX, pVCpu->hwaccm.s.vmx.u64HostTSCAux); 3130 } 3131 3107 3132 /* Possibly the last TSC value seen by the guest (too high) (only when we're in TSC offset mode). */ 3108 3133 if (!(pVCpu->hwaccm.s.vmx.proc_ctls & VMX_VMCS_CTRL_PROC_EXEC_CONTROLS_RDTSC_EXIT))
Note:
See TracChangeset
for help on using the changeset viewer.