VirtualBox

Changeset 33726 in vbox for trunk/src/VBox/VMM/PGMPhys.cpp


Ignore:
Timestamp:
Nov 3, 2010 1:35:35 PM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
67355
Message:

Allocation timeout > 1 second means immediate disabling of large page allocation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/PGMPhys.cpp

    r33725 r33726  
    39253925    {
    39263926        static uint32_t cTimeOut = 0;
    3927 
    3928         if (u64TimeStamp2 - u64TimeStamp1 > 100)
     3927        uint64_t u64TimeStampDelta = u64TimeStamp2 - u64TimeStamp1;
     3928
     3929        if (u64TimeStampDelta > 100)
    39293930        {
    39303931            STAM_COUNTER_INC(&pVM->pgm.s.CTX_SUFF(pStats)->StatLargePageOverflow);
    3931             if (++cTimeOut > 10)
     3932            if (    ++cTimeOut > 10
     3933                ||  u64TimeStampDelta > 1000 /* more than one second forces an early retirement from allocating large pages. */)
    39323934            {
    39333935                /* If repeated attempts to allocate a large page takes more than 100 ms, then we fall back to normal 4k pages.
    39343936                 * E.g. Vista 64 tries to move memory around, which takes a huge amount of time.
    39353937                 */
    3936                 LogRel(("PGMR3PhysAllocateLargePage: allocating large pages takes too long (last attempt %d ms); DISABLE\n", u64TimeStamp2 - u64TimeStamp1));
     3938                LogRel(("PGMR3PhysAllocateLargePage: allocating large pages takes too long (last attempt %d ms; nr of timeouts %d); DISABLE\n", u64TimeStampDelta, cTimeOut));
    39373939                PGMSetLargePageUsage(pVM, false);
    39383940            }
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