Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run SortPreservingMerge Inputs Concurrently #6162

Closed
tustvold opened this issue Apr 29, 2023 · 1 comment · Fixed by #6308
Closed

Run SortPreservingMerge Inputs Concurrently #6162

tustvold opened this issue Apr 29, 2023 · 1 comment · Fixed by #6308
Assignees
Labels
enhancement New feature or request

Comments

@tustvold
Copy link
Contributor

Is your feature request related to a problem or challenge?

SortPreservingMerge currently interleaves the execution of its input streams, and as a result all its inputs will be evaluated serially.

This is unfortunate if its inputs are performing a potentially expensive operation, such as decoding parquet.

Describe the solution you'd like

Perhaps we should do something similar to RepartitionExec and spawn the inputs into separate tokio tasks, allowing their execution to be scheduled in parallel

Describe alternatives you've considered

Longer-term a true morsel-driven concurrency story might be nice (#2504) and would avoid needing to manually parallelise operators such as SortPreservingMerge, however, this might be a shorter-term mechanism to boost performance.

Additional context

No response

@tustvold tustvold added the enhancement New feature or request label Apr 29, 2023
@alamb
Copy link
Contributor

alamb commented May 1, 2023

Yes, this would be very nice

tustvold added a commit to tustvold/arrow-datafusion that referenced this issue May 9, 2023
@tustvold tustvold self-assigned this May 11, 2023
tustvold added a commit that referenced this issue May 11, 2023
* Parallel merge sort (#6162)

* Fix test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants