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

   Currently the ABI of tvm::runtime::Map will change if TVM_LOG_DEBUG is 
enabled or not:
   ```
   // In MapNode::iterator
   #if TVM_LOG_DEBUG
       uint64_t state_marker;
       ...
   #else
       ...
   #endif  // TVM_LOG_DEBUG
   ```
   When TVM_LOG_DEBUG is inconsistent between different libraries (e.g. in TVM 
and in MLC-LLM), the inconsistency in ABI will lead to an invalid read/write.
   
   This PR introduces another macro `TVM_DEBUG_WITH_ABI_CHANGE` for such cases 
to warn users that this debug option can lead to changes in ABI. It is not 
enabled by default.
   
   cc @areusch @tqchen 
   
   


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