anirudh2290 commented on a change in pull request #14397: [WIP] Add exception 
handling support for waitall
URL: https://github.com/apache/incubator-mxnet/pull/14397#discussion_r264884326
 
 

 ##########
 File path: src/engine/threaded_engine.h
 ##########
 @@ -177,7 +177,11 @@ class ThreadedVar final
   static std::atomic<std::size_t> counter;
   ~ThreadedVar() { LOG(INFO) << __func__ << " " << --counter; }
 #endif  // ENGINE_DEBUG
-  /*! \brief exception_ptr associated with the ThreadedVar */
+  /*!
+   * \brief exception_ptr associated with the ThreadedOpr
+   * cannot modify state of exception object since dereferencing
+   * exception_ptr is undefined behavior. Using shared_ptr to hold
 
 Review comment:
   the purpose is to update the object that exception ptr points to and 
dereferencing an exception_ptr is undefined behavior. So wrapping it in 
shared_ptr is another way.

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


With regards,
Apache Git Services

Reply via email to