xref: /llvm-project/llvm/test/CodeGen/WebAssembly/simd-comparisons.ll (revision 122b0220fd45ee71acda912b0b712bb8edb6ba46)
1; RUN: llc < %s -asm-verbose=false -verify-machineinstrs -disable-wasm-fallthrough-return-opt -wasm-keep-registers -wasm-disable-explicit-locals -mattr=+simd128 | FileCheck %s --check-prefixes CHECK,SIMD128
2; RUN: llc < %s -asm-verbose=false -verify-machineinstrs -disable-wasm-fallthrough-return-opt -wasm-keep-registers -wasm-disable-explicit-locals | FileCheck %s --check-prefixes CHECK,NO-SIMD128
3
4; Test SIMD comparison operators
5
6target triple = "wasm32-unknown-unknown"
7
8; CHECK-LABEL: compare_eq_v16i8:
9; NO-SIMD128-NOT: i8x16
10; SIMD128-NEXT: .functype compare_eq_v16i8 (v128, v128) -> (v128){{$}}
11; SIMD128-NEXT: i8x16.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
12; SIMD128-NEXT: return $pop[[R]]{{$}}
13define <16 x i1> @compare_eq_v16i8 (<16 x i8> %x, <16 x i8> %y) {
14  %res = icmp eq <16 x i8> %x, %y
15  ret <16 x i1> %res
16}
17
18; CHECK-LABEL: compare_sext_eq_v16i8:
19; NO-SIMD128-NOT: i8x16
20; SIMD128-NEXT: .functype compare_sext_eq_v16i8 (v128, v128) -> (v128){{$}}
21; SIMD128-NEXT: i8x16.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
22; SIMD128-NEXT: return $pop[[R]]{{$}}
23define <16 x i8> @compare_sext_eq_v16i8 (<16 x i8> %x, <16 x i8> %y) {
24  %cmp = icmp eq <16 x i8> %x, %y
25  %res = sext <16 x i1> %cmp to <16 x i8>
26  ret <16 x i8> %res
27}
28
29; CHECK-LABEL: compare_ne_v16i8:
30; NO-SIMD128-NOT: i8x16
31; SIMD128-NEXT: .functype compare_ne_v16i8 (v128, v128) -> (v128){{$}}
32; SIMD128-NEXT: i8x16.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
33; SIMD128-NEXT: return $pop[[R]]{{$}}
34define <16 x i1> @compare_ne_v16i8 (<16 x i8> %x, <16 x i8> %y) {
35  %res = icmp ne <16 x i8> %x, %y
36  ret <16 x i1> %res
37}
38
39; CHECK-LABEL: compare_sext_ne_v16i8:
40; NO-SIMD128-NOT: i8x16
41; SIMD128-NEXT: .functype compare_sext_ne_v16i8 (v128, v128) -> (v128){{$}}
42; SIMD128-NEXT: i8x16.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
43; SIMD128-NEXT: return $pop[[R]]{{$}}
44define <16 x i8> @compare_sext_ne_v16i8 (<16 x i8> %x, <16 x i8> %y) {
45  %cmp = icmp ne <16 x i8> %x, %y
46  %res = sext <16 x i1> %cmp to <16 x i8>
47  ret <16 x i8> %res
48}
49
50; CHECK-LABEL: compare_slt_v16i8:
51; NO-SIMD128-NOT: i8x16
52; SIMD128-NEXT: .functype compare_slt_v16i8 (v128, v128) -> (v128){{$}}
53; SIMD128-NEXT: i8x16.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
54; SIMD128-NEXT: return $pop[[R]]{{$}}
55define <16 x i1> @compare_slt_v16i8 (<16 x i8> %x, <16 x i8> %y) {
56  %res = icmp slt <16 x i8> %x, %y
57  ret <16 x i1> %res
58}
59
60; CHECK-LABEL: compare_sext_slt_v16i8:
61; NO-SIMD128-NOT: i8x16
62; SIMD128-NEXT: .functype compare_sext_slt_v16i8 (v128, v128) -> (v128){{$}}
63; SIMD128-NEXT: i8x16.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
64; SIMD128-NEXT: return $pop[[R]]{{$}}
65define <16 x i8> @compare_sext_slt_v16i8 (<16 x i8> %x, <16 x i8> %y) {
66  %cmp = icmp slt <16 x i8> %x, %y
67  %res = sext <16 x i1> %cmp to <16 x i8>
68  ret <16 x i8> %res
69}
70
71; CHECK-LABEL: compare_ult_v16i8:
72; NO-SIMD128-NOT: i8x16
73; SIMD128-NEXT: .functype compare_ult_v16i8 (v128, v128) -> (v128){{$}}
74; SIMD128-NEXT: i8x16.lt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
75; SIMD128-NEXT: return $pop[[R]]{{$}}
76define <16 x i1> @compare_ult_v16i8 (<16 x i8> %x, <16 x i8> %y) {
77  %res = icmp ult <16 x i8> %x, %y
78  ret <16 x i1> %res
79}
80
81; CHECK-LABEL: compare_sext_ult_v16i8:
82; NO-SIMD128-NOT: i8x16
83; SIMD128-NEXT: .functype compare_sext_ult_v16i8 (v128, v128) -> (v128){{$}}
84; SIMD128-NEXT: i8x16.lt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
85; SIMD128-NEXT: return $pop[[R]]{{$}}
86define <16 x i8> @compare_sext_ult_v16i8 (<16 x i8> %x, <16 x i8> %y) {
87  %cmp = icmp ult <16 x i8> %x, %y
88  %res = sext <16 x i1> %cmp to <16 x i8>
89  ret <16 x i8> %res
90}
91
92; CHECK-LABEL: compare_sle_v16i8:
93; NO-SIMD128-NOT: i8x16
94; SIMD128-NEXT: .functype compare_sle_v16i8 (v128, v128) -> (v128){{$}}
95; SIMD128-NEXT: i8x16.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
96; SIMD128-NEXT: return $pop[[R]]{{$}}
97define <16 x i1> @compare_sle_v16i8 (<16 x i8> %x, <16 x i8> %y) {
98  %res = icmp sle <16 x i8> %x, %y
99  ret <16 x i1> %res
100}
101
102; CHECK-LABEL: compare_sext_sle_v16i8:
103; NO-SIMD128-NOT: i8x16
104; SIMD128-NEXT: .functype compare_sext_sle_v16i8 (v128, v128) -> (v128){{$}}
105; SIMD128-NEXT: i8x16.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
106; SIMD128-NEXT: return $pop[[R]]{{$}}
107define <16 x i8> @compare_sext_sle_v16i8 (<16 x i8> %x, <16 x i8> %y) {
108  %cmp = icmp sle <16 x i8> %x, %y
109  %res = sext <16 x i1> %cmp to <16 x i8>
110  ret <16 x i8> %res
111}
112
113; CHECK-LABEL: compare_ule_v16i8:
114; NO-SIMD128-NOT: i8x16
115; SIMD128-NEXT: .functype compare_ule_v16i8 (v128, v128) -> (v128){{$}}
116; SIMD128-NEXT: i8x16.le_u $push[[R:[0-9]+]]=, $0, $1{{$}}
117; SIMD128-NEXT: return $pop[[R]]{{$}}
118define <16 x i1> @compare_ule_v16i8 (<16 x i8> %x, <16 x i8> %y) {
119  %res = icmp ule <16 x i8> %x, %y
120  ret <16 x i1> %res
121}
122
123; CHECK-LABEL: compare_sext_ule_v16i8:
124; NO-SIMD128-NOT: i8x16
125; SIMD128-NEXT: .functype compare_sext_ule_v16i8 (v128, v128) -> (v128){{$}}
126; SIMD128-NEXT: i8x16.le_u $push[[R:[0-9]+]]=, $0, $1{{$}}
127; SIMD128-NEXT: return $pop[[R]]{{$}}
128define <16 x i8> @compare_sext_ule_v16i8 (<16 x i8> %x, <16 x i8> %y) {
129  %cmp = icmp ule <16 x i8> %x, %y
130  %res = sext <16 x i1> %cmp to <16 x i8>
131  ret <16 x i8> %res
132}
133
134; CHECK-LABEL: compare_sgt_v16i8:
135; NO-SIMD128-NOT: i8x16
136; SIMD128-NEXT: .functype compare_sgt_v16i8 (v128, v128) -> (v128){{$}}
137; SIMD128-NEXT: i8x16.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
138; SIMD128-NEXT: return $pop[[R]]{{$}}
139define <16 x i1> @compare_sgt_v16i8 (<16 x i8> %x, <16 x i8> %y) {
140  %res = icmp sgt <16 x i8> %x, %y
141  ret <16 x i1> %res
142}
143
144; CHECK-LABEL: compare_sext_sgt_v16i8:
145; NO-SIMD128-NOT: i8x16
146; SIMD128-NEXT: .functype compare_sext_sgt_v16i8 (v128, v128) -> (v128){{$}}
147; SIMD128-NEXT: i8x16.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
148; SIMD128-NEXT: return $pop[[R]]{{$}}
149define <16 x i8> @compare_sext_sgt_v16i8 (<16 x i8> %x, <16 x i8> %y) {
150  %cmp = icmp sgt <16 x i8> %x, %y
151  %res = sext <16 x i1> %cmp to <16 x i8>
152  ret <16 x i8> %res
153}
154
155; CHECK-LABEL: compare_ugt_v16i8:
156; NO-SIMD128-NOT: i8x16
157; SIMD128-NEXT: .functype compare_ugt_v16i8 (v128, v128) -> (v128){{$}}
158; SIMD128-NEXT: i8x16.gt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
159; SIMD128-NEXT: return $pop[[R]]{{$}}
160define <16 x i1> @compare_ugt_v16i8 (<16 x i8> %x, <16 x i8> %y) {
161  %res = icmp ugt <16 x i8> %x, %y
162  ret <16 x i1> %res
163}
164
165; CHECK-LABEL: compare_sext_ugt_v16i8:
166; NO-SIMD128-NOT: i8x16
167; SIMD128-NEXT: .functype compare_sext_ugt_v16i8 (v128, v128) -> (v128){{$}}
168; SIMD128-NEXT: i8x16.gt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
169; SIMD128-NEXT: return $pop[[R]]{{$}}
170define <16 x i8> @compare_sext_ugt_v16i8 (<16 x i8> %x, <16 x i8> %y) {
171  %cmp = icmp ugt <16 x i8> %x, %y
172  %res = sext <16 x i1> %cmp to <16 x i8>
173  ret <16 x i8> %res
174}
175
176; CHECK-LABEL: compare_sge_v16i8:
177; NO-SIMD128-NOT: i8x16
178; SIMD128-NEXT: .functype compare_sge_v16i8 (v128, v128) -> (v128){{$}}
179; SIMD128-NEXT: i8x16.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
180; SIMD128-NEXT: return $pop[[R]]{{$}}
181define <16 x i1> @compare_sge_v16i8 (<16 x i8> %x, <16 x i8> %y) {
182  %res = icmp sge <16 x i8> %x, %y
183  ret <16 x i1> %res
184}
185
186; CHECK-LABEL: compare_sext_sge_v16i8:
187; NO-SIMD128-NOT: i8x16
188; SIMD128-NEXT: .functype compare_sext_sge_v16i8 (v128, v128) -> (v128){{$}}
189; SIMD128-NEXT: i8x16.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
190; SIMD128-NEXT: return $pop[[R]]{{$}}
191define <16 x i8> @compare_sext_sge_v16i8 (<16 x i8> %x, <16 x i8> %y) {
192  %cmp = icmp sge <16 x i8> %x, %y
193  %res = sext <16 x i1> %cmp to <16 x i8>
194  ret <16 x i8> %res
195}
196
197; CHECK-LABEL: compare_uge_v16i8:
198; NO-SIMD128-NOT: i8x16
199; SIMD128-NEXT: .functype compare_uge_v16i8 (v128, v128) -> (v128){{$}}
200; SIMD128-NEXT: i8x16.ge_u $push[[R:[0-9]+]]=, $0, $1{{$}}
201; SIMD128-NEXT: return $pop[[R]]{{$}}
202define <16 x i1> @compare_uge_v16i8 (<16 x i8> %x, <16 x i8> %y) {
203  %res = icmp uge <16 x i8> %x, %y
204  ret <16 x i1> %res
205}
206
207; CHECK-LABEL: compare_sext_uge_v16i8:
208; NO-SIMD128-NOT: i8x16
209; SIMD128-NEXT: .functype compare_sext_uge_v16i8 (v128, v128) -> (v128){{$}}
210; SIMD128-NEXT: i8x16.ge_u $push[[R:[0-9]+]]=, $0, $1{{$}}
211; SIMD128-NEXT: return $pop[[R]]{{$}}
212define <16 x i8> @compare_sext_uge_v16i8 (<16 x i8> %x, <16 x i8> %y) {
213  %cmp = icmp uge <16 x i8> %x, %y
214  %res = sext <16 x i1> %cmp to <16 x i8>
215  ret <16 x i8> %res
216}
217
218; CHECK-LABEL: compare_eq_v8i16:
219; NO-SIMD128-NOT: i16x8
220; SIMD128-NEXT: .functype compare_eq_v8i16 (v128, v128) -> (v128){{$}}
221; SIMD128-NEXT: i16x8.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
222; SIMD128-NEXT: return $pop[[R]]{{$}}
223define <8 x i1> @compare_eq_v8i16 (<8 x i16> %x, <8 x i16> %y) {
224  %res = icmp eq <8 x i16> %x, %y
225  ret <8 x i1> %res
226}
227
228; CHECK-LABEL: compare_sext_eq_v8i16:
229; NO-SIMD128-NOT: i16x8
230; SIMD128-NEXT: .functype compare_sext_eq_v8i16 (v128, v128) -> (v128){{$}}
231; SIMD128-NEXT: i16x8.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
232; SIMD128-NEXT: return $pop[[R]]{{$}}
233define <8 x i16> @compare_sext_eq_v8i16 (<8 x i16> %x, <8 x i16> %y) {
234  %cmp = icmp eq <8 x i16> %x, %y
235  %res = sext <8 x i1> %cmp to <8 x i16>
236  ret <8 x i16> %res
237}
238
239; CHECK-LABEL: compare_ne_v8i16:
240; NO-SIMD128-NOT: i16x8
241; SIMD128-NEXT: .functype compare_ne_v8i16 (v128, v128) -> (v128){{$}}
242; SIMD128-NEXT: i16x8.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
243; SIMD128-NEXT: return $pop[[R]]{{$}}
244define <8 x i1> @compare_ne_v8i16 (<8 x i16> %x, <8 x i16> %y) {
245  %res = icmp ne <8 x i16> %x, %y
246  ret <8 x i1> %res
247}
248
249; CHECK-LABEL: compare_sext_ne_v8i16:
250; NO-SIMD128-NOT: i16x8
251; SIMD128-NEXT: .functype compare_sext_ne_v8i16 (v128, v128) -> (v128){{$}}
252; SIMD128-NEXT: i16x8.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
253; SIMD128-NEXT: return $pop[[R]]{{$}}
254define <8 x i16> @compare_sext_ne_v8i16 (<8 x i16> %x, <8 x i16> %y) {
255  %cmp = icmp ne <8 x i16> %x, %y
256  %res = sext <8 x i1> %cmp to <8 x i16>
257  ret <8 x i16> %res
258}
259
260; CHECK-LABEL: compare_slt_v8i16:
261; NO-SIMD128-NOT: i16x8
262; SIMD128-NEXT: .functype compare_slt_v8i16 (v128, v128) -> (v128){{$}}
263; SIMD128-NEXT: i16x8.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
264; SIMD128-NEXT: return $pop[[R]]{{$}}
265define <8 x i1> @compare_slt_v8i16 (<8 x i16> %x, <8 x i16> %y) {
266  %res = icmp slt <8 x i16> %x, %y
267  ret <8 x i1> %res
268}
269
270; CHECK-LABEL: compare_sext_slt_v8i16:
271; NO-SIMD128-NOT: i16x8
272; SIMD128-NEXT: .functype compare_sext_slt_v8i16 (v128, v128) -> (v128){{$}}
273; SIMD128-NEXT: i16x8.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
274; SIMD128-NEXT: return $pop[[R]]{{$}}
275define <8 x i16> @compare_sext_slt_v8i16 (<8 x i16> %x, <8 x i16> %y) {
276  %cmp = icmp slt <8 x i16> %x, %y
277  %res = sext <8 x i1> %cmp to <8 x i16>
278  ret <8 x i16> %res
279}
280
281; CHECK-LABEL: compare_ult_v8i16:
282; NO-SIMD128-NOT: i16x8
283; SIMD128-NEXT: .functype compare_ult_v8i16 (v128, v128) -> (v128){{$}}
284; SIMD128-NEXT: i16x8.lt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
285; SIMD128-NEXT: return $pop[[R]]{{$}}
286define <8 x i1> @compare_ult_v8i16 (<8 x i16> %x, <8 x i16> %y) {
287  %res = icmp ult <8 x i16> %x, %y
288  ret <8 x i1> %res
289}
290
291; CHECK-LABEL: compare_sext_ult_v8i16:
292; NO-SIMD128-NOT: i16x8
293; SIMD128-NEXT: .functype compare_sext_ult_v8i16 (v128, v128) -> (v128){{$}}
294; SIMD128-NEXT: i16x8.lt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
295; SIMD128-NEXT: return $pop[[R]]{{$}}
296define <8 x i16> @compare_sext_ult_v8i16 (<8 x i16> %x, <8 x i16> %y) {
297  %cmp = icmp ult <8 x i16> %x, %y
298  %res = sext <8 x i1> %cmp to <8 x i16>
299  ret <8 x i16> %res
300}
301
302; CHECK-LABEL: compare_sle_v8i16:
303; NO-SIMD128-NOT: i16x8
304; SIMD128-NEXT: .functype compare_sle_v8i16 (v128, v128) -> (v128){{$}}
305; SIMD128-NEXT: i16x8.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
306; SIMD128-NEXT: return $pop[[R]]{{$}}
307define <8 x i1> @compare_sle_v8i16 (<8 x i16> %x, <8 x i16> %y) {
308  %res = icmp sle <8 x i16> %x, %y
309  ret <8 x i1> %res
310}
311
312; CHECK-LABEL: compare_sext_sle_v8i16:
313; NO-SIMD128-NOT: i16x8
314; SIMD128-NEXT: .functype compare_sext_sle_v8i16 (v128, v128) -> (v128){{$}}
315; SIMD128-NEXT: i16x8.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
316; SIMD128-NEXT: return $pop[[R]]{{$}}
317define <8 x i16> @compare_sext_sle_v8i16 (<8 x i16> %x, <8 x i16> %y) {
318  %cmp = icmp sle <8 x i16> %x, %y
319  %res = sext <8 x i1> %cmp to <8 x i16>
320  ret <8 x i16> %res
321}
322
323; CHECK-LABEL: compare_ule_v8i16:
324; NO-SIMD128-NOT: i16x8
325; SIMD128-NEXT: .functype compare_ule_v8i16 (v128, v128) -> (v128){{$}}
326; SIMD128-NEXT: i16x8.le_u $push[[R:[0-9]+]]=, $0, $1{{$}}
327; SIMD128-NEXT: return $pop[[R]]{{$}}
328define <8 x i1> @compare_ule_v8i16 (<8 x i16> %x, <8 x i16> %y) {
329  %res = icmp ule <8 x i16> %x, %y
330  ret <8 x i1> %res
331}
332
333; CHECK-LABEL: compare_sext_ule_v8i16:
334; NO-SIMD128-NOT: i16x8
335; SIMD128-NEXT: .functype compare_sext_ule_v8i16 (v128, v128) -> (v128){{$}}
336; SIMD128-NEXT: i16x8.le_u $push[[R:[0-9]+]]=, $0, $1{{$}}
337; SIMD128-NEXT: return $pop[[R]]{{$}}
338define <8 x i16> @compare_sext_ule_v8i16 (<8 x i16> %x, <8 x i16> %y) {
339  %cmp = icmp ule <8 x i16> %x, %y
340  %res = sext <8 x i1> %cmp to <8 x i16>
341  ret <8 x i16> %res
342}
343
344; CHECK-LABEL: compare_sgt_v8i16:
345; NO-SIMD128-NOT: i16x8
346; SIMD128-NEXT: .functype compare_sgt_v8i16 (v128, v128) -> (v128){{$}}
347; SIMD128-NEXT: i16x8.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
348; SIMD128-NEXT: return $pop[[R]]{{$}}
349define <8 x i1> @compare_sgt_v8i16 (<8 x i16> %x, <8 x i16> %y) {
350  %res = icmp sgt <8 x i16> %x, %y
351  ret <8 x i1> %res
352}
353
354; CHECK-LABEL: compare_sext_sgt_v8i16:
355; NO-SIMD128-NOT: i16x8
356; SIMD128-NEXT: .functype compare_sext_sgt_v8i16 (v128, v128) -> (v128){{$}}
357; SIMD128-NEXT: i16x8.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
358; SIMD128-NEXT: return $pop[[R]]{{$}}
359define <8 x i16> @compare_sext_sgt_v8i16 (<8 x i16> %x, <8 x i16> %y) {
360  %cmp = icmp sgt <8 x i16> %x, %y
361  %res = sext <8 x i1> %cmp to <8 x i16>
362  ret <8 x i16> %res
363}
364
365; CHECK-LABEL: compare_ugt_v8i16:
366; NO-SIMD128-NOT: i16x8
367; SIMD128-NEXT: .functype compare_ugt_v8i16 (v128, v128) -> (v128){{$}}
368; SIMD128-NEXT: i16x8.gt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
369; SIMD128-NEXT: return $pop[[R]]{{$}}
370define <8 x i1> @compare_ugt_v8i16 (<8 x i16> %x, <8 x i16> %y) {
371  %res = icmp ugt <8 x i16> %x, %y
372  ret <8 x i1> %res
373}
374
375; CHECK-LABEL: compare_sext_ugt_v8i16:
376; NO-SIMD128-NOT: i16x8
377; SIMD128-NEXT: .functype compare_sext_ugt_v8i16 (v128, v128) -> (v128){{$}}
378; SIMD128-NEXT: i16x8.gt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
379; SIMD128-NEXT: return $pop[[R]]{{$}}
380define <8 x i16> @compare_sext_ugt_v8i16 (<8 x i16> %x, <8 x i16> %y) {
381  %cmp = icmp ugt <8 x i16> %x, %y
382  %res = sext <8 x i1> %cmp to <8 x i16>
383  ret <8 x i16> %res
384}
385
386; CHECK-LABEL: compare_sge_v8i16:
387; NO-SIMD128-NOT: i16x8
388; SIMD128-NEXT: .functype compare_sge_v8i16 (v128, v128) -> (v128){{$}}
389; SIMD128-NEXT: i16x8.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
390; SIMD128-NEXT: return $pop[[R]]{{$}}
391define <8 x i1> @compare_sge_v8i16 (<8 x i16> %x, <8 x i16> %y) {
392  %res = icmp sge <8 x i16> %x, %y
393  ret <8 x i1> %res
394}
395
396; CHECK-LABEL: compare_sext_sge_v8i16:
397; NO-SIMD128-NOT: i16x8
398; SIMD128-NEXT: .functype compare_sext_sge_v8i16 (v128, v128) -> (v128){{$}}
399; SIMD128-NEXT: i16x8.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
400; SIMD128-NEXT: return $pop[[R]]{{$}}
401define <8 x i16> @compare_sext_sge_v8i16 (<8 x i16> %x, <8 x i16> %y) {
402  %cmp = icmp sge <8 x i16> %x, %y
403  %res = sext <8 x i1> %cmp to <8 x i16>
404  ret <8 x i16> %res
405}
406
407; CHECK-LABEL: compare_uge_v8i16:
408; NO-SIMD128-NOT: i16x8
409; SIMD128-NEXT: .functype compare_uge_v8i16 (v128, v128) -> (v128){{$}}
410; SIMD128-NEXT: i16x8.ge_u $push[[R:[0-9]+]]=, $0, $1{{$}}
411; SIMD128-NEXT: return $pop[[R]]{{$}}
412define <8 x i1> @compare_uge_v8i16 (<8 x i16> %x, <8 x i16> %y) {
413  %res = icmp uge <8 x i16> %x, %y
414  ret <8 x i1> %res
415}
416
417; CHECK-LABEL: compare_sext_uge_v8i16:
418; NO-SIMD128-NOT: i16x8
419; SIMD128-NEXT: .functype compare_sext_uge_v8i16 (v128, v128) -> (v128){{$}}
420; SIMD128-NEXT: i16x8.ge_u $push[[R:[0-9]+]]=, $0, $1{{$}}
421; SIMD128-NEXT: return $pop[[R]]{{$}}
422define <8 x i16> @compare_sext_uge_v8i16 (<8 x i16> %x, <8 x i16> %y) {
423  %cmp = icmp uge <8 x i16> %x, %y
424  %res = sext <8 x i1> %cmp to <8 x i16>
425  ret <8 x i16> %res
426}
427
428; CHECK-LABEL: compare_eq_v4i32:
429; NO-SIMD128-NOT: i32x4
430; SIMD128-NEXT: .functype compare_eq_v4i32 (v128, v128) -> (v128){{$}}
431; SIMD128-NEXT: i32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
432; SIMD128-NEXT: return $pop[[R]]{{$}}
433define <4 x i1> @compare_eq_v4i32 (<4 x i32> %x, <4 x i32> %y) {
434  %res = icmp eq <4 x i32> %x, %y
435  ret <4 x i1> %res
436}
437
438; CHECK-LABEL: compare_sext_eq_v4i32:
439; NO-SIMD128-NOT: i32x4
440; SIMD128-NEXT: .functype compare_sext_eq_v4i32 (v128, v128) -> (v128){{$}}
441; SIMD128-NEXT: i32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
442; SIMD128-NEXT: return $pop[[R]]{{$}}
443define <4 x i32> @compare_sext_eq_v4i32 (<4 x i32> %x, <4 x i32> %y) {
444  %cmp = icmp eq <4 x i32> %x, %y
445  %res = sext <4 x i1> %cmp to <4 x i32>
446  ret <4 x i32> %res
447}
448
449; CHECK-LABEL: compare_ne_v4i32:
450; NO-SIMD128-NOT: i32x4
451; SIMD128-NEXT: .functype compare_ne_v4i32 (v128, v128) -> (v128){{$}}
452; SIMD128-NEXT: i32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
453; SIMD128-NEXT: return $pop[[R]]{{$}}
454define <4 x i1> @compare_ne_v4i32 (<4 x i32> %x, <4 x i32> %y) {
455  %res = icmp ne <4 x i32> %x, %y
456  ret <4 x i1> %res
457}
458
459; CHECK-LABEL: compare_sext_ne_v4i32:
460; NO-SIMD128-NOT: i32x4
461; SIMD128-NEXT: .functype compare_sext_ne_v4i32 (v128, v128) -> (v128){{$}}
462; SIMD128-NEXT: i32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
463; SIMD128-NEXT: return $pop[[R]]{{$}}
464define <4 x i32> @compare_sext_ne_v4i32 (<4 x i32> %x, <4 x i32> %y) {
465  %cmp = icmp ne <4 x i32> %x, %y
466  %res = sext <4 x i1> %cmp to <4 x i32>
467  ret <4 x i32> %res
468}
469
470; CHECK-LABEL: compare_slt_v4i32:
471; NO-SIMD128-NOT: i32x4
472; SIMD128-NEXT: .functype compare_slt_v4i32 (v128, v128) -> (v128){{$}}
473; SIMD128-NEXT: i32x4.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
474; SIMD128-NEXT: return $pop[[R]]{{$}}
475define <4 x i1> @compare_slt_v4i32 (<4 x i32> %x, <4 x i32> %y) {
476  %res = icmp slt <4 x i32> %x, %y
477  ret <4 x i1> %res
478}
479
480; CHECK-LABEL: compare_sext_slt_v4i32:
481; NO-SIMD128-NOT: i32x4
482; SIMD128-NEXT: .functype compare_sext_slt_v4i32 (v128, v128) -> (v128){{$}}
483; SIMD128-NEXT: i32x4.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
484; SIMD128-NEXT: return $pop[[R]]{{$}}
485define <4 x i32> @compare_sext_slt_v4i32 (<4 x i32> %x, <4 x i32> %y) {
486  %cmp = icmp slt <4 x i32> %x, %y
487  %res = sext <4 x i1> %cmp to <4 x i32>
488  ret <4 x i32> %res
489}
490
491; CHECK-LABEL: compare_ult_v4i32:
492; NO-SIMD128-NOT: i32x4
493; SIMD128-NEXT: .functype compare_ult_v4i32 (v128, v128) -> (v128){{$}}
494; SIMD128-NEXT: i32x4.lt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
495; SIMD128-NEXT: return $pop[[R]]{{$}}
496define <4 x i1> @compare_ult_v4i32 (<4 x i32> %x, <4 x i32> %y) {
497  %res = icmp ult <4 x i32> %x, %y
498  ret <4 x i1> %res
499}
500
501; CHECK-LABEL: compare_sext_ult_v4i32:
502; NO-SIMD128-NOT: i32x4
503; SIMD128-NEXT: .functype compare_sext_ult_v4i32 (v128, v128) -> (v128){{$}}
504; SIMD128-NEXT: i32x4.lt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
505; SIMD128-NEXT: return $pop[[R]]{{$}}
506define <4 x i32> @compare_sext_ult_v4i32 (<4 x i32> %x, <4 x i32> %y) {
507  %cmp = icmp ult <4 x i32> %x, %y
508  %res = sext <4 x i1> %cmp to <4 x i32>
509  ret <4 x i32> %res
510}
511
512; CHECK-LABEL: compare_sle_v4i32:
513; NO-SIMD128-NOT: i32x4
514; SIMD128-NEXT: .functype compare_sle_v4i32 (v128, v128) -> (v128){{$}}
515; SIMD128-NEXT: i32x4.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
516; SIMD128-NEXT: return $pop[[R]]{{$}}
517define <4 x i1> @compare_sle_v4i32 (<4 x i32> %x, <4 x i32> %y) {
518  %res = icmp sle <4 x i32> %x, %y
519  ret <4 x i1> %res
520}
521
522; CHECK-LABEL: compare_sext_sle_v4i32:
523; NO-SIMD128-NOT: i32x4
524; SIMD128-NEXT: .functype compare_sext_sle_v4i32 (v128, v128) -> (v128){{$}}
525; SIMD128-NEXT: i32x4.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
526; SIMD128-NEXT: return $pop[[R]]{{$}}
527define <4 x i32> @compare_sext_sle_v4i32 (<4 x i32> %x, <4 x i32> %y) {
528  %cmp = icmp sle <4 x i32> %x, %y
529  %res = sext <4 x i1> %cmp to <4 x i32>
530  ret <4 x i32> %res
531}
532
533; CHECK-LABEL: compare_ule_v4i32:
534; NO-SIMD128-NOT: i32x4
535; SIMD128-NEXT: .functype compare_ule_v4i32 (v128, v128) -> (v128){{$}}
536; SIMD128-NEXT: i32x4.le_u $push[[R:[0-9]+]]=, $0, $1{{$}}
537; SIMD128-NEXT: return $pop[[R]]{{$}}
538define <4 x i1> @compare_ule_v4i32 (<4 x i32> %x, <4 x i32> %y) {
539  %res = icmp ule <4 x i32> %x, %y
540  ret <4 x i1> %res
541}
542
543; CHECK-LABEL: compare_sext_ule_v4i32:
544; NO-SIMD128-NOT: i32x4
545; SIMD128-NEXT: .functype compare_sext_ule_v4i32 (v128, v128) -> (v128){{$}}
546; SIMD128-NEXT: i32x4.le_u $push[[R:[0-9]+]]=, $0, $1{{$}}
547; SIMD128-NEXT: return $pop[[R]]{{$}}
548define <4 x i32> @compare_sext_ule_v4i32 (<4 x i32> %x, <4 x i32> %y) {
549  %cmp = icmp ule <4 x i32> %x, %y
550  %res = sext <4 x i1> %cmp to <4 x i32>
551  ret <4 x i32> %res
552}
553
554; CHECK-LABEL: compare_sgt_v4i32:
555; NO-SIMD128-NOT: i32x4
556; SIMD128-NEXT: .functype compare_sgt_v4i32 (v128, v128) -> (v128){{$}}
557; SIMD128-NEXT: i32x4.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
558; SIMD128-NEXT: return $pop[[R]]{{$}}
559define <4 x i1> @compare_sgt_v4i32 (<4 x i32> %x, <4 x i32> %y) {
560  %res = icmp sgt <4 x i32> %x, %y
561  ret <4 x i1> %res
562}
563
564; CHECK-LABEL: compare_sext_sgt_v4i32:
565; NO-SIMD128-NOT: i32x4
566; SIMD128-NEXT: .functype compare_sext_sgt_v4i32 (v128, v128) -> (v128){{$}}
567; SIMD128-NEXT: i32x4.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
568; SIMD128-NEXT: return $pop[[R]]{{$}}
569define <4 x i32> @compare_sext_sgt_v4i32 (<4 x i32> %x, <4 x i32> %y) {
570  %cmp = icmp sgt <4 x i32> %x, %y
571  %res = sext <4 x i1> %cmp to <4 x i32>
572  ret <4 x i32> %res
573}
574
575; CHECK-LABEL: compare_ugt_v4i32:
576; NO-SIMD128-NOT: i32x4
577; SIMD128-NEXT: .functype compare_ugt_v4i32 (v128, v128) -> (v128){{$}}
578; SIMD128-NEXT: i32x4.gt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
579; SIMD128-NEXT: return $pop[[R]]{{$}}
580define <4 x i1> @compare_ugt_v4i32 (<4 x i32> %x, <4 x i32> %y) {
581  %res = icmp ugt <4 x i32> %x, %y
582  ret <4 x i1> %res
583}
584
585; CHECK-LABEL: compare_sext_ugt_v4i32:
586; NO-SIMD128-NOT: i32x4
587; SIMD128-NEXT: .functype compare_sext_ugt_v4i32 (v128, v128) -> (v128){{$}}
588; SIMD128-NEXT: i32x4.gt_u $push[[R:[0-9]+]]=, $0, $1{{$}}
589; SIMD128-NEXT: return $pop[[R]]{{$}}
590define <4 x i32> @compare_sext_ugt_v4i32 (<4 x i32> %x, <4 x i32> %y) {
591  %cmp = icmp ugt <4 x i32> %x, %y
592  %res = sext <4 x i1> %cmp to <4 x i32>
593  ret <4 x i32> %res
594}
595
596; CHECK-LABEL: compare_sge_v4i32:
597; NO-SIMD128-NOT: i32x4
598; SIMD128-NEXT: .functype compare_sge_v4i32 (v128, v128) -> (v128){{$}}
599; SIMD128-NEXT: i32x4.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
600; SIMD128-NEXT: return $pop[[R]]{{$}}
601define <4 x i1> @compare_sge_v4i32 (<4 x i32> %x, <4 x i32> %y) {
602  %res = icmp sge <4 x i32> %x, %y
603  ret <4 x i1> %res
604}
605
606; CHECK-LABEL: compare_sext_sge_v4i32:
607; NO-SIMD128-NOT: i32x4
608; SIMD128-NEXT: .functype compare_sext_sge_v4i32 (v128, v128) -> (v128){{$}}
609; SIMD128-NEXT: i32x4.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
610; SIMD128-NEXT: return $pop[[R]]{{$}}
611define <4 x i32> @compare_sext_sge_v4i32 (<4 x i32> %x, <4 x i32> %y) {
612  %cmp = icmp sge <4 x i32> %x, %y
613  %res = sext <4 x i1> %cmp to <4 x i32>
614  ret <4 x i32> %res
615}
616
617; CHECK-LABEL: compare_uge_v4i32:
618; NO-SIMD128-NOT: i32x4
619; SIMD128-NEXT: .functype compare_uge_v4i32 (v128, v128) -> (v128){{$}}
620; SIMD128-NEXT: i32x4.ge_u $push[[R:[0-9]+]]=, $0, $1{{$}}
621; SIMD128-NEXT: return $pop[[R]]{{$}}
622define <4 x i1> @compare_uge_v4i32 (<4 x i32> %x, <4 x i32> %y) {
623  %res = icmp uge <4 x i32> %x, %y
624  ret <4 x i1> %res
625}
626
627; CHECK-LABEL: compare_sext_uge_v4i32:
628; NO-SIMD128-NOT: i32x4
629; SIMD128-NEXT: .functype compare_sext_uge_v4i32 (v128, v128) -> (v128){{$}}
630; SIMD128-NEXT: i32x4.ge_u $push[[R:[0-9]+]]=, $0, $1{{$}}
631; SIMD128-NEXT: return $pop[[R]]{{$}}
632define <4 x i32> @compare_sext_uge_v4i32 (<4 x i32> %x, <4 x i32> %y) {
633  %cmp = icmp uge <4 x i32> %x, %y
634  %res = sext <4 x i1> %cmp to <4 x i32>
635  ret <4 x i32> %res
636}
637
638; CHECK-LABEL: compare_eq_v2i64:
639; NO-SIMD128-NOT: i64x2
640; SIMD128-NEXT: .functype compare_eq_v2i64 (v128, v128) -> (v128){{$}}
641; SIMD128-NEXT: i64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
642; SIMD128-NEXT: return $pop[[R]]{{$}}
643define <2 x i1> @compare_eq_v2i64 (<2 x i64> %x, <2 x i64> %y) {
644  %res = icmp eq <2 x i64> %x, %y
645  ret <2 x i1> %res
646}
647
648; CHECK-LABEL: compare_sext_eq_v2i64:
649; NO-SIMD128-NOT: i64x2
650; SIMD128-NEXT: .functype compare_sext_eq_v2i64 (v128, v128) -> (v128){{$}}
651; SIMD128-NEXT: i64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
652; SIMD128-NEXT: return $pop[[R]]{{$}}
653define <2 x i64> @compare_sext_eq_v2i64 (<2 x i64> %x, <2 x i64> %y) {
654  %cmp = icmp eq <2 x i64> %x, %y
655  %res = sext <2 x i1> %cmp to <2 x i64>
656  ret <2 x i64> %res
657}
658
659; CHECK-LABEL: compare_ne_v2i64:
660; NO-SIMD128-NOT: i64x2
661; SIMD128-NEXT: .functype compare_ne_v2i64 (v128, v128) -> (v128){{$}}
662; SIMD128-NEXT: i64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
663; SIMD128-NEXT: return $pop[[R]]{{$}}
664define <2 x i1> @compare_ne_v2i64 (<2 x i64> %x, <2 x i64> %y) {
665  %res = icmp ne <2 x i64> %x, %y
666  ret <2 x i1> %res
667}
668
669; CHECK-LABEL: compare_sext_ne_v2i64:
670; NO-SIMD128-NOT: i64x2
671; SIMD128-NEXT: .functype compare_sext_ne_v2i64 (v128, v128) -> (v128){{$}}
672; SIMD128-NEXT: i64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
673; SIMD128-NEXT: return $pop[[R]]{{$}}
674define <2 x i64> @compare_sext_ne_v2i64 (<2 x i64> %x, <2 x i64> %y) {
675  %cmp = icmp ne <2 x i64> %x, %y
676  %res = sext <2 x i1> %cmp to <2 x i64>
677  ret <2 x i64> %res
678}
679
680; CHECK-LABEL: compare_slt_v2i64:
681; NO-SIMD128-NOT: i64x2
682; SIMD128-NEXT: .functype compare_slt_v2i64 (v128, v128) -> (v128){{$}}
683; SIMD128-NEXT: i64x2.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
684; SIMD128-NEXT: return $pop[[R]]{{$}}
685define <2 x i1> @compare_slt_v2i64 (<2 x i64> %x, <2 x i64> %y) {
686  %res = icmp slt <2 x i64> %x, %y
687  ret <2 x i1> %res
688}
689
690; CHECK-LABEL: compare_sext_slt_v2i64:
691; NO-SIMD128-NOT: i64x2
692; SIMD128-NEXT: .functype compare_sext_slt_v2i64 (v128, v128) -> (v128){{$}}
693; SIMD128-NEXT: i64x2.lt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
694; SIMD128-NEXT: return $pop[[R]]{{$}}
695define <2 x i64> @compare_sext_slt_v2i64 (<2 x i64> %x, <2 x i64> %y) {
696  %cmp = icmp slt <2 x i64> %x, %y
697  %res = sext <2 x i1> %cmp to <2 x i64>
698  ret <2 x i64> %res
699}
700
701; CHECK-LABEL: compare_ult_v2i64:
702; SIMD128-NEXT: .functype compare_ult_v2i64 (v128, v128) -> (v128){{$}}
703; SIMD128: i64.lt_u
704define <2 x i1> @compare_ult_v2i64 (<2 x i64> %x, <2 x i64> %y) {
705  %res = icmp ult <2 x i64> %x, %y
706  ret <2 x i1> %res
707}
708
709; CHECK-LABEL: compare_sext_ult_v2i64:
710; SIMD128-NEXT: .functype compare_sext_ult_v2i64 (v128, v128) -> (v128){{$}}
711; SIMD128: i64.lt_u
712define <2 x i64> @compare_sext_ult_v2i64 (<2 x i64> %x, <2 x i64> %y) {
713  %cmp = icmp ult <2 x i64> %x, %y
714  %res = sext <2 x i1> %cmp to <2 x i64>
715  ret <2 x i64> %res
716}
717
718; CHECK-LABEL: compare_sle_v2i64:
719; NO-SIMD128-NOT: i64x2
720; SIMD128-NEXT: .functype compare_sle_v2i64 (v128, v128) -> (v128){{$}}
721; SIMD128-NEXT: i64x2.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
722; SIMD128-NEXT: return $pop[[R]]{{$}}
723define <2 x i1> @compare_sle_v2i64 (<2 x i64> %x, <2 x i64> %y) {
724  %res = icmp sle <2 x i64> %x, %y
725  ret <2 x i1> %res
726}
727
728; CHECK-LABEL: compare_sext_sle_v2i64:
729; NO-SIMD128-NOT: i64x2
730; SIMD128-NEXT: .functype compare_sext_sle_v2i64 (v128, v128) -> (v128){{$}}
731; SIMD128-NEXT: i64x2.le_s $push[[R:[0-9]+]]=, $0, $1{{$}}
732; SIMD128-NEXT: return $pop[[R]]{{$}}
733define <2 x i64> @compare_sext_sle_v2i64 (<2 x i64> %x, <2 x i64> %y) {
734  %cmp = icmp sle <2 x i64> %x, %y
735  %res = sext <2 x i1> %cmp to <2 x i64>
736  ret <2 x i64> %res
737}
738
739; CHECK-LABEL: compare_ule_v2i64:
740; SIMD128-NEXT: .functype compare_ule_v2i64 (v128, v128) -> (v128){{$}}
741; SIMD128: i64.le_u
742define <2 x i1> @compare_ule_v2i64 (<2 x i64> %x, <2 x i64> %y) {
743  %res = icmp ule <2 x i64> %x, %y
744  ret <2 x i1> %res
745}
746
747; CHECK-LABEL: compare_sext_ule_v2i64:
748; SIMD128-NEXT: .functype compare_sext_ule_v2i64 (v128, v128) -> (v128){{$}}
749; SIMD128: i64.le_u
750define <2 x i64> @compare_sext_ule_v2i64 (<2 x i64> %x, <2 x i64> %y) {
751  %cmp = icmp ule <2 x i64> %x, %y
752  %res = sext <2 x i1> %cmp to <2 x i64>
753  ret <2 x i64> %res
754}
755
756; CHECK-LABEL: compare_sgt_v2i64:
757; NO-SIMD128-NOT: i64x2
758; SIMD128-NEXT: .functype compare_sgt_v2i64 (v128, v128) -> (v128){{$}}
759; SIMD128-NEXT: i64x2.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
760; SIMD128-NEXT: return $pop[[R]]{{$}}
761define <2 x i1> @compare_sgt_v2i64 (<2 x i64> %x, <2 x i64> %y) {
762  %res = icmp sgt <2 x i64> %x, %y
763  ret <2 x i1> %res
764}
765
766; CHECK-LABEL: compare_sext_sgt_v2i64:
767; NO-SIMD128-NOT: i64x2
768; SIMD128-NEXT: .functype compare_sext_sgt_v2i64 (v128, v128) -> (v128){{$}}
769; SIMD128-NEXT: i64x2.gt_s $push[[R:[0-9]+]]=, $0, $1{{$}}
770; SIMD128-NEXT: return $pop[[R]]{{$}}
771define <2 x i64> @compare_sext_sgt_v2i64 (<2 x i64> %x, <2 x i64> %y) {
772  %cmp = icmp sgt <2 x i64> %x, %y
773  %res = sext <2 x i1> %cmp to <2 x i64>
774  ret <2 x i64> %res
775}
776
777; CHECK-LABEL: compare_ugt_v2i64:
778; SIMD128-NEXT: .functype compare_ugt_v2i64 (v128, v128) -> (v128){{$}}
779; SIMD128: i64.gt_u
780define <2 x i1> @compare_ugt_v2i64 (<2 x i64> %x, <2 x i64> %y) {
781  %res = icmp ugt <2 x i64> %x, %y
782  ret <2 x i1> %res
783}
784
785; CHECK-LABEL: compare_sext_ugt_v2i64:
786; SIMD128-NEXT: .functype compare_sext_ugt_v2i64 (v128, v128) -> (v128){{$}}
787; SIMD128: i64.gt_u
788define <2 x i64> @compare_sext_ugt_v2i64 (<2 x i64> %x, <2 x i64> %y) {
789  %cmp = icmp ugt <2 x i64> %x, %y
790  %res = sext <2 x i1> %cmp to <2 x i64>
791  ret <2 x i64> %res
792}
793
794; CHECK-LABEL: compare_sge_v2i64:
795; NO-SIMD128-NOT: i64x2
796; SIMD128-NEXT: .functype compare_sge_v2i64 (v128, v128) -> (v128){{$}}
797; SIMD128-NEXT: i64x2.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
798; SIMD128-NEXT: return $pop[[R]]{{$}}
799define <2 x i1> @compare_sge_v2i64 (<2 x i64> %x, <2 x i64> %y) {
800  %res = icmp sge <2 x i64> %x, %y
801  ret <2 x i1> %res
802}
803
804; CHECK-LABEL: compare_sext_sge_v2i64:
805; NO-SIMD128-NOT: i64x2
806; SIMD128-NEXT: .functype compare_sext_sge_v2i64 (v128, v128) -> (v128){{$}}
807; SIMD128-NEXT: i64x2.ge_s $push[[R:[0-9]+]]=, $0, $1{{$}}
808; SIMD128-NEXT: return $pop[[R]]{{$}}
809define <2 x i64> @compare_sext_sge_v2i64 (<2 x i64> %x, <2 x i64> %y) {
810  %cmp = icmp sge <2 x i64> %x, %y
811  %res = sext <2 x i1> %cmp to <2 x i64>
812  ret <2 x i64> %res
813}
814
815; CHECK-LABEL: compare_uge_v2i64:
816; SIMD128-NEXT: .functype compare_uge_v2i64 (v128, v128) -> (v128){{$}}
817; SIMD128: i64.ge_u
818define <2 x i1> @compare_uge_v2i64 (<2 x i64> %x, <2 x i64> %y) {
819  %res = icmp uge <2 x i64> %x, %y
820  ret <2 x i1> %res
821}
822
823; CHECK-LABEL: compare_sext_uge_v2i64:
824; SIMD128-NEXT: .functype compare_sext_uge_v2i64 (v128, v128) -> (v128){{$}}
825; SIMD128: i64.ge_u
826define <2 x i64> @compare_sext_uge_v2i64 (<2 x i64> %x, <2 x i64> %y) {
827  %cmp = icmp uge <2 x i64> %x, %y
828  %res = sext <2 x i1> %cmp to <2 x i64>
829  ret <2 x i64> %res
830}
831
832; CHECK-LABEL: compare_oeq_v4f32:
833; NO-SIMD128-NOT: f32x4
834; SIMD128-NEXT: .functype compare_oeq_v4f32 (v128, v128) -> (v128){{$}}
835; SIMD128-NEXT: f32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
836; SIMD128-NEXT: return $pop[[R]]{{$}}
837define <4 x i1> @compare_oeq_v4f32 (<4 x float> %x, <4 x float> %y) {
838  %res = fcmp oeq <4 x float> %x, %y
839  ret <4 x i1> %res
840}
841
842; CHECK-LABEL: compare_oeq_nnan_v4f32:
843; NO-SIMD128-NOT: f32x4
844; SIMD128-NEXT: .functype compare_oeq_nnan_v4f32 (v128, v128) -> (v128){{$}}
845; SIMD128-NEXT: f32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
846; SIMD128-NEXT: return $pop[[R]]{{$}}
847define <4 x i1> @compare_oeq_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
848  %res = fcmp nnan oeq <4 x float> %x, %y
849  ret <4 x i1> %res
850}
851
852; CHECK-LABEL: compare_sext_oeq_v4f32:
853; NO-SIMD128-NOT: f32x4
854; SIMD128-NEXT: .functype compare_sext_oeq_v4f32 (v128, v128) -> (v128){{$}}
855; SIMD128-NEXT: f32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
856; SIMD128-NEXT: return $pop[[R]]{{$}}
857define <4 x i32> @compare_sext_oeq_v4f32 (<4 x float> %x, <4 x float> %y) {
858  %cmp = fcmp oeq <4 x float> %x, %y
859  %res = sext <4 x i1> %cmp to <4 x i32>
860  ret <4 x i32> %res
861}
862
863; CHECK-LABEL: compare_sext_oeq_nnan_v4f32:
864; NO-SIMD128-NOT: f32x4
865; SIMD128-NEXT: .functype compare_sext_oeq_nnan_v4f32 (v128, v128) -> (v128){{$}}
866; SIMD128-NEXT: f32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
867; SIMD128-NEXT: return $pop[[R]]{{$}}
868define <4 x i32> @compare_sext_oeq_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
869  %cmp = fcmp nnan oeq <4 x float> %x, %y
870  %res = sext <4 x i1> %cmp to <4 x i32>
871  ret <4 x i32> %res
872}
873
874; CHECK-LABEL: compare_ogt_v4f32:
875; NO-SIMD128-NOT: f32x4
876; SIMD128-NEXT: .functype compare_ogt_v4f32 (v128, v128) -> (v128){{$}}
877; SIMD128-NEXT: f32x4.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
878; SIMD128-NEXT: return $pop[[R]]{{$}}
879define <4 x i1> @compare_ogt_v4f32 (<4 x float> %x, <4 x float> %y) {
880  %res = fcmp ogt <4 x float> %x, %y
881  ret <4 x i1> %res
882}
883
884; CHECK-LABEL: compare_ogt_nnan_v4f32:
885; NO-SIMD128-NOT: f32x4
886; SIMD128-NEXT: .functype compare_ogt_nnan_v4f32 (v128, v128) -> (v128){{$}}
887; SIMD128-NEXT: f32x4.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
888; SIMD128-NEXT: return $pop[[R]]{{$}}
889define <4 x i1> @compare_ogt_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
890  %res = fcmp nnan ogt <4 x float> %x, %y
891  ret <4 x i1> %res
892}
893
894; CHECK-LABEL: compare_sext_ogt_v4f32:
895; NO-SIMD128-NOT: f32x4
896; SIMD128-NEXT: .functype compare_sext_ogt_v4f32 (v128, v128) -> (v128){{$}}
897; SIMD128-NEXT: f32x4.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
898; SIMD128-NEXT: return $pop[[R]]{{$}}
899define <4 x i32> @compare_sext_ogt_v4f32 (<4 x float> %x, <4 x float> %y) {
900  %cmp = fcmp ogt <4 x float> %x, %y
901  %res = sext <4 x i1> %cmp to <4 x i32>
902  ret <4 x i32> %res
903}
904
905; CHECK-LABEL: compare_sext_ogt_nnan_v4f32:
906; NO-SIMD128-NOT: f32x4
907; SIMD128-NEXT: .functype compare_sext_ogt_nnan_v4f32 (v128, v128) -> (v128){{$}}
908; SIMD128-NEXT: f32x4.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
909; SIMD128-NEXT: return $pop[[R]]{{$}}
910define <4 x i32> @compare_sext_ogt_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
911  %cmp = fcmp nnan ogt <4 x float> %x, %y
912  %res = sext <4 x i1> %cmp to <4 x i32>
913  ret <4 x i32> %res
914}
915
916; CHECK-LABEL: compare_oge_v4f32:
917; NO-SIMD128-NOT: f32x4
918; SIMD128-NEXT: .functype compare_oge_v4f32 (v128, v128) -> (v128){{$}}
919; SIMD128-NEXT: f32x4.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
920; SIMD128-NEXT: return $pop[[R]]{{$}}
921define <4 x i1> @compare_oge_v4f32 (<4 x float> %x, <4 x float> %y) {
922  %res = fcmp oge <4 x float> %x, %y
923  ret <4 x i1> %res
924}
925
926; CHECK-LABEL: compare_oge_nnan_v4f32:
927; NO-SIMD128-NOT: f32x4
928; SIMD128-NEXT: .functype compare_oge_nnan_v4f32 (v128, v128) -> (v128){{$}}
929; SIMD128-NEXT: f32x4.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
930; SIMD128-NEXT: return $pop[[R]]{{$}}
931define <4 x i1> @compare_oge_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
932  %res = fcmp nnan oge <4 x float> %x, %y
933  ret <4 x i1> %res
934}
935
936; CHECK-LABEL: compare_sext_oge_v4f32:
937; NO-SIMD128-NOT: f32x4
938; SIMD128-NEXT: .functype compare_sext_oge_v4f32 (v128, v128) -> (v128){{$}}
939; SIMD128-NEXT: f32x4.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
940; SIMD128-NEXT: return $pop[[R]]{{$}}
941define <4 x i32> @compare_sext_oge_v4f32 (<4 x float> %x, <4 x float> %y) {
942  %cmp = fcmp oge <4 x float> %x, %y
943  %res = sext <4 x i1> %cmp to <4 x i32>
944  ret <4 x i32> %res
945}
946
947; CHECK-LABEL: compare_sext_oge_nnan_v4f32:
948; NO-SIMD128-NOT: f32x4
949; SIMD128-NEXT: .functype compare_sext_oge_nnan_v4f32 (v128, v128) -> (v128){{$}}
950; SIMD128-NEXT: f32x4.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
951; SIMD128-NEXT: return $pop[[R]]{{$}}
952define <4 x i32> @compare_sext_oge_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
953  %cmp = fcmp nnan oge <4 x float> %x, %y
954  %res = sext <4 x i1> %cmp to <4 x i32>
955  ret <4 x i32> %res
956}
957
958; CHECK-LABEL: compare_olt_v4f32:
959; NO-SIMD128-NOT: f32x4
960; SIMD128-NEXT: .functype compare_olt_v4f32 (v128, v128) -> (v128){{$}}
961; SIMD128-NEXT: f32x4.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
962; SIMD128-NEXT: return $pop[[R]]{{$}}
963define <4 x i1> @compare_olt_v4f32 (<4 x float> %x, <4 x float> %y) {
964  %res = fcmp olt <4 x float> %x, %y
965  ret <4 x i1> %res
966}
967
968; CHECK-LABEL: compare_olt_nnan_v4f32:
969; NO-SIMD128-NOT: f32x4
970; SIMD128-NEXT: .functype compare_olt_nnan_v4f32 (v128, v128) -> (v128){{$}}
971; SIMD128-NEXT: f32x4.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
972; SIMD128-NEXT: return $pop[[R]]{{$}}
973define <4 x i1> @compare_olt_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
974  %res = fcmp nnan olt <4 x float> %x, %y
975  ret <4 x i1> %res
976}
977
978; CHECK-LABEL: compare_sext_olt_v4f32:
979; NO-SIMD128-NOT: f32x4
980; SIMD128-NEXT: .functype compare_sext_olt_v4f32 (v128, v128) -> (v128){{$}}
981; SIMD128-NEXT: f32x4.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
982; SIMD128-NEXT: return $pop[[R]]{{$}}
983define <4 x i32> @compare_sext_olt_v4f32 (<4 x float> %x, <4 x float> %y) {
984  %cmp = fcmp olt <4 x float> %x, %y
985  %res = sext <4 x i1> %cmp to <4 x i32>
986  ret <4 x i32> %res
987}
988
989; CHECK-LABEL: compare_sext_olt_nnan_v4f32:
990; NO-SIMD128-NOT: f32x4
991; SIMD128-NEXT: .functype compare_sext_olt_nnan_v4f32 (v128, v128) -> (v128){{$}}
992; SIMD128-NEXT: f32x4.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
993; SIMD128-NEXT: return $pop[[R]]{{$}}
994define <4 x i32> @compare_sext_olt_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
995  %cmp = fcmp nnan olt <4 x float> %x, %y
996  %res = sext <4 x i1> %cmp to <4 x i32>
997  ret <4 x i32> %res
998}
999
1000; CHECK-LABEL: compare_ole_v4f32:
1001; NO-SIMD128-NOT: f32x4
1002; SIMD128-NEXT: .functype compare_ole_v4f32 (v128, v128) -> (v128){{$}}
1003; SIMD128-NEXT: f32x4.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1004; SIMD128-NEXT: return $pop[[R]]{{$}}
1005define <4 x i1> @compare_ole_v4f32 (<4 x float> %x, <4 x float> %y) {
1006  %res = fcmp ole <4 x float> %x, %y
1007  ret <4 x i1> %res
1008}
1009
1010; CHECK-LABEL: compare_ole_nnan_v4f32:
1011; NO-SIMD128-NOT: f32x4
1012; SIMD128-NEXT: .functype compare_ole_nnan_v4f32 (v128, v128) -> (v128){{$}}
1013; SIMD128-NEXT: f32x4.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1014; SIMD128-NEXT: return $pop[[R]]{{$}}
1015define <4 x i1> @compare_ole_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1016  %res = fcmp nnan ole <4 x float> %x, %y
1017  ret <4 x i1> %res
1018}
1019
1020; CHECK-LABEL: compare_sext_ole_v4f32:
1021; NO-SIMD128-NOT: f32x4
1022; SIMD128-NEXT: .functype compare_sext_ole_v4f32 (v128, v128) -> (v128){{$}}
1023; SIMD128-NEXT: f32x4.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1024; SIMD128-NEXT: return $pop[[R]]{{$}}
1025define <4 x i32> @compare_sext_ole_v4f32 (<4 x float> %x, <4 x float> %y) {
1026  %cmp = fcmp ole <4 x float> %x, %y
1027  %res = sext <4 x i1> %cmp to <4 x i32>
1028  ret <4 x i32> %res
1029}
1030
1031; CHECK-LABEL: compare_sext_ole_nnan_v4f32:
1032; NO-SIMD128-NOT: f32x4
1033; SIMD128-NEXT: .functype compare_sext_ole_nnan_v4f32 (v128, v128) -> (v128){{$}}
1034; SIMD128-NEXT: f32x4.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1035; SIMD128-NEXT: return $pop[[R]]{{$}}
1036define <4 x i32> @compare_sext_ole_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1037  %cmp = fcmp nnan ole <4 x float> %x, %y
1038  %res = sext <4 x i1> %cmp to <4 x i32>
1039  ret <4 x i32> %res
1040}
1041
1042; CHECK-LABEL: compare_one_v4f32:
1043; NO-SIMD128-NOT: f32x4
1044; SIMD128-NEXT: .functype compare_one_v4f32 (v128, v128) -> (v128){{$}}
1045; SIMD128-NEXT: f32x4.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1046; SIMD128-NEXT: f32x4.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1047; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1048; SIMD128-NEXT: return $pop[[R]]{{$}}
1049define <4 x i1> @compare_one_v4f32 (<4 x float> %x, <4 x float> %y) {
1050  %res = fcmp one <4 x float> %x, %y
1051  ret <4 x i1> %res
1052}
1053
1054; CHECK-LABEL: compare_one_nnan_v4f32:
1055; NO-SIMD128-NOT: f32x4
1056; SIMD128-NEXT: .functype compare_one_nnan_v4f32 (v128, v128) -> (v128){{$}}
1057; SIMD128-NEXT: f32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1058; SIMD128-NEXT: return $pop[[R]]{{$}}
1059define <4 x i1> @compare_one_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1060  %res = fcmp nnan one <4 x float> %x, %y
1061  ret <4 x i1> %res
1062}
1063
1064; CHECK-LABEL: compare_sext_one_v4f32:
1065; NO-SIMD128-NOT: f32x4
1066; SIMD128-NEXT: .functype compare_sext_one_v4f32 (v128, v128) -> (v128){{$}}
1067; SIMD128-NEXT: f32x4.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1068; SIMD128-NEXT: f32x4.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1069; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1070; SIMD128-NEXT: return $pop[[R]]{{$}}
1071define <4 x i32> @compare_sext_one_v4f32 (<4 x float> %x, <4 x float> %y) {
1072  %cmp = fcmp one <4 x float> %x, %y
1073  %res = sext <4 x i1> %cmp to <4 x i32>
1074  ret <4 x i32> %res
1075}
1076
1077; CHECK-LABEL: compare_sext_one_nnan_v4f32:
1078; NO-SIMD128-NOT: f32x4
1079; SIMD128-NEXT: .functype compare_sext_one_nnan_v4f32 (v128, v128) -> (v128){{$}}
1080; SIMD128-NEXT: f32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1081; SIMD128-NEXT: return $pop[[R]]{{$}}
1082define <4 x i32> @compare_sext_one_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1083  %cmp = fcmp nnan one <4 x float> %x, %y
1084  %res = sext <4 x i1> %cmp to <4 x i32>
1085  ret <4 x i32> %res
1086}
1087
1088; CHECK-LABEL: compare_ord_v4f32:
1089; NO-SIMD128-NOT: f32x4
1090; SIMD128-NEXT: .functype compare_ord_v4f32 (v128, v128) -> (v128){{$}}
1091; SIMD128-NEXT: f32x4.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1092; SIMD128-NEXT: f32x4.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1093; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1094; SIMD128-NEXT: return   $pop[[R]]{{$}}
1095define <4 x i1> @compare_ord_v4f32 (<4 x float> %x, <4 x float> %y) {
1096  %res = fcmp ord <4 x float> %x, %y
1097  ret <4 x i1> %res
1098}
1099
1100; CHECK-LABEL: compare_ord_nnan_v4f32:
1101; NO-SIMD128-NOT: f32x4
1102; SIMD128-NEXT: .functype compare_ord_nnan_v4f32 (v128, v128) -> (v128){{$}}
1103; SIMD128-NEXT: f32x4.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1104; SIMD128-NEXT: f32x4.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1105; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1106; SIMD128-NEXT: return   $pop[[R]]{{$}}
1107define <4 x i1> @compare_ord_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1108  %res = fcmp nnan ord <4 x float> %x, %y
1109  ret <4 x i1> %res
1110}
1111
1112; CHECK-LABEL: compare_sext_ord_v4f32:
1113; NO-SIMD128-NOT: f32x4
1114; SIMD128-NEXT: .functype compare_sext_ord_v4f32 (v128, v128) -> (v128){{$}}
1115; SIMD128-NEXT: f32x4.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1116; SIMD128-NEXT: f32x4.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1117; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1118; SIMD128-NEXT: return   $pop[[R]]{{$}}
1119define <4 x i32> @compare_sext_ord_v4f32 (<4 x float> %x, <4 x float> %y) {
1120  %cmp = fcmp ord <4 x float> %x, %y
1121  %res = sext <4 x i1> %cmp to <4 x i32>
1122  ret <4 x i32> %res
1123}
1124
1125; CHECK-LABEL: compare_sext_ord_nnan_v4f32:
1126; NO-SIMD128-NOT: f32x4
1127; SIMD128-NEXT: .functype compare_sext_ord_nnan_v4f32 (v128, v128) -> (v128){{$}}
1128; SIMD128-NEXT: f32x4.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1129; SIMD128-NEXT: f32x4.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1130; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1131; SIMD128-NEXT: return   $pop[[R]]{{$}}
1132define <4 x i32> @compare_sext_ord_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1133  %cmp = fcmp nnan ord <4 x float> %x, %y
1134  %res = sext <4 x i1> %cmp to <4 x i32>
1135  ret <4 x i32> %res
1136}
1137
1138; CHECK-LABEL: compare_ueq_v4f32:
1139; NO-SIMD128-NOT: f32x4
1140; SIMD128-NEXT: .functype compare_ueq_v4f32 (v128, v128) -> (v128){{$}}
1141; SIMD128-NEXT: f32x4.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1142; SIMD128-NEXT: f32x4.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1143; SIMD128-NEXT: v128.or $push[[T2:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1144; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T2]]{{$}}
1145; SIMD128-NEXT: return $pop[[R]]{{$}}
1146define <4 x i1> @compare_ueq_v4f32 (<4 x float> %x, <4 x float> %y) {
1147  %res = fcmp ueq <4 x float> %x, %y
1148  ret <4 x i1> %res
1149}
1150
1151; CHECK-LABEL: compare_ueq_nnan_v4f32:
1152; NO-SIMD128-NOT: f32x4
1153; SIMD128-NEXT: .functype compare_ueq_nnan_v4f32 (v128, v128) -> (v128){{$}}
1154; SIMD128-NEXT: f32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1155; SIMD128-NEXT: return $pop[[R]]{{$}}
1156define <4 x i1> @compare_ueq_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1157  %res = fcmp nnan ueq <4 x float> %x, %y
1158  ret <4 x i1> %res
1159}
1160
1161; CHECK-LABEL: compare_sext_ueq_v4f32:
1162; NO-SIMD128-NOT: f32x4
1163; SIMD128-NEXT: .functype compare_sext_ueq_v4f32 (v128, v128) -> (v128){{$}}
1164; SIMD128-NEXT: f32x4.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1165; SIMD128-NEXT: f32x4.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1166; SIMD128-NEXT: v128.or $push[[T2:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1167; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T2]]{{$}}
1168; SIMD128-NEXT: return $pop[[R]]
1169define <4 x i32> @compare_sext_ueq_v4f32 (<4 x float> %x, <4 x float> %y) {
1170  %cmp = fcmp ueq <4 x float> %x, %y
1171  %res = sext <4 x i1> %cmp to <4 x i32>
1172  ret <4 x i32> %res
1173}
1174
1175; CHECK-LABEL: compare_sext_ueq_nnan_v4f32:
1176; NO-SIMD128-NOT: f32x4
1177; SIMD128-NEXT: .functype compare_sext_ueq_nnan_v4f32 (v128, v128) -> (v128){{$}}
1178; SIMD128-NEXT: f32x4.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1179; SIMD128-NEXT: return $pop[[R]]
1180define <4 x i32> @compare_sext_ueq_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1181  %cmp = fcmp nnan ueq <4 x float> %x, %y
1182  %res = sext <4 x i1> %cmp to <4 x i32>
1183  ret <4 x i32> %res
1184}
1185
1186; CHECK-LABEL: compare_ugt_v4f32:
1187; NO-SIMD128-NOT: f32x4
1188; SIMD128-NEXT: .functype compare_ugt_v4f32 (v128, v128) -> (v128){{$}}
1189; SIMD128-NEXT: f32x4.le $push[[T0:[0-9]+]]=, $0, $1{{$}}
1190; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1191; SIMD128-NEXT: return $pop[[R]]{{$}}
1192define <4 x i1> @compare_ugt_v4f32 (<4 x float> %x, <4 x float> %y) {
1193  %res = fcmp ugt <4 x float> %x, %y
1194  ret <4 x i1> %res
1195}
1196
1197; CHECK-LABEL: compare_ugt_nnan_v4f32:
1198; NO-SIMD128-NOT: f32x4
1199; SIMD128-NEXT: .functype compare_ugt_nnan_v4f32 (v128, v128) -> (v128){{$}}
1200; SIMD128-NEXT: f32x4.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1201; SIMD128-NEXT: return $pop[[R]]{{$}}
1202define <4 x i1> @compare_ugt_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1203  %res = fcmp nnan ugt <4 x float> %x, %y
1204  ret <4 x i1> %res
1205}
1206
1207; CHECK-LABEL: compare_sext_ugt_v4f32:
1208; NO-SIMD128-NOT: f32x4
1209; SIMD128-NEXT: .functype compare_sext_ugt_v4f32 (v128, v128) -> (v128){{$}}
1210; SIMD128-NEXT: f32x4.le $push[[T0:[0-9]+]]=, $0, $1{{$}}
1211; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1212; SIMD128-NEXT: return $pop[[R]]{{$}}
1213define <4 x i32> @compare_sext_ugt_v4f32 (<4 x float> %x, <4 x float> %y) {
1214  %cmp = fcmp ugt <4 x float> %x, %y
1215  %res = sext <4 x i1> %cmp to <4 x i32>
1216  ret <4 x i32> %res
1217}
1218
1219; CHECK-LABEL: compare_sext_ugt_nnan_v4f32:
1220; NO-SIMD128-NOT: f32x4
1221; SIMD128-NEXT: .functype compare_sext_ugt_nnan_v4f32 (v128, v128) -> (v128){{$}}
1222; SIMD128-NEXT: f32x4.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1223; SIMD128-NEXT: return $pop[[R]]{{$}}
1224define <4 x i32> @compare_sext_ugt_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1225  %cmp = fcmp nnan ugt <4 x float> %x, %y
1226  %res = sext <4 x i1> %cmp to <4 x i32>
1227  ret <4 x i32> %res
1228}
1229
1230; CHECK-LABEL: compare_uge_v4f32:
1231; NO-SIMD128-NOT: f32x4
1232; SIMD128-NEXT: .functype compare_uge_v4f32 (v128, v128) -> (v128){{$}}
1233; SIMD128-NEXT: f32x4.lt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1234; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1235; SIMD128-NEXT: return $pop[[R]]{{$}}
1236define <4 x i1> @compare_uge_v4f32 (<4 x float> %x, <4 x float> %y) {
1237  %res = fcmp uge <4 x float> %x, %y
1238  ret <4 x i1> %res
1239}
1240
1241; CHECK-LABEL: compare_uge_nnan_v4f32:
1242; NO-SIMD128-NOT: f32x4
1243; SIMD128-NEXT: .functype compare_uge_nnan_v4f32 (v128, v128) -> (v128){{$}}
1244; SIMD128-NEXT: f32x4.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1245; SIMD128-NEXT: return $pop[[R]]{{$}}
1246define <4 x i1> @compare_uge_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1247  %res = fcmp nnan uge <4 x float> %x, %y
1248  ret <4 x i1> %res
1249}
1250
1251; CHECK-LABEL: compare_sext_uge_v4f32:
1252; NO-SIMD128-NOT: f32x4
1253; SIMD128-NEXT: .functype compare_sext_uge_v4f32 (v128, v128) -> (v128){{$}}
1254; SIMD128-NEXT: f32x4.lt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1255; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1256; SIMD128-NEXT: return $pop[[R]]{{$}}
1257define <4 x i32> @compare_sext_uge_v4f32 (<4 x float> %x, <4 x float> %y) {
1258  %cmp = fcmp uge <4 x float> %x, %y
1259  %res = sext <4 x i1> %cmp to <4 x i32>
1260  ret <4 x i32> %res
1261}
1262
1263; CHECK-LABEL: compare_sext_uge_nnan_v4f32:
1264; NO-SIMD128-NOT: f32x4
1265; SIMD128-NEXT: .functype compare_sext_uge_nnan_v4f32 (v128, v128) -> (v128){{$}}
1266; SIMD128-NEXT: f32x4.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1267; SIMD128-NEXT: return $pop[[R]]{{$}}
1268define <4 x i32> @compare_sext_uge_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1269  %cmp = fcmp nnan uge <4 x float> %x, %y
1270  %res = sext <4 x i1> %cmp to <4 x i32>
1271  ret <4 x i32> %res
1272}
1273
1274; CHECK-LABEL: compare_ult_v4f32:
1275; NO-SIMD128-NOT: f32x4
1276; SIMD128-NEXT: .functype compare_ult_v4f32 (v128, v128) -> (v128){{$}}
1277; SIMD128-NEXT: f32x4.ge $push[[T0:[0-9]+]]=, $0, $1{{$}}
1278; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1279; SIMD128-NEXT: return $pop[[R]]{{$}}
1280define <4 x i1> @compare_ult_v4f32 (<4 x float> %x, <4 x float> %y) {
1281  %res = fcmp ult <4 x float> %x, %y
1282  ret <4 x i1> %res
1283}
1284
1285; CHECK-LABEL: compare_ult_nnan_v4f32:
1286; NO-SIMD128-NOT: f32x4
1287; SIMD128-NEXT: .functype compare_ult_nnan_v4f32 (v128, v128) -> (v128){{$}}
1288; SIMD128-NEXT: f32x4.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1289; SIMD128-NEXT: return $pop[[R]]{{$}}
1290define <4 x i1> @compare_ult_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1291  %res = fcmp nnan ult <4 x float> %x, %y
1292  ret <4 x i1> %res
1293}
1294
1295; CHECK-LABEL: compare_sext_ult_v4f32:
1296; NO-SIMD128-NOT: f32x4
1297; SIMD128-NEXT: .functype compare_sext_ult_v4f32 (v128, v128) -> (v128){{$}}
1298; SIMD128-NEXT: f32x4.ge $push[[T0:[0-9]+]]=, $0, $1{{$}}
1299; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1300; SIMD128-NEXT: return $pop[[R]]{{$}}
1301define <4 x i32> @compare_sext_ult_v4f32 (<4 x float> %x, <4 x float> %y) {
1302  %cmp = fcmp ult <4 x float> %x, %y
1303  %res = sext <4 x i1> %cmp to <4 x i32>
1304  ret <4 x i32> %res
1305}
1306
1307; CHECK-LABEL: compare_sext_ult_nnan_v4f32:
1308; NO-SIMD128-NOT: f32x4
1309; SIMD128-NEXT: .functype compare_sext_ult_nnan_v4f32 (v128, v128) -> (v128){{$}}
1310; SIMD128-NEXT: f32x4.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1311; SIMD128-NEXT: return $pop[[R]]{{$}}
1312define <4 x i32> @compare_sext_ult_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1313  %cmp = fcmp nnan ult <4 x float> %x, %y
1314  %res = sext <4 x i1> %cmp to <4 x i32>
1315  ret <4 x i32> %res
1316}
1317
1318; CHECK-LABEL: compare_ule_v4f32:
1319; NO-SIMD128-NOT: f32x4
1320; SIMD128-NEXT: .functype compare_ule_v4f32 (v128, v128) -> (v128){{$}}
1321; SIMD128-NEXT: f32x4.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1322; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1323; SIMD128-NEXT: return $pop[[R]]{{$}}
1324define <4 x i1> @compare_ule_v4f32 (<4 x float> %x, <4 x float> %y) {
1325  %res = fcmp ule <4 x float> %x, %y
1326  ret <4 x i1> %res
1327}
1328
1329; CHECK-LABEL: compare_ule_nnan_v4f32:
1330; NO-SIMD128-NOT: f32x4
1331; SIMD128-NEXT: .functype compare_ule_nnan_v4f32 (v128, v128) -> (v128){{$}}
1332; SIMD128-NEXT: f32x4.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1333; SIMD128-NEXT: return $pop[[R]]{{$}}
1334define <4 x i1> @compare_ule_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1335  %res = fcmp nnan ule <4 x float> %x, %y
1336  ret <4 x i1> %res
1337}
1338
1339; CHECK-LABEL: compare_sext_ule_v4f32:
1340; NO-SIMD128-NOT: f32x4
1341; SIMD128-NEXT: .functype compare_sext_ule_v4f32 (v128, v128) -> (v128){{$}}
1342; SIMD128-NEXT: f32x4.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1343; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1344; SIMD128-NEXT: return $pop[[R]]{{$}}
1345define <4 x i32> @compare_sext_ule_v4f32 (<4 x float> %x, <4 x float> %y) {
1346  %cmp = fcmp ule <4 x float> %x, %y
1347  %res = sext <4 x i1> %cmp to <4 x i32>
1348  ret <4 x i32> %res
1349}
1350
1351; CHECK-LABEL: compare_sext_ule_nnan_v4f32:
1352; NO-SIMD128-NOT: f32x4
1353; SIMD128-NEXT: .functype compare_sext_ule_nnan_v4f32 (v128, v128) -> (v128){{$}}
1354; SIMD128-NEXT: f32x4.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1355; SIMD128-NEXT: return $pop[[R]]{{$}}
1356define <4 x i32> @compare_sext_ule_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1357  %cmp = fcmp nnan ule <4 x float> %x, %y
1358  %res = sext <4 x i1> %cmp to <4 x i32>
1359  ret <4 x i32> %res
1360}
1361
1362; CHECK-LABEL: compare_une_v4f32:
1363; NO-SIMD128-NOT: f32x4
1364; SIMD128-NEXT: .functype compare_une_v4f32 (v128, v128) -> (v128){{$}}
1365; SIMD128-NEXT: f32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}{{$}}
1366; SIMD128-NEXT: return $pop[[R]]{{$}}
1367define <4 x i1> @compare_une_v4f32 (<4 x float> %x, <4 x float> %y) {
1368  %res = fcmp une <4 x float> %x, %y
1369  ret <4 x i1> %res
1370}
1371
1372; CHECK-LABEL: compare_une_nnan_v4f32:
1373; NO-SIMD128-NOT: f32x4
1374; SIMD128-NEXT: .functype compare_une_nnan_v4f32 (v128, v128) -> (v128){{$}}
1375; SIMD128-NEXT: f32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}{{$}}
1376; SIMD128-NEXT: return $pop[[R]]{{$}}
1377define <4 x i1> @compare_une_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1378  %res = fcmp nnan une <4 x float> %x, %y
1379  ret <4 x i1> %res
1380}
1381
1382; CHECK-LABEL: compare_sext_une_v4f32:
1383; NO-SIMD128-NOT: f32x4
1384; SIMD128-NEXT: .functype compare_sext_une_v4f32 (v128, v128) -> (v128){{$}}
1385; SIMD128-NEXT: f32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1386; SIMD128-NEXT: return $pop[[R]]{{$}}
1387define <4 x i32> @compare_sext_une_v4f32 (<4 x float> %x, <4 x float> %y) {
1388  %cmp = fcmp une <4 x float> %x, %y
1389  %res = sext <4 x i1> %cmp to <4 x i32>
1390  ret <4 x i32> %res
1391}
1392
1393; CHECK-LABEL: compare_sext_une_nnan_v4f32:
1394; NO-SIMD128-NOT: f32x4
1395; SIMD128-NEXT: .functype compare_sext_une_nnan_v4f32 (v128, v128) -> (v128){{$}}
1396; SIMD128-NEXT: f32x4.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1397; SIMD128-NEXT: return $pop[[R]]{{$}}
1398define <4 x i32> @compare_sext_une_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1399  %cmp = fcmp nnan une <4 x float> %x, %y
1400  %res = sext <4 x i1> %cmp to <4 x i32>
1401  ret <4 x i32> %res
1402}
1403
1404; CHECK-LABEL: compare_uno_v4f32:
1405; NO-SIMD128-NOT: f32x4
1406; SIMD128-NEXT: .functype compare_uno_v4f32 (v128, v128) -> (v128){{$}}
1407; SIMD128-NEXT: f32x4.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
1408; SIMD128-NEXT: f32x4.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
1409; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1410; SIMD128-NEXT: return $pop[[R]]{{$}}
1411define <4 x i1> @compare_uno_v4f32 (<4 x float> %x, <4 x float> %y) {
1412  %res = fcmp uno <4 x float> %x, %y
1413  ret <4 x i1> %res
1414}
1415
1416; CHECK-LABEL: compare_uno_nnan_v4f32:
1417; NO-SIMD128-NOT: f32x4
1418; SIMD128-NEXT: .functype compare_uno_nnan_v4f32 (v128, v128) -> (v128){{$}}
1419; SIMD128-NEXT: f32x4.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
1420; SIMD128-NEXT: f32x4.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
1421; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1422; SIMD128-NEXT: return $pop[[R]]{{$}}
1423define <4 x i1> @compare_uno_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1424  %res = fcmp nnan uno <4 x float> %x, %y
1425  ret <4 x i1> %res
1426}
1427
1428; CHECK-LABEL: compare_sext_uno_v4f32:
1429; NO-SIMD128-NOT: f32x4
1430; SIMD128-NEXT: .functype compare_sext_uno_v4f32 (v128, v128) -> (v128){{$}}
1431; SIMD128-NEXT: f32x4.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
1432; SIMD128-NEXT: f32x4.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
1433; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1434; SIMD128-NEXT: return $pop[[R]]{{$}}
1435define <4 x i32> @compare_sext_uno_v4f32 (<4 x float> %x, <4 x float> %y) {
1436  %cmp = fcmp uno <4 x float> %x, %y
1437  %res = sext <4 x i1> %cmp to <4 x i32>
1438  ret <4 x i32> %res
1439}
1440
1441; CHECK-LABEL: compare_sext_uno_nnan_v4f32:
1442; NO-SIMD128-NOT: f32x4
1443; SIMD128-NEXT: .functype compare_sext_uno_nnan_v4f32 (v128, v128) -> (v128){{$}}
1444; SIMD128-NEXT: f32x4.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
1445; SIMD128-NEXT: f32x4.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
1446; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1447; SIMD128-NEXT: return $pop[[R]]{{$}}
1448define <4 x i32> @compare_sext_uno_nnan_v4f32 (<4 x float> %x, <4 x float> %y) {
1449  %cmp = fcmp nnan uno <4 x float> %x, %y
1450  %res = sext <4 x i1> %cmp to <4 x i32>
1451  ret <4 x i32> %res
1452}
1453
1454; CHECK-LABEL: compare_oeq_v2f64:
1455; NO-SIMD128-NOT: f64x2
1456; SIMD128-NEXT: .functype compare_oeq_v2f64 (v128, v128) -> (v128){{$}}
1457; SIMD128-NEXT: f64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1458; SIMD128-NEXT: return $pop[[R]]{{$}}
1459define <2 x i1> @compare_oeq_v2f64 (<2 x double> %x, <2 x double> %y) {
1460  %res = fcmp oeq <2 x double> %x, %y
1461  ret <2 x i1> %res
1462}
1463
1464; CHECK-LABEL: compare_oeq_nnan_v2f64:
1465; NO-SIMD128-NOT: f64x2
1466; SIMD128-NEXT: .functype compare_oeq_nnan_v2f64 (v128, v128) -> (v128){{$}}
1467; SIMD128-NEXT: f64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1468; SIMD128-NEXT: return $pop[[R]]{{$}}
1469define <2 x i1> @compare_oeq_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1470  %res = fcmp nnan oeq <2 x double> %x, %y
1471  ret <2 x i1> %res
1472}
1473
1474; CHECK-LABEL: compare_sext_oeq_v2f64:
1475; NO-SIMD128-NOT: f64x2
1476; SIMD128-NEXT: .functype compare_sext_oeq_v2f64 (v128, v128) -> (v128){{$}}
1477; SIMD128-NEXT: f64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1478; SIMD128-NEXT: return $pop[[R]]{{$}}
1479define <2 x i64> @compare_sext_oeq_v2f64 (<2 x double> %x, <2 x double> %y) {
1480  %cmp = fcmp oeq <2 x double> %x, %y
1481  %res = sext <2 x i1> %cmp to <2 x i64>
1482  ret <2 x i64> %res
1483}
1484
1485; CHECK-LABEL: compare_sext_oeq_nnan_v2f64:
1486; NO-SIMD128-NOT: f64x2
1487; SIMD128-NEXT: .functype compare_sext_oeq_nnan_v2f64 (v128, v128) -> (v128){{$}}
1488; SIMD128-NEXT: f64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1489; SIMD128-NEXT: return $pop[[R]]{{$}}
1490define <2 x i64> @compare_sext_oeq_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1491  %cmp = fcmp nnan oeq <2 x double> %x, %y
1492  %res = sext <2 x i1> %cmp to <2 x i64>
1493  ret <2 x i64> %res
1494}
1495
1496; CHECK-LABEL: compare_ogt_v2f64:
1497; NO-SIMD128-NOT: f64x2
1498; SIMD128-NEXT: .functype compare_ogt_v2f64 (v128, v128) -> (v128){{$}}
1499; SIMD128-NEXT: f64x2.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1500; SIMD128-NEXT: return $pop[[R]]{{$}}
1501define <2 x i1> @compare_ogt_v2f64 (<2 x double> %x, <2 x double> %y) {
1502  %res = fcmp ogt <2 x double> %x, %y
1503  ret <2 x i1> %res
1504}
1505
1506; CHECK-LABEL: compare_ogt_nnan_v2f64:
1507; NO-SIMD128-NOT: f64x2
1508; SIMD128-NEXT: .functype compare_ogt_nnan_v2f64 (v128, v128) -> (v128){{$}}
1509; SIMD128-NEXT: f64x2.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1510; SIMD128-NEXT: return $pop[[R]]{{$}}
1511define <2 x i1> @compare_ogt_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1512  %res = fcmp nnan ogt <2 x double> %x, %y
1513  ret <2 x i1> %res
1514}
1515
1516; CHECK-LABEL: compare_sext_ogt_v2f64:
1517; NO-SIMD128-NOT: f64x2
1518; SIMD128-NEXT: .functype compare_sext_ogt_v2f64 (v128, v128) -> (v128){{$}}
1519; SIMD128-NEXT: f64x2.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1520; SIMD128-NEXT: return $pop[[R]]{{$}}
1521define <2 x i64> @compare_sext_ogt_v2f64 (<2 x double> %x, <2 x double> %y) {
1522  %cmp = fcmp ogt <2 x double> %x, %y
1523  %res = sext <2 x i1> %cmp to <2 x i64>
1524  ret <2 x i64> %res
1525}
1526
1527; CHECK-LABEL: compare_sext_ogt_nnan_v2f64:
1528; NO-SIMD128-NOT: f64x2
1529; SIMD128-NEXT: .functype compare_sext_ogt_nnan_v2f64 (v128, v128) -> (v128){{$}}
1530; SIMD128-NEXT: f64x2.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1531; SIMD128-NEXT: return $pop[[R]]{{$}}
1532define <2 x i64> @compare_sext_ogt_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1533  %cmp = fcmp nnan ogt <2 x double> %x, %y
1534  %res = sext <2 x i1> %cmp to <2 x i64>
1535  ret <2 x i64> %res
1536}
1537
1538; CHECK-LABEL: compare_oge_v2f64:
1539; NO-SIMD128-NOT: f64x2
1540; SIMD128-NEXT: .functype compare_oge_v2f64 (v128, v128) -> (v128){{$}}
1541; SIMD128-NEXT: f64x2.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1542; SIMD128-NEXT: return $pop[[R]]{{$}}
1543define <2 x i1> @compare_oge_v2f64 (<2 x double> %x, <2 x double> %y) {
1544  %res = fcmp oge <2 x double> %x, %y
1545  ret <2 x i1> %res
1546}
1547
1548; CHECK-LABEL: compare_oge_nnan_v2f64:
1549; NO-SIMD128-NOT: f64x2
1550; SIMD128-NEXT: .functype compare_oge_nnan_v2f64 (v128, v128) -> (v128){{$}}
1551; SIMD128-NEXT: f64x2.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1552; SIMD128-NEXT: return $pop[[R]]{{$}}
1553define <2 x i1> @compare_oge_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1554  %res = fcmp nnan oge <2 x double> %x, %y
1555  ret <2 x i1> %res
1556}
1557
1558; CHECK-LABEL: compare_sext_oge_v2f64:
1559; NO-SIMD128-NOT: f64x2
1560; SIMD128-NEXT: .functype compare_sext_oge_v2f64 (v128, v128) -> (v128){{$}}
1561; SIMD128-NEXT: f64x2.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1562; SIMD128-NEXT: return $pop[[R]]{{$}}
1563define <2 x i64> @compare_sext_oge_v2f64 (<2 x double> %x, <2 x double> %y) {
1564  %cmp = fcmp oge <2 x double> %x, %y
1565  %res = sext <2 x i1> %cmp to <2 x i64>
1566  ret <2 x i64> %res
1567}
1568
1569; CHECK-LABEL: compare_sext_oge_nnan_v2f64:
1570; NO-SIMD128-NOT: f64x2
1571; SIMD128-NEXT: .functype compare_sext_oge_nnan_v2f64 (v128, v128) -> (v128){{$}}
1572; SIMD128-NEXT: f64x2.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1573; SIMD128-NEXT: return $pop[[R]]{{$}}
1574define <2 x i64> @compare_sext_oge_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1575  %cmp = fcmp nnan oge <2 x double> %x, %y
1576  %res = sext <2 x i1> %cmp to <2 x i64>
1577  ret <2 x i64> %res
1578}
1579
1580; CHECK-LABEL: compare_olt_v2f64:
1581; NO-SIMD128-NOT: f64x2
1582; SIMD128-NEXT: .functype compare_olt_v2f64 (v128, v128) -> (v128){{$}}
1583; SIMD128-NEXT: f64x2.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1584; SIMD128-NEXT: return $pop[[R]]{{$}}
1585define <2 x i1> @compare_olt_v2f64 (<2 x double> %x, <2 x double> %y) {
1586  %res = fcmp olt <2 x double> %x, %y
1587  ret <2 x i1> %res
1588}
1589
1590; CHECK-LABEL: compare_olt_nnan_v2f64:
1591; NO-SIMD128-NOT: f64x2
1592; SIMD128-NEXT: .functype compare_olt_nnan_v2f64 (v128, v128) -> (v128){{$}}
1593; SIMD128-NEXT: f64x2.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1594; SIMD128-NEXT: return $pop[[R]]{{$}}
1595define <2 x i1> @compare_olt_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1596  %res = fcmp nnan olt <2 x double> %x, %y
1597  ret <2 x i1> %res
1598}
1599
1600; CHECK-LABEL: compare_sext_olt_v2f64:
1601; NO-SIMD128-NOT: f64x2
1602; SIMD128-NEXT: .functype compare_sext_olt_v2f64 (v128, v128) -> (v128){{$}}
1603; SIMD128-NEXT: f64x2.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1604; SIMD128-NEXT: return $pop[[R]]{{$}}
1605define <2 x i64> @compare_sext_olt_v2f64 (<2 x double> %x, <2 x double> %y) {
1606  %cmp = fcmp olt <2 x double> %x, %y
1607  %res = sext <2 x i1> %cmp to <2 x i64>
1608  ret <2 x i64> %res
1609}
1610
1611; CHECK-LABEL: compare_sext_olt_nnan_v2f64:
1612; NO-SIMD128-NOT: f64x2
1613; SIMD128-NEXT: .functype compare_sext_olt_nnan_v2f64 (v128, v128) -> (v128){{$}}
1614; SIMD128-NEXT: f64x2.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1615; SIMD128-NEXT: return $pop[[R]]{{$}}
1616define <2 x i64> @compare_sext_olt_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1617  %cmp = fcmp nnan olt <2 x double> %x, %y
1618  %res = sext <2 x i1> %cmp to <2 x i64>
1619  ret <2 x i64> %res
1620}
1621
1622; CHECK-LABEL: compare_ole_v2f64:
1623; NO-SIMD128-NOT: f64x2
1624; SIMD128-NEXT: .functype compare_ole_v2f64 (v128, v128) -> (v128){{$}}
1625; SIMD128-NEXT: f64x2.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1626; SIMD128-NEXT: return $pop[[R]]{{$}}
1627define <2 x i1> @compare_ole_v2f64 (<2 x double> %x, <2 x double> %y) {
1628  %res = fcmp ole <2 x double> %x, %y
1629  ret <2 x i1> %res
1630}
1631
1632; CHECK-LABEL: compare_ole_nnan_v2f64:
1633; NO-SIMD128-NOT: f64x2
1634; SIMD128-NEXT: .functype compare_ole_nnan_v2f64 (v128, v128) -> (v128){{$}}
1635; SIMD128-NEXT: f64x2.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1636; SIMD128-NEXT: return $pop[[R]]{{$}}
1637define <2 x i1> @compare_ole_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1638  %res = fcmp nnan ole <2 x double> %x, %y
1639  ret <2 x i1> %res
1640}
1641
1642; CHECK-LABEL: compare_sext_ole_v2f64:
1643; NO-SIMD128-NOT: f64x2
1644; SIMD128-NEXT: .functype compare_sext_ole_v2f64 (v128, v128) -> (v128){{$}}
1645; SIMD128-NEXT: f64x2.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1646; SIMD128-NEXT: return $pop[[R]]{{$}}
1647define <2 x i64> @compare_sext_ole_v2f64 (<2 x double> %x, <2 x double> %y) {
1648  %cmp = fcmp ole <2 x double> %x, %y
1649  %res = sext <2 x i1> %cmp to <2 x i64>
1650  ret <2 x i64> %res
1651}
1652
1653; CHECK-LABEL: compare_sext_ole_nnan_v2f64:
1654; NO-SIMD128-NOT: f64x2
1655; SIMD128-NEXT: .functype compare_sext_ole_nnan_v2f64 (v128, v128) -> (v128){{$}}
1656; SIMD128-NEXT: f64x2.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1657; SIMD128-NEXT: return $pop[[R]]{{$}}
1658define <2 x i64> @compare_sext_ole_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1659  %cmp = fcmp nnan ole <2 x double> %x, %y
1660  %res = sext <2 x i1> %cmp to <2 x i64>
1661  ret <2 x i64> %res
1662}
1663
1664; CHECK-LABEL: compare_one_v2f64:
1665; NO-SIMD128-NOT: f64x2
1666; SIMD128-NEXT: .functype compare_one_v2f64 (v128, v128) -> (v128){{$}}
1667; SIMD128-NEXT: f64x2.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1668; SIMD128-NEXT: f64x2.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1669; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1670; SIMD128-NEXT: return $pop[[R]]{{$}}
1671define <2 x i1> @compare_one_v2f64 (<2 x double> %x, <2 x double> %y) {
1672  %res = fcmp one <2 x double> %x, %y
1673  ret <2 x i1> %res
1674}
1675
1676; CHECK-LABEL: compare_one_nnan_v2f64:
1677; NO-SIMD128-NOT: f64x2
1678; SIMD128-NEXT: .functype compare_one_nnan_v2f64 (v128, v128) -> (v128){{$}}
1679; SIMD128-NEXT: f64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1680; SIMD128-NEXT: return $pop[[R]]{{$}}
1681define <2 x i1> @compare_one_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1682  %res = fcmp nnan one <2 x double> %x, %y
1683  ret <2 x i1> %res
1684}
1685
1686; CHECK-LABEL: compare_sext_one_v2f64:
1687; NO-SIMD128-NOT: f64x2
1688; SIMD128-NEXT: .functype compare_sext_one_v2f64 (v128, v128) -> (v128){{$}}
1689; SIMD128-NEXT: f64x2.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1690; SIMD128-NEXT: f64x2.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1691; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1692; SIMD128-NEXT: return $pop[[R]]{{$}}
1693define <2 x i64> @compare_sext_one_v2f64 (<2 x double> %x, <2 x double> %y) {
1694  %cmp = fcmp one <2 x double> %x, %y
1695  %res = sext <2 x i1> %cmp to <2 x i64>
1696  ret <2 x i64> %res
1697}
1698
1699; CHECK-LABEL: compare_sext_one_nnan_v2f64:
1700; NO-SIMD128-NOT: f64x2
1701; SIMD128-NEXT: .functype compare_sext_one_nnan_v2f64 (v128, v128) -> (v128){{$}}
1702; SIMD128-NEXT: f64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1703; SIMD128-NEXT: return $pop[[R]]{{$}}
1704define <2 x i64> @compare_sext_one_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1705  %cmp = fcmp nnan one <2 x double> %x, %y
1706  %res = sext <2 x i1> %cmp to <2 x i64>
1707  ret <2 x i64> %res
1708}
1709
1710; CHECK-LABEL: compare_ord_v2f64:
1711; NO-SIMD128-NOT: f64x2
1712; SIMD128-NEXT: .functype compare_ord_v2f64 (v128, v128) -> (v128){{$}}
1713; SIMD128-NEXT: f64x2.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1714; SIMD128-NEXT: f64x2.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1715; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1716; SIMD128-NEXT: return   $pop[[R]]{{$}}
1717define <2 x i1> @compare_ord_v2f64 (<2 x double> %x, <2 x double> %y) {
1718  %res = fcmp ord <2 x double> %x, %y
1719  ret <2 x i1> %res
1720}
1721
1722; CHECK-LABEL: compare_ord_nnan_v2f64:
1723; NO-SIMD128-NOT: f64x2
1724; SIMD128-NEXT: .functype compare_ord_nnan_v2f64 (v128, v128) -> (v128){{$}}
1725; SIMD128-NEXT: f64x2.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1726; SIMD128-NEXT: f64x2.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1727; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1728; SIMD128-NEXT: return   $pop[[R]]{{$}}
1729define <2 x i1> @compare_ord_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1730  %res = fcmp nnan ord <2 x double> %x, %y
1731  ret <2 x i1> %res
1732}
1733
1734; CHECK-LABEL: compare_sext_ord_v2f64:
1735; NO-SIMD128-NOT: f64x2
1736; SIMD128-NEXT: .functype compare_sext_ord_v2f64 (v128, v128) -> (v128){{$}}
1737; SIMD128-NEXT: f64x2.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1738; SIMD128-NEXT: f64x2.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1739; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1740; SIMD128-NEXT: return   $pop[[R]]{{$}}
1741define <2 x i64> @compare_sext_ord_v2f64 (<2 x double> %x, <2 x double> %y) {
1742  %cmp = fcmp ord <2 x double> %x, %y
1743  %res = sext <2 x i1> %cmp to <2 x i64>
1744  ret <2 x i64> %res
1745}
1746
1747; CHECK-LABEL: compare_sext_ord_nnan_v2f64:
1748; NO-SIMD128-NOT: f64x2
1749; SIMD128-NEXT: .functype compare_sext_ord_nnan_v2f64 (v128, v128) -> (v128){{$}}
1750; SIMD128-NEXT: f64x2.eq $push[[T0:[0-9]+]]=, $0, $0{{$}}
1751; SIMD128-NEXT: f64x2.eq $push[[T1:[0-9]+]]=, $1, $1{{$}}
1752; SIMD128-NEXT: v128.and $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1753; SIMD128-NEXT: return   $pop[[R]]{{$}}
1754define <2 x i64> @compare_sext_ord_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1755  %cmp = fcmp nnan ord <2 x double> %x, %y
1756  %res = sext <2 x i1> %cmp to <2 x i64>
1757  ret <2 x i64> %res
1758}
1759
1760; CHECK-LABEL: compare_ueq_v2f64:
1761; NO-SIMD128-NOT: f64x2
1762; SIMD128-NEXT: .functype compare_ueq_v2f64 (v128, v128) -> (v128){{$}}
1763; SIMD128-NEXT: f64x2.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1764; SIMD128-NEXT: f64x2.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1765; SIMD128-NEXT: v128.or $push[[T2:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1766; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T2]]{{$}}
1767; SIMD128-NEXT: return $pop[[R]]{{$}}
1768define <2 x i1> @compare_ueq_v2f64 (<2 x double> %x, <2 x double> %y) {
1769  %res = fcmp ueq <2 x double> %x, %y
1770  ret <2 x i1> %res
1771}
1772
1773; CHECK-LABEL: compare_ueq_nnan_v2f64:
1774; NO-SIMD128-NOT: f64x2
1775; SIMD128-NEXT: .functype compare_ueq_nnan_v2f64 (v128, v128) -> (v128){{$}}
1776; SIMD128-NEXT: f64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1777; SIMD128-NEXT: return $pop[[R]]{{$}}
1778define <2 x i1> @compare_ueq_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1779  %res = fcmp nnan ueq <2 x double> %x, %y
1780  ret <2 x i1> %res
1781}
1782
1783; CHECK-LABEL: compare_sext_ueq_v2f64:
1784; NO-SIMD128-NOT: f64x2
1785; SIMD128-NEXT: .functype compare_sext_ueq_v2f64 (v128, v128) -> (v128){{$}}
1786; SIMD128-NEXT: f64x2.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1787; SIMD128-NEXT: f64x2.lt $push[[T1:[0-9]+]]=, $0, $1{{$}}
1788; SIMD128-NEXT: v128.or $push[[T2:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
1789; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T2]]{{$}}
1790; SIMD128-NEXT: return $pop[[R]]{{$}}
1791define <2 x i64> @compare_sext_ueq_v2f64 (<2 x double> %x, <2 x double> %y) {
1792  %cmp = fcmp ueq <2 x double> %x, %y
1793  %res = sext <2 x i1> %cmp to <2 x i64>
1794  ret <2 x i64> %res
1795}
1796
1797; CHECK-LABEL: compare_sext_ueq_nnan_v2f64:
1798; NO-SIMD128-NOT: f64x2
1799; SIMD128-NEXT: .functype compare_sext_ueq_nnan_v2f64 (v128, v128) -> (v128){{$}}
1800; SIMD128-NEXT: f64x2.eq $push[[R:[0-9]+]]=, $0, $1{{$}}
1801; SIMD128-NEXT: return $pop[[R]]{{$}}
1802define <2 x i64> @compare_sext_ueq_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1803  %cmp = fcmp nnan ueq <2 x double> %x, %y
1804  %res = sext <2 x i1> %cmp to <2 x i64>
1805  ret <2 x i64> %res
1806}
1807
1808; CHECK-LABEL: compare_ugt_v2f64:
1809; NO-SIMD128-NOT: f64x2
1810; SIMD128-NEXT: .functype compare_ugt_v2f64 (v128, v128) -> (v128){{$}}
1811; SIMD128-NEXT: f64x2.le $push[[T0:[0-9]+]]=, $0, $1{{$}}
1812; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1813; SIMD128-NEXT: return $pop[[R]]{{$}}
1814define <2 x i1> @compare_ugt_v2f64 (<2 x double> %x, <2 x double> %y) {
1815  %res = fcmp ugt <2 x double> %x, %y
1816  ret <2 x i1> %res
1817}
1818
1819; CHECK-LABEL: compare_ugt_nnan_v2f64:
1820; NO-SIMD128-NOT: f64x2
1821; SIMD128-NEXT: .functype compare_ugt_nnan_v2f64 (v128, v128) -> (v128){{$}}
1822; SIMD128-NEXT: f64x2.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1823; SIMD128-NEXT: return $pop[[R]]{{$}}
1824define <2 x i1> @compare_ugt_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1825  %res = fcmp nnan ugt <2 x double> %x, %y
1826  ret <2 x i1> %res
1827}
1828
1829; CHECK-LABEL: compare_sext_ugt_v2f64:
1830; NO-SIMD128-NOT: f64x2
1831; SIMD128-NEXT: .functype compare_sext_ugt_v2f64 (v128, v128) -> (v128){{$}}
1832; SIMD128-NEXT: f64x2.le $push[[T0:[0-9]+]]=, $0, $1{{$}}
1833; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1834; SIMD128-NEXT: return $pop[[R]]{{$}}
1835define <2 x i64> @compare_sext_ugt_v2f64 (<2 x double> %x, <2 x double> %y) {
1836  %cmp = fcmp ugt <2 x double> %x, %y
1837  %res = sext <2 x i1> %cmp to <2 x i64>
1838  ret <2 x i64> %res
1839}
1840
1841; CHECK-LABEL: compare_sext_ugt_nnan_v2f64:
1842; NO-SIMD128-NOT: f64x2
1843; SIMD128-NEXT: .functype compare_sext_ugt_nnan_v2f64 (v128, v128) -> (v128){{$}}
1844; SIMD128-NEXT: f64x2.gt $push[[R:[0-9]+]]=, $0, $1{{$}}
1845; SIMD128-NEXT: return $pop[[R]]{{$}}
1846define <2 x i64> @compare_sext_ugt_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1847  %cmp = fcmp nnan ugt <2 x double> %x, %y
1848  %res = sext <2 x i1> %cmp to <2 x i64>
1849  ret <2 x i64> %res
1850}
1851
1852; CHECK-LABEL: compare_uge_v2f64:
1853; NO-SIMD128-NOT: f64x2
1854; SIMD128-NEXT: .functype compare_uge_v2f64 (v128, v128) -> (v128){{$}}
1855; SIMD128-NEXT: f64x2.lt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1856; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1857; SIMD128-NEXT: return $pop[[R]]{{$}}
1858define <2 x i1> @compare_uge_v2f64 (<2 x double> %x, <2 x double> %y) {
1859  %res = fcmp uge <2 x double> %x, %y
1860  ret <2 x i1> %res
1861}
1862
1863; CHECK-LABEL: compare_uge_nnan_v2f64:
1864; NO-SIMD128-NOT: f64x2
1865; SIMD128-NEXT: .functype compare_uge_nnan_v2f64 (v128, v128) -> (v128){{$}}
1866; SIMD128-NEXT: f64x2.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1867; SIMD128-NEXT: return $pop[[R]]{{$}}
1868define <2 x i1> @compare_uge_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1869  %res = fcmp nnan uge <2 x double> %x, %y
1870  ret <2 x i1> %res
1871}
1872
1873; CHECK-LABEL: compare_sext_uge_v2f64:
1874; NO-SIMD128-NOT: f64x2
1875; SIMD128-NEXT: .functype compare_sext_uge_v2f64 (v128, v128) -> (v128){{$}}
1876; SIMD128-NEXT: f64x2.lt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1877; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1878; SIMD128-NEXT: return $pop[[R]]{{$}}
1879define <2 x i64> @compare_sext_uge_v2f64 (<2 x double> %x, <2 x double> %y) {
1880  %cmp = fcmp uge <2 x double> %x, %y
1881  %res = sext <2 x i1> %cmp to <2 x i64>
1882  ret <2 x i64> %res
1883}
1884
1885; CHECK-LABEL: compare_sext_uge_nnan_v2f64:
1886; NO-SIMD128-NOT: f64x2
1887; SIMD128-NEXT: .functype compare_sext_uge_nnan_v2f64 (v128, v128) -> (v128){{$}}
1888; SIMD128-NEXT: f64x2.ge $push[[R:[0-9]+]]=, $0, $1{{$}}
1889; SIMD128-NEXT: return $pop[[R]]{{$}}
1890define <2 x i64> @compare_sext_uge_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1891  %cmp = fcmp nnan uge <2 x double> %x, %y
1892  %res = sext <2 x i1> %cmp to <2 x i64>
1893  ret <2 x i64> %res
1894}
1895
1896; CHECK-LABEL: compare_ult_v2f64:
1897; NO-SIMD128-NOT: f64x2
1898; SIMD128-NEXT: .functype compare_ult_v2f64 (v128, v128) -> (v128){{$}}
1899; SIMD128-NEXT: f64x2.ge $push[[T0:[0-9]+]]=, $0, $1{{$}}
1900; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1901; SIMD128-NEXT: return $pop[[R]]{{$}}
1902define <2 x i1> @compare_ult_v2f64 (<2 x double> %x, <2 x double> %y) {
1903  %res = fcmp ult <2 x double> %x, %y
1904  ret <2 x i1> %res
1905}
1906
1907; CHECK-LABEL: compare_ult_nnan_v2f64:
1908; NO-SIMD128-NOT: f64x2
1909; SIMD128-NEXT: .functype compare_ult_nnan_v2f64 (v128, v128) -> (v128){{$}}
1910; SIMD128-NEXT: f64x2.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1911; SIMD128-NEXT: return $pop[[R]]{{$}}
1912define <2 x i1> @compare_ult_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1913  %res = fcmp nnan ult <2 x double> %x, %y
1914  ret <2 x i1> %res
1915}
1916
1917; CHECK-LABEL: compare_sext_ult_v2f64:
1918; NO-SIMD128-NOT: f64x2
1919; SIMD128-NEXT: .functype compare_sext_ult_v2f64 (v128, v128) -> (v128){{$}}
1920; SIMD128-NEXT: f64x2.ge $push[[T0:[0-9]+]]=, $0, $1{{$}}
1921; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1922; SIMD128-NEXT: return $pop[[R]]{{$}}
1923define <2 x i64> @compare_sext_ult_v2f64 (<2 x double> %x, <2 x double> %y) {
1924  %cmp = fcmp ult <2 x double> %x, %y
1925  %res = sext <2 x i1> %cmp to <2 x i64>
1926  ret <2 x i64> %res
1927}
1928
1929; CHECK-LABEL: compare_sext_ult_nnan_v2f64:
1930; NO-SIMD128-NOT: f64x2
1931; SIMD128-NEXT: .functype compare_sext_ult_nnan_v2f64 (v128, v128) -> (v128){{$}}
1932; SIMD128-NEXT: f64x2.lt $push[[R:[0-9]+]]=, $0, $1{{$}}
1933; SIMD128-NEXT: return $pop[[R]]{{$}}
1934define <2 x i64> @compare_sext_ult_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1935  %cmp = fcmp nnan ult <2 x double> %x, %y
1936  %res = sext <2 x i1> %cmp to <2 x i64>
1937  ret <2 x i64> %res
1938}
1939
1940; CHECK-LABEL: compare_ule_v2f64:
1941; NO-SIMD128-NOT: f64x2
1942; SIMD128-NEXT: .functype compare_ule_v2f64 (v128, v128) -> (v128){{$}}
1943; SIMD128-NEXT: f64x2.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1944; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1945; SIMD128-NEXT: return $pop[[R]]{{$}}
1946define <2 x i1> @compare_ule_v2f64 (<2 x double> %x, <2 x double> %y) {
1947  %res = fcmp ule <2 x double> %x, %y
1948  ret <2 x i1> %res
1949}
1950
1951; CHECK-LABEL: compare_ule_nnan_v2f64:
1952; NO-SIMD128-NOT: f64x2
1953; SIMD128-NEXT: .functype compare_ule_nnan_v2f64 (v128, v128) -> (v128){{$}}
1954; SIMD128-NEXT: f64x2.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1955; SIMD128-NEXT: return $pop[[R]]{{$}}
1956define <2 x i1> @compare_ule_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1957  %res = fcmp nnan ule <2 x double> %x, %y
1958  ret <2 x i1> %res
1959}
1960
1961; CHECK-LABEL: compare_sext_ule_v2f64:
1962; NO-SIMD128-NOT: f64x2
1963; SIMD128-NEXT: .functype compare_sext_ule_v2f64 (v128, v128) -> (v128){{$}}
1964; SIMD128-NEXT: f64x2.gt $push[[T0:[0-9]+]]=, $0, $1{{$}}
1965; SIMD128-NEXT: v128.not $push[[R:[0-9]+]]=, $pop[[T0]]{{$}}
1966; SIMD128-NEXT: return $pop[[R]]{{$}}
1967define <2 x i64> @compare_sext_ule_v2f64 (<2 x double> %x, <2 x double> %y) {
1968  %cmp = fcmp ule <2 x double> %x, %y
1969  %res = sext <2 x i1> %cmp to <2 x i64>
1970  ret <2 x i64> %res
1971}
1972
1973; CHECK-LABEL: compare_sext_ule_nnan_v2f64:
1974; NO-SIMD128-NOT: f64x2
1975; SIMD128-NEXT: .functype compare_sext_ule_nnan_v2f64 (v128, v128) -> (v128){{$}}
1976; SIMD128-NEXT: f64x2.le $push[[R:[0-9]+]]=, $0, $1{{$}}
1977; SIMD128-NEXT: return $pop[[R]]{{$}}
1978define <2 x i64> @compare_sext_ule_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
1979  %cmp = fcmp nnan ule <2 x double> %x, %y
1980  %res = sext <2 x i1> %cmp to <2 x i64>
1981  ret <2 x i64> %res
1982}
1983
1984; CHECK-LABEL: compare_une_v2f64:
1985; NO-SIMD128-NOT: f64x2
1986; SIMD128-NEXT: .functype compare_une_v2f64 (v128, v128) -> (v128){{$}}
1987; SIMD128-NEXT: f64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1988; SIMD128-NEXT: return $pop[[R]]{{$}}
1989define <2 x i1> @compare_une_v2f64 (<2 x double> %x, <2 x double> %y) {
1990  %res = fcmp une <2 x double> %x, %y
1991  ret <2 x i1> %res
1992}
1993
1994; CHECK-LABEL: compare_une_nnan_v2f64:
1995; NO-SIMD128-NOT: f64x2
1996; SIMD128-NEXT: .functype compare_une_nnan_v2f64 (v128, v128) -> (v128){{$}}
1997; SIMD128-NEXT: f64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
1998; SIMD128-NEXT: return $pop[[R]]{{$}}
1999define <2 x i1> @compare_une_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
2000  %res = fcmp nnan une <2 x double> %x, %y
2001  ret <2 x i1> %res
2002}
2003
2004; CHECK-LABEL: compare_sext_une_v2f64:
2005; NO-SIMD128-NOT: f64x2
2006; SIMD128-NEXT: .functype compare_sext_une_v2f64 (v128, v128) -> (v128){{$}}
2007; SIMD128-NEXT: f64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
2008; SIMD128-NEXT: return $pop[[R]]{{$}}
2009define <2 x i64> @compare_sext_une_v2f64 (<2 x double> %x, <2 x double> %y) {
2010  %cmp = fcmp une <2 x double> %x, %y
2011  %res = sext <2 x i1> %cmp to <2 x i64>
2012  ret <2 x i64> %res
2013}
2014
2015; CHECK-LABEL: compare_sext_une_nnan_v2f64:
2016; NO-SIMD128-NOT: f64x2
2017; SIMD128-NEXT: .functype compare_sext_une_nnan_v2f64 (v128, v128) -> (v128){{$}}
2018; SIMD128-NEXT: f64x2.ne $push[[R:[0-9]+]]=, $0, $1{{$}}
2019; SIMD128-NEXT: return $pop[[R]]{{$}}
2020define <2 x i64> @compare_sext_une_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
2021  %cmp = fcmp nnan une <2 x double> %x, %y
2022  %res = sext <2 x i1> %cmp to <2 x i64>
2023  ret <2 x i64> %res
2024}
2025
2026; CHECK-LABEL: compare_uno_v2f64:
2027; NO-SIMD128-NOT: f64x2
2028; SIMD128-NEXT: .functype compare_uno_v2f64 (v128, v128) -> (v128){{$}}
2029; SIMD128-NEXT: f64x2.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
2030; SIMD128-NEXT: f64x2.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
2031; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
2032; SIMD128-NEXT: return $pop[[R]]{{$}}
2033define <2 x i1> @compare_uno_v2f64 (<2 x double> %x, <2 x double> %y) {
2034  %res = fcmp uno <2 x double> %x, %y
2035  ret <2 x i1> %res
2036}
2037
2038; CHECK-LABEL: compare_uno_nnan_v2f64:
2039; NO-SIMD128-NOT: f64x2
2040; SIMD128-NEXT: .functype compare_uno_nnan_v2f64 (v128, v128) -> (v128){{$}}
2041; SIMD128-NEXT: f64x2.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
2042; SIMD128-NEXT: f64x2.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
2043; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
2044; SIMD128-NEXT: return $pop[[R]]{{$}}
2045define <2 x i1> @compare_uno_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
2046  %res = fcmp nnan uno <2 x double> %x, %y
2047  ret <2 x i1> %res
2048}
2049
2050; CHECK-LABEL: compare_sext_uno_v2f64:
2051; NO-SIMD128-NOT: f64x2
2052; SIMD128-NEXT: .functype compare_sext_uno_v2f64 (v128, v128) -> (v128){{$}}
2053; SIMD128-NEXT: f64x2.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
2054; SIMD128-NEXT: f64x2.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
2055; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
2056; SIMD128-NEXT: return $pop[[R]]{{$}}
2057define <2 x i64> @compare_sext_uno_v2f64 (<2 x double> %x, <2 x double> %y) {
2058  %cmp = fcmp uno <2 x double> %x, %y
2059  %res = sext <2 x i1> %cmp to <2 x i64>
2060  ret <2 x i64> %res
2061}
2062
2063; CHECK-LABEL: compare_sext_uno_nnan_v2f64:
2064; NO-SIMD128-NOT: f64x2
2065; SIMD128-NEXT: .functype compare_sext_uno_nnan_v2f64 (v128, v128) -> (v128){{$}}
2066; SIMD128-NEXT: f64x2.ne $push[[T0:[0-9]+]]=, $0, $0{{$}}
2067; SIMD128-NEXT: f64x2.ne $push[[T1:[0-9]+]]=, $1, $1{{$}}
2068; SIMD128-NEXT: v128.or $push[[R:[0-9]+]]=, $pop[[T0]], $pop[[T1]]{{$}}
2069; SIMD128-NEXT: return $pop[[R]]{{$}}
2070define <2 x i64> @compare_sext_uno_nnan_v2f64 (<2 x double> %x, <2 x double> %y) {
2071  %cmp = fcmp nnan uno <2 x double> %x, %y
2072  %res = sext <2 x i1> %cmp to <2 x i64>
2073  ret <2 x i64> %res
2074}
2075