Ted-Jiang opened a new pull request, #3219: URL: https://github.com/apache/arrow-datafusion/pull/3219
# Which issue does this PR close? Closes #3217 . # Rationale for this change <!-- Why are you proposing this change? If this is already explained clearly in the issue then this section is not needed. Explaining clearly why changes are proposed helps reviewers understand your changes and offer better suggestions for fixes. --> Before we use std::sort in update_batch of aggregate `approx_percentile_cont` We can use `arrow::compute::sort` and `merge_sorted_f64 ` replace `merge_unsorted_f64 ` run bench get ``` aggregate_query_approx_percentile_cont_on_u64 time: [6.1686 ms 6.1978 ms 6.2367 ms] change: [-8.4056% -7.5404% -6.5993%] (p = 0.00 < 0.05) Performance has improved. Found 7 outliers among 100 measurements (7.00%) 3 (3.00%) high mild 4 (4.00%) high severe aggregate_query_approx_percentile_cont_on_f32 time: [7.0710 ms 7.1209 ms 7.1847 ms] change: [-7.5669% -6.6221% -5.5469%] (p = 0.00 < 0.05) Performance has improved. Found 13 outliers among 100 measurements (13.00%) 4 (4.00%) high mild 9 (9.00%) high severe ``` # What changes are included in this PR? <!-- There is no need to duplicate the description in the issue here but it is sometimes worth providing a summary of the individual changes in this PR. --> # Are there any user-facing changes? <!-- If there are user-facing changes then we may require documentation to be updated before approving the PR. --> <!-- If there are any breaking changes to public APIs, please add the `api change` label. --> -- 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: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org