# RUN: llvm-mc -triple x86_64 -disassemble %s | FileCheck %s --check-prefix=ATT
# RUN: llvm-mc -triple x86_64 -disassemble -output-asm-variant=1 %s | FileCheck %s --check-prefix=INTEL
# ATT: {evex} rcrb $123, %bl
# INTEL: {evex} rcr bl, 123
0x62,0xf4,0x7c,0x08,0xc0,0xdb,0x7b
# ATT: rcrb $123, %bl, %bl
# INTEL: rcr bl, bl, 123
0x62,0xf4,0x64,0x18,0xc0,0xdb,0x7b
# ATT: {evex} rcrw $123, %dx
# INTEL: {evex} rcr dx, 123
0x62,0xf4,0x7d,0x08,0xc1,0xda,0x7b
# ATT: rcrw $123, %dx, %dx
# INTEL: rcr dx, dx, 123
0x62,0xf4,0x6d,0x18,0xc1,0xda,0x7b
# ATT: {evex} rcrl $123, %ecx
# INTEL: {evex} rcr ecx, 123
0x62,0xf4,0x7c,0x08,0xc1,0xd9,0x7b
# ATT: rcrl $123, %ecx, %ecx
# INTEL: rcr ecx, ecx, 123
0x62,0xf4,0x74,0x18,0xc1,0xd9,0x7b
# ATT: {evex} rcrq $123, %r9
# INTEL: {evex} rcr r9, 123
0x62,0xd4,0xfc,0x08,0xc1,0xd9,0x7b
# ATT: rcrq $123, %r9, %r9
# INTEL: rcr r9, r9, 123
0x62,0xd4,0xb4,0x18,0xc1,0xd9,0x7b
# ATT: {evex} rcrb $123, 291(%r8,%rax,4)
# INTEL: {evex} rcr byte ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0x7c,0x08,0xc0,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: rcrb $123, 291(%r8,%rax,4), %bl
# INTEL: rcr bl, byte ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0x64,0x18,0xc0,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: {evex} rcrw $123, 291(%r8,%rax,4)
# INTEL: {evex} rcr word ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0x7d,0x08,0xc1,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: rcrw $123, 291(%r8,%rax,4), %dx
# INTEL: rcr dx, word ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0x6d,0x18,0xc1,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: {evex} rcrl $123, 291(%r8,%rax,4)
# INTEL: {evex} rcr dword ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0x7c,0x08,0xc1,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: rcrl $123, 291(%r8,%rax,4), %ecx
# INTEL: rcr ecx, dword ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0x74,0x18,0xc1,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: {evex} rcrq $123, 291(%r8,%rax,4)
# INTEL: {evex} rcr qword ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0xfc,0x08,0xc1,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: rcrq $123, 291(%r8,%rax,4), %r9
# INTEL: rcr r9, qword ptr [r8 + 4*rax + 291], 123
0x62,0xd4,0xb4,0x18,0xc1,0x9c,0x80,0x23,0x01,0x00,0x00,0x7b
# ATT: {evex} rcrb %bl
# INTEL: {evex} rcr bl
0x62,0xf4,0x7c,0x08,0xd0,0xdb
# ATT: rcrb %bl, %bl
# INTEL: rcr bl, bl
0x62,0xf4,0x64,0x18,0xd0,0xdb
# ATT: {evex} rcrb %cl, %bl
# INTEL: {evex} rcr bl, cl
0x62,0xf4,0x7c,0x08,0xd2,0xdb
# ATT: rcrb %cl, %bl, %bl
# INTEL: rcr bl, bl, cl
0x62,0xf4,0x64,0x18,0xd2,0xdb
# ATT: {evex} rcrw %cl, %dx
# INTEL: {evex} rcr dx, cl
0x62,0xf4,0x7d,0x08,0xd3,0xda
# ATT: rcrw %cl, %dx, %dx
# INTEL: rcr dx, dx, cl
0x62,0xf4,0x6d,0x18,0xd3,0xda
# ATT: {evex} rcrl %cl, %ecx
# INTEL: {evex} rcr ecx, cl
0x62,0xf4,0x7c,0x08,0xd3,0xd9
# ATT: rcrl %cl, %ecx, %ecx
# INTEL: rcr ecx, ecx, cl
0x62,0xf4,0x74,0x18,0xd3,0xd9
# ATT: {evex} rcrq %cl, %r9
# INTEL: {evex} rcr r9, cl
0x62,0xd4,0xfc,0x08,0xd3,0xd9
# ATT: rcrq %cl, %r9, %r9
# INTEL: rcr r9, r9, cl
0x62,0xd4,0xb4,0x18,0xd3,0xd9
# ATT: {evex} rcrb %cl, 291(%r8,%rax,4)
# INTEL: {evex} rcr byte ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0x7c,0x08,0xd2,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrb %cl, 291(%r8,%rax,4), %bl
# INTEL: rcr bl, byte ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0x64,0x18,0xd2,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrw %cl, 291(%r8,%rax,4)
# INTEL: {evex} rcr word ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0x7d,0x08,0xd3,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrw %cl, 291(%r8,%rax,4), %dx
# INTEL: rcr dx, word ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0x6d,0x18,0xd3,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrl %cl, 291(%r8,%rax,4)
# INTEL: {evex} rcr dword ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0x7c,0x08,0xd3,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrl %cl, 291(%r8,%rax,4), %ecx
# INTEL: rcr ecx, dword ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0x74,0x18,0xd3,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrq %cl, 291(%r8,%rax,4)
# INTEL: {evex} rcr qword ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0xfc,0x08,0xd3,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrq %cl, 291(%r8,%rax,4), %r9
# INTEL: rcr r9, qword ptr [r8 + 4*rax + 291], cl
0x62,0xd4,0xb4,0x18,0xd3,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrw %dx
# INTEL: {evex} rcr dx
0x62,0xf4,0x7d,0x08,0xd1,0xda
# ATT: rcrw %dx, %dx
# INTEL: rcr dx, dx
0x62,0xf4,0x6d,0x18,0xd1,0xda
# ATT: {evex} rcrl %ecx
# INTEL: {evex} rcr ecx
0x62,0xf4,0x7c,0x08,0xd1,0xd9
# ATT: rcrl %ecx, %ecx
# INTEL: rcr ecx, ecx
0x62,0xf4,0x74,0x18,0xd1,0xd9
# ATT: {evex} rcrq %r9
# INTEL: {evex} rcr r9
0x62,0xd4,0xfc,0x08,0xd1,0xd9
# ATT: rcrq %r9, %r9
# INTEL: rcr r9, r9
0x62,0xd4,0xb4,0x18,0xd1,0xd9
# ATT: {evex} rcrb 291(%r8,%rax,4)
# INTEL: {evex} rcr byte ptr [r8 + 4*rax + 291]
0x62,0xd4,0x7c,0x08,0xd0,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrb 291(%r8,%rax,4), %bl
# INTEL: rcr bl, byte ptr [r8 + 4*rax + 291]
0x62,0xd4,0x64,0x18,0xd0,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrw 291(%r8,%rax,4)
# INTEL: {evex} rcr word ptr [r8 + 4*rax + 291]
0x62,0xd4,0x7d,0x08,0xd1,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrw 291(%r8,%rax,4), %dx
# INTEL: rcr dx, word ptr [r8 + 4*rax + 291]
0x62,0xd4,0x6d,0x18,0xd1,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrl 291(%r8,%rax,4)
# INTEL: {evex} rcr dword ptr [r8 + 4*rax + 291]
0x62,0xd4,0x7c,0x08,0xd1,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrl 291(%r8,%rax,4), %ecx
# INTEL: rcr ecx, dword ptr [r8 + 4*rax + 291]
0x62,0xd4,0x74,0x18,0xd1,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: {evex} rcrq 291(%r8,%rax,4)
# INTEL: {evex} rcr qword ptr [r8 + 4*rax + 291]
0x62,0xd4,0xfc,0x08,0xd1,0x9c,0x80,0x23,0x01,0x00,0x00
# ATT: rcrq 291(%r8,%rax,4), %r9
# INTEL: rcr r9, qword ptr [r8 + 4*rax + 291]
0x62,0xd4,0xb4,0x18,0xd1,0x9c,0x80,0x23,0x01,0x00,0x00