15 #ifndef LLVM_ANALYSIS_CODEMETRICS_H
16 #define LLVM_ANALYSIS_CODEMETRICS_H
26 class TargetTransformInfo;
bool isRecursive
True if this function calls itself.
unsigned NumVectorInsts
How many instructions produce vector values.
unsigned NumCalls
Keep track of the number of calls to 'big' functions.
unsigned NumInlineCandidates
The number of calls to internal functions with a single caller.
bool notDuplicatable
True if this function cannot be duplicated.
unsigned NumBlocks
Number of analyzed blocks.
void analyzeBasicBlock(const BasicBlock *BB, const TargetTransformInfo &TTI)
Add information about a block to the current state.
bool usesDynamicAlloca
True if this function calls alloca (in the C sense).
LLVM Basic Block Representation.
DenseMap< const BasicBlock *, unsigned > NumBBInsts
Keeps track of basic block code size estimates.
bool exposesReturnsTwice
True if this function contains a call to setjmp or other functions with attribute "returns twice" wit...
Utility to calculate the size and a few similar metrics for a set of basic blocks.
unsigned NumRets
How many 'ret' instructions the blocks contain.
bool callIsSmall(ImmutableCallSite CS)
Check whether a call will lower to something small.
unsigned NumInsts
Number of instructions in the analyzed blocks.