1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=amdgcn -mcpu=gfx1100 -mattr="+wavefrontsize32" -verify-machineinstrs < %s | FileCheck -check-prefixes=SDAG-GFX11 %s
3 ; RUN: llc -mtriple=amdgcn -mcpu=gfx1010 -mattr="+wavefrontsize32" -verify-machineinstrs < %s | FileCheck -check-prefixes=SDAG-GFX10 %s
5 ; RUN: llc -global-isel -mtriple=amdgcn -mcpu=gfx1100 -mattr="+wavefrontsize32" -verify-machineinstrs < %s | FileCheck -check-prefixes=GISEL-GFX11 %s
6 ; RUN: llc -global-isel -mtriple=amdgcn -mcpu=gfx1010 -mattr="+wavefrontsize32" -verify-machineinstrs < %s | FileCheck -check-prefixes=GISEL-GFX10 %s
8 declare i32 @llvm.amdgcn.fcmp.f32(float, float, i32) #0
9 declare i32 @llvm.amdgcn.fcmp.f64(double, double, i32) #0
10 declare float @llvm.fabs.f32(float) #0
12 declare i32 @llvm.amdgcn.fcmp.f16(half, half, i32) #0
13 declare half @llvm.fabs.f16(half) #0
15 define amdgpu_kernel void @v_fcmp_f32_oeq_with_fabs(ptr addrspace(1) %out, float %src, float %a) {
16 ; SDAG-GFX11-LABEL: v_fcmp_f32_oeq_with_fabs:
17 ; SDAG-GFX11: ; %bb.0:
18 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
19 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
20 ; SDAG-GFX11-NEXT: v_cmp_eq_f32_e64 s2, s2, |s3|
21 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
22 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
23 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
24 ; SDAG-GFX11-NEXT: s_nop 0
25 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
26 ; SDAG-GFX11-NEXT: s_endpgm
28 ; SDAG-GFX10-LABEL: v_fcmp_f32_oeq_with_fabs:
29 ; SDAG-GFX10: ; %bb.0:
30 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
31 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
32 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
33 ; SDAG-GFX10-NEXT: v_cmp_eq_f32_e64 s0, s6, |s7|
34 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
35 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
36 ; SDAG-GFX10-NEXT: s_endpgm
38 ; GISEL-GFX11-LABEL: v_fcmp_f32_oeq_with_fabs:
39 ; GISEL-GFX11: ; %bb.0:
40 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
41 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
42 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
43 ; GISEL-GFX11-NEXT: v_cmp_eq_f32_e64 s2, s2, |s3|
44 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
45 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
46 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
47 ; GISEL-GFX11-NEXT: s_nop 0
48 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
49 ; GISEL-GFX11-NEXT: s_endpgm
51 ; GISEL-GFX10-LABEL: v_fcmp_f32_oeq_with_fabs:
52 ; GISEL-GFX10: ; %bb.0:
53 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
54 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
55 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
56 ; GISEL-GFX10-NEXT: v_cmp_eq_f32_e64 s0, s6, |s7|
57 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
58 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
59 ; GISEL-GFX10-NEXT: s_endpgm
60 %temp = call float @llvm.fabs.f32(float %a)
61 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float %temp, i32 1)
62 store i32 %result, ptr addrspace(1) %out
66 define amdgpu_kernel void @v_fcmp_f32_oeq_both_operands_with_fabs(ptr addrspace(1) %out, float %src, float %a) {
67 ; SDAG-GFX11-LABEL: v_fcmp_f32_oeq_both_operands_with_fabs:
68 ; SDAG-GFX11: ; %bb.0:
69 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
70 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
71 ; SDAG-GFX11-NEXT: v_cmp_eq_f32_e64 s2, |s2|, |s3|
72 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
73 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
74 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
75 ; SDAG-GFX11-NEXT: s_nop 0
76 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
77 ; SDAG-GFX11-NEXT: s_endpgm
79 ; SDAG-GFX10-LABEL: v_fcmp_f32_oeq_both_operands_with_fabs:
80 ; SDAG-GFX10: ; %bb.0:
81 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
82 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
83 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
84 ; SDAG-GFX10-NEXT: v_cmp_eq_f32_e64 s0, |s6|, |s7|
85 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
86 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
87 ; SDAG-GFX10-NEXT: s_endpgm
89 ; GISEL-GFX11-LABEL: v_fcmp_f32_oeq_both_operands_with_fabs:
90 ; GISEL-GFX11: ; %bb.0:
91 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
92 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
93 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
94 ; GISEL-GFX11-NEXT: v_cmp_eq_f32_e64 s2, |s2|, |s3|
95 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
96 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
97 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
98 ; GISEL-GFX11-NEXT: s_nop 0
99 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
100 ; GISEL-GFX11-NEXT: s_endpgm
102 ; GISEL-GFX10-LABEL: v_fcmp_f32_oeq_both_operands_with_fabs:
103 ; GISEL-GFX10: ; %bb.0:
104 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
105 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
106 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
107 ; GISEL-GFX10-NEXT: v_cmp_eq_f32_e64 s0, |s6|, |s7|
108 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
109 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
110 ; GISEL-GFX10-NEXT: s_endpgm
111 %temp = call float @llvm.fabs.f32(float %a)
112 %src_input = call float @llvm.fabs.f32(float %src)
113 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src_input, float %temp, i32 1)
114 store i32 %result, ptr addrspace(1) %out
118 define amdgpu_kernel void @v_fcmp_f32(ptr addrspace(1) %out, float %src) {
119 ; SDAG-GFX11-LABEL: v_fcmp_f32:
120 ; SDAG-GFX11: ; %bb.0:
121 ; SDAG-GFX11-NEXT: s_endpgm
123 ; SDAG-GFX10-LABEL: v_fcmp_f32:
124 ; SDAG-GFX10: ; %bb.0:
125 ; SDAG-GFX10-NEXT: s_endpgm
127 ; GISEL-GFX11-LABEL: v_fcmp_f32:
128 ; GISEL-GFX11: ; %bb.0:
129 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
130 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, 0
131 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
132 ; GISEL-GFX11-NEXT: global_store_b32 v0, v0, s[0:1]
133 ; GISEL-GFX11-NEXT: s_nop 0
134 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
135 ; GISEL-GFX11-NEXT: s_endpgm
137 ; GISEL-GFX10-LABEL: v_fcmp_f32:
138 ; GISEL-GFX10: ; %bb.0:
139 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
140 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, 0
141 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
142 ; GISEL-GFX10-NEXT: global_store_dword v0, v0, s[0:1]
143 ; GISEL-GFX10-NEXT: s_endpgm
144 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 -1)
145 store i32 %result, ptr addrspace(1) %out
149 define amdgpu_kernel void @v_fcmp_f32_oeq(ptr addrspace(1) %out, float %src) {
150 ; SDAG-GFX11-LABEL: v_fcmp_f32_oeq:
151 ; SDAG-GFX11: ; %bb.0:
152 ; SDAG-GFX11-NEXT: s_clause 0x1
153 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
154 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
155 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
156 ; SDAG-GFX11-NEXT: v_cmp_eq_f32_e64 s2, 0x42c80000, s4
157 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
158 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
159 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
160 ; SDAG-GFX11-NEXT: s_nop 0
161 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
162 ; SDAG-GFX11-NEXT: s_endpgm
164 ; SDAG-GFX10-LABEL: v_fcmp_f32_oeq:
165 ; SDAG-GFX10: ; %bb.0:
166 ; SDAG-GFX10-NEXT: s_clause 0x1
167 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
168 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
169 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
170 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
171 ; SDAG-GFX10-NEXT: v_cmp_eq_f32_e64 s2, 0x42c80000, s4
172 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
173 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
174 ; SDAG-GFX10-NEXT: s_endpgm
176 ; GISEL-GFX11-LABEL: v_fcmp_f32_oeq:
177 ; GISEL-GFX11: ; %bb.0:
178 ; GISEL-GFX11-NEXT: s_clause 0x1
179 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
180 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
181 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
182 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
183 ; GISEL-GFX11-NEXT: v_cmp_eq_f32_e64 s2, 0x42c80000, s4
184 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
185 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
186 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
187 ; GISEL-GFX11-NEXT: s_nop 0
188 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
189 ; GISEL-GFX11-NEXT: s_endpgm
191 ; GISEL-GFX10-LABEL: v_fcmp_f32_oeq:
192 ; GISEL-GFX10: ; %bb.0:
193 ; GISEL-GFX10-NEXT: s_clause 0x1
194 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
195 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
196 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
197 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
198 ; GISEL-GFX10-NEXT: v_cmp_eq_f32_e64 s2, 0x42c80000, s4
199 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
200 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
201 ; GISEL-GFX10-NEXT: s_endpgm
202 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 1)
203 store i32 %result, ptr addrspace(1) %out
207 define amdgpu_kernel void @v_fcmp_f32_one(ptr addrspace(1) %out, float %src) {
208 ; SDAG-GFX11-LABEL: v_fcmp_f32_one:
209 ; SDAG-GFX11: ; %bb.0:
210 ; SDAG-GFX11-NEXT: s_clause 0x1
211 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
212 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
213 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
214 ; SDAG-GFX11-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
215 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
216 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
217 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
218 ; SDAG-GFX11-NEXT: s_nop 0
219 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
220 ; SDAG-GFX11-NEXT: s_endpgm
222 ; SDAG-GFX10-LABEL: v_fcmp_f32_one:
223 ; SDAG-GFX10: ; %bb.0:
224 ; SDAG-GFX10-NEXT: s_clause 0x1
225 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
226 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
227 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
228 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
229 ; SDAG-GFX10-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
230 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
231 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
232 ; SDAG-GFX10-NEXT: s_endpgm
234 ; GISEL-GFX11-LABEL: v_fcmp_f32_one:
235 ; GISEL-GFX11: ; %bb.0:
236 ; GISEL-GFX11-NEXT: s_clause 0x1
237 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
238 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
239 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
240 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
241 ; GISEL-GFX11-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
242 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
243 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
244 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
245 ; GISEL-GFX11-NEXT: s_nop 0
246 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
247 ; GISEL-GFX11-NEXT: s_endpgm
249 ; GISEL-GFX10-LABEL: v_fcmp_f32_one:
250 ; GISEL-GFX10: ; %bb.0:
251 ; GISEL-GFX10-NEXT: s_clause 0x1
252 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
253 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
254 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
255 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
256 ; GISEL-GFX10-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
257 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
258 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
259 ; GISEL-GFX10-NEXT: s_endpgm
260 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 6)
261 store i32 %result, ptr addrspace(1) %out
265 define amdgpu_kernel void @v_fcmp_f32_ogt(ptr addrspace(1) %out, float %src) {
266 ; SDAG-GFX11-LABEL: v_fcmp_f32_ogt:
267 ; SDAG-GFX11: ; %bb.0:
268 ; SDAG-GFX11-NEXT: s_clause 0x1
269 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
270 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
271 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
272 ; SDAG-GFX11-NEXT: v_cmp_lt_f32_e64 s2, 0x42c80000, s4
273 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
274 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
275 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
276 ; SDAG-GFX11-NEXT: s_nop 0
277 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
278 ; SDAG-GFX11-NEXT: s_endpgm
280 ; SDAG-GFX10-LABEL: v_fcmp_f32_ogt:
281 ; SDAG-GFX10: ; %bb.0:
282 ; SDAG-GFX10-NEXT: s_clause 0x1
283 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
284 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
285 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
286 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
287 ; SDAG-GFX10-NEXT: v_cmp_lt_f32_e64 s2, 0x42c80000, s4
288 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
289 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
290 ; SDAG-GFX10-NEXT: s_endpgm
292 ; GISEL-GFX11-LABEL: v_fcmp_f32_ogt:
293 ; GISEL-GFX11: ; %bb.0:
294 ; GISEL-GFX11-NEXT: s_clause 0x1
295 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
296 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
297 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
298 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
299 ; GISEL-GFX11-NEXT: v_cmp_lt_f32_e64 s2, 0x42c80000, s4
300 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
301 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
302 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
303 ; GISEL-GFX11-NEXT: s_nop 0
304 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
305 ; GISEL-GFX11-NEXT: s_endpgm
307 ; GISEL-GFX10-LABEL: v_fcmp_f32_ogt:
308 ; GISEL-GFX10: ; %bb.0:
309 ; GISEL-GFX10-NEXT: s_clause 0x1
310 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
311 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
312 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
313 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
314 ; GISEL-GFX10-NEXT: v_cmp_lt_f32_e64 s2, 0x42c80000, s4
315 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
316 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
317 ; GISEL-GFX10-NEXT: s_endpgm
318 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 2)
319 store i32 %result, ptr addrspace(1) %out
323 define amdgpu_kernel void @v_fcmp_f32_oge(ptr addrspace(1) %out, float %src) {
324 ; SDAG-GFX11-LABEL: v_fcmp_f32_oge:
325 ; SDAG-GFX11: ; %bb.0:
326 ; SDAG-GFX11-NEXT: s_clause 0x1
327 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
328 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
329 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
330 ; SDAG-GFX11-NEXT: v_cmp_le_f32_e64 s2, 0x42c80000, s4
331 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
332 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
333 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
334 ; SDAG-GFX11-NEXT: s_nop 0
335 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
336 ; SDAG-GFX11-NEXT: s_endpgm
338 ; SDAG-GFX10-LABEL: v_fcmp_f32_oge:
339 ; SDAG-GFX10: ; %bb.0:
340 ; SDAG-GFX10-NEXT: s_clause 0x1
341 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
342 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
343 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
344 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
345 ; SDAG-GFX10-NEXT: v_cmp_le_f32_e64 s2, 0x42c80000, s4
346 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
347 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
348 ; SDAG-GFX10-NEXT: s_endpgm
350 ; GISEL-GFX11-LABEL: v_fcmp_f32_oge:
351 ; GISEL-GFX11: ; %bb.0:
352 ; GISEL-GFX11-NEXT: s_clause 0x1
353 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
354 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
355 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
356 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
357 ; GISEL-GFX11-NEXT: v_cmp_le_f32_e64 s2, 0x42c80000, s4
358 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
359 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
360 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
361 ; GISEL-GFX11-NEXT: s_nop 0
362 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
363 ; GISEL-GFX11-NEXT: s_endpgm
365 ; GISEL-GFX10-LABEL: v_fcmp_f32_oge:
366 ; GISEL-GFX10: ; %bb.0:
367 ; GISEL-GFX10-NEXT: s_clause 0x1
368 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
369 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
370 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
371 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
372 ; GISEL-GFX10-NEXT: v_cmp_le_f32_e64 s2, 0x42c80000, s4
373 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
374 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
375 ; GISEL-GFX10-NEXT: s_endpgm
376 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 3)
377 store i32 %result, ptr addrspace(1) %out
381 define amdgpu_kernel void @v_fcmp_f32_olt(ptr addrspace(1) %out, float %src) {
382 ; SDAG-GFX11-LABEL: v_fcmp_f32_olt:
383 ; SDAG-GFX11: ; %bb.0:
384 ; SDAG-GFX11-NEXT: s_clause 0x1
385 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
386 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
387 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
388 ; SDAG-GFX11-NEXT: v_cmp_gt_f32_e64 s2, 0x42c80000, s4
389 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
390 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
391 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
392 ; SDAG-GFX11-NEXT: s_nop 0
393 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
394 ; SDAG-GFX11-NEXT: s_endpgm
396 ; SDAG-GFX10-LABEL: v_fcmp_f32_olt:
397 ; SDAG-GFX10: ; %bb.0:
398 ; SDAG-GFX10-NEXT: s_clause 0x1
399 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
400 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
401 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
402 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
403 ; SDAG-GFX10-NEXT: v_cmp_gt_f32_e64 s2, 0x42c80000, s4
404 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
405 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
406 ; SDAG-GFX10-NEXT: s_endpgm
408 ; GISEL-GFX11-LABEL: v_fcmp_f32_olt:
409 ; GISEL-GFX11: ; %bb.0:
410 ; GISEL-GFX11-NEXT: s_clause 0x1
411 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
412 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
413 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
414 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
415 ; GISEL-GFX11-NEXT: v_cmp_gt_f32_e64 s2, 0x42c80000, s4
416 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
417 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
418 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
419 ; GISEL-GFX11-NEXT: s_nop 0
420 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
421 ; GISEL-GFX11-NEXT: s_endpgm
423 ; GISEL-GFX10-LABEL: v_fcmp_f32_olt:
424 ; GISEL-GFX10: ; %bb.0:
425 ; GISEL-GFX10-NEXT: s_clause 0x1
426 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
427 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
428 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
429 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
430 ; GISEL-GFX10-NEXT: v_cmp_gt_f32_e64 s2, 0x42c80000, s4
431 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
432 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
433 ; GISEL-GFX10-NEXT: s_endpgm
434 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 4)
435 store i32 %result, ptr addrspace(1) %out
439 define amdgpu_kernel void @v_fcmp_f32_ole(ptr addrspace(1) %out, float %src) {
440 ; SDAG-GFX11-LABEL: v_fcmp_f32_ole:
441 ; SDAG-GFX11: ; %bb.0:
442 ; SDAG-GFX11-NEXT: s_clause 0x1
443 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
444 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
445 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
446 ; SDAG-GFX11-NEXT: v_cmp_ge_f32_e64 s2, 0x42c80000, s4
447 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
448 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
449 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
450 ; SDAG-GFX11-NEXT: s_nop 0
451 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
452 ; SDAG-GFX11-NEXT: s_endpgm
454 ; SDAG-GFX10-LABEL: v_fcmp_f32_ole:
455 ; SDAG-GFX10: ; %bb.0:
456 ; SDAG-GFX10-NEXT: s_clause 0x1
457 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
458 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
459 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
460 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
461 ; SDAG-GFX10-NEXT: v_cmp_ge_f32_e64 s2, 0x42c80000, s4
462 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
463 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
464 ; SDAG-GFX10-NEXT: s_endpgm
466 ; GISEL-GFX11-LABEL: v_fcmp_f32_ole:
467 ; GISEL-GFX11: ; %bb.0:
468 ; GISEL-GFX11-NEXT: s_clause 0x1
469 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
470 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
471 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
472 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
473 ; GISEL-GFX11-NEXT: v_cmp_ge_f32_e64 s2, 0x42c80000, s4
474 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
475 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
476 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
477 ; GISEL-GFX11-NEXT: s_nop 0
478 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
479 ; GISEL-GFX11-NEXT: s_endpgm
481 ; GISEL-GFX10-LABEL: v_fcmp_f32_ole:
482 ; GISEL-GFX10: ; %bb.0:
483 ; GISEL-GFX10-NEXT: s_clause 0x1
484 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
485 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
486 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
487 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
488 ; GISEL-GFX10-NEXT: v_cmp_ge_f32_e64 s2, 0x42c80000, s4
489 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
490 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
491 ; GISEL-GFX10-NEXT: s_endpgm
492 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 5)
493 store i32 %result, ptr addrspace(1) %out
497 define amdgpu_kernel void @v_fcmp_f32_o(ptr addrspace(1) %out, float %src) {
498 ; SDAG-GFX11-LABEL: v_fcmp_f32_o:
499 ; SDAG-GFX11: ; %bb.0:
500 ; SDAG-GFX11-NEXT: s_clause 0x1
501 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
502 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
503 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
504 ; SDAG-GFX11-NEXT: v_cmp_o_f32_e64 s2, 0x42c80000, s4
505 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
506 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
507 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
508 ; SDAG-GFX11-NEXT: s_nop 0
509 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
510 ; SDAG-GFX11-NEXT: s_endpgm
512 ; SDAG-GFX10-LABEL: v_fcmp_f32_o:
513 ; SDAG-GFX10: ; %bb.0:
514 ; SDAG-GFX10-NEXT: s_clause 0x1
515 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
516 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
517 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
518 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
519 ; SDAG-GFX10-NEXT: v_cmp_o_f32_e64 s2, 0x42c80000, s4
520 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
521 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
522 ; SDAG-GFX10-NEXT: s_endpgm
524 ; GISEL-GFX11-LABEL: v_fcmp_f32_o:
525 ; GISEL-GFX11: ; %bb.0:
526 ; GISEL-GFX11-NEXT: s_clause 0x1
527 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
528 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
529 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
530 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
531 ; GISEL-GFX11-NEXT: v_cmp_o_f32_e64 s2, 0x42c80000, s4
532 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
533 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
534 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
535 ; GISEL-GFX11-NEXT: s_nop 0
536 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
537 ; GISEL-GFX11-NEXT: s_endpgm
539 ; GISEL-GFX10-LABEL: v_fcmp_f32_o:
540 ; GISEL-GFX10: ; %bb.0:
541 ; GISEL-GFX10-NEXT: s_clause 0x1
542 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
543 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
544 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
545 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
546 ; GISEL-GFX10-NEXT: v_cmp_o_f32_e64 s2, 0x42c80000, s4
547 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
548 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
549 ; GISEL-GFX10-NEXT: s_endpgm
550 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 7)
551 store i32 %result, ptr addrspace(1) %out
555 define amdgpu_kernel void @v_fcmp_f32_uo(ptr addrspace(1) %out, float %src) {
556 ; SDAG-GFX11-LABEL: v_fcmp_f32_uo:
557 ; SDAG-GFX11: ; %bb.0:
558 ; SDAG-GFX11-NEXT: s_clause 0x1
559 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
560 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
561 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
562 ; SDAG-GFX11-NEXT: v_cmp_u_f32_e64 s2, 0x42c80000, s4
563 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
564 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
565 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
566 ; SDAG-GFX11-NEXT: s_nop 0
567 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
568 ; SDAG-GFX11-NEXT: s_endpgm
570 ; SDAG-GFX10-LABEL: v_fcmp_f32_uo:
571 ; SDAG-GFX10: ; %bb.0:
572 ; SDAG-GFX10-NEXT: s_clause 0x1
573 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
574 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
575 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
576 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
577 ; SDAG-GFX10-NEXT: v_cmp_u_f32_e64 s2, 0x42c80000, s4
578 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
579 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
580 ; SDAG-GFX10-NEXT: s_endpgm
582 ; GISEL-GFX11-LABEL: v_fcmp_f32_uo:
583 ; GISEL-GFX11: ; %bb.0:
584 ; GISEL-GFX11-NEXT: s_clause 0x1
585 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
586 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
587 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
588 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
589 ; GISEL-GFX11-NEXT: v_cmp_u_f32_e64 s2, 0x42c80000, s4
590 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
591 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
592 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
593 ; GISEL-GFX11-NEXT: s_nop 0
594 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
595 ; GISEL-GFX11-NEXT: s_endpgm
597 ; GISEL-GFX10-LABEL: v_fcmp_f32_uo:
598 ; GISEL-GFX10: ; %bb.0:
599 ; GISEL-GFX10-NEXT: s_clause 0x1
600 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
601 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
602 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
603 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
604 ; GISEL-GFX10-NEXT: v_cmp_u_f32_e64 s2, 0x42c80000, s4
605 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
606 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
607 ; GISEL-GFX10-NEXT: s_endpgm
608 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 8)
609 store i32 %result, ptr addrspace(1) %out
613 define amdgpu_kernel void @v_fcmp_f32_ueq(ptr addrspace(1) %out, float %src) {
614 ; SDAG-GFX11-LABEL: v_fcmp_f32_ueq:
615 ; SDAG-GFX11: ; %bb.0:
616 ; SDAG-GFX11-NEXT: s_clause 0x1
617 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
618 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
619 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
620 ; SDAG-GFX11-NEXT: v_cmp_nlg_f32_e64 s2, 0x42c80000, s4
621 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
622 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
623 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
624 ; SDAG-GFX11-NEXT: s_nop 0
625 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
626 ; SDAG-GFX11-NEXT: s_endpgm
628 ; SDAG-GFX10-LABEL: v_fcmp_f32_ueq:
629 ; SDAG-GFX10: ; %bb.0:
630 ; SDAG-GFX10-NEXT: s_clause 0x1
631 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
632 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
633 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
634 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
635 ; SDAG-GFX10-NEXT: v_cmp_nlg_f32_e64 s2, 0x42c80000, s4
636 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
637 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
638 ; SDAG-GFX10-NEXT: s_endpgm
640 ; GISEL-GFX11-LABEL: v_fcmp_f32_ueq:
641 ; GISEL-GFX11: ; %bb.0:
642 ; GISEL-GFX11-NEXT: s_clause 0x1
643 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
644 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
645 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
646 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
647 ; GISEL-GFX11-NEXT: v_cmp_nlg_f32_e64 s2, 0x42c80000, s4
648 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
649 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
650 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
651 ; GISEL-GFX11-NEXT: s_nop 0
652 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
653 ; GISEL-GFX11-NEXT: s_endpgm
655 ; GISEL-GFX10-LABEL: v_fcmp_f32_ueq:
656 ; GISEL-GFX10: ; %bb.0:
657 ; GISEL-GFX10-NEXT: s_clause 0x1
658 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
659 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
660 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
661 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
662 ; GISEL-GFX10-NEXT: v_cmp_nlg_f32_e64 s2, 0x42c80000, s4
663 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
664 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
665 ; GISEL-GFX10-NEXT: s_endpgm
666 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 9)
667 store i32 %result, ptr addrspace(1) %out
671 define amdgpu_kernel void @v_fcmp_f32_une(ptr addrspace(1) %out, float %src) {
672 ; SDAG-GFX11-LABEL: v_fcmp_f32_une:
673 ; SDAG-GFX11: ; %bb.0:
674 ; SDAG-GFX11-NEXT: s_clause 0x1
675 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
676 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
677 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
678 ; SDAG-GFX11-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
679 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
680 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
681 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
682 ; SDAG-GFX11-NEXT: s_nop 0
683 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
684 ; SDAG-GFX11-NEXT: s_endpgm
686 ; SDAG-GFX10-LABEL: v_fcmp_f32_une:
687 ; SDAG-GFX10: ; %bb.0:
688 ; SDAG-GFX10-NEXT: s_clause 0x1
689 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
690 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
691 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
692 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
693 ; SDAG-GFX10-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
694 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
695 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
696 ; SDAG-GFX10-NEXT: s_endpgm
698 ; GISEL-GFX11-LABEL: v_fcmp_f32_une:
699 ; GISEL-GFX11: ; %bb.0:
700 ; GISEL-GFX11-NEXT: s_clause 0x1
701 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
702 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
703 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
704 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
705 ; GISEL-GFX11-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
706 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
707 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
708 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
709 ; GISEL-GFX11-NEXT: s_nop 0
710 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
711 ; GISEL-GFX11-NEXT: s_endpgm
713 ; GISEL-GFX10-LABEL: v_fcmp_f32_une:
714 ; GISEL-GFX10: ; %bb.0:
715 ; GISEL-GFX10-NEXT: s_clause 0x1
716 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
717 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
718 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
719 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
720 ; GISEL-GFX10-NEXT: v_cmp_neq_f32_e64 s2, 0x42c80000, s4
721 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
722 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
723 ; GISEL-GFX10-NEXT: s_endpgm
724 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 14)
725 store i32 %result, ptr addrspace(1) %out
729 define amdgpu_kernel void @v_fcmp_f32_ugt(ptr addrspace(1) %out, float %src) {
730 ; SDAG-GFX11-LABEL: v_fcmp_f32_ugt:
731 ; SDAG-GFX11: ; %bb.0:
732 ; SDAG-GFX11-NEXT: s_clause 0x1
733 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
734 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
735 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
736 ; SDAG-GFX11-NEXT: v_cmp_nge_f32_e64 s2, 0x42c80000, s4
737 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
738 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
739 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
740 ; SDAG-GFX11-NEXT: s_nop 0
741 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
742 ; SDAG-GFX11-NEXT: s_endpgm
744 ; SDAG-GFX10-LABEL: v_fcmp_f32_ugt:
745 ; SDAG-GFX10: ; %bb.0:
746 ; SDAG-GFX10-NEXT: s_clause 0x1
747 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
748 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
749 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
750 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
751 ; SDAG-GFX10-NEXT: v_cmp_nge_f32_e64 s2, 0x42c80000, s4
752 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
753 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
754 ; SDAG-GFX10-NEXT: s_endpgm
756 ; GISEL-GFX11-LABEL: v_fcmp_f32_ugt:
757 ; GISEL-GFX11: ; %bb.0:
758 ; GISEL-GFX11-NEXT: s_clause 0x1
759 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
760 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
761 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
762 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
763 ; GISEL-GFX11-NEXT: v_cmp_nge_f32_e64 s2, 0x42c80000, s4
764 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
765 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
766 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
767 ; GISEL-GFX11-NEXT: s_nop 0
768 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
769 ; GISEL-GFX11-NEXT: s_endpgm
771 ; GISEL-GFX10-LABEL: v_fcmp_f32_ugt:
772 ; GISEL-GFX10: ; %bb.0:
773 ; GISEL-GFX10-NEXT: s_clause 0x1
774 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
775 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
776 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
777 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
778 ; GISEL-GFX10-NEXT: v_cmp_nge_f32_e64 s2, 0x42c80000, s4
779 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
780 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
781 ; GISEL-GFX10-NEXT: s_endpgm
782 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 10)
783 store i32 %result, ptr addrspace(1) %out
787 define amdgpu_kernel void @v_fcmp_f32_uge(ptr addrspace(1) %out, float %src) {
788 ; SDAG-GFX11-LABEL: v_fcmp_f32_uge:
789 ; SDAG-GFX11: ; %bb.0:
790 ; SDAG-GFX11-NEXT: s_clause 0x1
791 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
792 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
793 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
794 ; SDAG-GFX11-NEXT: v_cmp_ngt_f32_e64 s2, 0x42c80000, s4
795 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
796 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
797 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
798 ; SDAG-GFX11-NEXT: s_nop 0
799 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
800 ; SDAG-GFX11-NEXT: s_endpgm
802 ; SDAG-GFX10-LABEL: v_fcmp_f32_uge:
803 ; SDAG-GFX10: ; %bb.0:
804 ; SDAG-GFX10-NEXT: s_clause 0x1
805 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
806 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
807 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
808 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
809 ; SDAG-GFX10-NEXT: v_cmp_ngt_f32_e64 s2, 0x42c80000, s4
810 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
811 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
812 ; SDAG-GFX10-NEXT: s_endpgm
814 ; GISEL-GFX11-LABEL: v_fcmp_f32_uge:
815 ; GISEL-GFX11: ; %bb.0:
816 ; GISEL-GFX11-NEXT: s_clause 0x1
817 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
818 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
819 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
820 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
821 ; GISEL-GFX11-NEXT: v_cmp_ngt_f32_e64 s2, 0x42c80000, s4
822 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
823 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
824 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
825 ; GISEL-GFX11-NEXT: s_nop 0
826 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
827 ; GISEL-GFX11-NEXT: s_endpgm
829 ; GISEL-GFX10-LABEL: v_fcmp_f32_uge:
830 ; GISEL-GFX10: ; %bb.0:
831 ; GISEL-GFX10-NEXT: s_clause 0x1
832 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
833 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
834 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
835 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
836 ; GISEL-GFX10-NEXT: v_cmp_ngt_f32_e64 s2, 0x42c80000, s4
837 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
838 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
839 ; GISEL-GFX10-NEXT: s_endpgm
840 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 11)
841 store i32 %result, ptr addrspace(1) %out
845 define amdgpu_kernel void @v_fcmp_f32_ult(ptr addrspace(1) %out, float %src) {
846 ; SDAG-GFX11-LABEL: v_fcmp_f32_ult:
847 ; SDAG-GFX11: ; %bb.0:
848 ; SDAG-GFX11-NEXT: s_clause 0x1
849 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
850 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
851 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
852 ; SDAG-GFX11-NEXT: v_cmp_nle_f32_e64 s2, 0x42c80000, s4
853 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
854 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
855 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
856 ; SDAG-GFX11-NEXT: s_nop 0
857 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
858 ; SDAG-GFX11-NEXT: s_endpgm
860 ; SDAG-GFX10-LABEL: v_fcmp_f32_ult:
861 ; SDAG-GFX10: ; %bb.0:
862 ; SDAG-GFX10-NEXT: s_clause 0x1
863 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
864 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
865 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
866 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
867 ; SDAG-GFX10-NEXT: v_cmp_nle_f32_e64 s2, 0x42c80000, s4
868 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
869 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
870 ; SDAG-GFX10-NEXT: s_endpgm
872 ; GISEL-GFX11-LABEL: v_fcmp_f32_ult:
873 ; GISEL-GFX11: ; %bb.0:
874 ; GISEL-GFX11-NEXT: s_clause 0x1
875 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
876 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
877 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
878 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
879 ; GISEL-GFX11-NEXT: v_cmp_nle_f32_e64 s2, 0x42c80000, s4
880 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
881 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
882 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
883 ; GISEL-GFX11-NEXT: s_nop 0
884 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
885 ; GISEL-GFX11-NEXT: s_endpgm
887 ; GISEL-GFX10-LABEL: v_fcmp_f32_ult:
888 ; GISEL-GFX10: ; %bb.0:
889 ; GISEL-GFX10-NEXT: s_clause 0x1
890 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
891 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
892 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
893 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
894 ; GISEL-GFX10-NEXT: v_cmp_nle_f32_e64 s2, 0x42c80000, s4
895 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
896 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
897 ; GISEL-GFX10-NEXT: s_endpgm
898 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 12)
899 store i32 %result, ptr addrspace(1) %out
903 define amdgpu_kernel void @v_fcmp_f32_ule(ptr addrspace(1) %out, float %src) {
904 ; SDAG-GFX11-LABEL: v_fcmp_f32_ule:
905 ; SDAG-GFX11: ; %bb.0:
906 ; SDAG-GFX11-NEXT: s_clause 0x1
907 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
908 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
909 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
910 ; SDAG-GFX11-NEXT: v_cmp_nlt_f32_e64 s2, 0x42c80000, s4
911 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
912 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
913 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
914 ; SDAG-GFX11-NEXT: s_nop 0
915 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
916 ; SDAG-GFX11-NEXT: s_endpgm
918 ; SDAG-GFX10-LABEL: v_fcmp_f32_ule:
919 ; SDAG-GFX10: ; %bb.0:
920 ; SDAG-GFX10-NEXT: s_clause 0x1
921 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
922 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
923 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
924 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
925 ; SDAG-GFX10-NEXT: v_cmp_nlt_f32_e64 s2, 0x42c80000, s4
926 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
927 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
928 ; SDAG-GFX10-NEXT: s_endpgm
930 ; GISEL-GFX11-LABEL: v_fcmp_f32_ule:
931 ; GISEL-GFX11: ; %bb.0:
932 ; GISEL-GFX11-NEXT: s_clause 0x1
933 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
934 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
935 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
936 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
937 ; GISEL-GFX11-NEXT: v_cmp_nlt_f32_e64 s2, 0x42c80000, s4
938 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
939 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
940 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
941 ; GISEL-GFX11-NEXT: s_nop 0
942 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
943 ; GISEL-GFX11-NEXT: s_endpgm
945 ; GISEL-GFX10-LABEL: v_fcmp_f32_ule:
946 ; GISEL-GFX10: ; %bb.0:
947 ; GISEL-GFX10-NEXT: s_clause 0x1
948 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
949 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
950 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
951 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
952 ; GISEL-GFX10-NEXT: v_cmp_nlt_f32_e64 s2, 0x42c80000, s4
953 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
954 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
955 ; GISEL-GFX10-NEXT: s_endpgm
956 %result = call i32 @llvm.amdgcn.fcmp.f32(float %src, float 100.00, i32 13)
957 store i32 %result, ptr addrspace(1) %out
961 define amdgpu_kernel void @v_fcmp_f64_oeq(ptr addrspace(1) %out, double %src) {
962 ; SDAG-GFX11-LABEL: v_fcmp_f64_oeq:
963 ; SDAG-GFX11: ; %bb.0:
964 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
965 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
966 ; SDAG-GFX11-NEXT: v_cmp_eq_f64_e64 s2, 0x40590000, s[2:3]
967 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
968 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
969 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
970 ; SDAG-GFX11-NEXT: s_nop 0
971 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
972 ; SDAG-GFX11-NEXT: s_endpgm
974 ; SDAG-GFX10-LABEL: v_fcmp_f64_oeq:
975 ; SDAG-GFX10: ; %bb.0:
976 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
977 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
978 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
979 ; SDAG-GFX10-NEXT: v_cmp_eq_f64_e64 s0, 0x40590000, s[6:7]
980 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
981 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
982 ; SDAG-GFX10-NEXT: s_endpgm
984 ; GISEL-GFX11-LABEL: v_fcmp_f64_oeq:
985 ; GISEL-GFX11: ; %bb.0:
986 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
987 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
988 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
989 ; GISEL-GFX11-NEXT: v_cmp_eq_f64_e64 s2, 0x40590000, s[2:3]
990 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
991 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
992 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
993 ; GISEL-GFX11-NEXT: s_nop 0
994 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
995 ; GISEL-GFX11-NEXT: s_endpgm
997 ; GISEL-GFX10-LABEL: v_fcmp_f64_oeq:
998 ; GISEL-GFX10: ; %bb.0:
999 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1000 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1001 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1002 ; GISEL-GFX10-NEXT: v_cmp_eq_f64_e64 s0, 0x40590000, s[6:7]
1003 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1004 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1005 ; GISEL-GFX10-NEXT: s_endpgm
1006 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 1)
1007 store i32 %result, ptr addrspace(1) %out
1011 define amdgpu_kernel void @v_fcmp_f64_one(ptr addrspace(1) %out, double %src) {
1012 ; SDAG-GFX11-LABEL: v_fcmp_f64_one:
1013 ; SDAG-GFX11: ; %bb.0:
1014 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1015 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1016 ; SDAG-GFX11-NEXT: v_cmp_neq_f64_e64 s2, 0x40590000, s[2:3]
1017 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1018 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1019 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1020 ; SDAG-GFX11-NEXT: s_nop 0
1021 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1022 ; SDAG-GFX11-NEXT: s_endpgm
1024 ; SDAG-GFX10-LABEL: v_fcmp_f64_one:
1025 ; SDAG-GFX10: ; %bb.0:
1026 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1027 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1028 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1029 ; SDAG-GFX10-NEXT: v_cmp_neq_f64_e64 s0, 0x40590000, s[6:7]
1030 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1031 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1032 ; SDAG-GFX10-NEXT: s_endpgm
1034 ; GISEL-GFX11-LABEL: v_fcmp_f64_one:
1035 ; GISEL-GFX11: ; %bb.0:
1036 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1037 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1038 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1039 ; GISEL-GFX11-NEXT: v_cmp_neq_f64_e64 s2, 0x40590000, s[2:3]
1040 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1041 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1042 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1043 ; GISEL-GFX11-NEXT: s_nop 0
1044 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1045 ; GISEL-GFX11-NEXT: s_endpgm
1047 ; GISEL-GFX10-LABEL: v_fcmp_f64_one:
1048 ; GISEL-GFX10: ; %bb.0:
1049 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1050 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1051 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1052 ; GISEL-GFX10-NEXT: v_cmp_neq_f64_e64 s0, 0x40590000, s[6:7]
1053 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1054 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1055 ; GISEL-GFX10-NEXT: s_endpgm
1056 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 6)
1057 store i32 %result, ptr addrspace(1) %out
1061 define amdgpu_kernel void @v_fcmp_f64_ogt(ptr addrspace(1) %out, double %src) {
1062 ; SDAG-GFX11-LABEL: v_fcmp_f64_ogt:
1063 ; SDAG-GFX11: ; %bb.0:
1064 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1065 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1066 ; SDAG-GFX11-NEXT: v_cmp_lt_f64_e64 s2, 0x40590000, s[2:3]
1067 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1068 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1069 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1070 ; SDAG-GFX11-NEXT: s_nop 0
1071 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1072 ; SDAG-GFX11-NEXT: s_endpgm
1074 ; SDAG-GFX10-LABEL: v_fcmp_f64_ogt:
1075 ; SDAG-GFX10: ; %bb.0:
1076 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1077 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1078 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1079 ; SDAG-GFX10-NEXT: v_cmp_lt_f64_e64 s0, 0x40590000, s[6:7]
1080 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1081 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1082 ; SDAG-GFX10-NEXT: s_endpgm
1084 ; GISEL-GFX11-LABEL: v_fcmp_f64_ogt:
1085 ; GISEL-GFX11: ; %bb.0:
1086 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1087 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1088 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1089 ; GISEL-GFX11-NEXT: v_cmp_lt_f64_e64 s2, 0x40590000, s[2:3]
1090 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1091 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1092 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1093 ; GISEL-GFX11-NEXT: s_nop 0
1094 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1095 ; GISEL-GFX11-NEXT: s_endpgm
1097 ; GISEL-GFX10-LABEL: v_fcmp_f64_ogt:
1098 ; GISEL-GFX10: ; %bb.0:
1099 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1100 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1101 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1102 ; GISEL-GFX10-NEXT: v_cmp_lt_f64_e64 s0, 0x40590000, s[6:7]
1103 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1104 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1105 ; GISEL-GFX10-NEXT: s_endpgm
1106 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 2)
1107 store i32 %result, ptr addrspace(1) %out
1111 define amdgpu_kernel void @v_fcmp_f64_oge(ptr addrspace(1) %out, double %src) {
1112 ; SDAG-GFX11-LABEL: v_fcmp_f64_oge:
1113 ; SDAG-GFX11: ; %bb.0:
1114 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1115 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1116 ; SDAG-GFX11-NEXT: v_cmp_le_f64_e64 s2, 0x40590000, s[2:3]
1117 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1118 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1119 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1120 ; SDAG-GFX11-NEXT: s_nop 0
1121 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1122 ; SDAG-GFX11-NEXT: s_endpgm
1124 ; SDAG-GFX10-LABEL: v_fcmp_f64_oge:
1125 ; SDAG-GFX10: ; %bb.0:
1126 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1127 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1128 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1129 ; SDAG-GFX10-NEXT: v_cmp_le_f64_e64 s0, 0x40590000, s[6:7]
1130 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1131 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1132 ; SDAG-GFX10-NEXT: s_endpgm
1134 ; GISEL-GFX11-LABEL: v_fcmp_f64_oge:
1135 ; GISEL-GFX11: ; %bb.0:
1136 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1137 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1138 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1139 ; GISEL-GFX11-NEXT: v_cmp_le_f64_e64 s2, 0x40590000, s[2:3]
1140 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1141 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1142 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1143 ; GISEL-GFX11-NEXT: s_nop 0
1144 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1145 ; GISEL-GFX11-NEXT: s_endpgm
1147 ; GISEL-GFX10-LABEL: v_fcmp_f64_oge:
1148 ; GISEL-GFX10: ; %bb.0:
1149 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1150 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1151 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1152 ; GISEL-GFX10-NEXT: v_cmp_le_f64_e64 s0, 0x40590000, s[6:7]
1153 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1154 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1155 ; GISEL-GFX10-NEXT: s_endpgm
1156 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 3)
1157 store i32 %result, ptr addrspace(1) %out
1161 define amdgpu_kernel void @v_fcmp_f64_olt(ptr addrspace(1) %out, double %src) {
1162 ; SDAG-GFX11-LABEL: v_fcmp_f64_olt:
1163 ; SDAG-GFX11: ; %bb.0:
1164 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1165 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1166 ; SDAG-GFX11-NEXT: v_cmp_gt_f64_e64 s2, 0x40590000, s[2:3]
1167 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1168 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1169 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1170 ; SDAG-GFX11-NEXT: s_nop 0
1171 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1172 ; SDAG-GFX11-NEXT: s_endpgm
1174 ; SDAG-GFX10-LABEL: v_fcmp_f64_olt:
1175 ; SDAG-GFX10: ; %bb.0:
1176 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1177 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1178 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1179 ; SDAG-GFX10-NEXT: v_cmp_gt_f64_e64 s0, 0x40590000, s[6:7]
1180 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1181 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1182 ; SDAG-GFX10-NEXT: s_endpgm
1184 ; GISEL-GFX11-LABEL: v_fcmp_f64_olt:
1185 ; GISEL-GFX11: ; %bb.0:
1186 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1187 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1188 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1189 ; GISEL-GFX11-NEXT: v_cmp_gt_f64_e64 s2, 0x40590000, s[2:3]
1190 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1191 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1192 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1193 ; GISEL-GFX11-NEXT: s_nop 0
1194 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1195 ; GISEL-GFX11-NEXT: s_endpgm
1197 ; GISEL-GFX10-LABEL: v_fcmp_f64_olt:
1198 ; GISEL-GFX10: ; %bb.0:
1199 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1200 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1201 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1202 ; GISEL-GFX10-NEXT: v_cmp_gt_f64_e64 s0, 0x40590000, s[6:7]
1203 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1204 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1205 ; GISEL-GFX10-NEXT: s_endpgm
1206 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 4)
1207 store i32 %result, ptr addrspace(1) %out
1211 define amdgpu_kernel void @v_fcmp_f64_ole(ptr addrspace(1) %out, double %src) {
1212 ; SDAG-GFX11-LABEL: v_fcmp_f64_ole:
1213 ; SDAG-GFX11: ; %bb.0:
1214 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1215 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1216 ; SDAG-GFX11-NEXT: v_cmp_ge_f64_e64 s2, 0x40590000, s[2:3]
1217 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1218 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1219 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1220 ; SDAG-GFX11-NEXT: s_nop 0
1221 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1222 ; SDAG-GFX11-NEXT: s_endpgm
1224 ; SDAG-GFX10-LABEL: v_fcmp_f64_ole:
1225 ; SDAG-GFX10: ; %bb.0:
1226 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1227 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1228 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1229 ; SDAG-GFX10-NEXT: v_cmp_ge_f64_e64 s0, 0x40590000, s[6:7]
1230 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1231 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1232 ; SDAG-GFX10-NEXT: s_endpgm
1234 ; GISEL-GFX11-LABEL: v_fcmp_f64_ole:
1235 ; GISEL-GFX11: ; %bb.0:
1236 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1237 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1238 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1239 ; GISEL-GFX11-NEXT: v_cmp_ge_f64_e64 s2, 0x40590000, s[2:3]
1240 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1241 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1242 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1243 ; GISEL-GFX11-NEXT: s_nop 0
1244 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1245 ; GISEL-GFX11-NEXT: s_endpgm
1247 ; GISEL-GFX10-LABEL: v_fcmp_f64_ole:
1248 ; GISEL-GFX10: ; %bb.0:
1249 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1250 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1251 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1252 ; GISEL-GFX10-NEXT: v_cmp_ge_f64_e64 s0, 0x40590000, s[6:7]
1253 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1254 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1255 ; GISEL-GFX10-NEXT: s_endpgm
1256 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 5)
1257 store i32 %result, ptr addrspace(1) %out
1261 define amdgpu_kernel void @v_fcmp_f64_ueq(ptr addrspace(1) %out, double %src) {
1262 ; SDAG-GFX11-LABEL: v_fcmp_f64_ueq:
1263 ; SDAG-GFX11: ; %bb.0:
1264 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1265 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1266 ; SDAG-GFX11-NEXT: v_cmp_nlg_f64_e64 s2, 0x40590000, s[2:3]
1267 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1268 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1269 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1270 ; SDAG-GFX11-NEXT: s_nop 0
1271 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1272 ; SDAG-GFX11-NEXT: s_endpgm
1274 ; SDAG-GFX10-LABEL: v_fcmp_f64_ueq:
1275 ; SDAG-GFX10: ; %bb.0:
1276 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1277 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1278 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1279 ; SDAG-GFX10-NEXT: v_cmp_nlg_f64_e64 s0, 0x40590000, s[6:7]
1280 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1281 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1282 ; SDAG-GFX10-NEXT: s_endpgm
1284 ; GISEL-GFX11-LABEL: v_fcmp_f64_ueq:
1285 ; GISEL-GFX11: ; %bb.0:
1286 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1287 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1288 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1289 ; GISEL-GFX11-NEXT: v_cmp_nlg_f64_e64 s2, 0x40590000, s[2:3]
1290 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1291 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1292 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1293 ; GISEL-GFX11-NEXT: s_nop 0
1294 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1295 ; GISEL-GFX11-NEXT: s_endpgm
1297 ; GISEL-GFX10-LABEL: v_fcmp_f64_ueq:
1298 ; GISEL-GFX10: ; %bb.0:
1299 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1300 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1301 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1302 ; GISEL-GFX10-NEXT: v_cmp_nlg_f64_e64 s0, 0x40590000, s[6:7]
1303 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1304 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1305 ; GISEL-GFX10-NEXT: s_endpgm
1306 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 9)
1307 store i32 %result, ptr addrspace(1) %out
1311 define amdgpu_kernel void @v_fcmp_f64_o(ptr addrspace(1) %out, double %src) {
1312 ; SDAG-GFX11-LABEL: v_fcmp_f64_o:
1313 ; SDAG-GFX11: ; %bb.0:
1314 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1315 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1316 ; SDAG-GFX11-NEXT: v_cmp_o_f64_e64 s2, 0x40590000, s[2:3]
1317 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1318 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1319 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1320 ; SDAG-GFX11-NEXT: s_nop 0
1321 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1322 ; SDAG-GFX11-NEXT: s_endpgm
1324 ; SDAG-GFX10-LABEL: v_fcmp_f64_o:
1325 ; SDAG-GFX10: ; %bb.0:
1326 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1327 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1328 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1329 ; SDAG-GFX10-NEXT: v_cmp_o_f64_e64 s0, 0x40590000, s[6:7]
1330 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1331 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1332 ; SDAG-GFX10-NEXT: s_endpgm
1334 ; GISEL-GFX11-LABEL: v_fcmp_f64_o:
1335 ; GISEL-GFX11: ; %bb.0:
1336 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1337 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1338 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1339 ; GISEL-GFX11-NEXT: v_cmp_o_f64_e64 s2, 0x40590000, s[2:3]
1340 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1341 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1342 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1343 ; GISEL-GFX11-NEXT: s_nop 0
1344 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1345 ; GISEL-GFX11-NEXT: s_endpgm
1347 ; GISEL-GFX10-LABEL: v_fcmp_f64_o:
1348 ; GISEL-GFX10: ; %bb.0:
1349 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1350 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1351 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1352 ; GISEL-GFX10-NEXT: v_cmp_o_f64_e64 s0, 0x40590000, s[6:7]
1353 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1354 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1355 ; GISEL-GFX10-NEXT: s_endpgm
1356 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 7)
1357 store i32 %result, ptr addrspace(1) %out
1361 define amdgpu_kernel void @v_fcmp_f64_uo(ptr addrspace(1) %out, double %src) {
1362 ; SDAG-GFX11-LABEL: v_fcmp_f64_uo:
1363 ; SDAG-GFX11: ; %bb.0:
1364 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1365 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1366 ; SDAG-GFX11-NEXT: v_cmp_u_f64_e64 s2, 0x40590000, s[2:3]
1367 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1368 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1369 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1370 ; SDAG-GFX11-NEXT: s_nop 0
1371 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1372 ; SDAG-GFX11-NEXT: s_endpgm
1374 ; SDAG-GFX10-LABEL: v_fcmp_f64_uo:
1375 ; SDAG-GFX10: ; %bb.0:
1376 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1377 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1378 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1379 ; SDAG-GFX10-NEXT: v_cmp_u_f64_e64 s0, 0x40590000, s[6:7]
1380 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1381 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1382 ; SDAG-GFX10-NEXT: s_endpgm
1384 ; GISEL-GFX11-LABEL: v_fcmp_f64_uo:
1385 ; GISEL-GFX11: ; %bb.0:
1386 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1387 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1388 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1389 ; GISEL-GFX11-NEXT: v_cmp_u_f64_e64 s2, 0x40590000, s[2:3]
1390 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1391 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1392 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1393 ; GISEL-GFX11-NEXT: s_nop 0
1394 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1395 ; GISEL-GFX11-NEXT: s_endpgm
1397 ; GISEL-GFX10-LABEL: v_fcmp_f64_uo:
1398 ; GISEL-GFX10: ; %bb.0:
1399 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1400 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1401 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1402 ; GISEL-GFX10-NEXT: v_cmp_u_f64_e64 s0, 0x40590000, s[6:7]
1403 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1404 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1405 ; GISEL-GFX10-NEXT: s_endpgm
1406 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 8)
1407 store i32 %result, ptr addrspace(1) %out
1411 define amdgpu_kernel void @v_fcmp_f64_une(ptr addrspace(1) %out, double %src) {
1412 ; SDAG-GFX11-LABEL: v_fcmp_f64_une:
1413 ; SDAG-GFX11: ; %bb.0:
1414 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1415 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1416 ; SDAG-GFX11-NEXT: v_cmp_neq_f64_e64 s2, 0x40590000, s[2:3]
1417 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1418 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1419 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1420 ; SDAG-GFX11-NEXT: s_nop 0
1421 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1422 ; SDAG-GFX11-NEXT: s_endpgm
1424 ; SDAG-GFX10-LABEL: v_fcmp_f64_une:
1425 ; SDAG-GFX10: ; %bb.0:
1426 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1427 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1428 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1429 ; SDAG-GFX10-NEXT: v_cmp_neq_f64_e64 s0, 0x40590000, s[6:7]
1430 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1431 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1432 ; SDAG-GFX10-NEXT: s_endpgm
1434 ; GISEL-GFX11-LABEL: v_fcmp_f64_une:
1435 ; GISEL-GFX11: ; %bb.0:
1436 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1437 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1438 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1439 ; GISEL-GFX11-NEXT: v_cmp_neq_f64_e64 s2, 0x40590000, s[2:3]
1440 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1441 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1442 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1443 ; GISEL-GFX11-NEXT: s_nop 0
1444 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1445 ; GISEL-GFX11-NEXT: s_endpgm
1447 ; GISEL-GFX10-LABEL: v_fcmp_f64_une:
1448 ; GISEL-GFX10: ; %bb.0:
1449 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1450 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1451 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1452 ; GISEL-GFX10-NEXT: v_cmp_neq_f64_e64 s0, 0x40590000, s[6:7]
1453 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1454 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1455 ; GISEL-GFX10-NEXT: s_endpgm
1456 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 14)
1457 store i32 %result, ptr addrspace(1) %out
1461 define amdgpu_kernel void @v_fcmp_f64_ugt(ptr addrspace(1) %out, double %src) {
1462 ; SDAG-GFX11-LABEL: v_fcmp_f64_ugt:
1463 ; SDAG-GFX11: ; %bb.0:
1464 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1465 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1466 ; SDAG-GFX11-NEXT: v_cmp_nge_f64_e64 s2, 0x40590000, s[2:3]
1467 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1468 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1469 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1470 ; SDAG-GFX11-NEXT: s_nop 0
1471 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1472 ; SDAG-GFX11-NEXT: s_endpgm
1474 ; SDAG-GFX10-LABEL: v_fcmp_f64_ugt:
1475 ; SDAG-GFX10: ; %bb.0:
1476 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1477 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1478 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1479 ; SDAG-GFX10-NEXT: v_cmp_nge_f64_e64 s0, 0x40590000, s[6:7]
1480 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1481 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1482 ; SDAG-GFX10-NEXT: s_endpgm
1484 ; GISEL-GFX11-LABEL: v_fcmp_f64_ugt:
1485 ; GISEL-GFX11: ; %bb.0:
1486 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1487 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1488 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1489 ; GISEL-GFX11-NEXT: v_cmp_nge_f64_e64 s2, 0x40590000, s[2:3]
1490 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1491 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1492 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1493 ; GISEL-GFX11-NEXT: s_nop 0
1494 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1495 ; GISEL-GFX11-NEXT: s_endpgm
1497 ; GISEL-GFX10-LABEL: v_fcmp_f64_ugt:
1498 ; GISEL-GFX10: ; %bb.0:
1499 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1500 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1501 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1502 ; GISEL-GFX10-NEXT: v_cmp_nge_f64_e64 s0, 0x40590000, s[6:7]
1503 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1504 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1505 ; GISEL-GFX10-NEXT: s_endpgm
1506 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 10)
1507 store i32 %result, ptr addrspace(1) %out
1511 define amdgpu_kernel void @v_fcmp_f64_uge(ptr addrspace(1) %out, double %src) {
1512 ; SDAG-GFX11-LABEL: v_fcmp_f64_uge:
1513 ; SDAG-GFX11: ; %bb.0:
1514 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1515 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1516 ; SDAG-GFX11-NEXT: v_cmp_ngt_f64_e64 s2, 0x40590000, s[2:3]
1517 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1518 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1519 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1520 ; SDAG-GFX11-NEXT: s_nop 0
1521 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1522 ; SDAG-GFX11-NEXT: s_endpgm
1524 ; SDAG-GFX10-LABEL: v_fcmp_f64_uge:
1525 ; SDAG-GFX10: ; %bb.0:
1526 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1527 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1528 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1529 ; SDAG-GFX10-NEXT: v_cmp_ngt_f64_e64 s0, 0x40590000, s[6:7]
1530 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1531 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1532 ; SDAG-GFX10-NEXT: s_endpgm
1534 ; GISEL-GFX11-LABEL: v_fcmp_f64_uge:
1535 ; GISEL-GFX11: ; %bb.0:
1536 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1537 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1538 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1539 ; GISEL-GFX11-NEXT: v_cmp_ngt_f64_e64 s2, 0x40590000, s[2:3]
1540 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1541 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1542 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1543 ; GISEL-GFX11-NEXT: s_nop 0
1544 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1545 ; GISEL-GFX11-NEXT: s_endpgm
1547 ; GISEL-GFX10-LABEL: v_fcmp_f64_uge:
1548 ; GISEL-GFX10: ; %bb.0:
1549 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1550 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1551 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1552 ; GISEL-GFX10-NEXT: v_cmp_ngt_f64_e64 s0, 0x40590000, s[6:7]
1553 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1554 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1555 ; GISEL-GFX10-NEXT: s_endpgm
1556 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 11)
1557 store i32 %result, ptr addrspace(1) %out
1561 define amdgpu_kernel void @v_fcmp_f64_ult(ptr addrspace(1) %out, double %src) {
1562 ; SDAG-GFX11-LABEL: v_fcmp_f64_ult:
1563 ; SDAG-GFX11: ; %bb.0:
1564 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1565 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1566 ; SDAG-GFX11-NEXT: v_cmp_nle_f64_e64 s2, 0x40590000, s[2:3]
1567 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1568 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1569 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1570 ; SDAG-GFX11-NEXT: s_nop 0
1571 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1572 ; SDAG-GFX11-NEXT: s_endpgm
1574 ; SDAG-GFX10-LABEL: v_fcmp_f64_ult:
1575 ; SDAG-GFX10: ; %bb.0:
1576 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1577 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1578 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1579 ; SDAG-GFX10-NEXT: v_cmp_nle_f64_e64 s0, 0x40590000, s[6:7]
1580 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1581 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1582 ; SDAG-GFX10-NEXT: s_endpgm
1584 ; GISEL-GFX11-LABEL: v_fcmp_f64_ult:
1585 ; GISEL-GFX11: ; %bb.0:
1586 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1587 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1588 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1589 ; GISEL-GFX11-NEXT: v_cmp_nle_f64_e64 s2, 0x40590000, s[2:3]
1590 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1591 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1592 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1593 ; GISEL-GFX11-NEXT: s_nop 0
1594 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1595 ; GISEL-GFX11-NEXT: s_endpgm
1597 ; GISEL-GFX10-LABEL: v_fcmp_f64_ult:
1598 ; GISEL-GFX10: ; %bb.0:
1599 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1600 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1601 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1602 ; GISEL-GFX10-NEXT: v_cmp_nle_f64_e64 s0, 0x40590000, s[6:7]
1603 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1604 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1605 ; GISEL-GFX10-NEXT: s_endpgm
1606 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 12)
1607 store i32 %result, ptr addrspace(1) %out
1611 define amdgpu_kernel void @v_fcmp_f64_ule(ptr addrspace(1) %out, double %src) {
1612 ; SDAG-GFX11-LABEL: v_fcmp_f64_ule:
1613 ; SDAG-GFX11: ; %bb.0:
1614 ; SDAG-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1615 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1616 ; SDAG-GFX11-NEXT: v_cmp_nlt_f64_e64 s2, 0x40590000, s[2:3]
1617 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1618 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1619 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1620 ; SDAG-GFX11-NEXT: s_nop 0
1621 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1622 ; SDAG-GFX11-NEXT: s_endpgm
1624 ; SDAG-GFX10-LABEL: v_fcmp_f64_ule:
1625 ; SDAG-GFX10: ; %bb.0:
1626 ; SDAG-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1627 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1628 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1629 ; SDAG-GFX10-NEXT: v_cmp_nlt_f64_e64 s0, 0x40590000, s[6:7]
1630 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s0
1631 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[4:5]
1632 ; SDAG-GFX10-NEXT: s_endpgm
1634 ; GISEL-GFX11-LABEL: v_fcmp_f64_ule:
1635 ; GISEL-GFX11: ; %bb.0:
1636 ; GISEL-GFX11-NEXT: s_load_b128 s[0:3], s[2:3], 0x24
1637 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1638 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1639 ; GISEL-GFX11-NEXT: v_cmp_nlt_f64_e64 s2, 0x40590000, s[2:3]
1640 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1641 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1642 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1643 ; GISEL-GFX11-NEXT: s_nop 0
1644 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1645 ; GISEL-GFX11-NEXT: s_endpgm
1647 ; GISEL-GFX10-LABEL: v_fcmp_f64_ule:
1648 ; GISEL-GFX10: ; %bb.0:
1649 ; GISEL-GFX10-NEXT: s_load_dwordx4 s[4:7], s[2:3], 0x24
1650 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1651 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1652 ; GISEL-GFX10-NEXT: v_cmp_nlt_f64_e64 s0, 0x40590000, s[6:7]
1653 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s0
1654 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[4:5]
1655 ; GISEL-GFX10-NEXT: s_endpgm
1656 %result = call i32 @llvm.amdgcn.fcmp.f64(double %src, double 100.00, i32 13)
1657 store i32 %result, ptr addrspace(1) %out
1662 define amdgpu_kernel void @v_fcmp_f16_oeq_with_fabs(ptr addrspace(1) %out, half %src, half %a) {
1663 ; SDAG-GFX11-LABEL: v_fcmp_f16_oeq_with_fabs:
1664 ; SDAG-GFX11: ; %bb.0:
1665 ; SDAG-GFX11-NEXT: s_clause 0x1
1666 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1667 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1668 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1669 ; SDAG-GFX11-NEXT: s_lshr_b32 s2, s4, 16
1670 ; SDAG-GFX11-NEXT: s_delay_alu instid0(SALU_CYCLE_1) | instskip(NEXT) | instid1(VALU_DEP_1)
1671 ; SDAG-GFX11-NEXT: v_cmp_eq_f16_e64 s2, s4, |s2|
1672 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1673 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1674 ; SDAG-GFX11-NEXT: s_nop 0
1675 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1676 ; SDAG-GFX11-NEXT: s_endpgm
1678 ; SDAG-GFX10-LABEL: v_fcmp_f16_oeq_with_fabs:
1679 ; SDAG-GFX10: ; %bb.0:
1680 ; SDAG-GFX10-NEXT: s_clause 0x1
1681 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1682 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1683 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1684 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1685 ; SDAG-GFX10-NEXT: s_lshr_b32 s2, s4, 16
1686 ; SDAG-GFX10-NEXT: v_cmp_eq_f16_e64 s2, s4, |s2|
1687 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
1688 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
1689 ; SDAG-GFX10-NEXT: s_endpgm
1691 ; GISEL-GFX11-LABEL: v_fcmp_f16_oeq_with_fabs:
1692 ; GISEL-GFX11: ; %bb.0:
1693 ; GISEL-GFX11-NEXT: s_clause 0x1
1694 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1695 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1696 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1697 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1698 ; GISEL-GFX11-NEXT: s_lshr_b32 s2, s4, 16
1699 ; GISEL-GFX11-NEXT: s_delay_alu instid0(SALU_CYCLE_1) | instskip(NEXT) | instid1(VALU_DEP_1)
1700 ; GISEL-GFX11-NEXT: v_cmp_eq_f16_e64 s2, s4, |s2|
1701 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1702 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1703 ; GISEL-GFX11-NEXT: s_nop 0
1704 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1705 ; GISEL-GFX11-NEXT: s_endpgm
1707 ; GISEL-GFX10-LABEL: v_fcmp_f16_oeq_with_fabs:
1708 ; GISEL-GFX10: ; %bb.0:
1709 ; GISEL-GFX10-NEXT: s_clause 0x1
1710 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1711 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1712 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1713 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1714 ; GISEL-GFX10-NEXT: s_lshr_b32 s2, s4, 16
1715 ; GISEL-GFX10-NEXT: v_cmp_eq_f16_e64 s2, s4, |s2|
1716 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
1717 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
1718 ; GISEL-GFX10-NEXT: s_endpgm
1719 %temp = call half @llvm.fabs.f16(half %a)
1720 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half %temp, i32 1)
1721 store i32 %result, ptr addrspace(1) %out
1726 define amdgpu_kernel void @v_fcmp_f16_oeq_both_operands_with_fabs(ptr addrspace(1) %out, half %src, half %a) {
1727 ; SDAG-GFX11-LABEL: v_fcmp_f16_oeq_both_operands_with_fabs:
1728 ; SDAG-GFX11: ; %bb.0:
1729 ; SDAG-GFX11-NEXT: s_clause 0x1
1730 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1731 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1732 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1733 ; SDAG-GFX11-NEXT: s_lshr_b32 s2, s4, 16
1734 ; SDAG-GFX11-NEXT: s_delay_alu instid0(SALU_CYCLE_1) | instskip(NEXT) | instid1(VALU_DEP_1)
1735 ; SDAG-GFX11-NEXT: v_cmp_eq_f16_e64 s2, |s4|, |s2|
1736 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1737 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1738 ; SDAG-GFX11-NEXT: s_nop 0
1739 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1740 ; SDAG-GFX11-NEXT: s_endpgm
1742 ; SDAG-GFX10-LABEL: v_fcmp_f16_oeq_both_operands_with_fabs:
1743 ; SDAG-GFX10: ; %bb.0:
1744 ; SDAG-GFX10-NEXT: s_clause 0x1
1745 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1746 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1747 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1748 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1749 ; SDAG-GFX10-NEXT: s_lshr_b32 s2, s4, 16
1750 ; SDAG-GFX10-NEXT: v_cmp_eq_f16_e64 s2, |s4|, |s2|
1751 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
1752 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
1753 ; SDAG-GFX10-NEXT: s_endpgm
1755 ; GISEL-GFX11-LABEL: v_fcmp_f16_oeq_both_operands_with_fabs:
1756 ; GISEL-GFX11: ; %bb.0:
1757 ; GISEL-GFX11-NEXT: s_clause 0x1
1758 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1759 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1760 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1761 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1762 ; GISEL-GFX11-NEXT: s_lshr_b32 s2, s4, 16
1763 ; GISEL-GFX11-NEXT: s_delay_alu instid0(SALU_CYCLE_1) | instskip(NEXT) | instid1(VALU_DEP_1)
1764 ; GISEL-GFX11-NEXT: v_cmp_eq_f16_e64 s2, |s4|, |s2|
1765 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1766 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1767 ; GISEL-GFX11-NEXT: s_nop 0
1768 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1769 ; GISEL-GFX11-NEXT: s_endpgm
1771 ; GISEL-GFX10-LABEL: v_fcmp_f16_oeq_both_operands_with_fabs:
1772 ; GISEL-GFX10: ; %bb.0:
1773 ; GISEL-GFX10-NEXT: s_clause 0x1
1774 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1775 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1776 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1777 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1778 ; GISEL-GFX10-NEXT: s_lshr_b32 s2, s4, 16
1779 ; GISEL-GFX10-NEXT: v_cmp_eq_f16_e64 s2, |s4|, |s2|
1780 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
1781 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
1782 ; GISEL-GFX10-NEXT: s_endpgm
1783 %temp = call half @llvm.fabs.f16(half %a)
1784 %src_input = call half @llvm.fabs.f16(half %src)
1785 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src_input, half %temp, i32 1)
1786 store i32 %result, ptr addrspace(1) %out
1790 define amdgpu_kernel void @v_fcmp_f16(ptr addrspace(1) %out, half %src) {
1791 ; SDAG-GFX11-LABEL: v_fcmp_f16:
1792 ; SDAG-GFX11: ; %bb.0:
1793 ; SDAG-GFX11-NEXT: s_endpgm
1795 ; SDAG-GFX10-LABEL: v_fcmp_f16:
1796 ; SDAG-GFX10: ; %bb.0:
1797 ; SDAG-GFX10-NEXT: s_endpgm
1799 ; GISEL-GFX11-LABEL: v_fcmp_f16:
1800 ; GISEL-GFX11: ; %bb.0:
1801 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1802 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, 0
1803 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1804 ; GISEL-GFX11-NEXT: global_store_b32 v0, v0, s[0:1]
1805 ; GISEL-GFX11-NEXT: s_nop 0
1806 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1807 ; GISEL-GFX11-NEXT: s_endpgm
1809 ; GISEL-GFX10-LABEL: v_fcmp_f16:
1810 ; GISEL-GFX10: ; %bb.0:
1811 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1812 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, 0
1813 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1814 ; GISEL-GFX10-NEXT: global_store_dword v0, v0, s[0:1]
1815 ; GISEL-GFX10-NEXT: s_endpgm
1816 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 -1)
1817 store i32 %result, ptr addrspace(1) %out
1822 define amdgpu_kernel void @v_fcmp_f16_oeq(ptr addrspace(1) %out, half %src) {
1823 ; SDAG-GFX11-LABEL: v_fcmp_f16_oeq:
1824 ; SDAG-GFX11: ; %bb.0:
1825 ; SDAG-GFX11-NEXT: s_clause 0x1
1826 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1827 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1828 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1829 ; SDAG-GFX11-NEXT: v_cmp_eq_f16_e64 s2, 0x5640, s4
1830 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1831 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1832 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1833 ; SDAG-GFX11-NEXT: s_nop 0
1834 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1835 ; SDAG-GFX11-NEXT: s_endpgm
1837 ; SDAG-GFX10-LABEL: v_fcmp_f16_oeq:
1838 ; SDAG-GFX10: ; %bb.0:
1839 ; SDAG-GFX10-NEXT: s_clause 0x1
1840 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1841 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1842 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1843 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1844 ; SDAG-GFX10-NEXT: v_cmp_eq_f16_e64 s2, 0x5640, s4
1845 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
1846 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
1847 ; SDAG-GFX10-NEXT: s_endpgm
1849 ; GISEL-GFX11-LABEL: v_fcmp_f16_oeq:
1850 ; GISEL-GFX11: ; %bb.0:
1851 ; GISEL-GFX11-NEXT: s_clause 0x1
1852 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1853 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1854 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1855 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1856 ; GISEL-GFX11-NEXT: v_cmp_eq_f16_e64 s2, 0x5640, s4
1857 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1858 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1859 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1860 ; GISEL-GFX11-NEXT: s_nop 0
1861 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1862 ; GISEL-GFX11-NEXT: s_endpgm
1864 ; GISEL-GFX10-LABEL: v_fcmp_f16_oeq:
1865 ; GISEL-GFX10: ; %bb.0:
1866 ; GISEL-GFX10-NEXT: s_clause 0x1
1867 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1868 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1869 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1870 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1871 ; GISEL-GFX10-NEXT: v_cmp_eq_f16_e64 s2, 0x5640, s4
1872 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
1873 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
1874 ; GISEL-GFX10-NEXT: s_endpgm
1875 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 1)
1876 store i32 %result, ptr addrspace(1) %out
1881 define amdgpu_kernel void @v_fcmp_f16_one(ptr addrspace(1) %out, half %src) {
1882 ; SDAG-GFX11-LABEL: v_fcmp_f16_one:
1883 ; SDAG-GFX11: ; %bb.0:
1884 ; SDAG-GFX11-NEXT: s_clause 0x1
1885 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1886 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1887 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1888 ; SDAG-GFX11-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
1889 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1890 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1891 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1892 ; SDAG-GFX11-NEXT: s_nop 0
1893 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1894 ; SDAG-GFX11-NEXT: s_endpgm
1896 ; SDAG-GFX10-LABEL: v_fcmp_f16_one:
1897 ; SDAG-GFX10: ; %bb.0:
1898 ; SDAG-GFX10-NEXT: s_clause 0x1
1899 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1900 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1901 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1902 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1903 ; SDAG-GFX10-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
1904 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
1905 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
1906 ; SDAG-GFX10-NEXT: s_endpgm
1908 ; GISEL-GFX11-LABEL: v_fcmp_f16_one:
1909 ; GISEL-GFX11: ; %bb.0:
1910 ; GISEL-GFX11-NEXT: s_clause 0x1
1911 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1912 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1913 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1914 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1915 ; GISEL-GFX11-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
1916 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1917 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1918 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1919 ; GISEL-GFX11-NEXT: s_nop 0
1920 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1921 ; GISEL-GFX11-NEXT: s_endpgm
1923 ; GISEL-GFX10-LABEL: v_fcmp_f16_one:
1924 ; GISEL-GFX10: ; %bb.0:
1925 ; GISEL-GFX10-NEXT: s_clause 0x1
1926 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1927 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1928 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1929 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1930 ; GISEL-GFX10-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
1931 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
1932 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
1933 ; GISEL-GFX10-NEXT: s_endpgm
1934 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 6)
1935 store i32 %result, ptr addrspace(1) %out
1940 define amdgpu_kernel void @v_fcmp_f16_ogt(ptr addrspace(1) %out, half %src) {
1941 ; SDAG-GFX11-LABEL: v_fcmp_f16_ogt:
1942 ; SDAG-GFX11: ; %bb.0:
1943 ; SDAG-GFX11-NEXT: s_clause 0x1
1944 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1945 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1946 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1947 ; SDAG-GFX11-NEXT: v_cmp_lt_f16_e64 s2, 0x5640, s4
1948 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1949 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
1950 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
1951 ; SDAG-GFX11-NEXT: s_nop 0
1952 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1953 ; SDAG-GFX11-NEXT: s_endpgm
1955 ; SDAG-GFX10-LABEL: v_fcmp_f16_ogt:
1956 ; SDAG-GFX10: ; %bb.0:
1957 ; SDAG-GFX10-NEXT: s_clause 0x1
1958 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1959 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1960 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
1961 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1962 ; SDAG-GFX10-NEXT: v_cmp_lt_f16_e64 s2, 0x5640, s4
1963 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
1964 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
1965 ; SDAG-GFX10-NEXT: s_endpgm
1967 ; GISEL-GFX11-LABEL: v_fcmp_f16_ogt:
1968 ; GISEL-GFX11: ; %bb.0:
1969 ; GISEL-GFX11-NEXT: s_clause 0x1
1970 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
1971 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
1972 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
1973 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
1974 ; GISEL-GFX11-NEXT: v_cmp_lt_f16_e64 s2, 0x5640, s4
1975 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
1976 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
1977 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
1978 ; GISEL-GFX11-NEXT: s_nop 0
1979 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
1980 ; GISEL-GFX11-NEXT: s_endpgm
1982 ; GISEL-GFX10-LABEL: v_fcmp_f16_ogt:
1983 ; GISEL-GFX10: ; %bb.0:
1984 ; GISEL-GFX10-NEXT: s_clause 0x1
1985 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
1986 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
1987 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
1988 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
1989 ; GISEL-GFX10-NEXT: v_cmp_lt_f16_e64 s2, 0x5640, s4
1990 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
1991 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
1992 ; GISEL-GFX10-NEXT: s_endpgm
1993 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 2)
1994 store i32 %result, ptr addrspace(1) %out
1999 define amdgpu_kernel void @v_fcmp_f16_oge(ptr addrspace(1) %out, half %src) {
2000 ; SDAG-GFX11-LABEL: v_fcmp_f16_oge:
2001 ; SDAG-GFX11: ; %bb.0:
2002 ; SDAG-GFX11-NEXT: s_clause 0x1
2003 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2004 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2005 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2006 ; SDAG-GFX11-NEXT: v_cmp_le_f16_e64 s2, 0x5640, s4
2007 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2008 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2009 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2010 ; SDAG-GFX11-NEXT: s_nop 0
2011 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2012 ; SDAG-GFX11-NEXT: s_endpgm
2014 ; SDAG-GFX10-LABEL: v_fcmp_f16_oge:
2015 ; SDAG-GFX10: ; %bb.0:
2016 ; SDAG-GFX10-NEXT: s_clause 0x1
2017 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2018 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2019 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2020 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2021 ; SDAG-GFX10-NEXT: v_cmp_le_f16_e64 s2, 0x5640, s4
2022 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2023 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2024 ; SDAG-GFX10-NEXT: s_endpgm
2026 ; GISEL-GFX11-LABEL: v_fcmp_f16_oge:
2027 ; GISEL-GFX11: ; %bb.0:
2028 ; GISEL-GFX11-NEXT: s_clause 0x1
2029 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2030 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2031 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2032 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2033 ; GISEL-GFX11-NEXT: v_cmp_le_f16_e64 s2, 0x5640, s4
2034 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2035 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2036 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2037 ; GISEL-GFX11-NEXT: s_nop 0
2038 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2039 ; GISEL-GFX11-NEXT: s_endpgm
2041 ; GISEL-GFX10-LABEL: v_fcmp_f16_oge:
2042 ; GISEL-GFX10: ; %bb.0:
2043 ; GISEL-GFX10-NEXT: s_clause 0x1
2044 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2045 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2046 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2047 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2048 ; GISEL-GFX10-NEXT: v_cmp_le_f16_e64 s2, 0x5640, s4
2049 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2050 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2051 ; GISEL-GFX10-NEXT: s_endpgm
2052 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 3)
2053 store i32 %result, ptr addrspace(1) %out
2058 define amdgpu_kernel void @v_fcmp_f16_olt(ptr addrspace(1) %out, half %src) {
2059 ; SDAG-GFX11-LABEL: v_fcmp_f16_olt:
2060 ; SDAG-GFX11: ; %bb.0:
2061 ; SDAG-GFX11-NEXT: s_clause 0x1
2062 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2063 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2064 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2065 ; SDAG-GFX11-NEXT: v_cmp_gt_f16_e64 s2, 0x5640, s4
2066 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2067 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2068 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2069 ; SDAG-GFX11-NEXT: s_nop 0
2070 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2071 ; SDAG-GFX11-NEXT: s_endpgm
2073 ; SDAG-GFX10-LABEL: v_fcmp_f16_olt:
2074 ; SDAG-GFX10: ; %bb.0:
2075 ; SDAG-GFX10-NEXT: s_clause 0x1
2076 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2077 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2078 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2079 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2080 ; SDAG-GFX10-NEXT: v_cmp_gt_f16_e64 s2, 0x5640, s4
2081 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2082 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2083 ; SDAG-GFX10-NEXT: s_endpgm
2085 ; GISEL-GFX11-LABEL: v_fcmp_f16_olt:
2086 ; GISEL-GFX11: ; %bb.0:
2087 ; GISEL-GFX11-NEXT: s_clause 0x1
2088 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2089 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2090 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2091 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2092 ; GISEL-GFX11-NEXT: v_cmp_gt_f16_e64 s2, 0x5640, s4
2093 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2094 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2095 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2096 ; GISEL-GFX11-NEXT: s_nop 0
2097 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2098 ; GISEL-GFX11-NEXT: s_endpgm
2100 ; GISEL-GFX10-LABEL: v_fcmp_f16_olt:
2101 ; GISEL-GFX10: ; %bb.0:
2102 ; GISEL-GFX10-NEXT: s_clause 0x1
2103 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2104 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2105 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2106 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2107 ; GISEL-GFX10-NEXT: v_cmp_gt_f16_e64 s2, 0x5640, s4
2108 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2109 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2110 ; GISEL-GFX10-NEXT: s_endpgm
2111 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 4)
2112 store i32 %result, ptr addrspace(1) %out
2117 define amdgpu_kernel void @v_fcmp_f16_ole(ptr addrspace(1) %out, half %src) {
2118 ; SDAG-GFX11-LABEL: v_fcmp_f16_ole:
2119 ; SDAG-GFX11: ; %bb.0:
2120 ; SDAG-GFX11-NEXT: s_clause 0x1
2121 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2122 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2123 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2124 ; SDAG-GFX11-NEXT: v_cmp_ge_f16_e64 s2, 0x5640, s4
2125 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2126 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2127 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2128 ; SDAG-GFX11-NEXT: s_nop 0
2129 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2130 ; SDAG-GFX11-NEXT: s_endpgm
2132 ; SDAG-GFX10-LABEL: v_fcmp_f16_ole:
2133 ; SDAG-GFX10: ; %bb.0:
2134 ; SDAG-GFX10-NEXT: s_clause 0x1
2135 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2136 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2137 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2138 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2139 ; SDAG-GFX10-NEXT: v_cmp_ge_f16_e64 s2, 0x5640, s4
2140 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2141 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2142 ; SDAG-GFX10-NEXT: s_endpgm
2144 ; GISEL-GFX11-LABEL: v_fcmp_f16_ole:
2145 ; GISEL-GFX11: ; %bb.0:
2146 ; GISEL-GFX11-NEXT: s_clause 0x1
2147 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2148 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2149 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2150 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2151 ; GISEL-GFX11-NEXT: v_cmp_ge_f16_e64 s2, 0x5640, s4
2152 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2153 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2154 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2155 ; GISEL-GFX11-NEXT: s_nop 0
2156 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2157 ; GISEL-GFX11-NEXT: s_endpgm
2159 ; GISEL-GFX10-LABEL: v_fcmp_f16_ole:
2160 ; GISEL-GFX10: ; %bb.0:
2161 ; GISEL-GFX10-NEXT: s_clause 0x1
2162 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2163 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2164 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2165 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2166 ; GISEL-GFX10-NEXT: v_cmp_ge_f16_e64 s2, 0x5640, s4
2167 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2168 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2169 ; GISEL-GFX10-NEXT: s_endpgm
2170 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 5)
2171 store i32 %result, ptr addrspace(1) %out
2176 define amdgpu_kernel void @v_fcmp_f16_ueq(ptr addrspace(1) %out, half %src) {
2177 ; SDAG-GFX11-LABEL: v_fcmp_f16_ueq:
2178 ; SDAG-GFX11: ; %bb.0:
2179 ; SDAG-GFX11-NEXT: s_clause 0x1
2180 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2181 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2182 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2183 ; SDAG-GFX11-NEXT: v_cmp_nlg_f16_e64 s2, 0x5640, s4
2184 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2185 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2186 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2187 ; SDAG-GFX11-NEXT: s_nop 0
2188 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2189 ; SDAG-GFX11-NEXT: s_endpgm
2191 ; SDAG-GFX10-LABEL: v_fcmp_f16_ueq:
2192 ; SDAG-GFX10: ; %bb.0:
2193 ; SDAG-GFX10-NEXT: s_clause 0x1
2194 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2195 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2196 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2197 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2198 ; SDAG-GFX10-NEXT: v_cmp_nlg_f16_e64 s2, 0x5640, s4
2199 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2200 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2201 ; SDAG-GFX10-NEXT: s_endpgm
2203 ; GISEL-GFX11-LABEL: v_fcmp_f16_ueq:
2204 ; GISEL-GFX11: ; %bb.0:
2205 ; GISEL-GFX11-NEXT: s_clause 0x1
2206 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2207 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2208 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2209 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2210 ; GISEL-GFX11-NEXT: v_cmp_nlg_f16_e64 s2, 0x5640, s4
2211 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2212 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2213 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2214 ; GISEL-GFX11-NEXT: s_nop 0
2215 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2216 ; GISEL-GFX11-NEXT: s_endpgm
2218 ; GISEL-GFX10-LABEL: v_fcmp_f16_ueq:
2219 ; GISEL-GFX10: ; %bb.0:
2220 ; GISEL-GFX10-NEXT: s_clause 0x1
2221 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2222 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2223 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2224 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2225 ; GISEL-GFX10-NEXT: v_cmp_nlg_f16_e64 s2, 0x5640, s4
2226 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2227 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2228 ; GISEL-GFX10-NEXT: s_endpgm
2229 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 9)
2230 store i32 %result, ptr addrspace(1) %out
2235 define amdgpu_kernel void @v_fcmp_f16_une(ptr addrspace(1) %out, half %src) {
2236 ; SDAG-GFX11-LABEL: v_fcmp_f16_une:
2237 ; SDAG-GFX11: ; %bb.0:
2238 ; SDAG-GFX11-NEXT: s_clause 0x1
2239 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2240 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2241 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2242 ; SDAG-GFX11-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
2243 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2244 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2245 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2246 ; SDAG-GFX11-NEXT: s_nop 0
2247 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2248 ; SDAG-GFX11-NEXT: s_endpgm
2250 ; SDAG-GFX10-LABEL: v_fcmp_f16_une:
2251 ; SDAG-GFX10: ; %bb.0:
2252 ; SDAG-GFX10-NEXT: s_clause 0x1
2253 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2254 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2255 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2256 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2257 ; SDAG-GFX10-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
2258 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2259 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2260 ; SDAG-GFX10-NEXT: s_endpgm
2262 ; GISEL-GFX11-LABEL: v_fcmp_f16_une:
2263 ; GISEL-GFX11: ; %bb.0:
2264 ; GISEL-GFX11-NEXT: s_clause 0x1
2265 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2266 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2267 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2268 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2269 ; GISEL-GFX11-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
2270 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2271 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2272 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2273 ; GISEL-GFX11-NEXT: s_nop 0
2274 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2275 ; GISEL-GFX11-NEXT: s_endpgm
2277 ; GISEL-GFX10-LABEL: v_fcmp_f16_une:
2278 ; GISEL-GFX10: ; %bb.0:
2279 ; GISEL-GFX10-NEXT: s_clause 0x1
2280 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2281 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2282 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2283 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2284 ; GISEL-GFX10-NEXT: v_cmp_neq_f16_e64 s2, 0x5640, s4
2285 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2286 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2287 ; GISEL-GFX10-NEXT: s_endpgm
2288 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 14)
2289 store i32 %result, ptr addrspace(1) %out
2294 define amdgpu_kernel void @v_fcmp_f16_ugt(ptr addrspace(1) %out, half %src) {
2295 ; SDAG-GFX11-LABEL: v_fcmp_f16_ugt:
2296 ; SDAG-GFX11: ; %bb.0:
2297 ; SDAG-GFX11-NEXT: s_clause 0x1
2298 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2299 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2300 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2301 ; SDAG-GFX11-NEXT: v_cmp_nge_f16_e64 s2, 0x5640, s4
2302 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2303 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2304 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2305 ; SDAG-GFX11-NEXT: s_nop 0
2306 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2307 ; SDAG-GFX11-NEXT: s_endpgm
2309 ; SDAG-GFX10-LABEL: v_fcmp_f16_ugt:
2310 ; SDAG-GFX10: ; %bb.0:
2311 ; SDAG-GFX10-NEXT: s_clause 0x1
2312 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2313 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2314 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2315 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2316 ; SDAG-GFX10-NEXT: v_cmp_nge_f16_e64 s2, 0x5640, s4
2317 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2318 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2319 ; SDAG-GFX10-NEXT: s_endpgm
2321 ; GISEL-GFX11-LABEL: v_fcmp_f16_ugt:
2322 ; GISEL-GFX11: ; %bb.0:
2323 ; GISEL-GFX11-NEXT: s_clause 0x1
2324 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2325 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2326 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2327 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2328 ; GISEL-GFX11-NEXT: v_cmp_nge_f16_e64 s2, 0x5640, s4
2329 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2330 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2331 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2332 ; GISEL-GFX11-NEXT: s_nop 0
2333 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2334 ; GISEL-GFX11-NEXT: s_endpgm
2336 ; GISEL-GFX10-LABEL: v_fcmp_f16_ugt:
2337 ; GISEL-GFX10: ; %bb.0:
2338 ; GISEL-GFX10-NEXT: s_clause 0x1
2339 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2340 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2341 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2342 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2343 ; GISEL-GFX10-NEXT: v_cmp_nge_f16_e64 s2, 0x5640, s4
2344 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2345 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2346 ; GISEL-GFX10-NEXT: s_endpgm
2347 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 10)
2348 store i32 %result, ptr addrspace(1) %out
2353 define amdgpu_kernel void @v_fcmp_f16_uge(ptr addrspace(1) %out, half %src) {
2354 ; SDAG-GFX11-LABEL: v_fcmp_f16_uge:
2355 ; SDAG-GFX11: ; %bb.0:
2356 ; SDAG-GFX11-NEXT: s_clause 0x1
2357 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2358 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2359 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2360 ; SDAG-GFX11-NEXT: v_cmp_ngt_f16_e64 s2, 0x5640, s4
2361 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2362 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2363 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2364 ; SDAG-GFX11-NEXT: s_nop 0
2365 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2366 ; SDAG-GFX11-NEXT: s_endpgm
2368 ; SDAG-GFX10-LABEL: v_fcmp_f16_uge:
2369 ; SDAG-GFX10: ; %bb.0:
2370 ; SDAG-GFX10-NEXT: s_clause 0x1
2371 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2372 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2373 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2374 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2375 ; SDAG-GFX10-NEXT: v_cmp_ngt_f16_e64 s2, 0x5640, s4
2376 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2377 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2378 ; SDAG-GFX10-NEXT: s_endpgm
2380 ; GISEL-GFX11-LABEL: v_fcmp_f16_uge:
2381 ; GISEL-GFX11: ; %bb.0:
2382 ; GISEL-GFX11-NEXT: s_clause 0x1
2383 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2384 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2385 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2386 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2387 ; GISEL-GFX11-NEXT: v_cmp_ngt_f16_e64 s2, 0x5640, s4
2388 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2389 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2390 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2391 ; GISEL-GFX11-NEXT: s_nop 0
2392 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2393 ; GISEL-GFX11-NEXT: s_endpgm
2395 ; GISEL-GFX10-LABEL: v_fcmp_f16_uge:
2396 ; GISEL-GFX10: ; %bb.0:
2397 ; GISEL-GFX10-NEXT: s_clause 0x1
2398 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2399 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2400 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2401 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2402 ; GISEL-GFX10-NEXT: v_cmp_ngt_f16_e64 s2, 0x5640, s4
2403 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2404 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2405 ; GISEL-GFX10-NEXT: s_endpgm
2406 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 11)
2407 store i32 %result, ptr addrspace(1) %out
2412 define amdgpu_kernel void @v_fcmp_f16_ult(ptr addrspace(1) %out, half %src) {
2413 ; SDAG-GFX11-LABEL: v_fcmp_f16_ult:
2414 ; SDAG-GFX11: ; %bb.0:
2415 ; SDAG-GFX11-NEXT: s_clause 0x1
2416 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2417 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2418 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2419 ; SDAG-GFX11-NEXT: v_cmp_nle_f16_e64 s2, 0x5640, s4
2420 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2421 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2422 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2423 ; SDAG-GFX11-NEXT: s_nop 0
2424 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2425 ; SDAG-GFX11-NEXT: s_endpgm
2427 ; SDAG-GFX10-LABEL: v_fcmp_f16_ult:
2428 ; SDAG-GFX10: ; %bb.0:
2429 ; SDAG-GFX10-NEXT: s_clause 0x1
2430 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2431 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2432 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2433 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2434 ; SDAG-GFX10-NEXT: v_cmp_nle_f16_e64 s2, 0x5640, s4
2435 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2436 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2437 ; SDAG-GFX10-NEXT: s_endpgm
2439 ; GISEL-GFX11-LABEL: v_fcmp_f16_ult:
2440 ; GISEL-GFX11: ; %bb.0:
2441 ; GISEL-GFX11-NEXT: s_clause 0x1
2442 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2443 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2444 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2445 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2446 ; GISEL-GFX11-NEXT: v_cmp_nle_f16_e64 s2, 0x5640, s4
2447 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2448 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2449 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2450 ; GISEL-GFX11-NEXT: s_nop 0
2451 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2452 ; GISEL-GFX11-NEXT: s_endpgm
2454 ; GISEL-GFX10-LABEL: v_fcmp_f16_ult:
2455 ; GISEL-GFX10: ; %bb.0:
2456 ; GISEL-GFX10-NEXT: s_clause 0x1
2457 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2458 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2459 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2460 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2461 ; GISEL-GFX10-NEXT: v_cmp_nle_f16_e64 s2, 0x5640, s4
2462 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2463 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2464 ; GISEL-GFX10-NEXT: s_endpgm
2465 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 12)
2466 store i32 %result, ptr addrspace(1) %out
2470 define amdgpu_kernel void @v_fcmp_f16_o(ptr addrspace(1) %out, half %src) {
2471 ; SDAG-GFX11-LABEL: v_fcmp_f16_o:
2472 ; SDAG-GFX11: ; %bb.0:
2473 ; SDAG-GFX11-NEXT: s_clause 0x1
2474 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2475 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2476 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2477 ; SDAG-GFX11-NEXT: v_cmp_o_f16_e64 s2, 0x5640, s4
2478 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2479 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2480 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2481 ; SDAG-GFX11-NEXT: s_nop 0
2482 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2483 ; SDAG-GFX11-NEXT: s_endpgm
2485 ; SDAG-GFX10-LABEL: v_fcmp_f16_o:
2486 ; SDAG-GFX10: ; %bb.0:
2487 ; SDAG-GFX10-NEXT: s_clause 0x1
2488 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2489 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2490 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2491 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2492 ; SDAG-GFX10-NEXT: v_cmp_o_f16_e64 s2, 0x5640, s4
2493 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2494 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2495 ; SDAG-GFX10-NEXT: s_endpgm
2497 ; GISEL-GFX11-LABEL: v_fcmp_f16_o:
2498 ; GISEL-GFX11: ; %bb.0:
2499 ; GISEL-GFX11-NEXT: s_clause 0x1
2500 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2501 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2502 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2503 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2504 ; GISEL-GFX11-NEXT: v_cmp_o_f16_e64 s2, 0x5640, s4
2505 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2506 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2507 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2508 ; GISEL-GFX11-NEXT: s_nop 0
2509 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2510 ; GISEL-GFX11-NEXT: s_endpgm
2512 ; GISEL-GFX10-LABEL: v_fcmp_f16_o:
2513 ; GISEL-GFX10: ; %bb.0:
2514 ; GISEL-GFX10-NEXT: s_clause 0x1
2515 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2516 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2517 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2518 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2519 ; GISEL-GFX10-NEXT: v_cmp_o_f16_e64 s2, 0x5640, s4
2520 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2521 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2522 ; GISEL-GFX10-NEXT: s_endpgm
2523 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 7)
2524 store i32 %result, ptr addrspace(1) %out
2528 define amdgpu_kernel void @v_fcmp_f16_uo(ptr addrspace(1) %out, half %src) {
2529 ; SDAG-GFX11-LABEL: v_fcmp_f16_uo:
2530 ; SDAG-GFX11: ; %bb.0:
2531 ; SDAG-GFX11-NEXT: s_clause 0x1
2532 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2533 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2534 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2535 ; SDAG-GFX11-NEXT: v_cmp_u_f16_e64 s2, 0x5640, s4
2536 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2537 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2538 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2539 ; SDAG-GFX11-NEXT: s_nop 0
2540 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2541 ; SDAG-GFX11-NEXT: s_endpgm
2543 ; SDAG-GFX10-LABEL: v_fcmp_f16_uo:
2544 ; SDAG-GFX10: ; %bb.0:
2545 ; SDAG-GFX10-NEXT: s_clause 0x1
2546 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2547 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2548 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2549 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2550 ; SDAG-GFX10-NEXT: v_cmp_u_f16_e64 s2, 0x5640, s4
2551 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2552 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2553 ; SDAG-GFX10-NEXT: s_endpgm
2555 ; GISEL-GFX11-LABEL: v_fcmp_f16_uo:
2556 ; GISEL-GFX11: ; %bb.0:
2557 ; GISEL-GFX11-NEXT: s_clause 0x1
2558 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2559 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2560 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2561 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2562 ; GISEL-GFX11-NEXT: v_cmp_u_f16_e64 s2, 0x5640, s4
2563 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2564 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2565 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2566 ; GISEL-GFX11-NEXT: s_nop 0
2567 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2568 ; GISEL-GFX11-NEXT: s_endpgm
2570 ; GISEL-GFX10-LABEL: v_fcmp_f16_uo:
2571 ; GISEL-GFX10: ; %bb.0:
2572 ; GISEL-GFX10-NEXT: s_clause 0x1
2573 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2574 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2575 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2576 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2577 ; GISEL-GFX10-NEXT: v_cmp_u_f16_e64 s2, 0x5640, s4
2578 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2579 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2580 ; GISEL-GFX10-NEXT: s_endpgm
2581 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 8)
2582 store i32 %result, ptr addrspace(1) %out
2586 define amdgpu_kernel void @v_fcmp_f16_ule(ptr addrspace(1) %out, half %src) {
2587 ; SDAG-GFX11-LABEL: v_fcmp_f16_ule:
2588 ; SDAG-GFX11: ; %bb.0:
2589 ; SDAG-GFX11-NEXT: s_clause 0x1
2590 ; SDAG-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2591 ; SDAG-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2592 ; SDAG-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2593 ; SDAG-GFX11-NEXT: v_cmp_nlt_f16_e64 s2, 0x5640, s4
2594 ; SDAG-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2595 ; SDAG-GFX11-NEXT: v_dual_mov_b32 v0, 0 :: v_dual_mov_b32 v1, s2
2596 ; SDAG-GFX11-NEXT: global_store_b32 v0, v1, s[0:1]
2597 ; SDAG-GFX11-NEXT: s_nop 0
2598 ; SDAG-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2599 ; SDAG-GFX11-NEXT: s_endpgm
2601 ; SDAG-GFX10-LABEL: v_fcmp_f16_ule:
2602 ; SDAG-GFX10: ; %bb.0:
2603 ; SDAG-GFX10-NEXT: s_clause 0x1
2604 ; SDAG-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2605 ; SDAG-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2606 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v0, 0
2607 ; SDAG-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2608 ; SDAG-GFX10-NEXT: v_cmp_nlt_f16_e64 s2, 0x5640, s4
2609 ; SDAG-GFX10-NEXT: v_mov_b32_e32 v1, s2
2610 ; SDAG-GFX10-NEXT: global_store_dword v0, v1, s[0:1]
2611 ; SDAG-GFX10-NEXT: s_endpgm
2613 ; GISEL-GFX11-LABEL: v_fcmp_f16_ule:
2614 ; GISEL-GFX11: ; %bb.0:
2615 ; GISEL-GFX11-NEXT: s_clause 0x1
2616 ; GISEL-GFX11-NEXT: s_load_b32 s4, s[2:3], 0x2c
2617 ; GISEL-GFX11-NEXT: s_load_b64 s[0:1], s[2:3], 0x24
2618 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v1, 0
2619 ; GISEL-GFX11-NEXT: s_waitcnt lgkmcnt(0)
2620 ; GISEL-GFX11-NEXT: v_cmp_nlt_f16_e64 s2, 0x5640, s4
2621 ; GISEL-GFX11-NEXT: s_delay_alu instid0(VALU_DEP_1)
2622 ; GISEL-GFX11-NEXT: v_mov_b32_e32 v0, s2
2623 ; GISEL-GFX11-NEXT: global_store_b32 v1, v0, s[0:1]
2624 ; GISEL-GFX11-NEXT: s_nop 0
2625 ; GISEL-GFX11-NEXT: s_sendmsg sendmsg(MSG_DEALLOC_VGPRS)
2626 ; GISEL-GFX11-NEXT: s_endpgm
2628 ; GISEL-GFX10-LABEL: v_fcmp_f16_ule:
2629 ; GISEL-GFX10: ; %bb.0:
2630 ; GISEL-GFX10-NEXT: s_clause 0x1
2631 ; GISEL-GFX10-NEXT: s_load_dword s4, s[2:3], 0x2c
2632 ; GISEL-GFX10-NEXT: s_load_dwordx2 s[0:1], s[2:3], 0x24
2633 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v1, 0
2634 ; GISEL-GFX10-NEXT: s_waitcnt lgkmcnt(0)
2635 ; GISEL-GFX10-NEXT: v_cmp_nlt_f16_e64 s2, 0x5640, s4
2636 ; GISEL-GFX10-NEXT: v_mov_b32_e32 v0, s2
2637 ; GISEL-GFX10-NEXT: global_store_dword v1, v0, s[0:1]
2638 ; GISEL-GFX10-NEXT: s_endpgm
2639 %result = call i32 @llvm.amdgcn.fcmp.f16(half %src, half 100.00, i32 13)
2640 store i32 %result, ptr addrspace(1) %out
2644 attributes #0 = { nounwind readnone convergent }