clang API Documentation
#include <LiveVariables.h>


Classes | |
| class | LivenessValues |
| class | Observer |
Public Member Functions | |
| virtual | ~LiveVariables () |
| bool | isLive (const CFGBlock *B, const VarDecl *D) |
| bool | isLive (const Stmt *S, const VarDecl *D) |
| bool | isLive (const Stmt *Loc, const Stmt *StmtVal) |
| void | dumpBlockLiveness (const SourceManager &M) |
| void | runOnAllBlocks (Observer &obs) |
Static Public Member Functions | |
| static LiveVariables * | computeLiveness (AnalysisDeclContext &analysisContext, bool killAtAssign) |
| Compute the liveness information for a given CFG. | |
| static LiveVariables * | create (AnalysisDeclContext &analysisContext) |
| static const void * | getTag () |
Definition at line 30 of file LiveVariables.h.
| LiveVariables::~LiveVariables | ( | ) | [virtual] |
Definition at line 476 of file LiveVariables.cpp.
| LiveVariables * LiveVariables::computeLiveness | ( | AnalysisDeclContext & | analysisContext, |
| bool | killAtAssign | ||
| ) | [static] |
Compute the liveness information for a given CFG.
Definition at line 481 of file LiveVariables.cpp.
References clang::CFGBlock::begin(), clang::CFG::begin(), clang::BO_Assign, clang::CFGBlock::end(), clang::CFG::end(), clang::LiveVariables::LivenessValues::equals(), clang::CFGElement::getAs(), clang::CFGBlock::getBlockID(), clang::AnalysisDeclContext::getCFG(), clang::CFG::getNumBlockIDs(), clang::CFGBlock::succ_begin(), and clang::CFGBlock::succ_end().
Referenced by create(), and clang::RelaxedLiveVariables::create().
| static LiveVariables* clang::LiveVariables::create | ( | AnalysisDeclContext & | analysisContext | ) | [inline, static] |
Reimplemented in clang::RelaxedLiveVariables.
Definition at line 98 of file LiveVariables.h.
References computeLiveness().
| void LiveVariables::dumpBlockLiveness | ( | const SourceManager & | M | ) |
Print to stderr the liveness information associated with each basic block.
Definition at line 564 of file LiveVariables.cpp.
References getImpl().
| const void * LiveVariables::getTag | ( | ) | [static] |
Reimplemented in clang::RelaxedLiveVariables.
Definition at line 606 of file LiveVariables.cpp.
Return true if a variable is live at the end of a specified block.
Definition at line 183 of file LiveVariables.cpp.
References getImpl(), and isAlwaysAlive().
Returns true if a variable is live at the beginning of the the statement. This query only works if liveness information has been recorded at the statement level (see runOnAllBlocks), and only returns liveness information for block-level expressions.
Definition at line 187 of file LiveVariables.cpp.
References getImpl(), isAlwaysAlive(), and S.
Returns true the block-level expression "value" is live before the given block-level expression (see runOnAllBlocks).
Definition at line 191 of file LiveVariables.cpp.
References getImpl().
| void LiveVariables::runOnAllBlocks | ( | LiveVariables::Observer & | obs | ) |
Definition at line 468 of file LiveVariables.cpp.
References clang::CFG::begin(), clang::CFG::end(), and getImpl().