public void newSideEffect(AbstractOperator<PointsToSetVariable> op, PointerKey arg0, PointerKey arg1) { if (DEBUG) { System.err.println("add constraint D: " + op + ' ' + arg0); } assert !pointsToMap.isUnified(arg0); assert !pointsToMap.isUnified(arg1); PointsToSetVariable v1 = findOrCreatePointsToSet(arg0); PointsToSetVariable v2 = findOrCreatePointsToSet(arg1); newStatement(null, op, v1, v2, true, true); }
public void newSideEffect(AbstractOperator<PointsToSetVariable> op, PointerKey arg0, PointerKey arg1) { if (DEBUG) { System.err.println("add constraint D: " + op + ' ' + arg0); } assert !pointsToMap.isUnified(arg0); assert !pointsToMap.isUnified(arg1); PointsToSetVariable v1 = findOrCreatePointsToSet(arg0); PointsToSetVariable v2 = findOrCreatePointsToSet(arg1); newStatement(null, op, v1, v2, true, true); }
public void newSideEffect(UnaryOperator<PointsToSetVariable> op, PointerKey arg0) { if (arg0 == null) { throw new IllegalArgumentException("null arg0"); } if (DEBUG) { System.err.println("add constraint D: " + op + ' ' + arg0); } assert !pointsToMap.isUnified(arg0); PointsToSetVariable v1 = findOrCreatePointsToSet(arg0); newStatement(null, op, v1, true, true); }
public void newSideEffect(AbstractOperator<PointsToSetVariable> op, PointerKey[] arg0) { if (arg0 == null) { throw new IllegalArgumentException("null arg0"); } if (DEBUG) { System.err.println("add constraint D: " + op + ' ' + Arrays.toString(arg0)); } PointsToSetVariable[] vs = new PointsToSetVariable[ arg0.length ]; for(int i = 0; i < arg0.length; i++) { assert !pointsToMap.isUnified(arg0[i]); vs[i] = findOrCreatePointsToSet(arg0[i]); } newStatement(null, op, vs, true, true); }
public void newSideEffect(UnaryOperator<PointsToSetVariable> op, PointerKey arg0) { if (arg0 == null) { throw new IllegalArgumentException("null arg0"); } if (DEBUG) { System.err.println("add constraint D: " + op + ' ' + arg0); } assert !pointsToMap.isUnified(arg0); PointsToSetVariable v1 = findOrCreatePointsToSet(arg0); newStatement(null, op, v1, true, true); }
public void newSideEffect(AbstractOperator<PointsToSetVariable> op, PointerKey[] arg0) { if (arg0 == null) { throw new IllegalArgumentException("null arg0"); } if (DEBUG) { System.err.println("add constraint D: " + op + ' ' + Arrays.toString(arg0)); } PointsToSetVariable[] vs = new PointsToSetVariable[ arg0.length ]; for(int i = 0; i < arg0.length; i++) { assert !pointsToMap.isUnified(arg0[i]); vs[i] = findOrCreatePointsToSet(arg0[i]); } newStatement(null, op, vs, true, true); }
public boolean newConstraint(PointerKey lhs, AbstractOperator<PointsToSetVariable> op, PointerKey rhs) { if (lhs == null) { throw new IllegalArgumentException("lhs null"); } if (op == null) { throw new IllegalArgumentException("op null"); } if (rhs == null) { throw new IllegalArgumentException("rhs null"); } if (DEBUG) { System.err.println("Add constraint A: " + lhs + ' ' + op + ' ' + rhs); } assert !pointsToMap.isUnified(lhs); assert !pointsToMap.isUnified(rhs); PointsToSetVariable L = findOrCreatePointsToSet(lhs); PointsToSetVariable R = findOrCreatePointsToSet(rhs); return newStatement(L, op, new PointsToSetVariable[] { R }, true, true); }
public boolean newConstraint(PointerKey lhs, AbstractOperator<PointsToSetVariable> op, PointerKey rhs1, PointerKey rhs2) { if (lhs == null) { throw new IllegalArgumentException("null lhs"); } if (op == null) { throw new IllegalArgumentException("null op"); } if (rhs1 == null) { throw new IllegalArgumentException("null rhs1"); } if (rhs2 == null) { throw new IllegalArgumentException("null rhs2"); } if (DEBUG) { System.err.println("Add constraint A: " + lhs + ' ' + op + ' ' + rhs1 + ", " + rhs2); } assert !pointsToMap.isUnified(lhs); assert !pointsToMap.isUnified(rhs1); assert !pointsToMap.isUnified(rhs2); PointsToSetVariable L = findOrCreatePointsToSet(lhs); PointsToSetVariable R1 = findOrCreatePointsToSet(rhs1); PointsToSetVariable R2 = findOrCreatePointsToSet(rhs2); return newStatement(L, op, R1, R2, true, true); }
public boolean newConstraint(PointerKey lhs, AbstractOperator<PointsToSetVariable> op, PointerKey rhs1, PointerKey rhs2) { if (lhs == null) { throw new IllegalArgumentException("null lhs"); } if (op == null) { throw new IllegalArgumentException("null op"); } if (rhs1 == null) { throw new IllegalArgumentException("null rhs1"); } if (rhs2 == null) { throw new IllegalArgumentException("null rhs2"); } if (DEBUG) { System.err.println("Add constraint A: " + lhs + ' ' + op + ' ' + rhs1 + ", " + rhs2); } assert !pointsToMap.isUnified(lhs); assert !pointsToMap.isUnified(rhs1); assert !pointsToMap.isUnified(rhs2); PointsToSetVariable L = findOrCreatePointsToSet(lhs); PointsToSetVariable R1 = findOrCreatePointsToSet(rhs1); PointsToSetVariable R2 = findOrCreatePointsToSet(rhs2); return newStatement(L, op, R1, R2, true, true); }
public boolean newConstraint(PointerKey lhs, AbstractOperator<PointsToSetVariable> op, PointerKey rhs) { if (lhs == null) { throw new IllegalArgumentException("lhs null"); } if (op == null) { throw new IllegalArgumentException("op null"); } if (rhs == null) { throw new IllegalArgumentException("rhs null"); } if (DEBUG) { System.err.println("Add constraint A: " + lhs + ' ' + op + ' ' + rhs); } assert !pointsToMap.isUnified(lhs); assert !pointsToMap.isUnified(rhs); PointsToSetVariable L = findOrCreatePointsToSet(lhs); PointsToSetVariable R = findOrCreatePointsToSet(rhs); return newStatement(L, op, new PointsToSetVariable[] { R }, true, true); }
protected IntSet getParamObjects(int paramIndex, @SuppressWarnings("unused") int rhsi) { int paramVn = call.getUse(paramIndex); PointerKey var = getPointerKeyForLocal(caller, paramVn); IntSet s = system.findOrCreatePointsToSet(var).getValue(); return s; } }
protected IntSet getParamObjects(int paramIndex, @SuppressWarnings("unused") int rhsi) { int paramVn = call.getUse(paramIndex); PointerKey var = getPointerKeyForLocal(caller, paramVn); IntSet s = system.findOrCreatePointsToSet(var).getValue(); return s; } }
System.err.println("Add constraint A: " + lhs + ' ' + op + ' ' + rhs); PointsToSetVariable L = findOrCreatePointsToSet(lhs); PointsToSetVariable R = findOrCreatePointsToSet(rhs); if (op instanceof FilterOperator) {
System.err.println("Add constraint A: " + lhs + ' ' + op + ' ' + rhs); PointsToSetVariable L = findOrCreatePointsToSet(lhs); PointsToSetVariable R = findOrCreatePointsToSet(rhs); if (op instanceof FilterOperator) {
PointsToSetVariable FV = system.findOrCreatePointsToSet(F); if (FV.getValue() != null) { FV.getValue().foreach(ptr -> {
PointsToSetVariable L = findOrCreatePointsToSet(lhs); int index = findOrCreateIndexForInstanceKey(value); if (!L.add(index)) {
PointsToSetVariable L = findOrCreatePointsToSet(lhs); int index = findOrCreateIndexForInstanceKey(value); if (!L.add(index)) {
protected void doVisitArrayLoad(int def, int arrayRef) { PointerKey result = getPointerKeyForLocal(def); PointerKey arrayRefPtrKey = getPointerKeyForLocal(arrayRef); if (hasNoInterestingUses(def)) { system.recordImplicitPointsToSet(result); } else { if (contentsAreInvariant(symbolTable, du, arrayRef)) { system.recordImplicitPointsToSet(arrayRefPtrKey); InstanceKey[] ik = getInvariantContents(arrayRef); for (int i = 0; i < ik.length; i++) { if (!representsNullType(ik[i])) { system.findOrCreateIndexForInstanceKey(ik[i]); PointerKey p = getPointerKeyForArrayContents(ik[i]); if (p == null) { } else { system.newConstraint(result, assignOperator, p); } } } } else { assert !system.isUnified(result); assert !system.isUnified(arrayRefPtrKey); system.newSideEffect(getBuilder().new ArrayLoadOperator(system.findOrCreatePointsToSet(result)), arrayRefPtrKey); } } }
protected void doVisitArrayLoad(int def, int arrayRef) { PointerKey result = getPointerKeyForLocal(def); PointerKey arrayRefPtrKey = getPointerKeyForLocal(arrayRef); if (hasNoInterestingUses(def)) { system.recordImplicitPointsToSet(result); } else { if (contentsAreInvariant(symbolTable, du, arrayRef)) { system.recordImplicitPointsToSet(arrayRefPtrKey); InstanceKey[] ik = getInvariantContents(arrayRef); for (int i = 0; i < ik.length; i++) { if (!representsNullType(ik[i])) { system.findOrCreateIndexForInstanceKey(ik[i]); PointerKey p = getPointerKeyForArrayContents(ik[i]); if (p == null) { } else { system.newConstraint(result, assignOperator, p); } } } } else { assert !system.isUnified(result); assert !system.isUnified(arrayRefPtrKey); system.newSideEffect(getBuilder().new ArrayLoadOperator(system.findOrCreatePointsToSet(result)), arrayRefPtrKey); } } }
System.err.println("adding side effect " + f); system.newSideEffect(getBuilder().new PutFieldOperator(f, system.findOrCreatePointsToSet(rvalKey)), refKey);