コード例 #1
0
ファイル: OpCodeHandlers.cs プロジェクト: weiling103/iced
 public OpCodeHandler_MandatoryPrefix3(OpCodeHandler handler_reg, OpCodeHandler handler_mem, OpCodeHandler handler66_reg, OpCodeHandler handler66_mem, OpCodeHandler handlerF3_reg, OpCodeHandler handlerF3_mem, OpCodeHandler handlerF2_reg, OpCodeHandler handlerF2_mem, LegacyHandlerFlags flags)
 {
     Debug.Assert((int)MandatoryPrefix.None == 0);
     Debug.Assert((int)MandatoryPrefix.P66 == 1);
     Debug.Assert((int)MandatoryPrefix.PF3 == 2);
     Debug.Assert((int)MandatoryPrefix.PF2 == 3);
     handlers_reg = new Info[4] {
         new Info(handler_reg ?? throw new ArgumentNullException(nameof(handler_reg)), (flags & LegacyHandlerFlags.HandlerReg) == 0),
         new Info(handler66_reg ?? throw new ArgumentNullException(nameof(handler66_reg)), (flags & LegacyHandlerFlags.Handler66Reg) == 0),
         new Info(handlerF3_reg ?? throw new ArgumentNullException(nameof(handlerF3_reg)), (flags & LegacyHandlerFlags.HandlerF3Reg) == 0),
         new Info(handlerF2_reg ?? throw new ArgumentNullException(nameof(handlerF2_reg)), (flags & LegacyHandlerFlags.HandlerF2Reg) == 0),
     };
     handlers_mem = new Info[4] {
         new Info(handler_mem ?? throw new ArgumentNullException(nameof(handler_mem)), (flags & LegacyHandlerFlags.HandlerMem) == 0),
         new Info(handler66_mem ?? throw new ArgumentNullException(nameof(handler66_mem)), (flags & LegacyHandlerFlags.Handler66Mem) == 0),
         new Info(handlerF3_mem ?? throw new ArgumentNullException(nameof(handlerF3_mem)), (flags & LegacyHandlerFlags.HandlerF3Mem) == 0),
         new Info(handlerF2_mem ?? throw new ArgumentNullException(nameof(handlerF2_mem)), (flags & LegacyHandlerFlags.HandlerF2Mem) == 0),
     };
     Debug.Assert(handler_reg.HasModRM == HasModRM);
     Debug.Assert(handler_mem.HasModRM == HasModRM);
     Debug.Assert(handler66_reg.HasModRM == HasModRM);
     Debug.Assert(handler66_mem.HasModRM == HasModRM);
     Debug.Assert(handlerF3_reg.HasModRM == HasModRM);
     Debug.Assert(handlerF3_mem.HasModRM == HasModRM);
     Debug.Assert(handlerF2_reg.HasModRM == HasModRM);
     Debug.Assert(handlerF2_mem.HasModRM == HasModRM);
 }
コード例 #2
0
 public OpCodeHandler_W(OpCodeHandler handlerW0, OpCodeHandler handlerW1)
 {
     this.handlerW0 = handlerW0 ?? throw new ArgumentNullException(nameof(handlerW0));
     this.handlerW1 = handlerW1 ?? throw new ArgumentNullException(nameof(handlerW1));
     Debug.Assert(handlerW0.HasModRM == HasModRM);
     Debug.Assert(handlerW1.HasModRM == HasModRM);
 }
コード例 #3
0
 public OpCodeHandler_Options_DontReadModRM(OpCodeHandler defaultHandler, OpCodeHandler handler1, DecoderOptions options1)
 {
     this.defaultHandler = defaultHandler ?? throw new ArgumentNullException(nameof(defaultHandler));
     infos = new HandlerOptions[] {
         new HandlerOptions(handler1, options1),
     };
 }
コード例 #4
0
 public OpCodeHandler_Options(OpCodeHandler defaultHandler, OpCodeHandler handler1, DecoderOptions options1, OpCodeHandler handler2, DecoderOptions options2)
 {
     this.defaultHandler = defaultHandler ?? throw new ArgumentNullException(nameof(defaultHandler));
     infos = new HandlerOptions[] {
         new HandlerOptions(handler1 ?? throw new ArgumentNullException(nameof(handler1)), options1),
         new HandlerOptions(handler2 ?? throw new ArgumentNullException(nameof(handler2)), options2),
     };
 }
コード例 #5
0
ファイル: OpCodeHandlers.cs プロジェクト: xoofx/iced
 public OpCodeHandler_MandatoryPrefix_F3_F2(OpCodeHandler handlerNormal, OpCodeHandler handlerF3, OpCodeHandler handlerF2)
 {
     this.handlerNormal = handlerNormal ?? throw new ArgumentNullException(nameof(handlerNormal));
     this.handlerF3     = handlerF3 ?? throw new ArgumentNullException(nameof(handlerF3));
     this.handlerF2     = handlerF2 ?? throw new ArgumentNullException(nameof(handlerF2));
     Debug.Assert(handlerNormal.HasModRM == HasModRM);
     Debug.Assert(handlerF3.HasModRM == HasModRM);
     Debug.Assert(handlerF2.HasModRM == HasModRM);
 }
コード例 #6
0
 static OpCodeHandler WL0(OpCodeHandler handlerW0, OpCodeHandler handlerW1) =>
 new OpCodeHandler_MandatoryPrefix2(
     new OpCodeHandler_VectorLength_VEX(
         new OpCodeHandler_W(
             handlerW0,
             handlerW1
             ),
         OpCodeHandler_Invalid.Instance
         )
     );
コード例 #7
0
ファイル: OpCodeHandlers.cs プロジェクト: xoofx/iced
 public OpCodeHandler_MandatoryPrefix_MaybeModRM(OpCodeHandler handler, OpCodeHandler handler66, OpCodeHandler handlerF3, OpCodeHandler handlerF2)
 {
     Debug.Assert((int)MandatoryPrefix.None == 0);
     Debug.Assert((int)MandatoryPrefix.P66 == 1);
     Debug.Assert((int)MandatoryPrefix.PF3 == 2);
     Debug.Assert((int)MandatoryPrefix.PF2 == 3);
     handlers = new OpCodeHandler[4] {
         handler ?? throw new ArgumentNullException(nameof(handler)),
               handler66 ?? throw new ArgumentNullException(nameof(handler66)),
                     handlerF3 ?? throw new ArgumentNullException(nameof(handlerF3)),
                           handlerF2 ?? throw new ArgumentNullException(nameof(handlerF2)),
     };
 }
コード例 #8
0
ファイル: OpCodeHandlers.cs プロジェクト: xoofx/iced
 public OpCodeHandler_VectorLength_NoModRM_VEX(OpCodeHandler handler128, OpCodeHandler handler256)
 {
     Debug.Assert((int)VectorLength.L128 == 0);
     Debug.Assert((int)VectorLength.L256 == 1);
     Debug.Assert((int)VectorLength.L512 == 2);
     Debug.Assert((int)VectorLength.Unknown == 3);
     handlers = new OpCodeHandler[4] {
         handler128 ?? throw new ArgumentNullException(nameof(handler128)),
               handler256 ?? throw new ArgumentNullException(nameof(handler256)),
                     OpCodeHandler_Invalid.Instance,
                     OpCodeHandler_Invalid.Instance,
     };
     Debug.Assert(handler128.HasModRM == HasModRM);
     Debug.Assert(handler256.HasModRM == HasModRM);
 }
コード例 #9
0
 public OpCodeHandler_MandatoryPrefix2_NoModRM(OpCodeHandler handler, OpCodeHandler handler66, OpCodeHandler handlerF3, OpCodeHandler handlerF2)
 {
     Static.Assert((int)MandatoryPrefixByte.None == 0 ? 0 : -1);
     Static.Assert((int)MandatoryPrefixByte.P66 == 1 ? 0 : -1);
     Static.Assert((int)MandatoryPrefixByte.PF3 == 2 ? 0 : -1);
     Static.Assert((int)MandatoryPrefixByte.PF2 == 3 ? 0 : -1);
     handlers = new OpCodeHandler[4] {
         handler ?? throw new ArgumentNullException(nameof(handler)),
               handler66 ?? throw new ArgumentNullException(nameof(handler66)),
                     handlerF3 ?? throw new ArgumentNullException(nameof(handlerF3)),
                           handlerF2 ?? throw new ArgumentNullException(nameof(handlerF2)),
     };
     Debug.Assert(handler.HasModRM == HasModRM);
     Debug.Assert(handler66.HasModRM == HasModRM);
     Debug.Assert(handlerF3.HasModRM == HasModRM);
     Debug.Assert(handlerF2.HasModRM == HasModRM);
 }
コード例 #10
0
        static OpCodeHandler W0L(OpCodeHandler handler128, OpCodeHandler handler256)
        {
            var invalid = OpCodeHandler_Invalid.Instance;

            return(new OpCodeHandler_MandatoryPrefix2(
                       new OpCodeHandler_VectorLength_VEX(
                           new OpCodeHandler_W(
                               handler128,
                               invalid
                               ),
                           new OpCodeHandler_W(
                               handler256,
                               invalid
                               )
                           )
                       ));
        }
コード例 #11
0
ファイル: OpCodeHandlers.cs プロジェクト: weiling103/iced
 public Info(OpCodeHandler handler, bool mandatoryPrefix)
 {
     this.handler         = handler;
     this.mandatoryPrefix = mandatoryPrefix;
 }
コード例 #12
0
ファイル: OpCodeHandlers.cs プロジェクト: weiling103/iced
 public OpCodeHandler_MandatoryPrefix_F3_F2(OpCodeHandler handlerNormal, OpCodeHandler handlerF3, OpCodeHandler handlerF2)
 {
     this.handlerNormal = handlerNormal ?? throw new ArgumentNullException(nameof(handlerNormal));
     this.handlerF3     = handlerF3 ?? throw new ArgumentNullException(nameof(handlerF3));
     this.handlerF2     = handlerF2 ?? throw new ArgumentNullException(nameof(handlerF2));
 }
コード例 #13
0
 public HandlerOptions(OpCodeHandler handler, DecoderOptions options)
 {
     this.handler = handler;
     this.options = options;
 }
コード例 #14
0
 public OpCodeHandler_RM(OpCodeHandler reg, OpCodeHandler mem)
 {
     this.reg = reg ?? throw new ArgumentNullException(nameof(reg));
     this.mem = mem ?? throw new ArgumentNullException(nameof(mem));
 }
コード例 #15
0
 public OpCodeHandler_Bitness_DontReadModRM(OpCodeHandler handler1632, OpCodeHandler handler64)
 {
     this.handler1632 = handler1632;
     this.handler64   = handler64;
 }
コード例 #16
0
 public OpCodeHandler_Bitness(OpCodeHandler handler1632, OpCodeHandler handler64)
 {
     this.handler1632 = handler1632;
     this.handler64   = handler64;
 }
コード例 #17
0
 static OpCodeHandler W(OpCodeHandler handlerW0, OpCodeHandler handlerW1) =>
 new OpCodeHandler_MandatoryPrefix2(new OpCodeHandler_W(handlerW0, handlerW1));
コード例 #18
0
 public OpCodeHandler_MandatoryPrefix2(OpCodeHandler handler)
     : this(handler, OpCodeHandler_Invalid.Instance, OpCodeHandler_Invalid.Instance, OpCodeHandler_Invalid.Instance)
 {
 }
コード例 #19
0
 static OpCodeHandler W0L0(OpCodeHandler handler) => W0L(handler, OpCodeHandler_Invalid.Instance);
コード例 #20
0
        static OpCodeHandlers32Tables_XOP()
        {
            OpCodeHandler[] tbl;
            var             invalid = OpCodeHandler_Invalid.Instance;

            tbl = new OpCodeHandler[0x100];
            for (int i = 0; i < tbl.Length; i++)
            {
                tbl[i] = invalid;
            }
            tbl[0x85] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacssww_xmm_xmm_xmmm128_xmm));
            tbl[0x86] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacsswd_xmm_xmm_xmmm128_xmm));
            tbl[0x87] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacssdql_xmm_xmm_xmmm128_xmm));
            tbl[0x8E] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacssdd_xmm_xmm_xmmm128_xmm));
            tbl[0x8F] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacssdqh_xmm_xmm_xmmm128_xmm));
            tbl[0x95] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacsww_xmm_xmm_xmmm128_xmm));
            tbl[0x96] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacswd_xmm_xmm_xmmm128_xmm));
            tbl[0x97] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacsdql_xmm_xmm_xmmm128_xmm));
            tbl[0x9E] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacsdd_xmm_xmm_xmmm128_xmm));
            tbl[0x9F] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmacsdqh_xmm_xmm_xmmm128_xmm));
            tbl[0xA2] = W(
                new OpCodeHandler_VectorLength_VEX(
                    new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpcmov_xmm_xmm_xmmm128_xmm),
                    new OpCodeHandler_VEX_VHWIs4(Register.YMM0, Code.XOP_Vpcmov_ymm_ymm_ymmm256_ymm)
                    ),
                new OpCodeHandler_VectorLength_VEX(
                    new OpCodeHandler_VEX_VHIs4W(Register.XMM0, Code.XOP_Vpcmov_xmm_xmm_xmm_xmmm128),
                    new OpCodeHandler_VEX_VHIs4W(Register.YMM0, Code.XOP_Vpcmov_ymm_ymm_ymm_ymmm256)
                    )
                );
            tbl[0xA3] = W(
                new OpCodeHandler_VectorLength_VEX(
                    new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpperm_xmm_xmm_xmmm128_xmm),
                    invalid
                    ),
                new OpCodeHandler_VectorLength_VEX(
                    new OpCodeHandler_VEX_VHIs4W(Register.XMM0, Code.XOP_Vpperm_xmm_xmm_xmm_xmmm128),
                    invalid
                    )
                );
            tbl[0xA6] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmadcsswd_xmm_xmm_xmmm128_xmm));
            tbl[0xB6] = W0L0(new OpCodeHandler_VEX_VHWIs4(Register.XMM0, Code.XOP_Vpmadcswd_xmm_xmm_xmmm128_xmm));
            tbl[0xC0] = W0L0(new OpCodeHandler_VEX_VWIb(Register.XMM0, Code.XOP_Vprotb_xmm_xmmm128_imm8));
            tbl[0xC1] = W0L0(new OpCodeHandler_VEX_VWIb(Register.XMM0, Code.XOP_Vprotw_xmm_xmmm128_imm8));
            tbl[0xC2] = W0L0(new OpCodeHandler_VEX_VWIb(Register.XMM0, Code.XOP_Vprotd_xmm_xmmm128_imm8));
            tbl[0xC3] = W0L0(new OpCodeHandler_VEX_VWIb(Register.XMM0, Code.XOP_Vprotq_xmm_xmmm128_imm8));
            tbl[0xCC] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomb_xmm_xmm_xmmm128_imm8));
            tbl[0xCD] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomw_xmm_xmm_xmmm128_imm8));
            tbl[0xCE] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomd_xmm_xmm_xmmm128_imm8));
            tbl[0xCF] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomq_xmm_xmm_xmmm128_imm8));
            tbl[0xEC] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomub_xmm_xmm_xmmm128_imm8));
            tbl[0xED] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomuw_xmm_xmm_xmmm128_imm8));
            tbl[0xEE] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomud_xmm_xmm_xmmm128_imm8));
            tbl[0xEF] = W0L0(new OpCodeHandler_VEX_VHWIb(Register.XMM0, Code.XOP_Vpcomuq_xmm_xmm_xmmm128_imm8));
            XOP8      = tbl;

            tbl = new OpCodeHandler[0x100];
            for (int i = 0; i < tbl.Length; i++)
            {
                tbl[i] = invalid;
            }
            var grp_XOP9_01 = new OpCodeHandler[8] {
                invalid,
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blcfill_r32_rm32, Code.XOP_Blcfill_r64_rm64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blsfill_r32_rm32, Code.XOP_Blsfill_r64_rm64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blcs_r32_rm32, Code.XOP_Blcs_r64_rm64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Tzmsk_r32_rm32, Code.XOP_Tzmsk_r64_rm64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blcic_r32_rm32, Code.XOP_Blcic_r64_rm64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blsic_r32_rm32, Code.XOP_Blsic_r64_rm64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_T1mskc_r32_rm32, Code.XOP_T1mskc_r64_rm64),
                        invalid
                        )
                    ),
            };

            tbl[0x01] = new OpCodeHandler_Group(grp_XOP9_01);
            var grp_XOP9_02 = new OpCodeHandler[8] {
                invalid,
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blcmsk_r32_rm32, Code.XOP_Blcmsk_r64_rm64),
                        invalid
                        )
                    ),
                invalid,
                invalid,
                invalid,
                invalid,
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ev(Code.XOP_Blci_r32_rm32, Code.XOP_Blci_r64_rm64),
                        invalid
                        )
                    ),
                invalid,
            };

            tbl[0x02] = new OpCodeHandler_Group(grp_XOP9_02);
            var grp_XOP9_12 = new OpCodeHandler[8] {
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_RdRq(Code.XOP_Llwpcb_r32, Code.XOP_Llwpcb_r64),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_RdRq(Code.XOP_Slwpcb_r32, Code.XOP_Slwpcb_r64),
                        invalid
                        )
                    ),
                invalid,
                invalid,
                invalid,
                invalid,
                invalid,
                invalid,
            };

            tbl[0x12] = new OpCodeHandler_Group(grp_XOP9_12);
            tbl[0x80] = W0L(
                new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vfrczps_xmm_xmmm128),
                new OpCodeHandler_VEX_VW(Register.YMM0, Code.XOP_Vfrczps_ymm_ymmm256)
                );
            tbl[0x81] = W0L(
                new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vfrczpd_xmm_xmmm128),
                new OpCodeHandler_VEX_VW(Register.YMM0, Code.XOP_Vfrczpd_ymm_ymmm256)
                );
            tbl[0x82] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vfrczss_xmm_xmmm32));
            tbl[0x83] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vfrczsd_xmm_xmmm64));
            tbl[0x90] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vprotb_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vprotb_xmm_xmm_xmmm128)
                );
            tbl[0x91] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vprotw_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vprotw_xmm_xmm_xmmm128)
                );
            tbl[0x92] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vprotd_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vprotd_xmm_xmm_xmmm128)
                );
            tbl[0x93] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vprotq_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vprotq_xmm_xmm_xmmm128)
                );
            tbl[0x94] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshlb_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshlb_xmm_xmm_xmmm128)
                );
            tbl[0x95] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshlw_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshlw_xmm_xmm_xmmm128)
                );
            tbl[0x96] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshld_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshld_xmm_xmm_xmmm128)
                );
            tbl[0x97] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshlq_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshlq_xmm_xmm_xmmm128)
                );
            tbl[0x98] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshab_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshab_xmm_xmm_xmmm128)
                );
            tbl[0x99] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshaw_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshaw_xmm_xmm_xmmm128)
                );
            tbl[0x9A] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshad_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshad_xmm_xmm_xmmm128)
                );
            tbl[0x9B] = WL0(
                new OpCodeHandler_VEX_VWH(Register.XMM0, Code.XOP_Vpshaq_xmm_xmmm128_xmm),
                new OpCodeHandler_VEX_VHW(Register.XMM0, Code.XOP_Vpshaq_xmm_xmm_xmmm128)
                );
            tbl[0xC1] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddbw_xmm_xmmm128));
            tbl[0xC2] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddbd_xmm_xmmm128));
            tbl[0xC3] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddbq_xmm_xmmm128));
            tbl[0xC6] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddwd_xmm_xmmm128));
            tbl[0xC7] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddwq_xmm_xmmm128));
            tbl[0xCB] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphadddq_xmm_xmmm128));
            tbl[0xD1] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddubw_xmm_xmmm128));
            tbl[0xD2] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddubd_xmm_xmmm128));
            tbl[0xD3] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddubq_xmm_xmmm128));
            tbl[0xD6] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphadduwd_xmm_xmmm128));
            tbl[0xD7] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphadduwq_xmm_xmmm128));
            tbl[0xDB] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphaddudq_xmm_xmmm128));
            tbl[0xE1] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphsubbw_xmm_xmmm128));
            tbl[0xE2] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphsubwd_xmm_xmmm128));
            tbl[0xE3] = W0L0(new OpCodeHandler_VEX_VW(Register.XMM0, Code.XOP_Vphsubdq_xmm_xmmm128));
            XOP9      = tbl;

            tbl = new OpCodeHandler[0x100];
            for (int i = 0; i < tbl.Length; i++)
            {
                tbl[i] = invalid;
            }
            tbl[0x10] = new OpCodeHandler_MandatoryPrefix2(
                new OpCodeHandler_VectorLength_VEX(
                    new OpCodeHandler_VEX_Gv_Ev_Id(Code.XOP_Bextr_r32_rm32_imm32, Code.XOP_Bextr_r64_rm64_imm32),
                    invalid
                    )
                );
            var grp_XOPA_12 = new OpCodeHandler[8] {
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ed_Id(Code.XOP_Lwpins_r32_rm32_imm32, Code.XOP_Lwpins_r64_rm32_imm32),
                        invalid
                        )
                    ),
                new OpCodeHandler_MandatoryPrefix2(
                    new OpCodeHandler_VectorLength_VEX(
                        new OpCodeHandler_VEX_Hv_Ed_Id(Code.XOP_Lwpval_r32_rm32_imm32, Code.XOP_Lwpval_r64_rm32_imm32),
                        invalid
                        )
                    ),
                invalid,
                invalid,
                invalid,
                invalid,
                invalid,
                invalid,
            };

            tbl[0x12] = new OpCodeHandler_Group(grp_XOPA_12);
            XOPA      = tbl;
        }