| 1 |
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py |
| 2 |
# RUN: llc -mtriple=riscv64 -run-pass=legalizer %s -o - \ |
| 3 |
# RUN: | FileCheck %s |
| 4 |
|
| 5 |
--- |
| 6 |
name: saddo_i8 |
| 7 |
body: | |
| 8 |
bb.1: |
| 9 |
liveins: $x10, $x11 |
| 10 |
|
| 11 |
; CHECK-LABEL: name: saddo_i8 |
| 12 |
; CHECK: liveins: $x10, $x11 |
| 13 |
; CHECK-NEXT: {{ $}} |
| 14 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 15 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 16 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 56 |
| 17 |
; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s64) = G_SHL [[COPY]], [[C]](s64) |
| 18 |
; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s64) = G_ASHR [[SHL]], [[C]](s64) |
| 19 |
; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s64) = G_SHL [[COPY1]], [[C]](s64) |
| 20 |
; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s64) = G_ASHR [[SHL1]], [[C]](s64) |
| 21 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[ASHR]], [[ASHR1]] |
| 22 |
; CHECK-NEXT: [[SHL2:%[0-9]+]]:_(s64) = G_SHL [[ADD]], [[C]](s64) |
| 23 |
; CHECK-NEXT: [[ASHR2:%[0-9]+]]:_(s64) = G_ASHR [[SHL2]], [[C]](s64) |
| 24 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ne), [[ADD]](s64), [[ASHR2]] |
| 25 |
; CHECK-NEXT: $x10 = COPY [[ADD]](s64) |
| 26 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 27 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 28 |
%2:_(s64) = COPY $x10 |
| 29 |
%0:_(s8) = G_TRUNC %2(s64) |
| 30 |
%3:_(s64) = COPY $x11 |
| 31 |
%1:_(s8) = G_TRUNC %3(s64) |
| 32 |
%4:_(s8), %5:_(s1) = G_SADDO %0, %1 |
| 33 |
%6:_(s64) = G_ANYEXT %4(s8) |
| 34 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 35 |
$x10 = COPY %6(s64) |
| 36 |
$x11 = COPY %7(s64) |
| 37 |
PseudoRET implicit $x10, implicit $x11 |
| 38 |
|
| 39 |
... |
| 40 |
--- |
| 41 |
name: saddo_i16 |
| 42 |
body: | |
| 43 |
bb.1: |
| 44 |
liveins: $x10, $x11 |
| 45 |
|
| 46 |
; CHECK-LABEL: name: saddo_i16 |
| 47 |
; CHECK: liveins: $x10, $x11 |
| 48 |
; CHECK-NEXT: {{ $}} |
| 49 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 50 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 51 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 48 |
| 52 |
; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s64) = G_SHL [[COPY]], [[C]](s64) |
| 53 |
; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s64) = G_ASHR [[SHL]], [[C]](s64) |
| 54 |
; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s64) = G_SHL [[COPY1]], [[C]](s64) |
| 55 |
; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s64) = G_ASHR [[SHL1]], [[C]](s64) |
| 56 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[ASHR]], [[ASHR1]] |
| 57 |
; CHECK-NEXT: [[SHL2:%[0-9]+]]:_(s64) = G_SHL [[ADD]], [[C]](s64) |
| 58 |
; CHECK-NEXT: [[ASHR2:%[0-9]+]]:_(s64) = G_ASHR [[SHL2]], [[C]](s64) |
| 59 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ne), [[ADD]](s64), [[ASHR2]] |
| 60 |
; CHECK-NEXT: $x10 = COPY [[ADD]](s64) |
| 61 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 62 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 63 |
%2:_(s64) = COPY $x10 |
| 64 |
%0:_(s16) = G_TRUNC %2(s64) |
| 65 |
%3:_(s64) = COPY $x11 |
| 66 |
%1:_(s16) = G_TRUNC %3(s64) |
| 67 |
%4:_(s16), %5:_(s1) = G_SADDO %0, %1 |
| 68 |
%6:_(s64) = G_ANYEXT %4(s16) |
| 69 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 70 |
$x10 = COPY %6(s64) |
| 71 |
$x11 = COPY %7(s64) |
| 72 |
PseudoRET implicit $x10, implicit $x11 |
| 73 |
|
| 74 |
... |
| 75 |
--- |
| 76 |
name: saddo_i32 |
| 77 |
body: | |
| 78 |
bb.1: |
| 79 |
liveins: $x10, $x11 |
| 80 |
|
| 81 |
; CHECK-LABEL: name: saddo_i32 |
| 82 |
; CHECK: liveins: $x10, $x11 |
| 83 |
; CHECK-NEXT: {{ $}} |
| 84 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 85 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 86 |
; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY]], 32 |
| 87 |
; CHECK-NEXT: [[SEXT_INREG1:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY1]], 32 |
| 88 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[SEXT_INREG]], [[SEXT_INREG1]] |
| 89 |
; CHECK-NEXT: [[SEXT_INREG2:%[0-9]+]]:_(s64) = G_SEXT_INREG [[ADD]], 32 |
| 90 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ne), [[ADD]](s64), [[SEXT_INREG2]] |
| 91 |
; CHECK-NEXT: $x10 = COPY [[ADD]](s64) |
| 92 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 93 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 94 |
%2:_(s64) = COPY $x10 |
| 95 |
%0:_(s32) = G_TRUNC %2(s64) |
| 96 |
%3:_(s64) = COPY $x11 |
| 97 |
%1:_(s32) = G_TRUNC %3(s64) |
| 98 |
%4:_(s32), %5:_(s1) = G_SADDO %0, %1 |
| 99 |
%6:_(s64) = G_ANYEXT %4(s32) |
| 100 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 101 |
$x10 = COPY %6(s64) |
| 102 |
$x11 = COPY %7(s64) |
| 103 |
PseudoRET implicit $x10, implicit $x11 |
| 104 |
|
| 105 |
... |
| 106 |
--- |
| 107 |
name: saddo_i64 |
| 108 |
body: | |
| 109 |
bb.1: |
| 110 |
liveins: $x10, $x11 |
| 111 |
|
| 112 |
; CHECK-LABEL: name: saddo_i64 |
| 113 |
; CHECK: liveins: $x10, $x11 |
| 114 |
; CHECK-NEXT: {{ $}} |
| 115 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 116 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 117 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[COPY]], [[COPY1]] |
| 118 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 0 |
| 119 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(slt), [[ADD]](s64), [[COPY]] |
| 120 |
; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s64) = G_ICMP intpred(slt), [[COPY1]](s64), [[C]] |
| 121 |
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[ICMP1]], [[ICMP]] |
| 122 |
; CHECK-NEXT: [[COPY2:%[0-9]+]]:_(s64) = COPY [[ADD]](s64) |
| 123 |
; CHECK-NEXT: $x10 = COPY [[COPY2]](s64) |
| 124 |
; CHECK-NEXT: $x11 = COPY [[XOR]](s64) |
| 125 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 126 |
%0:_(s64) = COPY $x10 |
| 127 |
%1:_(s64) = COPY $x11 |
| 128 |
%2:_(s64), %3:_(s1) = G_SADDO %0, %1 |
| 129 |
%4:_(s64) = G_ANYEXT %3(s1) |
| 130 |
$x10 = COPY %2(s64) |
| 131 |
$x11 = COPY %4(s64) |
| 132 |
PseudoRET implicit $x10, implicit $x11 |
| 133 |
|
| 134 |
... |
| 135 |
--- |
| 136 |
name: ssubo_i8 |
| 137 |
body: | |
| 138 |
bb.1: |
| 139 |
liveins: $x10, $x11 |
| 140 |
|
| 141 |
; CHECK-LABEL: name: ssubo_i8 |
| 142 |
; CHECK: liveins: $x10, $x11 |
| 143 |
; CHECK-NEXT: {{ $}} |
| 144 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 145 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 146 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 56 |
| 147 |
; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s64) = G_SHL [[COPY]], [[C]](s64) |
| 148 |
; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s64) = G_ASHR [[SHL]], [[C]](s64) |
| 149 |
; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s64) = G_SHL [[COPY1]], [[C]](s64) |
| 150 |
; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s64) = G_ASHR [[SHL1]], [[C]](s64) |
| 151 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[ASHR]], [[ASHR1]] |
| 152 |
; CHECK-NEXT: [[SHL2:%[0-9]+]]:_(s64) = G_SHL [[SUB]], [[C]](s64) |
| 153 |
; CHECK-NEXT: [[ASHR2:%[0-9]+]]:_(s64) = G_ASHR [[SHL2]], [[C]](s64) |
| 154 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ne), [[SUB]](s64), [[ASHR2]] |
| 155 |
; CHECK-NEXT: $x10 = COPY [[SUB]](s64) |
| 156 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 157 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 158 |
%2:_(s64) = COPY $x10 |
| 159 |
%0:_(s8) = G_TRUNC %2(s64) |
| 160 |
%3:_(s64) = COPY $x11 |
| 161 |
%1:_(s8) = G_TRUNC %3(s64) |
| 162 |
%4:_(s8), %5:_(s1) = G_SSUBO %0, %1 |
| 163 |
%6:_(s64) = G_ANYEXT %4(s8) |
| 164 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 165 |
$x10 = COPY %6(s64) |
| 166 |
$x11 = COPY %7(s64) |
| 167 |
PseudoRET implicit $x10, implicit $x11 |
| 168 |
|
| 169 |
... |
| 170 |
--- |
| 171 |
name: ssubo_i16 |
| 172 |
body: | |
| 173 |
bb.1: |
| 174 |
liveins: $x10, $x11 |
| 175 |
|
| 176 |
; CHECK-LABEL: name: ssubo_i16 |
| 177 |
; CHECK: liveins: $x10, $x11 |
| 178 |
; CHECK-NEXT: {{ $}} |
| 179 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 180 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 181 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 48 |
| 182 |
; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s64) = G_SHL [[COPY]], [[C]](s64) |
| 183 |
; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s64) = G_ASHR [[SHL]], [[C]](s64) |
| 184 |
; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s64) = G_SHL [[COPY1]], [[C]](s64) |
| 185 |
; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s64) = G_ASHR [[SHL1]], [[C]](s64) |
| 186 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[ASHR]], [[ASHR1]] |
| 187 |
; CHECK-NEXT: [[SHL2:%[0-9]+]]:_(s64) = G_SHL [[SUB]], [[C]](s64) |
| 188 |
; CHECK-NEXT: [[ASHR2:%[0-9]+]]:_(s64) = G_ASHR [[SHL2]], [[C]](s64) |
| 189 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ne), [[SUB]](s64), [[ASHR2]] |
| 190 |
; CHECK-NEXT: $x10 = COPY [[SUB]](s64) |
| 191 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 192 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 193 |
%2:_(s64) = COPY $x10 |
| 194 |
%0:_(s16) = G_TRUNC %2(s64) |
| 195 |
%3:_(s64) = COPY $x11 |
| 196 |
%1:_(s16) = G_TRUNC %3(s64) |
| 197 |
%4:_(s16), %5:_(s1) = G_SSUBO %0, %1 |
| 198 |
%6:_(s64) = G_ANYEXT %4(s16) |
| 199 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 200 |
$x10 = COPY %6(s64) |
| 201 |
$x11 = COPY %7(s64) |
| 202 |
PseudoRET implicit $x10, implicit $x11 |
| 203 |
|
| 204 |
... |
| 205 |
--- |
| 206 |
name: ssubo_i32 |
| 207 |
body: | |
| 208 |
bb.1: |
| 209 |
liveins: $x10, $x11 |
| 210 |
|
| 211 |
; CHECK-LABEL: name: ssubo_i32 |
| 212 |
; CHECK: liveins: $x10, $x11 |
| 213 |
; CHECK-NEXT: {{ $}} |
| 214 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 215 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 216 |
; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY]], 32 |
| 217 |
; CHECK-NEXT: [[SEXT_INREG1:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY1]], 32 |
| 218 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[SEXT_INREG]], [[SEXT_INREG1]] |
| 219 |
; CHECK-NEXT: [[SEXT_INREG2:%[0-9]+]]:_(s64) = G_SEXT_INREG [[SUB]], 32 |
| 220 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ne), [[SUB]](s64), [[SEXT_INREG2]] |
| 221 |
; CHECK-NEXT: $x10 = COPY [[SUB]](s64) |
| 222 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 223 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 224 |
%2:_(s64) = COPY $x10 |
| 225 |
%0:_(s32) = G_TRUNC %2(s64) |
| 226 |
%3:_(s64) = COPY $x11 |
| 227 |
%1:_(s32) = G_TRUNC %3(s64) |
| 228 |
%4:_(s32), %5:_(s1) = G_SSUBO %0, %1 |
| 229 |
%6:_(s64) = G_ANYEXT %4(s32) |
| 230 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 231 |
$x10 = COPY %6(s64) |
| 232 |
$x11 = COPY %7(s64) |
| 233 |
PseudoRET implicit $x10, implicit $x11 |
| 234 |
|
| 235 |
... |
| 236 |
--- |
| 237 |
name: ssubo_i64 |
| 238 |
body: | |
| 239 |
bb.1: |
| 240 |
liveins: $x10, $x11 |
| 241 |
|
| 242 |
; CHECK-LABEL: name: ssubo_i64 |
| 243 |
; CHECK: liveins: $x10, $x11 |
| 244 |
; CHECK-NEXT: {{ $}} |
| 245 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 246 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 247 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[COPY]], [[COPY1]] |
| 248 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 0 |
| 249 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(slt), [[SUB]](s64), [[COPY]] |
| 250 |
; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s64) = G_ICMP intpred(sgt), [[COPY1]](s64), [[C]] |
| 251 |
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[ICMP1]], [[ICMP]] |
| 252 |
; CHECK-NEXT: [[COPY2:%[0-9]+]]:_(s64) = COPY [[SUB]](s64) |
| 253 |
; CHECK-NEXT: $x10 = COPY [[COPY2]](s64) |
| 254 |
; CHECK-NEXT: $x11 = COPY [[XOR]](s64) |
| 255 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 256 |
%0:_(s64) = COPY $x10 |
| 257 |
%1:_(s64) = COPY $x11 |
| 258 |
%2:_(s64), %3:_(s1) = G_SSUBO %0, %1 |
| 259 |
%4:_(s64) = G_ANYEXT %3(s1) |
| 260 |
$x10 = COPY %2(s64) |
| 261 |
$x11 = COPY %4(s64) |
| 262 |
PseudoRET implicit $x10, implicit $x11 |
| 263 |
|
| 264 |
... |
| 265 |
--- |
| 266 |
name: uaddo_i8 |
| 267 |
body: | |
| 268 |
bb.1: |
| 269 |
liveins: $x10, $x11 |
| 270 |
|
| 271 |
; CHECK-LABEL: name: uaddo_i8 |
| 272 |
; CHECK: liveins: $x10, $x11 |
| 273 |
; CHECK-NEXT: {{ $}} |
| 274 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 275 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 276 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[COPY]], [[COPY1]] |
| 277 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 255 |
| 278 |
; CHECK-NEXT: [[AND:%[0-9]+]]:_(s64) = G_AND [[ADD]], [[C]] |
| 279 |
; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s64) = G_AND [[COPY1]], [[C]] |
| 280 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[AND]](s64), [[AND1]] |
| 281 |
; CHECK-NEXT: $x10 = COPY [[ADD]](s64) |
| 282 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 283 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 284 |
%2:_(s64) = COPY $x10 |
| 285 |
%0:_(s8) = G_TRUNC %2(s64) |
| 286 |
%3:_(s64) = COPY $x11 |
| 287 |
%1:_(s8) = G_TRUNC %3(s64) |
| 288 |
%4:_(s8), %5:_(s1) = G_UADDO %0, %1 |
| 289 |
%6:_(s64) = G_ANYEXT %4(s8) |
| 290 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 291 |
$x10 = COPY %6(s64) |
| 292 |
$x11 = COPY %7(s64) |
| 293 |
PseudoRET implicit $x10, implicit $x11 |
| 294 |
|
| 295 |
... |
| 296 |
--- |
| 297 |
name: uaddo_i16 |
| 298 |
body: | |
| 299 |
bb.1: |
| 300 |
liveins: $x10, $x11 |
| 301 |
|
| 302 |
; CHECK-LABEL: name: uaddo_i16 |
| 303 |
; CHECK: liveins: $x10, $x11 |
| 304 |
; CHECK-NEXT: {{ $}} |
| 305 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 306 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 307 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[COPY]], [[COPY1]] |
| 308 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 65535 |
| 309 |
; CHECK-NEXT: [[AND:%[0-9]+]]:_(s64) = G_AND [[ADD]], [[C]] |
| 310 |
; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s64) = G_AND [[COPY1]], [[C]] |
| 311 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[AND]](s64), [[AND1]] |
| 312 |
; CHECK-NEXT: $x10 = COPY [[ADD]](s64) |
| 313 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 314 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 315 |
%2:_(s64) = COPY $x10 |
| 316 |
%0:_(s16) = G_TRUNC %2(s64) |
| 317 |
%3:_(s64) = COPY $x11 |
| 318 |
%1:_(s16) = G_TRUNC %3(s64) |
| 319 |
%4:_(s16), %5:_(s1) = G_UADDO %0, %1 |
| 320 |
%6:_(s64) = G_ANYEXT %4(s16) |
| 321 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 322 |
$x10 = COPY %6(s64) |
| 323 |
$x11 = COPY %7(s64) |
| 324 |
PseudoRET implicit $x10, implicit $x11 |
| 325 |
|
| 326 |
... |
| 327 |
--- |
| 328 |
name: uaddo_i32 |
| 329 |
body: | |
| 330 |
bb.1: |
| 331 |
liveins: $x10, $x11 |
| 332 |
|
| 333 |
; CHECK-LABEL: name: uaddo_i32 |
| 334 |
; CHECK: liveins: $x10, $x11 |
| 335 |
; CHECK-NEXT: {{ $}} |
| 336 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 337 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 338 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[COPY]], [[COPY1]] |
| 339 |
; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s64) = G_SEXT_INREG [[ADD]], 32 |
| 340 |
; CHECK-NEXT: [[SEXT_INREG1:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY1]], 32 |
| 341 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[SEXT_INREG]](s64), [[SEXT_INREG1]] |
| 342 |
; CHECK-NEXT: $x10 = COPY [[SEXT_INREG]](s64) |
| 343 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 344 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 345 |
%2:_(s64) = COPY $x10 |
| 346 |
%0:_(s32) = G_TRUNC %2(s64) |
| 347 |
%3:_(s64) = COPY $x11 |
| 348 |
%1:_(s32) = G_TRUNC %3(s64) |
| 349 |
%4:_(s32), %5:_(s1) = G_UADDO %0, %1 |
| 350 |
%6:_(s64) = G_ANYEXT %4(s32) |
| 351 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 352 |
$x10 = COPY %6(s64) |
| 353 |
$x11 = COPY %7(s64) |
| 354 |
PseudoRET implicit $x10, implicit $x11 |
| 355 |
|
| 356 |
... |
| 357 |
--- |
| 358 |
name: uaddo_i64 |
| 359 |
body: | |
| 360 |
bb.1: |
| 361 |
liveins: $x10, $x11 |
| 362 |
|
| 363 |
; CHECK-LABEL: name: uaddo_i64 |
| 364 |
; CHECK: liveins: $x10, $x11 |
| 365 |
; CHECK-NEXT: {{ $}} |
| 366 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 367 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 368 |
; CHECK-NEXT: [[ADD:%[0-9]+]]:_(s64) = G_ADD [[COPY]], [[COPY1]] |
| 369 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[ADD]](s64), [[COPY1]] |
| 370 |
; CHECK-NEXT: [[COPY2:%[0-9]+]]:_(s64) = COPY [[ADD]](s64) |
| 371 |
; CHECK-NEXT: $x10 = COPY [[COPY2]](s64) |
| 372 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 373 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 374 |
%0:_(s64) = COPY $x10 |
| 375 |
%1:_(s64) = COPY $x11 |
| 376 |
%2:_(s64), %3:_(s1) = G_UADDO %0, %1 |
| 377 |
%4:_(s64) = G_ANYEXT %3(s1) |
| 378 |
$x10 = COPY %2(s64) |
| 379 |
$x11 = COPY %4(s64) |
| 380 |
PseudoRET implicit $x10, implicit $x11 |
| 381 |
|
| 382 |
... |
| 383 |
--- |
| 384 |
name: usubo_i8 |
| 385 |
body: | |
| 386 |
bb.1: |
| 387 |
liveins: $x10, $x11 |
| 388 |
|
| 389 |
; CHECK-LABEL: name: usubo_i8 |
| 390 |
; CHECK: liveins: $x10, $x11 |
| 391 |
; CHECK-NEXT: {{ $}} |
| 392 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 393 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 394 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[COPY]], [[COPY1]] |
| 395 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 255 |
| 396 |
; CHECK-NEXT: [[AND:%[0-9]+]]:_(s64) = G_AND [[COPY]], [[C]] |
| 397 |
; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s64) = G_AND [[COPY1]], [[C]] |
| 398 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[AND]](s64), [[AND1]] |
| 399 |
; CHECK-NEXT: $x10 = COPY [[SUB]](s64) |
| 400 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 401 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 402 |
%2:_(s64) = COPY $x10 |
| 403 |
%0:_(s8) = G_TRUNC %2(s64) |
| 404 |
%3:_(s64) = COPY $x11 |
| 405 |
%1:_(s8) = G_TRUNC %3(s64) |
| 406 |
%4:_(s8), %5:_(s1) = G_USUBO %0, %1 |
| 407 |
%6:_(s64) = G_ANYEXT %4(s8) |
| 408 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 409 |
$x10 = COPY %6(s64) |
| 410 |
$x11 = COPY %7(s64) |
| 411 |
PseudoRET implicit $x10, implicit $x11 |
| 412 |
|
| 413 |
... |
| 414 |
--- |
| 415 |
name: usubo_i16 |
| 416 |
body: | |
| 417 |
bb.1: |
| 418 |
liveins: $x10, $x11 |
| 419 |
|
| 420 |
; CHECK-LABEL: name: usubo_i16 |
| 421 |
; CHECK: liveins: $x10, $x11 |
| 422 |
; CHECK-NEXT: {{ $}} |
| 423 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 424 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 425 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[COPY]], [[COPY1]] |
| 426 |
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 65535 |
| 427 |
; CHECK-NEXT: [[AND:%[0-9]+]]:_(s64) = G_AND [[COPY]], [[C]] |
| 428 |
; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s64) = G_AND [[COPY1]], [[C]] |
| 429 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[AND]](s64), [[AND1]] |
| 430 |
; CHECK-NEXT: $x10 = COPY [[SUB]](s64) |
| 431 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 432 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 433 |
%2:_(s64) = COPY $x10 |
| 434 |
%0:_(s16) = G_TRUNC %2(s64) |
| 435 |
%3:_(s64) = COPY $x11 |
| 436 |
%1:_(s16) = G_TRUNC %3(s64) |
| 437 |
%4:_(s16), %5:_(s1) = G_USUBO %0, %1 |
| 438 |
%6:_(s64) = G_ANYEXT %4(s16) |
| 439 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 440 |
$x10 = COPY %6(s64) |
| 441 |
$x11 = COPY %7(s64) |
| 442 |
PseudoRET implicit $x10, implicit $x11 |
| 443 |
|
| 444 |
... |
| 445 |
--- |
| 446 |
name: usubo_i32 |
| 447 |
body: | |
| 448 |
bb.1: |
| 449 |
liveins: $x10, $x11 |
| 450 |
|
| 451 |
; CHECK-LABEL: name: usubo_i32 |
| 452 |
; CHECK: liveins: $x10, $x11 |
| 453 |
; CHECK-NEXT: {{ $}} |
| 454 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 455 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 456 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[COPY]], [[COPY1]] |
| 457 |
; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s64) = G_SEXT_INREG [[SUB]], 32 |
| 458 |
; CHECK-NEXT: [[SEXT_INREG1:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY]], 32 |
| 459 |
; CHECK-NEXT: [[SEXT_INREG2:%[0-9]+]]:_(s64) = G_SEXT_INREG [[COPY1]], 32 |
| 460 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[SEXT_INREG1]](s64), [[SEXT_INREG2]] |
| 461 |
; CHECK-NEXT: $x10 = COPY [[SEXT_INREG]](s64) |
| 462 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 463 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 464 |
%2:_(s64) = COPY $x10 |
| 465 |
%0:_(s32) = G_TRUNC %2(s64) |
| 466 |
%3:_(s64) = COPY $x11 |
| 467 |
%1:_(s32) = G_TRUNC %3(s64) |
| 468 |
%4:_(s32), %5:_(s1) = G_USUBO %0, %1 |
| 469 |
%6:_(s64) = G_ANYEXT %4(s32) |
| 470 |
%7:_(s64) = G_ANYEXT %5(s1) |
| 471 |
$x10 = COPY %6(s64) |
| 472 |
$x11 = COPY %7(s64) |
| 473 |
PseudoRET implicit $x10, implicit $x11 |
| 474 |
|
| 475 |
... |
| 476 |
--- |
| 477 |
name: usubo_i64 |
| 478 |
body: | |
| 479 |
bb.1: |
| 480 |
liveins: $x10, $x11 |
| 481 |
|
| 482 |
; CHECK-LABEL: name: usubo_i64 |
| 483 |
; CHECK: liveins: $x10, $x11 |
| 484 |
; CHECK-NEXT: {{ $}} |
| 485 |
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(s64) = COPY $x10 |
| 486 |
; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $x11 |
| 487 |
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB [[COPY]], [[COPY1]] |
| 488 |
; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s64) = G_ICMP intpred(ult), [[COPY]](s64), [[COPY1]] |
| 489 |
; CHECK-NEXT: $x10 = COPY [[SUB]](s64) |
| 490 |
; CHECK-NEXT: $x11 = COPY [[ICMP]](s64) |
| 491 |
; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11 |
| 492 |
%0:_(s64) = COPY $x10 |
| 493 |
%1:_(s64) = COPY $x11 |
| 494 |
%2:_(s64), %3:_(s1) = G_USUBO %0, %1 |
| 495 |
%4:_(s64) = G_ANYEXT %3(s1) |
| 496 |
$x10 = COPY %2(s64) |
| 497 |
$x11 = COPY %4(s64) |
| 498 |
PseudoRET implicit $x10, implicit $x11 |
| 499 |
|
| 500 |
... |