VirtualBox

Changeset 22015 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Aug 6, 2009 8:39:54 AM (15 years ago)
Author:
vboxsync
Message:

Removed unnecessary TPR patch instructions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/HWACCM.cpp

    r22002 r22015  
    17711771                *
    17721772                */
     1773            bool fUsesEax = (pDis->param2.flags == USE_REG_GEN32 && pDis->param2.base.reg_gen == USE_REG_EAX);
     1774
    17731775            aPatch[off++] = 0x51;    /* push ecx */
    17741776            aPatch[off++] = 0x52;    /* push edx */
    1775             aPatch[off++] = 0x50;    /* push eax */
     1777            if (!fUsesEax)
     1778                aPatch[off++] = 0x50;    /* push eax */
    17761779            aPatch[off++] = 0x31;    /* xor edx, edx */
    17771780            aPatch[off++] = 0xD2;
    17781781            if (pDis->param2.flags == USE_REG_GEN32)
    17791782            {
    1780                 if (pDis->param2.base.reg_gen != USE_REG_EAX)
     1783                if (!fUsesEax)
    17811784                {
    17821785                    aPatch[off++] = 0x89;    /* mov eax, src_reg */
     
    17971800            aPatch[off++] = 0x0F;    /* wrmsr */
    17981801            aPatch[off++] = 0x30;
    1799             aPatch[off++] = 0x58;    /* pop eax */
     1802            if (!fUsesEax)
     1803                aPatch[off++] = 0x58;    /* pop eax */
    18001804            aPatch[off++] = 0x5A;    /* pop edx */
    18011805            aPatch[off++] = 0x59;    /* pop ecx */
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