Changeset 15436 in vbox for trunk/src/VBox/VMM/VMMR0/PGMR0DynMap.cpp
- Timestamp:
- Dec 13, 2008 11:59:30 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR0/PGMR0DynMap.cpp
r15434 r15436 52 52 /** The minimum number of pages we reserve per CPU. 53 53 * This must be equal or larger than the autoset size. */ 54 #define PGMR0DYNMAP_PAGES_PER_CPU_MIN 3254 #define PGMR0DYNMAP_PAGES_PER_CPU_MIN 64 55 55 /** The number of guard pages. 56 56 * @remarks Never do tuning of the hashing or whatnot with a strict build! */ … … 1566 1566 pSet->iCpu = -1; 1567 1567 1568 STAM_COUNTER_INC(&pVCpu->pVMR0->pgm.s.aStatR0DynMapSetSize[(cEntries * 10 / RT_ELEMENTS(pSet->aEntries)) % 11]); 1568 1569 AssertMsg(cEntries < PGMMAPSET_MAX_FILL, ("%u\n", cEntries)); 1569 1570 if (cEntries > RT_ELEMENTS(pSet->aEntries) * 50 / 100) … … 1589 1590 uint32_t cEntries = pSet->cEntries; 1590 1591 AssertReturnVoid(cEntries != PGMMAPSET_CLOSED); 1592 STAM_COUNTER_INC(&pVCpu->pVMR0->pgm.s.aStatR0DynMapSetSize[(cEntries * 10 / RT_ELEMENTS(pSet->aEntries)) % 11]); 1591 1593 if (cEntries >= RT_ELEMENTS(pSet->aEntries) * 45 / 100) 1592 1594 { … … 1733 1735 { 1734 1736 PPGMMAPSET pSet = &pVCpu->pgm.s.AutoSet; 1735 AssertReturnVoid(pSet->cEntries != PGMMAPSET_CLOSED); 1737 uint32_t cEntries = pSet->cEntries; 1738 AssertReturnVoid(cEntries != PGMMAPSET_CLOSED); 1736 1739 AssertReturnVoid(pSet->iSubset <= iPrevSubset || iPrevSubset == UINT32_MAX); 1737 1740 Assert(iPrevSubset == UINT32_MAX); 1738 if ( pSet->cEntries >= RT_ELEMENTS(pSet->aEntries) * 40 / 1001739 && pSet->cEntries != pSet->iSubset)1740 {1741 AssertMsg(pSet->cEntries < PGMMAPSET_MAX_FILL, ("%u\n", pSet->cEntries));1742 STAM_COUNTER_INC(&pVCpu->pVMR0->pgm.s.StatR0DynMapPopFlushes);1741 STAM_COUNTER_INC(&pVCpu->pVMR0->pgm.s.aStatR0DynMapSetSize[(cEntries * 10 / RT_ELEMENTS(pSet->aEntries)) % 11]); 1742 if ( cEntries >= RT_ELEMENTS(pSet->aEntries) * 40 / 100 1743 && cEntries != pSet->iSubset) 1744 { 1745 AssertMsg(cEntries < PGMMAPSET_MAX_FILL, ("%u\n", cEntries)); 1743 1746 pgmDynMapFlushSubset(pSet); 1744 1747 } … … 1888 1891 { 1889 1892 STAM_COUNTER_INC(&pVM->pgm.s.StatR0DynMapSetSearchFlushes); 1893 STAM_COUNTER_INC(&pVM->pgm.s.aStatR0DynMapSetSize[(pSet->cEntries * 10 / RT_ELEMENTS(pSet->aEntries)) % 11]); 1890 1894 AssertMsg(pSet->cEntries < PGMMAPSET_MAX_FILL, ("%u\n", pSet->cEntries)); 1891 1895 pgmDynMapFlushSubset(pSet);
Note:
See TracChangeset
for help on using the changeset viewer.