Re-implement DistinctCombineOperator to utilize more threads to merge#14714
Closed
Jackie-Jiang wants to merge 1 commit intoapache:masterfrom
Closed
Re-implement DistinctCombineOperator to utilize more threads to merge#14714Jackie-Jiang wants to merge 1 commit intoapache:masterfrom
Jackie-Jiang wants to merge 1 commit intoapache:masterfrom
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #14714 +/- ##
============================================
+ Coverage 61.75% 63.89% +2.14%
- Complexity 207 1609 +1402
============================================
Files 2436 2703 +267
Lines 133233 150729 +17496
Branches 20636 23282 +2646
============================================
+ Hits 82274 96308 +14034
- Misses 44911 47228 +2317
- Partials 6048 7193 +1145
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
c4fe425 to
0643417
Compare
0643417 to
10410e4
Compare
xiangfu0
approved these changes
Dec 30, 2024
| // Use the atomic reference as the swap space to merge the results blocks. If the swap space is null, put the new | ||
| // results block in it. If the swap space is not null, take the results block from the swap space, and merge it | ||
| // with the new results block. Repeat this process until successfully put the new results block in the swap space. | ||
| // After all threads are done, the results block in the swap space is the final merged results block. |
Contributor
There was a problem hiding this comment.
I am not sure how does this help utilize more threads. Can you elaborate ?
Contributor
Author
There was a problem hiding this comment.
This allows all threads to perform the merge. In the old algorithm, the merge is done by a single thread.
Contributor
|
Close stale PR, please either rebase and get this PR merged or create a new one. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On top of #14701
The combine algorithm is as following:
Use an atomic reference as the swap space to merge the results blocks.
Repeat this process until successfully put the new results block in the swap space.
After all threads are done, the results block in the swap space is the final merged results block.