LLVM: lib/Analysis/CaptureTracking.cpp File Reference (original) (raw)

Go to the source code of this file.

Macros
#define DEBUG_TYPE "capture-tracking"
Functions
Variables
static cl::opt< unsigned > DefaultMaxUsesToExplore ("capture-tracking-max-uses-to-explore", cl::Hidden, cl::desc("Maximal number of uses to explore."), cl::init(100))
The default value for MaxUsesToExplore argument.

DEBUG_TYPE

#define DEBUG_TYPE "capture-tracking"

STATISTIC() [1/4]

STATISTIC ( NumCaptured ,
"Number of pointers maybe captured" )

STATISTIC() [2/4]

STATISTIC ( NumCapturedBefore ,
"Number of pointers maybe captured before" )

STATISTIC() [3/4]

STATISTIC ( NumNotCaptured ,
"Number of pointers not captured" )

STATISTIC() [4/4]

STATISTIC ( NumNotCapturedBefore ,
"Number of pointers not captured before" )

DefaultMaxUsesToExplore

cl::opt< unsigned > DefaultMaxUsesToExplore("capture-tracking-max-uses-to-explore", cl::Hidden, cl::desc("Maximal number of uses to explore."), cl::init(100)) ( "capture-tracking-max-uses-to-explore" , cl::Hidden , cl::desc("Maximal number of uses to explore.") , cl::init(100) ) static

The default value for MaxUsesToExplore argument.

It's relatively small to keep the cost of analysis reasonable for clients like BasicAliasAnalysis, where the results can't be cached. TODO: we should probably introduce a caching CaptureTracking analysis and use it where possible. The caching version can use much higher limit or don't have this cap at all.

Referenced by llvm::getDefaultMaxUsesToExploreForCaptureTracking(), and llvm::PointerMayBeCaptured().