Back to News
Advertisement
tthomasahle about 19 hours ago 9 commentsRead Article on thomasahle.com

ZH version is available. Content is displayed in original English for accuracy.

A few years ago my coauthor and I was wondering if we could reduce the number of multiplications used for hashing algorithms. We had a construction and a 100 page proof, but we were not 100% sure it was correct. Now we have a full Lean proof, so we decided to publish it.

I made this website to make it easy for anyone how has polynomials to evaluate to see how it would be done using our method, as well as a number of previous approaches by Knuth and others.

Advertisement

⚡ Community Insights

Discussion Sentiment

100% Positive

Analyzed from 160 words in the discussion.

Trending Topics

#monic#faster#between#algorithms#curious#hashes#using#construction#multiplications#keeps

Discussion (9 Comments)Read Original on HackerNews

voxelghostabout 1 hour ago
It keeps flipping back to 'monic' from e.g. 'ln(1+x)' when switching between algorithms, and then seems to lock to 'monic'? (Am I missing something?)

Also I am curious, in your version vs. horner , how do both algorithms map onto number of fmadd operations?

gowldabout 1 hour ago
"monic" is a separate switch from the example functions radio-selector. Enabling "monic" removes the leading coefficient.
vlovich123about 1 hour ago
Would this be applicable to fast hashes like WyHash and xxh3 or are those not using polynomials? Is this mainly for faster cryptographic hashes?
aetherspawnabout 2 hours ago
I guess it’s not faster than using a table for CRC8?
gowldabout 1 hour ago
From the abstract, a name that many on HN would recognize:

> We also give an injective polynomial construction for universal hashing that uses N multiplications to hash 2N values with a single random key. This improves the best previous construction by Daniel J. Bernstein (this http URL).

gowldabout 1 hour ago
What is the tradeoff between multiplication and addition?
nraynaud26 minutes ago
Just a few years ago, mults were slower, but I think now (Intel i9) mult, add and fma are the same.

https://stackoverflow.com/a/39135689

gigatexalabout 1 hour ago
I think multiplications are faster to do in computer land than adds? I too am curious.
hyperhelloabout 1 hour ago
Also could use analysis of dependencies to see what can happen in parallel. Or for that matter, some real benchmarks.