1 ; Test strict conversions of signed i32s to floating-point values.
3 ; RUN: llc < %s -mtriple=s390x-linux-gnu | FileCheck %s
5 declare float @llvm.experimental.constrained.sitofp.f32.i32(i32, metadata, metadata)
6 declare double @llvm.experimental.constrained.sitofp.f64.i32(i32, metadata, metadata)
7 declare fp128 @llvm.experimental.constrained.sitofp.f128.i32(i32, metadata, metadata)
10 define float @f1(i32 %i) #0 {
12 ; CHECK: cefbr %f0, %r2
14 %conv = call float @llvm.experimental.constrained.sitofp.f32.i32(i32 %i,
15 metadata !"round.dynamic",
16 metadata !"fpexcept.strict") #0
21 define double @f2(i32 %i) #0 {
23 ; CHECK: cdfbr %f0, %r2
25 %conv = call double @llvm.experimental.constrained.sitofp.f64.i32(i32 %i,
26 metadata !"round.dynamic",
27 metadata !"fpexcept.strict") #0
32 define void @f3(i32 %i, ptr %dst) #0 {
34 ; CHECK: cxfbr %f0, %r2
35 ; CHECK: std %f0, 0(%r3)
36 ; CHECK: std %f2, 8(%r3)
38 %conv = call fp128 @llvm.experimental.constrained.sitofp.f128.i32(i32 %i,
39 metadata !"round.dynamic",
40 metadata !"fpexcept.strict") #0
41 store fp128 %conv, ptr %dst
45 attributes #0 = { strictfp }