Skip to content

Commit

Permalink
#1445: active: Add LB stats instrumentation for self-send runnable ob…
Browse files Browse the repository at this point in the history
…ject
  • Loading branch information
JacobDomagala committed Jan 18, 2022
1 parent 6d19474 commit e199648
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/vt/messaging/active.cc
Original file line number Diff line number Diff line change
Expand Up @@ -528,8 +528,21 @@ EventType ActiveMessenger::doMessageSend(
if (dest != this_node) {
sendMsgBytesWithPut(dest, base, send_tag);
} else {
if (theContext()->getTask() != nullptr) {
auto lb = theContext()->getTask()->get<ctx::LBStats>();
if (lb) {
auto const already_recorded =
envelopeCommStatsRecordedAboveBareHandler(msg->env);
if (not already_recorded) {
auto dest_elm_id = elm::ElmIDBits::createBareHandler(dest);
theContext()->getTask()->send(dest_elm_id, base.size());
}
}
}

runnable::makeRunnable(base, true, envelopeGetHandler(msg->env), dest)
.withTDEpochFromMsg(is_term)
.withLBStats(&bare_handler_stats_, bare_handler_dummy_elm_id_for_lb_stats_)
.enqueue();
}
return no_event;
Expand Down

0 comments on commit e199648

Please sign in to comment.