Changeset 66968 in vbox for trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-generated-1-template.c
- Timestamp:
- May 19, 2017 10:25:44 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
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
Note:
See TracChangeset
for help on using the changeset viewer.