blob: d1ffde703faa75074459a0cf090b898efc3309fb [file] [log] [blame]
Meador Inge193e0352012-11-13 04:16:17 +00001; Test that the pow library call simplifier works correctly.
2;
3; RUN: opt < %s -instcombine -S | FileCheck %s
4
5declare float @pow(double, double)
6
7; Check that pow functions with the wrong prototype aren't simplified.
8
9define float @test_no_simplify1(double %x) {
Stephen Linc1c7a132013-07-14 01:42:54 +000010; CHECK-LABEL: @test_no_simplify1(
Meador Inge193e0352012-11-13 04:16:17 +000011 %retval = call float @pow(double 1.0, double %x)
12; CHECK-NEXT: call float @pow(double 1.000000e+00, double %x)
13 ret float %retval
14}