Package soot.jimple.spark.geom.heapinsE
Class HeapInsNode
- java.lang.Object
-
- soot.jimple.spark.geom.geomPA.IVarAbstraction
-
- soot.jimple.spark.geom.heapinsE.HeapInsNode
-
- All Implemented Interfaces:
Numberable
public class HeapInsNode extends IVarAbstraction
This class defines a pointer variable for use in the HeapIns encoding based points-to solver. HeapIns is a simpler form of geometric encoding. HeapIns is faster and uses less memory, but also, it is less precise than geometric encoding. NOT recommended to use.- Author:
- xiao
-
-
Field Summary
Fields Modifier and Type Field Description Vector<PlainConstraint>complex_consHashMap<HeapInsNode,HeapInsIntervalManager>flowtoMap<AllocNode,HeapInsIntervalManager>new_ptsHashMap<AllocNode,HeapInsIntervalManager>pt_objs-
Fields inherited from class soot.jimple.spark.geom.geomPA.IVarAbstraction
deadManager, id, lrf_value, me, parent, pres, Qpos, stubManager, top_value, willUpdate
-
-
Constructor Summary
Constructors Constructor Description HeapInsNode(Node thisVar)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanadd_points_to_3(AllocNode obj, long I1, long I2, long L)booleanadd_points_to_4(AllocNode obj, long I1, long I2, long L1, long L2)booleanadd_simple_constraint_3(IVarAbstraction qv, long I1, long I2, long L)booleanadd_simple_constraint_4(IVarAbstraction qv, long I1, long I2, long L1, long L2)intcount_flow_intervals(IVarAbstraction qv)intcount_new_pts_intervals()intcount_pts_intervals(AllocNode obj)voiddeleteAll()voiddo_after_propagation()Remember to clean the is_new flagvoiddo_before_propagation()voiddrop_duplicates()Discard all the ONE_TO_ONE figures which are covered by the ALL_TO_MANY and MANY_TO_ALL figuresvoidget_all_context_sensitive_objects(long l, long r, PtSensVisitor visitor)Given the pointers falling in the context range [l, r), we compute the set of context sensitive objects pointed to by those pointers.Set<AllocNode>get_all_points_to_objects()Obtain context insensitive points-to result (by removing contexts).booleanheap_sensitive_intersection(IVarAbstraction qv)Query if this pointer and qv could point to the same object under any contextsvoidinjectPts()booleanisDeadObject(AllocNode obj)Test if the particular object has been obsoleted.voidkeepPointsToOnly()intnum_of_diff_edges()intnum_of_diff_objs()Return -1 if this pointer does not have points-to information.booleanpointer_interval_points_to(long l, long r, AllocNode obj)Test if the pointer in the context range [l, R) points to object obj.voidprint_context_sensitive_points_to(PrintStream outPrintStream)voidpropagate(GeomPointsTo ptAnalyzer, IWorklist worklist)An efficient implementation of differential propagation.voidput_complex_constraint(PlainConstraint cons)voidreconstruct()voidremove_points_to(AllocNode obj)-
Methods inherited from class soot.jimple.spark.geom.geomPA.IVarAbstraction
enclosingMethod, getNumber, getRepresentative, getType, getWrappedNode, hasPTResult, isLocalPointer, lessThan, merge, reachable, setNumber, toString
-
-
-
-
Field Detail
-
flowto
public HashMap<HeapInsNode,HeapInsIntervalManager> flowto
-
pt_objs
public HashMap<AllocNode,HeapInsIntervalManager> pt_objs
-
new_pts
public Map<AllocNode,HeapInsIntervalManager> new_pts
-
complex_cons
public Vector<PlainConstraint> complex_cons
-
-
Constructor Detail
-
HeapInsNode
public HeapInsNode(Node thisVar)
-
-
Method Detail
-
deleteAll
public void deleteAll()
- Specified by:
deleteAllin classIVarAbstraction
-
reconstruct
public void reconstruct()
- Specified by:
reconstructin classIVarAbstraction
-
do_before_propagation
public void do_before_propagation()
- Specified by:
do_before_propagationin classIVarAbstraction
-
do_after_propagation
public void do_after_propagation()
Remember to clean the is_new flag- Specified by:
do_after_propagationin classIVarAbstraction
-
num_of_diff_objs
public int num_of_diff_objs()
Description copied from class:IVarAbstractionReturn -1 if this pointer does not have points-to information. This function can be used for testing if the pointer has been processed by geomPTA.- Specified by:
num_of_diff_objsin classIVarAbstraction
-
num_of_diff_edges
public int num_of_diff_edges()
- Specified by:
num_of_diff_edgesin classIVarAbstraction
-
add_points_to_3
public boolean add_points_to_3(AllocNode obj, long I1, long I2, long L)
- Specified by:
add_points_to_3in classIVarAbstraction
-
add_points_to_4
public boolean add_points_to_4(AllocNode obj, long I1, long I2, long L1, long L2)
- Specified by:
add_points_to_4in classIVarAbstraction
-
add_simple_constraint_3
public boolean add_simple_constraint_3(IVarAbstraction qv, long I1, long I2, long L)
- Specified by:
add_simple_constraint_3in classIVarAbstraction
-
add_simple_constraint_4
public boolean add_simple_constraint_4(IVarAbstraction qv, long I1, long I2, long L1, long L2)
- Specified by:
add_simple_constraint_4in classIVarAbstraction
-
put_complex_constraint
public void put_complex_constraint(PlainConstraint cons)
- Specified by:
put_complex_constraintin classIVarAbstraction
-
drop_duplicates
public void drop_duplicates()
Discard all the ONE_TO_ONE figures which are covered by the ALL_TO_MANY and MANY_TO_ALL figures- Specified by:
drop_duplicatesin classIVarAbstraction
-
propagate
public void propagate(GeomPointsTo ptAnalyzer, IWorklist worklist)
An efficient implementation of differential propagation.- Specified by:
propagatein classIVarAbstraction
-
count_pts_intervals
public int count_pts_intervals(AllocNode obj)
- Specified by:
count_pts_intervalsin classIVarAbstraction
-
count_flow_intervals
public int count_flow_intervals(IVarAbstraction qv)
- Specified by:
count_flow_intervalsin classIVarAbstraction
-
heap_sensitive_intersection
public boolean heap_sensitive_intersection(IVarAbstraction qv)
Query if this pointer and qv could point to the same object under any contexts- Specified by:
heap_sensitive_intersectionin classIVarAbstraction- Returns:
-
get_all_points_to_objects
public Set<AllocNode> get_all_points_to_objects()
Description copied from class:IVarAbstractionObtain context insensitive points-to result (by removing contexts).- Specified by:
get_all_points_to_objectsin classIVarAbstraction- Returns:
-
print_context_sensitive_points_to
public void print_context_sensitive_points_to(PrintStream outPrintStream)
- Specified by:
print_context_sensitive_points_toin classIVarAbstraction
-
pointer_interval_points_to
public boolean pointer_interval_points_to(long l, long r, AllocNode obj)Description copied from class:IVarAbstractionTest if the pointer in the context range [l, R) points to object obj.- Specified by:
pointer_interval_points_toin classIVarAbstraction- Returns:
-
remove_points_to
public void remove_points_to(AllocNode obj)
- Specified by:
remove_points_toin classIVarAbstraction
-
keepPointsToOnly
public void keepPointsToOnly()
- Specified by:
keepPointsToOnlyin classIVarAbstraction
-
count_new_pts_intervals
public int count_new_pts_intervals()
- Specified by:
count_new_pts_intervalsin classIVarAbstraction
-
get_all_context_sensitive_objects
public void get_all_context_sensitive_objects(long l, long r, PtSensVisitor visitor)Description copied from class:IVarAbstractionGiven the pointers falling in the context range [l, r), we compute the set of context sensitive objects pointed to by those pointers. This function is designed in visitor pattern.- Specified by:
get_all_context_sensitive_objectsin classIVarAbstraction- See Also:
Obj_1cfa_extractor,Obj_full_extractor
-
injectPts
public void injectPts()
- Specified by:
injectPtsin classIVarAbstraction
-
isDeadObject
public boolean isDeadObject(AllocNode obj)
Description copied from class:IVarAbstractionTest if the particular object has been obsoleted. It's mainly for points-to developer use.- Specified by:
isDeadObjectin classIVarAbstraction- Returns:
-
-