Changeset 80150 in vbox for trunk/src/VBox/VMM/include
- Timestamp:
- Aug 6, 2019 7:44:20 AM (5 years ago)
- Location:
- trunk/src/VBox/VMM/include
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/include/HMInternal.h
r80080 r80150 665 665 AssertCompileMemberAlignment(HM, StatTprPatchSuccess, 8); 666 666 667 /* Maximum number of cached entries. */668 #define VMX_VMCS_CACHE_MAX_ENTRY 128669 670 /**671 * Cache of a VMCS for batch reads or writes.672 */673 typedef struct VMXVMCSCACHE674 {675 #ifdef VBOX_WITH_CRASHDUMP_MAGIC676 /* Magic marker for searching in crash dumps. */677 uint8_t aMagic[16];678 uint64_t uMagic;679 uint64_t u64TimeEntry;680 uint64_t u64TimeSwitch;681 uint64_t cResume;682 uint64_t interPD;683 uint64_t pSwitcher;684 uint32_t uPos;685 uint32_t idCpu;686 #endif687 /* CR2 is saved here for EPT syncing. */688 uint64_t cr2;689 struct690 {691 uint32_t cValidEntries;692 uint32_t uAlignment;693 uint32_t aField[VMX_VMCS_CACHE_MAX_ENTRY];694 uint64_t aFieldVal[VMX_VMCS_CACHE_MAX_ENTRY];695 } Write;696 struct697 {698 uint32_t cValidEntries;699 uint32_t uAlignment;700 uint32_t aField[VMX_VMCS_CACHE_MAX_ENTRY];701 uint64_t aFieldVal[VMX_VMCS_CACHE_MAX_ENTRY];702 } Read;703 #ifdef VBOX_STRICT704 struct705 {706 RTHCPHYS HCPhysCpuPage;707 RTHCPHYS HCPhysVmcs;708 RTGCPTR pCache;709 RTGCPTR pCtx;710 } TestIn;711 struct712 {713 RTHCPHYS HCPhysVmcs;714 RTGCPTR pCache;715 RTGCPTR pCtx;716 uint64_t eflags;717 uint64_t cr8;718 } TestOut;719 struct720 {721 uint64_t param1;722 uint64_t param2;723 uint64_t param3;724 uint64_t param4;725 } ScratchPad;726 #endif727 } VMXVMCSCACHE;728 /** Pointer to VMXVMCSCACHE. */729 typedef VMXVMCSCACHE *PVMXVMCSCACHE;730 AssertCompileSizeAlignment(VMXVMCSCACHE, 8);731 732 667 /** 733 668 * VMX StartVM function. … … 736 671 * @param fResume Whether to use VMRESUME (true) or VMLAUNCH (false). 737 672 * @param pCtx The CPU register context. 738 * @param p VmcsCache The VMCS batch cache.673 * @param pvUnused Unused argument. 739 674 * @param pVM Pointer to the cross context VM structure. 740 675 * @param pVCpu Pointer to the cross context per-CPU structure. 741 676 */ 742 typedef DECLCALLBACK(int) FNHMVMXSTARTVM(RTHCUINT fResume, PCPUMCTX pCtx, PVMXVMCSCACHE pVmcsCache, PVM pVM, PVMCPU pVCpu);677 typedef DECLCALLBACK(int) FNHMVMXSTARTVM(RTHCUINT fResume, PCPUMCTX pCtx, void *pvUnused, PVM pVM, PVMCPU pVCpu); 743 678 /** Pointer to a VMX StartVM function. */ 744 679 typedef R0PTRTYPE(FNHMVMXSTARTVM *) PFNHMVMXSTARTVM; … … 986 921 /** Cached guest APIC-base MSR for identifying when to map the APIC-access page. */ 987 922 uint64_t u64GstMsrApicBase; 988 /** VMCS cache for batched vmread/vmwrites. */989 VMXVMCSCACHE VmcsCache;990 923 PGMPAGEMAPLOCK PgMapLockVirtApic; 991 924 /** @} */ … … 1255 1188 1256 1189 # ifdef VBOX_WITH_KERNEL_USING_XMM 1257 DECLASM(int) hmR0VMXStartVMWrapXMM(RTHCUINT fResume, PCPUMCTX pCtx, PVMXVMCSCACHE pVmcsCache, PVM pVM,1258 P VMCPU pVCpu, PFNHMVMXSTARTVM pfnStartVM);1190 DECLASM(int) hmR0VMXStartVMWrapXMM(RTHCUINT fResume, PCPUMCTX pCtx, void *pvUnused, PVM pVM, PVMCPU pVCpu, 1191 PFNHMVMXSTARTVM pfnStartVM); 1259 1192 DECLASM(int) hmR0SVMRunWrapXMM(RTHCPHYS pVmcbHostPhys, RTHCPHYS pVmcbPhys, PCPUMCTX pCtx, PVM pVM, PVMCPU pVCpu, 1260 1193 PFNHMSVMVMRUN pfnVMRun); -
trunk/src/VBox/VMM/include/HMInternal.mac
r80078 r80150 15 15 ; hope that it will be useful, but WITHOUT ANY WARRANTY of any kind. 16 16 ; 17 18 ;Maximum number of cached entries.19 %define VMX_VMCS_CACHE_MAX_ENTRY 12820 21 ; Structure for storing read and write VMCS actions.22 struc VMXVMCSCACHE23 %ifdef VBOX_WITH_CRASHDUMP_MAGIC24 .aMagic resb 1625 .uMagic resq 126 .u64TimeEntry resq 127 .u64TimeSwitch resq 128 .cResume resq 129 .interPD resq 130 .pSwitcher resq 131 .uPos resd 132 .idCpu resd 133 %endif34 .cr2 resq 135 .Write.cValidEntries resd 136 .Write.uAlignment resd 137 .Write.aField resd VMX_VMCS_CACHE_MAX_ENTRY38 .Write.aFieldVal resq VMX_VMCS_CACHE_MAX_ENTRY39 .Read.cValidEntries resd 140 .Read.uAlignment resd 141 .Read.aField resd VMX_VMCS_CACHE_MAX_ENTRY42 .Read.aFieldVal resq VMX_VMCS_CACHE_MAX_ENTRY43 %ifdef VBOX_STRICT44 .TestIn.HCPhysCpuPage resq 145 .TestIn.HCPhysVmcs resq 146 .TestIn.pCache resq 147 .TestIn.pCtx resq 148 .TestOut.HCPhysVmcs resq 149 .TestOut.pCache resq 150 .TestOut.pCtx resq 151 .TestOut.eflags resq 152 .TestOut.cr8 resq 153 .ScratchPad.param1 resq 154 .ScratchPad.param2 resq 155 .ScratchPad.param3 resq 156 .ScratchPad.param4 resq 157 %endif58 endstruc59 17 60 18 struc HMCPU
Note:
See TracChangeset
for help on using the changeset viewer.