Changeset 17295 in vbox
- Timestamp:
- Mar 3, 2009 3:56:07 PM (16 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/hwaccm.h
r17292 r17295 120 120 VMMR3DECL(bool) HWACCMR3IsVPIDActive(PVM pVM); 121 121 VMMR3DECL(int) HWACCMR3InjectNMI(PVM pVM); 122 VMMR3DECL( void)HWACCMR3EmulateIoBlock(PVM pVM, PCPUMCTX pCtx);122 VMMR3DECL(int) HWACCMR3EmulateIoBlock(PVM pVM, PCPUMCTX pCtx); 123 123 124 124 /** @} */ -
trunk/src/VBox/VMM/EM.cpp
r17292 r17295 2360 2360 */ 2361 2361 case VINF_EM_RAW_EMULATE_IO_BLOCK: 2362 HWACCMR3EmulateIoBlock(pVM, pCtx); 2363 rc = VINF_EM_RESCHEDULE_REM; 2362 rc =HWACCMR3EmulateIoBlock(pVM, pCtx); 2364 2363 break; 2365 2364 -
trunk/src/VBox/VMM/HWACCM.cpp
r17293 r17295 1192 1192 * Force execution of the current IO code in the recompiler 1193 1193 * 1194 * @returns VBox status code. 1194 1195 * @param pVM The VM to operate on. 1195 1196 * @param pCtx Partial VM execution context 1196 1197 */ 1197 VMMR3DECL( void) HWACCMR3EmulateIoBlock(PVM pVM, PCPUMCTX pCtx)1198 VMMR3DECL(int) HWACCMR3EmulateIoBlock(PVM pVM, PCPUMCTX pCtx) 1198 1199 { 1199 1200 PVMCPU pVCpu = VMMGetCpu(pVM); 1200 1201 1201 1202 Assert(pVM->fHWACCMEnabled); 1202 pVCpu->hwaccm.s.EmulateIoBlock.fEnabled = true; 1203 pVCpu->hwaccm.s.EmulateIoBlock.GCPtrFunctionEsp = pCtx->rsp; 1203 Log(("HWACCMR3EmulateIoBlock\n")); 1204 if (!CPUMIsGuestInPagedProtectedModeEx(pCtx)) 1205 { 1206 Log(("HWACCMR3EmulateIoBlock -> enabled\n")); 1207 pVCpu->hwaccm.s.EmulateIoBlock.fEnabled = true; 1208 pVCpu->hwaccm.s.EmulateIoBlock.GCPtrFunctionEsp = pCtx->rsp; 1209 pVCpu->hwaccm.s.EmulateIoBlock.cr0 = pCtx->cr0; 1210 return VINF_EM_RESCHEDULE_REM; 1211 } 1212 return VINF_SUCCESS; 1204 1213 } 1205 1214 … … 1218 1227 1219 1228 if ( RT_UNLIKELY(pVCpu->hwaccm.s.EmulateIoBlock.fEnabled) 1220 && pCtx->rsp <= pVCpu->hwaccm.s.EmulateIoBlock.GCPtrFunctionEsp) 1229 && pCtx->rsp <= pVCpu->hwaccm.s.EmulateIoBlock.GCPtrFunctionEsp 1230 && pCtx->cr0 == pVCpu->hwaccm.s.EmulateIoBlock.cr0) 1221 1231 return false; 1222 1232 -
trunk/src/VBox/VMM/HWACCMInternal.h
r17292 r17295 558 558 /** Esp at the start of the io code we wish to emulate in the recompiler. */ 559 559 RTGCPTR GCPtrFunctionEsp; 560 561 uint64_t cr0; 560 562 } EmulateIoBlock; 561 563
Note:
See TracChangeset
for help on using the changeset viewer.