MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / DispatchSend

Method DispatchSend

tensorflow/core/common_runtime/ring_alg.cc:380–396  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

378}
379
380void RingAlg::DispatchSend(RingField* rf, const StatusCallback& done) {
381 DCHECK(rf->do_send);
382 string send_buf_key = RingAlgBufKey(name_, col_ctx_->exec_key,
383 rf->second_pass, rf->sc_idx, rf->rank);
384 VLOG(3) << "DispatchSend rank=" << col_params_->default_rank << " send key "
385 << send_buf_key << " chunk " << ca_->TBounds(rf->chunk) << " sc_idx "
386 << rf->sc_idx;
387 int send_to_rank = (rf->rank + 1) % group_size_;
388 int send_to_dev_idx = col_params_->instance.impl_details
389 .subdiv_permutations[rf->subdiv_idx][send_to_rank];
390 col_ctx_->col_exec->PostToPeer(
391 col_params_->instance.device_names[send_to_dev_idx],
392 col_params_->instance.task_names[send_to_dev_idx], send_buf_key,
393 col_ctx_->device, col_ctx_->op_ctx->op_device_context(),
394 col_ctx_->op_ctx->output_alloc_attr(0), &rf->chunk,
395 col_ctx_->device_locality, done);
396}
397
398void RingAlg::DispatchRecv(RingField* rf, const StatusCallback& done) {
399 DCHECK(rf->do_recv);

Callers

nothing calls this directly

Calls 5

RingAlgBufKeyFunction · 0.85
TBoundsMethod · 0.80
output_alloc_attrMethod · 0.80
PostToPeerMethod · 0.45
op_device_contextMethod · 0.45

Tested by

no test coverage detected