VirtualBox

Changeset 48565 in vbox for trunk/include/VBox/vmm


Ignore:
Timestamp:
Sep 19, 2013 10:16:00 PM (12 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
89117
Message:

VMM/HM: Added total VM-exits STAM.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/vmm/hm.h

    r48562 r48565  
    7171#define VMCPU_HMCF_IS_PENDING(pVCpu, fFlags)    RT_BOOL((pVCpu)->hm.s.fContextUseFlags & (fFlags))
    7272
     73/** @def VMCPU_HMCF_RESET_TO
     74 * Resets the HM-context flags to the specified value.
     75 *
     76 * @param   pVCpu   Pointer to the VMCPU.
     77 * @param   fFlags  The reset value.
     78 */
     79#define VMCPU_HMCF_RESET_TO(pVCpu, fFlags)      ((pVCpu)->hm.s.fContextUseFlags = (fFlags))
     80
    7381/**
    7482 * Checks whether HM (VT-x/AMD-V) is being used by this VM.
     
    8290 */
    8391#if defined(VBOX_STRICT) && defined(IN_RING3)
    84 # define HMIsEnabled(a_pVM)   HMIsEnabledNotMacro(a_pVM)
     92# define HMIsEnabled(a_pVM)                 HMIsEnabledNotMacro(a_pVM)
    8593#else
    86 # define HMIsEnabled(a_pVM)   ((a_pVM)->fHMEnabled)
     94# define HMIsEnabled(a_pVM)                 ((a_pVM)->fHMEnabled)
    8795#endif
    8896
     
    98106 */
    99107#if HC_ARCH_BITS == 64
    100 # define HMIsRawModeCtxNeeded(a_pVM)   (!HMIsEnabled(a_pVM))
     108# define HMIsRawModeCtxNeeded(a_pVM)        (!HMIsEnabled(a_pVM))
    101109#else
    102 # define HMIsRawModeCtxNeeded(a_pVM)   (!HMIsEnabled(a_pVM) || (a_pVM)->fHMNeedRawModeCtx)
     110# define HMIsRawModeCtxNeeded(a_pVM)        (!HMIsEnabled(a_pVM) || (a_pVM)->fHMNeedRawModeCtx)
    103111#endif
    104112
     
    110118 * @internal
    111119 */
    112 #define HMCanEmulateIoBlock(a_pVCpu)     (!CPUMIsGuestInPagedProtectedMode(a_pVCpu))
     120#define HMCanEmulateIoBlock(a_pVCpu)        (!CPUMIsGuestInPagedProtectedMode(a_pVCpu))
    113121
    114122 /**
     
    119127 * @internal
    120128 */
    121 #define HMCanEmulateIoBlockEx(a_pCtx)   (!CPUMIsGuestInPagedProtectedModeEx(a_pCtx))
     129#define HMCanEmulateIoBlockEx(a_pCtx)       (!CPUMIsGuestInPagedProtectedModeEx(a_pCtx))
    122130
    123131/**
     
    128136 */
    129137#ifdef IN_RING0
    130 # define HMIsInHwVirtCtx(a_pVCpu)       (VMCPU_GET_STATE(a_pVCpu) == VMCPUSTATE_STARTED_HM)
     138# define HMIsInHwVirtCtx(a_pVCpu)           (VMCPU_GET_STATE(a_pVCpu) == VMCPUSTATE_STARTED_HM)
    131139#else
    132 # define HMIsInHwVirtCtx(a_pVCpu)       (false)
     140# define HMIsInHwVirtCtx(a_pVCpu)           (false)
    133141#endif
    134142
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette