[InstCombine] Signed saturation patterns
[llvm-complete.git] / test / MC / AArch64 / SVE / clastb.s
blob6785edb87ceed8d80dca04fe2288b6f274f0bff0
1 // RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve < %s \
2 // RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST
3 // RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \
4 // RUN: | FileCheck %s --check-prefix=CHECK-ERROR
5 // RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \
6 // RUN: | llvm-objdump -d -mattr=+sve - | FileCheck %s --check-prefix=CHECK-INST
7 // RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \
8 // RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN
10 clastb w0, p7, w0, z31.b
11 // CHECK-INST: clastb w0, p7, w0, z31.b
12 // CHECK-ENCODING: [0xe0,0xbf,0x31,0x05]
13 // CHECK-ERROR: instruction requires: sve
14 // CHECK-UNKNOWN: e0 bf 31 05 <unknown>
16 clastb w0, p7, w0, z31.h
17 // CHECK-INST: clastb w0, p7, w0, z31.h
18 // CHECK-ENCODING: [0xe0,0xbf,0x71,0x05]
19 // CHECK-ERROR: instruction requires: sve
20 // CHECK-UNKNOWN: e0 bf 71 05 <unknown>
22 clastb w0, p7, w0, z31.s
23 // CHECK-INST: clastb w0, p7, w0, z31.s
24 // CHECK-ENCODING: [0xe0,0xbf,0xb1,0x05]
25 // CHECK-ERROR: instruction requires: sve
26 // CHECK-UNKNOWN: e0 bf b1 05 <unknown>
28 clastb x0, p7, x0, z31.d
29 // CHECK-INST: clastb x0, p7, x0, z31.d
30 // CHECK-ENCODING: [0xe0,0xbf,0xf1,0x05]
31 // CHECK-ERROR: instruction requires: sve
32 // CHECK-UNKNOWN: e0 bf f1 05 <unknown>
34 clastb b0, p7, b0, z31.b
35 // CHECK-INST: clastb b0, p7, b0, z31.b
36 // CHECK-ENCODING: [0xe0,0x9f,0x2b,0x05]
37 // CHECK-ERROR: instruction requires: sve
38 // CHECK-UNKNOWN: e0 9f 2b 05 <unknown>
40 clastb h0, p7, h0, z31.h
41 // CHECK-INST: clastb h0, p7, h0, z31.h
42 // CHECK-ENCODING: [0xe0,0x9f,0x6b,0x05]
43 // CHECK-ERROR: instruction requires: sve
44 // CHECK-UNKNOWN: e0 9f 6b 05 <unknown>
46 clastb s0, p7, s0, z31.s
47 // CHECK-INST: clastb s0, p7, s0, z31.s
48 // CHECK-ENCODING: [0xe0,0x9f,0xab,0x05]
49 // CHECK-ERROR: instruction requires: sve
50 // CHECK-UNKNOWN: e0 9f ab 05 <unknown>
52 clastb d0, p7, d0, z31.d
53 // CHECK-INST: clastb d0, p7, d0, z31.d
54 // CHECK-ENCODING: [0xe0,0x9f,0xeb,0x05]
55 // CHECK-ERROR: instruction requires: sve
56 // CHECK-UNKNOWN: e0 9f eb 05 <unknown>
58 clastb z0.b, p7, z0.b, z31.b
59 // CHECK-INST: clastb z0.b, p7, z0.b, z31.b
60 // CHECK-ENCODING: [0xe0,0x9f,0x29,0x05]
61 // CHECK-ERROR: instruction requires: sve
62 // CHECK-UNKNOWN: e0 9f 29 05 <unknown>
64 clastb z0.h, p7, z0.h, z31.h
65 // CHECK-INST: clastb z0.h, p7, z0.h, z31.h
66 // CHECK-ENCODING: [0xe0,0x9f,0x69,0x05]
67 // CHECK-ERROR: instruction requires: sve
68 // CHECK-UNKNOWN: e0 9f 69 05 <unknown>
70 clastb z0.s, p7, z0.s, z31.s
71 // CHECK-INST: clastb z0.s, p7, z0.s, z31.s
72 // CHECK-ENCODING: [0xe0,0x9f,0xa9,0x05]
73 // CHECK-ERROR: instruction requires: sve
74 // CHECK-UNKNOWN: e0 9f a9 05 <unknown>
76 clastb z0.d, p7, z0.d, z31.d
77 // CHECK-INST: clastb z0.d, p7, z0.d, z31.d
78 // CHECK-ENCODING: [0xe0,0x9f,0xe9,0x05]
79 // CHECK-ERROR: instruction requires: sve
80 // CHECK-UNKNOWN: e0 9f e9 05 <unknown>
83 // --------------------------------------------------------------------------//
84 // Test compatibility with MOVPRFX instruction.
86 movprfx z0, z7
87 // CHECK-INST: movprfx z0, z7
88 // CHECK-ENCODING: [0xe0,0xbc,0x20,0x04]
89 // CHECK-ERROR: instruction requires: sve
90 // CHECK-UNKNOWN: e0 bc 20 04 <unknown>
92 clastb z0.d, p7, z0.d, z31.d
93 // CHECK-INST: clastb z0.d, p7, z0.d, z31.d
94 // CHECK-ENCODING: [0xe0,0x9f,0xe9,0x05]
95 // CHECK-ERROR: instruction requires: sve
96 // CHECK-UNKNOWN: e0 9f e9 05 <unknown>