MCPcopy Create free account
hub / github.com/SVF-tools/SVF / getJoinedThread

Method getJoinedThread

svf/lib/Util/ThreadAPI.cpp:219–233  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

217}
218
219const SVFVar* ThreadAPI::getJoinedThread(const CallICFGNode *cs) const
220{
221 assert(isTDJoin(cs) && "not a thread join function!");
222 const ValVar* join = cs->getArgument(0);
223 for(const SVFStmt* stmt : join->getInEdges())
224 {
225 if(SVFUtil::isa<LoadStmt>(stmt))
226 return stmt->getSrcNode();
227 }
228 if(SVFUtil::isa<ArgValVar>(join))
229 return join;
230
231 assert(false && "the value of the first argument at join is not a load instruction?");
232 return nullptr;
233}
234
235/*!
236 *

Callers 1

updateJoinEdgeMethod · 0.45

Calls 2

getArgumentMethod · 0.80
getSrcNodeMethod · 0.45

Tested by

no test coverage detected