llvm-6502/include/llvm/Transforms/Utils
Sanjay Patel dc18ebc4b1 Shrinkify libcalls: use float versions of double libm functions with fast-math (bug 17850)
When a call to a double-precision libm function has fast-math semantics 
(via function attribute for now because there is no IR-level FMF on calls), 
we can avoid fpext/fptrunc operations and use the float version of the call
if the input and output are both float.

We already do this optimization using a command-line option; this patch just
adds the ability for fast-math to use the existing functionality.

I moved the cl::opt from InstructionCombining into SimplifyLibCalls because
it's only ever used internally to that class.

Modified the existing test cases to use the unsafe-fp-math attribute rather
than repeating all tests.

This patch should solve: http://llvm.org/bugs/show_bug.cgi?id=17850

Differential Revision: http://reviews.llvm.org/D5893



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220390 91177308-0d34-0410-b5e6-96231b3b80d8
2014-10-22 15:29:23 +00:00
..
ASanStackFrameLayout.h
BasicBlockUtils.h
BuildLibCalls.h
BypassSlowDivision.h
Cloning.h Add an Assumption-Tracking Pass 2014-09-07 12:44:26 +00:00
CmpInstAnalysis.h
CodeExtractor.h
CtorUtils.h
GlobalStatus.h
IntegerDivision.h
Local.h [SimplifyCFG] threshold for folding branches with common destination 2014-09-30 22:23:38 +00:00
LoopUtils.h Make use of @llvm.assume in ValueTracking (computeKnownBits, etc.) 2014-09-07 18:57:58 +00:00
ModuleUtils.h Repace SmallPtrSet with SmallPtrSetImpl in function arguments to avoid needing to mention the size. 2014-08-21 05:55:13 +00:00
PromoteMemToReg.h Make use of @llvm.assume in ValueTracking (computeKnownBits, etc.) 2014-09-07 18:57:58 +00:00
SimplifyIndVar.h
SimplifyLibCalls.h Shrinkify libcalls: use float versions of double libm functions with fast-math (bug 17850) 2014-10-22 15:29:23 +00:00
SSAUpdater.h Reformat blank lines. 2014-05-19 04:43:26 +00:00
SSAUpdaterImpl.h
UnifyFunctionExitNodes.h
UnrollLoop.h Add an Assumption-Tracking Pass 2014-09-07 12:44:26 +00:00
ValueMapper.h
VectorUtils.h Add minnum / maxnum intrinsics 2014-10-21 23:00:20 +00:00