yiguolei commented on code in PR #60367:
URL: https://github.com/apache/doris/pull/60367#discussion_r2834342623
##########
be/src/pipeline/exec/partitioned_hash_join_probe_operator.cpp:
##########
@@ -165,72 +216,122 @@ Status
PartitionedHashJoinProbeLocalState::close(RuntimeState* state) {
return Status::OK();
}
-Status
PartitionedHashJoinProbeLocalState::_execute_spill_probe_blocks(RuntimeState*
state,
- const
UniqueId& query_id) {
- SCOPED_TIMER(_spill_probe_timer);
+Status PartitionedHashJoinProbeLocalState::spill_probe_blocks(RuntimeState*
state) {
+ auto query_id = state->query_id();
- size_t not_revoked_size = 0;
- auto& p = _parent->cast<PartitionedHashJoinProbeOperatorX>();
- for (uint32_t partition_index = 0; partition_index != p._partition_count;
++partition_index) {
- auto& blocks = _probe_blocks[partition_index];
- auto& partitioned_block = _partitioned_blocks[partition_index];
- if (partitioned_block) {
- const auto size = partitioned_block->allocated_bytes();
- if (size >= vectorized::SpillStream::MIN_SPILL_WRITE_BATCH_MEM) {
- blocks.emplace_back(partitioned_block->to_block());
- partitioned_block.reset();
- } else {
- not_revoked_size += size;
+ auto spill_func = [query_id, state, this] {
Review Comment:
lamda 太长了
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]