1 // RUN: not llvm-mc -triple x86_64-unknown-unknown --show-encoding %s 2> %t.err | FileCheck --check-prefix=64 %s
2 // RUN: FileCheck --check-prefix=ERR64 < %t.err %s
3 // RUN: not llvm-mc -triple i386-unknown-unknown --show-encoding %s 2> %t.err | FileCheck --check-prefix=32 %s
4 // RUN: FileCheck --check-prefix=ERR32 < %t.err %s
5 // RUN: not llvm-mc -triple i386-unknown-unknown-code16 --show-encoding %s 2> %t.err | FileCheck --check-prefix=16 %s
6 // RUN: FileCheck --check-prefix=ERR16 < %t.err %s
10 // 64: encoding: [0xc3]
12 // 32: encoding: [0xc3]
14 // 16: encoding: [0xc3]
17 // 64: encoding: [0x66,0xc3]
19 // 32: encoding: [0x66,0xc3]
21 // 16: encoding: [0xc3]
23 // ERR64: error: instruction requires: Not 64-bit mode
25 // 32: encoding: [0xc3]
27 // 16: encoding: [0x66,0xc3]
30 // 64: encoding: [0xc3]
31 // ERR32: error: instruction requires: 64-bit mode
32 // ERR16: error: instruction requires: 64-bit mode
36 // 64: encoding: [0xc2,0x00,0x00]
38 // 32: encoding: [0xc2,0x00,0x00]
40 // 16: encoding: [0xc2,0x00,0x00]
43 // 64: encoding: [0x66,0xc2,0x00,0x00]
45 // 32: encoding: [0x66,0xc2,0x00,0x00]
47 // 16: encoding: [0xc2,0x00,0x00]
49 // ERR64: error: instruction requires: Not 64-bit mode
51 // 32: encoding: [0xc2,0x00,0x00]
53 // 16: encoding: [0x66,0xc2,0x00,0x00]
56 // 64: encoding: [0xc2,0x00,0x00]
57 // ERR32: error: instruction requires: 64-bit mode
58 // ERR16: error: instruction requires: 64-bit mode
62 // 64: encoding: [0xcb]
64 // 32: encoding: [0xcb]
66 // 16: encoding: [0xcb]
69 // 64: encoding: [0x66,0xcb]
71 // 32: encoding: [0x66,0xcb]
73 // 16: encoding: [0xcb]
76 // 64: encoding: [0xcb]
78 // 32: encoding: [0xcb]
80 // 16: encoding: [0x66,0xcb]
83 // 64: encoding: [0x48,0xcb]
84 // ERR32: error: instruction requires: 64-bit mode
85 // ERR16: error: instruction requires: 64-bit mode
89 // 64: encoding: [0xca,0x00,0x00]
91 // 32: encoding: [0xca,0x00,0x00]
93 // 16: encoding: [0xca,0x00,0x00]
96 // 64: encoding: [0x66,0xca,0x00,0x00]
98 // 32: encoding: [0x66,0xca,0x00,0x00]
100 // 16: encoding: [0xca,0x00,0x00]
103 // 64: encoding: [0xca,0x00,0x00]
105 // 32: encoding: [0xca,0x00,0x00]
107 // 16: encoding: [0x66,0xca,0x00,0x00]
110 // 64: encoding: [0x48,0xca,0x00,0x00]
111 // ERR32: error: instruction requires: 64-bit mode
112 // ERR16: error: instruction requires: 64-bit mode