tqchen commented on code in PR #15870:
URL: https://github.com/apache/tvm/pull/15870#discussion_r1346091140
##########
src/runtime/disco/nccl/nccl.cc:
##########
@@ -140,9 +140,19 @@ struct CCLThreadLocalContext {
deviceStream_t default_stream = nullptr;
ncclComm_t comm;
- void Clear() { NCCL_CALL(ncclCommDestroy(comm)); }
+ void Clear() {
+ NCCL_CALL(ncclCommDestroy(comm));
+ if (default_stream != nullptr) {
Review Comment:
given in this case `default_stream` is a member that can be changed later, i
think having such code is better. Note it is not the same as the default stream
in the CUDA terminology, but in the nccl runtime
--
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]