Merge branch 'master' into HEAD
This commit is contained in:
commit
8e04d80382
@ -55,7 +55,7 @@ To install NCCL on the system, create a package then install it as root.
|
|||||||
Debian/Ubuntu :
|
Debian/Ubuntu :
|
||||||
```shell
|
```shell
|
||||||
$ # Install tools to create debian packages
|
$ # Install tools to create debian packages
|
||||||
$ sudo apt install build-essential devscripts debhelper
|
$ sudo apt install build-essential devscripts debhelper fakeroot
|
||||||
$ # Build NCCL deb package
|
$ # Build NCCL deb package
|
||||||
$ make pkg.debian.build
|
$ make pkg.debian.build
|
||||||
$ ls build/pkg/deb/
|
$ ls build/pkg/deb/
|
||||||
|
@ -880,10 +880,12 @@ static ncclResult_t getCpuGpuAffinity(int cudaDev, cpu_set_t* mask) {
|
|||||||
path[PATH_MAX-1] = '\0';
|
path[PATH_MAX-1] = '\0';
|
||||||
int fd;
|
int fd;
|
||||||
SYSCHECKVAL(open(path, O_RDONLY), "open", fd);
|
SYSCHECKVAL(open(path, O_RDONLY), "open", fd);
|
||||||
char affinityStr[sizeof(cpu_set_t)*2];
|
char affinityStr[sizeof(cpu_set_t)*2 + 1];
|
||||||
int r = read(fd, affinityStr, sizeof(cpu_set_t)*2);
|
int r = read(fd, affinityStr, sizeof(cpu_set_t)*2);
|
||||||
if (r > 0)
|
if (r > 0) {
|
||||||
|
affinityStr[r] = '\0';
|
||||||
NCCLCHECK(ncclStrToCpuset(affinityStr, mask));
|
NCCLCHECK(ncclStrToCpuset(affinityStr, mask));
|
||||||
|
}
|
||||||
close(fd);
|
close(fd);
|
||||||
free(cudaPath);
|
free(cudaPath);
|
||||||
return ncclSuccess;
|
return ncclSuccess;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user