Skip to content

Commit

Permalink
Merge pull request #111 from coneoproject/graph-dict
Browse files Browse the repository at this point in the history
* graph-dict:
  avoid key shuffling with networkx.Graph
  • Loading branch information
wence- committed Dec 16, 2016
2 parents 5a39a14 + 9f5050b commit 87e5078
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion coffee/rewriter.py
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ def sharing_graph_rewrite(self):
self.licm('only_const').licm('only_outlinear')

# Transform the expression based on the sharing graph
nodes, edges = sgraph.nodes(), sgraph.edges()
nodes = [n for n in nodes if n in sgraph.nodes()]
if not (nodes and all(sgraph.degree(n) > 0 for n in nodes)):
self.factorize(mode='heuristic')
self.licm('only_const').licm('only_outlinear')
Expand Down

0 comments on commit 87e5078

Please sign in to comment.