VirtualBox

Changeset 10275 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Jul 5, 2008 1:39:26 PM (17 years ago)
Author:
vboxsync
Message:

Handle the 'mov %Ev, %Iz' case correctly in 64 bits op mode.

Location:
trunk/src/VBox/Disassembler
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Disassembler/DisasmCore.cpp

    r10272 r10275  
    13231323    {
    13241324        pParam->parval = DISReadDWord(pCpu, lpszCodeBlock);
    1325         pParam->flags |= USE_IMMEDIATE32;
    1326         pParam->size   = sizeof(uint32_t);
     1325        /* 64 bits op mode means zero extend to 64 bits. */
     1326        if (pCpu->opmode == CPUMODE_64BIT)
     1327        {
     1328            pParam->flags |= USE_IMMEDIATE64;
     1329            pParam->size   = sizeof(uint64_t);
     1330        }
     1331        else
     1332        {
     1333            pParam->flags |= USE_IMMEDIATE32;
     1334            pParam->size   = sizeof(uint32_t);
     1335        }
    13271336
    13281337        disasmAddStringF(pParam->szParam, sizeof(pParam->szParam), "0%08Xh", (uint32_t)pParam->parval);
  • trunk/src/VBox/Disassembler/DisasmTest.cpp

    r9761 r10275  
    7878            char         szOutput[256];
    7979
    80 //__debugbreak();
     80__debugbreak();
    8181            memset(&cpu, 0, sizeof(cpu));
    8282            cpu.mode = CPUMODE_64BIT;
  • trunk/src/VBox/Disassembler/DisasmTestA.asm

    r10271 r10275  
    7373      ;incorrectly assembled by yasm; REX.W should not be added!
    7474      ;test rax, dword 0cc90cc90h
     75      mov   qword [rcx+rdx], 0
     76      mov   dword [rcx+rdx], 0
    7577      and   [r15], rax
    7678      movzx rcx, sil
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