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/02/24 18:46:15 UTC

[GitHub] [tvm] areusch commented on a change in pull request #10311: [Draft][runtime][Hexagon] AOTExecutor implementation for C Codegen

areusch commented on a change in pull request #10311:
URL: https://github.com/apache/tvm/pull/10311#discussion_r814167425



##########
File path: src/runtime/hexagon/hexagon/hexagon_device_api_v2.cc
##########
@@ -82,7 +82,11 @@ void* HexagonDeviceAPIv2::AllocDataSpace(Device dev, size_t nbytes, size_t align
 }
 
 void HexagonDeviceAPIv2::FreeDataSpace(Device dev, void* ptr) {
-  CHECK(TVMDeviceExtType(dev.device_type) == kDLHexagon);
+  bool device = false;
+  if ((TVMDeviceExtType(dev.device_type) == kDLHexagon) || (DLDeviceType(dev.device_type) == kDLCPU)) {

Review comment:
       on AOT we currently require device_type == kDLCPU. this hack seems consistent with the previous approach to patch the CPU device with Hexagon. we could add a comment here to explain. 
   
   imo we should take up the issue of what device type to actually use here when we address the compilation path for Hexagon code.




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