Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Binyang2014 committed Jan 23, 2024
1 parent 2eb20af commit 8e32bd2
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
1 change: 1 addition & 0 deletions python/mscclpp/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,5 +154,6 @@ def pack(*args):
raise RuntimeError(f"Unsupported type: {type(arg)}")
return res


def is_nvls_supported():
return cp.cuda.runtime.runtimeGetVersion() >= 12010
1 change: 1 addition & 0 deletions src/nvls_connection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include <sys/syscall.h>
#include <unistd.h>

#include <algorithm>
#include <mscclpp/core.hpp>
#include <mscclpp/utils.hpp>

Expand Down
6 changes: 3 additions & 3 deletions src/utils.cc
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ std::string getHostName(int maxlen, const char delim) {
bool isNvlsSupported() {
#if (CUDART_VERSION >= 12010)
CUdevice dev;
int nvlsSupport;
int isNvlsSupported;
MSCCLPP_CUTHROW(cuCtxGetDevice(&dev));
MSCCLPP_CUTHROW(cuDeviceGetAttribute(&nvlsSupport, CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED, dev));
return nvlsSupport == 1;
MSCCLPP_CUTHROW(cuDeviceGetAttribute(&isNvlsSupported, CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED, dev));
return isNvlsSupported == 1;
#endif
return false;
}
Expand Down

0 comments on commit 8e32bd2

Please sign in to comment.