efriedma added a comment.

Currently, the clang driver supports three platforms which have errno-setting 
libc implementations: GNU/Linux (with glibc), Solaris, and Windows (with Visual 
Studio CRT).  (BSD-based systems, including OS X, never set errno in libm, so 
they aren't relevant here.)  As long as our markings are consistent with those 
targets, we should be fine.

Both MSVC and GNU libraries never set errno for cbrt() and fma(); we want to 
keep those assumptions in clang.

We can ignore Visual Studio for the discussion of complex.h, I guess, because 
MSVC doesn't support _Complex.  (It has a header called complex.h, but the 
types aren't right, so clang won't recognize any of the functions.  For 
reference, though, its cabs() and catanh() set errno).

I have no idea how Solaris and other Unix targets handle these functions; it's 
probably a bad idea to add special cases for them without testing.


https://reviews.llvm.org/D39611



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to