VirtualBox

Ignore:
Timestamp:
Feb 22, 2010 5:48:23 PM (15 years ago)
Author:
vboxsync
Message:

Large page changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/PGMAllPhys.cpp

    r26679 r26685  
    368368    Assert(!PGM_PAGE_IS_MMIO(pPage));
    369369
     370    if (PGMIsUsingLargePages(pVM))
     371    {
     372        RTHCPHYS HCPhysDummy;
     373
     374        int rc = pgmPhysAllocLargePage(pVM, GCPhys, &HCPhysDummy);
     375        if (rc == VINF_SUCCESS)
     376            return rc;
     377
     378        /* fall back to 4kb pages. */
     379    }
    370380
    371381    /*
     
    471481     */
    472482    Assert(PGMIsLocked(pVM));
     483    Assert(PGMIsUsingLargePages(pVM));
    473484    Assert((GCPhys & X86_PD_PAE_MASK) == 0);
    474485    AssertPtr(pHCPhys);
     
    540551                }
    541552                LogFlow(("pgmPhysAllocLargePage failed with %Rrc\n", rc));
     553
     554                /* If we fail once, it most likely means the host's memory is too fragmented; don't bother trying again. */
     555                PGMSetLargePageUsage(pVM, false);
    542556                return rc;
    543557            }
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