1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=i686-- -no-integrated-as | FileCheck %s -check-prefix=X32
3 ; RUN: llc < %s -mtriple=x86_64-- -no-integrated-as | FileCheck %s -check-prefix=X64
5 define i32 @test_cca(i64 %nr, ptr %addr) nounwind {
7 ; X32: # %bb.0: # %entry
9 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
10 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
11 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
12 ; X32-NEXT: xorl %eax, %eax
14 ; X32-NEXT: cmp %ecx,(%esi)
20 ; X64-LABEL: test_cca:
21 ; X64: # %bb.0: # %entry
22 ; X64-NEXT: xorl %eax, %eax
24 ; X64-NEXT: cmp %rdi,(%rsi)
29 %cc = tail call i32 asm "cmp $2,$1", "={@cca},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
30 %tobool = icmp ne i32 %cc, 0
31 %rv = zext i1 %tobool to i32
36 define i32 @test_ccae(i64 %nr, ptr %addr) nounwind {
37 ; X32-LABEL: test_ccae:
38 ; X32: # %bb.0: # %entry
39 ; X32-NEXT: pushl %esi
40 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
41 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
42 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
43 ; X32-NEXT: xorl %eax, %eax
45 ; X32-NEXT: cmp %ecx,(%esi)
51 ; X64-LABEL: test_ccae:
52 ; X64: # %bb.0: # %entry
53 ; X64-NEXT: xorl %eax, %eax
55 ; X64-NEXT: cmp %rdi,(%rsi)
60 %cc = tail call i32 asm "cmp $2,$1", "={@ccae},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
61 %tobool = icmp ne i32 %cc, 0
62 %rv = zext i1 %tobool to i32
67 define i32 @test_ccb(i64 %nr, ptr %addr) nounwind {
68 ; X32-LABEL: test_ccb:
69 ; X32: # %bb.0: # %entry
70 ; X32-NEXT: pushl %esi
71 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
72 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
73 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
74 ; X32-NEXT: xorl %eax, %eax
76 ; X32-NEXT: cmp %ecx,(%esi)
82 ; X64-LABEL: test_ccb:
83 ; X64: # %bb.0: # %entry
84 ; X64-NEXT: xorl %eax, %eax
86 ; X64-NEXT: cmp %rdi,(%rsi)
91 %cc = tail call i32 asm "cmp $2,$1", "={@ccb},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
92 %tobool = icmp ne i32 %cc, 0
93 %rv = zext i1 %tobool to i32
98 define i32 @test_ccbe(i64 %nr, ptr %addr) nounwind {
99 ; X32-LABEL: test_ccbe:
100 ; X32: # %bb.0: # %entry
101 ; X32-NEXT: pushl %esi
102 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
103 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
104 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
105 ; X32-NEXT: xorl %eax, %eax
107 ; X32-NEXT: cmp %ecx,(%esi)
109 ; X32-NEXT: setbe %al
110 ; X32-NEXT: popl %esi
113 ; X64-LABEL: test_ccbe:
114 ; X64: # %bb.0: # %entry
115 ; X64-NEXT: xorl %eax, %eax
117 ; X64-NEXT: cmp %rdi,(%rsi)
119 ; X64-NEXT: setbe %al
122 %cc = tail call i32 asm "cmp $2,$1", "={@ccbe},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
123 %tobool = icmp ne i32 %cc, 0
124 %rv = zext i1 %tobool to i32
129 define i32 @test_ccc(i64 %nr, ptr %addr) nounwind {
130 ; X32-LABEL: test_ccc:
131 ; X32: # %bb.0: # %entry
132 ; X32-NEXT: pushl %esi
133 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
134 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
135 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
136 ; X32-NEXT: xorl %eax, %eax
138 ; X32-NEXT: cmp %ecx,(%esi)
141 ; X32-NEXT: popl %esi
144 ; X64-LABEL: test_ccc:
145 ; X64: # %bb.0: # %entry
146 ; X64-NEXT: xorl %eax, %eax
148 ; X64-NEXT: cmp %rdi,(%rsi)
153 %cc = tail call i32 asm "cmp $2,$1", "={@ccc},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
154 %tobool = icmp ne i32 %cc, 0
155 %rv = zext i1 %tobool to i32
160 define i32 @test_cce(i64 %nr, ptr %addr) nounwind {
161 ; X32-LABEL: test_cce:
162 ; X32: # %bb.0: # %entry
163 ; X32-NEXT: pushl %esi
164 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
165 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
166 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
167 ; X32-NEXT: xorl %eax, %eax
169 ; X32-NEXT: cmp %ecx,(%esi)
172 ; X32-NEXT: popl %esi
175 ; X64-LABEL: test_cce:
176 ; X64: # %bb.0: # %entry
177 ; X64-NEXT: xorl %eax, %eax
179 ; X64-NEXT: cmp %rdi,(%rsi)
184 %cc = tail call i32 asm "cmp $2,$1", "={@cce},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
185 %tobool = icmp ne i32 %cc, 0
186 %rv = zext i1 %tobool to i32
191 define i32 @test_ccz(i64 %nr, ptr %addr) nounwind {
192 ; X32-LABEL: test_ccz:
193 ; X32: # %bb.0: # %entry
194 ; X32-NEXT: pushl %esi
195 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
196 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
197 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
198 ; X32-NEXT: xorl %eax, %eax
200 ; X32-NEXT: cmp %ecx,(%esi)
203 ; X32-NEXT: popl %esi
206 ; X64-LABEL: test_ccz:
207 ; X64: # %bb.0: # %entry
208 ; X64-NEXT: xorl %eax, %eax
210 ; X64-NEXT: cmp %rdi,(%rsi)
215 %cc = tail call i32 asm "cmp $2,$1", "={@ccz},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
216 %tobool = icmp ne i32 %cc, 0
217 %rv = zext i1 %tobool to i32
222 define i32 @test_ccg(i64 %nr, ptr %addr) nounwind {
223 ; X32-LABEL: test_ccg:
224 ; X32: # %bb.0: # %entry
225 ; X32-NEXT: pushl %esi
226 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
227 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
228 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
229 ; X32-NEXT: xorl %eax, %eax
231 ; X32-NEXT: cmp %ecx,(%esi)
234 ; X32-NEXT: popl %esi
237 ; X64-LABEL: test_ccg:
238 ; X64: # %bb.0: # %entry
239 ; X64-NEXT: xorl %eax, %eax
241 ; X64-NEXT: cmp %rdi,(%rsi)
246 %cc = tail call i32 asm "cmp $2,$1", "={@ccg},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
247 %tobool = icmp ne i32 %cc, 0
248 %rv = zext i1 %tobool to i32
253 define i32 @test_ccge(i64 %nr, ptr %addr) nounwind {
254 ; X32-LABEL: test_ccge:
255 ; X32: # %bb.0: # %entry
256 ; X32-NEXT: pushl %esi
257 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
258 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
259 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
260 ; X32-NEXT: xorl %eax, %eax
262 ; X32-NEXT: cmp %ecx,(%esi)
264 ; X32-NEXT: setge %al
265 ; X32-NEXT: popl %esi
268 ; X64-LABEL: test_ccge:
269 ; X64: # %bb.0: # %entry
270 ; X64-NEXT: xorl %eax, %eax
272 ; X64-NEXT: cmp %rdi,(%rsi)
274 ; X64-NEXT: setge %al
277 %cc = tail call i32 asm "cmp $2,$1", "={@ccge},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
278 %tobool = icmp ne i32 %cc, 0
279 %rv = zext i1 %tobool to i32
284 define i32 @test_ccl(i64 %nr, ptr %addr) nounwind {
285 ; X32-LABEL: test_ccl:
286 ; X32: # %bb.0: # %entry
287 ; X32-NEXT: pushl %esi
288 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
289 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
290 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
291 ; X32-NEXT: xorl %eax, %eax
293 ; X32-NEXT: cmp %ecx,(%esi)
296 ; X32-NEXT: popl %esi
299 ; X64-LABEL: test_ccl:
300 ; X64: # %bb.0: # %entry
301 ; X64-NEXT: xorl %eax, %eax
303 ; X64-NEXT: cmp %rdi,(%rsi)
308 %cc = tail call i32 asm "cmp $2,$1", "={@ccl},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
309 %tobool = icmp ne i32 %cc, 0
310 %rv = zext i1 %tobool to i32
315 define i32 @test_ccle(i64 %nr, ptr %addr) nounwind {
316 ; X32-LABEL: test_ccle:
317 ; X32: # %bb.0: # %entry
318 ; X32-NEXT: pushl %esi
319 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
320 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
321 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
322 ; X32-NEXT: xorl %eax, %eax
324 ; X32-NEXT: cmp %ecx,(%esi)
326 ; X32-NEXT: setle %al
327 ; X32-NEXT: popl %esi
330 ; X64-LABEL: test_ccle:
331 ; X64: # %bb.0: # %entry
332 ; X64-NEXT: xorl %eax, %eax
334 ; X64-NEXT: cmp %rdi,(%rsi)
336 ; X64-NEXT: setle %al
339 %cc = tail call i32 asm "cmp $2,$1", "={@ccle},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
340 %tobool = icmp ne i32 %cc, 0
341 %rv = zext i1 %tobool to i32
346 define i32 @test_ccna(i64 %nr, ptr %addr) nounwind {
347 ; X32-LABEL: test_ccna:
348 ; X32: # %bb.0: # %entry
349 ; X32-NEXT: pushl %esi
350 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
351 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
352 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
353 ; X32-NEXT: xorl %eax, %eax
355 ; X32-NEXT: cmp %ecx,(%esi)
357 ; X32-NEXT: setbe %al
358 ; X32-NEXT: popl %esi
361 ; X64-LABEL: test_ccna:
362 ; X64: # %bb.0: # %entry
363 ; X64-NEXT: xorl %eax, %eax
365 ; X64-NEXT: cmp %rdi,(%rsi)
367 ; X64-NEXT: setbe %al
370 %cc = tail call i32 asm "cmp $2,$1", "={@ccna},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
371 %tobool = icmp ne i32 %cc, 0
372 %rv = zext i1 %tobool to i32
377 define i32 @test_ccnae(i64 %nr, ptr %addr) nounwind {
378 ; X32-LABEL: test_ccnae:
379 ; X32: # %bb.0: # %entry
380 ; X32-NEXT: pushl %esi
381 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
382 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
383 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
384 ; X32-NEXT: xorl %eax, %eax
386 ; X32-NEXT: cmp %ecx,(%esi)
389 ; X32-NEXT: popl %esi
392 ; X64-LABEL: test_ccnae:
393 ; X64: # %bb.0: # %entry
394 ; X64-NEXT: xorl %eax, %eax
396 ; X64-NEXT: cmp %rdi,(%rsi)
401 %cc = tail call i32 asm "cmp $2,$1", "={@ccnae},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
402 %tobool = icmp ne i32 %cc, 0
403 %rv = zext i1 %tobool to i32
408 define i32 @test_ccnb(i64 %nr, ptr %addr) nounwind {
409 ; X32-LABEL: test_ccnb:
410 ; X32: # %bb.0: # %entry
411 ; X32-NEXT: pushl %esi
412 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
413 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
414 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
415 ; X32-NEXT: xorl %eax, %eax
417 ; X32-NEXT: cmp %ecx,(%esi)
419 ; X32-NEXT: setae %al
420 ; X32-NEXT: popl %esi
423 ; X64-LABEL: test_ccnb:
424 ; X64: # %bb.0: # %entry
425 ; X64-NEXT: xorl %eax, %eax
427 ; X64-NEXT: cmp %rdi,(%rsi)
429 ; X64-NEXT: setae %al
432 %cc = tail call i32 asm "cmp $2,$1", "={@ccnb},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
433 %tobool = icmp ne i32 %cc, 0
434 %rv = zext i1 %tobool to i32
439 define i32 @test_ccnbe(i64 %nr, ptr %addr) nounwind {
440 ; X32-LABEL: test_ccnbe:
441 ; X32: # %bb.0: # %entry
442 ; X32-NEXT: pushl %esi
443 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
444 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
445 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
446 ; X32-NEXT: xorl %eax, %eax
448 ; X32-NEXT: cmp %ecx,(%esi)
451 ; X32-NEXT: popl %esi
454 ; X64-LABEL: test_ccnbe:
455 ; X64: # %bb.0: # %entry
456 ; X64-NEXT: xorl %eax, %eax
458 ; X64-NEXT: cmp %rdi,(%rsi)
463 %cc = tail call i32 asm "cmp $2,$1", "={@ccnbe},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
464 %tobool = icmp ne i32 %cc, 0
465 %rv = zext i1 %tobool to i32
470 define i32 @test_ccnc(i64 %nr, ptr %addr) nounwind {
471 ; X32-LABEL: test_ccnc:
472 ; X32: # %bb.0: # %entry
473 ; X32-NEXT: pushl %esi
474 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
475 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
476 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
477 ; X32-NEXT: xorl %eax, %eax
479 ; X32-NEXT: cmp %ecx,(%esi)
481 ; X32-NEXT: setae %al
482 ; X32-NEXT: popl %esi
485 ; X64-LABEL: test_ccnc:
486 ; X64: # %bb.0: # %entry
487 ; X64-NEXT: xorl %eax, %eax
489 ; X64-NEXT: cmp %rdi,(%rsi)
491 ; X64-NEXT: setae %al
494 %cc = tail call i32 asm "cmp $2,$1", "={@ccnc},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
495 %tobool = icmp ne i32 %cc, 0
496 %rv = zext i1 %tobool to i32
501 define i32 @test_ccne(i64 %nr, ptr %addr) nounwind {
502 ; X32-LABEL: test_ccne:
503 ; X32: # %bb.0: # %entry
504 ; X32-NEXT: pushl %esi
505 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
506 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
507 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
508 ; X32-NEXT: xorl %eax, %eax
510 ; X32-NEXT: cmp %ecx,(%esi)
512 ; X32-NEXT: setne %al
513 ; X32-NEXT: popl %esi
516 ; X64-LABEL: test_ccne:
517 ; X64: # %bb.0: # %entry
518 ; X64-NEXT: xorl %eax, %eax
520 ; X64-NEXT: cmp %rdi,(%rsi)
522 ; X64-NEXT: setne %al
525 %cc = tail call i32 asm "cmp $2,$1", "={@ccne},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
526 %tobool = icmp ne i32 %cc, 0
527 %rv = zext i1 %tobool to i32
532 define i32 @test_ccnz(i64 %nr, ptr %addr) nounwind {
533 ; X32-LABEL: test_ccnz:
534 ; X32: # %bb.0: # %entry
535 ; X32-NEXT: pushl %esi
536 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
537 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
538 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
539 ; X32-NEXT: xorl %eax, %eax
541 ; X32-NEXT: cmp %ecx,(%esi)
543 ; X32-NEXT: setne %al
544 ; X32-NEXT: popl %esi
547 ; X64-LABEL: test_ccnz:
548 ; X64: # %bb.0: # %entry
549 ; X64-NEXT: xorl %eax, %eax
551 ; X64-NEXT: cmp %rdi,(%rsi)
553 ; X64-NEXT: setne %al
556 %cc = tail call i32 asm "cmp $2,$1", "={@ccnz},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
557 %tobool = icmp ne i32 %cc, 0
558 %rv = zext i1 %tobool to i32
563 define i32 @test_ccng(i64 %nr, ptr %addr) nounwind {
564 ; X32-LABEL: test_ccng:
565 ; X32: # %bb.0: # %entry
566 ; X32-NEXT: pushl %esi
567 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
568 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
569 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
570 ; X32-NEXT: xorl %eax, %eax
572 ; X32-NEXT: cmp %ecx,(%esi)
574 ; X32-NEXT: setle %al
575 ; X32-NEXT: popl %esi
578 ; X64-LABEL: test_ccng:
579 ; X64: # %bb.0: # %entry
580 ; X64-NEXT: xorl %eax, %eax
582 ; X64-NEXT: cmp %rdi,(%rsi)
584 ; X64-NEXT: setle %al
587 %cc = tail call i32 asm "cmp $2,$1", "={@ccng},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
588 %tobool = icmp ne i32 %cc, 0
589 %rv = zext i1 %tobool to i32
594 define i32 @test_ccnge(i64 %nr, ptr %addr) nounwind {
595 ; X32-LABEL: test_ccnge:
596 ; X32: # %bb.0: # %entry
597 ; X32-NEXT: pushl %esi
598 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
599 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
600 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
601 ; X32-NEXT: xorl %eax, %eax
603 ; X32-NEXT: cmp %ecx,(%esi)
606 ; X32-NEXT: popl %esi
609 ; X64-LABEL: test_ccnge:
610 ; X64: # %bb.0: # %entry
611 ; X64-NEXT: xorl %eax, %eax
613 ; X64-NEXT: cmp %rdi,(%rsi)
618 %cc = tail call i32 asm "cmp $2,$1", "={@ccnge},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
619 %tobool = icmp ne i32 %cc, 0
620 %rv = zext i1 %tobool to i32
625 define i32 @test_ccnl(i64 %nr, ptr %addr) nounwind {
626 ; X32-LABEL: test_ccnl:
627 ; X32: # %bb.0: # %entry
628 ; X32-NEXT: pushl %esi
629 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
630 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
631 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
632 ; X32-NEXT: xorl %eax, %eax
634 ; X32-NEXT: cmp %ecx,(%esi)
636 ; X32-NEXT: setge %al
637 ; X32-NEXT: popl %esi
640 ; X64-LABEL: test_ccnl:
641 ; X64: # %bb.0: # %entry
642 ; X64-NEXT: xorl %eax, %eax
644 ; X64-NEXT: cmp %rdi,(%rsi)
646 ; X64-NEXT: setge %al
649 %cc = tail call i32 asm "cmp $2,$1", "={@ccnl},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
650 %tobool = icmp ne i32 %cc, 0
651 %rv = zext i1 %tobool to i32
656 define i32 @test_ccnle(i64 %nr, ptr %addr) nounwind {
657 ; X32-LABEL: test_ccnle:
658 ; X32: # %bb.0: # %entry
659 ; X32-NEXT: pushl %esi
660 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
661 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
662 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
663 ; X32-NEXT: xorl %eax, %eax
665 ; X32-NEXT: cmp %ecx,(%esi)
668 ; X32-NEXT: popl %esi
671 ; X64-LABEL: test_ccnle:
672 ; X64: # %bb.0: # %entry
673 ; X64-NEXT: xorl %eax, %eax
675 ; X64-NEXT: cmp %rdi,(%rsi)
680 %cc = tail call i32 asm "cmp $2,$1", "={@ccnle},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
681 %tobool = icmp ne i32 %cc, 0
682 %rv = zext i1 %tobool to i32
687 define i32 @test_ccno(i64 %nr, ptr %addr) nounwind {
688 ; X32-LABEL: test_ccno:
689 ; X32: # %bb.0: # %entry
690 ; X32-NEXT: pushl %esi
691 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
692 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
693 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
694 ; X32-NEXT: xorl %eax, %eax
696 ; X32-NEXT: cmp %ecx,(%esi)
698 ; X32-NEXT: setno %al
699 ; X32-NEXT: popl %esi
702 ; X64-LABEL: test_ccno:
703 ; X64: # %bb.0: # %entry
704 ; X64-NEXT: xorl %eax, %eax
706 ; X64-NEXT: cmp %rdi,(%rsi)
708 ; X64-NEXT: setno %al
711 %cc = tail call i32 asm "cmp $2,$1", "={@ccno},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
712 %tobool = icmp ne i32 %cc, 0
713 %rv = zext i1 %tobool to i32
718 define i32 @test_ccnp(i64 %nr, ptr %addr) nounwind {
719 ; X32-LABEL: test_ccnp:
720 ; X32: # %bb.0: # %entry
721 ; X32-NEXT: pushl %esi
722 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
723 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
724 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
725 ; X32-NEXT: xorl %eax, %eax
727 ; X32-NEXT: cmp %ecx,(%esi)
729 ; X32-NEXT: setnp %al
730 ; X32-NEXT: popl %esi
733 ; X64-LABEL: test_ccnp:
734 ; X64: # %bb.0: # %entry
735 ; X64-NEXT: xorl %eax, %eax
737 ; X64-NEXT: cmp %rdi,(%rsi)
739 ; X64-NEXT: setnp %al
742 %cc = tail call i32 asm "cmp $2,$1", "={@ccnp},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
743 %tobool = icmp ne i32 %cc, 0
744 %rv = zext i1 %tobool to i32
749 define i32 @test_ccns(i64 %nr, ptr %addr) nounwind {
750 ; X32-LABEL: test_ccns:
751 ; X32: # %bb.0: # %entry
752 ; X32-NEXT: pushl %esi
753 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
754 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
755 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
756 ; X32-NEXT: xorl %eax, %eax
758 ; X32-NEXT: cmp %ecx,(%esi)
760 ; X32-NEXT: setns %al
761 ; X32-NEXT: popl %esi
764 ; X64-LABEL: test_ccns:
765 ; X64: # %bb.0: # %entry
766 ; X64-NEXT: xorl %eax, %eax
768 ; X64-NEXT: cmp %rdi,(%rsi)
770 ; X64-NEXT: setns %al
773 %cc = tail call i32 asm "cmp $2,$1", "={@ccns},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
774 %tobool = icmp ne i32 %cc, 0
775 %rv = zext i1 %tobool to i32
780 define i32 @test_cco(i64 %nr, ptr %addr) nounwind {
781 ; X32-LABEL: test_cco:
782 ; X32: # %bb.0: # %entry
783 ; X32-NEXT: pushl %esi
784 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
785 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
786 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
787 ; X32-NEXT: xorl %eax, %eax
789 ; X32-NEXT: cmp %ecx,(%esi)
792 ; X32-NEXT: popl %esi
795 ; X64-LABEL: test_cco:
796 ; X64: # %bb.0: # %entry
797 ; X64-NEXT: xorl %eax, %eax
799 ; X64-NEXT: cmp %rdi,(%rsi)
804 %cc = tail call i32 asm "cmp $2,$1", "={@cco},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
805 %tobool = icmp ne i32 %cc, 0
806 %rv = zext i1 %tobool to i32
811 define i32 @test_ccp(i64 %nr, ptr %addr) nounwind {
812 ; X32-LABEL: test_ccp:
813 ; X32: # %bb.0: # %entry
814 ; X32-NEXT: pushl %esi
815 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
816 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
817 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
818 ; X32-NEXT: xorl %eax, %eax
820 ; X32-NEXT: cmp %ecx,(%esi)
823 ; X32-NEXT: popl %esi
826 ; X64-LABEL: test_ccp:
827 ; X64: # %bb.0: # %entry
828 ; X64-NEXT: xorl %eax, %eax
830 ; X64-NEXT: cmp %rdi,(%rsi)
835 %cc = tail call i32 asm "cmp $2,$1", "={@ccp},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
836 %tobool = icmp ne i32 %cc, 0
837 %rv = zext i1 %tobool to i32
842 define i32 @test_ccs(i64 %nr, ptr %addr) nounwind {
843 ; X32-LABEL: test_ccs:
844 ; X32: # %bb.0: # %entry
845 ; X32-NEXT: pushl %esi
846 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
847 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
848 ; X32-NEXT: movl {{[0-9]+}}(%esp), %esi
849 ; X32-NEXT: xorl %eax, %eax
851 ; X32-NEXT: cmp %ecx,(%esi)
854 ; X32-NEXT: popl %esi
857 ; X64-LABEL: test_ccs:
858 ; X64: # %bb.0: # %entry
859 ; X64-NEXT: xorl %eax, %eax
861 ; X64-NEXT: cmp %rdi,(%rsi)
866 %cc = tail call i32 asm "cmp $2,$1", "={@ccs},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
867 %tobool = icmp ne i32 %cc, 0
868 %rv = zext i1 %tobool to i32
874 define void @test_cca_branch(i64 %nr, ptr %addr) nounwind {
875 ; X32-LABEL: test_cca_branch:
876 ; X32: # %bb.0: # %entry
877 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
878 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
879 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
881 ; X32-NEXT: cmp %eax,(%edx)
883 ; X32-NEXT: jbe .LBB28_2
884 ; X32-NEXT: # %bb.1: # %then
885 ; X32-NEXT: calll bar@PLT
886 ; X32-NEXT: .LBB28_2: # %exit
889 ; X64-LABEL: test_cca_branch:
890 ; X64: # %bb.0: # %entry
892 ; X64-NEXT: cmp %rdi,(%rsi)
894 ; X64-NEXT: jbe .LBB28_2
895 ; X64-NEXT: # %bb.1: # %then
896 ; X64-NEXT: pushq %rax
897 ; X64-NEXT: callq bar@PLT
898 ; X64-NEXT: addq $8, %rsp
899 ; X64-NEXT: .LBB28_2: # %exit
902 %cc = tail call i8 asm "cmp $2,$1", "={@cca},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
903 %tobool = icmp ne i8 %cc, 0
904 br i1 %tobool, label %then, label %exit
914 define void @test_ccae_branch(i64 %nr, ptr %addr) nounwind {
915 ; X32-LABEL: test_ccae_branch:
916 ; X32: # %bb.0: # %entry
917 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
918 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
919 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
921 ; X32-NEXT: cmp %eax,(%edx)
923 ; X32-NEXT: jb .LBB29_2
924 ; X32-NEXT: # %bb.1: # %then
925 ; X32-NEXT: calll bar@PLT
926 ; X32-NEXT: .LBB29_2: # %exit
929 ; X64-LABEL: test_ccae_branch:
930 ; X64: # %bb.0: # %entry
932 ; X64-NEXT: cmp %rdi,(%rsi)
934 ; X64-NEXT: jb .LBB29_2
935 ; X64-NEXT: # %bb.1: # %then
936 ; X64-NEXT: pushq %rax
937 ; X64-NEXT: callq bar@PLT
938 ; X64-NEXT: addq $8, %rsp
939 ; X64-NEXT: .LBB29_2: # %exit
942 %cc = tail call i8 asm "cmp $2,$1", "={@ccae},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
943 %tobool = icmp ne i8 %cc, 0
944 br i1 %tobool, label %then, label %exit
954 define void @test_ccb_branch(i64 %nr, ptr %addr) nounwind {
955 ; X32-LABEL: test_ccb_branch:
956 ; X32: # %bb.0: # %entry
957 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
958 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
959 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
961 ; X32-NEXT: cmp %eax,(%edx)
963 ; X32-NEXT: jae .LBB30_2
964 ; X32-NEXT: # %bb.1: # %then
965 ; X32-NEXT: calll bar@PLT
966 ; X32-NEXT: .LBB30_2: # %exit
969 ; X64-LABEL: test_ccb_branch:
970 ; X64: # %bb.0: # %entry
972 ; X64-NEXT: cmp %rdi,(%rsi)
974 ; X64-NEXT: jae .LBB30_2
975 ; X64-NEXT: # %bb.1: # %then
976 ; X64-NEXT: pushq %rax
977 ; X64-NEXT: callq bar@PLT
978 ; X64-NEXT: addq $8, %rsp
979 ; X64-NEXT: .LBB30_2: # %exit
982 %cc = tail call i8 asm "cmp $2,$1", "={@ccb},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
983 %tobool = icmp ne i8 %cc, 0
984 br i1 %tobool, label %then, label %exit
994 define void @test_ccbe_branch(i64 %nr, ptr %addr) nounwind {
995 ; X32-LABEL: test_ccbe_branch:
996 ; X32: # %bb.0: # %entry
997 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
998 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
999 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1001 ; X32-NEXT: cmp %eax,(%edx)
1003 ; X32-NEXT: ja .LBB31_2
1004 ; X32-NEXT: # %bb.1: # %then
1005 ; X32-NEXT: calll bar@PLT
1006 ; X32-NEXT: .LBB31_2: # %exit
1009 ; X64-LABEL: test_ccbe_branch:
1010 ; X64: # %bb.0: # %entry
1012 ; X64-NEXT: cmp %rdi,(%rsi)
1014 ; X64-NEXT: ja .LBB31_2
1015 ; X64-NEXT: # %bb.1: # %then
1016 ; X64-NEXT: pushq %rax
1017 ; X64-NEXT: callq bar@PLT
1018 ; X64-NEXT: addq $8, %rsp
1019 ; X64-NEXT: .LBB31_2: # %exit
1022 %cc = tail call i8 asm "cmp $2,$1", "={@ccbe},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1023 %tobool = icmp ne i8 %cc, 0
1024 br i1 %tobool, label %then, label %exit
1034 define void @test_ccc_branch(i64 %nr, ptr %addr) nounwind {
1035 ; X32-LABEL: test_ccc_branch:
1036 ; X32: # %bb.0: # %entry
1037 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1038 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1039 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1041 ; X32-NEXT: cmp %eax,(%edx)
1043 ; X32-NEXT: jae .LBB32_2
1044 ; X32-NEXT: # %bb.1: # %then
1045 ; X32-NEXT: calll bar@PLT
1046 ; X32-NEXT: .LBB32_2: # %exit
1049 ; X64-LABEL: test_ccc_branch:
1050 ; X64: # %bb.0: # %entry
1052 ; X64-NEXT: cmp %rdi,(%rsi)
1054 ; X64-NEXT: jae .LBB32_2
1055 ; X64-NEXT: # %bb.1: # %then
1056 ; X64-NEXT: pushq %rax
1057 ; X64-NEXT: callq bar@PLT
1058 ; X64-NEXT: addq $8, %rsp
1059 ; X64-NEXT: .LBB32_2: # %exit
1062 %cc = tail call i8 asm "cmp $2,$1", "={@ccc},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1063 %tobool = icmp ne i8 %cc, 0
1064 br i1 %tobool, label %then, label %exit
1074 define void @test_cce_branch(i64 %nr, ptr %addr) nounwind {
1075 ; X32-LABEL: test_cce_branch:
1076 ; X32: # %bb.0: # %entry
1077 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1078 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1079 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1081 ; X32-NEXT: cmp %eax,(%edx)
1083 ; X32-NEXT: jne .LBB33_2
1084 ; X32-NEXT: # %bb.1: # %then
1085 ; X32-NEXT: calll bar@PLT
1086 ; X32-NEXT: .LBB33_2: # %exit
1089 ; X64-LABEL: test_cce_branch:
1090 ; X64: # %bb.0: # %entry
1092 ; X64-NEXT: cmp %rdi,(%rsi)
1094 ; X64-NEXT: jne .LBB33_2
1095 ; X64-NEXT: # %bb.1: # %then
1096 ; X64-NEXT: pushq %rax
1097 ; X64-NEXT: callq bar@PLT
1098 ; X64-NEXT: addq $8, %rsp
1099 ; X64-NEXT: .LBB33_2: # %exit
1102 %cc = tail call i8 asm "cmp $2,$1", "={@cce},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1103 %tobool = icmp ne i8 %cc, 0
1104 br i1 %tobool, label %then, label %exit
1114 define void @test_ccz_branch(i64 %nr, ptr %addr) nounwind {
1115 ; X32-LABEL: test_ccz_branch:
1116 ; X32: # %bb.0: # %entry
1117 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1118 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1119 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1121 ; X32-NEXT: cmp %eax,(%edx)
1123 ; X32-NEXT: jne .LBB34_2
1124 ; X32-NEXT: # %bb.1: # %then
1125 ; X32-NEXT: calll bar@PLT
1126 ; X32-NEXT: .LBB34_2: # %exit
1129 ; X64-LABEL: test_ccz_branch:
1130 ; X64: # %bb.0: # %entry
1132 ; X64-NEXT: cmp %rdi,(%rsi)
1134 ; X64-NEXT: jne .LBB34_2
1135 ; X64-NEXT: # %bb.1: # %then
1136 ; X64-NEXT: pushq %rax
1137 ; X64-NEXT: callq bar@PLT
1138 ; X64-NEXT: addq $8, %rsp
1139 ; X64-NEXT: .LBB34_2: # %exit
1142 %cc = tail call i8 asm "cmp $2,$1", "={@ccz},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1143 %tobool = icmp ne i8 %cc, 0
1144 br i1 %tobool, label %then, label %exit
1154 define void @test_ccg_branch(i64 %nr, ptr %addr) nounwind {
1155 ; X32-LABEL: test_ccg_branch:
1156 ; X32: # %bb.0: # %entry
1157 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1158 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1159 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1161 ; X32-NEXT: cmp %eax,(%edx)
1163 ; X32-NEXT: jle .LBB35_2
1164 ; X32-NEXT: # %bb.1: # %then
1165 ; X32-NEXT: calll bar@PLT
1166 ; X32-NEXT: .LBB35_2: # %exit
1169 ; X64-LABEL: test_ccg_branch:
1170 ; X64: # %bb.0: # %entry
1172 ; X64-NEXT: cmp %rdi,(%rsi)
1174 ; X64-NEXT: jle .LBB35_2
1175 ; X64-NEXT: # %bb.1: # %then
1176 ; X64-NEXT: pushq %rax
1177 ; X64-NEXT: callq bar@PLT
1178 ; X64-NEXT: addq $8, %rsp
1179 ; X64-NEXT: .LBB35_2: # %exit
1182 %cc = tail call i8 asm "cmp $2,$1", "={@ccg},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1183 %tobool = icmp ne i8 %cc, 0
1184 br i1 %tobool, label %then, label %exit
1194 define void @test_ccge_branch(i64 %nr, ptr %addr) nounwind {
1195 ; X32-LABEL: test_ccge_branch:
1196 ; X32: # %bb.0: # %entry
1197 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1198 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1199 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1201 ; X32-NEXT: cmp %eax,(%edx)
1203 ; X32-NEXT: jl .LBB36_2
1204 ; X32-NEXT: # %bb.1: # %then
1205 ; X32-NEXT: calll bar@PLT
1206 ; X32-NEXT: .LBB36_2: # %exit
1209 ; X64-LABEL: test_ccge_branch:
1210 ; X64: # %bb.0: # %entry
1212 ; X64-NEXT: cmp %rdi,(%rsi)
1214 ; X64-NEXT: jl .LBB36_2
1215 ; X64-NEXT: # %bb.1: # %then
1216 ; X64-NEXT: pushq %rax
1217 ; X64-NEXT: callq bar@PLT
1218 ; X64-NEXT: addq $8, %rsp
1219 ; X64-NEXT: .LBB36_2: # %exit
1222 %cc = tail call i8 asm "cmp $2,$1", "={@ccge},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1223 %tobool = icmp ne i8 %cc, 0
1224 br i1 %tobool, label %then, label %exit
1234 define void @test_ccl_branch(i64 %nr, ptr %addr) nounwind {
1235 ; X32-LABEL: test_ccl_branch:
1236 ; X32: # %bb.0: # %entry
1237 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1238 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1239 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1241 ; X32-NEXT: cmp %eax,(%edx)
1243 ; X32-NEXT: jge .LBB37_2
1244 ; X32-NEXT: # %bb.1: # %then
1245 ; X32-NEXT: calll bar@PLT
1246 ; X32-NEXT: .LBB37_2: # %exit
1249 ; X64-LABEL: test_ccl_branch:
1250 ; X64: # %bb.0: # %entry
1252 ; X64-NEXT: cmp %rdi,(%rsi)
1254 ; X64-NEXT: jge .LBB37_2
1255 ; X64-NEXT: # %bb.1: # %then
1256 ; X64-NEXT: pushq %rax
1257 ; X64-NEXT: callq bar@PLT
1258 ; X64-NEXT: addq $8, %rsp
1259 ; X64-NEXT: .LBB37_2: # %exit
1262 %cc = tail call i8 asm "cmp $2,$1", "={@ccl},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1263 %tobool = icmp ne i8 %cc, 0
1264 br i1 %tobool, label %then, label %exit
1274 define void @test_ccle_branch(i64 %nr, ptr %addr) nounwind {
1275 ; X32-LABEL: test_ccle_branch:
1276 ; X32: # %bb.0: # %entry
1277 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1278 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1279 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1281 ; X32-NEXT: cmp %eax,(%edx)
1283 ; X32-NEXT: jg .LBB38_2
1284 ; X32-NEXT: # %bb.1: # %then
1285 ; X32-NEXT: calll bar@PLT
1286 ; X32-NEXT: .LBB38_2: # %exit
1289 ; X64-LABEL: test_ccle_branch:
1290 ; X64: # %bb.0: # %entry
1292 ; X64-NEXT: cmp %rdi,(%rsi)
1294 ; X64-NEXT: jg .LBB38_2
1295 ; X64-NEXT: # %bb.1: # %then
1296 ; X64-NEXT: pushq %rax
1297 ; X64-NEXT: callq bar@PLT
1298 ; X64-NEXT: addq $8, %rsp
1299 ; X64-NEXT: .LBB38_2: # %exit
1302 %cc = tail call i8 asm "cmp $2,$1", "={@ccle},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1303 %tobool = icmp ne i8 %cc, 0
1304 br i1 %tobool, label %then, label %exit
1314 define void @test_ccna_branch(i64 %nr, ptr %addr) nounwind {
1315 ; X32-LABEL: test_ccna_branch:
1316 ; X32: # %bb.0: # %entry
1317 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1318 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1319 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1321 ; X32-NEXT: cmp %eax,(%edx)
1323 ; X32-NEXT: ja .LBB39_2
1324 ; X32-NEXT: # %bb.1: # %then
1325 ; X32-NEXT: calll bar@PLT
1326 ; X32-NEXT: .LBB39_2: # %exit
1329 ; X64-LABEL: test_ccna_branch:
1330 ; X64: # %bb.0: # %entry
1332 ; X64-NEXT: cmp %rdi,(%rsi)
1334 ; X64-NEXT: ja .LBB39_2
1335 ; X64-NEXT: # %bb.1: # %then
1336 ; X64-NEXT: pushq %rax
1337 ; X64-NEXT: callq bar@PLT
1338 ; X64-NEXT: addq $8, %rsp
1339 ; X64-NEXT: .LBB39_2: # %exit
1342 %cc = tail call i8 asm "cmp $2,$1", "={@ccna},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1343 %tobool = icmp ne i8 %cc, 0
1344 br i1 %tobool, label %then, label %exit
1354 define void @test_ccnae_branch(i64 %nr, ptr %addr) nounwind {
1355 ; X32-LABEL: test_ccnae_branch:
1356 ; X32: # %bb.0: # %entry
1357 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1358 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1359 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1361 ; X32-NEXT: cmp %eax,(%edx)
1363 ; X32-NEXT: jae .LBB40_2
1364 ; X32-NEXT: # %bb.1: # %then
1365 ; X32-NEXT: calll bar@PLT
1366 ; X32-NEXT: .LBB40_2: # %exit
1369 ; X64-LABEL: test_ccnae_branch:
1370 ; X64: # %bb.0: # %entry
1372 ; X64-NEXT: cmp %rdi,(%rsi)
1374 ; X64-NEXT: jae .LBB40_2
1375 ; X64-NEXT: # %bb.1: # %then
1376 ; X64-NEXT: pushq %rax
1377 ; X64-NEXT: callq bar@PLT
1378 ; X64-NEXT: addq $8, %rsp
1379 ; X64-NEXT: .LBB40_2: # %exit
1382 %cc = tail call i8 asm "cmp $2,$1", "={@ccnae},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1383 %tobool = icmp ne i8 %cc, 0
1384 br i1 %tobool, label %then, label %exit
1394 define void @test_ccnb_branch(i64 %nr, ptr %addr) nounwind {
1395 ; X32-LABEL: test_ccnb_branch:
1396 ; X32: # %bb.0: # %entry
1397 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1398 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1399 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1401 ; X32-NEXT: cmp %eax,(%edx)
1403 ; X32-NEXT: jb .LBB41_2
1404 ; X32-NEXT: # %bb.1: # %then
1405 ; X32-NEXT: calll bar@PLT
1406 ; X32-NEXT: .LBB41_2: # %exit
1409 ; X64-LABEL: test_ccnb_branch:
1410 ; X64: # %bb.0: # %entry
1412 ; X64-NEXT: cmp %rdi,(%rsi)
1414 ; X64-NEXT: jb .LBB41_2
1415 ; X64-NEXT: # %bb.1: # %then
1416 ; X64-NEXT: pushq %rax
1417 ; X64-NEXT: callq bar@PLT
1418 ; X64-NEXT: addq $8, %rsp
1419 ; X64-NEXT: .LBB41_2: # %exit
1422 %cc = tail call i8 asm "cmp $2,$1", "={@ccnb},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1423 %tobool = icmp ne i8 %cc, 0
1424 br i1 %tobool, label %then, label %exit
1434 define void @test_ccnbe_branch(i64 %nr, ptr %addr) nounwind {
1435 ; X32-LABEL: test_ccnbe_branch:
1436 ; X32: # %bb.0: # %entry
1437 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1438 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1439 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1441 ; X32-NEXT: cmp %eax,(%edx)
1443 ; X32-NEXT: jbe .LBB42_2
1444 ; X32-NEXT: # %bb.1: # %then
1445 ; X32-NEXT: calll bar@PLT
1446 ; X32-NEXT: .LBB42_2: # %exit
1449 ; X64-LABEL: test_ccnbe_branch:
1450 ; X64: # %bb.0: # %entry
1452 ; X64-NEXT: cmp %rdi,(%rsi)
1454 ; X64-NEXT: jbe .LBB42_2
1455 ; X64-NEXT: # %bb.1: # %then
1456 ; X64-NEXT: pushq %rax
1457 ; X64-NEXT: callq bar@PLT
1458 ; X64-NEXT: addq $8, %rsp
1459 ; X64-NEXT: .LBB42_2: # %exit
1462 %cc = tail call i8 asm "cmp $2,$1", "={@ccnbe},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1463 %tobool = icmp ne i8 %cc, 0
1464 br i1 %tobool, label %then, label %exit
1474 define void @test_ccnc_branch(i64 %nr, ptr %addr) nounwind {
1475 ; X32-LABEL: test_ccnc_branch:
1476 ; X32: # %bb.0: # %entry
1477 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1478 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1479 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1481 ; X32-NEXT: cmp %eax,(%edx)
1483 ; X32-NEXT: jb .LBB43_2
1484 ; X32-NEXT: # %bb.1: # %then
1485 ; X32-NEXT: calll bar@PLT
1486 ; X32-NEXT: .LBB43_2: # %exit
1489 ; X64-LABEL: test_ccnc_branch:
1490 ; X64: # %bb.0: # %entry
1492 ; X64-NEXT: cmp %rdi,(%rsi)
1494 ; X64-NEXT: jb .LBB43_2
1495 ; X64-NEXT: # %bb.1: # %then
1496 ; X64-NEXT: pushq %rax
1497 ; X64-NEXT: callq bar@PLT
1498 ; X64-NEXT: addq $8, %rsp
1499 ; X64-NEXT: .LBB43_2: # %exit
1502 %cc = tail call i8 asm "cmp $2,$1", "={@ccnc},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1503 %tobool = icmp ne i8 %cc, 0
1504 br i1 %tobool, label %then, label %exit
1514 define void @test_ccne_branch(i64 %nr, ptr %addr) nounwind {
1515 ; X32-LABEL: test_ccne_branch:
1516 ; X32: # %bb.0: # %entry
1517 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1518 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1519 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1521 ; X32-NEXT: cmp %eax,(%edx)
1523 ; X32-NEXT: je .LBB44_2
1524 ; X32-NEXT: # %bb.1: # %then
1525 ; X32-NEXT: calll bar@PLT
1526 ; X32-NEXT: .LBB44_2: # %exit
1529 ; X64-LABEL: test_ccne_branch:
1530 ; X64: # %bb.0: # %entry
1532 ; X64-NEXT: cmp %rdi,(%rsi)
1534 ; X64-NEXT: je .LBB44_2
1535 ; X64-NEXT: # %bb.1: # %then
1536 ; X64-NEXT: pushq %rax
1537 ; X64-NEXT: callq bar@PLT
1538 ; X64-NEXT: addq $8, %rsp
1539 ; X64-NEXT: .LBB44_2: # %exit
1542 %cc = tail call i8 asm "cmp $2,$1", "={@ccne},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1543 %tobool = icmp ne i8 %cc, 0
1544 br i1 %tobool, label %then, label %exit
1554 define void @test_ccnz_branch(i64 %nr, ptr %addr) nounwind {
1555 ; X32-LABEL: test_ccnz_branch:
1556 ; X32: # %bb.0: # %entry
1557 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1558 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1559 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1561 ; X32-NEXT: cmp %eax,(%edx)
1563 ; X32-NEXT: je .LBB45_2
1564 ; X32-NEXT: # %bb.1: # %then
1565 ; X32-NEXT: calll bar@PLT
1566 ; X32-NEXT: .LBB45_2: # %exit
1569 ; X64-LABEL: test_ccnz_branch:
1570 ; X64: # %bb.0: # %entry
1572 ; X64-NEXT: cmp %rdi,(%rsi)
1574 ; X64-NEXT: je .LBB45_2
1575 ; X64-NEXT: # %bb.1: # %then
1576 ; X64-NEXT: pushq %rax
1577 ; X64-NEXT: callq bar@PLT
1578 ; X64-NEXT: addq $8, %rsp
1579 ; X64-NEXT: .LBB45_2: # %exit
1582 %cc = tail call i8 asm "cmp $2,$1", "={@ccnz},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1583 %tobool = icmp ne i8 %cc, 0
1584 br i1 %tobool, label %then, label %exit
1594 define void @test_ccng_branch(i64 %nr, ptr %addr) nounwind {
1595 ; X32-LABEL: test_ccng_branch:
1596 ; X32: # %bb.0: # %entry
1597 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1598 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1599 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1601 ; X32-NEXT: cmp %eax,(%edx)
1603 ; X32-NEXT: jg .LBB46_2
1604 ; X32-NEXT: # %bb.1: # %then
1605 ; X32-NEXT: calll bar@PLT
1606 ; X32-NEXT: .LBB46_2: # %exit
1609 ; X64-LABEL: test_ccng_branch:
1610 ; X64: # %bb.0: # %entry
1612 ; X64-NEXT: cmp %rdi,(%rsi)
1614 ; X64-NEXT: jg .LBB46_2
1615 ; X64-NEXT: # %bb.1: # %then
1616 ; X64-NEXT: pushq %rax
1617 ; X64-NEXT: callq bar@PLT
1618 ; X64-NEXT: addq $8, %rsp
1619 ; X64-NEXT: .LBB46_2: # %exit
1622 %cc = tail call i8 asm "cmp $2,$1", "={@ccng},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1623 %tobool = icmp ne i8 %cc, 0
1624 br i1 %tobool, label %then, label %exit
1634 define void @test_ccnge_branch(i64 %nr, ptr %addr) nounwind {
1635 ; X32-LABEL: test_ccnge_branch:
1636 ; X32: # %bb.0: # %entry
1637 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1638 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1639 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1641 ; X32-NEXT: cmp %eax,(%edx)
1643 ; X32-NEXT: jge .LBB47_2
1644 ; X32-NEXT: # %bb.1: # %then
1645 ; X32-NEXT: calll bar@PLT
1646 ; X32-NEXT: .LBB47_2: # %exit
1649 ; X64-LABEL: test_ccnge_branch:
1650 ; X64: # %bb.0: # %entry
1652 ; X64-NEXT: cmp %rdi,(%rsi)
1654 ; X64-NEXT: jge .LBB47_2
1655 ; X64-NEXT: # %bb.1: # %then
1656 ; X64-NEXT: pushq %rax
1657 ; X64-NEXT: callq bar@PLT
1658 ; X64-NEXT: addq $8, %rsp
1659 ; X64-NEXT: .LBB47_2: # %exit
1662 %cc = tail call i8 asm "cmp $2,$1", "={@ccnge},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1663 %tobool = icmp ne i8 %cc, 0
1664 br i1 %tobool, label %then, label %exit
1674 define void @test_ccnl_branch(i64 %nr, ptr %addr) nounwind {
1675 ; X32-LABEL: test_ccnl_branch:
1676 ; X32: # %bb.0: # %entry
1677 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1678 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1679 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1681 ; X32-NEXT: cmp %eax,(%edx)
1683 ; X32-NEXT: jl .LBB48_2
1684 ; X32-NEXT: # %bb.1: # %then
1685 ; X32-NEXT: calll bar@PLT
1686 ; X32-NEXT: .LBB48_2: # %exit
1689 ; X64-LABEL: test_ccnl_branch:
1690 ; X64: # %bb.0: # %entry
1692 ; X64-NEXT: cmp %rdi,(%rsi)
1694 ; X64-NEXT: jl .LBB48_2
1695 ; X64-NEXT: # %bb.1: # %then
1696 ; X64-NEXT: pushq %rax
1697 ; X64-NEXT: callq bar@PLT
1698 ; X64-NEXT: addq $8, %rsp
1699 ; X64-NEXT: .LBB48_2: # %exit
1702 %cc = tail call i8 asm "cmp $2,$1", "={@ccnl},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1703 %tobool = icmp ne i8 %cc, 0
1704 br i1 %tobool, label %then, label %exit
1714 define void @test_ccnle_branch(i64 %nr, ptr %addr) nounwind {
1715 ; X32-LABEL: test_ccnle_branch:
1716 ; X32: # %bb.0: # %entry
1717 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1718 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1719 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1721 ; X32-NEXT: cmp %eax,(%edx)
1723 ; X32-NEXT: jle .LBB49_2
1724 ; X32-NEXT: # %bb.1: # %then
1725 ; X32-NEXT: calll bar@PLT
1726 ; X32-NEXT: .LBB49_2: # %exit
1729 ; X64-LABEL: test_ccnle_branch:
1730 ; X64: # %bb.0: # %entry
1732 ; X64-NEXT: cmp %rdi,(%rsi)
1734 ; X64-NEXT: jle .LBB49_2
1735 ; X64-NEXT: # %bb.1: # %then
1736 ; X64-NEXT: pushq %rax
1737 ; X64-NEXT: callq bar@PLT
1738 ; X64-NEXT: addq $8, %rsp
1739 ; X64-NEXT: .LBB49_2: # %exit
1742 %cc = tail call i8 asm "cmp $2,$1", "={@ccnle},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1743 %tobool = icmp ne i8 %cc, 0
1744 br i1 %tobool, label %then, label %exit
1754 define void @test_ccno_branch(i64 %nr, ptr %addr) nounwind {
1755 ; X32-LABEL: test_ccno_branch:
1756 ; X32: # %bb.0: # %entry
1757 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1758 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1759 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1761 ; X32-NEXT: cmp %eax,(%edx)
1763 ; X32-NEXT: jo .LBB50_2
1764 ; X32-NEXT: # %bb.1: # %then
1765 ; X32-NEXT: calll bar@PLT
1766 ; X32-NEXT: .LBB50_2: # %exit
1769 ; X64-LABEL: test_ccno_branch:
1770 ; X64: # %bb.0: # %entry
1772 ; X64-NEXT: cmp %rdi,(%rsi)
1774 ; X64-NEXT: jo .LBB50_2
1775 ; X64-NEXT: # %bb.1: # %then
1776 ; X64-NEXT: pushq %rax
1777 ; X64-NEXT: callq bar@PLT
1778 ; X64-NEXT: addq $8, %rsp
1779 ; X64-NEXT: .LBB50_2: # %exit
1782 %cc = tail call i8 asm "cmp $2,$1", "={@ccno},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1783 %tobool = icmp ne i8 %cc, 0
1784 br i1 %tobool, label %then, label %exit
1794 define void @test_ccnp_branch(i64 %nr, ptr %addr) nounwind {
1795 ; X32-LABEL: test_ccnp_branch:
1796 ; X32: # %bb.0: # %entry
1797 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1798 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1799 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1801 ; X32-NEXT: cmp %eax,(%edx)
1803 ; X32-NEXT: jp .LBB51_2
1804 ; X32-NEXT: # %bb.1: # %then
1805 ; X32-NEXT: calll bar@PLT
1806 ; X32-NEXT: .LBB51_2: # %exit
1809 ; X64-LABEL: test_ccnp_branch:
1810 ; X64: # %bb.0: # %entry
1812 ; X64-NEXT: cmp %rdi,(%rsi)
1814 ; X64-NEXT: jp .LBB51_2
1815 ; X64-NEXT: # %bb.1: # %then
1816 ; X64-NEXT: pushq %rax
1817 ; X64-NEXT: callq bar@PLT
1818 ; X64-NEXT: addq $8, %rsp
1819 ; X64-NEXT: .LBB51_2: # %exit
1822 %cc = tail call i8 asm "cmp $2,$1", "={@ccnp},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1823 %tobool = icmp ne i8 %cc, 0
1824 br i1 %tobool, label %then, label %exit
1834 define void @test_ccns_branch(i64 %nr, ptr %addr) nounwind {
1835 ; X32-LABEL: test_ccns_branch:
1836 ; X32: # %bb.0: # %entry
1837 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1838 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1839 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1841 ; X32-NEXT: cmp %eax,(%edx)
1843 ; X32-NEXT: js .LBB52_2
1844 ; X32-NEXT: # %bb.1: # %then
1845 ; X32-NEXT: calll bar@PLT
1846 ; X32-NEXT: .LBB52_2: # %exit
1849 ; X64-LABEL: test_ccns_branch:
1850 ; X64: # %bb.0: # %entry
1852 ; X64-NEXT: cmp %rdi,(%rsi)
1854 ; X64-NEXT: js .LBB52_2
1855 ; X64-NEXT: # %bb.1: # %then
1856 ; X64-NEXT: pushq %rax
1857 ; X64-NEXT: callq bar@PLT
1858 ; X64-NEXT: addq $8, %rsp
1859 ; X64-NEXT: .LBB52_2: # %exit
1862 %cc = tail call i8 asm "cmp $2,$1", "={@ccns},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1863 %tobool = icmp ne i8 %cc, 0
1864 br i1 %tobool, label %then, label %exit
1874 define void @test_cco_branch(i64 %nr, ptr %addr) nounwind {
1875 ; X32-LABEL: test_cco_branch:
1876 ; X32: # %bb.0: # %entry
1877 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1878 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1879 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1881 ; X32-NEXT: cmp %eax,(%edx)
1883 ; X32-NEXT: jno .LBB53_2
1884 ; X32-NEXT: # %bb.1: # %then
1885 ; X32-NEXT: calll bar@PLT
1886 ; X32-NEXT: .LBB53_2: # %exit
1889 ; X64-LABEL: test_cco_branch:
1890 ; X64: # %bb.0: # %entry
1892 ; X64-NEXT: cmp %rdi,(%rsi)
1894 ; X64-NEXT: jno .LBB53_2
1895 ; X64-NEXT: # %bb.1: # %then
1896 ; X64-NEXT: pushq %rax
1897 ; X64-NEXT: callq bar@PLT
1898 ; X64-NEXT: addq $8, %rsp
1899 ; X64-NEXT: .LBB53_2: # %exit
1902 %cc = tail call i8 asm "cmp $2,$1", "={@cco},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1903 %tobool = icmp ne i8 %cc, 0
1904 br i1 %tobool, label %then, label %exit
1914 define void @test_ccp_branch(i64 %nr, ptr %addr) nounwind {
1915 ; X32-LABEL: test_ccp_branch:
1916 ; X32: # %bb.0: # %entry
1917 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1918 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1919 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1921 ; X32-NEXT: cmp %eax,(%edx)
1923 ; X32-NEXT: jnp .LBB54_2
1924 ; X32-NEXT: # %bb.1: # %then
1925 ; X32-NEXT: calll bar@PLT
1926 ; X32-NEXT: .LBB54_2: # %exit
1929 ; X64-LABEL: test_ccp_branch:
1930 ; X64: # %bb.0: # %entry
1932 ; X64-NEXT: cmp %rdi,(%rsi)
1934 ; X64-NEXT: jnp .LBB54_2
1935 ; X64-NEXT: # %bb.1: # %then
1936 ; X64-NEXT: pushq %rax
1937 ; X64-NEXT: callq bar@PLT
1938 ; X64-NEXT: addq $8, %rsp
1939 ; X64-NEXT: .LBB54_2: # %exit
1942 %cc = tail call i8 asm "cmp $2,$1", "={@ccp},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1943 %tobool = icmp ne i8 %cc, 0
1944 br i1 %tobool, label %then, label %exit
1954 define void @test_ccs_branch(i64 %nr, ptr %addr) nounwind {
1955 ; X32-LABEL: test_ccs_branch:
1956 ; X32: # %bb.0: # %entry
1957 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
1958 ; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
1959 ; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
1961 ; X32-NEXT: cmp %eax,(%edx)
1963 ; X32-NEXT: jns .LBB55_2
1964 ; X32-NEXT: # %bb.1: # %then
1965 ; X32-NEXT: calll bar@PLT
1966 ; X32-NEXT: .LBB55_2: # %exit
1969 ; X64-LABEL: test_ccs_branch:
1970 ; X64: # %bb.0: # %entry
1972 ; X64-NEXT: cmp %rdi,(%rsi)
1974 ; X64-NEXT: jns .LBB55_2
1975 ; X64-NEXT: # %bb.1: # %then
1976 ; X64-NEXT: pushq %rax
1977 ; X64-NEXT: callq bar@PLT
1978 ; X64-NEXT: addq $8, %rsp
1979 ; X64-NEXT: .LBB55_2: # %exit
1982 %cc = tail call i8 asm "cmp $2,$1", "={@ccs},=*m,r,~{cc},~{dirflag},~{fpsr},~{flags}"(ptr elementtype(i64) %addr, i64 %nr) nounwind
1983 %tobool = icmp ne i8 %cc, 0
1984 br i1 %tobool, label %then, label %exit