# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py # RUN: llc -mtriple=riscv64 -mattr=+zbb -run-pass=instruction-select \ # RUN: -simplify-mir -verify-machineinstrs %s -o - \ # RUN: | FileCheck -check-prefix=RV64I %s --- name: smax_i64 legalized: true regBankSelected: true body: | bb.0.entry: ; RV64I-LABEL: name: smax_i64 ; RV64I: [[COPY:%[0-9]+]]:gpr = COPY $x10 ; RV64I-NEXT: [[COPY1:%[0-9]+]]:gpr = COPY $x11 ; RV64I-NEXT: [[MAX:%[0-9]+]]:gpr = MAX [[COPY]], [[COPY1]] ; RV64I-NEXT: $x10 = COPY [[MAX]] ; RV64I-NEXT: PseudoRET implicit $x10 %0:gprb(s64) = COPY $x10 %1:gprb(s64) = COPY $x11 %2:gprb(s64) = G_SMAX %0, %1 $x10 = COPY %2(s64) PseudoRET implicit $x10 ... --- name: smin_i64 legalized: true regBankSelected: true body: | bb.0.entry: ; RV64I-LABEL: name: smin_i64 ; RV64I: [[COPY:%[0-9]+]]:gpr = COPY $x10 ; RV64I-NEXT: [[COPY1:%[0-9]+]]:gpr = COPY $x11 ; RV64I-NEXT: [[MIN:%[0-9]+]]:gpr = MIN [[COPY]], [[COPY1]] ; RV64I-NEXT: $x10 = COPY [[MIN]] ; RV64I-NEXT: PseudoRET implicit $x10 %0:gprb(s64) = COPY $x10 %1:gprb(s64) = COPY $x11 %2:gprb(s64) = G_SMIN %0, %1 $x10 = COPY %2(s64) PseudoRET implicit $x10 ... --- name: umax_i64 legalized: true regBankSelected: true body: | bb.0.entry: ; RV64I-LABEL: name: umax_i64 ; RV64I: [[COPY:%[0-9]+]]:gpr = COPY $x10 ; RV64I-NEXT: [[COPY1:%[0-9]+]]:gpr = COPY $x11 ; RV64I-NEXT: [[MAXU:%[0-9]+]]:gpr = MAXU [[COPY]], [[COPY1]] ; RV64I-NEXT: $x10 = COPY [[MAXU]] ; RV64I-NEXT: PseudoRET implicit $x10 %0:gprb(s64) = COPY $x10 %1:gprb(s64) = COPY $x11 %2:gprb(s64) = G_UMAX %0, %1 $x10 = COPY %2(s64) PseudoRET implicit $x10 ... --- name: umin_i64 legalized: true regBankSelected: true body: | bb.0.entry: ; RV64I-LABEL: name: umin_i64 ; RV64I: [[COPY:%[0-9]+]]:gpr = COPY $x10 ; RV64I-NEXT: [[COPY1:%[0-9]+]]:gpr = COPY $x11 ; RV64I-NEXT: [[MINU:%[0-9]+]]:gpr = MINU [[COPY]], [[COPY1]] ; RV64I-NEXT: $x10 = COPY [[MINU]] ; RV64I-NEXT: PseudoRET implicit $x10 %0:gprb(s64) = COPY $x10 %1:gprb(s64) = COPY $x11 %2:gprb(s64) = G_UMIN %0, %1 $x10 = COPY %2(s64) PseudoRET implicit $x10 ...