brintos

brintos / llvm-project-archived public Read only

0
0
Text · 583 B · 27dae58 Raw
19 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py2; Test that the pow library call simplifier works correctly.3;4; RUN: opt < %s -passes=instcombine -S | FileCheck %s5 6declare float @pow(double, double)7 8; Check that pow functions with the wrong prototype aren't simplified.9 10define float @test_no_simplify1(double %x) {11; CHECK-LABEL: @test_no_simplify1(12; CHECK-NEXT:    [[RETVAL:%.*]] = call float @pow(double 1.000000e+00, double [[X:%.*]])13; CHECK-NEXT:    ret float [[RETVAL]]14;15  %retval = call float @pow(double 1.0, double %x)16  ret float %retval17}18 19