- Timestamp:
- May 24, 2007 9:15:01 PM (18 years ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/TM.cpp
r2857 r2859 573 573 if (tmR3HasFixedTSC()) 574 574 /* Sleep a bit to get a more reliable CpuHz value. */ 575 RTThreadSleep(32); 575 RTThreadSleep(32); 576 576 else 577 577 { … … 1452 1452 " u64VirtualSyncCatchUpPrev=%016RX64\n" 1453 1453 " u64VirtualSyncStoppedTS=%016RX64 %s by %#d (cur %#d)\n" 1454 " u32VirtualSyncStoppedCpuHz=%08RX32 (cur %08RX32)\n" 1454 1455 "u32VirtualSyncCatchUpPercentage=%08RX32\n" 1455 1456 " fVirtualSyncTicking=%RTbool (prev=%RTbool)\n" 1456 1457 " fVirtualSyncCatchUp=%RTbool (prev=%RTbool)\n", 1457 1458 u64Now, 1458 u64Max, 1459 u64Max, 1459 1460 pNext->u64Expire, 1460 1461 pVM->tm.s.u64VirtualSync, … … 1467 1468 pVM->tm.s.u64VirtualSyncCatchUpPrev, 1468 1469 pVM->tm.s.u64VirtualSyncStoppedTS, pVM->tm.s.fVirtualSyncStoppedInGC ? "GC" : "R3", pVM->tm.s.u8VirtualSyncStoppedApicId, ASMGetApicId(), 1470 pVM->tm.s.u32VirtualSyncStoppedCpuHz, (uint32_t)SUPGetCpuHzFromGIP(g_pSUPGlobalInfoPage), 1469 1471 pVM->tm.s.u32VirtualSyncCatchUpPercentage, 1470 pVM->tm.s.fVirtualSyncTicking, fWasTicking, 1472 pVM->tm.s.fVirtualSyncTicking, fWasTicking, 1471 1473 pVM->tm.s.fVirtualSyncCatchUp, fWasInCatchup)); 1472 1474 Assert(u64Now <= u64VirtualNow - pVM->tm.s.offVirtualSyncGivenUp); … … 1638 1640 if (offLag > _1P && s_cRelLogEntries++ < 128) 1639 1641 LogRel(("TM: offLag=%RI64 is way too large/negative! Please add this to #1414.\n" 1640 " offLag=%016RX64\n" 1641 " offNew=%016RX64\n" 1642 " u64Elapsed=%016RX64\n" 1643 " offSlack=%016RX64\n" 1644 " u64VirtualNow2=%016RX64\n" 1645 " u64VirtualNow=%016RX64\n" 1646 " u64VirtualSync=%016RX64\n" 1647 " offVirtualSync=%016RX64\n" 1648 " offVirtualSyncGivenUp=%016RX64\n" 1649 " u64Now=%016RX64\n" 1650 " u64Max=%016RX64\n" 1651 "u64VirtualSyncStoppedTS=%016RX64 %s by %#d (cur %#d)\n", 1642 " offLag=%016RX64\n" 1643 " offNew=%016RX64\n" 1644 " u64Elapsed=%016RX64\n" 1645 " offSlack=%016RX64\n" 1646 " u64VirtualNow2=%016RX64\n" 1647 " u64VirtualNow=%016RX64\n" 1648 " u64VirtualSync=%016RX64\n" 1649 " offVirtualSync=%016RX64\n" 1650 " offVirtualSyncGivenUp=%016RX64\n" 1651 " u64Now=%016RX64\n" 1652 " u64Max=%016RX64\n" 1653 " u64VirtualSyncStoppedTS=%016RX64 %s by %#d (cur %#d)\n" 1654 "u32VirtualSyncStoppedCpuHz=%08RX32 (cur %08RX32)\n" 1655 , 1652 1656 offLag, 1653 1657 offLag, … … 1662 1666 u64Now, 1663 1667 u64Max, 1664 pVM->tm.s.u64VirtualSyncStoppedTS, pVM->tm.s.fVirtualSyncStoppedInGC ? "GC" : "R3", pVM->tm.s.u8VirtualSyncStoppedApicId, ASMGetApicId())); 1668 pVM->tm.s.u64VirtualSyncStoppedTS, pVM->tm.s.fVirtualSyncStoppedInGC ? "GC" : "R3", pVM->tm.s.u8VirtualSyncStoppedApicId, ASMGetApicId(), 1669 pVM->tm.s.u32VirtualSyncStoppedCpuHz, (uint32_t)SUPGetCpuHzFromGIP(g_pSUPGlobalInfoPage) 1670 )); 1665 1671 //debugging - remove - end 1666 1672 STAM_COUNTER_INC(&pVM->tm.s.StatVirtualSyncGiveUpBeforeStarting); -
trunk/src/VBox/VMM/TMInternal.h
r2857 r2859 345 345 uint8_t volatile u8VirtualSyncStoppedApicId;/**< for debugging - remove later */ 346 346 uint8_t au8PaddingDbg[2];/**< for debugging - remove later */ 347 uint32_t u32 PaddingDbg;/**< for debugging - remove later */347 uint32_t u32VirtualSyncStoppedCpuHz;/**< for debugging - remove later */ 348 348 /** The TMCLOCK_VIRTUAL at the previous TMVirtualGetSync call when catch-up is active. */ 349 349 uint64_t volatile u64VirtualSyncCatchUpPrev; -
trunk/src/VBox/VMM/VMMAll/TMAllVirtual.cpp
r2857 r2859 271 271 #else 272 272 pVM->tm.s.fVirtualSyncStoppedInGC = false; 273 #endif 273 #endif 274 274 pVM->tm.s.u8VirtualSyncStoppedApicId = ASMGetApicId(); 275 #ifdef IN_RING0 276 PCSUPGLOBALINFOPAGE pGip = &g_SUPGlobalInfoPage; 277 #else 278 PCSUPGLOBALINFOPAGE pGip = g_pSUPGlobalInfoPage; 279 #endif 280 if (pGip) 281 { 282 PCSUPGIPCPU pCpu = &pGip->aCPUs[0]; 283 if (pGip->u32Mode == SUPGIPMODE_ASYNC_TSC) 284 pCpu = &pGip->aCPUs[pVM->tm.s.u8VirtualSyncStoppedApicId]; 285 pVM->tm.s.u32VirtualSyncStoppedCpuHz = (uint32_t)pCpu->u64CpuHz; 286 } 275 287 //debugging - remove this later - end 276 288 if ( fCheckTimers
Note:
See TracChangeset
for help on using the changeset viewer.