Mousius commented on a change in pull request #9500:
URL: https://github.com/apache/tvm/pull/9500#discussion_r749395869



##########
File path: src/relay/backend/aot_executor_codegen.cc
##########
@@ -426,6 +434,44 @@ class AOTExecutorCodegen : public MixedModeVisitor {
     }
   }
 
+  /**
+   * \brief Generates a call to a given hook for all Devices found for C 
Device API
+   * \param Name of hook to generate statements for
+   * \return Statement with function calls for each device
+   */
+  tir::Stmt GenerateAllDeviceHook(const String& hook) {
+    std::vector<tir::Stmt> device_activations;
+    for (const auto& it : devices_) {
+      const String& device_name = it.first;
+      const tir::Var& context = it.second;
+      Array<String> sections = {"Device", device_name, hook};
+      String device_activation = ToCFunctionStyle(PrefixName(sections));

Review comment:
       This should be `device_hook` 




-- 
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