clang API Documentation
#include "clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h"
#include "PrettyStackTraceLocationContext.h"
#include "clang/AST/CharUnits.h"
#include "clang/AST/ParentMap.h"
#include "clang/AST/StmtCXX.h"
#include "clang/AST/StmtObjC.h"
#include "clang/Basic/Builtins.h"
#include "clang/Basic/PrettyStackTrace.h"
#include "clang/Basic/SourceManager.h"
#include "clang/StaticAnalyzer/Core/BugReporter/BugType.h"
#include "clang/StaticAnalyzer/Core/CheckerManager.h"
#include "clang/StaticAnalyzer/Core/PathSensitive/AnalysisManager.h"
#include "clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h"
#include "llvm/ADT/ImmutableList.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Support/GraphWriter.h"
Go to the source code of this file.
Classes | |
struct | llvm::DOTGraphTraits< ExplodedNode * > |
Namespaces | |
namespace | llvm |
Defines | |
#define | DEBUG_TYPE "ExprEngine" |
Typedefs | |
typedef std::pair< const CXXBindTemporaryExpr *, const StackFrameContext * > | CXXBindTemporaryContext |
Functions | |
STATISTIC (NumRemoveDeadBindings,"The # of times RemoveDeadBindings is called") | |
STATISTIC (NumMaxBlockCountReached,"The # of aborted paths due to reaching the maximum block count in ""a top level function") | |
STATISTIC (NumMaxBlockCountReachedInInlined,"The # of aborted paths due to reaching the maximum block count in ""an inlined function") | |
STATISTIC (NumTimesRetriedWithoutInlining,"The # of times we re-evaluated a call without inlining") | |
REGISTER_TRAIT_WITH_PROGRAMSTATE (InitializedTemporariesSet, llvm::ImmutableSet< CXXBindTemporaryContext >) static const char *TagProviderName | |
static bool | shouldRemoveDeadBindings (AnalysisManager &AMgr, const CFGStmt S, const ExplodedNode *Pred, const LocationContext *LC) |
static SVal | RecoverCastedSymbol (ProgramStateManager &StateMgr, ProgramStateRef state, const Stmt *Condition, const LocationContext *LCtx, ASTContext &Ctx) |
static const Stmt * | getRightmostLeaf (const Stmt *Condition) |
static const Stmt * | ResolveCondition (const Stmt *Condition, const CFGBlock *B) |
REGISTER_TRAIT_WITH_PROGRAMSTATE (InitializedGlobalsSet, llvm::ImmutableSet< const VarDecl * >) void ExprEngine | |
template<typename ITERATOR > | |
ExplodedNode * | GetGraphNode (ITERATOR I) |
Variables | |
static ExprEngine * | GraphPrintCheckerState |
static SourceManager * | GraphPrintSourceManager |
#define DEBUG_TYPE "ExprEngine" |
Definition at line 41 of file ExprEngine.cpp.
typedef std::pair<const CXXBindTemporaryExpr *, const StackFrameContext *> CXXBindTemporaryContext |
Definition at line 55 of file ExprEngine.cpp.
ExplodedNode* GetGraphNode | ( | ITERATOR | I | ) |
Definition at line 2651 of file ExprEngine.cpp.
static const Stmt* getRightmostLeaf | ( | const Stmt * | Condition | ) | [static] |
Definition at line 1456 of file ExprEngine.cpp.
References clang::BinaryOperator::getRHS(), clang::Expr::IgnoreParens(), and clang::BinaryOperator::isLogicalOp().
Referenced by ResolveCondition().
static SVal RecoverCastedSymbol | ( | ProgramStateManager & | StateMgr, |
ProgramStateRef | state, | ||
const Stmt * | Condition, | ||
const LocationContext * | LCtx, | ||
ASTContext & | Ctx | ||
) | [static] |
RecoverCastedSymbol - A helper function for ProcessBranch that is used to try to recover some path-sensitivity for casts of symbolic integers that promote their values (which are currently not tracked well). This function returns the SVal bound to Condition->IgnoreCasts if all the
Definition at line 1417 of file ExprEngine.cpp.
References clang::Expr::getType(), clang::ASTContext::getTypeSize(), and clang::Type::isIntegralOrEnumerationType().
Referenced by clang::ento::ExprEngine::processBranch().
REGISTER_TRAIT_WITH_PROGRAMSTATE | ( | InitializedTemporariesSet | , |
llvm::ImmutableSet< CXXBindTemporaryContext > | |||
) | const |
REGISTER_TRAIT_WITH_PROGRAMSTATE | ( | InitializedGlobalsSet | , |
llvm::ImmutableSet< const VarDecl * > | |||
) |
The GDM component containing the set of global variables which have been previously initialized with explicit initializers.
Definition at line 1615 of file ExprEngine.cpp.
static const Stmt* ResolveCondition | ( | const Stmt * | Condition, |
const CFGBlock * | B | ||
) | [static] |
Definition at line 1482 of file ExprEngine.cpp.
References clang::CFGElement::getAs(), getRightmostLeaf(), clang::CFGBlock::getTerminator(), clang::Expr::IgnoreParens(), clang::BinaryOperator::isLogicalOp(), clang::CFGTerminator::isTemporaryDtorsBranch(), clang::CFGBlock::rbegin(), and clang::CFGBlock::rend().
Referenced by clang::ento::ExprEngine::processBranch().
static bool shouldRemoveDeadBindings | ( | AnalysisManager & | AMgr, |
const CFGStmt | S, | ||
const ExplodedNode * | Pred, | ||
const LocationContext * | LC | ||
) | [static] |
Definition at line 314 of file ExprEngine.cpp.
References clang::AnalyzerOptions::AnalysisPurgeOpt, clang::LocationContext::getAnalysisDeclContext(), clang::ProgramPoint::getAs(), clang::ento::ExplodedNode::getLocation(), clang::AnalysisDeclContext::getParentMap(), clang::CFGStmt::getStmt(), clang::ento::CallEvent::isCallStmt(), clang::ParentMap::isConsumedExpr(), and clang::ento::AnalysisManager::options.
Referenced by clang::ento::ExprEngine::ProcessStmt().
STATISTIC | ( | NumRemoveDeadBindings | , |
"The # of times RemoveDeadBindings is called" | |||
) |
STATISTIC | ( | NumMaxBlockCountReached | , |
"The # of aborted paths due to reaching the maximum block count in ""a top level function" | |||
) |
STATISTIC | ( | NumMaxBlockCountReachedInInlined | , |
"The # of aborted paths due to reaching the maximum block count in ""an inlined function" | |||
) |
STATISTIC | ( | NumTimesRetriedWithoutInlining | , |
"The # of times we re-evaluated a call without inlining" | |||
) |
ExprEngine* GraphPrintCheckerState [static] |
Definition at line 2394 of file ExprEngine.cpp.
Referenced by llvm::DOTGraphTraits< ExplodedNode * >::getNodeAttributes(), llvm::DOTGraphTraits< ExplodedNode * >::getNodeLabel(), and clang::ento::ExprEngine::ViewGraph().
SourceManager* GraphPrintSourceManager [static] |
Definition at line 2395 of file ExprEngine.cpp.
Referenced by llvm::DOTGraphTraits< ExplodedNode * >::getNodeLabel(), llvm::DOTGraphTraits< ExplodedNode * >::printLocation(), and clang::ento::ExprEngine::ViewGraph().