Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / llvm / test / MC / AArch64 / SME2 / zip.s
blobcfb048710ca43f48e70271238f1168eb2515f342
1 // RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %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=+sme2 < %s \
6 // RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST
7 // RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \
8 // RUN: | llvm-objdump -d --mattr=-sme2 - | FileCheck %s --check-prefix=CHECK-UNKNOWN
9 // RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \
10 // RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \
11 // RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \
12 // RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST
15 zip {z0.q - z1.q}, z0.q, z0.q // 11000001-00100000-11010100-00000000
16 // CHECK-INST: zip { z0.q, z1.q }, z0.q, z0.q
17 // CHECK-ENCODING: [0x00,0xd4,0x20,0xc1]
18 // CHECK-ERROR: instruction requires: sme2
19 // CHECK-UNKNOWN: c120d400 <unknown>
21 zip {z20.q - z21.q}, z10.q, z21.q // 11000001-00110101-11010101-01010100
22 // CHECK-INST: zip { z20.q, z21.q }, z10.q, z21.q
23 // CHECK-ENCODING: [0x54,0xd5,0x35,0xc1]
24 // CHECK-ERROR: instruction requires: sme2
25 // CHECK-UNKNOWN: c135d554 <unknown>
27 zip {z22.q - z23.q}, z13.q, z8.q // 11000001-00101000-11010101-10110110
28 // CHECK-INST: zip { z22.q, z23.q }, z13.q, z8.q
29 // CHECK-ENCODING: [0xb6,0xd5,0x28,0xc1]
30 // CHECK-ERROR: instruction requires: sme2
31 // CHECK-UNKNOWN: c128d5b6 <unknown>
33 zip {z30.q - z31.q}, z31.q, z31.q // 11000001-00111111-11010111-11111110
34 // CHECK-INST: zip { z30.q, z31.q }, z31.q, z31.q
35 // CHECK-ENCODING: [0xfe,0xd7,0x3f,0xc1]
36 // CHECK-ERROR: instruction requires: sme2
37 // CHECK-UNKNOWN: c13fd7fe <unknown>
40 zip {z0.h - z1.h}, z0.h, z0.h // 11000001-01100000-11010000-00000000
41 // CHECK-INST: zip { z0.h, z1.h }, z0.h, z0.h
42 // CHECK-ENCODING: [0x00,0xd0,0x60,0xc1]
43 // CHECK-ERROR: instruction requires: sme2
44 // CHECK-UNKNOWN: c160d000 <unknown>
46 zip {z20.h - z21.h}, z10.h, z21.h // 11000001-01110101-11010001-01010100
47 // CHECK-INST: zip { z20.h, z21.h }, z10.h, z21.h
48 // CHECK-ENCODING: [0x54,0xd1,0x75,0xc1]
49 // CHECK-ERROR: instruction requires: sme2
50 // CHECK-UNKNOWN: c175d154 <unknown>
52 zip {z22.h - z23.h}, z13.h, z8.h // 11000001-01101000-11010001-10110110
53 // CHECK-INST: zip { z22.h, z23.h }, z13.h, z8.h
54 // CHECK-ENCODING: [0xb6,0xd1,0x68,0xc1]
55 // CHECK-ERROR: instruction requires: sme2
56 // CHECK-UNKNOWN: c168d1b6 <unknown>
58 zip {z30.h - z31.h}, z31.h, z31.h // 11000001-01111111-11010011-11111110
59 // CHECK-INST: zip { z30.h, z31.h }, z31.h, z31.h
60 // CHECK-ENCODING: [0xfe,0xd3,0x7f,0xc1]
61 // CHECK-ERROR: instruction requires: sme2
62 // CHECK-UNKNOWN: c17fd3fe <unknown>
65 zip {z0.s - z1.s}, z0.s, z0.s // 11000001-10100000-11010000-00000000
66 // CHECK-INST: zip { z0.s, z1.s }, z0.s, z0.s
67 // CHECK-ENCODING: [0x00,0xd0,0xa0,0xc1]
68 // CHECK-ERROR: instruction requires: sme2
69 // CHECK-UNKNOWN: c1a0d000 <unknown>
71 zip {z20.s - z21.s}, z10.s, z21.s // 11000001-10110101-11010001-01010100
72 // CHECK-INST: zip { z20.s, z21.s }, z10.s, z21.s
73 // CHECK-ENCODING: [0x54,0xd1,0xb5,0xc1]
74 // CHECK-ERROR: instruction requires: sme2
75 // CHECK-UNKNOWN: c1b5d154 <unknown>
77 zip {z22.s - z23.s}, z13.s, z8.s // 11000001-10101000-11010001-10110110
78 // CHECK-INST: zip { z22.s, z23.s }, z13.s, z8.s
79 // CHECK-ENCODING: [0xb6,0xd1,0xa8,0xc1]
80 // CHECK-ERROR: instruction requires: sme2
81 // CHECK-UNKNOWN: c1a8d1b6 <unknown>
83 zip {z30.s - z31.s}, z31.s, z31.s // 11000001-10111111-11010011-11111110
84 // CHECK-INST: zip { z30.s, z31.s }, z31.s, z31.s
85 // CHECK-ENCODING: [0xfe,0xd3,0xbf,0xc1]
86 // CHECK-ERROR: instruction requires: sme2
87 // CHECK-UNKNOWN: c1bfd3fe <unknown>
90 zip {z0.d - z1.d}, z0.d, z0.d // 11000001-11100000-11010000-00000000
91 // CHECK-INST: zip { z0.d, z1.d }, z0.d, z0.d
92 // CHECK-ENCODING: [0x00,0xd0,0xe0,0xc1]
93 // CHECK-ERROR: instruction requires: sme2
94 // CHECK-UNKNOWN: c1e0d000 <unknown>
96 zip {z20.d - z21.d}, z10.d, z21.d // 11000001-11110101-11010001-01010100
97 // CHECK-INST: zip { z20.d, z21.d }, z10.d, z21.d
98 // CHECK-ENCODING: [0x54,0xd1,0xf5,0xc1]
99 // CHECK-ERROR: instruction requires: sme2
100 // CHECK-UNKNOWN: c1f5d154 <unknown>
102 zip {z22.d - z23.d}, z13.d, z8.d // 11000001-11101000-11010001-10110110
103 // CHECK-INST: zip { z22.d, z23.d }, z13.d, z8.d
104 // CHECK-ENCODING: [0xb6,0xd1,0xe8,0xc1]
105 // CHECK-ERROR: instruction requires: sme2
106 // CHECK-UNKNOWN: c1e8d1b6 <unknown>
108 zip {z30.d - z31.d}, z31.d, z31.d // 11000001-11111111-11010011-11111110
109 // CHECK-INST: zip { z30.d, z31.d }, z31.d, z31.d
110 // CHECK-ENCODING: [0xfe,0xd3,0xff,0xc1]
111 // CHECK-ERROR: instruction requires: sme2
112 // CHECK-UNKNOWN: c1ffd3fe <unknown>
115 zip {z0.b - z1.b}, z0.b, z0.b // 11000001-00100000-11010000-00000000
116 // CHECK-INST: zip { z0.b, z1.b }, z0.b, z0.b
117 // CHECK-ENCODING: [0x00,0xd0,0x20,0xc1]
118 // CHECK-ERROR: instruction requires: sme2
119 // CHECK-UNKNOWN: c120d000 <unknown>
121 zip {z20.b, z21.b}, z10.b, z21.b // 11000001-00110101-11010001-01010100
122 // CHECK-INST: zip { z20.b, z21.b }, z10.b, z21.b
123 // CHECK-ENCODING: [0x54,0xd1,0x35,0xc1]
124 // CHECK-ERROR: instruction requires: sme2
125 // CHECK-UNKNOWN: c135d154 <unknown>
127 zip {z22.b - z23.b}, z13.b, z8.b // 11000001-00101000-11010001-10110110
128 // CHECK-INST: zip { z22.b, z23.b }, z13.b, z8.b
129 // CHECK-ENCODING: [0xb6,0xd1,0x28,0xc1]
130 // CHECK-ERROR: instruction requires: sme2
131 // CHECK-UNKNOWN: c128d1b6 <unknown>
133 zip {z30.b - z31.b}, z31.b, z31.b // 11000001-00111111-11010011-11111110
134 // CHECK-INST: zip { z30.b, z31.b }, z31.b, z31.b
135 // CHECK-ENCODING: [0xfe,0xd3,0x3f,0xc1]
136 // CHECK-ERROR: instruction requires: sme2
137 // CHECK-UNKNOWN: c13fd3fe <unknown>
140 zip {z0.q - z3.q}, {z0.q - z3.q} // 11000001-00110111-11100000-00000000
141 // CHECK-INST: zip { z0.q - z3.q }, { z0.q - z3.q }
142 // CHECK-ENCODING: [0x00,0xe0,0x37,0xc1]
143 // CHECK-ERROR: instruction requires: sme2
144 // CHECK-UNKNOWN: c137e000 <unknown>
146 zip {z20.q - z23.q}, {z8.q - z11.q} // 11000001-00110111-11100001-00010100
147 // CHECK-INST: zip { z20.q - z23.q }, { z8.q - z11.q }
148 // CHECK-ENCODING: [0x14,0xe1,0x37,0xc1]
149 // CHECK-ERROR: instruction requires: sme2
150 // CHECK-UNKNOWN: c137e114 <unknown>
152 zip {z20.q - z23.q}, {z12.q - z15.q} // 11000001-00110111-11100001-10010100
153 // CHECK-INST: zip { z20.q - z23.q }, { z12.q - z15.q }
154 // CHECK-ENCODING: [0x94,0xe1,0x37,0xc1]
155 // CHECK-ERROR: instruction requires: sme2
156 // CHECK-UNKNOWN: c137e194 <unknown>
158 zip {z28.q - z31.q}, {z28.q - z31.q} // 11000001-00110111-11100011-10011100
159 // CHECK-INST: zip { z28.q - z31.q }, { z28.q - z31.q }
160 // CHECK-ENCODING: [0x9c,0xe3,0x37,0xc1]
161 // CHECK-ERROR: instruction requires: sme2
162 // CHECK-UNKNOWN: c137e39c <unknown>
165 zip {z0.h - z3.h}, {z0.h - z3.h} // 11000001-01110110-11100000-00000000
166 // CHECK-INST: zip { z0.h - z3.h }, { z0.h - z3.h }
167 // CHECK-ENCODING: [0x00,0xe0,0x76,0xc1]
168 // CHECK-ERROR: instruction requires: sme2
169 // CHECK-UNKNOWN: c176e000 <unknown>
171 zip {z20.h - z23.h}, {z8.h - z11.h} // 11000001-01110110-11100001-00010100
172 // CHECK-INST: zip { z20.h - z23.h }, { z8.h - z11.h }
173 // CHECK-ENCODING: [0x14,0xe1,0x76,0xc1]
174 // CHECK-ERROR: instruction requires: sme2
175 // CHECK-UNKNOWN: c176e114 <unknown>
177 zip {z20.h - z23.h}, {z12.h - z15.h} // 11000001-01110110-11100001-10010100
178 // CHECK-INST: zip { z20.h - z23.h }, { z12.h - z15.h }
179 // CHECK-ENCODING: [0x94,0xe1,0x76,0xc1]
180 // CHECK-ERROR: instruction requires: sme2
181 // CHECK-UNKNOWN: c176e194 <unknown>
183 zip {z28.h - z31.h}, {z28.h - z31.h} // 11000001-01110110-11100011-10011100
184 // CHECK-INST: zip { z28.h - z31.h }, { z28.h - z31.h }
185 // CHECK-ENCODING: [0x9c,0xe3,0x76,0xc1]
186 // CHECK-ERROR: instruction requires: sme2
187 // CHECK-UNKNOWN: c176e39c <unknown>
190 zip {z0.s - z3.s}, {z0.s - z3.s} // 11000001-10110110-11100000-00000000
191 // CHECK-INST: zip { z0.s - z3.s }, { z0.s - z3.s }
192 // CHECK-ENCODING: [0x00,0xe0,0xb6,0xc1]
193 // CHECK-ERROR: instruction requires: sme2
194 // CHECK-UNKNOWN: c1b6e000 <unknown>
196 zip {z20.s - z23.s}, {z8.s - z11.s} // 11000001-10110110-11100001-00010100
197 // CHECK-INST: zip { z20.s - z23.s }, { z8.s - z11.s }
198 // CHECK-ENCODING: [0x14,0xe1,0xb6,0xc1]
199 // CHECK-ERROR: instruction requires: sme2
200 // CHECK-UNKNOWN: c1b6e114 <unknown>
202 zip {z20.s - z23.s}, {z12.s - z15.s} // 11000001-10110110-11100001-10010100
203 // CHECK-INST: zip { z20.s - z23.s }, { z12.s - z15.s }
204 // CHECK-ENCODING: [0x94,0xe1,0xb6,0xc1]
205 // CHECK-ERROR: instruction requires: sme2
206 // CHECK-UNKNOWN: c1b6e194 <unknown>
208 zip {z28.s - z31.s}, {z28.s - z31.s} // 11000001-10110110-11100011-10011100
209 // CHECK-INST: zip { z28.s - z31.s }, { z28.s - z31.s }
210 // CHECK-ENCODING: [0x9c,0xe3,0xb6,0xc1]
211 // CHECK-ERROR: instruction requires: sme2
212 // CHECK-UNKNOWN: c1b6e39c <unknown>
215 zip {z0.d - z3.d}, {z0.d - z3.d} // 11000001-11110110-11100000-00000000
216 // CHECK-INST: zip { z0.d - z3.d }, { z0.d - z3.d }
217 // CHECK-ENCODING: [0x00,0xe0,0xf6,0xc1]
218 // CHECK-ERROR: instruction requires: sme2
219 // CHECK-UNKNOWN: c1f6e000 <unknown>
221 zip {z20.d - z23.d}, {z8.d - z11.d} // 11000001-11110110-11100001-00010100
222 // CHECK-INST: zip { z20.d - z23.d }, { z8.d - z11.d }
223 // CHECK-ENCODING: [0x14,0xe1,0xf6,0xc1]
224 // CHECK-ERROR: instruction requires: sme2
225 // CHECK-UNKNOWN: c1f6e114 <unknown>
227 zip {z20.d - z23.d}, {z12.d - z15.d} // 11000001-11110110-11100001-10010100
228 // CHECK-INST: zip { z20.d - z23.d }, { z12.d - z15.d }
229 // CHECK-ENCODING: [0x94,0xe1,0xf6,0xc1]
230 // CHECK-ERROR: instruction requires: sme2
231 // CHECK-UNKNOWN: c1f6e194 <unknown>
233 zip {z28.d - z31.d}, {z28.d - z31.d} // 11000001-11110110-11100011-10011100
234 // CHECK-INST: zip { z28.d - z31.d }, { z28.d - z31.d }
235 // CHECK-ENCODING: [0x9c,0xe3,0xf6,0xc1]
236 // CHECK-ERROR: instruction requires: sme2
237 // CHECK-UNKNOWN: c1f6e39c <unknown>
240 zip {z0.b - z3.b}, {z0.b - z3.b} // 11000001-00110110-11100000-00000000
241 // CHECK-INST: zip { z0.b - z3.b }, { z0.b - z3.b }
242 // CHECK-ENCODING: [0x00,0xe0,0x36,0xc1]
243 // CHECK-ERROR: instruction requires: sme2
244 // CHECK-UNKNOWN: c136e000 <unknown>
246 zip {z20.b - z23.b}, {z8.b - z11.b} // 11000001-00110110-11100001-00010100
247 // CHECK-INST: zip { z20.b - z23.b }, { z8.b - z11.b }
248 // CHECK-ENCODING: [0x14,0xe1,0x36,0xc1]
249 // CHECK-ERROR: instruction requires: sme2
250 // CHECK-UNKNOWN: c136e114 <unknown>
252 zip {z20.b - z23.b}, {z12.b - z15.b} // 11000001-00110110-11100001-10010100
253 // CHECK-INST: zip { z20.b - z23.b }, { z12.b - z15.b }
254 // CHECK-ENCODING: [0x94,0xe1,0x36,0xc1]
255 // CHECK-ERROR: instruction requires: sme2
256 // CHECK-UNKNOWN: c136e194 <unknown>
258 zip {z28.b - z31.b}, {z28.b - z31.b} // 11000001-00110110-11100011-10011100
259 // CHECK-INST: zip { z28.b - z31.b }, { z28.b - z31.b }
260 // CHECK-ENCODING: [0x9c,0xe3,0x36,0xc1]
261 // CHECK-ERROR: instruction requires: sme2
262 // CHECK-UNKNOWN: c136e39c <unknown>