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

Vectorized grouping by multiple column #7754

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

akuzm
Copy link
Member

@akuzm akuzm commented Feb 19, 2025

Paste the values together and use the umash hash of the resulting value for grouping, like we do for the text keys.

Up to 150% improvement on some tsbench queries.

Paste the values together and use the umash hash of the resulting value
for grouping, like we do for the text keys.
Copy link

codecov bot commented Feb 19, 2025

Codecov Report

Attention: Patch coverage is 89.44954% with 23 lines in your changes missing coverage. Please review.

Project coverage is 81.96%. Comparing base (59f50f2) to head (a162488).
Report is 799 commits behind head on main.

Files with missing lines Patch % Lines
...odes/vector_agg/hashing/hash_strategy_serialized.c 88.70% 2 Missing and 19 partials ⚠️
tsl/src/nodes/vector_agg/grouping_policy_hash.c 90.90% 0 Missing and 1 partial ⚠️
...rc/nodes/vector_agg/hashing/batch_hashing_params.h 83.33% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7754      +/-   ##
==========================================
+ Coverage   80.06%   81.96%   +1.89%     
==========================================
  Files         190      248      +58     
  Lines       37181    45622    +8441     
  Branches     9450    11404    +1954     
==========================================
+ Hits        29770    37392    +7622     
- Misses       2997     3744     +747     
- Partials     4414     4486      +72     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@akuzm akuzm mentioned this pull request Feb 19, 2025
11 tasks
@akuzm akuzm marked this pull request as ready for review February 28, 2025 10:15
@@ -225,7 +227,7 @@ add_one_range(GroupingPolicyHash *policy, TupleTableSlot *vector_slot, const int
* Remember which aggregation states have already existed, and which we
* have to initialize. State index zero is invalid.
*/
const uint32 last_initialized_key_index = policy->last_used_key_index;
const uint32 last_initialized_key_index = policy->hashing.last_used_key_index;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did some mechanical refactoring to move more hashing-related data into the hashing strategy struct.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant