69 iter != eiter; ++iter)
82 DBOUT(
DSaber,
outs() <<
"Forward analysis reaches globals for slice:" << (*iter)->getId() <<
")\n");
86 DBOUT(
DSaber,
outs() <<
"Forward process for slice:" << (*iter)->getId() <<
" (size = " <<
getCurSlice()->getForwardSliceSize() <<
")\n");
96 DBOUT(
DSaber,
outs() <<
"Backward process for slice:" << (*iter)->getId() <<
" (size = " <<
getCurSlice()->getBackwardSliceSize() <<
")\n");
104 DBOUT(
DSaber,
outs() <<
"Guard computation for slice:" << (*iter)->getId() <<
")\n");
121 bool reachFunExit =
false;
216 csId = callEdge->getCallSiteId();
228 csId = callEdge->getCallSiteId();
#define DBOUT(TYPE, X)
LLVM debug macros, define type of your DBUG model of each pass.
static AndersenWaveDiff * createAndersenWaveDiff(SVFIR *_pag)
Create an singleton instance directly instead of invoking llvm pass manager.
u32_t cxtSize() const
Get context size.
static void setMaxCxtLen(u32_t max)
set max context limit
void pushContext(NodeID cxt)
Push context.
const ContextCond & getContexts() const
Get context.
virtual bool matchContext(NodeID cxt)
Match context.
NodeType * getSrcNode() const
NodeType * getDstNode() const
NodeID getSrcID() const
get methods of the components
iterator OutEdgeBegin()
iterators
bool pushIntoWorklist(CxtDPItem &item)
virtual void backwardTraverse(CxtDPItem &it)
virtual void forwardTraverse(CxtDPItem &it)
static const Option< u32_t > CxtLimit
static const Option< bool > SABERFULLSVFG
static const Option< u32_t > MaxStepInWrapper
static const Option< bool > DumpSlice
CallGraph * getCallGraph() const
Return call graph.
SVFGNodeSetIter sinksEnd() const
const SVFGNode * getSource() const
root and sink operations
SVFGNodeSetIter backwardSliceBegin() const
SVFGNodeSetIter forwardSliceEnd() const
SVFGNodeSetIter sinksBegin() const
SVFGNodeSetIter forwardSliceBegin() const
SVFGNodeSetIter backwardSliceEnd() const
void addToBackwardSlice(const SVFGNode *node)
void addToSources(const SVFGNode *node)
void addToSinks(const SVFGNode *node)
void addToForwardSlice(const SVFGNode *node)
SVFGStat * getStat() const
Return statistics.
static SVFIR * getPAG(bool buildFromFile=false)
Singleton design here to make sure we only have one instance during any analysis.
NodeID getId() const
Get ID.
void allocate()
Perform path allocation.
std::string getMemUsage()
Statistics.
bool test(unsigned Idx) const
SVFGNodeSetIter sourcesBegin() const
virtual void initSnks()=0
virtual void initSrcs()=0
bool backwardVisited(const SVFGNode *node)
bool isGlobalSVFGNode(const SVFGNode *node) const
Whether this svfg node may access global variable.
void BWProcessIncomingEdge(const DPIm &item, SVFGEdge *edge) override
Propagate information backward without matching context, as forward analysis already did it.
ProgSlice::VFWorkList WorkList
Set< const CallICFGNode * > CallSiteSet
void addForwardVisited(const SVFGNode *node, const DPIm &item)
virtual void analyze()
Start analysis here.
SVFGNodeSetIter sinksBegin() const
ProgSlice * getCurSlice() const
void annotateSlice(ProgSlice *slice)
bool forwardVisited(const SVFGNode *node, const DPIm &item)
Whether has been visited or not, in order to avoid recursion on SVFG.
void addBackwardVisited(const SVFGNode *node)
virtual void reportBug(ProgSlice *slice)=0
report bug on the current analyzed slice
SVFGNodeSetIter sinksEnd() const
virtual void setCurSlice(const SVFGNode *src)
Slice operations.
void dumpSlices()
Dump SVFG with annotated slice information.
void FWProcessOutgoingEdge(const DPIm &item, SVFGEdge *edge) override
Propagate information forward by matching context.
SVFGNodeSetIter sourcesEnd() const
SVFGNodeSet::const_iterator SVFGNodeSetIter
const SVFG * getSVFG() const
Get SVFG.
SaberCondAllocator * getSaberCondAllocator() const
Get saber condition allocator.
virtual void initialize()
Initialize analysis.
virtual void finalize()
Finalize analysis.
bool isInAWrapper(const SVFGNode *src, CallSiteSet &csIdSet)
Identify allocation wrappers.
bool isRetVFGEdge() const
bool isCallVFGEdge() const
bool isRetDirectVFGEdge() const
bool isCallDirectVFGEdge() const
VFGEdge::VFGEdgeSetTy::const_iterator const_iterator
std::enable_if_t<!is_simple_type< Y >::value, typename cast_retty< X, const Y >::ret_type > cast(const Y &Val)
LLVM_NODISCARD bool isa(const Y &Val)
std::ostream & outs()
Overwrite llvm::outs().
LLVM_NODISCARD std::enable_if_t<!is_simple_type< Y >::value, typename cast_retty< X, const Y >::ret_type > dyn_cast(const Y &Val)
StoreVFGNode StoreSVFGNode
ActualRetVFGNode ActualRetSVFGNode
void dump(const SparseBitVector< ElementSize > &LHS, std::ostream &out)
FormalRetVFGNode FormalRetSVFGNode