t-vi commented on pull request #7231:
URL: https://github.com/apache/tvm/pull/7231#issuecomment-757036217


   @masahi , @codeislife99 : I mentioned this to one of the other PyTorch devs 
and he mentioned that there is a remove mutation pass in PyTorch that should 
take care of the cases where the PyTorch alias analysis can prove it is safe to 
remove it:
   
https://github.com/pytorch/pytorch/blob/aa18d174553e1c2ab4d9e09ae45c6ac323f04af5/torch/csrc/jit/passes/remove_mutation.h#L92
   It doesn't do the slice bits, obviously, but I think running that before 
conversion might be an alternative that seems better than the implicit 
assumption it is safe.
   


----------------------------------------------------------------
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:
[email protected]


Reply via email to