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

optimize: ContainesHash method adopts fast failure #12

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

imalasong
Copy link

When determining whether to include an element, as long as any bit does not match, it can be determined that the element does not exist. I think this quick failure method should improve performance

Copy link

@eltNEG eltNEG left a comment

Choose a reason for hiding this comment

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

@holiman This change looks good. Please consider merging it.

Copy link
Owner

@holiman holiman left a comment

Choose a reason for hiding this comment

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

This change adds a conditional inside a tight loop. Please demonstrate (via benchmark) that it's an improvement in speed

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.

3 participants