Changeset 66968 in vbox for trunk/src/VBox
- Timestamp:
- May 19, 2017 10:25:44 AM (8 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAllInstructionsVexMap1.cpp.h
r66966 r66968 856 856 * @optest vex.l==1 / op2=0xbbbbbbbbcccccccc4444444433333333ddddddddeeeeeeee2222222211111111 857 857 * -> op1=0x4444444433333333444444443333333322222222111111112222222211111111 858 * @oponly859 858 */ 860 859 FNIEMOP_DEF(iemOp_vmovddup_Vx_Wx) … … 959 958 * @optest op1=1 op2=2 -> op1=2 960 959 * @optest op1=0 op2=-42 -> op1=-42 960 * @oponly 961 961 */ 962 962 FNIEMOP_DEF(iemOp_vmovlps_Mq_Vq) … … 993 993 * @opcpuid avx 994 994 * @optest -> 995 * @oponly 995 996 */ 996 997 return IEMOP_RAISE_INVALID_OPCODE(); … … 998 999 999 1000 1000 /** Opcode VEX.66.0F 0x13 - vmovlpd Mq, Vq */1001 FNIEMOP_STUB(iemOp_vmovlpd_Mq_Vq); 1002 //FNIEMOP_DEF(iemOp_vmovlpd_Mq_Vq) 1003 //{ 1004 // IEMOP_MNEMONIC(vmovlpd_Mq_Vq, "movlpd Mq,Vq"); 1005 // uint8_t bRm; IEM_OPCODE_GET_NEXT_U8(&bRm); 1006 // if ((bRm & X86_MODRM_MOD_MASK) == (3 << X86_MODRM_MOD_SHIFT)) 1007 // { 1008 //#if 0 1009 // /* 1010 // * Register, register. 1011 // */ 1012 // IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1013 // IEM_MC_BEGIN(0, 1);1014 // IEM_MC_LOCAL(uint64_t, uSrc); 1015 // IEM_MC_MAYBE_RAISE_SSE2_RELATED_XCPT(); 1016 // IEM_MC_ACTUALIZE_SSE_STATE_FOR_CHANGE();1017 // IEM_MC_FETCH_XREG_U64(uSrc, ((bRm >> X86_MODRM_REG_SHIFT) & X86_MODRM_REG_SMASK) | pVCpu->iem.s.uRexReg);1018 // IEM_MC_STORE_XREG_U64((bRm & X86_MODRM_RM_MASK) | pVCpu->iem.s.uRexB,uSrc);1019 // IEM_MC_ADVANCE_RIP();1020 // IEM_MC_END(); 1021 //#else 1022 // return IEMOP_RAISE_INVALID_OPCODE();1023 //#endif 1024 // } 1025 // else 1026 // { 1027 // /* 1028 // * Memory, register. 1029 // */ 1030 // IEM_MC_BEGIN(0, 2);1031 // IEM_MC_LOCAL(uint64_t, uSrc);1032 // IEM_MC_LOCAL(RTGCPTR, GCPtrEffSrc); 1033 // 1034 // IEM_MC_CALC_RM_EFF_ADDR(GCPtrEffSrc, bRm, 0); 1035 // IEMOP_HLP_DONE_DECODING_NO_LOCK_PREFIX(); 1036 // IEM_MC_MAYBE_RAISE_SSE2_RELATED_XCPT(); 1037 // IEM_MC_ACTUALIZE_SSE_STATE_FOR_READ(); 1038 // 1039 // IEM_MC_FETCH_XREG_U64(uSrc, ((bRm >> X86_MODRM_REG_SHIFT) & X86_MODRM_REG_SMASK) | pVCpu->iem.s.uRexReg); 1040 // IEM_MC_STORE_MEM_U64(pVCpu->iem.s.iEffSeg, GCPtrEffSrc, uSrc); 1041 // 1042 // IEM_MC_ADVANCE_RIP(); 1043 // IEM_MC_END(); 1044 // } 1045 // return VINF_SUCCESS;1046 //}1001 /** 1002 * @opcode 0x13 1003 * @opcodesub !11 mr/reg 1004 * @oppfx 0x66 1005 * @opcpuid avx 1006 * @opgroup og_avx_pcksclr_datamove 1007 * @opxcpttype 5 1008 * @optest op1=1 op2=2 -> op1=2 1009 * @optest op1=0 op2=-42 -> op1=-42 1010 * @oponly 1011 */ 1012 FNIEMOP_DEF(iemOp_vmovlpd_Mq_Vq) 1013 { 1014 uint8_t bRm; IEM_OPCODE_GET_NEXT_U8(&bRm); 1015 if ((bRm & X86_MODRM_MOD_MASK) != (3 << X86_MODRM_MOD_SHIFT)) 1016 { 1017 IEMOP_MNEMONIC2(VEX_MR_MEM, VMOVLPD, vmovlpd, Mq_WO, Vq, DISOPTYPE_HARMLESS, IEMOPHINT_IGNORES_OP_SIZE | IEMOPHINT_VEX_L_ZERO); 1018 IEM_MC_BEGIN(0, 2); 1019 IEM_MC_LOCAL(uint64_t, uSrc); 1020 IEM_MC_LOCAL(RTGCPTR, GCPtrEffSrc); 1021 1022 IEM_MC_CALC_RM_EFF_ADDR(GCPtrEffSrc, bRm, 0); 1023 IEMOP_HLP_DONE_VEX_DECODING_L0_AND_NO_VVVV(); 1024 IEM_MC_MAYBE_RAISE_AVX_RELATED_XCPT(); 1025 IEM_MC_ACTUALIZE_AVX_STATE_FOR_READ(); 1026 1027 IEM_MC_FETCH_YREG_U64(uSrc, ((bRm >> X86_MODRM_REG_SHIFT) & X86_MODRM_REG_SMASK) | pVCpu->iem.s.uRexReg); 1028 IEM_MC_STORE_MEM_U64(pVCpu->iem.s.iEffSeg, GCPtrEffSrc, uSrc); 1029 1030 IEM_MC_ADVANCE_RIP(); 1031 IEM_MC_END(); 1032 return VINF_SUCCESS; 1033 } 1034 1035 /** 1036 * @opdone 1037 * @opmnemonic udvex660f13m3 1038 * @opcode 0x13 1039 * @opcodesub 11 mr/reg 1040 * @oppfx 0x66 1041 * @opunused immediate 1042 * @opcpuid avx 1043 * @optest -> 1044 * @oponly 1045 */ 1046 return IEMOP_RAISE_INVALID_OPCODE(); 1047 } 1047 1048 1048 1049 /* Opcode VEX.F3.0F 0x13 - invalid */ -
trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-generated-1-data.py
r66937 r66968 327 327 if oInstr.sInvalidStyle and oInstr.sInvalidStyle.startswith('intel-'): 328 328 self.asFlags.append('BS3CG1INSTR_F_INTEL_DECODES_INVALID'); 329 if 'vex_l_zero' in oInstr.dHints: 330 self.asFlags.append('BS3CG1INSTR_F_VEX_L_ZERO'); 329 331 330 332 self.fAdvanceMnemonic = True; ##< Set by the caller. -
trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-generated-1-template.c
r66957 r66968 2787 2787 pThis->fInvalidEncoding = true; 2788 2788 break; 2789 case 11: 2790 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 7 /*~V*/, 0 /*L*/, 1 /*~R*/, 1 /*~X*/, 1 /*~B*/, 0 /*W*/); 2791 off = Bs3Cg1InsertOpcodes(pThis, off); 2792 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 2, 0); 2793 pThis->fInvalidEncoding = true; 2794 break; 2795 default: 2796 return 0; 2797 } 2798 pThis->cbCurInstr = off; 2799 return iEncoding + 1; 2800 } 2801 2802 2803 /** 2804 * Wip - VEX.W ignored. 2805 * L0 - VEX.L must be zero. 2806 */ 2807 static unsigned BS3_NEAR_CODE 2808 Bs3Cg1EncodeNext_VEX_MODRM_VsomethingWO_Msomething_Wip_L0_OR_ViceVersa(PBS3CG1STATE pThis, unsigned iEncoding) 2809 { 2810 unsigned off; 2811 switch (iEncoding) 2812 { 2813 case 0: 2814 off = Bs3Cg1InsertVex2bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 1 /*~R*/); 2815 off = Bs3Cg1InsertOpcodes(pThis, off); 2816 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 0, 0); 2817 break; 2818 case 1: 2819 off = Bs3Cg1InsertVex2bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 1 /*L - invalid*/, 1 /*~R*/); 2820 off = Bs3Cg1InsertOpcodes(pThis, off); 2821 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 7, 0); 2822 pThis->fInvalidEncoding = true; 2823 if (!BS3_MODE_IS_64BIT_CODE(pThis->bMode)) 2824 iEncoding += 2; 2825 break; 2826 #if ARCH_BITS == 64 2827 case 2: 2828 off = Bs3Cg1InsertVex2bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 0 /*~R*/); 2829 off = Bs3Cg1InsertOpcodes(pThis, off); 2830 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 7 + 8, 0); 2831 break; 2832 case 3: 2833 off = Bs3Cg1InsertVex2bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 1 /*L - invalid*/, 0 /*~R*/); 2834 off = Bs3Cg1InsertOpcodes(pThis, off); 2835 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 5 + 8, 0); 2836 pThis->fInvalidEncoding = true; 2837 break; 2838 #endif 2839 case 4: 2840 off = Bs3Cg1InsertVex2bPrefix(pThis, 0 /*offDst*/, 0xe /*~V*/, 0 /*L*/, 1 /*~R*/); 2841 off = Bs3Cg1InsertOpcodes(pThis, off); 2842 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 0, 0); 2843 pThis->fInvalidEncoding = true; 2844 break; 2845 case 5: 2846 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 1 /*~R*/, 1 /*~X*/, 1 /*~B*/, 0 /*W*/); 2847 off = Bs3Cg1InsertOpcodes(pThis, off); 2848 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 1, 0); 2849 break; 2850 case 6: 2851 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 1 /*L - invalid*/, 1 /*~R*/, 1 /*~X*/, 1 /*~B*/, 0 /*W*/); 2852 off = Bs3Cg1InsertOpcodes(pThis, off); 2853 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 1, 0); 2854 pThis->fInvalidEncoding = true; 2855 break; 2856 case 7: 2857 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 1 /*~R*/, 1 /*~X*/, 1 /*~B*/, 1 /*W-ignored*/); 2858 off = Bs3Cg1InsertOpcodes(pThis, off); 2859 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 5, 0); 2860 if (!BS3_MODE_IS_64BIT_CODE(pThis->bMode)) 2861 iEncoding += 3; 2862 break; 2863 #if ARCH_BITS == 64 2864 case 8: 2865 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 0 /*~R*/, 1 /*~X*/, 1 /*~B*/, 0 /*W*/); 2866 off = Bs3Cg1InsertOpcodes(pThis, off); 2867 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 5+8, 0); 2868 break; 2869 case 9: 2870 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 1 /*~R*/, 1 /*~X*/, 0 /*~B-ignored*/, 0 /*W*/); 2871 off = Bs3Cg1InsertOpcodes(pThis, off); 2872 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 1, 0); 2873 break; 2874 case 10: 2875 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0xf /*~V*/, 0 /*L*/, 1 /*~R*/, 0 /*~X-ignored*/, 1 /*~B*/, 0 /*W*/); 2876 off = Bs3Cg1InsertOpcodes(pThis, off); 2877 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 2, 0); 2878 break; 2879 #endif 2880 case 11: 2881 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 0 /*~V*/, 0 /*L*/, 1 /*~R*/, 1 /*~X*/, 1 /*~B*/, 0 /*W*/); 2882 off = Bs3Cg1InsertOpcodes(pThis, off); 2883 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 5, 0); 2884 pThis->fInvalidEncoding = true; 2885 break; 2886 case 12: 2887 off = Bs3Cg1InsertVex3bPrefix(pThis, 0 /*offDst*/, 7 /*~V*/, 0 /*L*/, 1 /*~R*/, 1 /*~X*/, 1 /*~B*/, 0 /*W*/); 2888 off = Bs3Cg1InsertOpcodes(pThis, off); 2889 off = Bs3Cfg1EncodeMemMod0DispWithRegFieldAndDefaults(pThis, false, off, 2, 0); 2890 pThis->fInvalidEncoding = true; 2891 break; 2789 2892 default: 2790 2893 return 0; … … 3780 3883 pThis->aOperands[0].idxFieldBase = BS3CG1DST_INVALID; 3781 3884 pThis->aOperands[1].idxFieldBase = BS3CG1DST_XMM0_DW0; 3885 break; 3886 3887 case BS3CG1ENC_VEX_MODRM_Mq_WO_Vq: 3888 pThis->pfnEncoder = pThis->fFlags & BS3CG1INSTR_F_VEX_L_ZERO 3889 ? Bs3Cg1EncodeNext_VEX_MODRM_VsomethingWO_Msomething_Wip_L0_OR_ViceVersa 3890 : Bs3Cg1EncodeNext_VEX_MODRM_VsomethingWO_Msomething_Wip_Lig_OR_ViceVersa; 3891 pThis->iRmOp = 0; 3892 pThis->iRegOp = 1; 3893 pThis->aOperands[0].cbOp = 8; 3894 pThis->aOperands[1].cbOp = 8; 3895 pThis->aOperands[0].enmLocation = BS3CG1OPLOC_MEM_WO; 3896 pThis->aOperands[1].enmLocation = BS3CG1OPLOC_CTX; 3897 pThis->aOperands[0].idxFieldBase = BS3CG1DST_INVALID; 3898 pThis->aOperands[1].idxFieldBase = BS3CG1DST_XMM0_LO; 3782 3899 break; 3783 3900 -
trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-generated-1.h
r66950 r66968 161 161 BS3CG1ENC_VEX_MODRM_Vx_WO_Wx, 162 162 BS3CG1ENC_VEX_MODRM_Md_WO, 163 BS3CG1ENC_VEX_MODRM_Mq_WO_Vq, 163 164 BS3CG1ENC_VEX_MODRM_Md_WO_Vss, 164 165 BS3CG1ENC_VEX_MODRM_Mq_WO_Vsd, … … 316 317 * Always used with BS3CG1INSTR_F_INVALID or BS3CG1INSTR_F_UNUSED. */ 317 318 #define BS3CG1INSTR_F_INTEL_DECODES_INVALID UINT32_C(0x00000010) 319 /** VEX.L must be zero (IEMOPHINT_VEX_L_ZERO). */ 320 #define BS3CG1INSTR_F_VEX_L_ZERO UINT32_C(0x00000020) 318 321 /** @} */ 319 322
Note:
See TracChangeset
for help on using the changeset viewer.