Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions csrc/multidevice/ipc_handle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,12 @@ void IpcHandleCache::exchangeHandles(

insert(communication, std::move(ipc_handles));
}

// a second barrier is needed here to ensure all ranks have received the
// memhandles and the keys are deleted from the store before the next call to
// exchangeHandles
// TODO: precisely select what ranks need to wait on that barrier.
communicator->barrier();
}

} // namespace nvfuser
2 changes: 1 addition & 1 deletion tests/cpp/test_multidevice_communications.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ INSTANTIATE_TEST_SUITE_P(

using P2PCommunicationTest = MultiDeviceTest;

TEST_F(P2PCommunicationTest, DISABLED_CudaComm) {
TEST_F(P2PCommunicationTest, CudaComm) {
static constexpr int kTensorSize = 8;
static constexpr int kNumRepetitions = 32;

Expand Down
2 changes: 1 addition & 1 deletion tests/cpp/test_multidevice_host_ir.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ TEST_F(OverlapDistributedMatmulTest, AG_linear) {
EXPECT_TRUE(torch::allclose(out_ref, out_at, 1e-1, 1e-1));
}

TEST_F(MultiDeviceTest, DISABLED_ShareIpcMemHandles) {
TEST_F(MultiDeviceTest, ShareIpcMemHandles) {
static constexpr int kTensorSize = 4;
static constexpr int kNumRepetitions = 10;

Expand Down