clang  3.9.0svn
Classes | Public Types | Public Member Functions | Static Public Member Functions | Friends | List of all members
clang::ento::ExplodedNode Class Reference

#include <ExplodedGraph.h>

Inheritance diagram for clang::ento::ExplodedNode:
Inheritance graph
[legend]
Collaboration diagram for clang::ento::ExplodedNode:
Collaboration graph
[legend]

Classes

class  Auditor
 

Public Types

typedef ExplodedNode *const * succ_iterator
 
typedef const ExplodedNode *const * const_succ_iterator
 
typedef ExplodedNode *const * pred_iterator
 
typedef const ExplodedNode *const * const_pred_iterator
 

Public Member Functions

 ExplodedNode (const ProgramPoint &loc, ProgramStateRef state, bool IsSink)
 
ProgramPoint getLocation () const
 getLocation - Returns the edge associated with the given node. More...
 
const LocationContextgetLocationContext () const
 
const StackFrameContextgetStackFrame () const
 
const DeclgetCodeDecl () const
 
CFGgetCFG () const
 
ParentMapgetParentMap () const
 
template<typename T >
T & getAnalysis () const
 
const ProgramStateRefgetState () const
 
template<typename T >
Optional< T > getLocationAs () const LLVM_LVALUE_FUNCTION
 
void Profile (llvm::FoldingSetNodeID &ID) const
 
void addPredecessor (ExplodedNode *V, ExplodedGraph &G)
 addPredeccessor - Adds a predecessor to the current node, and in tandem add this node as a successor of the other node. More...
 
unsigned succ_size () const
 
unsigned pred_size () const
 
bool succ_empty () const
 
bool pred_empty () const
 
bool isSink () const
 
bool hasSinglePred () const
 
ExplodedNodegetFirstPred ()
 
const ExplodedNodegetFirstPred () const
 
const ExplodedNodegetFirstSucc () const
 
pred_iterator pred_begin ()
 
pred_iterator pred_end ()
 
const_pred_iterator pred_begin () const
 
const_pred_iterator pred_end () const
 
succ_iterator succ_begin ()
 
succ_iterator succ_end ()
 
const_succ_iterator succ_begin () const
 
const_succ_iterator succ_end () const
 

Static Public Member Functions

static void Profile (llvm::FoldingSetNodeID &ID, const ProgramPoint &Loc, const ProgramStateRef &state, bool IsSink)
 
static void SetAuditor (Auditor *A)
 

Friends

class ExplodedGraph
 
class CoreEngine
 
class NodeBuilder
 
class BranchNodeBuilder
 
class IndirectGotoNodeBuilder
 
class SwitchNodeBuilder
 
class EndOfFunctionNodeBuilder
 

Detailed Description

Definition at line 55 of file ExplodedGraph.h.

Member Typedef Documentation

Definition at line 205 of file ExplodedGraph.h.

Definition at line 203 of file ExplodedGraph.h.

Definition at line 204 of file ExplodedGraph.h.

Definition at line 202 of file ExplodedGraph.h.

Constructor & Destructor Documentation

clang::ento::ExplodedNode::ExplodedNode ( const ProgramPoint loc,
ProgramStateRef  state,
bool  IsSink 
)
inlineexplicit

Definition at line 125 of file ExplodedGraph.h.

References isSink().

Member Function Documentation

void ExplodedNode::addPredecessor ( ExplodedNode V,
ExplodedGraph G 
)
template<typename T >
T& clang::ento::ExplodedNode::getAnalysis ( ) const
inline

Definition at line 149 of file ExplodedGraph.h.

References clang::LocationContext::getAnalysis(), and getLocationContext().

CFG& clang::ento::ExplodedNode::getCFG ( ) const
inline

Definition at line 144 of file ExplodedGraph.h.

References clang::LocationContext::getCFG(), and getLocationContext().

const Decl& clang::ento::ExplodedNode::getCodeDecl ( ) const
inline
ExplodedNode* clang::ento::ExplodedNode::getFirstPred ( )
inline
const ExplodedNode* clang::ento::ExplodedNode::getFirstPred ( ) const
inline

Definition at line 193 of file ExplodedGraph.h.

References getFirstPred().

const ExplodedNode* clang::ento::ExplodedNode::getFirstSucc ( ) const
inline

Definition at line 197 of file ExplodedGraph.h.

References succ_begin(), and succ_empty().

Referenced by clang::ento::PathDiagnosticLocation::getNextStmt().

ProgramPoint clang::ento::ExplodedNode::getLocation ( ) const
inline

getLocation - Returns the edge associated with the given node.

Definition at line 132 of file ExplodedGraph.h.

Referenced by alreadyExecutedAtLeastOneLoopIteration(), clang::ento::PathDiagnosticLocation::createEndOfPath(), didPreviousFreeFail(), clang::ento::CoreEngine::dispatchWorkItem(), clang::ento::WorkList::enqueue(), clang::ento::CoreEngine::enqueueStmtNode(), clang::ento::ExprEngine::evalEagerlyAssumeBinOpBifurcation(), clang::ento::CoreEngine::ExecuteWorkList(), findFailedReallocSymbol(), clang::ento::BugReporter::FlushReports(), GenerateAlternateExtensivePathDiagnostic(), GenerateExtensivePathDiagnostic(), GenerateMinimalPathDiagnostic(), GetAllocationSite(), getAsPointeeSymbol(), clang::ento::BugReporterVisitor::getDefaultEndPath(), getLastStmt(), getLocationContext(), clang::ento::CheckerContext::getLocationRegionIfPostStore(), clang::ento::StackHintGeneratorForSymbol::getMessage(), llvm::DOTGraphTraits< ExplodedNode * >::getNodeLabel(), getNullConstraint(), getReturnTypeForMethod(), clang::ento::PathDiagnosticLocation::getStmt(), getStmtBeforeCond(), clang::ento::ExplodedGraph::isInterestingLValueExpr(), isNSStringType(), isSynthesizedAccessor(), clang::ento::WorkList::makeBFS(), peelOffOuterExpr(), clang::ento::ExprEngine::processCFGBlockEntrance(), clang::ento::mpi::MPIBugReporter::reportUnmatchedWait(), shouldRemoveDeadBindings(), clang::ento::bugreporter::trackNullOrUndefValue(), clang::ento::ExplodedGraph::trim(), clang::ento::ExprEngine::Visit(), clang::ento::ExprEngine::VisitLogicalExpr(), clang::ento::FindLastStoreBRVisitor::VisitNode(), clang::ento::TrackConstraintBRVisitor::VisitNode(), clang::ento::UndefOrNullArgVisitor::VisitNode(), clang::ento::SuppressInlineDefensiveChecksVisitor::VisitNode(), clang::ento::ConditionBRVisitor::VisitNodeImpl(), and clang::ento::ExprEngine::VisitObjCMessage().

template<typename T >
Optional<T> clang::ento::ExplodedNode::getLocationAs ( ) const
inline
const LocationContext* clang::ento::ExplodedNode::getLocationContext ( ) const
inline

Definition at line 134 of file ExplodedGraph.h.

References getLocation(), and clang::ProgramPoint::getLocationContext().

Referenced by clang::ento::ExprEngine::bindReturnValue(), clang::ento::ExprEngine::CreateCXXTemporaryObject(), clang::ento::PathDiagnosticLocation::createEndOfPath(), didPreviousFreeFail(), clang::ento::CoreEngine::enqueueEndOfFunction(), clang::ento::CoreEngine::enqueueStmtNode(), clang::ento::ExprEngine::evalBind(), clang::ento::ExprEngine::evalEagerlyAssumeBinOpBifurcation(), clang::ento::CoreEngine::ExecuteWorkListWithInitialState(), expandGraphWithCheckers(), findFailedReallocSymbol(), GenerateAlternateExtensivePathDiagnostic(), clang::ento::SwitchNodeBuilder::generateCaseStmtNode(), clang::ento::SwitchNodeBuilder::generateDefaultCaseNode(), GenerateExtensivePathDiagnostic(), GenerateMinimalPathDiagnostic(), clang::ento::StmtNodeBuilder::generateNode(), clang::ento::BranchNodeBuilder::generateNode(), clang::ento::IndirectGotoNodeBuilder::generateNode(), clang::ento::StmtNodeBuilder::generateSink(), GetAllocationSite(), getAnalysis(), getArgumentValueString(), getAsPointeeSymbol(), clang::ento::CheckerContext::getCalleeDecl(), getCFG(), getCodeDecl(), clang::ento::CheckerContext::getCurrentAnalysisDeclContext(), clang::ento::BugReport::getDeclWithIssue(), clang::ento::BugReporterVisitor::getDefaultEndPath(), clang::ento::LikelyFalsePositiveSuppressionBRVisitor::getEndPath(), getFreeWhenDoneArg(), clang::ento::CheckerContext::getLocationContext(), clang::ento::IndirectGotoNodeBuilder::getLocationContext(), clang::ento::SwitchNodeBuilder::getLocationContext(), getLocationRegionIfReference(), clang::ento::StackHintGeneratorForSymbol::getMessage(), clang::ento::NilReceiverBRVisitor::getNilReceiver(), getNullConstraint(), getParentMap(), getReturnTypeForMethod(), getStackFrame(), isInitializationOfVar(), clang::ento::ExplodedGraph::isInterestingLValueExpr(), isNSStringType(), isSynthesizedAccessor(), makeZeroElementRegion(), mayInlineCallKind(), mayInlineDecl(), clang::ento::ConditionBRVisitor::patternMatch(), clang::ento::ExprEngine::ProcessAutomaticObjDtor(), clang::ento::ExprEngine::ProcessBaseDtor(), clang::ento::ExprEngine::processBranch(), clang::ento::ExprEngine::processCallExit(), clang::ento::ExprEngine::processCFGBlockEntrance(), clang::ento::ExprEngine::processCFGElement(), clang::ento::ExprEngine::ProcessDeleteDtor(), clang::ento::ExprEngine::processEndOfFunction(), clang::ento::ExprEngine::ProcessInitializer(), clang::ento::ExprEngine::ProcessMemberDtor(), clang::ento::ExprEngine::ProcessNewAllocator(), clang::ento::ExprEngine::ProcessStmt(), clang::ento::FindLastStoreBRVisitor::registerStatementVarDecls(), clang::ento::ExprEngine::removeDeadOnEndOfFunction(), removePiecesWithInvalidLocations(), clang::ento::CheckerManager::runCheckersForCallEvent(), clang::ento::CheckerManager::runCheckersForEndFunction(), clang::ento::CheckerManager::runCheckersForEvalCall(), clang::ento::CheckerManager::runCheckersForLiveSymbols(), suppressReport(), clang::ento::bugreporter::trackNullOrUndefValue(), clang::ento::ExprEngine::Visit(), clang::ento::ExprEngine::VisitBlockExpr(), clang::ento::ExprEngine::VisitCallExpr(), clang::ento::ExprEngine::VisitCast(), clang::ento::ExprEngine::VisitCommonDeclRefExpr(), clang::ento::ExprEngine::VisitCompoundLiteralExpr(), clang::ento::ConditionBRVisitor::VisitConditionVariable(), clang::ento::ExprEngine::VisitCXXCatchStmt(), clang::ento::ExprEngine::VisitCXXConstructExpr(), clang::ento::ExprEngine::VisitCXXDestructor(), clang::ento::ExprEngine::VisitCXXNewAllocatorCall(), clang::ento::ExprEngine::VisitCXXNewExpr(), clang::ento::ExprEngine::VisitCXXThisExpr(), clang::ento::ExprEngine::VisitDeclStmt(), clang::ento::ExprEngine::VisitGCCAsmStmt(), clang::ento::ExprEngine::VisitGuardedExpr(), clang::ento::ExprEngine::VisitIncrementDecrementOperator(), clang::ento::ExprEngine::VisitInitListExpr(), clang::ento::ExprEngine::VisitLambdaExpr(), clang::ento::ExprEngine::VisitLogicalExpr(), clang::ento::ExprEngine::VisitLvalObjCIvarRefExpr(), clang::ento::NilReceiverBRVisitor::VisitNode(), clang::ento::SuppressInlineDefensiveChecksVisitor::VisitNode(), clang::ento::ExprEngine::VisitObjCForCollectionStmt(), clang::ento::ExprEngine::VisitObjCMessage(), clang::ento::ExprEngine::VisitOffsetOfExpr(), and clang::ento::ConditionBRVisitor::VisitTrueTest().

ParentMap& clang::ento::ExplodedNode::getParentMap ( ) const
inline
const StackFrameContext* clang::ento::ExplodedNode::getStackFrame ( ) const
inline
const ProgramStateRef& clang::ento::ExplodedNode::getState ( ) const
inline

Definition at line 153 of file ExplodedGraph.h.

Referenced by clang::ento::mpi::MPIChecker::checkDoubleNonblocking(), clang::ento::CheckerContext::CheckerContext(), checkInvariantViolation(), clang::ento::ExprEngine::CreateCXXTemporaryObject(), clang::ento::ExprEngine::defaultEvalCall(), didPreviousFreeFail(), clang::ento::CoreEngine::enqueueStmtNode(), clang::ento::ExprEngine::evalBind(), clang::ento::ExprEngine::evalEagerlyAssumeBinOpBifurcation(), clang::ento::ExprEngine::evalLoad(), findFailedReallocSymbol(), clang::ento::BugReporter::FlushReports(), GenerateAlternateExtensivePathDiagnostic(), GenerateExtensivePathDiagnostic(), GetAllocationSite(), getArgumentValueString(), getAsPointeeSymbol(), clang::ento::CheckerContext::getCalleeName(), clang::ento::BugReporterVisitor::getDefaultEndPath(), getLocationRegionIfReference(), clang::ento::StackHintGeneratorForSymbol::getMessage(), clang::ento::NilReceiverBRVisitor::getNilReceiver(), llvm::DOTGraphTraits< ExplodedNode * >::getNodeLabel(), getNullConstraint(), getReturnTypeForMethod(), clang::ento::CheckerContext::getState(), clang::ento::TrackConstraintBRVisitor::getTag(), clang::ento::ExplodedGraph::isInterestingLValueExpr(), isNSStringType(), isSynthesizedAccessor(), makeZeroElementRegion(), clang::ento::ConditionBRVisitor::patternMatch(), clang::ento::ExprEngine::ProcessAutomaticObjDtor(), clang::ento::ExprEngine::ProcessBaseDtor(), clang::ento::ExprEngine::processBranch(), clang::ento::ExprEngine::processCallEnter(), clang::ento::ExprEngine::processCallExit(), clang::ento::ExprEngine::processCFGBlockEntrance(), clang::ento::ExprEngine::processCleanupTemporaryBranch(), clang::ento::ExprEngine::ProcessDeleteDtor(), clang::ento::ExprEngine::processEndOfFunction(), clang::ento::ExprEngine::processIndirectGoto(), clang::ento::ExprEngine::ProcessInitializer(), clang::ento::ExprEngine::ProcessMemberDtor(), clang::ento::ExprEngine::ProcessNewAllocator(), clang::ento::ExprEngine::ProcessTemporaryDtor(), clang::ento::FindLastStoreBRVisitor::registerStatementVarDecls(), clang::ento::ExprEngine::removeDead(), clang::ento::mpi::MPIBugReporter::reportUnmatchedWait(), clang::ento::CheckerManager::runCheckersForObjCMessage(), clang::ento::CheckerManager::runCheckersForStmt(), clang::ento::SuppressInlineDefensiveChecksVisitor::SuppressInlineDefensiveChecksVisitor(), clang::ento::bugreporter::trackNullOrUndefValue(), clang::ento::ExprEngine::Visit(), clang::ento::ExprEngine::VisitBlockExpr(), clang::ento::ExprEngine::VisitCallExpr(), clang::ento::ExprEngine::VisitCast(), clang::ento::ExprEngine::VisitCommonDeclRefExpr(), clang::ento::ExprEngine::VisitCompoundLiteralExpr(), clang::ento::ConditionBRVisitor::VisitConditionVariable(), clang::ento::ExprEngine::VisitCXXCatchStmt(), clang::ento::ExprEngine::VisitCXXConstructExpr(), clang::ento::ExprEngine::VisitCXXDeleteExpr(), clang::ento::ExprEngine::VisitCXXDestructor(), clang::ento::ExprEngine::VisitCXXNewAllocatorCall(), clang::ento::ExprEngine::VisitCXXNewExpr(), clang::ento::ExprEngine::VisitCXXThisExpr(), clang::ento::ExprEngine::VisitDeclStmt(), clang::ento::ExprEngine::VisitGCCAsmStmt(), clang::ento::ExprEngine::VisitGuardedExpr(), clang::ento::ExprEngine::VisitIncrementDecrementOperator(), clang::ento::ExprEngine::VisitInitListExpr(), clang::ento::ExprEngine::VisitLambdaExpr(), clang::ento::ExprEngine::VisitLogicalExpr(), clang::ento::ExprEngine::VisitLvalObjCIvarRefExpr(), clang::ento::ExprEngine::VisitMSAsmStmt(), clang::ento::FindLastStoreBRVisitor::VisitNode(), clang::ento::UndefOrNullArgVisitor::VisitNode(), clang::ento::SuppressInlineDefensiveChecksVisitor::VisitNode(), clang::ento::ConditionBRVisitor::VisitNodeImpl(), clang::ento::ExprEngine::VisitObjCForCollectionStmt(), clang::ento::ExprEngine::VisitObjCMessage(), clang::ento::ExprEngine::VisitOffsetOfExpr(), and clang::ento::ConditionBRVisitor::VisitTrueTest().

bool clang::ento::ExplodedNode::hasSinglePred ( ) const
inline

Definition at line 185 of file ExplodedGraph.h.

References pred_size().

Referenced by clang::ento::CoreEngine::dispatchWorkItem().

bool clang::ento::ExplodedNode::isSink ( ) const
inline
pred_iterator clang::ento::ExplodedNode::pred_begin ( )
inline
const_pred_iterator clang::ento::ExplodedNode::pred_begin ( ) const
inline

Definition at line 210 of file ExplodedGraph.h.

References pred_begin().

bool clang::ento::ExplodedNode::pred_empty ( ) const
inline
pred_iterator clang::ento::ExplodedNode::pred_end ( )
inline
const_pred_iterator clang::ento::ExplodedNode::pred_end ( ) const
inline

Definition at line 213 of file ExplodedGraph.h.

References pred_end().

unsigned clang::ento::ExplodedNode::pred_size ( ) const
inline
static void clang::ento::ExplodedNode::Profile ( llvm::FoldingSetNodeID &  ID,
const ProgramPoint Loc,
const ProgramStateRef state,
bool  IsSink 
)
inlinestatic

Definition at line 160 of file ExplodedGraph.h.

Referenced by clang::ento::ExplodedGraph::getNode(), and Profile().

void clang::ento::ExplodedNode::Profile ( llvm::FoldingSetNodeID &  ID) const
inline

Definition at line 169 of file ExplodedGraph.h.

References addPredecessor(), isSink(), and Profile().

void ExplodedNode::SetAuditor ( ExplodedNode::Auditor A)
static

Definition at line 40 of file ExplodedGraph.cpp.

Referenced by getFunctionName().

succ_iterator clang::ento::ExplodedNode::succ_begin ( )
inline
const_succ_iterator clang::ento::ExplodedNode::succ_begin ( ) const
inline

Definition at line 220 of file ExplodedGraph.h.

References succ_begin().

bool clang::ento::ExplodedNode::succ_empty ( ) const
inline

Definition at line 180 of file ExplodedGraph.h.

Referenced by FindReportInEquivalenceClass(), and getFirstSucc().

succ_iterator clang::ento::ExplodedNode::succ_end ( )
inline
const_succ_iterator clang::ento::ExplodedNode::succ_end ( ) const
inline

Definition at line 223 of file ExplodedGraph.h.

References succ_end().

unsigned clang::ento::ExplodedNode::succ_size ( ) const
inline

Friends And Related Function Documentation

friend class BranchNodeBuilder
friend

Definition at line 59 of file ExplodedGraph.h.

friend class CoreEngine
friend

Definition at line 57 of file ExplodedGraph.h.

friend class EndOfFunctionNodeBuilder
friend

Definition at line 62 of file ExplodedGraph.h.

friend class ExplodedGraph
friend

Definition at line 56 of file ExplodedGraph.h.

Referenced by clang::ento::ExplodedGraph::addEndOfPath().

friend class IndirectGotoNodeBuilder
friend

Definition at line 60 of file ExplodedGraph.h.

friend class NodeBuilder
friend

Definition at line 58 of file ExplodedGraph.h.

friend class SwitchNodeBuilder
friend

Definition at line 61 of file ExplodedGraph.h.


The documentation for this class was generated from the following files: