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 2021/06/18 21:15:10 UTC

[GitHub] [tvm] mehrdadh commented on a change in pull request #8259: [Graph Debug Executor] Fix device_type for profile command

mehrdadh commented on a change in pull request #8259:
URL: https://github.com/apache/tvm/pull/8259#discussion_r654012924



##########
File path: src/runtime/graph_executor/debug/graph_executor_debug.cc
##########
@@ -300,7 +306,8 @@ class GraphExecutorDebug : public GraphExecutor {
         }
 
         uint32_t eid = entry_id(i, 0);
-        const Device& dev = data_entry_[eid]->device;
+        Device dev = data_entry_[eid]->device;
+        dev.device_type = static_cast<DLDeviceType>(dev.device_type % kRPCSessMask);

Review comment:
       So the reason that I did this way is that [RPC client](https://github.com/apache/tvm/blob/1c251f50ee616507bdfd8866408e7acf9888cc3f/python/tvm/rpc/client.py#L75) adds an encoding to device type which we need to decode somehow when is used in graph_executor_debugger. I'm not sure if this is the best place to remove encoding.




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

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