[PATCH] Make the sqrt intrinsic return undef for a negative input.

hfinkel at anl.gov hfinkel at anl.gov
Mon Sep 29 11:40:33 PDT 2014


Comment at: lib/Analysis/ConstantFolding.cpp:1527
@@ +1526,3 @@
+            // negative number is not defined for the LLVM sqrt intrinsic.
+            // This is because the intrinsic should only be generated when using
+            // "no-nans-fp-math".
I'd say, "... should only be emitted in place of a call to libm's sqrt function when using..."


More information about the llvm-commits mailing list