You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/07/23 13:45:46 UTC

[GitHub] [tvm] Hzfengsy commented on a diff in pull request #12138: [FIX,TIR] Handle LetStmt in EstimateTIRFLops

Hzfengsy commented on code in PR #12138:
URL: https://github.com/apache/tvm/pull/12138#discussion_r928125306


##########
tests/python/unittest/test_tir_analysis_estimate_tir_flops.py:
##########
@@ -48,5 +50,16 @@ def test_te_workload(workload, flops):
     assert float(flops) == estimate_tir_flops(mod)
 
 
+@T.prim_func
+def flops_with_let(a: T.Buffer[16, "float32"]):
+    for i in range(8):
+        j = i + 8
+        a[j] = a[i]
+
+
+def test_flops_with_let():
+    estimate_tir_flops(IRModule({"main": flops_with_let}))

Review Comment:
   Could you please add an `assert` to check the flops number?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org