Fully disable MSCCL when machine is not matched (#1017)

* Disable MSCCL algorithm meta loading when machine is not matched

* fully disable init

* fix potential segfault
This commit is contained in:
Ziyue Yang
2023-12-14 00:36:21 +08:00
committed by GitHub
parent 53d807a5b9
commit 655742a3a6
4 changed files with 17 additions and 4 deletions
+2 -1
View File
@@ -579,7 +579,8 @@ ncclResult_t ncclTopoPostset(struct ncclComm* comm, int* firstRanks, int* treePa
}
int minNchannels = ncclMinNchannels();
if (mscclEnabled()) {
if (mscclEnabled() && (comm->topo->mscclEnabled || mscclForceEnabled())) {
int mscclNumChannelsRequired = 0;
mscclSchedulerInit(comm, &mscclNumChannelsRequired);
minNchannels = std::max(minNchannels, mscclNumChannelsRequired);