Fix pytest failure (#567)

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Binyang Li
2025-07-11 16:49:28 -07:00
committed by GitHub
parent 65c10fa8ec
commit 9b71d524b3

View File

@@ -220,7 +220,9 @@ std::shared_ptr<char> NvlsConnection::Impl::bindMemory(CUdeviceptr devicePtr, si
MSCCLPP_CUTHROW(cuDeviceGet(&device, deviceId));
MSCCLPP_CUTHROW(cuMemUnmap((CUdeviceptr)ptr, devBuffSize));
MSCCLPP_CUTHROW(cuMemAddressFree((CUdeviceptr)ptr, devBuffSize));
MSCCLPP_CUTHROW(cuMulticastUnbind(mcHandle_, device, offset, devBuffSize));
// Refer to NCCL, Unbind can trigger RM error if buffer is freed already by users.
// Ignore error here, unbind will succeed anyway.
cuMulticastUnbind(mcHandle_, device, offset, devBuffSize);
self->freeBuffer(offset, devBuffSize);
};