1; RUN: opt < %s -inline -instcombine -S | FileCheck %s 2 3; PR22857: http://llvm.org/bugs/show_bug.cgi?id=22857 4; The inliner should not add an edge to an intrinsic and 5; then assert that it did not add an edge to an intrinsic! 6 7define float @foo(float %f1) #0 { 8 %call = call float @bar(float %f1) 9 ret float %call 10 11; CHECK-LABEL: @foo( 12; CHECK-NEXT: call fast float @llvm.fabs.f32 13; CHECK-NEXT: ret float 14} 15 16define float @bar(float %f1) #0 { 17 %call = call float @sqr(float %f1) 18 %call1 = call float @sqrtf(float %call) #0 19 ret float %call1 20} 21 22define float @sqr(float %f) #0 { 23 %mul = fmul fast float %f, %f 24 ret float %mul 25} 26 27declare float @sqrtf(float) #0 28 29attributes #0 = { "unsafe-fp-math"="true" } 30 31