/** * Copy Constructor for LoopVertex. * * @param that the source object for copying */ public LoopVertex(final LoopVertex that) { super(that); this.compositeTransformFullName = new String(that.compositeTransformFullName); // Copy all elements to the clone final DAG<IRVertex, IREdge> dagToCopy = that.getDAG(); dagToCopy.topologicalDo(v -> { this.getBuilder().addVertex(v, dagToCopy); dagToCopy.getIncomingEdgesOf(v).forEach(this.getBuilder()::connectVertices); }); that.dagIncomingEdges.forEach(((v, es) -> es.forEach(this::addDagIncomingEdge))); that.iterativeIncomingEdges.forEach((v, es) -> es.forEach(this::addIterativeIncomingEdge)); that.nonIterativeIncomingEdges.forEach((v, es) -> es.forEach(this::addNonIterativeIncomingEdge)); that.dagOutgoingEdges.forEach(((v, es) -> es.forEach(this::addDagOutgoingEdge))); that.edgeWithLoopToEdgeWithInternalVertex.forEach((eLoop, eInternal) -> this.mapEdgeWithLoop(eLoop, eInternal)); this.maxNumberOfIterations = that.maxNumberOfIterations; this.terminationCondition = that.terminationCondition; }
/** * Copy Constructor for LoopVertex. * * @param that the source object for copying */ public LoopVertex(final LoopVertex that) { super(that); this.compositeTransformFullName = new String(that.compositeTransformFullName); // Copy all elements to the clone final DAG<IRVertex, IREdge> dagToCopy = that.getDAG(); dagToCopy.topologicalDo(v -> { this.getBuilder().addVertex(v, dagToCopy); dagToCopy.getIncomingEdgesOf(v).forEach(this.getBuilder()::connectVertices); }); that.dagIncomingEdges.forEach(((v, es) -> es.forEach(this::addDagIncomingEdge))); that.iterativeIncomingEdges.forEach((v, es) -> es.forEach(this::addIterativeIncomingEdge)); that.nonIterativeIncomingEdges.forEach((v, es) -> es.forEach(this::addNonIterativeIncomingEdge)); that.dagOutgoingEdges.forEach(((v, es) -> es.forEach(this::addDagOutgoingEdge))); that.edgeWithLoopToEdgeWithInternalVertex.forEach((eLoop, eInternal) -> this.mapEdgeWithLoop(eLoop, eInternal)); this.maxNumberOfIterations = that.maxNumberOfIterations; this.terminationCondition = that.terminationCondition; }
edge.copyExecutionPropertiesTo(newIrEdge); finalRootLoopVertex.addDagOutgoingEdge(newIrEdge); finalRootLoopVertex.mapEdgeWithLoop(loopVertex.getEdgeWithLoop(edge), newIrEdge); }));
edge.copyExecutionPropertiesTo(newIrEdge); finalRootLoopVertex.addDagOutgoingEdge(newIrEdge); finalRootLoopVertex.mapEdgeWithLoop(loopVertex.getEdgeWithLoop(edge), newIrEdge); }));
irEdge.copyExecutionPropertiesTo(edgeToLoop); builder.connectVertices(edgeToLoop); assignedLoopVertex.mapEdgeWithLoop(edgeToLoop, irEdge); irEdge.copyExecutionPropertiesTo(edgeToLoop); builder.connectVertices(edgeToLoop); assignedLoopVertex.mapEdgeWithLoop(edgeToLoop, irEdge);
irEdge.copyExecutionPropertiesTo(edgeToLoop); builder.connectVertices(edgeToLoop); assignedLoopVertex.mapEdgeWithLoop(edgeToLoop, irEdge); irEdge.copyExecutionPropertiesTo(edgeToLoop); builder.connectVertices(edgeToLoop); assignedLoopVertex.mapEdgeWithLoop(edgeToLoop, irEdge);
irEdge.copyExecutionPropertiesTo(edgeFromLoop); builder.connectVertices(edgeFromLoop); srcLoopVertex.mapEdgeWithLoop(edgeFromLoop, irEdge); } else { // connecting outside the composite loop: operator -> operator. builder.connectVertices(irEdge);
irEdge.copyExecutionPropertiesTo(edgeFromLoop); builder.connectVertices(edgeFromLoop); srcLoopVertex.mapEdgeWithLoop(edgeFromLoop, irEdge); } else { // connecting outside the composite loop: operator -> operator. builder.connectVertices(irEdge);