; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py ; RUN: llc -mtriple=riscv64 -mattr=+d,+experimental-v,+experimental-zfh -target-abi lp64d -verify-machineinstrs < %s | FileCheck %s ; RUN: llc -mtriple=riscv32 -mattr=+d,+experimental-v,+experimental-zfh -target-abi ilp32d -verify-machineinstrs < %s | FileCheck %s declare half @llvm.riscv.vfmv.f.s.nxv1f16() define half @intrinsic_vfmv.f.s_s_nxv1f16( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv1f16: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e16,mf4,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call half @llvm.riscv.vfmv.f.s.nxv1f16( %0) ret half %a } declare half @llvm.riscv.vfmv.f.s.nxv2f16() define half @intrinsic_vfmv.f.s_s_nxv2f16( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv2f16: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e16,mf2,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call half @llvm.riscv.vfmv.f.s.nxv2f16( %0) ret half %a } declare half @llvm.riscv.vfmv.f.s.nxv4f16() define half @intrinsic_vfmv.f.s_s_nxv4f16( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv4f16: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e16,m1,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call half @llvm.riscv.vfmv.f.s.nxv4f16( %0) ret half %a } declare half @llvm.riscv.vfmv.f.s.nxv8f16() define half @intrinsic_vfmv.f.s_s_nxv8f16( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv8f16: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e16,m2,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call half @llvm.riscv.vfmv.f.s.nxv8f16( %0) ret half %a } declare half @llvm.riscv.vfmv.f.s.nxv16f16() define half @intrinsic_vfmv.f.s_s_nxv16f16( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv16f16: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e16,m4,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call half @llvm.riscv.vfmv.f.s.nxv16f16( %0) ret half %a } declare half @llvm.riscv.vfmv.f.s.nxv32f16() define half @intrinsic_vfmv.f.s_s_nxv32f16( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv32f16: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e16,m8,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call half @llvm.riscv.vfmv.f.s.nxv32f16( %0) ret half %a } declare float @llvm.riscv.vfmv.f.s.nxv1f32() define float @intrinsic_vfmv.f.s_s_nxv1f32( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv1f32: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e32,mf2,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call float @llvm.riscv.vfmv.f.s.nxv1f32( %0) ret float %a } declare float @llvm.riscv.vfmv.f.s.nxv2f32() define float @intrinsic_vfmv.f.s_s_nxv2f32( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv2f32: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e32,m1,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call float @llvm.riscv.vfmv.f.s.nxv2f32( %0) ret float %a } declare float @llvm.riscv.vfmv.f.s.nxv4f32() define float @intrinsic_vfmv.f.s_s_nxv4f32( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv4f32: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e32,m2,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call float @llvm.riscv.vfmv.f.s.nxv4f32( %0) ret float %a } declare float @llvm.riscv.vfmv.f.s.nxv8f32() define float @intrinsic_vfmv.f.s_s_nxv8f32( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv8f32: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e32,m4,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call float @llvm.riscv.vfmv.f.s.nxv8f32( %0) ret float %a } declare float @llvm.riscv.vfmv.f.s.nxv16f32() define float @intrinsic_vfmv.f.s_s_nxv16f32( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv16f32: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e32,m8,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call float @llvm.riscv.vfmv.f.s.nxv16f32( %0) ret float %a } declare double @llvm.riscv.vfmv.f.s.nxv1f64() define double @intrinsic_vfmv.f.s_s_nxv1f64( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv1f64: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e64,m1,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call double @llvm.riscv.vfmv.f.s.nxv1f64( %0) ret double %a } declare double @llvm.riscv.vfmv.f.s.nxv2f64() define double @intrinsic_vfmv.f.s_s_nxv2f64( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv2f64: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e64,m2,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call double @llvm.riscv.vfmv.f.s.nxv2f64( %0) ret double %a } declare double @llvm.riscv.vfmv.f.s.nxv4f64() define double @intrinsic_vfmv.f.s_s_nxv4f64( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv4f64: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e64,m4,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call double @llvm.riscv.vfmv.f.s.nxv4f64( %0) ret double %a } declare double @llvm.riscv.vfmv.f.s.nxv8f64() define double @intrinsic_vfmv.f.s_s_nxv8f64( %0) nounwind { ; CHECK-LABEL: intrinsic_vfmv.f.s_s_nxv8f64: ; CHECK: # %bb.0: # %entry ; CHECK-NEXT: vsetvli zero, zero, e64,m8,ta,mu ; CHECK-NEXT: vfmv.f.s fa0, v8 ; CHECK-NEXT: ret entry: %a = call double @llvm.riscv.vfmv.f.s.nxv8f64( %0) ret double %a }