1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -triple x86_64-apple-darwin %s -emit-llvm -o - | FileCheck %s 2*f4a2713aSLionel Sambuc // llvm.sqrt has undefined behavior on negative inputs, so it is 3*f4a2713aSLionel Sambuc // inappropriate to translate C/C++ sqrt to this. 4*f4a2713aSLionel Sambuc float sqrtf(float x); foo(float X)5*f4a2713aSLionel Sambucfloat foo(float X) { 6*f4a2713aSLionel Sambuc // CHECK: foo 7*f4a2713aSLionel Sambuc // CHECK: call float @sqrtf(float % 8*f4a2713aSLionel Sambuc // Check that this is marked readonly when errno is ignored. 9*f4a2713aSLionel Sambuc return sqrtf(X); 10*f4a2713aSLionel Sambuc } 11