Enable double to float shrinking optimizations for binary functions like 'fmin/fmax'. Fix radar:15283121

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@197434 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Yi Jiang
2013-12-16 22:42:40 +00:00
parent 89452cf827
commit 4faf2ba0c7
6 changed files with 172 additions and 9 deletions

View File

@@ -83,6 +83,14 @@ namespace llvm {
Value *EmitUnaryFloatFnCall(Value *Op, StringRef Name, IRBuilder<> &B,
const AttributeSet &Attrs);
/// EmitUnaryFloatFnCall - Emit a call to the binary function named 'Name'
/// (e.g. 'fmin'). This function is known to take type matching 'Op1' and
/// 'Op2' and return one value with the same type. If 'Op1/Op2' are long
/// double, 'l' is added as the suffix of name, if 'Op1/Op2' are float, we
/// add a 'f' suffix.
Value *EmitBinaryFloatFnCall(Value *Op1, Value *Op2, StringRef Name,
IRBuilder<> &B, const AttributeSet &Attrs);
/// EmitPutChar - Emit a call to the putchar function. This assumes that Char
/// is an integer.
Value *EmitPutChar(Value *Char, IRBuilder<> &B, const DataLayout *TD,