Hzfengsy opened a new pull request, #18323:
URL: https://github.com/apache/tvm/pull/18323

   This PR adds support for conditional expressions in TVMScript parser, which 
allows developers to use Python-style conditional expressions
   
   ```python
   @T.prim_func
   def func(A: T.buffer((128, 128), "float32")):
       for i, j in T.grid(128, 128):
           A[i, j] = i if i < j else j
   
   @T.prim_func
   def expected(A: T.buffer((128, 128), "float32")):
       for i, j in T.grid(128, 128):
           A[i, j] = T.if_then_else(i < j, i, j)
   ```


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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to