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

perf: Predict hash table size for aggregation #253

Merged
merged 4 commits into from
Apr 28, 2023

Conversation

canhld94
Copy link
Collaborator

Changelog category :

  • Performance Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

  • Predict hash table size to preallocate during group by

Documentation entry for user-facing changes

  • Documentation is written (mandatory for new features)

auto & tbl = expr.database_and_table_name->as<DB::ASTTableIdentifier &>();
auto db_name = tbl.name_parts.size() == 2 ? tbl.name_parts[0] : "";
auto tb_name = tbl.name_parts.size() == 2 ? tbl.name_parts[1] : tbl.name_parts[0];
/// Table name in worker has name like t_441011350722576384 with last 18 characters
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe we can use table uuid in future.

}
}
}
hash.update(tables->getTreeHash());
Copy link
Contributor

Choose a reason for hiding this comment

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

how the table renaming is updated?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I forgot to push a commit. Just push it now.

@hustnn hustnn merged commit 07cb618 into master Apr 28, 2023
2 checks passed
@WillemJiang WillemJiang changed the title [perf] Predict hash table size for aggregation perf: Predict hash table size for aggregation May 15, 2023
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.

None yet

2 participants