LLVM  4.0.0
Public Member Functions | Friends | List of all members
llvm::TargetLibraryInfo Class Reference

Provides information about what library functions are available for the current target. More...

#include <TargetLibraryInfo.h>

Public Member Functions

 TargetLibraryInfo (const TargetLibraryInfoImpl &Impl)
 
 TargetLibraryInfo (const TargetLibraryInfo &TLI)
 
 TargetLibraryInfo (TargetLibraryInfo &&TLI)
 
TargetLibraryInfooperator= (const TargetLibraryInfo &TLI)
 
TargetLibraryInfooperator= (TargetLibraryInfo &&TLI)
 
bool getLibFunc (StringRef funcName, LibFunc::Func &F) const
 Searches for a particular function name. More...
 
bool getLibFunc (const Function &FDecl, LibFunc::Func &F) const
 
bool has (LibFunc::Func F) const
 Tests whether a library function is available. More...
 
bool isFunctionVectorizable (StringRef F, unsigned VF) const
 
bool isFunctionVectorizable (StringRef F) const
 
StringRef getVectorizedFunction (StringRef F, unsigned VF) const
 
bool hasOptimizedCodeGen (LibFunc::Func F) const
 Tests if the function is both available and a candidate for optimized code generation. More...
 
StringRef getName (LibFunc::Func F) const
 
Attribute::AttrKind getExtAttrForI32Param (bool Signed=true) const
 Returns extension attribute kind to be used for i32 parameters corresponding to C-level int or unsigned int. More...
 
Attribute::AttrKind getExtAttrForI32Return (bool Signed=true) const
 Returns extension attribute kind to be used for i32 return values corresponding to C-level int or unsigned int. More...
 
bool invalidate (Module &, const PreservedAnalyses &, ModuleAnalysisManager::Invalidator &)
 Handle invalidation from the pass manager. More...
 
bool invalidate (Function &, const PreservedAnalyses &, FunctionAnalysisManager::Invalidator &)
 

Friends

class TargetLibraryAnalysis
 
class TargetLibraryInfoWrapperPass
 

Detailed Description

Provides information about what library functions are available for the current target.

This both allows optimizations to handle them specially and frontends to disable such optimizations through -fno-builtin etc.

Definition at line 203 of file TargetLibraryInfo.h.

Constructor & Destructor Documentation

llvm::TargetLibraryInfo::TargetLibraryInfo ( const TargetLibraryInfoImpl Impl)
inlineexplicit

Definition at line 210 of file TargetLibraryInfo.h.

llvm::TargetLibraryInfo::TargetLibraryInfo ( const TargetLibraryInfo TLI)
inline

Definition at line 213 of file TargetLibraryInfo.h.

llvm::TargetLibraryInfo::TargetLibraryInfo ( TargetLibraryInfo &&  TLI)
inline

Definition at line 214 of file TargetLibraryInfo.h.

Member Function Documentation

Attribute::AttrKind llvm::TargetLibraryInfo::getExtAttrForI32Param ( bool  Signed = true) const
inline

Returns extension attribute kind to be used for i32 parameters corresponding to C-level int or unsigned int.

May be zeroext, signext, or none.

Definition at line 295 of file TargetLibraryInfo.h.

References llvm::Attribute::None, and Signed.

Referenced by getOrInsertValueProfilingCall().

Attribute::AttrKind llvm::TargetLibraryInfo::getExtAttrForI32Return ( bool  Signed = true) const
inline

Returns extension attribute kind to be used for i32 return values corresponding to C-level int or unsigned int.

May be zeroext, signext, or none.

Definition at line 306 of file TargetLibraryInfo.h.

References llvm::Attribute::None, and Signed.

bool llvm::TargetLibraryInfo::getLibFunc ( StringRef  funcName,
LibFunc::Func F 
) const
inline
bool llvm::TargetLibraryInfo::getLibFunc ( const Function FDecl,
LibFunc::Func F 
) const
inline

Definition at line 232 of file TargetLibraryInfo.h.

References llvm::TargetLibraryInfoImpl::getLibFunc().

StringRef llvm::TargetLibraryInfo::getName ( LibFunc::Func  F) const
inline
StringRef llvm::TargetLibraryInfo::getVectorizedFunction ( StringRef  F,
unsigned  VF 
) const
inline
bool llvm::TargetLibraryInfo::has ( LibFunc::Func  F) const
inline
bool llvm::TargetLibraryInfo::hasOptimizedCodeGen ( LibFunc::Func  F) const
inline

Tests if the function is both available and a candidate for optimized code generation.

Definition at line 252 of file TargetLibraryInfo.h.

References round(), and fuzzer::strcmp.

Referenced by llvm::maybeMarkSanitizerLibraryCallNoBuiltin(), and llvm::FastISel::selectInstruction().

bool llvm::TargetLibraryInfo::invalidate ( Module ,
const PreservedAnalyses ,
ModuleAnalysisManager::Invalidator  
)
inline

Handle invalidation from the pass manager.

If we try to invalidate this info, just return false. It cannot become invalid even if the module or function changes.

Definition at line 316 of file TargetLibraryInfo.h.

bool llvm::TargetLibraryInfo::invalidate ( Function ,
const PreservedAnalyses ,
FunctionAnalysisManager::Invalidator  
)
inline

Definition at line 320 of file TargetLibraryInfo.h.

bool llvm::TargetLibraryInfo::isFunctionVectorizable ( StringRef  F,
unsigned  VF 
) const
inline
bool llvm::TargetLibraryInfo::isFunctionVectorizable ( StringRef  F) const
inline
TargetLibraryInfo& llvm::TargetLibraryInfo::operator= ( const TargetLibraryInfo TLI)
inline

Definition at line 215 of file TargetLibraryInfo.h.

TargetLibraryInfo& llvm::TargetLibraryInfo::operator= ( TargetLibraryInfo &&  TLI)
inline

Definition at line 219 of file TargetLibraryInfo.h.

Friends And Related Function Documentation

friend class TargetLibraryAnalysis
friend

Definition at line 204 of file TargetLibraryInfo.h.

friend class TargetLibraryInfoWrapperPass
friend

Definition at line 205 of file TargetLibraryInfo.h.


The documentation for this class was generated from the following file: