tvm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [incubator-tvm] masahi commented on a change in pull request #5493: [REFACTOR][BOYC] Non recursive partitioning
Date Fri, 01 May 2020 12:00:12 GMT

masahi commented on a change in pull request #5493:
URL: https://github.com/apache/incubator-tvm/pull/5493#discussion_r418514358



##########
File path: src/relay/transforms/partition_graph.cc
##########
@@ -470,115 +353,82 @@ class Partitioner : public ExprMutator {
   Expr GetFunctionOutput(AnnotatedRegion region, const Expr& end_arg) {
     Expr arg = Downcast<Call>(end_arg)->args[0];
     // Function has one output.
-    if (region_return_indices_[region].size() == 1) {
-      return region_function_calls[region];
+    if (region_func_meta_[region].out_expr_indices.size() == 1) {
+      return region_func_meta_[region].func_call;
     }
+
     // Function has multiple outputs.
     // Use already made TupleGetItem.
-    if (region_return_tuplegetitem_.count(region) &&
-        region_return_tuplegetitem_[region].count(arg)) {
-      return region_return_tuplegetitem_[region][arg];
+    if (region_func_meta_[region].out_expr_indices.count(arg) &&

Review comment:
       The first condition is redundant since you have 
   
   ```
   CHECK(region_func_meta_[region].out_expr_indices.count(arg))
   ```
   below.




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



Mime
View raw message