save-buffer commented on code in PR #12289:
URL: https://github.com/apache/arrow/pull/12289#discussion_r868529898
##########
cpp/src/arrow/compute/exec/hash_join.cc:
##########
@@ -651,23 +777,44 @@ class HashJoinBasicImpl : public HashJoinImpl {
return Status::OK();
}
+ Status BuildBloomFilter_on_finished(size_t thread_index) {
+ if (cancelled_) return Status::Cancelled("Hash join cancelled");
+ ARROW_DCHECK(pushdown_target_);
+ RETURN_NOT_OK(pushdown_target_->PushBloomFilter(
+ thread_index, std::move(bloom_filter_), std::move(column_map_)));
+ return BuildHashTable(thread_index);
+ }
+
Status BuildHashTable_on_finished(size_t thread_index) {
if (cancelled_) {
return Status::Cancelled("Hash join cancelled");
}
+ bool proceed;
{
std::lock_guard<std::mutex> lock(left_batches_mutex_);
+ std::lock_guard<std::mutex> lock_finish(finished_mutex_);
+ left_queue_bloom_finished_ =
+ left_queue_bloom_finished_ || num_expected_bloom_filters_ == 0;
+ proceed = !has_hash_table_ && left_queue_bloom_finished_;
has_hash_table_ = true;
}
+ if (proceed) RETURN_NOT_OK(ProbeQueuedBatches(thread_index));
right_batches_.clear();
Review Comment:
Seems harmless, I'll do that.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]