llvm::emitUnaryFloatFnCall

Emit a call to the unary function named 'Name' (e.g. 'floor'). This function is known to take a single of type matching 'Op' and returns one value with the same type. If 'Op' is a long double, 'l' is added as the suffix of name, if 'Op' is a float, we add a 'f' suffix.

Synopsis

Declared in <llvm/Transforms/Utils/BuildLibCalls.h>

Value*
emitUnaryFloatFnCall(
    Value* Op,
    TargetLibraryInfo const* TLI,
    StringRef Name,
    IRBuilderBase& B,
    AttributeList const& Attrs);

Return Value

LLVM Value Representation

Parameters

NameDescription
OpLLVM Value Representation
TLIProvides information about what library functions are available for the current target.
NameRepresent a constant reference to a string, i.e. a character array and a length, which need not be null terminated.
BCommon base class shared among various IRBuilders.
AttrsThis class holds the attributes for a function, its return value, and its parameters. You access the attributes for each of them via an index into the AttributeList object. The function attributes are at index `AttributeList::FunctionIndex', the return value is at index `AttributeList::ReturnIndex', and the attributes for the parameters start at index `AttributeList::FirstArgIndex'.