1 # RUN: llvm-mc %s -triple=riscv32 -mattr=+experimental-b -riscv-no-aliases \
2 # RUN: | FileCheck -check-prefixes=CHECK-S-OBJ-NOALIAS %s
3 # RUN: llvm-mc %s -triple=riscv32 -mattr=+experimental-b \
4 # RUN: | FileCheck -check-prefixes=CHECK-S-OBJ %s
5 # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+experimental-b < %s \
6 # RUN: | llvm-objdump -d -r -M no-aliases --mattr=+experimental-b - \
7 # RUN: | FileCheck -check-prefixes=CHECK-S-OBJ-NOALIAS %s
8 # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+experimental-b < %s \
9 # RUN: | llvm-objdump -d -r --mattr=+experimental-b - \
10 # RUN: | FileCheck -check-prefixes=CHECK-S-OBJ %s
12 # The following check prefixes are used in this test:
13 # CHECK-S-OBJ Match both the .s and objdumped object output with
15 # CHECK-S-OBJ-NOALIAS Match both the .s and objdumped object output with
18 # CHECK-S-OBJ-NOALIAS: andi t0, t1, 255
19 # CHECK-S-OBJ: andi t0, t1, 255
22 # CHECK-S-OBJ-NOALIAS: zext.h t0, t1
23 # CHECK-S-OBJ: zext.h t0, t1
26 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 1
27 # CHECK-S-OBJ: rev.p t0, t1
30 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 2
31 # CHECK-S-OBJ: rev2.n t0, t1
34 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 3
35 # CHECK-S-OBJ: rev.n t0, t1
38 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 4
39 # CHECK-S-OBJ: rev4.b t0, t1
42 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 6
43 # CHECK-S-OBJ: rev2.b t0, t1
46 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 7
47 # CHECK-S-OBJ: rev.b t0, t1
50 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 8
51 # CHECK-S-OBJ: rev8.h t0, t1
54 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 12
55 # CHECK-S-OBJ: rev4.h t0, t1
58 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 14
59 # CHECK-S-OBJ: rev2.h t0, t1
62 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 15
63 # CHECK-S-OBJ: rev.h t0, t1
66 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 16
67 # CHECK-S-OBJ: rev16 t0, t1
70 # CHECK-S-OBJ-NOALIAS: rev8 t0, t1
71 # CHECK-S-OBJ: rev8 t0, t1
74 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 28
75 # CHECK-S-OBJ: rev4 t0, t1
78 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 30
79 # CHECK-S-OBJ: rev2 t0, t1
82 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 31
83 # CHECK-S-OBJ: rev t0, t1
86 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 1
87 # CHECK-S-OBJ: zip.n t0, t1
90 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 1
91 # CHECK-S-OBJ: unzip.n t0, t1
94 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 2
95 # CHECK-S-OBJ: zip2.b t0, t1
98 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 2
99 # CHECK-S-OBJ: unzip2.b t0, t1
102 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 3
103 # CHECK-S-OBJ: zip.b t0, t1
106 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 3
107 # CHECK-S-OBJ: unzip.b t0, t1
110 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 4
111 # CHECK-S-OBJ: zip4.h t0, t1
114 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 4
115 # CHECK-S-OBJ: unzip4.h t0, t1
118 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 6
119 # CHECK-S-OBJ: zip2.h t0, t1
122 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 6
123 # CHECK-S-OBJ: unzip2.h t0, t1
126 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 7
127 # CHECK-S-OBJ: zip.h t0, t1
130 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 7
131 # CHECK-S-OBJ: unzip.h t0, t1
134 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 8
135 # CHECK-S-OBJ: zip8 t0, t1
138 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 8
139 # CHECK-S-OBJ: unzip8 t0, t1
142 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 12
143 # CHECK-S-OBJ: zip4 t0, t1
146 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 12
147 # CHECK-S-OBJ: unzip4 t0, t1
150 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 14
151 # CHECK-S-OBJ: zip2 t0, t1
154 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 14
155 # CHECK-S-OBJ: unzip2 t0, t1
158 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 15
159 # CHECK-S-OBJ: zip t0, t1
162 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 15
163 # CHECK-S-OBJ: unzip t0, t1
166 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 1
167 # CHECK-S-OBJ: orc.p t0, t1
170 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 2
171 # CHECK-S-OBJ: orc2.n t0, t1
174 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 3
175 # CHECK-S-OBJ: orc.n t0, t1
178 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 4
179 # CHECK-S-OBJ: orc4.b t0, t1
182 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 6
183 # CHECK-S-OBJ: orc2.b t0, t1
186 # CHECK-S-OBJ-NOALIAS: orc.b t0, t1
187 # CHECK-S-OBJ: orc.b t0, t1
190 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 8
191 # CHECK-S-OBJ: orc8.h t0, t1
194 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 12
195 # CHECK-S-OBJ: orc4.h t0, t1
198 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 14
199 # CHECK-S-OBJ: orc2.h t0, t1
202 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 15
203 # CHECK-S-OBJ: orc.h t0, t1
206 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 16
207 # CHECK-S-OBJ: orc16 t0, t1
210 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 24
211 # CHECK-S-OBJ: orc8 t0, t1
214 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 28
215 # CHECK-S-OBJ: orc4 t0, t1
218 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 30
219 # CHECK-S-OBJ: orc2 t0, t1
222 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 31
223 # CHECK-S-OBJ: orc t0, t1
226 # CHECK-S-OBJ-NOALIAS: rori t0, t1, 8
227 # CHECK-S-OBJ: rori t0, t1, 8
230 # CHECK-S-OBJ-NOALIAS: bseti t0, t1, 8
231 # CHECK-S-OBJ: bseti t0, t1, 8
234 # CHECK-S-OBJ-NOALIAS: bclri t0, t1, 8
235 # CHECK-S-OBJ: bclri t0, t1, 8
238 # CHECK-S-OBJ-NOALIAS: binvi t0, t1, 8
239 # CHECK-S-OBJ: binvi t0, t1, 8
242 # CHECK-S-OBJ-NOALIAS: bexti t0, t1, 8
243 # CHECK-S-OBJ: bexti t0, t1, 8
246 # CHECK-S-OBJ-NOALIAS: grevi t0, t1, 13
247 # CHECK-S-OBJ: grevi t0, t1, 13
250 # CHECK-S-OBJ-NOALIAS: gorci t0, t1, 13
251 # CHECK-S-OBJ: gorci t0, t1, 13
254 # CHECK-S-OBJ-NOALIAS: shfli t0, t1, 13
255 # CHECK-S-OBJ: shfli t0, t1, 13
258 # CHECK-S-OBJ-NOALIAS: unshfli t0, t1, 13
259 # CHECK-S-OBJ: unshfli t0, t1, 13