-
Notifications
You must be signed in to change notification settings - Fork 110
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
issue 158: Add SmallState #226
Conversation
Signed-off-by: Tom Kaitchuck <Tom.Kaitchuck@gmail.com>
I performed a quick benchmark with runtime-rng enabled (the most common feature I suppose) and the time to hash a 10 byte string goes from 2.5ns to 12.3ns, which puts it in siphash territory. Do you think we could take some liberties with the creation of RandomState from SmallState, like
This brings it down from 12ns to 4ns |
Signed-off-by: Tom Kaitchuck <Tom.Kaitchuck@gmail.com>
@arthurprs The code you have there won't be sufficiently strong. But I have tried to speed it up. Give it another try. |
Signed-off-by: Tom Kaitchuck <Tom.Kaitchuck@gmail.com>
I think I should be able to lower the added overhead by another 20%. |
Signed-off-by: Tom Kaitchuck <Tom.Kaitchuck@gmail.com>
@arthurprs Is e2ae7b7 any faster on your system? It should be, but it my tests it appears to be, but only by about the same margin as random variation, so I am not sure if it is significant. |
I can confirm the latest commit (~5ns) is 12% faster than the previous. |
Is an optional reduced size state.
Fixes #158