VirtualBox

Changeset 41823 in vbox for trunk/src/VBox/VMM/VMMR0


Ignore:
Timestamp:
Jun 19, 2012 1:43:39 PM (12 years ago)
Author:
vboxsync
Message:

Avoid using SELMValidateAndConvertCSAddr+EMInterpretDisasOneEx when possible and call EMInterpretDisasOne instead. Changed EMInterpretDisasOne to use SELMValidateAndConvertCSAddr instead of SELMToFlatEx.

File:
1 edited

Legend:

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

    r41801 r41823  
    29742974    if (enmMode != DISCPUMODE_16BIT)
    29752975    {
    2976         RTGCPTR pbCode;
    2977         int rc = SELMValidateAndConvertCSAddr(pVCpu, pRegFrame->eflags, pRegFrame->ss, pRegFrame->cs,
    2978                                               &pRegFrame->csHid, (RTGCPTR)pRegFrame->rip, &pbCode);
    2979         if (RT_SUCCESS(rc))
    2980         {
    2981             uint32_t     cbOp;
    2982             PDISCPUSTATE pDis = &pVCpu->hwaccm.s.DisState;
    2983 
    2984             pDis->uCpuMode = enmMode;
    2985             rc = EMInterpretDisasOneEx(pVM, pVCpu, pbCode, pRegFrame, pDis, &cbOp);
    2986             Assert(RT_FAILURE(rc) || pDis->pCurInstr->uOpcode == OP_INVLPG);
    2987             if (RT_SUCCESS(rc) && pDis->pCurInstr->uOpcode == OP_INVLPG)
    2988             {
    2989                 Assert(cbOp == pDis->cbInstr);
    2990                 rc = hmR0svmInterpretInvlPg(pVCpu, pDis, pRegFrame, uASID);
    2991                 if (RT_SUCCESS(rc))
    2992                     pRegFrame->rip += cbOp; /* Move on to the next instruction. */
    2993 
    2994                 return rc;
    2995             }
     2976        PDISSTATE pDis = &pVCpu->hwaccm.s.DisState;
     2977        int rc = EMInterpretDisasOne(pVM, pVCpu, pRegFrame, pDis, NULL);
     2978        if (RT_SUCCESS(rc) && pDis->pCurInstr->uOpcode == OP_INVLPG)
     2979        {
     2980            rc = hmR0svmInterpretInvlPg(pVCpu, pDis, pRegFrame, uASID);
     2981            if (RT_SUCCESS(rc))
     2982                pRegFrame->rip += pDis->cbInstr; /* Move on to the next instruction. */
     2983            return rc;
    29962984        }
    29972985    }
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