Skip to content

Commit

Permalink
fix operator addInput stats collection
Browse files Browse the repository at this point in the history
  • Loading branch information
LeonidChistov committed Jan 22, 2025
1 parent 13f2c7c commit b8c318f
Showing 1 changed file with 18 additions and 17 deletions.
35 changes: 18 additions & 17 deletions velox/exec/Driver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -615,23 +615,24 @@ StopReason Driver::runInternal(
});
pushdownFilters(i);
if (intermediateResult) {
withDeltaCpuWallTimer(op, &OperatorStats::addInputTiming, [&]() {
{
auto lockedStats = nextOp->stats().wlock();
lockedStats->addInputVector(
resultBytes, intermediateResult->size());
}
nextOp->traceInput(intermediateResult);
TestValue::adjust(
"facebook::velox::exec::Driver::runInternal::addInput",
nextOp);

CALL_OPERATOR(
nextOp->addInput(intermediateResult),
nextOp,
curOperatorId_ + 1,
kOpMethodAddInput);
});
withDeltaCpuWallTimer(
nextOp, &OperatorStats::addInputTiming, [&]() {
{
auto lockedStats = nextOp->stats().wlock();
lockedStats->addInputVector(
resultBytes, intermediateResult->size());
}
nextOp->traceInput(intermediateResult);
TestValue::adjust(
"facebook::velox::exec::Driver::runInternal::addInput",
nextOp);

CALL_OPERATOR(
nextOp->addInput(intermediateResult),
nextOp,
curOperatorId_ + 1,
kOpMethodAddInput);
});
// The next iteration will see if operators_[i + 1] has
// output now that it got input.
i += 2;
Expand Down

0 comments on commit b8c318f

Please sign in to comment.