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/02/05 18:53:07 UTC

[GitHub] [tvm] altanh opened a new pull request #7416: [Relay][BBNF] Lift nodes used across scope for basic block normal form

altanh opened a new pull request #7416:
URL: https://github.com/apache/tvm/pull/7416


   Previously, the following program was considered valid BBNF (by the BBNF checker)
   ```
   #[version = "0.0.5"]
   def @main(%x: int, %y: int) {
       %0 = add(%x, %y);     /* block0 */
       %1 = less(%0, 0);     /* block0 */
       if (%1) {             /* block0 */
           multiply(%0, %x)  /* block1 */
       } else {
           multiply(%0, %y)  /* block2 */
       }
   }
   ```
   Note that `%0` is used in multiple blocks, which per D2 of the [RFC](https://discuss.tvm.apache.org/t/basic-block-normal-form/5908) means it must be let-bound to a variable.
   
   This PR disallows this behavior, with an exception for Constant nodes (they are treated like variables).
   
   cc @eric-haibin-lin @MarisaKirisame @mbrookhart 


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



[GitHub] [tvm] altanh closed pull request #7416: [WIP][Relay][BBNF] Lift nodes used across scope for basic block normal form

Posted by GitBox <gi...@apache.org>.
altanh closed pull request #7416:
URL: https://github.com/apache/tvm/pull/7416


   


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