VirtualBox

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


Ignore:
Timestamp:
Feb 3, 2012 4:31:04 PM (13 years ago)
Author:
vboxsync
Message:

txtX86-1: some prefix decoding checks for the groups and rex.

File:
1 edited

Legend:

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

    r39974 r39989  
    32663266
    32673267/** Opcode 0x0f 0xae. */
    3268 FNIEMOP_STUB(iemOp_Grp15); /** @todo next up: fxrstor */
     3268FNIEMOP_DEF(iemOp_Grp15)
     3269{
     3270    uint8_t bRm; IEM_OPCODE_GET_NEXT_U8(&bRm);
     3271    IEMOP_HLP_NO_LOCK_PREFIX(); /** @todo should probably not be raised until we've fetched all the opcode bytes? */
     3272    if ((bRm & X86_MODRM_MOD_MASK) != (3 << X86_MODRM_MOD_SHIFT))
     3273    {
     3274        ////
     3275    }
     3276    else
     3277    {
     3278
     3279        if (pIemCpu->offOpcode == 2 || )
     3280        {
     3281        }
     3282        pIemCpu->
     3283        switch (pIemCpu->fPrefixes & (IEM_OP_PRF_REPZ | IEM_OP_PRF_REPNZ | IEM_OP_PRF_SIZE_OP))
     3284        {
     3285            case IEM_OP_PRF_SIZE_OP:
     3286
     3287
     3288            case IEM_OP_PRF_REPZ:
     3289        }
     3290    }
     3291
     3292
     3293
     3294    if ((bRm & X86_MODRM_REG_MASK) != (0 << X86_MODRM_REG_SHIFT)) /* only mov Eb,Ib in this group. */
     3295        return IEMOP_RAISE_INVALID_LOCK_PREFIX();
     3296    IEMOP_MNEMONIC("mov Eb,Ib");
     3297
     3298    if ((bRm & X86_MODRM_MOD_MASK) == (3 << X86_MODRM_MOD_SHIFT))
     3299    {
     3300        /* register access */
     3301        uint8_t u8Imm; IEM_OPCODE_GET_NEXT_U8(&u8Imm);
     3302        IEM_MC_BEGIN(0, 0);
     3303        IEM_MC_STORE_GREG_U8((bRm & X86_MODRM_RM_MASK) | pIemCpu->uRexB, u8Imm);
     3304        IEM_MC_ADVANCE_RIP();
     3305        IEM_MC_END();
     3306    }
     3307    else
     3308    {
     3309        /* memory access. */
     3310        IEM_MC_BEGIN(0, 1);
     3311        IEM_MC_LOCAL(RTGCPTR, GCPtrEffDst);
     3312        IEM_MC_CALC_RM_EFF_ADDR(GCPtrEffDst, bRm);
     3313        uint8_t u8Imm; IEM_OPCODE_GET_NEXT_U8(&u8Imm);
     3314        IEM_MC_STORE_MEM_U8(pIemCpu->iEffSeg, GCPtrEffDst, u8Imm);
     3315        IEM_MC_ADVANCE_RIP();
     3316        IEM_MC_END();
     3317    }
     3318    return VINF_SUCCESS;
     3319}
    32693320
    32703321
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