Skip to content

Commit 7663f97

Browse files
committed
disable concatenation in outlining example for now
1 parent 6798732 commit 7663f97

1 file changed

Lines changed: 14 additions & 12 deletions

File tree

examples/how_to_outline.py

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,21 @@ def transform_dag(self, dag):
2525
assert pt.analysis.get_num_call_sites(dag) == Ncalls
2626

2727
dag = pt.tag_all_calls_to_be_inlined(dag)
28-
print("[Pre-concatenation] Number of nodes =",
29-
pt.analysis.get_num_nodes(pt.inline_calls(dag)))
30-
dag = pt.concatenate_calls(
31-
dag,
32-
lambda cs: pt.tags.FunctionIdentifier("foo") in cs.call.function.tags
33-
)
34-
35-
# Test 2: Test that only one call-sites is left post concatentation
36-
assert pt.analysis.get_num_call_sites(dag) == 1
37-
28+
# FIXME: Re-enable this when concatenation is added to pytato
29+
# print("[Pre-concatenation] Number of nodes =",
30+
# pt.analysis.get_num_nodes(pt.inline_calls(dag)))
31+
# dag = pt.concatenate_calls(
32+
# dag,
33+
# lambda cs: pt.tags.FunctionIdentifier("foo") in cs.call.function.tags
34+
# )
35+
#
36+
# # Test 2: Test that only one call-sites is left post concatentation
37+
# assert pt.analysis.get_num_call_sites(dag) == 1
38+
#
39+
# dag = pt.inline_calls(dag)
40+
# print("[Post-concatenation] Number of nodes =",
41+
# pt.analysis.get_num_nodes(dag))
3842
dag = pt.inline_calls(dag)
39-
print("[Post-concatenation] Number of nodes =",
40-
pt.analysis.get_num_nodes(dag))
4143

4244
return dag
4345

0 commit comments

Comments
 (0)