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

Modernize XXH32/XXH64 #989

Merged
merged 2 commits into from
Dec 28, 2024
Merged

Modernize XXH32/XXH64 #989

merged 2 commits into from
Dec 28, 2024

Conversation

Cyan4973
Copy link
Owner

code refactor

  • Fix the state structs to use unsigned char, update names
  • Extract the algorithm steps into inline subroutines
  • Fix a theoretical integer overflow bug
  • Reroll XXH64 on 32-bit (it is going to run like crap anyway)

cherry-picked 0a9db72 from #802 by @easyaspi314

no performance difference in tests

easyaspi314 and others added 2 commits December 27, 2024 16:28
 - Fix the state structs to use unsigned char, update names
 - Extract the algorithm steps into inline subroutines
 - Fix a theoretical integer overflow bug
 - Reroll XXH64 on 32-bit (it is going to run like crap anyway)
they are suspicious that some tests on unsigned values might wrap around.
They should not, but let's write these branches differently to also cover these cases.
@Cyan4973 Cyan4973 self-assigned this Dec 28, 2024
@Cyan4973 Cyan4973 merged commit abae92f into dev Dec 28, 2024
126 checks passed
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.

2 participants