Skip to content

Commit

Permalink
[coll] Increase timeout for allgather test. (#9777)
Browse files Browse the repository at this point in the history
  • Loading branch information
trivialfis authored Nov 8, 2023
1 parent 44099f5 commit 6fd4a30
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/cpp/collective/test_allgather.cc
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class Worker : public WorkerForTest {

std::size_t n = 8192; // n_bytes = 8192 * sizeof(int)
std::vector<std::int32_t> data(comm_.World() * n, 0);
auto s_data = common::Span{data.data(), data.size()};
auto s_data = common::Span<std::int32_t>{data};
auto seg = s_data.subspan(comm_.Rank() * n, n);
std::iota(seg.begin(), seg.end(), comm_.Rank());

Expand Down
3 changes: 2 additions & 1 deletion tests/cpp/collective/test_worker.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,12 @@ class TrackerTest : public SocketTest {

template <typename WorkerFn>
void TestDistributed(std::int32_t n_workers, WorkerFn worker_fn) {
std::chrono::seconds timeout{1};
std::chrono::seconds timeout{2};

std::string host;
auto rc = GetHostAddress(&host);
ASSERT_TRUE(rc.OK()) << rc.Report();
LOG(INFO) << "Using " << n_workers << " workers for test.";
RabitTracker tracker{StringView{host}, n_workers, 0, timeout};
auto fut = tracker.Run();

Expand Down

0 comments on commit 6fd4a30

Please sign in to comment.