VirtualBox

Changeset 10277 in vbox for trunk/src/VBox/VMM/VMMAll


Ignore:
Timestamp:
Jul 5, 2008 2:02:00 PM (17 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
32889
Message:

Deal with 8 byte movsx instructions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/IOMAllMMIO.cpp

    r9837 r10277  
    179179     */
    180180    unsigned cb = DISGetParamSize(pCpu, &pCpu->param2);
    181     AssertMsg(cb > 0 && cb <= sizeof(uint32_t), ("cb=%d\n", cb));
    182 
    183     uint32_t u32Data = 0;
    184     int rc = iomMMIODoRead(pVM, pRange, GCPhysFault, &u32Data, cb);
     181    AssertMsg(cb > 0 && cb <= sizeof(uint64_t), ("cb=%d\n", cb));
     182
     183    uint64_t u64Data = 0;
     184    int rc = iomMMIODoRead(pVM, pRange, GCPhysFault, &u64Data, cb);
    185185    if (rc == VINF_SUCCESS)
    186186    {
     
    194194            {
    195195                /* DWORD <- BYTE */
    196                 int32_t iData = (int8_t)u32Data;
    197                 u32Data = (uint32_t)iData;
     196                int64_t iData = (int8_t)u64Data;
     197                u64Data = (uint64_t)iData;
    198198            }
    199199            else
    200200            {
    201201                /* DWORD <- WORD */
    202                 int32_t iData = (int16_t)u32Data;
    203                 u32Data = (uint32_t)iData;
     202                int64_t iData = (int16_t)u64Data;
     203                u64Data = (uint64_t)iData;
    204204            }
    205205        }
     
    208208         * Store the result to register (parameter 1).
    209209         */
    210         bool fRc = iomSaveDataToReg(pCpu, &pCpu->param1, pRegFrame, u32Data);
     210        bool fRc = iomSaveDataToReg(pCpu, &pCpu->param1, pRegFrame, u64Data);
    211211        AssertMsg(fRc, ("Failed to store register value!\n")); NOREF(fRc);
    212212    }
     
    319319     */
    320320    unsigned cb = DISGetParamSize(pCpu, &pCpu->param1);
    321     Assert(cb);
     321    AssertMsg(cb > 0 && cb <= sizeof(uint32_t), ("cb=%d\n", cb));
    322322    int      offIncrement = pRegFrame->eflags.Bits.u1DF ? -(signed)cb : (signed)cb;
    323323
     
    557557     */
    558558    unsigned cb = DISGetParamSize(pCpu, &pCpu->param1);
    559     Assert(cb);
     559    AssertMsg(cb > 0 && cb <= sizeof(uint32_t), ("cb=%d\n", cb));
    560560    int      offIncrement = pRegFrame->eflags.Bits.u1DF ? -(signed)cb : (signed)cb;
    561561
     
    663663     */
    664664    unsigned cb = DISGetParamSize(pCpu, &pCpu->param2);
    665     Assert(cb);
     665    AssertMsg(cb > 0 && cb <= sizeof(uint32_t), ("cb=%d\n", cb));
    666666    int     offIncrement = pRegFrame->eflags.Bits.u1DF ? -(signed)cb : (signed)cb;
    667667
Note: See TracChangeset for help on using the changeset viewer.

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