1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -march=amdgcn -mcpu=fiji -run-pass=regbankselect -regbankselect-fast -verify-machineinstrs -o - %s | FileCheck %s
3 # RUN: llc -march=amdgcn -mcpu=fiji -run-pass=regbankselect -regbankselect-greedy -verify-machineinstrs -o - %s | FileCheck %s
11 liveins: $sgpr0, $sgpr1, $sgpr2
12 ; CHECK-LABEL: name: fshr_sss
13 ; CHECK: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
14 ; CHECK: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
15 ; CHECK: [[COPY2:%[0-9]+]]:sgpr(s32) = COPY $sgpr2
16 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
17 ; CHECK: [[COPY4:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
18 ; CHECK: [[COPY5:%[0-9]+]]:vgpr(s32) = COPY [[COPY2]](s32)
19 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY3]], [[COPY4]], [[COPY5]](s32)
20 %0:_(s32) = COPY $sgpr0
21 %1:_(s32) = COPY $sgpr1
22 %2:_(s32) = COPY $sgpr2
23 %3:_(s32) = G_FSHR %0, %1, %2
31 liveins: $vgpr0, $sgpr0, $sgpr1
32 ; CHECK-LABEL: name: fshr_vss
33 ; CHECK: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
34 ; CHECK: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
35 ; CHECK: [[COPY2:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
36 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
37 ; CHECK: [[COPY4:%[0-9]+]]:vgpr(s32) = COPY [[COPY2]](s32)
38 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY]], [[COPY3]], [[COPY4]](s32)
39 %0:_(s32) = COPY $vgpr0
40 %1:_(s32) = COPY $sgpr0
41 %2:_(s32) = COPY $sgpr1
42 %3:_(s32) = G_FSHR %0, %1, %2
50 liveins: $sgpr0, $vgpr0, $sgpr1
51 ; CHECK-LABEL: name: fshr_svs
52 ; CHECK: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
53 ; CHECK: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
54 ; CHECK: [[COPY2:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
55 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
56 ; CHECK: [[COPY4:%[0-9]+]]:vgpr(s32) = COPY [[COPY2]](s32)
57 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY3]], [[COPY1]], [[COPY4]](s32)
58 %0:_(s32) = COPY $sgpr0
59 %1:_(s32) = COPY $vgpr0
60 %2:_(s32) = COPY $sgpr1
61 %3:_(s32) = G_FSHR %0, %1, %2
69 liveins: $sgpr0, $sgpr1, $vgpr0
70 ; CHECK-LABEL: name: fshr_ssv
71 ; CHECK: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
72 ; CHECK: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
73 ; CHECK: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
74 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
75 ; CHECK: [[COPY4:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
76 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY3]], [[COPY4]], [[COPY2]](s32)
77 %0:_(s32) = COPY $sgpr0
78 %1:_(s32) = COPY $sgpr1
79 %2:_(s32) = COPY $vgpr0
80 %3:_(s32) = G_FSHR %0, %1, %2
88 liveins: $vgpr0, $vgpr1, $sgpr0
89 ; CHECK-LABEL: name: fshr_vvs
90 ; CHECK: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
91 ; CHECK: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
92 ; CHECK: [[COPY2:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
93 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY2]](s32)
94 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY]], [[COPY1]], [[COPY3]](s32)
95 %0:_(s32) = COPY $vgpr0
96 %1:_(s32) = COPY $vgpr1
97 %2:_(s32) = COPY $sgpr0
98 %3:_(s32) = G_FSHR %0, %1, %2
106 liveins: $vgpr0, $sgpr0, $vgpr1
107 ; CHECK-LABEL: name: fshr_vsv
108 ; CHECK: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
109 ; CHECK: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
110 ; CHECK: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
111 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
112 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY]], [[COPY3]], [[COPY2]](s32)
113 %0:_(s32) = COPY $vgpr0
114 %1:_(s32) = COPY $sgpr1
115 %2:_(s32) = COPY $vgpr1
116 %3:_(s32) = G_FSHR %0, %1, %2
124 liveins: $sgpr0, $vgpr0, $vgpr1
125 ; CHECK-LABEL: name: fshr_svv
126 ; CHECK: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
127 ; CHECK: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
128 ; CHECK: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
129 ; CHECK: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
130 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY3]], [[COPY1]], [[COPY2]](s32)
131 %0:_(s32) = COPY $sgpr0
132 %1:_(s32) = COPY $vgpr0
133 %2:_(s32) = COPY $vgpr1
134 %3:_(s32) = G_FSHR %0, %1, %2
142 liveins: $vgpr0, $vgpr1, $vgpr2
143 ; CHECK-LABEL: name: fshr_vvv
144 ; CHECK: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
145 ; CHECK: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
146 ; CHECK: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr2
147 ; CHECK: [[FSHR:%[0-9]+]]:vgpr(s32) = G_FSHR [[COPY]], [[COPY1]], [[COPY2]](s32)
148 %0:_(s32) = COPY $vgpr0
149 %1:_(s32) = COPY $vgpr1
150 %2:_(s32) = COPY $vgpr2
151 %3:_(s32) = G_FSHR %0, %1, %2