icemelon9 commented on a change in pull request #7797:
URL: https://github.com/apache/tvm/pull/7797#discussion_r616072697



##########
File path: include/tvm/runtime/profiling.h
##########
@@ -151,6 +151,54 @@ Timer DefaultTimer(Device dev);
 
 namespace profiling {
 
+/*! \brief Data collected from a profiling run. Includes per-call metrics and 
overall metrics.
+ */
+class ReportNode : public Object {
+ public:
+  /*! \brief A list of function calls and the metrics recorded for that call.
+   *
+   * Each element is a mapping from metric name to value. Some metrics that
+   * appear in every call are "Name" (the function name), "Argument Shapes",
+   * and "Duration (us)". Values are one of `String`, `PercentNode`,
+   * `DurationNode`, or `CountNode`.
+   */
+  Array<Map<String, ObjectRef>> calls;
+  /*! \brief Metrics collected for the entire run of the model on a per-device 
basis.
+   *
+   * `overall` is indexed by device name then metric.
+   *
+   * These metrics may be larger than the sum of the same metric in `calls`
+   * because these metrics include the overhead of the executor.
+   */
+  Map<String, Map<String, ObjectRef>> overall;

Review comment:
       I think the `overall` name is too general. Maybe call it 
`device_metrics` since it collects the metrics per device.




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


Reply via email to