MCPcopy Create free account
hub / github.com/apache/tvm / test_stmt_expr_mutator

Function test_stmt_expr_mutator

tests/python/tirx/transform/test_stmt_functor.py:984–992  ·  view source on GitHub ↗

Test StmtExprMutator.

()

Source from the content-addressed store, hash-verified

982
983
984def test_stmt_expr_mutator():
985 """Test StmtExprMutator."""
986 evaluate_stmt = create_test_statements()["evaluate"]
987 mutator = StmtExprMutatorPrinter()
988 result = mutator.visit_stmt(evaluate_stmt)
989 tvm.ir.assert_structural_equal(result, evaluate_stmt)
990
991 expected = "\n".join(["Var", "IntImm", "Add", "Evaluate"])
992 assert str(mutator.log) == expected
993
994
995def test_stmt_expr_visitor():

Callers

nothing calls this directly

Calls 5

strFunction · 0.85
create_test_statementsFunction · 0.70
visit_stmtMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…