# RUN: llvm-mc -triple x86_64 -show-encoding %s | FileCheck %s
# RUN: not llvm-mc -triple i386 -show-encoding %s 2>&1 | FileCheck %s --check-prefix=ERROR

# ERROR-COUNT-96: error:
# ERROR-NOT: error:
# CHECK: cmovbw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x42,0xc2]
         cmovbw	%dx, %ax, %r9w
# CHECK: cmovbl	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x42,0xd1]
         cmovbl	%ecx, %edx, %r10d
# CHECK: cmovbq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x42,0xf9]
         cmovbq	%r9, %r15, %r11
# CHECK: cmovbw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x42,0x54,0x80,0x7b]
         cmovbw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovbl	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x42,0x4c,0x80,0x7b]
         cmovbl	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovbq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x42,0x4c,0x80,0x7b]
         cmovbq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovbew	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x46,0xc2]
         cmovbew	%dx, %ax, %r9w
# CHECK: cmovbel	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x46,0xd1]
         cmovbel	%ecx, %edx, %r10d
# CHECK: cmovbeq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x46,0xf9]
         cmovbeq	%r9, %r15, %r11
# CHECK: cmovbew	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x46,0x54,0x80,0x7b]
         cmovbew	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovbel	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x46,0x4c,0x80,0x7b]
         cmovbel	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovbeq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x46,0x4c,0x80,0x7b]
         cmovbeq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovlw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x4c,0xc2]
         cmovlw	%dx, %ax, %r9w
# CHECK: cmovll	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x4c,0xd1]
         cmovll	%ecx, %edx, %r10d
# CHECK: cmovlq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x4c,0xf9]
         cmovlq	%r9, %r15, %r11
# CHECK: cmovlw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x4c,0x54,0x80,0x7b]
         cmovlw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovll	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x4c,0x4c,0x80,0x7b]
         cmovll	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovlq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x4c,0x4c,0x80,0x7b]
         cmovlq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovlew	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x4e,0xc2]
         cmovlew	%dx, %ax, %r9w
# CHECK: cmovlel	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x4e,0xd1]
         cmovlel	%ecx, %edx, %r10d
# CHECK: cmovleq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x4e,0xf9]
         cmovleq	%r9, %r15, %r11
# CHECK: cmovlew	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x4e,0x54,0x80,0x7b]
         cmovlew	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovlel	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x4e,0x4c,0x80,0x7b]
         cmovlel	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovleq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x4e,0x4c,0x80,0x7b]
         cmovleq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovaew	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x43,0xc2]
         cmovaew	%dx, %ax, %r9w
# CHECK: cmovael	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x43,0xd1]
         cmovael	%ecx, %edx, %r10d
# CHECK: cmovaeq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x43,0xf9]
         cmovaeq	%r9, %r15, %r11
# CHECK: cmovaew	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x43,0x54,0x80,0x7b]
         cmovaew	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovael	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x43,0x4c,0x80,0x7b]
         cmovael	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovaeq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x43,0x4c,0x80,0x7b]
         cmovaeq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovaw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x47,0xc2]
         cmovaw	%dx, %ax, %r9w
# CHECK: cmoval	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x47,0xd1]
         cmoval	%ecx, %edx, %r10d
# CHECK: cmovaq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x47,0xf9]
         cmovaq	%r9, %r15, %r11
# CHECK: cmovaw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x47,0x54,0x80,0x7b]
         cmovaw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmoval	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x47,0x4c,0x80,0x7b]
         cmoval	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovaq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x47,0x4c,0x80,0x7b]
         cmovaq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovgew	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x4d,0xc2]
         cmovgew	%dx, %ax, %r9w
# CHECK: cmovgel	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x4d,0xd1]
         cmovgel	%ecx, %edx, %r10d
# CHECK: cmovgeq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x4d,0xf9]
         cmovgeq	%r9, %r15, %r11
# CHECK: cmovgew	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x4d,0x54,0x80,0x7b]
         cmovgew	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovgel	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x4d,0x4c,0x80,0x7b]
         cmovgel	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovgeq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x4d,0x4c,0x80,0x7b]
         cmovgeq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovgw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x4f,0xc2]
         cmovgw	%dx, %ax, %r9w
# CHECK: cmovgl	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x4f,0xd1]
         cmovgl	%ecx, %edx, %r10d
# CHECK: cmovgq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x4f,0xf9]
         cmovgq	%r9, %r15, %r11
# CHECK: cmovgw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x4f,0x54,0x80,0x7b]
         cmovgw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovgl	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x4f,0x4c,0x80,0x7b]
         cmovgl	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovgq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x4f,0x4c,0x80,0x7b]
         cmovgq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovnow	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x41,0xc2]
         cmovnow	%dx, %ax, %r9w
# CHECK: cmovnol	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x41,0xd1]
         cmovnol	%ecx, %edx, %r10d
# CHECK: cmovnoq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x41,0xf9]
         cmovnoq	%r9, %r15, %r11
# CHECK: cmovnow	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x41,0x54,0x80,0x7b]
         cmovnow	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovnol	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x41,0x4c,0x80,0x7b]
         cmovnol	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovnoq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x41,0x4c,0x80,0x7b]
         cmovnoq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovnpw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x4b,0xc2]
         cmovnpw	%dx, %ax, %r9w
# CHECK: cmovnpl	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x4b,0xd1]
         cmovnpl	%ecx, %edx, %r10d
# CHECK: cmovnpq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x4b,0xf9]
         cmovnpq	%r9, %r15, %r11
# CHECK: cmovnpw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x4b,0x54,0x80,0x7b]
         cmovnpw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovnpl	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x4b,0x4c,0x80,0x7b]
         cmovnpl	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovnpq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x4b,0x4c,0x80,0x7b]
         cmovnpq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovnsw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x49,0xc2]
         cmovnsw	%dx, %ax, %r9w
# CHECK: cmovnsl	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x49,0xd1]
         cmovnsl	%ecx, %edx, %r10d
# CHECK: cmovnsq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x49,0xf9]
         cmovnsq	%r9, %r15, %r11
# CHECK: cmovnsw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x49,0x54,0x80,0x7b]
         cmovnsw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovnsl	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x49,0x4c,0x80,0x7b]
         cmovnsl	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovnsq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x49,0x4c,0x80,0x7b]
         cmovnsq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovnew	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x45,0xc2]
         cmovnew	%dx, %ax, %r9w
# CHECK: cmovnel	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x45,0xd1]
         cmovnel	%ecx, %edx, %r10d
# CHECK: cmovneq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x45,0xf9]
         cmovneq	%r9, %r15, %r11
# CHECK: cmovnew	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x45,0x54,0x80,0x7b]
         cmovnew	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovnel	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x45,0x4c,0x80,0x7b]
         cmovnel	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovneq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x45,0x4c,0x80,0x7b]
         cmovneq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovow	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x40,0xc2]
         cmovow	%dx, %ax, %r9w
# CHECK: cmovol	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x40,0xd1]
         cmovol	%ecx, %edx, %r10d
# CHECK: cmovoq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x40,0xf9]
         cmovoq	%r9, %r15, %r11
# CHECK: cmovow	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x40,0x54,0x80,0x7b]
         cmovow	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovol	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x40,0x4c,0x80,0x7b]
         cmovol	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovoq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x40,0x4c,0x80,0x7b]
         cmovoq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovpw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x4a,0xc2]
         cmovpw	%dx, %ax, %r9w
# CHECK: cmovpl	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x4a,0xd1]
         cmovpl	%ecx, %edx, %r10d
# CHECK: cmovpq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x4a,0xf9]
         cmovpq	%r9, %r15, %r11
# CHECK: cmovpw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x4a,0x54,0x80,0x7b]
         cmovpw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovpl	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x4a,0x4c,0x80,0x7b]
         cmovpl	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovpq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x4a,0x4c,0x80,0x7b]
         cmovpq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovsw	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x48,0xc2]
         cmovsw	%dx, %ax, %r9w
# CHECK: cmovsl	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x48,0xd1]
         cmovsl	%ecx, %edx, %r10d
# CHECK: cmovsq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x48,0xf9]
         cmovsq	%r9, %r15, %r11
# CHECK: cmovsw	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x48,0x54,0x80,0x7b]
         cmovsw	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovsl	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x48,0x4c,0x80,0x7b]
         cmovsl	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmovsq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x48,0x4c,0x80,0x7b]
         cmovsq	123(%r8,%rax,4), %r9, %r15
# CHECK: cmovew	%dx, %ax, %r9w
# CHECK: encoding: [0x62,0xf4,0x35,0x18,0x44,0xc2]
         cmovew	%dx, %ax, %r9w
# CHECK: cmovel	%ecx, %edx, %r10d
# CHECK: encoding: [0x62,0xf4,0x2c,0x18,0x44,0xd1]
         cmovel	%ecx, %edx, %r10d
# CHECK: cmoveq	%r9, %r15, %r11
# CHECK: encoding: [0x62,0x54,0xa4,0x18,0x44,0xf9]
         cmoveq	%r9, %r15, %r11
# CHECK: cmovew	123(%r8,%rax,4), %dx, %ax
# CHECK: encoding: [0x62,0xd4,0x7d,0x18,0x44,0x54,0x80,0x7b]
         cmovew	123(%r8,%rax,4), %dx, %ax
# CHECK: cmovel	123(%r8,%rax,4), %ecx, %edx
# CHECK: encoding: [0x62,0xd4,0x6c,0x18,0x44,0x4c,0x80,0x7b]
         cmovel	123(%r8,%rax,4), %ecx, %edx
# CHECK: cmoveq	123(%r8,%rax,4), %r9, %r15
# CHECK: encoding: [0x62,0x54,0x84,0x18,0x44,0x4c,0x80,0x7b]
         cmoveq	123(%r8,%rax,4), %r9, %r15
