Dan Gohman | fce288f | 2009-09-09 00:09:15 +0000 | [diff] [blame] | 1 | ; RUN: llc < %s | grep je | count 1 |
| 2 | ; RUN: llc < %s | grep jne | count 1 |
| 3 | ; RUN: llc < %s | grep jhe | count 2 |
| 4 | ; RUN: llc < %s | grep jle | count 2 |
| 5 | ; RUN: llc < %s | grep jh | count 4 |
| 6 | ; RUN: llc < %s | grep jl | count 4 |
Anton Korobeynikov | ecf22d5 | 2009-07-16 13:53:15 +0000 | [diff] [blame] | 7 | |
| 8 | target datalayout = "E-p:64:64:64-i1:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-f128:128:128" |
| 9 | target triple = "s390x-unknown-linux-gnu" |
| 10 | |
| 11 | define void @foo(i64 %a, i64 %b) nounwind { |
| 12 | entry: |
| 13 | %cmp = icmp ult i64 %a, %b ; <i1> [#uses=1] |
| 14 | br i1 %cmp, label %if.then, label %if.end |
| 15 | |
| 16 | if.then: ; preds = %entry |
| 17 | tail call void @bar() nounwind |
| 18 | ret void |
| 19 | |
| 20 | if.end: ; preds = %entry |
| 21 | ret void |
| 22 | } |
| 23 | |
| 24 | declare void @bar() |
| 25 | |
| 26 | define void @foo1(i64 %a, i64 %b) nounwind { |
| 27 | entry: |
| 28 | %cmp = icmp ugt i64 %a, %b ; <i1> [#uses=1] |
| 29 | br i1 %cmp, label %if.then, label %if.end |
| 30 | |
| 31 | if.then: ; preds = %entry |
| 32 | tail call void @bar() nounwind |
| 33 | ret void |
| 34 | |
| 35 | if.end: ; preds = %entry |
| 36 | ret void |
| 37 | } |
| 38 | |
| 39 | define void @foo2(i64 %a, i64 %b) nounwind { |
| 40 | entry: |
| 41 | %cmp = icmp ugt i64 %a, %b ; <i1> [#uses=1] |
| 42 | br i1 %cmp, label %if.end, label %if.then |
| 43 | |
| 44 | if.then: ; preds = %entry |
| 45 | tail call void @bar() nounwind |
| 46 | ret void |
| 47 | |
| 48 | if.end: ; preds = %entry |
| 49 | ret void |
| 50 | } |
| 51 | |
| 52 | define void @foo3(i64 %a, i64 %b) nounwind { |
| 53 | entry: |
| 54 | %cmp = icmp ult i64 %a, %b ; <i1> [#uses=1] |
| 55 | br i1 %cmp, label %if.end, label %if.then |
| 56 | |
| 57 | if.then: ; preds = %entry |
| 58 | tail call void @bar() nounwind |
| 59 | ret void |
| 60 | |
| 61 | if.end: ; preds = %entry |
| 62 | ret void |
| 63 | } |
| 64 | |
| 65 | define void @foo4(i64 %a, i64 %b) nounwind { |
| 66 | entry: |
| 67 | %cmp = icmp eq i64 %a, %b ; <i1> [#uses=1] |
| 68 | br i1 %cmp, label %if.then, label %if.end |
| 69 | |
| 70 | if.then: ; preds = %entry |
| 71 | tail call void @bar() nounwind |
| 72 | ret void |
| 73 | |
| 74 | if.end: ; preds = %entry |
| 75 | ret void |
| 76 | } |
| 77 | |
| 78 | define void @foo5(i64 %a, i64 %b) nounwind { |
| 79 | entry: |
| 80 | %cmp = icmp eq i64 %a, %b ; <i1> [#uses=1] |
| 81 | br i1 %cmp, label %if.end, label %if.then |
| 82 | |
| 83 | if.then: ; preds = %entry |
| 84 | tail call void @bar() nounwind |
| 85 | ret void |
| 86 | |
| 87 | if.end: ; preds = %entry |
| 88 | ret void |
| 89 | } |
| 90 | |
| 91 | define void @foo6(i64 %a, i64 %b) nounwind { |
| 92 | entry: |
| 93 | %cmp = icmp slt i64 %a, %b ; <i1> [#uses=1] |
| 94 | br i1 %cmp, label %if.then, label %if.end |
| 95 | |
| 96 | if.then: ; preds = %entry |
| 97 | tail call void @bar() nounwind |
| 98 | ret void |
| 99 | |
| 100 | if.end: ; preds = %entry |
| 101 | ret void |
| 102 | } |
| 103 | |
| 104 | define void @foo7(i64 %a, i64 %b) nounwind { |
| 105 | entry: |
| 106 | %cmp = icmp sgt i64 %a, %b ; <i1> [#uses=1] |
| 107 | br i1 %cmp, label %if.then, label %if.end |
| 108 | |
| 109 | if.then: ; preds = %entry |
| 110 | tail call void @bar() nounwind |
| 111 | ret void |
| 112 | |
| 113 | if.end: ; preds = %entry |
| 114 | ret void |
| 115 | } |
| 116 | |
| 117 | define void @foo8(i64 %a, i64 %b) nounwind { |
| 118 | entry: |
| 119 | %cmp = icmp sgt i64 %a, %b ; <i1> [#uses=1] |
| 120 | br i1 %cmp, label %if.end, label %if.then |
| 121 | |
| 122 | if.then: ; preds = %entry |
| 123 | tail call void @bar() nounwind |
| 124 | ret void |
| 125 | |
| 126 | if.end: ; preds = %entry |
| 127 | ret void |
| 128 | } |
| 129 | |
| 130 | define void @foo9(i64 %a, i64 %b) nounwind { |
| 131 | entry: |
| 132 | %cmp = icmp slt i64 %a, %b ; <i1> [#uses=1] |
| 133 | br i1 %cmp, label %if.end, label %if.then |
| 134 | |
| 135 | if.then: ; preds = %entry |
| 136 | tail call void @bar() nounwind |
| 137 | ret void |
| 138 | |
| 139 | if.end: ; preds = %entry |
| 140 | ret void |
| 141 | } |