comaniac commented on issue #5409:
URL: https://github.com/apache/incubator-tvm/pull/5409#issuecomment-618537434


   Ah I see your point. I missed considering that `ConstantNode` is also a 
"node" instead of a "var". I agree with you that constant nodes should follow 
the target of the consuming node and the output you illustrated makes sense to 
me. On the other hand, it'd be better to maintain the statement of "annotating 
every node" of `AnnotateTarget` pass. A similar case is `TupleNode`. We 
determine the target of tuple nodes by looking at its arguments, and still 
annotate it whatever it should be at the TVM or other targets. In summary, I'd 
prefer the following annotation generated by `AnnotateTarget`:
   
   ```
   input
     |
   begin
     |
    op -- begin -- end -- const -- begin
     |
    end
   ```
   
   instead of
   
   ```
   input
     |
   begin
     |
    op -- const
     |
    end
   ```
   
   This can naturally guarantee that this change will not affect the rest BYOC 
flow.
   


----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to