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

Faster filtering #8

Merged
merged 1 commit into from Jun 24, 2021
Merged

Faster filtering #8

merged 1 commit into from Jun 24, 2021

Conversation

kelindar
Copy link
Owner

This PR speeds up filtering by around 10-15% by avoiding calling to Contains on each item in the fill list. Instead, we do a SIMD-accelerated AND right before the filter loop, cutting out all of the elements that are not present out of the index. The benchmarks are conservative, and this AND operation doesn't actually eliminate anything since all of the rows have the column.

Not only it removes the Contains calls but also in the case of numbers it should reduce branch mispredictions as there's no more branches during the filter, but I haven't checked the numbers.

@kelindar kelindar merged commit 15fc3b7 into main Jun 24, 2021
@kelindar kelindar deleted the filter branch June 24, 2021 19:39
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

1 participant