VirtualBox

Changeset 67033 in vbox for trunk


Ignore:
Timestamp:
May 23, 2017 10:08:01 AM (7 years ago)
Author:
vboxsync
Message:

IEM: Tests+docs+adjustments for movntq Mq,Pq (0x0f 0xe7).

Location:
trunk/src/VBox
Files:
4 edited

Legend:

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

    r67030 r67033  
    89388938
    89398939
    8940 /** Opcode      0x0f 0xe7 - movntq Mq, Pq */
     8940/**
     8941 * @opcode      0xe7
     8942 * @opcodesub   !11 mr/reg
     8943 * @oppfx       none
     8944 * @opcpuid     sse
     8945 * @opgroup     og_sse1_cachect
     8946 * @opxcpttype  none
     8947 * @optest      op1=-1 op2=2  -> op1=2   ftw=0xff
     8948 * @optest      op1=0 op2=-42 -> op1=-42 ftw=0xff
     8949 */
    89418950FNIEMOP_DEF(iemOp_movntq_Mq_Pq)
    89428951{
    8943     IEMOP_MNEMONIC(movntq_Mq_Pq, "movntq Mq,Pq");
     8952    IEMOP_MNEMONIC2(MR_MEM, MOVNTQ, movntq, Mq_WO, Pq, DISOPTYPE_HARMLESS, IEMOPHINT_IGNORES_OP_SIZES);
    89448953    uint8_t bRm; IEM_OPCODE_GET_NEXT_U8(&bRm);
    89458954    if ((bRm & X86_MODRM_MOD_MASK) != (3 << X86_MODRM_MOD_SHIFT))
     
    89538962        IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX();
    89548963        IEM_MC_MAYBE_RAISE_MMX_RELATED_XCPT();
    8955         IEM_MC_ACTUALIZE_FPU_STATE_FOR_READ();
     8964        IEM_MC_ACTUALIZE_FPU_STATE_FOR_CHANGE();
    89568965
    89578966        IEM_MC_FETCH_MREG_U64(uSrc, (bRm >> X86_MODRM_REG_SHIFT) & X86_MODRM_REG_SMASK);
    89588967        IEM_MC_STORE_MEM_U64(pVCpu->iem.s.iEffSeg, GCPtrEffSrc, uSrc);
     8968        IEM_MC_FPU_TO_MMX_MODE();
    89598969
    89608970        IEM_MC_ADVANCE_RIP();
     
    89628972        return VINF_SUCCESS;
    89638973    }
    8964     /* The register, register encoding is invalid. */
     8974    /**
     8975     * @opdone
     8976     * @opmnemonic  ud0fe7reg
     8977     * @opcode      0xe7
     8978     * @opcodesub   11 mr/reg
     8979     * @oppfx       f2
     8980     * @opunused    immediate
     8981     * @opcpuid     sse
     8982     * @optest      ->
     8983     */
    89658984    return IEMOP_RAISE_INVALID_OPCODE();
    89668985}
  • trunk/src/VBox/VMM/VMMAll/IEMAllInstructionsVexMap1.cpp.h

    r67030 r67033  
    33643364 * @optest      op1=-1 op2=2 -> op1=2
    33653365 * @optest      op1=0 op2=-42 -> op1=-42
    3366  * @oponly
    33673366 */
    33683367FNIEMOP_DEF(iemOp_vmovq_Wq_Vq)
  • trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-generated-1-template.c

    r67030 r67033  
    23352335
    23362336
     2337static unsigned BS3_NEAR_CODE Bs3Cg1EncodeNext_MODRM_Mq_WO_Pq(PBS3CG1STATE pThis, unsigned iEncoding)
     2338{
     2339    unsigned off;
     2340    switch (iEncoding)
     2341    {
     2342        case 0:
     2343            off = Bs3Cg1InsertOpcodes(pThis, Bs3Cg1InsertReqPrefix(pThis, 0));
     2344            off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 4 /*iReg*/, 0 /*cbMisalign*/);
     2345            break;
     2346        case 1:
     2347            off = Bs3Cg1InsertOpcodes(pThis, Bs3Cg1InsertReqPrefix(pThis, 0));
     2348            off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 7 /*iReg*/, 1 /*cbMisalign*/);
     2349            iEncoding += !BS3CG1_IS_64BIT_TARGET(pThis) ? 1 : 0;
     2350            break;
     2351#if ARCH_BITS == 64
     2352        case 2:
     2353            off = Bs3Cg1InsertReqPrefix(pThis, 0);
     2354            pThis->abCurInstr[off++] = REX__RBX;
     2355            off = Bs3Cg1InsertOpcodes(pThis, off);
     2356            off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 7 /*iReg - no +8*/, 0 /*cbMisalign*/);
     2357            break;
     2358#endif
     2359
     2360        default:
     2361            return 0;
     2362    }
     2363
     2364    pThis->cbCurInstr = off;
     2365    return iEncoding + 1;
     2366}
     2367
     2368
    23372369static unsigned BS3_NEAR_CODE Bs3Cg1EncodeNext_MODRM_Mq_WO_Vq(PBS3CG1STATE pThis, unsigned iEncoding)
    23382370{
     
    45314563            pThis->aOperands[0].cbOp = 4;
    45324564            pThis->aOperands[0].enmLocation = BS3CG1OPLOC_MEM_WO;
     4565            break;
     4566
     4567        case BS3CG1ENC_MODRM_Mq_WO_Pq:
     4568            pThis->pfnEncoder        = Bs3Cg1EncodeNext_MODRM_Mq_WO_Pq;
     4569            pThis->iRmOp             = 0;
     4570            pThis->iRegOp            = 1;
     4571            pThis->aOperands[0].cbOp = 8;
     4572            pThis->aOperands[1].cbOp = 8;
     4573            pThis->aOperands[1].idxFieldBase = BS3CG1DST_MM0;
     4574            pThis->aOperands[0].enmLocation  = BS3CG1OPLOC_MEM_WO;
     4575            pThis->aOperands[1].enmLocation  = BS3CG1OPLOC_CTX;
    45334576            break;
    45344577
  • trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-generated-1.h

    r67030 r67033  
    173173    BS3CG1ENC_MODRM_Md_RO,
    174174    BS3CG1ENC_MODRM_Md_WO,
     175    BS3CG1ENC_MODRM_Mq_WO_Pq,
    175176    BS3CG1ENC_MODRM_Mq_WO_Vq,
    176177    BS3CG1ENC_MODRM_Mq_WO_VqHi,
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