@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } DagConnection solutionSetInput = this.iterationNode.getFirstIncomingConnection(); OptimizerNode solutionSetSource = solutionSetInput.getSource(); addClosedBranches(solutionSetSource.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = solutionSetSource.getBranchesForParent(solutionSetInput); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } OptimizerNode inputToIteration = this.iterationNode.getPredecessorNode(); addClosedBranches(inputToIteration.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = inputToIteration.getBranchesForParent(this.iterationNode.getIncomingConnection()); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } DagConnection worksetInput = this.iterationNode.getSecondIncomingConnection(); OptimizerNode worksetSource = worksetInput.getSource(); addClosedBranches(worksetSource.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = worksetSource.getBranchesForParent(worksetInput); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
protected List<UnclosedBranchDescriptor> computeUnclosedBranchStackForBroadcastInputs( List<UnclosedBranchDescriptor> branchesSoFar) { // handle the data flow branching for the broadcast inputs for (DagConnection broadcastInput : getBroadcastConnections()) { OptimizerNode bcSource = broadcastInput.getSource(); addClosedBranches(bcSource.closedBranchingNodes); List<UnclosedBranchDescriptor> bcBranches = bcSource.getBranchesForParent(broadcastInput); ArrayList<UnclosedBranchDescriptor> mergedBranches = new ArrayList<UnclosedBranchDescriptor>(); mergeLists(branchesSoFar, bcBranches, mergedBranches, true); branchesSoFar = mergedBranches.isEmpty() ? Collections.<UnclosedBranchDescriptor>emptyList() : mergedBranches; } return branchesSoFar; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } addClosedBranches(getPredecessorNode().closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = getPredecessorNode().getBranchesForParent(this.inConn); // handle the data flow branching for the broadcast inputs List<UnclosedBranchDescriptor> result = computeUnclosedBranchStackForBroadcastInputs(fromInput); this.openBranches = (result == null || result.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : result; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // we need to track open branches even in the sinks, because they get "closed" when // we build a single "root" for the data flow plan addClosedBranches(getPredecessorNode().closedBranchingNodes); this.openBranches = getPredecessorNode().getBranchesForParent(this.input); }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // handle the data flow branching for the regular inputs addClosedBranches(getFirstPredecessorNode().closedBranchingNodes); addClosedBranches(getSecondPredecessorNode().closedBranchingNodes); List<UnclosedBranchDescriptor> result1 = getFirstPredecessorNode().getBranchesForParent(getFirstIncomingConnection()); List<UnclosedBranchDescriptor> result2 = getSecondPredecessorNode().getBranchesForParent(getSecondIncomingConnection()); ArrayList<UnclosedBranchDescriptor> inputsMerged = new ArrayList<UnclosedBranchDescriptor>(); mergeLists(result1, result2, inputsMerged, true); // handle the data flow branching for the broadcast inputs List<UnclosedBranchDescriptor> result = computeUnclosedBranchStackForBroadcastInputs(inputsMerged); this.openBranches = (result == null || result.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : result; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // IMPORTANT: First compute closed branches from the two inputs // we need to do this because the runtime iteration head effectively joins addClosedBranches(getFirstPredecessorNode().closedBranchingNodes); addClosedBranches(getSecondPredecessorNode().closedBranchingNodes); List<UnclosedBranchDescriptor> result1 = getFirstPredecessorNode().getBranchesForParent(getFirstIncomingConnection()); List<UnclosedBranchDescriptor> result2 = getSecondPredecessorNode().getBranchesForParent(getSecondIncomingConnection()); ArrayList<UnclosedBranchDescriptor> inputsMerged1 = new ArrayList<UnclosedBranchDescriptor>(); mergeLists(result1, result2, inputsMerged1, true); // this method also sets which branches are joined here (in the head) addClosedBranches(getSingleRootOfStepFunction().closedBranchingNodes); ArrayList<UnclosedBranchDescriptor> inputsMerged2 = new ArrayList<UnclosedBranchDescriptor>(); List<UnclosedBranchDescriptor> result3 = getSingleRootOfStepFunction().openBranches; mergeLists(inputsMerged1, result3, inputsMerged2, true); // handle the data flow branching for the broadcast inputs List<UnclosedBranchDescriptor> result = computeUnclosedBranchStackForBroadcastInputs(inputsMerged2); this.openBranches = (result == null || result.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : result; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } OptimizerNode inputToIteration = this.iterationNode.getPredecessorNode(); addClosedBranches(inputToIteration.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = inputToIteration.getBranchesForParent(this.iterationNode.getIncomingConnection()); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } DagConnection worksetInput = this.iterationNode.getSecondIncomingConnection(); OptimizerNode worksetSource = worksetInput.getSource(); addClosedBranches(worksetSource.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = worksetSource.getBranchesForParent(worksetInput); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } DagConnection solutionSetInput = this.iterationNode.getFirstIncomingConnection(); OptimizerNode solutionSetSource = solutionSetInput.getSource(); addClosedBranches(solutionSetSource.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = solutionSetSource.getBranchesForParent(solutionSetInput); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } DagConnection solutionSetInput = this.iterationNode.getFirstIncomingConnection(); OptimizerNode solutionSetSource = solutionSetInput.getSource(); addClosedBranches(solutionSetSource.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = solutionSetSource.getBranchesForParent(solutionSetInput); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } OptimizerNode inputToIteration = this.iterationNode.getPredecessorNode(); addClosedBranches(inputToIteration.closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = inputToIteration.getBranchesForParent(this.iterationNode.getIncomingConnection()); this.openBranches = (fromInput == null || fromInput.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : fromInput; } }
protected List<UnclosedBranchDescriptor> computeUnclosedBranchStackForBroadcastInputs( List<UnclosedBranchDescriptor> branchesSoFar) { // handle the data flow branching for the broadcast inputs for (DagConnection broadcastInput : getBroadcastConnections()) { OptimizerNode bcSource = broadcastInput.getSource(); addClosedBranches(bcSource.closedBranchingNodes); List<UnclosedBranchDescriptor> bcBranches = bcSource.getBranchesForParent(broadcastInput); ArrayList<UnclosedBranchDescriptor> mergedBranches = new ArrayList<UnclosedBranchDescriptor>(); mergeLists(branchesSoFar, bcBranches, mergedBranches, true); branchesSoFar = mergedBranches.isEmpty() ? Collections.<UnclosedBranchDescriptor>emptyList() : mergedBranches; } return branchesSoFar; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } addClosedBranches(getPredecessorNode().closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = getPredecessorNode().getBranchesForParent(this.inConn); // handle the data flow branching for the broadcast inputs List<UnclosedBranchDescriptor> result = computeUnclosedBranchStackForBroadcastInputs(fromInput); this.openBranches = (result == null || result.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : result; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } addClosedBranches(getPredecessorNode().closedBranchingNodes); List<UnclosedBranchDescriptor> fromInput = getPredecessorNode().getBranchesForParent(this.inConn); // handle the data flow branching for the broadcast inputs List<UnclosedBranchDescriptor> result = computeUnclosedBranchStackForBroadcastInputs(fromInput); this.openBranches = (result == null || result.isEmpty()) ? Collections.<UnclosedBranchDescriptor>emptyList() : result; }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // we need to track open branches even in the sinks, because they get "closed" when // we build a single "root" for the data flow plan addClosedBranches(getPredecessorNode().closedBranchingNodes); this.openBranches = getPredecessorNode().getBranchesForParent(this.input); }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // we need to track open branches even in the sinks, because they get "closed" when // we build a single "root" for the data flow plan addClosedBranches(getPredecessorNode().closedBranchingNodes); this.openBranches = getPredecessorNode().getBranchesForParent(this.input); }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // we need to track open branches even in the sinks, because they get "closed" when // we build a single "root" for the data flow plan addClosedBranches(getPredecessorNode().closedBranchingNodes); this.openBranches = getPredecessorNode().getBranchesForParent(this.input); }
@Override public void computeUnclosedBranchStack() { if (this.openBranches != null) { return; } // we need to track open branches even in the sinks, because they get "closed" when // we build a single "root" for the data flow plan addClosedBranches(getPredecessorNode().closedBranchingNodes); this.openBranches = getPredecessorNode().getBranchesForParent(this.input); }