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

+Perfect GroupBy and some old GroupBy algos changes #35

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

Conversation

bagrorg
Copy link
Collaborator

@bagrorg bagrorg commented Jul 12, 2022

No description provided.

@bagrorg bagrorg changed the title Groupby branch +Perfect GroupBy and some old GroupBy algos changes Jul 12, 2022
@bagrorg bagrorg marked this pull request as draft July 12, 2022 12:28
@bagrorg bagrorg marked this pull request as ready for review August 23, 2022 13:47
@@ -91,7 +91,8 @@ void PerfectGroupBy::_run(const size_t buf_size, Meter &meter) {
h.single_task<class clean>([=]() {
for (size_t i = 0; i < groups_count * threads_count; i++) {
ht_v[i] = 0;
o[i] = 0;
if (i < groups_count)
o[i] = 0;
Copy link
Owner

Choose a reason for hiding this comment

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

What's the logic behind this one?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Here we want to clear all output from previous iteration using single_task
However, groups_count * threads_count may be bigger than output array size, so we need to control it to prevent SEGFAULT
This is not so clear, I wanted to do it in one for loop, but is it better to separate this two operations into two single_tasks?

Copy link
Owner

Choose a reason for hiding this comment

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

I guess no big difference since it's a single task

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