Lunderberg commented on issue #17239:
URL: https://github.com/apache/tvm/issues/17239#issuecomment-2269415367

   Looks like this is a combination of a couple of factors.
   
   1. Like `R.call_tir`, the arguments in `R.call_tir_inplace` must be an 
in-line `relax::Tuple` (See the discussion in 
https://github.com/apache/tvm/pull/15916 for discussion on this requirement.)
   2. The argument provided to `R.call_tir_inplace` is wrapped into an in-line 
tuple if it is not already an in-line tuple.  While the normalization of 
`R.call_tir_inplace` would handle this case if the expression is generated 
through C++, this wrapping generates a tuple of var-to-tuple (`R.tuple(args)`), 
circumventing the normalization.
   3. The error-checking by `R.call_tir_inplace` can be triggered by multiple 
conditions (argument is not a tensor, argument doesn't have known shape, 
argument's known shape does not match output shape), but the error message 
attempts to access the argument's known shape, triggering a segfault if it 
doesn't actually exist.


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