Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NewComm] Fix hogwild_worker compilation problem of unused variable. #57781

Merged
merged 1 commit into from
Sep 27, 2023
Merged
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
3 changes: 0 additions & 3 deletions paddle/fluid/framework/hogwild_worker.cc
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ bool HogwildWorker::CheckBatchNum(int flag) {
}
g_barrier.wait();
float *stat_ptr = sync_stat_.data<float>();
int nranks = 0;
int ring_id = 0;
platform::NCCLComm *comm = nullptr;
const auto &comm_context_manager =
Expand All @@ -181,11 +180,9 @@ bool HogwildWorker::CheckBatchNum(int flag) {
platform::errors::Unavailable(
"NCCLCommContext is nullptr, collective op should "
"has ring_id attr."));
nranks = comm_ctx->GetSize();
} else {
comm = platform::NCCLCommContext::Instance().Get(ring_id,
place_.GetDeviceId());
nranks = comm->nranks();
}

auto stream = static_cast<phi::GPUContext *>(dev_ctx_)->stream();
Expand Down