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 2020/01/17 15:42:27 UTC

[GitHub] [incubator-tvm] MarisaKirisame commented on a change in pull request #4693: [runtime][refactor] Unify vm and interpreter objects

MarisaKirisame commented on a change in pull request #4693: [runtime][refactor] Unify vm and interpreter objects
URL: https://github.com/apache/incubator-tvm/pull/4693#discussion_r368000465
 
 

 ##########
 File path: src/relay/backend/interpreter.cc
 ##########
 @@ -774,6 +751,14 @@ class Interpreter :
   // Cache ops that need to be frequently used later to reduce lookup overhead.
   const Op& debug_op_;
   const Op& shape_of_op_;
+  // The free vars captured by the last closure.
+  std::unordered_map<Closure, std::vector<Var>, ObjectHash, ObjectEqual> closure_captured_vars_;
 
 Review comment:
   wait... what?
   closure got it's name because closure store the free variables it need.
   Is there any reason for this design? This is just moving the member from inside the closure to a map.

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


With regards,
Apache Git Services