You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2018/10/10 01:48:48 UTC

[GitHub] ZhennanQin commented on issue #12764: Updated tvm submodule head

ZhennanQin commented on issue #12764: Updated tvm submodule head
URL: https://github.com/apache/incubator-mxnet/pull/12764#issuecomment-428410251
 
 
   Explain a bit for removing 'FInplaceIdentity' attr for cast and _backward_cast.
   After upgrading tvm, a minor change on memory planning pass is included that allow doing memory inplace optimization on different data type with same size. Eg, for 'cast' op that casting data from fp32 to int32, previously, even  this op has 'FInplaceOption' and 'FInplaceIdentity' attrs, memory inplace won't happen because input and output have different data type(fp32 vs int32). After upgrading tvm, as fp32 and int32 are both 32-bit data size, memory inplace optimization will take effect.
   Memory inplace optimization for 'cast' is a good thing, but 'FInplaceIdentity' will cause trouble when inputs has more than 1 dependence, which means the input will be used by other ops, and memory inplace will override the input, leading result incorrect. Removing 'FInplaceIdentity' can fix this issue.
   Overall, after upgrading tvm with this fix, 'cast' can correctly get benefit from memory inplace optimization now.
   @tqchen What do you think?
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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


With regards,
Apache Git Services