Search in sources :

Example 51 with SegmentNode

use of soot.jimple.spark.geom.dataRep.SegmentNode in project soot by Sable.

the class HeapInsIntervalManager method generate_all_to_many.

/**
 * Merge all the ONE_TO_ONE figures pointed to by mp.
 * The result is in the form (p, q, 0, I, L).
 */
private SegmentNode generate_all_to_many(SegmentNode mp) {
    long left, right;
    SegmentNode p;
    left = mp.I2;
    right = left + mp.L;
    p = mp.next;
    while (p != null) {
        if (p.I2 < left)
            left = p.I2;
        long t = p.I2 + p.L;
        if (t > right)
            right = t;
        p = p.next;
    }
    // We reuse the first element in the list mp
    mp.I1 = 0;
    mp.I2 = left;
    mp.L = right - left;
    mp.next = null;
    return mp;
}
Also used : SegmentNode(soot.jimple.spark.geom.dataRep.SegmentNode)

Aggregations

SegmentNode (soot.jimple.spark.geom.dataRep.SegmentNode)51 PlainConstraint (soot.jimple.spark.geom.dataRep.PlainConstraint)24 AllocNode (soot.jimple.spark.pag.AllocNode)12 HashMap (java.util.HashMap)6 Map (java.util.Map)6 RectangleNode (soot.jimple.spark.geom.dataRep.RectangleNode)5 SootMethod (soot.SootMethod)3 GeomPointsTo (soot.jimple.spark.geom.geomPA.GeomPointsTo)3 StringConstantNode (soot.jimple.spark.pag.StringConstantNode)3 ClassConstantNode (soot.jimple.spark.pag.ClassConstantNode)2