VirtualBox

Changeset 101001 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Sep 1, 2023 1:57:59 PM (17 months ago)
Author:
vboxsync
Message:

VMM: Nested VMX: bugref:10318 Fix performance issue with Hyper-V enabled Windows Server 2012 R2 guests.

Location:
trunk/src/VBox/VMM
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/PGMAllBth.h

    r100964 r101001  
    26342634     */
    26352635    SHWPTE Pte;
    2636     uint64_t const fGstShwPteFlags = pGstWalkAll->u.Ept.Pte.u & pVCpu->pgm.s.fGstEptShadowedPteMask;
     2636    uint64_t const fGstShwPteFlags = (pGstWalkAll->u.Ept.Pte.u & pVCpu->pgm.s.fGstEptShadowedPteMask)
     2637                                   | EPT_E_MEMTYPE_WB | EPT_E_IGNORE_PAT;
    26372638    if (!PGM_PAGE_HAS_ACTIVE_HANDLERS(pPage) || PGM_PAGE_IS_HNDL_PHYS_NOT_IN_HM(pPage))
    26382639    {
     
    27962797        Assert(pShwPage->enmKind == PGMPOOLKIND_EPT_PT_FOR_EPT_2MB);
    27972798#endif
    2798         uint64_t const fGstPteFlags = pGstWalkAll->u.Ept.Pde.u & pVCpu->pgm.s.fGstEptShadowedBigPdeMask & ~EPT_E_LEAF;
     2799        uint64_t const fGstPteFlags = (pGstWalkAll->u.Ept.Pde.u & pVCpu->pgm.s.fGstEptShadowedBigPdeMask & ~EPT_E_LEAF)
     2800                                    | EPT_E_MEMTYPE_WB | EPT_E_IGNORE_PAT;
    27992801        pGstWalkAll->u.Ept.Pte.u = GCPhysPage | fGstPteFlags;
    28002802
     
    29882990         * If we have a 2M backing page, we can map the guest's 2M page right away.
    29892991         */
    2990         uint64_t const fShwBigPdeFlags = pGstWalkAll->u.Ept.Pde.u & pVCpu->pgm.s.fGstEptShadowedBigPdeMask;
     2992        uint64_t const fShwBigPdeFlags = (pGstWalkAll->u.Ept.Pde.u & pVCpu->pgm.s.fGstEptShadowedBigPdeMask)
     2993                                       | EPT_E_MEMTYPE_WB | EPT_E_IGNORE_PAT;
    29912994        if (HCPhys != NIL_RTHCPHYS)
    29922995        {
  • trunk/src/VBox/VMM/VMMR3/PGM.cpp

    r100965 r101001  
    17291729        /* We currently do -not- shadow reserved bits in guest page tables but instead trap them using non-present permissions,
    17301730           see todo in (NestedSyncPT). */
    1731         pVCpu->pgm.s.fGstEptShadowedPteMask    = EPT_PRESENT_MASK | EPT_E_MEMTYPE_MASK | EPT_E_IGNORE_PAT;
     1731        pVCpu->pgm.s.fGstEptShadowedPteMask    = EPT_PRESENT_MASK;
    17321732        pVCpu->pgm.s.fGstEptShadowedPdeMask    = EPT_PRESENT_MASK;
    1733         pVCpu->pgm.s.fGstEptShadowedBigPdeMask = EPT_PRESENT_MASK | EPT_E_MEMTYPE_MASK | EPT_E_IGNORE_PAT | EPT_E_LEAF;
    1734         pVCpu->pgm.s.fGstEptShadowedPdpteMask  = EPT_PRESENT_MASK | EPT_E_MEMTYPE_MASK | EPT_E_IGNORE_PAT | EPT_E_LEAF;
     1733        pVCpu->pgm.s.fGstEptShadowedBigPdeMask = EPT_PRESENT_MASK | EPT_E_LEAF;
     1734        pVCpu->pgm.s.fGstEptShadowedPdpteMask  = EPT_PRESENT_MASK;
    17351735        pVCpu->pgm.s.fGstEptShadowedPml4eMask  = EPT_PRESENT_MASK | EPT_PML4E_MBZ_MASK;
    17361736        /* If mode-based execute control for EPT is enabled, we would need to include bit 10 in the present mask. */
Note: See TracChangeset for help on using the changeset viewer.

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