Lines Matching refs:vmm

22 #include <VBox/vmm/vmm.h>
24 #include <VBox/vmm/trpm.h>
25 #include <VBox/vmm/cpum.h>
26 #include <VBox/vmm/pdmapi.h>
27 #include <VBox/vmm/pgm.h>
28 #include <VBox/vmm/stam.h>
29 #include <VBox/vmm/tm.h>
31 #include <VBox/vmm/vm.h>
33 # include <VBox/vmm/pdmpci.h>
36 #include <VBox/vmm/gvmm.h>
37 #include <VBox/vmm/gmm.h>
38 #include <VBox/vmm/gim.h>
40 #include <VBox/vmm/hm.h>
309 PVMMR0LOGGER pR0Logger = pVCpu->vmm.s.pR0LoggerR0;
351 if ( pVM->vmm.s.fUsePeriodicPreemptionTimers
353 pVM->vmm.s.fUsePeriodicPreemptionTimers = false;
459 Assert(pVCpu->vmm.s.hR0ThreadCtx == NIL_RTTHREADCTX);
461 int rc = RTThreadCtxHooksCreate(&pVCpu->vmm.s.hR0ThreadCtx);
482 RTThreadCtxHooksRelease(pVCpu->vmm.s.hR0ThreadCtx);
498 return RTThreadCtxHooksRegister(pVCpu->vmm.s.hR0ThreadCtx, pfnThreadHook, pVCpu);
514 if (pVCpu->vmm.s.hR0ThreadCtx != NIL_RTTHREADCTX)
517 int rc = RTThreadCtxHooksDeregister(pVCpu->vmm.s.hR0ThreadCtx);
532 return pVCpu->vmm.s.hR0ThreadCtx != NIL_RTTHREADCTX;
544 return RTThreadCtxHooksAreRegistered(pVCpu->vmm.s.hR0ThreadCtx);
632 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetNormal);
635 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetInterrupt);
638 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetInterruptHyper);
641 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetGuestTrap);
644 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetRingSwitch);
647 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetRingSwitchInt);
650 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetStaleSelector);
653 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetIRETTrap);
656 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetIORead);
659 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetIOWrite);
662 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMMIORead);
665 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMMIOWrite);
668 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMMIOReadWrite);
671 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMMIOPatchRead);
674 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMMIOPatchWrite);
677 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMSRRead);
680 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMSRWrite);
683 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetEmulate);
686 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetIOBlockEmulate);
689 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPatchEmulate);
692 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetLDTFault);
695 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetGDTFault);
698 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetIDTFault);
701 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetTSSFault);
704 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPDFault);
707 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetCSAMTask);
710 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetSyncCR3);
713 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPatchInt3);
716 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPatchPF);
719 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPatchGP);
722 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPatchIretIRQ);
725 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetRescheduleREM);
729 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3TMVirt);
731 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3HandyPages);
733 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3PDMQueues);
735 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3Rendezvous);
737 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3DMA);
739 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3Timer);
741 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3CritSect);
743 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3);
745 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetToR3Unknown);
749 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetTimerPending);
752 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetInterruptPending);
755 switch (pVCpu->vmm.s.enmCallRing3Operation)
758 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallPDMCritSectEnter);
761 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallPDMLock);
764 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallPGMPoolGrow);
767 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallPGMLock);
770 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallPGMMapChunk);
773 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallPGMAllocHandy);
776 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallRemReplay);
779 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallLogFlush);
782 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallVMSetError);
785 STAM_COUNTER_INC(&pVM->vmm.s.StatRZCallVMSetRuntimeError);
789 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetCallRing3);
794 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPATMDuplicateFn);
797 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPGMChangeMode);
800 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPGMFlushPending);
803 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPendingRequest);
806 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetPatchTPR);
809 STAM_COUNTER_INC(&pVM->vmm.s.StatRZRetMisc);
843 * The return code is stored in pVM->vmm.s.iLastGZRc.
874 pVCpu->vmm.s.iLastGZRc = VERR_PGM_NO_CR3_SHADOW_ROOT;
903 if (pVM->vmm.s.fUsePeriodicPreemptionTimers)
910 int rc = HMR0EnterSwitcher(pVM, pVM->vmm.s.enmSwitcher, &fVTxDisabled);
924 rc = pVM->vmm.s.pfnR0ToRawMode(pVM);
925 pVCpu->vmm.s.iLastGZRc = rc;
932 SUPR0TracerUmodProbeFire(pVM->pSession, &pVCpu->vmm.s.TracerCtx);
950 STAM_COUNTER_INC(&pVM->vmm.s.StatRunRC);
955 pVCpu->vmm.s.iLastGZRc = rc;
977 pVCpu->vmm.s.iLastGZRc = VINF_EM_RAW_TO_R3;
979 pVCpu->vmm.s.iLastGZRc = rc;
982 pVCpu->vmm.s.iLastGZRc = VERR_INVALID_CPU_INDEX;
1014 if (pVM->vmm.s.fUsePeriodicPreemptionTimers)
1023 PVMMR0LOGGER pR0Logger = pVCpu->vmm.s.pR0LoggerR0;
1068 rc = vmmR0CallRing3SetJmp(&pVCpu->vmm.s.CallRing3JmpBufR0, HMR0RunGuestCode, pVM, pVCpu);
1077 pVM->vmm.s.szRing0AssertMsg1[0] = '\0';
1078 RTStrPrintf(pVM->vmm.s.szRing0AssertMsg2, sizeof(pVM->vmm.s.szRing0AssertMsg2),
1084 pVM->vmm.s.szRing0AssertMsg1[0] = '\0';
1085 RTStrPrintf(pVM->vmm.s.szRing0AssertMsg2, sizeof(pVM->vmm.s.szRing0AssertMsg2),
1092 STAM_COUNTER_INC(&pVM->vmm.s.StatRunRC);
1109 pVCpu->vmm.s.iLastGZRc = rc;
1131 pVCpu->vmm.s.iLastGZRc = VINF_EM_RAW_TO_R3;
1133 pVCpu->vmm.s.iLastGZRc = rc;
1136 pVCpu->vmm.s.iLastGZRc = VERR_INVALID_CPU_INDEX;
1145 pVCpu->vmm.s.iLastGZRc = VINF_SUCCESS;
1153 pVCpu->vmm.s.iLastGZRc = VERR_NOT_SUPPORTED;
1369 int rc = HMR0EnterSwitcher(pVM, pVM->vmm.s.enmSwitcher, &fVTxDisabled);
1375 rc = pVM->vmm.s.pfnR0ToRawMode(pVM);
1514 rc = vmmR0CallRing3SetJmp(&pVCpu->vmm.s.CallRing3JmpBufR0, GMMR0CheckSharedModules, pVM, pVCpu); /* this may resume code. */
1516 || (rc == VINF_VMM_CALL_HOST && pVCpu->vmm.s.enmCallRing3Operation == VMMCALLRING3_VMM_LOGGER_FLUSH));
1749 if (!pVCpu->vmm.s.CallRing3JmpBufR0.pvSavedStack)
1760 return vmmR0CallRing3SetJmpEx(&pVCpu->vmm.s.CallRing3JmpBufR0, vmmR0EntryExWrapper, &Args);
1782 return pVCpu->vmm.s.CallRing3JmpBufR0.eip
1783 && !pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call;
1785 return pVCpu->vmm.s.CallRing3JmpBufR0.rip
1786 && !pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call;
1800 return pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call;
1847 if ( !pVCpu->vmm.s.CallRing3JmpBufR0.eip
1848 || pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call)
1850 if ( !pVCpu->vmm.s.CallRing3JmpBufR0.rip
1851 || pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call)
1909 if (pVCpu->vmm.s.pR0LoggerR0)
1910 pVCpu->vmm.s.pR0LoggerR0->fFlushingDisabled = true;
1921 if (pVCpu->vmm.s.pR0LoggerR0)
1922 pVCpu->vmm.s.pR0LoggerR0->fFlushingDisabled = false;
1933 if (pVCpu->vmm.s.pR0LoggerR0)
1934 return pVCpu->vmm.s.pR0LoggerR0->fFlushingDisabled;
1957 if ( pVCpu->vmm.s.CallRing3JmpBufR0.eip
1958 && !pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call)
1960 if ( pVCpu->vmm.s.CallRing3JmpBufR0.rip
1961 && !pVCpu->vmm.s.CallRing3JmpBufR0.fInRing3Call)
2001 RTStrPrintf(pVM->vmm.s.szRing0AssertMsg1, sizeof(pVM->vmm.s.szRing0AssertMsg1),
2063 RTStrPrintfV(pVM->vmm.s.szRing0AssertMsg2, sizeof(pVM->vmm.s.szRing0AssertMsg2), pszFormat, vaCopy);