Lunderberg commented on code in PR #15103:
URL: https://github.com/apache/tvm/pull/15103#discussion_r1285218031


##########
tests/python/relay/aot/test_crt_forward_declarations.py:
##########
@@ -160,8 +160,8 @@ def test_internal_calls(interface_api, use_unpacked_api, 
test_runner):
 
     lib_mod = compiled_models[0].executor_factory.lib.imported_modules[0]
     main_source = lib_mod.get_source()
-    assert main_source.count("int32_t 
tvmgen_default_fused_nn_contrib_depthwise_conv2d_NCHWc") == 1
-    assert main_source.count("int32_t tvmgen_default_fused_layout_transform") 
== 3
+    assert main_source.count("int32_t 
tvmgen_default_fused_nn_contrib_depthwise_conv2d_NCHWc") == 2
+    assert main_source.count("int32_t tvmgen_default_fused_layout_transform") 
== 6

Review Comment:
   That is correct.  The string appears once for the function declaration and 
once for the definition.  The codegen is simpler if every function is 
forward-declared, not just those that are called from within the IRModule, so 
the count needed to be updated.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to