clang  9.0.0svn
Public Member Functions | Friends | List of all members
clang::ento::ProgramStateManager Class Reference

#include "clang/StaticAnalyzer/Core/PathSensitive/ProgramState.h"

Public Member Functions

 ProgramStateManager (ASTContext &Ctx, StoreManagerCreator CreateStoreManager, ConstraintManagerCreator CreateConstraintManager, llvm::BumpPtrAllocator &alloc, SubEngine *subeng)
 
 ~ProgramStateManager ()
 
ProgramStateRef getInitialState (const LocationContext *InitLoc)
 
ASTContextgetContext ()
 
const ASTContextgetContext () const
 
BasicValueFactorygetBasicVals ()
 
SValBuildergetSValBuilder ()
 
SymbolManagergetSymbolManager ()
 
const SymbolManagergetSymbolManager () const
 
llvm::BumpPtrAllocator & getAllocator ()
 
MemRegionManagergetRegionManager ()
 
const MemRegionManagergetRegionManager () const
 
CallEventManagergetCallEventManager ()
 
StoreManagergetStoreManager ()
 
ConstraintManagergetConstraintManager ()
 
SubEnginegetOwningEngine ()
 
ProgramStateRef removeDeadBindings (ProgramStateRef St, const StackFrameContext *LCtx, SymbolReaper &SymReaper)
 
SVal ArrayToPointer (Loc Array, QualType ElementTy)
 
ProgramStateRef addGDM (ProgramStateRef St, void *Key, void *Data)
 
ProgramStateRef removeGDM (ProgramStateRef state, void *Key)
 
void iterBindings (ProgramStateRef state, StoreManager::BindingsHandler &F)
 
ProgramStateRef getPersistentState (ProgramState &Impl)
 
ProgramStateRef getPersistentStateWithGDM (ProgramStateRef FromState, ProgramStateRef GDMState)
 
bool haveEqualConstraints (ProgramStateRef S1, ProgramStateRef S2) const
 
bool haveEqualEnvironments (ProgramStateRef S1, ProgramStateRef S2) const
 
bool haveEqualStores (ProgramStateRef S1, ProgramStateRef S2) const
 
template<typename T >
ProgramStateRef set (ProgramStateRef st, typename ProgramStateTrait< T >::data_type D)
 
template<typename T >
ProgramStateRef set (ProgramStateRef st, typename ProgramStateTrait< T >::key_type K, typename ProgramStateTrait< T >::value_type V, typename ProgramStateTrait< T >::context_type C)
 
template<typename T >
ProgramStateRef add (ProgramStateRef st, typename ProgramStateTrait< T >::key_type K, typename ProgramStateTrait< T >::context_type C)
 
template<typename T >
ProgramStateRef remove (ProgramStateRef st, typename ProgramStateTrait< T >::key_type K, typename ProgramStateTrait< T >::context_type C)
 
template<typename T >
ProgramStateRef remove (ProgramStateRef st)
 
void * FindGDMContext (void *index, void *(*CreateContext)(llvm::BumpPtrAllocator &), void(*DeleteContext)(void *))
 
template<typename T >
ProgramStateTrait< T >::context_type get_context ()
 
void EndPath (ProgramStateRef St)
 

Friends

class ProgramState
 
void ProgramStateRelease (const ProgramState *state)
 Decrement the number of times this state is referenced. More...
 

Detailed Description

Definition at line 454 of file ProgramState.h.

Constructor & Destructor Documentation

◆ ProgramStateManager()

ProgramStateManager::ProgramStateManager ( ASTContext Ctx,
StoreManagerCreator  CreateStoreManager,
ConstraintManagerCreator  CreateConstraintManager,
llvm::BumpPtrAllocator &  alloc,
SubEngine subeng 
)

Definition at line 74 of file ProgramState.cpp.

◆ ~ProgramStateManager()

ProgramStateManager::~ProgramStateManager ( )

Definition at line 87 of file ProgramState.cpp.

Member Function Documentation

◆ add()

template<typename T >
ProgramStateRef clang::ento::ProgramStateManager::add ( ProgramStateRef  st,
typename ProgramStateTrait< T >::key_type  K,
typename ProgramStateTrait< T >::context_type  C 
)
inline

Definition at line 602 of file ProgramState.h.

◆ addGDM()

ProgramStateRef ProgramStateManager::addGDM ( ProgramStateRef  St,
void *  Key,
void *  Data 
)

Definition at line 499 of file ProgramState.cpp.

References getPersistentState().

◆ ArrayToPointer()

SVal clang::ento::ProgramStateManager::ArrayToPointer ( Loc  Array,
QualType  ElementTy 
)
inline

Definition at line 536 of file ProgramState.h.

References clang::CodeGen::state.

Referenced by clang::ento::SValBuilder::evalCast().

◆ EndPath()

void clang::ento::ProgramStateManager::EndPath ( ProgramStateRef  St)
inline

Definition at line 636 of file ProgramState.h.

◆ FindGDMContext()

void * ProgramStateManager::FindGDMContext ( void *  index,
void *(*)(llvm::BumpPtrAllocator &)  CreateContext,
void(*)(void *)  DeleteContext 
)

Definition at line 486 of file ProgramState.cpp.

◆ get_context()

template<typename T >
ProgramStateTrait<T>::context_type clang::ento::ProgramStateManager::get_context ( )
inline

Definition at line 628 of file ProgramState.h.

◆ getAllocator()

llvm::BumpPtrAllocator& clang::ento::ProgramStateManager::getAllocator ( )
inline

Definition at line 515 of file ProgramState.h.

◆ getBasicVals()

BasicValueFactory& clang::ento::ProgramStateManager::getBasicVals ( )
inline

◆ getCallEventManager()

CallEventManager& clang::ento::ProgramStateManager::getCallEventManager ( )
inline

◆ getConstraintManager()

ConstraintManager& clang::ento::ProgramStateManager::getConstraintManager ( )
inline

◆ getContext() [1/2]

ASTContext& clang::ento::ProgramStateManager::getContext ( )
inline

Definition at line 497 of file ProgramState.h.

Referenced by clang::ento::StoreManager::castRegion().

◆ getContext() [2/2]

const ASTContext& clang::ento::ProgramStateManager::getContext ( ) const
inline

Definition at line 498 of file ProgramState.h.

◆ getInitialState()

ProgramStateRef ProgramStateManager::getInitialState ( const LocationContext InitLoc)

◆ getOwningEngine()

SubEngine& clang::ento::ProgramStateManager::getOwningEngine ( )
inline

◆ getPersistentState()

ProgramStateRef ProgramStateManager::getPersistentState ( ProgramState Impl)

◆ getPersistentStateWithGDM()

ProgramStateRef ProgramStateManager::getPersistentStateWithGDM ( ProgramStateRef  FromState,
ProgramStateRef  GDMState 
)

Definition at line 394 of file ProgramState.cpp.

References getPersistentState().

Referenced by clang::ento::ExprEngine::removeDead().

◆ getRegionManager() [1/2]

MemRegionManager& clang::ento::ProgramStateManager::getRegionManager ( )
inline

Definition at line 517 of file ProgramState.h.

◆ getRegionManager() [2/2]

const MemRegionManager& clang::ento::ProgramStateManager::getRegionManager ( ) const
inline

Definition at line 520 of file ProgramState.h.

◆ getStoreManager()

StoreManager& clang::ento::ProgramStateManager::getStoreManager ( )
inline

◆ getSValBuilder()

SValBuilder& clang::ento::ProgramStateManager::getSValBuilder ( )
inline

◆ getSymbolManager() [1/2]

SymbolManager& clang::ento::ProgramStateManager::getSymbolManager ( )
inline

Definition at line 508 of file ProgramState.h.

◆ getSymbolManager() [2/2]

const SymbolManager& clang::ento::ProgramStateManager::getSymbolManager ( ) const
inline

Definition at line 511 of file ProgramState.h.

◆ haveEqualConstraints()

bool clang::ento::ProgramStateManager::haveEqualConstraints ( ProgramStateRef  S1,
ProgramStateRef  S2 
) const
inline

Definition at line 554 of file ProgramState.h.

◆ haveEqualEnvironments()

bool clang::ento::ProgramStateManager::haveEqualEnvironments ( ProgramStateRef  S1,
ProgramStateRef  S2 
) const
inline

Definition at line 558 of file ProgramState.h.

Referenced by clang::ento::ExprEngine::removeDead().

◆ haveEqualStores()

bool clang::ento::ProgramStateManager::haveEqualStores ( ProgramStateRef  S1,
ProgramStateRef  S2 
) const
inline

Definition at line 562 of file ProgramState.h.

Referenced by clang::ento::ExprEngine::removeDead().

◆ iterBindings()

void clang::ento::ProgramStateManager::iterBindings ( ProgramStateRef  state,
StoreManager::BindingsHandler F 
)
inline

Definition at line 546 of file ProgramState.h.

◆ remove() [1/2]

template<typename T >
ProgramStateRef clang::ento::ProgramStateManager::remove ( ProgramStateRef  st,
typename ProgramStateTrait< T >::key_type  K,
typename ProgramStateTrait< T >::context_type  C 
)
inline

Definition at line 610 of file ProgramState.h.

References AttributeLangSupport::C.

◆ remove() [2/2]

template<typename T >
ProgramStateRef clang::ento::ProgramStateManager::remove ( ProgramStateRef  st)
inline

Definition at line 619 of file ProgramState.h.

◆ removeDeadBindings()

ProgramStateRef ProgramStateManager::removeDeadBindings ( ProgramStateRef  St,
const StackFrameContext LCtx,
SymbolReaper SymReaper 
)

◆ removeGDM()

ProgramStateRef ProgramStateManager::removeGDM ( ProgramStateRef  state,
void *  Key 
)

Definition at line 511 of file ProgramState.cpp.

References getPersistentState(), and clang::CodeGen::state.

◆ set() [1/2]

template<typename T >
ProgramStateRef clang::ento::ProgramStateManager::set ( ProgramStateRef  st,
typename ProgramStateTrait< T >::data_type  D 
)
inline

Definition at line 586 of file ProgramState.h.

◆ set() [2/2]

template<typename T >
ProgramStateRef clang::ento::ProgramStateManager::set ( ProgramStateRef  st,
typename ProgramStateTrait< T >::key_type  K,
typename ProgramStateTrait< T >::value_type  V,
typename ProgramStateTrait< T >::context_type  C 
)
inline

Definition at line 592 of file ProgramState.h.

References AttributeLangSupport::C.

Friends And Related Function Documentation

◆ ProgramState

friend class ProgramState
friend

Definition at line 455 of file ProgramState.h.

Referenced by getPersistentState().

◆ ProgramStateRelease

void ProgramStateRelease ( const ProgramState state)
friend

Decrement the number of times this state is referenced.

Definition at line 33 of file ProgramState.cpp.


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