45 u32_t numOfForkEdge = 0;
46 u32_t numOfJoinEdge = 0;
47 u32_t numOfIndForksite = 0;
48 u32_t numOfIndForkEdge = 0;
51 bool indirectfork =
false;
58 for (ThreadCallGraph::ForkEdgeSet::const_iterator cgIt = tcg->
getForkEdgeBegin(*it), ecgIt =
69 for (ThreadCallGraph::JoinEdgeSet::const_iterator cgIt = tcg->
getJoinEdgeBegin(*it), ecgIt =
86 SVFUtil::outs() <<
"\n****Thread Call Graph Statistics****\n";
102 SVFUtil::outs() <<
"\n****Thread Creation Tree Statistics****\n";
133 if(SVFUtil::isa<LoadStmt>(stmt))
135 instSet1.insert(stmt->getICFGNode());
137 else if(SVFUtil::isa<StoreStmt>(stmt))
139 instSet1.insert(stmt->getICFGNode());
140 instSet2.insert(stmt->getICFGNode());
u32_t getTotalNodeNum() const
Get total number of node/edge.
TCT * getTCT() const
Get Thread Creation Tree.
u32_t numOfTotalQueries
Total number of queries.
virtual bool mayHappenInParallel(const ICFGNode *i1, const ICFGNode *i2)
Interface to query whether two instructions may happen-in-parallel.
bool isConnectedfromMain(const SVFFunction *fun)
Whether the function is connected from main function in thread call graph.
double interleavingQueriesTime
u32_t numOfMHPQueries
Number of queries are answered as may-happen-in-parallel.
void performTCTStat(TCT *tct)
Statistics for thread creation tree.
void performThreadCallGraphStat(ThreadCallGraph *tcg)
Statistics for thread call graph.
double TCTTime
Statistics for annotation.
void performMHPPairStat(MHP *mhp, LockAnalysis *lsa)
Statistics for MHP statement pairs.
static const Option< bool > AllPairMHP
u32_t getNumOfResolvedIndCallEdge() const
const std::vector< const ICFGNode * > & getICFGNodeList() const
std::vector< const SVFBasicBlock * >::const_iterator const_iterator
static SVFIR * getPAG(bool buildFromFile=false)
Singleton design here to make sure we only have one instance during any analysis.
SVFStmtList & getSVFStmtList(const ICFGNode *inst)
Given an instruction, get all its PAGEdges.
const FunctionSetType & getFunctionSet() const
virtual void printStat(std::string str="")
const SVFValue * getValue() const
Get/has methods of the components.
ThreadCallGraph * getThreadCallGraph() const
Get TCG.
u32_t getMaxCxtSize() const
const FunSet & getMakredProcs() const
Get marked candidate functions.
u32_t getTCTEdgeNum() const
SVFModule * getSVFModule() const
Get SVFFModule.
u32_t getTCTNodeNum() const
Get Statistics.
const SVFVar * getForkedFun(const CallICFGNode *inst) const
CallSiteSet::const_iterator forksitesEnd() const
CallSiteSet::const_iterator forksitesBegin() const
Fork sites iterators.
CallSiteSet::const_iterator joinsitesEnd() const
u32_t getNumOfJoinsite() const
JoinEdgeSet::const_iterator getJoinEdgeEnd(const CallICFGNode *cs) const
ForkEdgeSet::const_iterator getForkEdgeEnd(const CallICFGNode *cs) const
ForkEdgeSet::const_iterator getForkEdgeBegin(const CallICFGNode *cs) const
CallSiteSet::const_iterator joinsitesBegin() const
Join sites iterators.
u32_t getNumOfForksite() const
Num of fork/join sites.
ThreadAPI * getThreadAPI() const
Thread API.
JoinEdgeSet::const_iterator getJoinEdgeBegin(const CallICFGNode *cs) const
bool isExtCall(const SVFFunction *fun)
std::ostream & outs()
Overwrite llvm::outs()
std::unordered_set< Key, Hash, KeyEqual, Allocator > Set