svf-lib 1.0.1841 → 1.0.1843

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -88,8 +88,18 @@ public:
88
88
  if((*outedge)->getEdgeKind() == graph->getStartKind())
89
89
  {
90
90
  // Need to Find dst addr src
91
- CFLNode *vNode = graph->getGNode((*outedge)->getDstID());
92
- addPts(ptr, svfir->getBaseValVar((*outedge)->getDstID()));
91
+ SVFVar *vNode = svfir->getGNode((*outedge)->getDstID());
92
+ NodeID basevNodeID;
93
+ // Remove svfir->getBaseValVar, SVF IR api change
94
+ if (vNode->hasIncomingEdges(SVFStmt::Gep))
95
+ {
96
+ SVFStmt::SVFStmtSetTy& geps = vNode->getIncomingEdges(SVFStmt::Gep);
97
+ SVFVar::iterator it = geps.begin();
98
+ basevNodeID = (*it)->getSrcID();
99
+ }
100
+ else
101
+ basevNodeID = vNode->getId();
102
+ addPts(ptr, basevNodeID);
93
103
  for(auto inEdge = vNode->getInEdges().begin(); inEdge!=vNode->getInEdges().end(); inEdge++)
94
104
  {
95
105
  if((*inEdge)->getEdgeKind() == 0)
@@ -439,7 +439,6 @@ public:
439
439
  /// Base and Offset methods for Value and Object node
440
440
  //@{
441
441
  /// Get a base pointer node given a field pointer
442
- NodeID getBaseValVar(NodeID nodeId);
443
442
  inline NodeID getBaseObjVar(NodeID id) const
444
443
  {
445
444
  return getBaseObj(id)->getId();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "svf-lib",
3
- "version": "1.0.1841",
3
+ "version": "1.0.1843",
4
4
  "description": "SVF's npm support",
5
5
  "main": "index.js",
6
6
  "scripts": {