MCPcopy Create free account
hub / github.com/apache/impala / NextProbeRow

Method NextProbeRow

be/src/exec/nested-loop-join-node.cc:669–694  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

667}
668
669Status NestedLoopJoinNode::NextProbeRow(RuntimeState* state, RowBatch* output_batch) {
670 current_probe_row_ = NULL;
671 matched_probe_ = false;
672 while (probe_batch_pos_ == probe_batch_->num_rows()) {
673 probe_batch_->TransferResourceOwnership(output_batch);
674 probe_batch_pos_ = 0;
675 // If output_batch_ is at capacity after acquiring probe_batch_'s resources, we
676 // need to pass it up through the execution before getting a new probe batch.
677 // Otherwise, subsequent GetNext() calls to the probe input may cause the
678 // memory referenced by this batch to be deleted (see IMPALA-2191).
679 if (output_batch->AtCapacity()) return Status::OK();
680 if (probe_side_eos_) {
681 eos_ = !NeedToProcessUnmatchedBuildRows(join_op_);
682 return Status::OK();
683 } else {
684 RETURN_IF_ERROR(child(0)->GetNext(state, probe_batch_.get(), &probe_side_eos_));
685 COUNTER_ADD(probe_row_counter_, probe_batch_->num_rows());
686 }
687 }
688 current_probe_row_ = probe_batch_->GetRow(probe_batch_pos_++);
689 // We have a valid probe row; reset the build row iterator.
690 build_row_iterator_ = build_batches_->Iterator();
691 current_build_row_idx_ = 0;
692 VLOG_ROW << "left row: " << GetLeftChildRowString(current_probe_row_);
693 return Status::OK();
694}

Callers

nothing calls this directly

Calls 9

OKFunction · 0.85
getMethod · 0.65
num_rowsMethod · 0.45
AtCapacityMethod · 0.45
GetNextMethod · 0.45
GetRowMethod · 0.45
IteratorMethod · 0.45

Tested by

no test coverage detected