Changeset 101096 in vbox for trunk/src/VBox/VMM/VMMR3
- Timestamp:
- Sep 12, 2023 10:59:30 PM (17 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR3/IEMR3.cpp
r101088 r101096 116 116 117 117 #ifdef VBOX_WITH_IEM_RECOMPILER 118 /** @cfgm{/IEM/InitialTbCount, uint32_t, 32768}119 * Initial (minimum) number of TBs per EMT in ring-3. */120 uint32_t cInitialTbs = 0;121 rc = CFGMR3QueryU32Def(pIem, "InitialTbCount", &cInitialTbs, _32K);122 AssertLogRelRCReturn(rc, rc);123 if (cInitialTbs < _16K || cInitialTbs > _8M)124 return VMSetError(pVM, VERR_OUT_OF_RANGE, RT_SRC_POS,125 "InitialTbCount value %u (%#x) is out of range (min %u, max %u)", cInitialTbs, cInitialTbs, _16K, _8M);126 127 118 /** @cfgm{/IEM/MaxTbCount, uint32_t, 524288} 128 119 * Max number of TBs per EMT. */ … … 130 121 rc = CFGMR3QueryU32Def(pIem, "MaxTbCount", &cMaxTbs, _512K); 131 122 AssertLogRelRCReturn(rc, rc); 132 if (cMaxTbs < cInitialTbs|| cMaxTbs > _8M)123 if (cMaxTbs < _16K || cMaxTbs > _8M) 133 124 return VMSetError(pVM, VERR_OUT_OF_RANGE, RT_SRC_POS, 134 "MaxTbCount value %u (%#x) is out of range (min %u, max %u)", cMaxTbs, cMaxTbs, cInitialTbs, _8M); 125 "MaxTbCount value %u (%#x) is out of range (min %u, max %u)", cMaxTbs, cMaxTbs, _16K, _8M); 126 127 /** @cfgm{/IEM/InitialTbCount, uint32_t, 32678} 128 * Initial (minimum) number of TBs per EMT in ring-3. */ 129 uint32_t cInitialTbs = 0; 130 rc = CFGMR3QueryU32Def(pIem, "InitialTbCount", &cInitialTbs, RT_MIN(cMaxTbs, _32K)); 131 AssertLogRelRCReturn(rc, rc); 132 if (cInitialTbs < _16K || cInitialTbs > _8M) 133 return VMSetError(pVM, VERR_OUT_OF_RANGE, RT_SRC_POS, 134 "InitialTbCount value %u (%#x) is out of range (min %u, max %u)", cInitialTbs, cInitialTbs, _16K, _8M); 135 136 /* Check that the two values makes sense together. Expect user/api to do 137 the right thing or get lost. */ 138 if (cInitialTbs > cMaxTbs) 139 return VMSetError(pVM, VERR_OUT_OF_RANGE, RT_SRC_POS, 140 "InitialTbCount value %u (%#x) is higher than the MaxTbCount value %u (%#x)", 141 cInitialTbs, cInitialTbs, cMaxTbs, cMaxTbs); 135 142 #endif 136 143 … … 285 292 286 293 PIEMTBALLOCATOR const pTbAllocator = pVCpu->iem.s.pTbAllocatorR3; 287 STAMR3RegisterF(pVM, (void *)&pTbAllocator->StatAllocs, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS, STAMUNIT_ OCCURENCES,288 "Translation block allocations", "/IEM/CPU%u/re/cTbAlloc s", idCpu);289 STAMR3RegisterF(pVM, (void *)&pTbAllocator->StatFrees, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS, STAMUNIT_ OCCURENCES,290 "Translation block frees", "/IEM/CPU%u/re/cTbFree s", idCpu);294 STAMR3RegisterF(pVM, (void *)&pTbAllocator->StatAllocs, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS, STAMUNIT_CALLS, 295 "Translation block allocations", "/IEM/CPU%u/re/cTbAllocCalls", idCpu); 296 STAMR3RegisterF(pVM, (void *)&pTbAllocator->StatFrees, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS, STAMUNIT_CALLS, 297 "Translation block frees", "/IEM/CPU%u/re/cTbFreeCalls", idCpu); 291 298 # ifdef VBOX_WITH_STATISTICS 292 299 STAMR3RegisterF(pVM, (void *)&pTbAllocator->StatPrune, STAMTYPE_PROFILE, STAMVISIBILITY_ALWAYS, STAMUNIT_TICKS_PER_CALL,
Note:
See TracChangeset
for help on using the changeset viewer.