LLVM API Documentation
#include "llvm/Analysis/InlineCost.h"#include "llvm/ADT/STLExtras.h"#include "llvm/ADT/SetVector.h"#include "llvm/ADT/SmallPtrSet.h"#include "llvm/ADT/SmallVector.h"#include "llvm/ADT/Statistic.h"#include "llvm/Analysis/AssumptionTracker.h"#include "llvm/Analysis/ConstantFolding.h"#include "llvm/Analysis/CodeMetrics.h"#include "llvm/Analysis/InstructionSimplify.h"#include "llvm/Analysis/TargetTransformInfo.h"#include "llvm/IR/CallSite.h"#include "llvm/IR/CallingConv.h"#include "llvm/IR/DataLayout.h"#include "llvm/IR/GetElementPtrTypeIterator.h"#include "llvm/IR/GlobalAlias.h"#include "llvm/IR/InstVisitor.h"#include "llvm/IR/IntrinsicInst.h"#include "llvm/IR/Operator.h"#include "llvm/Support/Debug.h"#include "llvm/Support/raw_ostream.h"
Go to the source code of this file.
Defines | |
| #define | DEBUG_TYPE "inline-cost" |
| #define | DEBUG_PRINT_STAT(x) dbgs() << " " #x ": " << x << "\n" |
Functions | |
| STATISTIC (NumCallsAnalyzed,"Number of call sites analyzed") | |
| INITIALIZE_PASS_BEGIN (InlineCostAnalysis,"inline-cost","Inline Cost Analysis", true, true) INITIALIZE_PASS_END(InlineCostAnalysis | |
| static bool | attributeMatches (Function *F1, Function *F2, Attribute::AttrKind Attr) |
| Test that two functions either have or have not the given attribute at the same time. | |
| static bool | functionsHaveCompatibleAttributes (Function *Caller, Function *Callee) |
| Test that there are no attribute conflicts between Caller and Callee that prevent inlining. | |
Variables | |
| inline | cost |
| inline Inline Cost | Analysis |
| inline Inline Cost | true |
| #define DEBUG_PRINT_STAT | ( | x | ) | dbgs() << " " #x ": " << x << "\n" |
| #define DEBUG_TYPE "inline-cost" |
Definition at line 38 of file InlineCost.cpp.
| static bool attributeMatches | ( | Function * | F1, |
| Function * | F2, | ||
| Attribute::AttrKind | Attr | ||
| ) | [static] |
Test that two functions either have or have not the given attribute at the same time.
Definition at line 1265 of file InlineCost.cpp.
References llvm::Function::hasFnAttribute().
Referenced by functionsHaveCompatibleAttributes().
| static bool functionsHaveCompatibleAttributes | ( | Function * | Caller, |
| Function * | Callee | ||
| ) | [static] |
Test that there are no attribute conflicts between Caller and Callee that prevent inlining.
Definition at line 1272 of file InlineCost.cpp.
References attributeMatches(), llvm::Attribute::SanitizeAddress, llvm::Attribute::SanitizeMemory, and llvm::Attribute::SanitizeThread.
Referenced by llvm::InlineCostAnalysis::getInlineCost().
| INITIALIZE_PASS_BEGIN | ( | InlineCostAnalysis | , |
| "inline-cost" | , | ||
| "Inline Cost Analysis" | , | ||
| true | , | ||
| true | |||
| ) |
| STATISTIC | ( | NumCallsAnalyzed | , |
| "Number of call sites analyzed" | |||
| ) |
Definition at line 1237 of file InlineCost.cpp.
Definition at line 1237 of file InlineCost.cpp.
Referenced by isProfitableChain().
Definition at line 1237 of file InlineCost.cpp.