- Timestamp:
- Apr 13, 2007 8:46:06 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMGC/TRPMGCHandlers.cpp
r2013 r2065 687 687 /* 688 688 * Handle virtualized TSC reads. 689 * (EMInterpretInstructionCPU isn't usable here because it rejects cpl != 0.)690 689 */ 691 690 case OP_RDTSC: 692 691 { 693 /** @todo statistics */ 694 if (CPUMGetGuestCR4(pVM) & X86_CR4_TSD) 695 rc = VINF_EM_RAW_EMULATE_INSTR; 696 else 697 { 698 uint64_t Tsc = TMCpuTickGet(pVM); 699 pRegFrame->eax = Tsc; 700 pRegFrame->edx = Tsc >> 32; 692 uint32_t cbIgnored; 693 rc = EMInterpretInstructionCPU(pVM, pCpu, pRegFrame, PC, &cbIgnored); 694 if (VBOX_SUCCESS(rc)) 701 695 pRegFrame->eip += pCpu->opsize; 702 rc = VINF_SUCCESS;703 }696 else if (rc == VERR_EM_INTERPRETER) 697 rc = VINF_EM_RAW_EXCEPTION_PRIVILEGED; 704 698 return trpmGCExitTrap(pVM, rc, pRegFrame); 705 699 }
Note:
See TracChangeset
for help on using the changeset viewer.