Mryange opened a new pull request, #61946:
URL: https://github.com/apache/doris/pull/61946
### What problem does this PR solve?
Continue the migration from old `VExprContext::execute(Block*, int*)` API to
the new `VExprContext::execute(const Block*, ColumnPtr&)` API, following up on
#61912 (Part 1).
The old API inserts the result column into the Block and returns a column
index, which mutates the Block and causes unnecessary column lifetime coupling.
The new API returns the result column directly without modifying the Block.
### Changes
- **vectorized_agg_fn**: Use new execute API with a calc-then-reset pattern
— `_calc_argument_columns()` populates holders, and `_reset_input_columns()`
clears them after each aggregation call to avoid inflating VSlotRef shared
column reference counts.
- **hashjoin_probe_operator**: Change `_do_evaluate` /
`_extract_join_column` / `_need_probe_null_map` to work with
`vector<ColumnPtr>` instead of `vector<int>`. All column references stored in
`_key_columns_holder` to keep raw pointers alive.
- **distinct_streaming_aggregation_operator**: Replace `result_idxs` with
`Columns key_column_ptrs`. Simplify the streaming swap path to `std::move` +
`in_block->clear()`.
- **set_probe_sink_operator**: Use `_probe_column_holders` to hold
ColumnPtrs. Remove dead `_probe_column_inserted_id` field.
- **scanner**: Replace `execute + shuffle_columns` with
`execute(ColumnWithTypeAndName)` overload + direct Block c
### Release note
None
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] Regression test
- [ ] Unit Test
- [ ] Manual test (add detailed scripts or steps below)
- [ ] No need to test or manual test. Explain why:
- [ ] This is a refactor/code format and no logic has been changed.
- [ ] Previous test can cover this change.
- [ ] No code files have been changed.
- [ ] Other reason <!-- Add your reason? -->
- Behavior changed:
- [ ] No.
- [ ] Yes. <!-- Explain the behavior change -->
- Does this need documentation?
- [ ] No.
- [ ] Yes. <!-- Add document PR link here. eg:
https://github.com/apache/doris-website/pull/1214 -->
### Check List (For Reviewer who merge this PR)
- [ ] Confirm the release note
- [ ] Confirm test cases
- [ ] Confirm document
- [ ] Add branch pick label <!-- Add branch pick label that this PR should
merge into -->
--
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]