VirtualBox

Ignore:
Timestamp:
Jun 21, 2018 10:47:43 AM (6 years ago)
Author:
vboxsync
Message:

EM,HM: Removed EMInterpretRdtsc and EMInterpretRdtscp (reapplying r123092 backed out in r123118). Use VINF_IEM_RAISED_XCPT rather than VINF_EM_RESCHEDULE for clarity. bugref:6973

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR0/HMSVMR0.cpp

    r72623 r72636  
    62556255{
    62566256    HMSVM_VALIDATE_EXIT_HANDLER_PARAMS();
    6257 #if 1 /** @todo Needs testing. @bugref{6973} */
    62586257    VBOXSTRICTRC rcStrict = IEMExecDecodedRdtsc(pVCpu, hmR0SvmGetInstrLengthHwAssist(pVCpu, pCtx, 2));
    62596258    if (rcStrict == VINF_SUCCESS)
    62606259        pSvmTransient->fUpdateTscOffsetting = true;
    6261     else if (rcStrict == VINF_EM_RESCHEDULE)
     6260    else if (rcStrict == VINF_IEM_RAISED_XCPT)
    62626261        rcStrict = VINF_SUCCESS;
    62636262    HMSVM_CHECK_SINGLE_STEP(pVCpu, rcStrict);
    62646263    STAM_COUNTER_INC(&pVCpu->hm.s.StatExitRdtsc);
    62656264    return VBOXSTRICTRC_TODO(rcStrict);
    6266 #else
    6267     int rc = EMInterpretRdtsc(pVCpu->CTX_SUFF(pVM), pVCpu, CPUMCTX2CORE(pCtx));
    6268     if (RT_LIKELY(rc == VINF_SUCCESS))
    6269     {
    6270         pSvmTransient->fUpdateTscOffsetting = true;
    6271         hmR0SvmAdvanceRipHwAssist(pVCpu, pCtx, 2);
    6272         HMSVM_CHECK_SINGLE_STEP(pVCpu, rc);
    6273     }
    6274     else
    6275     {
    6276         AssertMsgFailed(("hmR0SvmExitRdtsc: EMInterpretRdtsc failed with %Rrc\n", rc));
    6277         rc = VERR_EM_INTERPRETER;
    6278     }
    6279     STAM_COUNTER_INC(&pVCpu->hm.s.StatExitRdtsc);
    6280     return rc;
    6281 #endif
    62826265}
    62836266
     
    62896272{
    62906273    HMSVM_VALIDATE_EXIT_HANDLER_PARAMS();
    6291 #if 1 /** @todo Needs testing. @bugref{6973} */
    62926274    VBOXSTRICTRC rcStrict = IEMExecDecodedRdtscp(pVCpu, hmR0SvmGetInstrLengthHwAssist(pVCpu, pCtx, 3));
    62936275    if (rcStrict == VINF_SUCCESS)
    62946276        pSvmTransient->fUpdateTscOffsetting = true;
    6295     else if (rcStrict == VINF_EM_RESCHEDULE)
     6277    else if (rcStrict == VINF_IEM_RAISED_XCPT)
    62966278        rcStrict = VINF_SUCCESS;
    62976279    HMSVM_CHECK_SINGLE_STEP(pVCpu, rcStrict);
    62986280    STAM_COUNTER_INC(&pVCpu->hm.s.StatExitRdtscp);
    62996281    return VBOXSTRICTRC_TODO(rcStrict);
    6300 #else
    6301     int rc = EMInterpretRdtscp(pVCpu->CTX_SUFF(pVM), pVCpu, pCtx);
    6302     if (RT_LIKELY(rc == VINF_SUCCESS))
    6303     {
    6304         pSvmTransient->fUpdateTscOffsetting = true;
    6305         hmR0SvmAdvanceRipHwAssist(pVCpu, pCtx, 3);
    6306         HMSVM_CHECK_SINGLE_STEP(pVCpu, rc);
    6307     }
    6308     else
    6309     {
    6310         AssertMsgFailed(("hmR0SvmExitRdtsc: EMInterpretRdtscp failed with %Rrc\n", rc));
    6311         rc = VERR_EM_INTERPRETER;
    6312     }
    6313     STAM_COUNTER_INC(&pVCpu->hm.s.StatExitRdtscp);
    6314     return rc;
    6315 #endif
    63166282}
    63176283
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette