/** * Look up an Edge by its id. * * @param id * the id of the edge to look up * @return the Edge, or null if no matching Edge was found */ public Edge lookupEdgeById(int id) { Iterator<Edge> i = edgeIterator(); while (i.hasNext()) { Edge edge = i.next(); if (edge.getId() == id) { return edge; } } return null; }
public List<Edge> getDuplicates(CFG cfg, Edge edge) { InstructionHandle ih = edge.getSource().getLastInstruction(); if(ih == null) { return Collections.emptyList(); } BitSet duplicates = getDuplicates(ih.getPosition()); if(duplicates.isEmpty()) { return Collections.emptyList(); } List<Edge> result = new ArrayList<>(); for(Iterator<Edge> edgeIterator = cfg.edgeIterator(); edgeIterator.hasNext(); ) { Edge next = edgeIterator.next(); if(next.getType() != edge.getType()) { continue; } InstructionHandle lastInst = next.getSource().getLastInstruction(); if(lastInst != null && lastInst.getPosition() >= 0 && duplicates.get(lastInst.getPosition())) { result.add(next); } } return result; }
for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge edge = i.next(); if (!edge.isExceptionEdge()) {
public void checkEdges(CFG cfg, Map<ValueNumber, NullValueUnconditionalDeref> nullValueGuaranteedDerefMap, Map<ValueNumber, SortedSet<Location>> bugEdgeLocationMap) throws DataflowAnalysisException { for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge edge = i.next();
Map<ValueNumber, VariableData> analyzedArguments = new HashMap<>(); Map<Edge, Branch> allEdges = new IdentityHashMap<>(); for (Iterator<Edge> edgeIterator = cfg.edgeIterator(); edgeIterator.hasNext();) { Edge edge = edgeIterator.next(); if (edge.getType() == EdgeTypes.IFCMP_EDGE) {
for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge edge = i.next();
if (ASSUME_ASSERTIONS_ENABLED) { LinkedList<Edge> edgesToRemove = new LinkedList<>(); for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge e = i.next(); if (e.getType() == EdgeTypes.IFCMP_EDGE) {
/** * Look up an Edge by its id. * * @param id * the id of the edge to look up * @return the Edge, or null if no matching Edge was found */ public Edge lookupEdgeById(int id) { Iterator<Edge> i = edgeIterator(); while (i.hasNext()) { Edge edge = i.next(); if (edge.getId() == id) { return edge; } } return null; }
public List<Edge> getDuplicates(CFG cfg, Edge edge) { InstructionHandle ih = edge.getSource().getLastInstruction(); if(ih == null) { return Collections.emptyList(); } BitSet duplicates = getDuplicates(ih.getPosition()); if(duplicates.isEmpty()) { return Collections.emptyList(); } List<Edge> result = new ArrayList<>(); for(Iterator<Edge> edgeIterator = cfg.edgeIterator(); edgeIterator.hasNext(); ) { Edge next = edgeIterator.next(); if(next.getType() != edge.getType()) { continue; } InstructionHandle lastInst = next.getSource().getLastInstruction(); if(lastInst != null && lastInst.getPosition() >= 0 && duplicates.get(lastInst.getPosition())) { result.add(next); } } return result; }
for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge edge = i.next(); if (!edge.isExceptionEdge()) {
public void checkEdges(CFG cfg, Map<ValueNumber, NullValueUnconditionalDeref> nullValueGuaranteedDerefMap, Map<ValueNumber, SortedSet<Location>> bugEdgeLocationMap) throws DataflowAnalysisException { for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge edge = i.next();
Map<ValueNumber, VariableData> analyzedArguments = new HashMap<>(); Map<Edge, Branch> allEdges = new IdentityHashMap<>(); for (Iterator<Edge> edgeIterator = cfg.edgeIterator(); edgeIterator.hasNext();) { Edge edge = edgeIterator.next(); if (edge.getType() == EdgeTypes.IFCMP_EDGE) {
for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge edge = i.next();
if (ASSUME_ASSERTIONS_ENABLED) { LinkedList<Edge> edgesToRemove = new LinkedList<Edge>(); for (Iterator<Edge> i = cfg.edgeIterator(); i.hasNext();) { Edge e = i.next(); if (e.getType() == EdgeTypes.IFCMP_EDGE) {