// File: /workspace/github_c_makefile_star2_O0/buptlxb[P]xRay/disasm/instr_set/opcodes_Grp9.c
// Function: G9_
void __bea_callspec__ G9_(PDISASM pMyDisasm)
{
    GV.REGOPCODE = ((*((UInt8*)(UIntPtr) (GV.EIP_+1))) >> 3) & 0x7;
    GV.MemDecoration = Arg2qword;
    MOD_RM(&(*pMyDisasm).Argument2, pMyDisasm);
    if (GV.REGOPCODE == 1) {
        if (GV.REX.W_ == 1) {
            GV.MemDecoration = Arg2dqword;
            (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+DATA_TRANSFER;
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "cmpxchg16b ");
            #endif
            (*pMyDisasm).Argument1.ArgType = REGISTER_TYPE+GENERAL_REG+REG0+REG2;
            (*pMyDisasm).Argument1.ArgSize = 128;
            (*pMyDisasm).Argument1.AccessMode = READ;
            FillFlags(pMyDisasm, 23);
            GV.EIP_ += GV.DECALAGE_EIP+2;
        }
        else {
            (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+DATA_TRANSFER;
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "cmpxchg8b ");
            #endif
            (*pMyDisasm).Argument1.ArgType = REGISTER_TYPE+GENERAL_REG+REG0+REG2;
            (*pMyDisasm).Argument1.ArgSize = 64;
            (*pMyDisasm).Argument1.AccessMode = READ;
            FillFlags(pMyDisasm, 23);
            GV.EIP_ += GV.DECALAGE_EIP+2;
        }
    }
    else if (GV.REGOPCODE == 6) {
        (*pMyDisasm).Instruction.Category = VM_INSTRUCTION;
        if (GV.OperandSize == 16) {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "vmclear ");
            #endif
        }
        else if (GV.PrefRepe == 1) {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "vmxon ");
            #endif
        }
        else {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "vmptrld ");
            #endif
        }
        GV.EIP_ += GV.DECALAGE_EIP+2;

    }
    else if (GV.REGOPCODE == 7) {
        (*pMyDisasm).Instruction.Category = VM_INSTRUCTION;
        #ifndef BEA_LIGHT_DISASSEMBLY
           (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "vmptrst ");
        #endif
        GV.EIP_ += GV.DECALAGE_EIP+2;
    }
    else {
        FailDecode(pMyDisasm);
    }

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x1f0(%rax), %rax
movzbl 0x1(%rax), %ecx
sarl $0x3, %ecx
andl $0x7, %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x240(%rax)
movq -0x8(%rbp), %rax
movl $0x68, 0x210(%rax)
movq -0x8(%rbp), %rdi
addq $0x104, %rdi            # imm = 0x104
movq -0x8(%rbp), %rsi
callq 0x4dbc0
movq -0x8(%rbp), %rax
cmpl $0x1, 0x240(%rax)
jne 0x3d1e3
movq -0x8(%rbp), %rax
movzbl 0x284(%rax), %eax
cmpl $0x1, %eax
jne 0x3d160
movq -0x8(%rbp), %rax
movl $0x6c, 0x210(%rax)
movq -0x8(%rbp), %rax
movl $0x10001, 0x60(%rax)    # imm = 0x10001
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x148e0(%rip), %rsi     # 0x519de
callq 0x81c0
movq -0x8(%rbp), %rax
movl $0x20020005, 0xdc(%rax) # imm = 0x20020005
movq -0x8(%rbp), %rax
movl $0x80, 0xe0(%rax)
movq -0x8(%rbp), %rax
movl $0x1, 0xe8(%rax)
movq -0x8(%rbp), %rdi
movl $0x17, %esi
callq 0x4d560
movq -0x8(%rbp), %rax
movl 0x244(%rax), %eax
addl $0x2, %eax
movl %eax, %eax
movl %eax, %ecx
movq -0x8(%rbp), %rax
addq 0x1f0(%rax), %rcx
movq %rcx, 0x1f0(%rax)
jmp 0x3d1de
movq -0x8(%rbp), %rax
movl $0x10001, 0x60(%rax)    # imm = 0x10001
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x1486c(%rip), %rsi     # 0x519ea
callq 0x81c0
movq -0x8(%rbp), %rax
movl $0x20020005, 0xdc(%rax) # imm = 0x20020005
movq -0x8(%rbp), %rax
movl $0x40, 0xe0(%rax)
movq -0x8(%rbp), %rax
movl $0x1, 0xe8(%rax)
movq -0x8(%rbp), %rdi
movl $0x17, %esi
callq 0x4d560
movq -0x8(%rbp), %rax
movl 0x244(%rax), %eax
addl $0x2, %eax
movl %eax, %eax
movl %eax, %ecx
movq -0x8(%rbp), %rax
addq 0x1f0(%rax), %rcx
movq %rcx, 0x1f0(%rax)
jmp 0x3d2ee
movq -0x8(%rbp), %rax
cmpl $0x6, 0x240(%rax)
jne 0x3d28c
movq -0x8(%rbp), %rax
movl $0x4000000, 0x60(%rax)  # imm = 0x4000000
movq -0x8(%rbp), %rax
cmpl $0x10, 0x20c(%rax)
jne 0x3d226
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x147d6(%rip), %rsi     # 0x519f5
callq 0x81c0
jmp 0x3d267
movq -0x8(%rbp), %rax
cmpl $0x1, 0x268(%rax)
jne 0x3d24d
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x147b8(%rip), %rsi     # 0x519fe
callq 0x81c0
jmp 0x3d265
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x147a5(%rip), %rsi     # 0x51a05
callq 0x81c0
jmp 0x3d267
movq -0x8(%rbp), %rax
movl 0x244(%rax), %eax
addl $0x2, %eax
movl %eax, %eax
movl %eax, %ecx
movq -0x8(%rbp), %rax
addq 0x1f0(%rax), %rcx
movq %rcx, 0x1f0(%rax)
jmp 0x3d2ec
movq -0x8(%rbp), %rax
cmpl $0x7, 0x240(%rax)
jne 0x3d2e1
movq -0x8(%rbp), %rax
movl $0x4000000, 0x60(%rax)  # imm = 0x4000000
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x14757(%rip), %rsi     # 0x51a0e
callq 0x81c0
movq -0x8(%rbp), %rax
movl 0x244(%rax), %eax
addl $0x2, %eax
movl %eax, %eax
movl %eax, %ecx
movq -0x8(%rbp), %rax
addq 0x1f0(%rax), %rcx
movq %rcx, 0x1f0(%rax)
jmp 0x3d2ea
movq -0x8(%rbp), %rdi
callq 0x30050
jmp 0x3d2ec
jmp 0x3d2ee
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)