1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=riscv32 -mattr=+d,zfh -run-pass=regbankselect \
3 # RUN: -simplify-mir -verify-machineinstrs %s \
4 # RUN: -o - | FileCheck %s
5 # RUN: llc -mtriple=riscv64 -mattr=+d,zfh -run-pass=regbankselect \
6 # RUN: -simplify-mir -verify-machineinstrs %s \
7 # RUN: -o - | FileCheck %s
12 tracksRegLiveness: true
17 ; CHECK-LABEL: name: fpext_f32
18 ; CHECK: liveins: $f10_h
20 ; CHECK-NEXT: [[COPY:%[0-9]+]]:fprb(s16) = COPY $f10_h
21 ; CHECK-NEXT: [[FPEXT:%[0-9]+]]:fprb(s32) = G_FPEXT [[COPY]](s16)
22 ; CHECK-NEXT: $f10_f = COPY [[FPEXT]](s32)
23 ; CHECK-NEXT: PseudoRET implicit $f10_f
24 %0:_(s16) = COPY $f10_h
25 %1:_(s32) = G_FPEXT %0(s16)
27 PseudoRET implicit $f10_f
33 tracksRegLiveness: true
38 ; CHECK-LABEL: name: fptrunc_f32
39 ; CHECK: liveins: $f10_f
41 ; CHECK-NEXT: [[COPY:%[0-9]+]]:fprb(s32) = COPY $f10_f
42 ; CHECK-NEXT: [[FPTRUNC:%[0-9]+]]:fprb(s16) = G_FPTRUNC [[COPY]](s32)
43 ; CHECK-NEXT: $f10_h = COPY [[FPTRUNC]](s16)
44 ; CHECK-NEXT: PseudoRET implicit $f10_h
45 %0:_(s32) = COPY $f10_f
46 %1:_(s16) = G_FPTRUNC %0(s32)
48 PseudoRET implicit $f10_h
54 tracksRegLiveness: true
59 ; CHECK-LABEL: name: fpext_f64
60 ; CHECK: liveins: $f10_h
62 ; CHECK-NEXT: [[COPY:%[0-9]+]]:fprb(s16) = COPY $f10_h
63 ; CHECK-NEXT: [[FPEXT:%[0-9]+]]:fprb(s64) = G_FPEXT [[COPY]](s16)
64 ; CHECK-NEXT: $f10_d = COPY [[FPEXT]](s64)
65 ; CHECK-NEXT: PseudoRET implicit $f10_d
66 %0:_(s16) = COPY $f10_h
67 %1:_(s64) = G_FPEXT %0(s16)
69 PseudoRET implicit $f10_d
75 tracksRegLiveness: true
80 ; CHECK-LABEL: name: fptrunc_f64
81 ; CHECK: liveins: $f10_d
83 ; CHECK-NEXT: [[COPY:%[0-9]+]]:fprb(s64) = COPY $f10_d
84 ; CHECK-NEXT: [[FPTRUNC:%[0-9]+]]:fprb(s16) = G_FPTRUNC [[COPY]](s64)
85 ; CHECK-NEXT: $f10_h = COPY [[FPTRUNC]](s16)
86 ; CHECK-NEXT: PseudoRET implicit $f10_h
87 %0:_(s64) = COPY $f10_d
88 %1:_(s16) = G_FPTRUNC %0(s64)
90 PseudoRET implicit $f10_h