# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py # RUN: llc -mtriple=riscv32 -run-pass=legalizer %s -o - \ # RUN: | FileCheck %s --- name: cmp_sgt_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sgt_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sgt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sgt), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sgt_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sgt_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sgt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sgt), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sgt_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sgt_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sgt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sgt), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sgt_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sgt_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sgt), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(sgt), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_sgt_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sgt_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL %xlo, [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL %ylo, [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sgt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(sgt), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_sgt_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sgt_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sgt), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(sgt), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_slt_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_slt_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(slt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(slt), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_slt_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_slt_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(slt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(slt), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_slt_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_slt_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(slt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(slt), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_slt_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_slt_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(slt), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(slt), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_slt_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_slt_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL %xlo, [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL %ylo, [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(slt), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(slt), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_slt_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_slt_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(slt), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(slt), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_sge_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sge_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sge), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sge_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sge_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sge), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sge_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sge_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sge), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sge_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sge_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(sge), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_sge_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sge_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL %xlo, [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL %ylo, [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(sge), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_sge_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sge_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(sge), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_sle_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sle_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 25 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sle), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sle), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sle_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sle_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 24 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sle), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sle), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sle_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sle_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[COPY]], [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[COPY1]], [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sle), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(sle), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_sle_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sle_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sle), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(sle), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_sle_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sle_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL:%[0-9]+]]:_(s32) = G_SHL %xlo, [[C]](s32) ; CHECK-NEXT: [[ASHR:%[0-9]+]]:_(s32) = G_ASHR [[SHL]], [[C]](s32) ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 16 ; CHECK-NEXT: [[SHL1:%[0-9]+]]:_(s32) = G_SHL %ylo, [[C1]](s32) ; CHECK-NEXT: [[ASHR1:%[0-9]+]]:_(s32) = G_ASHR [[SHL1]], [[C1]](s32) ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sle), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[ASHR]](s32), [[ASHR1]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(sle), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_sle_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_sle_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sle), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(sle), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ugt_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ugt_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ugt), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ugt_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ugt_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ugt), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ugt_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ugt_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ugt), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ugt_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ugt_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(ugt), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_ugt_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ugt_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND %xhi, [[C]] ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND %xlo, [[C1]] ; CHECK-NEXT: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C3:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND2:%[0-9]+]]:_(s32) = G_AND %yhi, [[C2]] ; CHECK-NEXT: [[AND3:%[0-9]+]]:_(s32) = G_AND %ylo, [[C3]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), [[AND]](s32), [[AND2]] ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(ugt), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ugt_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ugt_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ugt), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(ugt), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ult_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ult_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ult), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ult_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ult_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ult), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ult_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ult_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ult), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ult_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ult_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(ult), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_ult_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ult_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND %xhi, [[C]] ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND %xlo, [[C1]] ; CHECK-NEXT: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C3:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND2:%[0-9]+]]:_(s32) = G_AND %yhi, [[C2]] ; CHECK-NEXT: [[AND3:%[0-9]+]]:_(s32) = G_AND %ylo, [[C3]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ult), [[AND]](s32), [[AND2]] ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(ult), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ult_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ult_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(sge), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(sge), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_uge_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_uge_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(uge), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_uge_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_uge_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(uge), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_uge_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_uge_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(uge), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_uge_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_uge_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(uge), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_uge_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_uge_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND %xhi, [[C]] ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND %xlo, [[C1]] ; CHECK-NEXT: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C3:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND2:%[0-9]+]]:_(s32) = G_AND %yhi, [[C2]] ; CHECK-NEXT: [[AND3:%[0-9]+]]:_(s32) = G_AND %ylo, [[C3]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), [[AND]](s32), [[AND2]] ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(uge), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_uge_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_uge_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(uge), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(uge), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ule_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ule_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ule), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ule_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ule_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ule), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ule_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ule_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ule), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ule_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ule_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(ule), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_ule_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ule_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND %xhi, [[C]] ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND %xlo, [[C1]] ; CHECK-NEXT: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C3:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND2:%[0-9]+]]:_(s32) = G_AND %yhi, [[C2]] ; CHECK-NEXT: [[AND3:%[0-9]+]]:_(s32) = G_AND %ylo, [[C3]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND1]](s32), [[AND3]] ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), [[AND]](s32), [[AND2]] ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(ule), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ule_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ule_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), %xlo(s32), %ylo ; CHECK-NEXT: [[ICMP2:%[0-9]+]]:_(s32) = G_ICMP intpred(ule), %xhi(s32), %yhi ; CHECK-NEXT: [[SELECT:%[0-9]+]]:_(s32) = G_SELECT [[ICMP1]](s32), [[ICMP2]], [[ICMP]] ; CHECK-NEXT: $x10 = COPY [[SELECT]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(ule), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(eq), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(eq), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(eq), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(eq), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND %xhi, [[C]] ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND %xlo, [[C1]] ; CHECK-NEXT: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C3:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND2:%[0-9]+]]:_(s32) = G_AND %yhi, [[C2]] ; CHECK-NEXT: [[AND3:%[0-9]+]]:_(s32) = G_AND %ylo, [[C3]] ; CHECK-NEXT: [[C4:%[0-9]+]]:_(s32) = G_CONSTANT i32 0 ; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s32) = G_XOR [[AND]], [[AND2]] ; CHECK-NEXT: [[XOR1:%[0-9]+]]:_(s32) = G_XOR [[AND1]], [[AND3]] ; CHECK-NEXT: [[OR:%[0-9]+]]:_(s32) = G_OR [[XOR]], [[XOR1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[OR]](s32), [[C4]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(eq), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 0 ; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s32) = G_XOR %xhi, %yhi ; CHECK-NEXT: [[XOR1:%[0-9]+]]:_(s32) = G_XOR %xlo, %ylo ; CHECK-NEXT: [[OR:%[0-9]+]]:_(s32) = G_OR [[XOR]], [[XOR1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[OR]](s32), [[C]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(eq), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ne_i7 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ne_i7 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 127 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ne), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s7) = G_TRUNC %0(s32) %3:_(s7) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ne), %2(s7), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ne_i8 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ne_i8 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 255 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ne), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s8) = G_TRUNC %0(s32) %3:_(s8) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ne), %2(s8), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ne_i16 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ne_i16 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY]], [[C]] ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND [[COPY1]], [[C1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ne), [[AND]](s32), [[AND1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s16) = G_TRUNC %0(s32) %3:_(s16) = G_TRUNC %1(s32) %4:_(s1) = G_ICMP intpred(ne), %2(s16), %3 %5:_(s32) = G_ANYEXT %4(s1) $x10 = COPY %5(s32) PseudoRET implicit $x10 ... --- name: cmp_ne_i32 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ne_i32 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ne), [[COPY]](s32), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(s32) = COPY $x10 %1:_(s32) = COPY $x11 %2:_(s1) = G_ICMP intpred(ne), %0(s32), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ... --- name: cmp_ne_i48 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ne_i48 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND:%[0-9]+]]:_(s32) = G_AND %xhi, [[C]] ; CHECK-NEXT: [[AND1:%[0-9]+]]:_(s32) = G_AND %xlo, [[C1]] ; CHECK-NEXT: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 -1 ; CHECK-NEXT: [[C3:%[0-9]+]]:_(s32) = G_CONSTANT i32 65535 ; CHECK-NEXT: [[AND2:%[0-9]+]]:_(s32) = G_AND %yhi, [[C2]] ; CHECK-NEXT: [[AND3:%[0-9]+]]:_(s32) = G_AND %ylo, [[C3]] ; CHECK-NEXT: [[C4:%[0-9]+]]:_(s32) = G_CONSTANT i32 0 ; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s32) = G_XOR [[AND]], [[AND2]] ; CHECK-NEXT: [[XOR1:%[0-9]+]]:_(s32) = G_XOR [[AND1]], [[AND3]] ; CHECK-NEXT: [[OR:%[0-9]+]]:_(s32) = G_OR [[XOR]], [[XOR1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ne), [[OR]](s32), [[C4]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x0:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y0:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %x:_(s48) = G_TRUNC %x0(s64) %y:_(s48) = G_TRUNC %y0(s64) %z:_(s1) = G_ICMP intpred(ne), %x(s48), %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_ne_i64 body: | bb.0.entry: ; CHECK-LABEL: name: cmp_ne_i64 ; CHECK: %xhi:_(s32) = COPY $x10 ; CHECK-NEXT: %xlo:_(s32) = COPY $x11 ; CHECK-NEXT: %yhi:_(s32) = COPY $x12 ; CHECK-NEXT: %ylo:_(s32) = COPY $x13 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 0 ; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s32) = G_XOR %xhi, %yhi ; CHECK-NEXT: [[XOR1:%[0-9]+]]:_(s32) = G_XOR %xlo, %ylo ; CHECK-NEXT: [[OR:%[0-9]+]]:_(s32) = G_OR [[XOR]], [[XOR1]] ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(ne), [[OR]](s32), [[C]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %xhi:_(s32) = COPY $x10 %xlo:_(s32) = COPY $x11 %yhi:_(s32) = COPY $x12 %ylo:_(s32) = COPY $x13 %x:_(s64) = G_MERGE_VALUES %xhi(s32), %xlo(s32) %y:_(s64) = G_MERGE_VALUES %yhi(s32), %ylo(s32) %z:_(s1) = G_ICMP intpred(ne), %x, %y %z0:_(s32) = G_ANYEXT %z(s1) $x10 = COPY %z0(s32) PseudoRET implicit $x10 ... --- name: cmp_eq_ptr body: | bb.0.entry: ; CHECK-LABEL: name: cmp_eq_ptr ; CHECK: [[COPY:%[0-9]+]]:_(p0) = COPY $x10 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(p0) = COPY $x11 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:_(s32) = G_ICMP intpred(eq), [[COPY]](p0), [[COPY1]] ; CHECK-NEXT: $x10 = COPY [[ICMP]](s32) ; CHECK-NEXT: PseudoRET implicit $x10 %0:_(p0) = COPY $x10 %1:_(p0) = COPY $x11 %2:_(s1) = G_ICMP intpred(eq), %0(p0), %1 %3:_(s32) = G_ANYEXT %2(s1) $x10 = COPY %3(s32) PseudoRET implicit $x10 ...