[llvm-commits] Patch for pr12559: mark missing math LibCalls as unavailable on win32; fix SimplifyLibCalls to use TLI for floor etc.

Anton Korobeynikov anton at korobeynikov.info
Sat Apr 14 16:22:39 PDT 2012


> Hi everyone. Attached is a patch that fixes PR12559 on Windows. The
> Win32 CRT does not provide real entry points for single-precision math
> functions such as sqrtf, but instead implements them as macros in
> math.h. This patch marks sqrtf etc. as unavailable (along with the C99
> math functions not provided on Windows) to prevent libcall
> optimizations from attempting to use them for Win32 targets. I also
> updated some crufty-looking #ifdefs in SimplifyLibCalls into
> TargetLibraryInfo checks and fixed some typos. Let me know if you
> recommend any additional changes. Thanks.
LGTM

-- 
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University



More information about the llvm-commits mailing list